On 8/14/2024 12:54 PM, Sergey Temerkhanov wrote:

...

+static inline bool ice_is_primary(struct ice_hw *hw)

No 'inline' functions in c files please.

+{
+       return ice_is_e825c(hw) && ice_is_dual(hw) ?
+               !!(hw->dev_caps.nac_topo.mode & ICE_NAC_TOPO_PRIMARY_M) : true;
+}
+

...

diff --git a/drivers/net/ethernet/intel/ice/ice_ptp_hw.h 
b/drivers/net/ethernet/intel/ice/ice_ptp_hw.h
index fc946fcd28b9..f67981d64bb8 100644
--- a/drivers/net/ethernet/intel/ice/ice_ptp_hw.h
+++ b/drivers/net/ethernet/intel/ice/ice_ptp_hw.h
@@ -468,6 +468,11 @@ static inline u64 ice_get_base_incval(struct ice_hw *hw)
        }
  }
+static inline bool ice_is_dual(struct ice_hw *hw)
+{
+        return !!(hw->dev_caps.nac_topo.mode & ICE_NAC_TOPO_DUAL_M);
+}

From checkpatch:

ERROR: code indent should use tabs where possible
#408: FILE: drivers/net/ethernet/intel/ice/ice_ptp_hw.h:473:
+        return !!(hw->dev_caps.nac_topo.mode & ICE_NAC_TOPO_DUAL_M);$

WARNING: please, no spaces at the start of a line
#408: FILE: drivers/net/ethernet/intel/ice/ice_ptp_hw.h:473:
+        return !!(hw->dev_caps.nac_topo.mode & ICE_NAC_TOPO_DUAL_M);$


  #define PFTSYN_SEM_BYTES      4
#define ICE_PTP_CLOCK_INDEX_0 0x00

Reply via email to