Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 1b1cb1f7 authored by Eric Dumazet's avatar Eric Dumazet Committed by David S. Miller
Browse files

net: ping: small changes



ping_table is not __read_mostly, since it contains one rwlock,
and is static to ping.c

ping_port_rover & ping_v4_lookup are static

Signed-off-by: default avatarEric Dumazet <eric.dumazet@gmail.com>
Acked-by: default avatarVasiliy Kulikov <segoon@openwall.com>
Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
parent 89c64d75
Loading
Loading
Loading
Loading
+4 −4
Original line number Diff line number Diff line
@@ -49,9 +49,9 @@
#include <net/checksum.h>


struct ping_table ping_table __read_mostly;
static struct ping_table ping_table;

u16 ping_port_rover;
static u16 ping_port_rover;

static inline int ping_hashfn(struct net *net, unsigned num, unsigned mask)
{
@@ -150,7 +150,7 @@ static void ping_v4_unhash(struct sock *sk)
	}
}

struct sock *ping_v4_lookup(struct net *net, u32 saddr, u32 daddr,
static struct sock *ping_v4_lookup(struct net *net, u32 saddr, u32 daddr,
				   u16 ident, int dif)
{
	struct hlist_nulls_head *hslot = ping_hashslot(&ping_table, net, ident);