diff options
author | Glauber Costa <gcosta@redhat.com> | 2008-04-08 12:20:59 -0400 |
---|---|---|
committer | Ingo Molnar <mingo@elte.hu> | 2008-04-19 13:19:58 -0400 |
commit | 2e33e361188617628e47b4bc47e87e84feaf556f (patch) | |
tree | 9a66f99445537ef47fb1a80b9bdac52483482704 /arch/x86 | |
parent | cac67877d268f21da74d879a355247e4e25b5b5f (diff) |
x86: adjust dma_free_coherent for i386
We call unmap_single, if available.
Signed-off-by: Glauber Costa <gcosta@redhat.com>
Signed-off-by: Ingo Molnar <mingo@elte.hu>
Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
Diffstat (limited to 'arch/x86')
-rw-r--r-- | arch/x86/kernel/pci-dma_32.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/arch/x86/kernel/pci-dma_32.c b/arch/x86/kernel/pci-dma_32.c index 9199bccb9214..5ae3470113c6 100644 --- a/arch/x86/kernel/pci-dma_32.c +++ b/arch/x86/kernel/pci-dma_32.c | |||
@@ -80,6 +80,8 @@ void dma_free_coherent(struct device *dev, size_t size, | |||
80 | WARN_ON(irqs_disabled()); /* for portability */ | 80 | WARN_ON(irqs_disabled()); /* for portability */ |
81 | if (dma_release_coherent(dev, order, vaddr)) | 81 | if (dma_release_coherent(dev, order, vaddr)) |
82 | return; | 82 | return; |
83 | if (dma_ops->unmap_single) | ||
84 | dma_ops->unmap_single(dev, dma_handle, size, 0); | ||
83 | free_pages((unsigned long)vaddr, order); | 85 | free_pages((unsigned long)vaddr, order); |
84 | } | 86 | } |
85 | EXPORT_SYMBOL(dma_free_coherent); | 87 | EXPORT_SYMBOL(dma_free_coherent); |