From: Nigel Christian <nigel.l.christian@gmail.com>
To: gregkh@linuxfoundation.org, lee.jones@linaro.org
Cc: linux-usb@vger.kernel.org, kernel-janitors@vger.kernel.org
Subject: [PATCH] usb: core: ledtrig-usbport: use octal permission
Date: Sat, 31 Oct 2020 17:19:30 +0000 [thread overview]
Message-ID: <20201031171930.GA21555@fedora-project> (raw)
Change read/write for owner permission from symbolic to octal
to enhance readability. This patch reduces checkpatch warnings
for this file to nil.
see: https://lkml.org/lkml/2016/8/2/1945
verified via chmod(2) man page
Signed-off-by: Nigel Christian <nigel.l.christian@gmail.com>
---
drivers/usb/core/ledtrig-usbport.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/usb/core/ledtrig-usbport.c b/drivers/usb/core/ledtrig-usbport.c
index ba371a24ff78..8e9b1c5cc971 100644
--- a/drivers/usb/core/ledtrig-usbport.c
+++ b/drivers/usb/core/ledtrig-usbport.c
@@ -211,7 +211,7 @@ static int usbport_trig_add_port(struct usbport_trig_data *usbport_data,
sysfs_attr_init(&port->attr.attr);
port->attr.attr.name = port->port_name;
- port->attr.attr.mode = S_IRUSR | S_IWUSR;
+ port->attr.attr.mode = 0600;
port->attr.show = usbport_trig_port_show;
port->attr.store = usbport_trig_port_store;
--
2.28.0
WARNING: multiple messages have this Message-ID (diff)
From: Nigel Christian <nigel.l.christian@gmail.com>
To: gregkh@linuxfoundation.org, lee.jones@linaro.org
Cc: linux-usb@vger.kernel.org, kernel-janitors@vger.kernel.org
Subject: [PATCH] usb: core: ledtrig-usbport: use octal permission
Date: Sat, 31 Oct 2020 13:19:30 -0400 [thread overview]
Message-ID: <20201031171930.GA21555@fedora-project> (raw)
Change read/write for owner permission from symbolic to octal
to enhance readability. This patch reduces checkpatch warnings
for this file to nil.
see: https://lkml.org/lkml/2016/8/2/1945
verified via chmod(2) man page
Signed-off-by: Nigel Christian <nigel.l.christian@gmail.com>
---
drivers/usb/core/ledtrig-usbport.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/usb/core/ledtrig-usbport.c b/drivers/usb/core/ledtrig-usbport.c
index ba371a24ff78..8e9b1c5cc971 100644
--- a/drivers/usb/core/ledtrig-usbport.c
+++ b/drivers/usb/core/ledtrig-usbport.c
@@ -211,7 +211,7 @@ static int usbport_trig_add_port(struct usbport_trig_data *usbport_data,
sysfs_attr_init(&port->attr.attr);
port->attr.attr.name = port->port_name;
- port->attr.attr.mode = S_IRUSR | S_IWUSR;
+ port->attr.attr.mode = 0600;
port->attr.show = usbport_trig_port_show;
port->attr.store = usbport_trig_port_store;
--
2.28.0
next reply other threads:[~2020-10-31 17:19 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-10-31 17:19 Nigel Christian [this message]
2020-10-31 17:19 ` [PATCH] usb: core: ledtrig-usbport: use octal permission Nigel Christian
2020-11-01 6:36 ` Greg KH
2020-11-01 6:36 ` Greg KH
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=20201031171930.GA21555@fedora-project \
--to=nigel.l.christian@gmail.com \
--cc=gregkh@linuxfoundation.org \
--cc=kernel-janitors@vger.kernel.org \
--cc=lee.jones@linaro.org \
--cc=linux-usb@vger.kernel.org \
/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.