On Fri, Jan 26, 2018 at 01:24:50PM -0800, Jeff Kirsher wrote: > From: Alice Michael <alice.michael@xxxxxxxxx> > > As we have added more flags, we need to now use more > bits and have over flooded the 32 bit size. So > make it 64. > > Also change all the existing bits to unsigned long long > bits. > > Signed-off-by: Alice Michael <alice.michael@xxxxxxxxx> > Tested-by: Andrew Bowers <andrewx.bowers@xxxxxxxxx> > Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@xxxxxxxxx> > --- > drivers/net/ethernet/intel/i40e/i40e.h | 67 +++++++++++++------------- > drivers/net/ethernet/intel/i40e/i40e_ethtool.c | 4 +- > 2 files changed, 36 insertions(+), 35 deletions(-) ... > @@ -4323,7 +4323,7 @@ static int i40e_set_priv_flags(struct net_device *dev, u32 flags) > * originally. We'll just punt with an error and log something in the > * message buffer. > */ > - if (cmpxchg(&pf->flags, orig_flags, new_flags) != orig_flags) { > + if (cmpxchg64(&pf->flags, orig_flags, new_flags) != orig_flags) { This breaks allyesconfig builds on certain architectures, for example MIPS 32-bit with SMP enabled, which doesn't support cmpxchg64: CC drivers/net/ethernet/intel/i40e/i40e_ethtool.o drivers/net/ethernet/intel/i40e/i40e_ethtool.c: In function ‘i40e_set_priv_flags’: drivers/net/ethernet/intel/i40e/i40e_ethtool.c:4326:6: error: implicit declaration of function ‘cmpxchg64’; did you mean ‘__cmpxchg’? [-Werror=implicit-function-declaration] if (cmpxchg64(&pf->flags, orig_flags, new_flags) != orig_flags) { ^~~~~~~~~ __cmpxchg Should the driver now depend on 64BIT or something? Cheers James
Attachment:
signature.asc
Description: Digital signature