Revert "kernel/sysctl.c: detect overflows when converting to int"
We have scripts which write to certain fields on 3.18 kernels but this seems to be failing on 4.4 kernels. An entry which we write to here is xfrm_aevent_rseqth which is u32. echo 4294967295 > /proc/sys/net/core/xfrm_aevent_rseqth Commit 230633d1 ("kernel/sysctl.c: detect overflows when converting to int") prevented writing to sysctl entries when integer overflow occurs. However, this does not apply to unsigned integers. u32 should be able to hold 4294967295 here, however it fails due to this check. static int do_proc_dointvec_conv(bool *negp, unsigned long *lvalp, if (*lvalp > (unsigned long) INT_MAX) return -EINVAL; Fix this for now by reverting this commit till a solution is finalized upstream. CRs-Fixed: 10265075 Change-Id: I4fae5f442e4cc2c2414a69e960d42c05c3062415 Signed-off-by:Subash Abhinov Kasiviswanathan <subashab@codeaurora.org>
Loading
Please register or sign in to comment