Messages in this thread | | | From | "Wang, Yalin" <> | Date | Thu, 22 Jan 2015 10:07:49 +0800 | Subject | RE: [RFC] export module parameters even the permission is zero |
| |
> -----Original Message----- > From: Rusty Russell [mailto:rusty@rustcorp.com.au] > Sent: Tuesday, January 20, 2015 2:33 PM > To: Wang, Yalin; 'akpm@linux-foundation.org'; 'jani.nikula@intel.com'; > 'hch@infradead.org'; 'hare@suse.de'; 'keescook@chromium.org'; 'linux- > kernel@vger.kernel.org' > Subject: Re: [RFC] export module parameters even the permission is zero > > "Wang, Yalin" <Yalin.Wang@sonymobile.com> writes: > > This patch make sure to export module parameters even the permission > > is zero, this is useful for some platforms like Android, the init > > process can change the parameter mode/owner by chmod/chown during > > bootup > > > > Signed-off-by: Yalin Wang <yalin.wang@sonymobile.com> > > Hi! > > Unfortunately, this won't work. Various parts of the code assume > that 0 permissions means "cannot be changed or read", so this change would > introduce many bugs (eg. the parameter could be __initdata). > > Since these are owned by root at boot, changing mode and owner should still > work. However, you can't make a read-only field writable and expect it to > work. > Oh, I see, This means kernel cmdline can change this module_parameter ignored permission,
Thanks for your comments.
| |