This is the mail archive of the libc-ports@sources.redhat.com mailing list for the libc-ports project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [PATCH] arm: ioperm use /proc/sys not sysctl


On Sun, 2009-11-08 at 21:58 -0800, Eric W. Biederman wrote:
> sysctl is essentially unmaintained bloat in the linux kernel
> and is scheduled for removal in a year or so, meanwhile the
> /proc/sys interface will remain and has always existed.
> 
> So use /proc/sys instead of sysctl in the implementation
> of ioperm so it continues to work even when sysctl is not
> present in the kernel.

Thanks for the patch.  

I think I would prefer to see the sysctl support retained, at least for
the time being.  Reading files from /proc obviously relies on that
filesystem being mounted which is not necessarily the case at all times.
The sysctl interface is also faster, when it works, than reading
from /proc.

Aside from that, some specific comments about your patch:

 - please format your code according to the GNU standards;
 - please supply an appropriate changelog entry
 - it seems unnecessary to memset() the whole of "buf" to zero.  I think
just doing "buf[ret] = 0;" after the read() call would suffice.

Do you have a copyright assignment on file for glibc?  This change is
maybe small enough to accept without but it is borderline and an
assignment would be better.

p.



Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]