From: tom.leiming@gmail.com
To: linux@arm.linux.org.uk, rmk@arm.linux.org.uk
Cc: linux-arm-kernel@lists.arm.linux.org.uk,
linux-kernel@vger.kernel.org, akpm@linux-foundation.org,
Ming Lei <tom.leiming@gmail.com>
Subject: [PATCH v2 4/4] ARM:dma-mapping:fix dma_map_sg and dma_unmap_sg
Date: Mon, 20 Jul 2009 22:25:54 +0800 [thread overview]
Message-ID: <1248099954-6666-5-git-send-email-tom.leiming@gmail.com> (raw)
In-Reply-To: <1248099954-6666-4-git-send-email-tom.leiming@gmail.com>
From: Ming Lei <tom.leiming@gmail.com>
This patch removes unnecessary calling of debug_dma_map_page
and debug_dma_unmap_page in dma_map_sg and dma_unmap_sg.
Signed-off-by: Ming Lei <tom.leiming@gmail.com>
---
arch/arm/mm/dma-mapping.c | 6 +++---
1 files changed, 3 insertions(+), 3 deletions(-)
diff --git a/arch/arm/mm/dma-mapping.c b/arch/arm/mm/dma-mapping.c
index 64e5d82..584018c 100644
--- a/arch/arm/mm/dma-mapping.c
+++ b/arch/arm/mm/dma-mapping.c
@@ -610,7 +610,7 @@ int __dma_map_sg(struct device *dev, struct scatterlist *sg, int nents,
int i, j;
for_each_sg(sg, s, nents, i) {
- s->dma_address = dma_map_page(dev, sg_page(s), s->offset,
+ s->dma_address = __dma_map_page(dev, sg_page(s), s->offset,
s->length, dir);
if (dma_mapping_error(dev, s->dma_address))
goto bad_mapping;
@@ -619,7 +619,7 @@ int __dma_map_sg(struct device *dev, struct scatterlist *sg, int nents,
bad_mapping:
for_each_sg(sg, s, i, j)
- dma_unmap_page(dev, sg_dma_address(s), sg_dma_len(s), dir);
+ __dma_unmap_single(dev, sg_dma_address(s), sg_dma_len(s), dir);
return 0;
}
EXPORT_SYMBOL(__dma_map_sg);
@@ -641,7 +641,7 @@ void __dma_unmap_sg(struct device *dev, struct scatterlist *sg, int nents,
int i;
for_each_sg(sg, s, nents, i)
- dma_unmap_page(dev, sg_dma_address(s), sg_dma_len(s), dir);
+ __dma_unmap_single(dev, sg_dma_address(s), sg_dma_len(s), dir);
}
EXPORT_SYMBOL(__dma_unmap_sg);
--
1.6.0.GIT
next prev parent reply other threads:[~2009-07-20 14:27 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2009-07-20 14:25 [PATCH v2 0/4] ARM:dma-mapping:DMA-API debugging patch set tom.leiming
2009-07-20 14:25 ` [PATCH v2 1/4] ARM:dma-mapping:wrappers for dma-api tom.leiming
2009-07-20 14:25 ` [PATCH v2 2/4] ARM:dma-mapping:only provide one set of dma-api wrappers tom.leiming
2009-07-20 14:25 ` [PATCH v2 3/4] ARM:dma-mapping:Support DMA-API debugging facility on ARM tom.leiming
2009-07-20 14:25 ` tom.leiming [this message]
2009-07-26 10:05 ` [PATCH v2 0/4] ARM:dma-mapping:DMA-API debugging patch set Ming Lei
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1248099954-6666-5-git-send-email-tom.leiming@gmail.com \
--to=tom.leiming@gmail.com \
--cc=akpm@linux-foundation.org \
--cc=linux-arm-kernel@lists.arm.linux.org.uk \
--cc=linux-kernel@vger.kernel.org \
--cc=linux@arm.linux.org.uk \
--cc=rmk@arm.linux.org.uk \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
Powered by JetHome