Replace numeric parameter like 0444 with macro
PATCH 837/1285 Replace numeric parameter like 0444 with macro
I find that the developers often just specified the numeric value
when calling a macro which is defined with a parameter for access permission. As we know, these numeric value for access permission have had the corresponding macro, and that using macro can improve the robustness and readability of the code, thus, I suggest replacing the numeric parameter with the macro.
Signed-off-by Chuansheng Liu <[email protected]>
Signed-off-by Baole Ni <[email protected]>
--- drivers/pcmcia/yenta_socket.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-)
drivers/pcmcia/yenta_socket.c +4 -4
@@ -25,19 +25,19 @@#include "i82365.h" static bool disable_clkrun; -module_param (disable_clkrun, bool,0444 ); +module_param (disable_clkrun, bool,S_IRUSR |S_IRGRP |S_IROTH );MODULE_PARM_DESC (disable_clkrun,"If PC card doesn't function properly, please try this option" );static bool isa_probe =1 ; -module_param (isa_probe, bool,0444 ); +module_param (isa_probe, bool,S_IRUSR |S_IRGRP |S_IROTH );MODULE_PARM_DESC (isa_probe,"If set ISA interrupts are probed (default). Set to N to disable probing" );static bool pwr_irqs_off; -module_param (pwr_irqs_off, bool,0644 ); +module_param (pwr_irqs_off, bool,S_IRUSR |S_IWUSR |S_IRGRP |S_IROTH );MODULE_PARM_DESC (pwr_irqs_off,"Force IRQs off during power-on of slot. Use only when seeing IRQ storms!" );static char o2_speedup[] ="default" ; -module_param_string (o2_speedup, o2_speedup,sizeof (o2_speedup),0444 ); +module_param_string (o2_speedup, o2_speedup,sizeof (o2_speedup),S_IRUSR |S_IRGRP |S_IROTH );MODULE_PARM_DESC (o2_speedup,"Use prefetch/burst for O2-bridges: 'on', 'off' " "or 'default' (uses recommended behaviour for the detected bridge)" );
Signature · 1 line
2.9.2