aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--drivers/net/tg3.c16
-rw-r--r--drivers/net/tg3.h4
2 files changed, 10 insertions, 10 deletions
diff --git a/drivers/net/tg3.c b/drivers/net/tg3.c
index 00e7e14fd3f7..59a715a25623 100644
--- a/drivers/net/tg3.c
+++ b/drivers/net/tg3.c
@@ -4564,13 +4564,13 @@ static int tg3_rx(struct tg3_napi *tnapi, int budget)
4564 ri = &tpr->rx_std_buffers[desc_idx]; 4564 ri = &tpr->rx_std_buffers[desc_idx];
4565 dma_addr = pci_unmap_addr(ri, mapping); 4565 dma_addr = pci_unmap_addr(ri, mapping);
4566 skb = ri->skb; 4566 skb = ri->skb;
4567 post_ptr = &tpr->rx_std_ptr; 4567 post_ptr = &tpr->rx_std_prod_idx;
4568 rx_std_posted++; 4568 rx_std_posted++;
4569 } else if (opaque_key == RXD_OPAQUE_RING_JUMBO) { 4569 } else if (opaque_key == RXD_OPAQUE_RING_JUMBO) {
4570 ri = &tpr->rx_jmb_buffers[desc_idx]; 4570 ri = &tpr->rx_jmb_buffers[desc_idx];
4571 dma_addr = pci_unmap_addr(ri, mapping); 4571 dma_addr = pci_unmap_addr(ri, mapping);
4572 skb = ri->skb; 4572 skb = ri->skb;
4573 post_ptr = &tpr->rx_jmb_ptr; 4573 post_ptr = &tpr->rx_jmb_prod_idx;
4574 } else 4574 } else
4575 goto next_pkt_nopost; 4575 goto next_pkt_nopost;
4576 4576
@@ -4687,12 +4687,12 @@ next_pkt_nopost:
4687 4687
4688 /* Refill RX ring(s). */ 4688 /* Refill RX ring(s). */
4689 if (work_mask & RXD_OPAQUE_RING_STD) { 4689 if (work_mask & RXD_OPAQUE_RING_STD) {
4690 sw_idx = tpr->rx_std_ptr % TG3_RX_RING_SIZE; 4690 sw_idx = tpr->rx_std_prod_idx % TG3_RX_RING_SIZE;
4691 tw32_rx_mbox(MAILBOX_RCV_STD_PROD_IDX + TG3_64BIT_REG_LOW, 4691 tw32_rx_mbox(MAILBOX_RCV_STD_PROD_IDX + TG3_64BIT_REG_LOW,
4692 sw_idx); 4692 sw_idx);
4693 } 4693 }
4694 if (work_mask & RXD_OPAQUE_RING_JUMBO) { 4694 if (work_mask & RXD_OPAQUE_RING_JUMBO) {
4695 sw_idx = tpr->rx_jmb_ptr % TG3_RX_JUMBO_RING_SIZE; 4695 sw_idx = tpr->rx_jmb_prod_idx % TG3_RX_JUMBO_RING_SIZE;
4696 tw32_rx_mbox(MAILBOX_RCV_JUMBO_PROD_IDX + TG3_64BIT_REG_LOW, 4696 tw32_rx_mbox(MAILBOX_RCV_JUMBO_PROD_IDX + TG3_64BIT_REG_LOW,
4697 sw_idx); 4697 sw_idx);
4698 } 4698 }
@@ -7509,14 +7509,14 @@ static int tg3_reset_hw(struct tg3 *tp, int reset_phy)
7509 7509
7510 tw32(RCVDBDI_STD_BD + TG3_BDINFO_MAXLEN_FLAGS, val); 7510 tw32(RCVDBDI_STD_BD + TG3_BDINFO_MAXLEN_FLAGS, val);
7511 7511
7512 tpr->rx_std_ptr = tp->rx_pending; 7512 tpr->rx_std_prod_idx = tp->rx_pending;
7513 tw32_rx_mbox(MAILBOX_RCV_STD_PROD_IDX + TG3_64BIT_REG_LOW, 7513 tw32_rx_mbox(MAILBOX_RCV_STD_PROD_IDX + TG3_64BIT_REG_LOW,
7514 tpr->rx_std_ptr); 7514 tpr->rx_std_prod_idx);
7515 7515
7516 tpr->rx_jmb_ptr = (tp->tg3_flags & TG3_FLAG_JUMBO_RING_ENABLE) ? 7516 tpr->rx_jmb_prod_idx = (tp->tg3_flags & TG3_FLAG_JUMBO_RING_ENABLE) ?
7517 tp->rx_jumbo_pending : 0; 7517 tp->rx_jumbo_pending : 0;
7518 tw32_rx_mbox(MAILBOX_RCV_JUMBO_PROD_IDX + TG3_64BIT_REG_LOW, 7518 tw32_rx_mbox(MAILBOX_RCV_JUMBO_PROD_IDX + TG3_64BIT_REG_LOW,
7519 tpr->rx_jmb_ptr); 7519 tpr->rx_jmb_prod_idx);
7520 7520
7521 if (GET_ASIC_REV(tp->pci_chip_rev_id) == ASIC_REV_5717) { 7521 if (GET_ASIC_REV(tp->pci_chip_rev_id) == ASIC_REV_5717) {
7522 tw32(STD_REPLENISH_LWM, 32); 7522 tw32(STD_REPLENISH_LWM, 32);
diff --git a/drivers/net/tg3.h b/drivers/net/tg3.h
index 42fefa11c052..e0b86ba3b5b9 100644
--- a/drivers/net/tg3.h
+++ b/drivers/net/tg3.h
@@ -2570,8 +2570,8 @@ struct tg3_ethtool_stats {
2570}; 2570};
2571 2571
2572struct tg3_rx_prodring_set { 2572struct tg3_rx_prodring_set {
2573 u32 rx_std_ptr; 2573 u32 rx_std_prod_idx;
2574 u32 rx_jmb_ptr; 2574 u32 rx_jmb_prod_idx;
2575 struct tg3_rx_buffer_desc *rx_std; 2575 struct tg3_rx_buffer_desc *rx_std;
2576 struct tg3_ext_rx_buffer_desc *rx_jmb; 2576 struct tg3_ext_rx_buffer_desc *rx_jmb;
2577 struct ring_info *rx_std_buffers; 2577 struct ring_info *rx_std_buffers;