Re: [PATCH] sysctl: Fix conversion of INT_MIN for LP64 systems

2015-07-11 Thread Ilya Dryomov
On Sat, Jul 11, 2015 at 10:35 AM, Robert Xiao wrote: > On LP64 systems, reading a sysctl file containing an INT_MIN (-2147483648) > could incorrectly show -18446744071562067968 due to an incorrect conversion > in do_proc_dointvec_conv. This patch fixes the edge case by converting to > unsigned int

[PATCH] sysctl: Fix conversion of INT_MIN for LP64 systems

2015-07-11 Thread Robert Xiao
On LP64 systems, reading a sysctl file containing an INT_MIN (-2147483648) could incorrectly show -18446744071562067968 due to an incorrect conversion in do_proc_dointvec_conv. This patch fixes the edge case by converting to unsigned int first to avoid sign extending INT_MIN to unsigned long. Test

[PATCH] sysctl: Fix conversion of INT_MIN for LP64 systems

2015-07-11 Thread Robert Xiao
On LP64 systems, reading a sysctl file containing an INT_MIN (-2147483648) could incorrectly show -18446744071562067968 due to an incorrect conversion in do_proc_dointvec_conv. This patch fixes the edge case by converting to unsigned int first to avoid sign extending INT_MIN to unsigned long. Test

[PATCH] sysctl: Fix conversion of INT_MIN for LP64 systems

2015-07-11 Thread Robert Xiao
On LP64 systems, reading a sysctl file containing an INT_MIN (-2147483648) could incorrectly show -18446744071562067968 due to an incorrect conversion in do_proc_dointvec_conv. This patch fixes the edge case by converting to unsigned int first to avoid sign extending INT_MIN to unsigned long. Test