qlge: Fix frame routing issue related to bonding.

Currently frames are routed based on their type and MAC address. This
patch adds the port number on which the frame arrived to the routing.
This prevents problems in the case where both interfaces have the same MAC address in
a routing configuration.

Signed-off-by: Ron Mercer <ron.mercer@qlogic.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
This commit is contained in:
Ron Mercer 2009-10-08 09:54:38 +00:00 committed by David S. Miller
parent 541ae28c2d
commit a3b71939a9
1 changed files with 7 additions and 0 deletions

View File

@ -3241,6 +3241,13 @@ static int ql_adapter_initialize(struct ql_adapter *qdev)
ql_write32(qdev, SPLT_HDR, SPLT_HDR_EP | ql_write32(qdev, SPLT_HDR, SPLT_HDR_EP |
min(SMALL_BUFFER_SIZE, MAX_SPLIT_SIZE)); min(SMALL_BUFFER_SIZE, MAX_SPLIT_SIZE));
/* Set RX packet routing to use port/pci function on which the
* packet arrived on in addition to usual frame routing.
* This is helpful on bonding where both interfaces can have
* the same MAC address.
*/
ql_write32(qdev, RST_FO, RST_FO_RR_MASK | RST_FO_RR_RCV_FUNC_CQ);
/* Start up the rx queues. */ /* Start up the rx queues. */
for (i = 0; i < qdev->rx_ring_count; i++) { for (i = 0; i < qdev->rx_ring_count; i++) {
status = ql_start_rx_ring(qdev, &qdev->rx_ring[i]); status = ql_start_rx_ring(qdev, &qdev->rx_ring[i]);