RE: [PATCH net-next v2] net: core: change bool members of struct net_device to bitfield members

2018-10-10 Thread David Laight
From: Eric Dumazet > Sent: 09 October 2018 21:52 > > On 10/09/2018 01:24 PM, Heiner Kallweit wrote: > > > Reordering the struct members to fill the holes could be a little tricky > > and could have side effects because it may make a performance difference > > whether certain members are in one

Re: [PATCH net-next v2] net: core: change bool members of struct net_device to bitfield members

2018-10-09 Thread Eric Dumazet
On 10/09/2018 01:24 PM, Heiner Kallweit wrote: > Reordering the struct members to fill the holes could be a little tricky > and could have side effects because it may make a performance difference > whether certain members are in one cacheline or not. > And whether it's worth to spend this

Re: [PATCH net-next v2] net: core: change bool members of struct net_device to bitfield members

2018-10-09 Thread David Ahern
On 10/9/18 2:24 PM, Heiner Kallweit wrote: > Reordering the struct members to fill the holes could be a little tricky > and could have side effects because it may make a performance difference > whether certain members are in one cacheline or not. > And whether it's worth to spend this effort

Re: [PATCH net-next v2] net: core: change bool members of struct net_device to bitfield members

2018-10-09 Thread Heiner Kallweit
On 09.10.2018 17:20, David Ahern wrote: > On 10/8/18 2:17 PM, Heiner Kallweit wrote: >> bool is good as parameter type or function return type, but if used >> for struct members it consumes more memory than needed. >> Changing the bool members of struct net_device to bitfield members >> allows to

Re: [PATCH net-next v2] net: core: change bool members of struct net_device to bitfield members

2018-10-09 Thread David Ahern
On 10/8/18 2:17 PM, Heiner Kallweit wrote: > bool is good as parameter type or function return type, but if used > for struct members it consumes more memory than needed. > Changing the bool members of struct net_device to bitfield members > allows to decrease the memory footprint of this struct.

[PATCH net-next v2] net: core: change bool members of struct net_device to bitfield members

2018-10-08 Thread Heiner Kallweit
bool is good as parameter type or function return type, but if used for struct members it consumes more memory than needed. Changing the bool members of struct net_device to bitfield members allows to decrease the memory footprint of this struct. Signed-off-by: Heiner Kallweit --- v2: - Change