aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/net/ethernet/intel/i40e/i40e.h
diff options
context:
space:
mode:
authorIvan Vecera <[email protected]>2023-11-13 23:10:27 +0000
committerJakub Kicinski <[email protected]>2023-11-15 04:05:44 +0000
commit0e8b9fdd40fe65b28d58ea7fa3f97aed350da69a (patch)
tree29aadb0e5fd73b50918489bdb5ef28a6462cb487 /drivers/net/ethernet/intel/i40e/i40e.h
parenti40e: Use DECLARE_BITMAP for flags field in i40e_hw (diff)
downloadkernel-0e8b9fdd40fe65b28d58ea7fa3f97aed350da69a.tar.gz
kernel-0e8b9fdd40fe65b28d58ea7fa3f97aed350da69a.zip
i40e: Consolidate hardware capabilities
Fields .caps in i40e_hw and .hw_features in i40e_pf both indicate capabilities provided by hardware. Move and merge i40e_pf.hw_features into i40e_hw.caps as this is more appropriate place for them and adjust their names to I40E_HW_CAP_... convention. Signed-off-by: Ivan Vecera <[email protected]> Reviewed-by: Jacob Keller <[email protected]> Tested-by: Pucha Himasekhar Reddy <[email protected]> (A Contingent worker at Intel) Signed-off-by: Tony Nguyen <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Jakub Kicinski <[email protected]>
Diffstat (limited to 'drivers/net/ethernet/intel/i40e/i40e.h')
-rw-r--r--drivers/net/ethernet/intel/i40e/i40e.h27
1 files changed, 2 insertions, 25 deletions
diff --git a/drivers/net/ethernet/intel/i40e/i40e.h b/drivers/net/ethernet/intel/i40e/i40e.h
index ba87870e0fb4..6022944d04f8 100644
--- a/drivers/net/ethernet/intel/i40e/i40e.h
+++ b/drivers/net/ethernet/intel/i40e/i40e.h
@@ -34,11 +34,11 @@
#define I40E_MIN_VSI_ALLOC 83 /* LAN, ATR, FCOE, 64 VF */
/* max 16 qps */
#define i40e_default_queues_per_vmdq(pf) \
- (test_bit(I40E_HW_RSS_AQ_CAPABLE, (pf)->hw_features) ? 4 : 1)
+ (test_bit(I40E_HW_CAP_RSS_AQ, (pf)->hw.caps) ? 4 : 1)
#define I40E_DEFAULT_QUEUES_PER_VF 4
#define I40E_MAX_VF_QUEUES 16
#define i40e_pf_get_max_q_per_tc(pf) \
- (test_bit(I40E_HW_128_QP_RSS_CAPABLE, (pf)->hw_features) ? 128 : 64)
+ (test_bit(I40E_HW_CAP_128_QP_RSS, (pf)->hw.caps) ? 128 : 64)
#define I40E_FDIR_RING_COUNT 32
#define I40E_MAX_AQ_BUF_SIZE 4096
#define I40E_AQ_LEN 256
@@ -139,28 +139,6 @@ enum i40e_vsi_state {
__I40E_VSI_STATE_SIZE__,
};
-enum i40e_pf_hw_features {
- I40E_HW_RSS_AQ_CAPABLE,
- I40E_HW_128_QP_RSS_CAPABLE,
- I40E_HW_ATR_EVICT_CAPABLE,
- I40E_HW_WB_ON_ITR_CAPABLE,
- I40E_HW_MULTIPLE_TCP_UDP_RSS_PCTYPE,
- I40E_HW_NO_PCI_LINK_CHECK,
- I40E_HW_100M_SGMII_CAPABLE,
- I40E_HW_NO_DCB_SUPPORT,
- I40E_HW_USE_SET_LLDP_MIB,
- I40E_HW_GENEVE_OFFLOAD_CAPABLE,
- I40E_HW_PTP_L4_CAPABLE,
- I40E_HW_WOL_MC_MAGIC_PKT_WAKE,
- I40E_HW_HAVE_CRT_RETIMER,
- I40E_HW_OUTER_UDP_CSUM_CAPABLE,
- I40E_HW_PHY_CONTROLS_LEDS,
- I40E_HW_STOP_FW_LLDP,
- I40E_HW_PORT_ID_VALID,
- I40E_HW_RESTART_AUTONEG,
- I40E_PF_HW_FEATURES_NBITS, /* must be last */
-};
-
enum i40e_pf_flags {
I40E_FLAG_MSI_ENA,
I40E_FLAG_MSIX_ENA,
@@ -557,7 +535,6 @@ struct i40e_pf {
struct timer_list service_timer;
struct work_struct service_task;
- DECLARE_BITMAP(hw_features, I40E_PF_HW_FEATURES_NBITS);
DECLARE_BITMAP(flags, I40E_PF_FLAGS_NBITS);
struct i40e_client_instance *cinst;
bool stat_offsets_loaded;