diff options
Diffstat (limited to 'drivers/net/ixgbe/ixgbe_dcb_82599.c')
-rw-r--r-- | drivers/net/ixgbe/ixgbe_dcb_82599.c | 12 |
1 files changed, 5 insertions, 7 deletions
diff --git a/drivers/net/ixgbe/ixgbe_dcb_82599.c b/drivers/net/ixgbe/ixgbe_dcb_82599.c index 05f224715073..374e1f74d0f5 100644 --- a/drivers/net/ixgbe/ixgbe_dcb_82599.c +++ b/drivers/net/ixgbe/ixgbe_dcb_82599.c | |||
@@ -251,19 +251,17 @@ s32 ixgbe_dcb_config_pfc_82599(struct ixgbe_hw *hw, | |||
251 | 251 | ||
252 | /* Configure PFC Tx thresholds per TC */ | 252 | /* Configure PFC Tx thresholds per TC */ |
253 | for (i = 0; i < MAX_TRAFFIC_CLASS; i++) { | 253 | for (i = 0; i < MAX_TRAFFIC_CLASS; i++) { |
254 | if (dcb_config->rx_pba_cfg == pba_equal) | 254 | rx_pba_size = IXGBE_READ_REG(hw, IXGBE_RXPBSIZE(i)); |
255 | rx_pba_size = IXGBE_RXPBSIZE_64KB; | 255 | rx_pba_size >>= IXGBE_RXPBSIZE_SHIFT; |
256 | else | 256 | |
257 | rx_pba_size = (i < 4) ? IXGBE_RXPBSIZE_80KB | 257 | reg = (rx_pba_size - hw->fc.low_water) << 10; |
258 | : IXGBE_RXPBSIZE_48KB; | ||
259 | 258 | ||
260 | reg = ((rx_pba_size >> 5) & 0xFFE0); | ||
261 | if (dcb_config->tc_config[i].dcb_pfc == pfc_enabled_full || | 259 | if (dcb_config->tc_config[i].dcb_pfc == pfc_enabled_full || |
262 | dcb_config->tc_config[i].dcb_pfc == pfc_enabled_tx) | 260 | dcb_config->tc_config[i].dcb_pfc == pfc_enabled_tx) |
263 | reg |= IXGBE_FCRTL_XONE; | 261 | reg |= IXGBE_FCRTL_XONE; |
264 | IXGBE_WRITE_REG(hw, IXGBE_FCRTL_82599(i), reg); | 262 | IXGBE_WRITE_REG(hw, IXGBE_FCRTL_82599(i), reg); |
265 | 263 | ||
266 | reg = ((rx_pba_size >> 2) & 0xFFE0); | 264 | reg = (rx_pba_size - hw->fc.high_water) << 10; |
267 | if (dcb_config->tc_config[i].dcb_pfc == pfc_enabled_full || | 265 | if (dcb_config->tc_config[i].dcb_pfc == pfc_enabled_full || |
268 | dcb_config->tc_config[i].dcb_pfc == pfc_enabled_tx) | 266 | dcb_config->tc_config[i].dcb_pfc == pfc_enabled_tx) |
269 | reg |= IXGBE_FCRTH_FCEN; | 267 | reg |= IXGBE_FCRTH_FCEN; |