mirror of
https://github.com/hardkernel/linux.git
synced 2026-06-07 03:15:31 +09:00
net: spider_net: Fix the size used in a 'dma_free_coherent()' call
[ Upstream commit36f28f7687] Update the size used in 'dma_free_coherent()' in order to match the one used in the corresponding 'dma_alloc_coherent()', in 'spider_net_init_chain()'. Fixes:d4ed8f8d1f("Spidernet DMA coalescing") Signed-off-by: Christophe JAILLET <christophe.jaillet@wanadoo.fr> Signed-off-by: David S. Miller <davem@davemloft.net> Signed-off-by: Sasha Levin <sashal@kernel.org>
This commit is contained in:
committed by
Chris
parent
df00a449c8
commit
a37f5b62b6
@@ -296,8 +296,8 @@ spider_net_free_chain(struct spider_net_card *card,
|
||||
descr = descr->next;
|
||||
} while (descr != chain->ring);
|
||||
|
||||
dma_free_coherent(&card->pdev->dev, chain->num_desc,
|
||||
chain->hwring, chain->dma_addr);
|
||||
dma_free_coherent(&card->pdev->dev, chain->num_desc * sizeof(struct spider_net_hw_descr),
|
||||
chain->hwring, chain->dma_addr);
|
||||
}
|
||||
|
||||
/**
|
||||
|
||||
Reference in New Issue
Block a user