projects
/
GitHub
/
MotorolaMobilityLLC
/
kernel-slsi.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
13d9fea
)
AMD IOMMU: replace memset with __GFP_ZERO in alloc_coherent
author
Joerg Roedel
<joerg.roedel@amd.com>
Thu, 11 Sep 2008 08:59:15 +0000
(10:59 +0200)
committer
Ingo Molnar
<mingo@elte.hu>
Fri, 19 Sep 2008 10:59:25 +0000
(12:59 +0200)
Remove the memset and use __GFP_ZERO at allocation time instead.
Signed-off-by: Joerg Roedel <joerg.roedel@amd.com>
Signed-off-by: Ingo Molnar <mingo@elte.hu>
arch/x86/kernel/amd_iommu.c
patch
|
blob
|
blame
|
history
diff --git
a/arch/x86/kernel/amd_iommu.c
b/arch/x86/kernel/amd_iommu.c
index e4866660463ec3fd475cd2cf39720210d54877b9..f405a61f61fc758fe8b63f8de54fb29e77005a40 100644
(file)
--- a/
arch/x86/kernel/amd_iommu.c
+++ b/
arch/x86/kernel/amd_iommu.c
@@
-1176,11
+1176,11
@@
static void *alloc_coherent(struct device *dev, size_t size,
if (!get_device_resources(dev, &iommu, &domain, &devid))
flag &= ~(__GFP_DMA | __GFP_HIGHMEM | __GFP_DMA32);
+ flag |= __GFP_ZERO;
virt_addr = (void *)__get_free_pages(flag, get_order(size));
if (!virt_addr)
return 0;
- memset(virt_addr, 0, size);
paddr = virt_to_phys(virt_addr);
if (!iommu || !domain) {