kernel-janitors.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] usb: core: ledtrig-usbport: use octal permission
@ 2020-10-31 17:19 Nigel Christian
  2020-11-01  6:36 ` Greg KH
  0 siblings, 1 reply; 2+ messages in thread
From: Nigel Christian @ 2020-10-31 17:19 UTC (permalink / raw)
  To: gregkh, lee.jones; +Cc: linux-usb, kernel-janitors

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

^ permalink raw reply related	[flat|nested] 2+ messages in thread

* Re: [PATCH] usb: core: ledtrig-usbport: use octal permission
  2020-10-31 17:19 [PATCH] usb: core: ledtrig-usbport: use octal permission Nigel Christian
@ 2020-11-01  6:36 ` Greg KH
  0 siblings, 0 replies; 2+ messages in thread
From: Greg KH @ 2020-11-01  6:36 UTC (permalink / raw)
  To: Nigel Christian; +Cc: lee.jones, linux-usb, kernel-janitors

On Sat, Oct 31, 2020 at 01:19:30PM -0400, Nigel Christian wrote:
> 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

Please use lore.kernel.org links for mailing list stuff.

thanks,

greg k-h

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2020-11-01  6:36 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-10-31 17:19 [PATCH] usb: core: ledtrig-usbport: use octal permission Nigel Christian
2020-11-01  6:36 ` Greg KH

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).