tcp: Make tcp_fastopen_alloc_ctx static
authorYueHaibing <yuehaibing@huawei.com>
Mon, 10 Jun 2019 15:19:08 +0000 (23:19 +0800)
committerDavid S. Miller <davem@davemloft.net>
Mon, 10 Jun 2019 17:38:50 +0000 (10:38 -0700)
Fix sparse warning:

net/ipv4/tcp_fastopen.c:75:29: warning:
 symbol 'tcp_fastopen_alloc_ctx' was not declared. Should it be static?

Reported-by: Hulk Robot <hulkci@huawei.com>
Signed-off-by: YueHaibing <yuehaibing@huawei.com>
Acked-by: Jason Baron <jbaron@akamai.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
net/ipv4/tcp_fastopen.c

index 8e1580485c9e6187c15a3ab1fcc14c85c6d140aa..7d19fa4c8121e511daae44d8dc1857ad433e8be4 100644 (file)
@@ -72,9 +72,9 @@ void tcp_fastopen_ctx_destroy(struct net *net)
                call_rcu(&ctxt->rcu, tcp_fastopen_ctx_free);
 }
 
-struct tcp_fastopen_context *tcp_fastopen_alloc_ctx(void *primary_key,
-                                                   void *backup_key,
-                                                   unsigned int len)
+static struct tcp_fastopen_context *tcp_fastopen_alloc_ctx(void *primary_key,
+                                                          void *backup_key,
+                                                          unsigned int len)
 {
        struct tcp_fastopen_context *new_ctx;
        void *key = primary_key;