[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <2d5a9ca4-5e76-86a9-7db9-b4bbec764706@linux.dev>
Date: Tue, 25 Jul 2023 14:19:54 -0700
From: Martin KaFai Lau <martin.lau@...ux.dev>
To: Lorenz Bauer <lmb@...valent.com>
Cc: Hemanth Malla <hemanthmalla@...il.com>, netdev@...r.kernel.org,
linux-kernel@...r.kernel.org, bpf@...r.kernel.org,
linux-kselftest@...r.kernel.org, "David S. Miller" <davem@...emloft.net>,
Eric Dumazet <edumazet@...gle.com>, Jakub Kicinski <kuba@...nel.org>,
Paolo Abeni <pabeni@...hat.com>, David Ahern <dsahern@...nel.org>,
Willem de Bruijn <willemdebruijn.kernel@...il.com>,
Alexei Starovoitov <ast@...nel.org>, Daniel Borkmann <daniel@...earbox.net>,
Andrii Nakryiko <andrii@...nel.org>, Song Liu <song@...nel.org>,
Yonghong Song <yhs@...com>, John Fastabend <john.fastabend@...il.com>,
KP Singh <kpsingh@...nel.org>, Stanislav Fomichev <sdf@...gle.com>,
Hao Luo <haoluo@...gle.com>, Jiri Olsa <jolsa@...nel.org>,
Joe Stringer <joe@...d.net.nz>, Mykola Lysenko <mykolal@...com>,
Shuah Khan <shuah@...nel.org>, Kuniyuki Iwashima <kuniyu@...zon.com>
Subject: Re: [PATCH bpf-next v6 4/8] net: remove duplicate reuseport_lookup
functions
On 7/24/23 5:53 PM, Martin KaFai Lau wrote:
> On 7/20/23 8:30 AM, Lorenz Bauer wrote:
>> diff --git a/include/net/inet6_hashtables.h b/include/net/inet6_hashtables.h
>> index 032ddab48f8f..f89320b6fee3 100644
>> --- a/include/net/inet6_hashtables.h
>> +++ b/include/net/inet6_hashtables.h
>> @@ -48,12 +48,21 @@ struct sock *__inet6_lookup_established(struct net *net,
>> const u16 hnum, const int dif,
>> const int sdif);
>> +typedef u32 (inet6_ehashfn_t)(const struct net *net,
>> + const struct in6_addr *laddr, const u16 lport,
>> + const struct in6_addr *faddr, const __be16 fport);
>> +
>> +inet6_ehashfn_t inet6_ehashfn;
>> +
>> +INDIRECT_CALLABLE_DECLARE(inet6_ehashfn_t udp6_ehashfn);
>> +
>
> [ ... ]
>
>> diff --git a/net/ipv6/inet6_hashtables.c b/net/ipv6/inet6_hashtables.c
>> index b7c56867314e..3616225c89ef 100644
>> --- a/net/ipv6/inet6_hashtables.c
>> +++ b/net/ipv6/inet6_hashtables.c
>> @@ -39,6 +39,7 @@ u32 inet6_ehashfn(const struct net *net,
>> return __inet6_ehashfn(lhash, lport, fhash, fport,
>> inet6_ehash_secret + net_hash_mix(net));
>> }
>> +EXPORT_SYMBOL_GPL(inet6_ehashfn);
>> /*
>> * Sockets in TCP_CLOSE state are _always_ taken out of the hash, so
>> @@ -111,18 +112,22 @@ static inline int compute_score(struct sock *sk, struct
>> net *net,
>> return score;
>> }
>> +INDIRECT_CALLABLE_DECLARE(inet6_ehashfn_t udp6_ehashfn);
>
> The same INDIRECT_CALLABLE_DECLARE is also added to inet6_hashtables.h. Is this
> one still needed here?
>
> The same goes for the inet_hashtables.c.
Please follow up if one of the INDIRECT_CALLABLE_DECLARE makes sense to remove.
I have applied the set after fixing up patch 7 and 8.
Powered by blists - more mailing lists