History

ixgbe: don't set RXDCTL.RLPML for 82599

commit 2de6aa3a666e ("ixgbe: Add support for padding packet") Uses RXDCTL.RLPML to limit the maximum frame size on Rx when using build_skb. Unfortunately that register does not work on 82599. Added an explicit check to avoid setting this register on 82599 MAC. Extended the comment related to the setting of RXDCTL.RLPML to better explain its purpose.

Emil Tantilov committed 8 years ago

Commit 2bafa8f1 parent fd492221 file · +6 −2Browse files

Unified · Split

drivers/net/ethernet/intel/ixgbe/ixgbe_main.c+6−2
@@ -4133,11 +4133,15 @@ void ixgbe_configure_rx_ring(struct ixgbe_adapter *adapter, · 4132 unmodified lines
4133 rxdctl &= ~0x3FFFFF;4133 rxdctl &= ~0x3FFFFF;
4134 rxdctl |= 0x080420;4134 rxdctl |= 0x080420;
4135#if (PAGE_SIZE < 8192)4135#if (PAGE_SIZE < 8192)
4136 } else {4136 /* RXDCTL.RLPML does not work on 82599 */
4137 } else if (hw->mac.type != ixgbe_mac_82599EB) {
4137 rxdctl &= ~(IXGBE_RXDCTL_RLPMLMASK |4138 rxdctl &= ~(IXGBE_RXDCTL_RLPMLMASK |
4138 IXGBE_RXDCTL_RLPML_EN);4139 IXGBE_RXDCTL_RLPML_EN);
4139 4140
4140 /* Limit the maximum frame size so we don't overrun the skb */4141 /* Limit the maximum frame size so we don't overrun the skb.
4142 * This can happen in SRIOV mode when the MTU of the VF is
4143 * higher than the MTU of the PF.
4144 */
4141 if (ring_uses_build_skb(ring) &&4145 if (ring_uses_build_skb(ring) &&
4142 !test_bit(__IXGBE_RX_3K_BUFFER, &ring->state))4146 !test_bit(__IXGBE_RX_3K_BUFFER, &ring->state))
4143 rxdctl |= IXGBE_MAX_2K_FRAME_BUILD_SKB |4147 rxdctl |= IXGBE_MAX_2K_FRAME_BUILD_SKB |