From mboxrd@z Thu Jan 1 00:00:00 1970 From: David Ahern Subject: Re: [PATCH net-next v4 2/9] net: ensure unbound stream socket to be chosen when not in a VRF Date: Tue, 6 Nov 2018 10:55:14 -0700 Message-ID: References: <20181102191020.14170-1-mmanning@vyatta.att-mail.com> <20181102191020.14170-3-mmanning@vyatta.att-mail.com> Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit To: Mike Manning , netdev@vger.kernel.org Return-path: Received: from mail-pf1-f195.google.com ([209.85.210.195]:38995 "EHLO mail-pf1-f195.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1730671AbeKGDVi (ORCPT ); Tue, 6 Nov 2018 22:21:38 -0500 Received: by mail-pf1-f195.google.com with SMTP id n11-v6so6453286pfb.6 for ; Tue, 06 Nov 2018 09:55:16 -0800 (PST) In-Reply-To: <20181102191020.14170-3-mmanning@vyatta.att-mail.com> Content-Language: en-US Sender: netdev-owner@vger.kernel.org List-ID: Since you need to re-send once net-next opens ... On 11/2/18 1:10 PM, Mike Manning wrote: > diff --git a/include/net/inet_hashtables.h b/include/net/inet_hashtables.h > index 4ae060b4bac2..5de2d9f24c05 100644 > --- a/include/net/inet_hashtables.h > +++ b/include/net/inet_hashtables.h > @@ -189,6 +189,17 @@ static inline void inet_ehash_locks_free(struct inet_hashinfo *hashinfo) > hashinfo->ehash_locks = NULL; > } > > +static inline bool inet_sk_bound_dev_eq(struct net *net, int bound_dev_if, > + int dif, int sdif) > +{ > +#if IS_ENABLED(CONFIG_NET_L3_MASTER_DEV) > + return inet_bound_dev_eq(net->ipv4.sysctl_tcp_l3mdev_accept, > + bound_dev_if, dif, sdif); Column misalignment on the bound_dev_if. Also, since the arg to inet_bound_dev_eq is a bool, that should be !!net->ipv4.sysctl_tcp_l3mdev_accept > +#else > + return inet_bound_dev_eq(1, bound_dev_if, dif, sdif); > +#endif > +} > + > struct inet_bind_bucket * > inet_bind_bucket_create(struct kmem_cache *cachep, struct net *net, > struct inet_bind_hashbucket *head,