Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.kernel > #1455177

Re: [PATCH 0875/1285] Replace numeric parameter like 0444 with macro

From Heiko Carstens <heiko.carstens@de.ibm.com>
Newsgroups linux.kernel
Subject Re: [PATCH 0875/1285] Replace numeric parameter like 0444 with macro
Date 2016-08-02 19:50 +0200
Message-ID <s1LZf-7Ht-1@gated-at.bofh.it> (permalink)
References <s1JNM-6gj-23@gated-at.bofh.it>
Organization linux.* mail to news gateway

Show all headers | View raw


On Tue, Aug 02, 2016 at 07:54:12PM +0800, Baole Ni wrote:
> 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 <chuansheng.liu@intel.com>
> Signed-off-by: Baole Ni <baolex.ni@intel.com>
> ---
>  drivers/s390/block/dasd_devmap.c | 38 +++++++++++++++++++-------------------
>  1 file changed, 19 insertions(+), 19 deletions(-)
> 
> diff --git a/drivers/s390/block/dasd_devmap.c b/drivers/s390/block/dasd_devmap.c
> index 3cdbce4..a70a159 100644
> --- a/drivers/s390/block/dasd_devmap.c
> +++ b/drivers/s390/block/dasd_devmap.c
> @@ -747,7 +747,7 @@ static ssize_t dasd_ff_store(struct device *dev, struct device_attribute *attr,
>  	return count;
>  }
> 
> -static DEVICE_ATTR(failfast, 0644, dasd_ff_show, dasd_ff_store);
> +static DEVICE_ATTR(failfast, S_IRUSR | S_IWUSR | S_IRGRP | S_IROTH, dasd_ff_show, dasd_ff_store);

Please consider all patches NACK'ed that touch s390 code, for the same
reasons that have been outlined by several other people.

Back to linux.kernel | Previous | NextPrevious in thread | Find similar | Unroll thread


Thread

[PATCH 0875/1285] Replace numeric parameter like 0444 with macro Baole Ni <baolex.ni@intel.com> - 2016-08-02 17:30 +0200
  Re: [PATCH 0875/1285] Replace numeric parameter like 0444 with macro Heiko Carstens <heiko.carstens@de.ibm.com> - 2016-08-02 19:50 +0200

csiph-web