All of lore.kernel.org
 help / color / mirror / Atom feed
From: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
To: "Rodolfo C. Villordo" <rodolfovillordo@gmail.com>
Cc: linux-kernel@vger.kernel.org, devel@driverdev.osuosl.org,
	Richard Yeh <rcy@google.com>, Rob Springer <rspringer@google.com>,
	Todd Poynor <toddpoynor@google.com>
Subject: Re: [PATCH] staging: gasket: replace symbolic permissions
Date: Thu, 18 Jun 2020 09:47:50 +0200	[thread overview]
Message-ID: <20200618074750.GA186463@kroah.com> (raw)
In-Reply-To: <20200601005240.6315-1-rodolfovillordo@gmail.com>

On Mon, Jun 01, 2020 at 12:52:40AM +0000, Rodolfo C. Villordo wrote:
> WARNING: Symbolic permissions 'S_IRUGO' are not preferred. Consider using octal permissions '0444'.
> +               .attr = __ATTR(_name, S_IRUGO, _show_function, NULL),          \
> warning detected by checkpatch.pl
> 
> Signed-off-by: Rodolfo C. Villordo <rodolfovillordo@gmail.com>
> ---
>  drivers/staging/gasket/gasket_sysfs.h | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/drivers/staging/gasket/gasket_sysfs.h b/drivers/staging/gasket/gasket_sysfs.h
> index ab5aa351d555..d5e167dfbe76 100644
> --- a/drivers/staging/gasket/gasket_sysfs.h
> +++ b/drivers/staging/gasket/gasket_sysfs.h
> @@ -71,7 +71,7 @@ struct gasket_sysfs_attribute {
>  
>  #define GASKET_SYSFS_RO(_name, _show_function, _attr_type)                     \
>  	{                                                                      \
> -		.attr = __ATTR(_name, S_IRUGO, _show_function, NULL),          \
> +		.attr = __ATTR(_name, 0444, _show_function, NULL),          \

What about using __ATTR_RO() instead?

thanks,

greg k-h

  reply	other threads:[~2020-06-18  7:47 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-06-01  0:52 [PATCH] staging: gasket: replace symbolic permissions Rodolfo C. Villordo
2020-06-18  7:47 ` Greg Kroah-Hartman [this message]
2020-06-19  8:27   ` Rodolfo C Villordo
2020-06-19  8:32     ` Greg Kroah-Hartman
2020-06-22  7:13       ` Rodolfo C Villordo

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20200618074750.GA186463@kroah.com \
    --to=gregkh@linuxfoundation.org \
    --cc=devel@driverdev.osuosl.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=rcy@google.com \
    --cc=rodolfovillordo@gmail.com \
    --cc=rspringer@google.com \
    --cc=toddpoynor@google.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.