sysctl: don't print negative flag for proc_douintvec

I saw some very confusing sysctl output on my system:
  # cat /proc/sys/net/core/xfrm_aevent_rseqth
  # cat /proc/sys/net/core/xfrm_aevent_etime
  # cat /proc/sys/net/ipv4/tcp_notsent_lowat

Because we forget to set the *negp flag in proc_douintvec, so it will
become a garbage value.

Since the value related to proc_douintvec is always an unsigned integer,
so we can set *negp to false explictily to fix this issue.

Fixes: e7d316a02f68 ("sysctl: handle error writing UINT_MAX to u32 fields")
Signed-off-by: Liping Zhang <>
Cc: Subash Abhinov Kasiviswanathan <>
Cc: Andrew Morton <>
Signed-off-by: Linus Torvalds <>
1 file changed