From: Qi Zhang Date: Thu, 16 Sep 2021 09:52:54 +0000 (+0800) Subject: net/ice/base: include more E810T adapters X-Git-Url: http://git.droids-corp.org/?a=commitdiff_plain;h=8d90c55c459b156dc60ff4049b3a293fcc4a36ba;p=dpdk.git net/ice/base: include more E810T adapters Expand the ice_is_e810t to include: - Intel(R) Ethernet Network Adapter E810-C-Q2T - Intel(R) Ethernet 25G 4P E810-XXV-st Signed-off-by: Maciej Machnikowski Signed-off-by: Qi Zhang Acked-by: Junfeng Guo --- diff --git a/drivers/net/ice/base/ice_common.c b/drivers/net/ice/base/ice_common.c index 6004c95625..a7804219d8 100644 --- a/drivers/net/ice/base/ice_common.c +++ b/drivers/net/ice/base/ice_common.c @@ -208,8 +208,21 @@ bool ice_is_e810(struct ice_hw *hw) */ bool ice_is_e810t(struct ice_hw *hw) { - return (hw->device_id == ICE_DEV_ID_E810C_SFP && - hw->subsystem_device_id == ICE_SUBDEV_ID_E810T); + switch (hw->device_id) { + case ICE_DEV_ID_E810C_SFP: + if (hw->subsystem_device_id == ICE_SUBDEV_ID_E810T || + hw->subsystem_device_id == ICE_SUBDEV_ID_E810T2) + return true; + break; + case ICE_DEV_ID_E810C_QSFP: + if (hw->subsystem_device_id == ICE_SUBDEV_ID_E810T2) + return true; + break; + default: + break; + } + + return false; } /** diff --git a/drivers/net/ice/base/ice_devids.h b/drivers/net/ice/base/ice_devids.h index 18397f1925..e52bb71403 100644 --- a/drivers/net/ice/base/ice_devids.h +++ b/drivers/net/ice/base/ice_devids.h @@ -23,6 +23,7 @@ /* Intel(R) Ethernet Controller E810-C for SFP */ #define ICE_DEV_ID_E810C_SFP 0x1593 #define ICE_SUBDEV_ID_E810T 0x000E +#define ICE_SUBDEV_ID_E810T2 0x000F /* Intel(R) Ethernet Controller E810-XXV for backplane */ #define ICE_DEV_ID_E810_XXV_BACKPLANE 0x1599 /* Intel(R) Ethernet Controller E810-XXV for QSFP */