All of lore.kernel.org
 help / color / mirror / Atom feed
From: ebiederm@xmission.com (Eric W. Biederman)
To: Vitaly Kuznetsov <vitty@altlinux.ru>
Cc: Greg Kroah-Hartman <gregkh@suse.de>, <linux-kernel@vger.kernel.org>
Subject: Re: [PATCH] sysfs: change permissions for /sys from 0755 to 0555
Date: Sun, 18 Dec 2011 18:32:18 -0800	[thread overview]
Message-ID: <m162hdmgul.fsf@fess.ebiederm.org> (raw)
In-Reply-To: <1b3c733f0412e214042566bac2c3f3e6@hadoop.ru> (Vitaly Kuznetsov's message of "Wed, 14 Dec 2011 19:34:50 +0400")

Vitaly Kuznetsov <vitty@altlinux.ru> writes:

> There is a misleading difference between /proc and /sys permissions, /proc is
> 0555 and /sys is 0755. But
> as it is impossible to create or unlink something in /sys it would be nice to
> have same permissions.

Where does this difference matter?  This doesn't look like something
that could matter in practice.  If this does matter in practice this
change deserves a comment and a fuller explanation.

The change itself seems reasonable and probably worth making as general
cleanup.

Eric

> Signed-off-by: Vitaly Kuznetsov <vitty@altlinux.ru>
> ---
>  fs/sysfs/mount.c |    2 +-
>  1 files changed, 1 insertions(+), 1 deletions(-)
>
> diff --git a/fs/sysfs/mount.c b/fs/sysfs/mount.c
> index 4974995..9d56fdd 100644
> --- a/fs/sysfs/mount.c
> +++ b/fs/sysfs/mount.c
> @@ -36,7 +36,7 @@ struct sysfs_dirent sysfs_root = {
>         .s_name         = "",
>         .s_count        = ATOMIC_INIT(1),
>         .s_flags        = SYSFS_DIR,
> -       .s_mode         = S_IFDIR | S_IRWXU | S_IRUGO | S_IXUGO,
> +       .s_mode         = S_IFDIR | S_IRUGO | S_IXUGO,
>         .s_ino          = 1,
>  };

  reply	other threads:[~2011-12-19  2:30 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-12-14 15:34 [PATCH] sysfs: change permissions for /sys from 0755 to 0555 Vitaly Kuznetsov
2011-12-19  2:32 ` Eric W. Biederman [this message]
2011-12-20 12:34   ` Vitaly Kuznetsov
2012-01-05  0:17 ` Greg KH
2012-01-17 12:17   ` Vitaly Kuznetsov

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=m162hdmgul.fsf@fess.ebiederm.org \
    --to=ebiederm@xmission.com \
    --cc=gregkh@suse.de \
    --cc=linux-kernel@vger.kernel.org \
    --cc=vitty@altlinux.ru \
    /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.