i40evf: Use le32_to_cpu before evaluating HW desc fields
authorTushar Dave <tushar.n.dave@oracle.com>
Thu, 22 Jun 2017 16:44:32 +0000 (09:44 -0700)
committerJeff Kirsher <jeffrey.t.kirsher@intel.com>
Wed, 26 Jul 2017 10:25:21 +0000 (03:25 -0700)
commitc969ef4ed9cbf3662fc8709e2581427c191504fb
tree5ef1b5a98bfbdcdd6557e5b12f42507eafbfef21
parenteb23039f6c22a6b240aef7d7ebccceeb52a8452a
i40evf: Use le32_to_cpu before evaluating HW desc fields

i40e hardware descriptor fields are in little-endian format. Driver
must use le32_to_cpu while evaluating these fields otherwise on
big-endian arch we end up evaluating incorrect values, cause errors
like:
i40evf 0000:03:0a.0: Expected response 24 from PF, received 402653184
i40evf 0000:03:0a.1: Expected response 7 from PF, received 117440512

Signed-off-by: Tushar Dave <tushar.n.dave@oracle.com>
Reviewed-by: Shannon Nelson <shannon.nelson@oracle.com>
Tested-by: Andrew Bowers <andrewx.bowers@intel.com>
Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
drivers/net/ethernet/intel/i40evf/i40evf_main.c