aboutsummaryrefslogtreecommitdiffstatshomepage
diff options
context:
space:
mode:
authorLorenzo Bianconi <lorenzo@kernel.org>2025-06-25 16:43:15 +0200
committerJakub Kicinski <kuba@kernel.org>2025-06-26 17:11:01 -0700
commit4cd9d227ab838b3590c4b27e3707b8c3ef14d7e9 (patch)
treebd4f41cbdf91478a59e767de1cb07a914075bcb0
parentnet: mana: Fix build errors when CONFIG_NET_SHAPER is disabled (diff)
downloadwireguard-linux-4cd9d227ab838b3590c4b27e3707b8c3ef14d7e9.tar.xz
wireguard-linux-4cd9d227ab838b3590c4b27e3707b8c3ef14d7e9.zip
net: airoha: Get rid of dma_sync_single_for_device() in airoha_qdma_fill_rx_queue()
Since the page_pool for airoha_eth driver is created with PP_FLAG_DMA_SYNC_DEV flag, we do not need to sync_for_device each page received from the pool since it is already done by the page_pool codebase. Signed-off-by: Lorenzo Bianconi <lorenzo@kernel.org> Reviewed-by: Alexander Lobakin <aleksander.lobakin@intel.com> Link: https://patch.msgid.link/20250625-airoha-sync-for-device-v1-1-923741deaabf@kernel.org Signed-off-by: Jakub Kicinski <kuba@kernel.org>
-rw-r--r--drivers/net/ethernet/airoha/airoha_eth.c5
1 files changed, 0 insertions, 5 deletions
diff --git a/drivers/net/ethernet/airoha/airoha_eth.c b/drivers/net/ethernet/airoha/airoha_eth.c
index 06dea3a13e77..10a167224bf5 100644
--- a/drivers/net/ethernet/airoha/airoha_eth.c
+++ b/drivers/net/ethernet/airoha/airoha_eth.c
@@ -551,9 +551,7 @@ static int airoha_fe_init(struct airoha_eth *eth)
static int airoha_qdma_fill_rx_queue(struct airoha_queue *q)
{
- enum dma_data_direction dir = page_pool_get_dma_dir(q->page_pool);
struct airoha_qdma *qdma = q->qdma;
- struct airoha_eth *eth = qdma->eth;
int qid = q - &qdma->q_rx[0];
int nframes = 0;
@@ -577,9 +575,6 @@ static int airoha_qdma_fill_rx_queue(struct airoha_queue *q)
e->dma_addr = page_pool_get_dma_addr(page) + offset;
e->dma_len = SKB_WITH_OVERHEAD(q->buf_size);
- dma_sync_single_for_device(eth->dev, e->dma_addr, e->dma_len,
- dir);
-
val = FIELD_PREP(QDMA_DESC_LEN_MASK, e->dma_len);
WRITE_ONCE(desc->ctrl, cpu_to_le32(val));
WRITE_ONCE(desc->addr, cpu_to_le32(e->dma_addr));