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]> --- arch/powerpc/platforms/powernv/subcore.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/arch/powerpc/platforms/powernv/subcore.c b/arch/powerpc/platforms/powernv/subcore.c index 0babef1..efffe94 100644 --- a/arch/powerpc/platforms/powernv/subcore.c +++ b/arch/powerpc/platforms/powernv/subcore.c @@ -402,7 +402,7 @@ static ssize_t show_subcores_per_core(struct device *dev, return sprintf(buf, "%x\n", subcores_per_core); } -static DEVICE_ATTR(subcores_per_core, 0644, +static DEVICE_ATTR(subcores_per_core, S_IRUSR | S_IWUSR | S_IRGRP | S_IROTH, show_subcores_per_core, store_subcores_per_core); static int subcore_init(void) -- 2.9.2

