aboutsummaryrefslogtreecommitdiffstats
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 bc262f88173f..44e2f707cb9f 100644
--- a/include/net/ll_poll.h
+++ b/include/net/ll_poll.h
@@ -34,7 +34,7 @@
34#ifdef CONFIG_NET_LL_RX_POLL 34#ifdef CONFIG_NET_LL_RX_POLL
35 35
36struct napi_struct; 36struct napi_struct;
37extern unsigned long sysctl_net_ll_poll __read_mostly; 37extern unsigned int sysctl_net_ll_poll __read_mostly;
38 38
39/* return values from ndo_ll_poll */ 39/* return values from ndo_ll_poll */
40#define LL_FLUSH_FAILED -1 40#define LL_FLUSH_FAILED -1
@@ -45,7 +45,8 @@ extern unsigned long sysctl_net_ll_poll __read_mostly;
45 45
46static inline cycles_t ll_end_time(void) 46static inline cycles_t ll_end_time(void)
47{ 47{
48 return TSC_MHZ * ACCESS_ONCE(sysctl_net_ll_poll) + get_cycles(); 48 return (cycles_t)TSC_MHZ * ACCESS_ONCE(sysctl_net_ll_poll)
49 + get_cycles();
49} 50}
50 51
51static inline bool sk_valid_ll(struct sock *sk) 52static 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 78c746e016ae..62702c2053de 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[] = {
302 { 302 {
303 .procname = "low_latency_poll", 303 .procname = "low_latency_poll",
304 .data = &sysctl_net_ll_poll, 304 .data = &sysctl_net_ll_poll,
305 .maxlen = sizeof(unsigned long), 305 .maxlen = sizeof(unsigned int),
306 .mode = 0644, 306 .mode = 0644,
307 .proc_handler = proc_doulongvec_minmax 307 .proc_handler = proc_dointvec
308 }, 308 },
309#endif 309#endif
310#endif /* CONFIG_NET */ 310#endif /* CONFIG_NET */
diff --git a/net/socket.c b/net/socket.c
index 21fd29f63ed2..caaffa14e87e 100644
--- a/net/socket.c
+++ b/net/socket.c
@@ -107,7 +107,7 @@
107#include <net/ll_poll.h> 107#include <net/ll_poll.h>
108 108
109#ifdef CONFIG_NET_LL_RX_POLL 109#ifdef CONFIG_NET_LL_RX_POLL
110unsigned long sysctl_net_ll_poll __read_mostly; 110unsigned int sysctl_net_ll_poll __read_mostly;
111EXPORT_SYMBOL_GPL(sysctl_net_ll_poll); 111EXPORT_SYMBOL_GPL(sysctl_net_ll_poll);
112#endif 112#endif
113 113