igb: add defaults for i210 TX/RX PBSIZE

Set the defaults on probe for the packet buffer size registers for the
i210.

Signed-off-by: Todd Fujinaka <todd.fujinaka@intel.com>
Tested-by: Aaron Brown <aaron.f.brown@intel.com>
Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
This commit is contained in:
Todd Fujinaka 2014-05-29 05:47:26 +00:00 committed by Jeff Kirsher
parent 3cfcf036e1
commit 27dff8b2f6
3 changed files with 13 additions and 0 deletions

View File

@ -329,6 +329,9 @@
/* Timestamp in Rx buffer */ /* Timestamp in Rx buffer */
#define E1000_RXPBS_CFG_TS_EN 0x80000000 #define E1000_RXPBS_CFG_TS_EN 0x80000000
#define I210_RXPBSIZE_DEFAULT 0x000000A2 /* RXPBSIZE default */
#define I210_TXPBSIZE_DEFAULT 0x04000014 /* TXPBSIZE default */
/* SerDes Control */ /* SerDes Control */
#define E1000_SCTL_DISABLE_SERDES_LOOPBACK 0x0400 #define E1000_SCTL_DISABLE_SERDES_LOOPBACK 0x0400

View File

@ -192,6 +192,10 @@
: (0x0E038 + ((_n) * 0x40))) : (0x0E038 + ((_n) * 0x40)))
#define E1000_TDWBAH(_n) ((_n) < 4 ? (0x0383C + ((_n) * 0x100)) \ #define E1000_TDWBAH(_n) ((_n) < 4 ? (0x0383C + ((_n) * 0x100)) \
: (0x0E03C + ((_n) * 0x40))) : (0x0E03C + ((_n) * 0x40)))
#define E1000_RXPBS 0x02404 /* Rx Packet Buffer Size - RW */
#define E1000_TXPBS 0x03404 /* Tx Packet Buffer Size - RW */
#define E1000_TDFH 0x03410 /* TX Data FIFO Head - RW */ #define E1000_TDFH 0x03410 /* TX Data FIFO Head - RW */
#define E1000_TDFT 0x03418 /* TX Data FIFO Tail - RW */ #define E1000_TDFT 0x03418 /* TX Data FIFO Tail - RW */
#define E1000_TDFHS 0x03420 /* TX Data FIFO Head Saved - RW */ #define E1000_TDFHS 0x03420 /* TX Data FIFO Head Saved - RW */

View File

@ -2433,6 +2433,12 @@ static int igb_probe(struct pci_dev *pdev, const struct pci_device_id *ent)
/* get firmware version for ethtool -i */ /* get firmware version for ethtool -i */
igb_set_fw_version(adapter); igb_set_fw_version(adapter);
/* configure RXPBSIZE and TXPBSIZE */
if (hw->mac.type == e1000_i210) {
wr32(E1000_RXPBS, I210_RXPBSIZE_DEFAULT);
wr32(E1000_TXPBS, I210_TXPBSIZE_DEFAULT);
}
setup_timer(&adapter->watchdog_timer, igb_watchdog, setup_timer(&adapter->watchdog_timer, igb_watchdog,
(unsigned long) adapter); (unsigned long) adapter);
setup_timer(&adapter->phy_info_timer, igb_update_phy_info, setup_timer(&adapter->phy_info_timer, igb_update_phy_info,