[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <20180926150102.GA1251@lunn.ch>
Date: Wed, 26 Sep 2018 17:01:02 +0200
From: Andrew Lunn <andrew@...n.ch>
To: Nikolay Aleksandrov <nikolay@...ulusnetworks.com>
Cc: netdev@...r.kernel.org, roopa@...ulusnetworks.com,
davem@...emloft.net, stephen@...workplumber.org,
bridge@...ts.linux-foundation.org
Subject: Re: [PATCH net-next 2/9] net: bridge: add bitfield for options and
convert vlan opts
On Wed, Sep 26, 2018 at 05:55:47PM +0300, Nikolay Aleksandrov wrote:
> On 26/09/18 17:48, Andrew Lunn wrote:
> > Hi Nikolay
> >
> >> struct net_bridge {
> >> spinlock_t lock;
> >> spinlock_t hash_lock;
> >> struct list_head port_list;
> >> struct net_device *dev;
> >> struct pcpu_sw_netstats __percpu *stats;
> >> + unsigned long options;
> >
> > Maybe a u32 would be better, so we run out of bits at the same time on
> > 32 and 64 bit systems?
> >
> > Andrew
> >
>
> Bitops operate on an unsigned long, I actually had a BUILD_BUG_ON() for
> 32 bits initially, but checked other places and they seem to be using it
> as-is without any checks so I decided to leave it as well (e.g.
> sock_flags).
O.K.
I assume we get compiler warnings anyway, when we use bit 32 on a
32bit system. The build-bots should let us know.
Andrew
Powered by blists - more mailing lists