summaryrefslogtreecommitdiff
path: root/drivers/net/ethernet/intel/ice/ice_devlink.h
diff options
context:
space:
mode:
authorKarol Kolacinski <karol.kolacinski@intel.com>2023-07-26 00:50:47 +0300
committerTony Nguyen <anthony.l.nguyen@intel.com>2023-09-18 20:39:09 +0300
commit097c317afe0a582cfbf04506f368ee3a3ad0ae74 (patch)
tree757615038f89e76f16a86113b99a55442dd14aad /drivers/net/ethernet/intel/ice/ice_devlink.h
parent40326b2b4296052039ef1f71330f920063ca1096 (diff)
downloadlinux-097c317afe0a582cfbf04506f368ee3a3ad0ae74.tar.xz
ice: retry acquiring hardware semaphore during cross-timestamp request
The hardware for performing a cross-timestamp on E822 uses a hardware semaphore which we must acquire before initiating the cross-timestamp operation. The current implementation only attempts to acquire the semaphore once, and assumes that it will succeed. If the semaphore is busy for any reason, the cross-timestamp operation fails with -EFAULT. Instead of immediately failing, try the acquire the lock a few times with a small sleep between attempts. This ensures that most requests will go through without issue. Additionally, return -EBUSY instead of -EFAULT if the operation can't continue due to the semaphore being busy. Signed-off-by: Karol Kolacinski <karol.kolacinski@intel.com> Signed-off-by: Jacob Keller <jacob.e.keller@intel.com> Tested-by: Pucha Himasekhar Reddy <himasekharx.reddy.pucha@intel.com> (A Contingent worker at Intel) Signed-off-by: Tony Nguyen <anthony.l.nguyen@intel.com>
Diffstat (limited to 'drivers/net/ethernet/intel/ice/ice_devlink.h')
0 files changed, 0 insertions, 0 deletions