mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git
synced 2025-01-17 02:36:21 +00:00
Merge branch '100GbE' of git://git.kernel.org/pub/scm/linux/kernel/git/tnguy/net-queue
Tony Nguyen says: ==================== Intel Wired LAN Driver Updates 2024-12-03 (ice, idpf, ixgbe, ixgbevf, igb) This series contains updates to ice, idpf, ixgbe, ixgbevf, and igb drivers. For ice: Arkadiusz corrects search for determining whether PHY clock recovery is supported on the device. Przemyslaw corrects mask used for PHY timestamps on ETH56G devices. Wojciech adds missing virtchnl ops which caused NULL pointer dereference. Marcin fixes VLAN filter settings for uplink VSI in switchdev mode. For idpf: Josh restores setting of completion tag for empty buffers. For ixgbevf: Jake removes incorrect initialization/support of IPSEC for mailbox version 1.5. For ixgbe: Jake rewords and downgrades misleading message when negotiation of VF mailbox version is not supported. Tore Amundsen corrects value for BASE-BX10 capability. For igb: Yuan Can adds proper teardown on failed pci_register_driver() call. * '100GbE' of git://git.kernel.org/pub/scm/linux/kernel/git/tnguy/net-queue: igb: Fix potential invalid memory access in igb_init_module() ixgbe: Correct BASE-BX10 compliance code ixgbe: downgrade logging of unsupported VF API version to debug ixgbevf: stop attempting IPSEC offload on Mailbox API 1.5 idpf: set completion tag for "empty" bufs associated with a packet ice: Fix VLAN pruning in switchdev mode ice: Fix NULL pointer dereference in switchdev ice: fix PHY timestamp extraction for ETH56G ice: fix PHY Clock Recovery availability check ==================== Link: https://patch.msgid.link/20241203215521.1646668-1-anthony.l.nguyen@intel.com Signed-off-by: Jakub Kicinski <kuba@kernel.org>
This commit is contained in:
commit
4615855ea8
@ -542,7 +542,8 @@ ice_aq_get_netlist_node(struct ice_hw *hw, struct ice_aqc_get_link_topo *cmd,
|
||||
/**
|
||||
* ice_find_netlist_node
|
||||
* @hw: pointer to the hw struct
|
||||
* @node_type_ctx: type of netlist node to look for
|
||||
* @node_type: type of netlist node to look for
|
||||
* @ctx: context of the search
|
||||
* @node_part_number: node part number to look for
|
||||
* @node_handle: output parameter if node found - optional
|
||||
*
|
||||
@ -552,10 +553,12 @@ ice_aq_get_netlist_node(struct ice_hw *hw, struct ice_aqc_get_link_topo *cmd,
|
||||
* valid if the function returns zero, and should be ignored on any non-zero
|
||||
* return value.
|
||||
*
|
||||
* Returns: 0 if the node is found, -ENOENT if no handle was found, and
|
||||
* a negative error code on failure to access the AQ.
|
||||
* Return:
|
||||
* * 0 if the node is found,
|
||||
* * -ENOENT if no handle was found,
|
||||
* * negative error code on failure to access the AQ.
|
||||
*/
|
||||
static int ice_find_netlist_node(struct ice_hw *hw, u8 node_type_ctx,
|
||||
static int ice_find_netlist_node(struct ice_hw *hw, u8 node_type, u8 ctx,
|
||||
u8 node_part_number, u16 *node_handle)
|
||||
{
|
||||
u8 idx;
|
||||
@ -566,8 +569,8 @@ static int ice_find_netlist_node(struct ice_hw *hw, u8 node_type_ctx,
|
||||
int status;
|
||||
|
||||
cmd.addr.topo_params.node_type_ctx =
|
||||
FIELD_PREP(ICE_AQC_LINK_TOPO_NODE_TYPE_M,
|
||||
node_type_ctx);
|
||||
FIELD_PREP(ICE_AQC_LINK_TOPO_NODE_TYPE_M, node_type) |
|
||||
FIELD_PREP(ICE_AQC_LINK_TOPO_NODE_CTX_M, ctx);
|
||||
cmd.addr.topo_params.index = idx;
|
||||
|
||||
status = ice_aq_get_netlist_node(hw, &cmd,
|
||||
@ -2747,9 +2750,11 @@ bool ice_is_pf_c827(struct ice_hw *hw)
|
||||
*/
|
||||
bool ice_is_phy_rclk_in_netlist(struct ice_hw *hw)
|
||||
{
|
||||
if (ice_find_netlist_node(hw, ICE_AQC_LINK_TOPO_NODE_TYPE_CLK_CTRL,
|
||||
if (ice_find_netlist_node(hw, ICE_AQC_LINK_TOPO_NODE_TYPE_PHY,
|
||||
ICE_AQC_LINK_TOPO_NODE_CTX_PORT,
|
||||
ICE_AQC_GET_LINK_TOPO_NODE_NR_C827, NULL) &&
|
||||
ice_find_netlist_node(hw, ICE_AQC_LINK_TOPO_NODE_TYPE_CLK_CTRL,
|
||||
ice_find_netlist_node(hw, ICE_AQC_LINK_TOPO_NODE_TYPE_PHY,
|
||||
ICE_AQC_LINK_TOPO_NODE_CTX_PORT,
|
||||
ICE_AQC_GET_LINK_TOPO_NODE_NR_E822_PHY, NULL))
|
||||
return false;
|
||||
|
||||
@ -2765,6 +2770,7 @@ bool ice_is_phy_rclk_in_netlist(struct ice_hw *hw)
|
||||
bool ice_is_clock_mux_in_netlist(struct ice_hw *hw)
|
||||
{
|
||||
if (ice_find_netlist_node(hw, ICE_AQC_LINK_TOPO_NODE_TYPE_CLK_MUX,
|
||||
ICE_AQC_LINK_TOPO_NODE_CTX_GLOBAL,
|
||||
ICE_AQC_GET_LINK_TOPO_NODE_NR_GEN_CLK_MUX,
|
||||
NULL))
|
||||
return false;
|
||||
@ -2785,12 +2791,14 @@ bool ice_is_clock_mux_in_netlist(struct ice_hw *hw)
|
||||
bool ice_is_cgu_in_netlist(struct ice_hw *hw)
|
||||
{
|
||||
if (!ice_find_netlist_node(hw, ICE_AQC_LINK_TOPO_NODE_TYPE_CLK_CTRL,
|
||||
ICE_AQC_LINK_TOPO_NODE_CTX_GLOBAL,
|
||||
ICE_AQC_GET_LINK_TOPO_NODE_NR_ZL30632_80032,
|
||||
NULL)) {
|
||||
hw->cgu_part_number = ICE_AQC_GET_LINK_TOPO_NODE_NR_ZL30632_80032;
|
||||
return true;
|
||||
} else if (!ice_find_netlist_node(hw,
|
||||
ICE_AQC_LINK_TOPO_NODE_TYPE_CLK_CTRL,
|
||||
ICE_AQC_LINK_TOPO_NODE_CTX_GLOBAL,
|
||||
ICE_AQC_GET_LINK_TOPO_NODE_NR_SI5383_5384,
|
||||
NULL)) {
|
||||
hw->cgu_part_number = ICE_AQC_GET_LINK_TOPO_NODE_NR_SI5383_5384;
|
||||
@ -2809,6 +2817,7 @@ bool ice_is_cgu_in_netlist(struct ice_hw *hw)
|
||||
bool ice_is_gps_in_netlist(struct ice_hw *hw)
|
||||
{
|
||||
if (ice_find_netlist_node(hw, ICE_AQC_LINK_TOPO_NODE_TYPE_GPS,
|
||||
ICE_AQC_LINK_TOPO_NODE_CTX_GLOBAL,
|
||||
ICE_AQC_GET_LINK_TOPO_NODE_NR_GEN_GPS, NULL))
|
||||
return false;
|
||||
|
||||
|
@ -6408,10 +6408,12 @@ ice_set_vlan_filtering_features(struct ice_vsi *vsi, netdev_features_t features)
|
||||
int err = 0;
|
||||
|
||||
/* support Single VLAN Mode (SVM) and Double VLAN Mode (DVM) by checking
|
||||
* if either bit is set
|
||||
* if either bit is set. In switchdev mode Rx filtering should never be
|
||||
* enabled.
|
||||
*/
|
||||
if (features &
|
||||
(NETIF_F_HW_VLAN_CTAG_FILTER | NETIF_F_HW_VLAN_STAG_FILTER))
|
||||
if ((features &
|
||||
(NETIF_F_HW_VLAN_CTAG_FILTER | NETIF_F_HW_VLAN_STAG_FILTER)) &&
|
||||
!ice_is_eswitch_mode_switchdev(vsi->back))
|
||||
err = vlan_ops->ena_rx_filtering(vsi);
|
||||
else
|
||||
err = vlan_ops->dis_rx_filtering(vsi);
|
||||
|
@ -1518,7 +1518,8 @@ static int ice_read_ptp_tstamp_eth56g(struct ice_hw *hw, u8 port, u8 idx,
|
||||
* lower 8 bits in the low register, and the upper 32 bits in the high
|
||||
* register.
|
||||
*/
|
||||
*tstamp = ((u64)hi) << TS_PHY_HIGH_S | ((u64)lo & TS_PHY_LOW_M);
|
||||
*tstamp = FIELD_PREP(TS_PHY_HIGH_M, hi) |
|
||||
FIELD_PREP(TS_PHY_LOW_M, lo);
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
@ -682,9 +682,8 @@ static inline bool ice_is_dual(struct ice_hw *hw)
|
||||
#define TS_HIGH_M 0xFF
|
||||
#define TS_HIGH_S 32
|
||||
|
||||
#define TS_PHY_LOW_M 0xFF
|
||||
#define TS_PHY_HIGH_M 0xFFFFFFFF
|
||||
#define TS_PHY_HIGH_S 8
|
||||
#define TS_PHY_LOW_M GENMASK(7, 0)
|
||||
#define TS_PHY_HIGH_M GENMASK_ULL(39, 8)
|
||||
|
||||
#define BYTES_PER_IDX_ADDR_L_U 8
|
||||
#define BYTES_PER_IDX_ADDR_L 4
|
||||
|
@ -4128,6 +4128,9 @@ static const struct ice_virtchnl_ops ice_virtchnl_dflt_ops = {
|
||||
.get_qos_caps = ice_vc_get_qos_caps,
|
||||
.cfg_q_bw = ice_vc_cfg_q_bw,
|
||||
.cfg_q_quanta = ice_vc_cfg_q_quanta,
|
||||
/* If you add a new op here please make sure to add it to
|
||||
* ice_virtchnl_repr_ops as well.
|
||||
*/
|
||||
};
|
||||
|
||||
/**
|
||||
@ -4258,6 +4261,9 @@ static const struct ice_virtchnl_ops ice_virtchnl_repr_ops = {
|
||||
.dis_vlan_stripping_v2_msg = ice_vc_dis_vlan_stripping_v2_msg,
|
||||
.ena_vlan_insertion_v2_msg = ice_vc_ena_vlan_insertion_v2_msg,
|
||||
.dis_vlan_insertion_v2_msg = ice_vc_dis_vlan_insertion_v2_msg,
|
||||
.get_qos_caps = ice_vc_get_qos_caps,
|
||||
.cfg_q_bw = ice_vc_cfg_q_bw,
|
||||
.cfg_q_quanta = ice_vc_cfg_q_quanta,
|
||||
};
|
||||
|
||||
/**
|
||||
|
@ -2448,6 +2448,7 @@ static void idpf_tx_splitq_map(struct idpf_tx_queue *tx_q,
|
||||
* rest of the packet.
|
||||
*/
|
||||
tx_buf->type = LIBETH_SQE_EMPTY;
|
||||
idpf_tx_buf_compl_tag(tx_buf) = params->compl_tag;
|
||||
|
||||
/* Adjust the DMA offset and the remaining size of the
|
||||
* fragment. On the first iteration of this loop,
|
||||
|
@ -637,6 +637,10 @@ static int __init igb_init_module(void)
|
||||
dca_register_notify(&dca_notifier);
|
||||
#endif
|
||||
ret = pci_register_driver(&igb_driver);
|
||||
#ifdef CONFIG_IGB_DCA
|
||||
if (ret)
|
||||
dca_unregister_notify(&dca_notifier);
|
||||
#endif
|
||||
return ret;
|
||||
}
|
||||
|
||||
|
@ -194,6 +194,8 @@ u32 ixgbe_read_reg(struct ixgbe_hw *hw, u32 reg);
|
||||
dev_err(&adapter->pdev->dev, format, ## arg)
|
||||
#define e_dev_notice(format, arg...) \
|
||||
dev_notice(&adapter->pdev->dev, format, ## arg)
|
||||
#define e_dbg(msglvl, format, arg...) \
|
||||
netif_dbg(adapter, msglvl, adapter->netdev, format, ## arg)
|
||||
#define e_info(msglvl, format, arg...) \
|
||||
netif_info(adapter, msglvl, adapter->netdev, format, ## arg)
|
||||
#define e_err(msglvl, format, arg...) \
|
||||
|
@ -40,7 +40,7 @@
|
||||
#define IXGBE_SFF_1GBASESX_CAPABLE 0x1
|
||||
#define IXGBE_SFF_1GBASELX_CAPABLE 0x2
|
||||
#define IXGBE_SFF_1GBASET_CAPABLE 0x8
|
||||
#define IXGBE_SFF_BASEBX10_CAPABLE 0x64
|
||||
#define IXGBE_SFF_BASEBX10_CAPABLE 0x40
|
||||
#define IXGBE_SFF_10GBASESR_CAPABLE 0x10
|
||||
#define IXGBE_SFF_10GBASELR_CAPABLE 0x20
|
||||
#define IXGBE_SFF_SOFT_RS_SELECT_MASK 0x8
|
||||
|
@ -1048,7 +1048,7 @@ static int ixgbe_negotiate_vf_api(struct ixgbe_adapter *adapter,
|
||||
break;
|
||||
}
|
||||
|
||||
e_info(drv, "VF %d requested invalid api version %u\n", vf, api);
|
||||
e_dbg(drv, "VF %d requested unsupported api version %u\n", vf, api);
|
||||
|
||||
return -1;
|
||||
}
|
||||
|
@ -629,7 +629,6 @@ void ixgbevf_init_ipsec_offload(struct ixgbevf_adapter *adapter)
|
||||
|
||||
switch (adapter->hw.api_version) {
|
||||
case ixgbe_mbox_api_14:
|
||||
case ixgbe_mbox_api_15:
|
||||
break;
|
||||
default:
|
||||
return;
|
||||
|
Loading…
x
Reference in New Issue
Block a user