summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--include/net/ll_poll.h5
-rw-r--r--net/core/sysctl_net_core.c4
-rw-r--r--net/socket.c2
3 files changed, 6 insertions, 5 deletions
diff --git a/include/net/ll_poll.h b/include/net/ll_poll.h
index bc262f8..44e2f70 100644
--- a/include/net/ll_poll.h
+++ b/include/net/ll_poll.h
@@ -34,7 +34,7 @@
#ifdef CONFIG_NET_LL_RX_POLL
struct napi_struct;
-extern unsigned long sysctl_net_ll_poll __read_mostly;
+extern unsigned int sysctl_net_ll_poll __read_mostly;
/* return values from ndo_ll_poll */
#define LL_FLUSH_FAILED -1
@@ -45,7 +45,8 @@ extern unsigned long sysctl_net_ll_poll __read_mostly;
static inline cycles_t ll_end_time(void)
{
- return TSC_MHZ * ACCESS_ONCE(sysctl_net_ll_poll) + get_cycles();
+ return (cycles_t)TSC_MHZ * ACCESS_ONCE(sysctl_net_ll_poll)
+ + get_cycles();
}
static inline bool sk_valid_ll(struct sock *sk)
diff --git a/net/core/sysctl_net_core.c b/net/core/sysctl_net_core.c
index 78c746e..62702c2 100644
--- a/net/core/sysctl_net_core.c
+++ b/net/core/sysctl_net_core.c
@@ -302,9 +302,9 @@ static struct ctl_table net_core_table[] = {
{
.procname = "low_latency_poll",
.data = &sysctl_net_ll_poll,
- .maxlen = sizeof(unsigned long),
+ .maxlen = sizeof(unsigned int),
.mode = 0644,
- .proc_handler = proc_doulongvec_minmax
+ .proc_handler = proc_dointvec
},
#endif
#endif /* CONFIG_NET */
diff --git a/net/socket.c b/net/socket.c
index 21fd29f..caaffa1 100644
--- a/net/socket.c
+++ b/net/socket.c
@@ -107,7 +107,7 @@
#include <net/ll_poll.h>
#ifdef CONFIG_NET_LL_RX_POLL
-unsigned long sysctl_net_ll_poll __read_mostly;
+unsigned int sysctl_net_ll_poll __read_mostly;
EXPORT_SYMBOL_GPL(sysctl_net_ll_poll);
#endif
OpenPOWER on IntegriCloud