summaryrefslogtreecommitdiffstats
path: root/drivers/net/ixgb
diff options
context:
space:
mode:
authorJesse Brandeburg <jesse.brandeburg@intel.com>2008-07-08 15:51:22 -0700
committerJeff Garzik <jgarzik@redhat.com>2008-07-11 01:20:27 -0400
commita3dc3da02a7c29237ca4ce3ec17f0e1f87ff0a06 (patch)
tree427de9c92a8c12385629f6083755dd20d29939e6 /drivers/net/ixgb
parent4360386f7d849f521e8ef042f90dbca73e07509c (diff)
downloadop-kernel-dev-a3dc3da02a7c29237ca4ce3ec17f0e1f87ff0a06.zip
op-kernel-dev-a3dc3da02a7c29237ca4ce3ec17f0e1f87ff0a06.tar.gz
ixgb: leave room for extra hardware memory usage
ixgb hardware (not ixgbe) has a problem where it might dma past the end of a buffer in certain cases. leave 8 bytes extra room. Signed-off-by: Jesse Brandeburg <jesse.brandeburg@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
Diffstat (limited to 'drivers/net/ixgb')
-rw-r--r--drivers/net/ixgb/ixgb_main.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/net/ixgb/ixgb_main.c b/drivers/net/ixgb/ixgb_main.c
index ecd5252..ec8bce1 100644
--- a/drivers/net/ixgb/ixgb_main.c
+++ b/drivers/net/ixgb/ixgb_main.c
@@ -560,7 +560,7 @@ ixgb_sw_init(struct ixgb_adapter *adapter)
hw->subsystem_id = pdev->subsystem_device;
hw->max_frame_size = netdev->mtu + ENET_HEADER_SIZE + ENET_FCS_LENGTH;
- adapter->rx_buffer_len = hw->max_frame_size;
+ adapter->rx_buffer_len = hw->max_frame_size + 8; /* + 8 for errata */
if((hw->device_id == IXGB_DEVICE_ID_82597EX)
|| (hw->device_id == IXGB_DEVICE_ID_82597EX_CX4)
@@ -1573,7 +1573,7 @@ ixgb_change_mtu(struct net_device *netdev, int new_mtu)
return -EINVAL;
}
- adapter->rx_buffer_len = max_frame;
+ adapter->rx_buffer_len = max_frame + 8; /* + 8 for errata */
netdev->mtu = new_mtu;
OpenPOWER on IntegriCloud