Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > linux.kernel > #1607477
| From | Geliang Tang <geliangtang@gmail.com> |
|---|---|
| Newsgroups | linux.kernel |
| Subject | [PATCH] microblaze: use sg_phys() |
| Date | 2017-03-23 14:20 +0100 |
| Message-ID | <toaOK-2Hz-35@gated-at.bofh.it> (permalink) |
| References | <toaOJ-2Hz-17@gated-at.bofh.it> |
| Organization | linux.* mail to news gateway |
Use sg_phys() instead of open-coding it. Signed-off-by: Geliang Tang <geliangtang@gmail.com> --- arch/microblaze/kernel/dma.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/arch/microblaze/kernel/dma.c b/arch/microblaze/kernel/dma.c index 12e093a..e45ada8 100644 --- a/arch/microblaze/kernel/dma.c +++ b/arch/microblaze/kernel/dma.c @@ -65,8 +65,7 @@ static int dma_direct_map_sg(struct device *dev, struct scatterlist *sgl, if (attrs & DMA_ATTR_SKIP_CPU_SYNC) continue; - __dma_sync(page_to_phys(sg_page(sg)) + sg->offset, - sg->length, direction); + __dma_sync(sg_phys(sg), sg->length, direction); } return nents; -- 2.9.3
Back to linux.kernel | Previous | Next | Find similar | Unroll thread
[PATCH] microblaze: use sg_phys() Geliang Tang <geliangtang@gmail.com> - 2017-03-23 14:20 +0100
csiph-web