Skip to content

Commit 2790b29

Browse files
committed
DBG: test for tx timeout
1 parent b2af2de commit 2790b29

File tree

1 file changed

+6
-4
lines changed

1 file changed

+6
-4
lines changed

drivers/net/ethernet/mediatek/mtk_eth_soc.c

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -2797,10 +2797,12 @@ static int mtk_rx_alloc(struct mtk_eth *eth, int ring_no, int rx_flag)
27972797
} else {
27982798
struct mtk_tx_ring *tx_ring = &eth->tx_ring;
27992799

2800-
ring->dma = tx_ring->dma + tx_ring_size *
2801-
eth->soc->tx.desc_size * (ring_no + 1);
2802-
ring->phys = tx_ring->phys + tx_ring_size *
2803-
eth->soc->tx.desc_size * (ring_no + 1);
2800+
ring->dma = tx_ring->dma +
2801+
eth->soc->tx.dma_size * eth->soc->tx.desc_size +
2802+
eth->soc->rx.dma_size * eth->soc->rx.desc_size * ring_no;
2803+
ring->phys = tx_ring->phys +
2804+
eth->soc->tx.dma_size * eth->soc->tx.desc_size +
2805+
eth->soc->rx.dma_size * eth->soc->rx.desc_size * ring_no;
28042806
}
28052807

28062808
if (!ring->dma)

0 commit comments

Comments
 (0)