diff options
author | Eric Dumazet <edumazet@google.com> | 2019-06-15 16:19:55 -0400 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2019-06-16 17:15:07 -0400 |
commit | 2e05fcae83c41eb2df10558338dc600dc783af47 (patch) | |
tree | 1bedfe78c671b634aed0faa9dbb2ec5cda7a4261 | |
parent | d424a2afd7da136a98e9485bfd6c5d5506bd77f8 (diff) |
tcp: fix compile error if !CONFIG_SYSCTL
tcp_tx_skb_cache_key and tcp_rx_skb_cache_key must be available
even if CONFIG_SYSCTL is not set.
Fixes: 0b7d7f6b2208 ("tcp: add tcp_tx_skb_cache sysctl")
Fixes: ede61ca474a0 ("tcp: add tcp_rx_skb_cache sysctl")
Signed-off-by: Eric Dumazet <edumazet@google.com>
Reported-by: Willem de Bruijn <willemb@google.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
-rw-r--r-- | net/ipv4/sysctl_net_ipv4.c | 5 | ||||
-rw-r--r-- | net/ipv4/tcp.c | 5 |
2 files changed, 5 insertions, 5 deletions
diff --git a/net/ipv4/sysctl_net_ipv4.c b/net/ipv4/sysctl_net_ipv4.c index 08a428a7b274..fa213bd8e233 100644 --- a/net/ipv4/sysctl_net_ipv4.c +++ b/net/ipv4/sysctl_net_ipv4.c | |||
@@ -51,11 +51,6 @@ static int comp_sack_nr_max = 255; | |||
51 | static u32 u32_max_div_HZ = UINT_MAX / HZ; | 51 | static u32 u32_max_div_HZ = UINT_MAX / HZ; |
52 | static int one_day_secs = 24 * 3600; | 52 | static int one_day_secs = 24 * 3600; |
53 | 53 | ||
54 | DEFINE_STATIC_KEY_FALSE(tcp_rx_skb_cache_key); | ||
55 | EXPORT_SYMBOL(tcp_rx_skb_cache_key); | ||
56 | |||
57 | DEFINE_STATIC_KEY_FALSE(tcp_tx_skb_cache_key); | ||
58 | |||
59 | /* obsolete */ | 54 | /* obsolete */ |
60 | static int sysctl_tcp_low_latency __read_mostly; | 55 | static int sysctl_tcp_low_latency __read_mostly; |
61 | 56 | ||
diff --git a/net/ipv4/tcp.c b/net/ipv4/tcp.c index f12d500ec85c..f448a288d158 100644 --- a/net/ipv4/tcp.c +++ b/net/ipv4/tcp.c | |||
@@ -317,6 +317,11 @@ struct tcp_splice_state { | |||
317 | unsigned long tcp_memory_pressure __read_mostly; | 317 | unsigned long tcp_memory_pressure __read_mostly; |
318 | EXPORT_SYMBOL_GPL(tcp_memory_pressure); | 318 | EXPORT_SYMBOL_GPL(tcp_memory_pressure); |
319 | 319 | ||
320 | DEFINE_STATIC_KEY_FALSE(tcp_rx_skb_cache_key); | ||
321 | EXPORT_SYMBOL(tcp_rx_skb_cache_key); | ||
322 | |||
323 | DEFINE_STATIC_KEY_FALSE(tcp_tx_skb_cache_key); | ||
324 | |||
320 | void tcp_enter_memory_pressure(struct sock *sk) | 325 | void tcp_enter_memory_pressure(struct sock *sk) |
321 | { | 326 | { |
322 | unsigned long val; | 327 | unsigned long val; |