diff options
author | Catalin Marinas <catalin.marinas@arm.com> | 2009-08-27 14:29:20 +0100 |
---|---|---|
committer | Catalin Marinas <catalin.marinas@arm.com> | 2009-09-01 11:12:32 +0100 |
commit | acde31dc467797ccae3a55b791a77af446cce018 (patch) | |
tree | ef7a46bef9485830cc8f104889def098e1604eb7 /arch/x86/kernel/pci-dma.c | |
parent | 0494e08281d08f0a3dc442eb5e5cecc125b53b27 (diff) | |
download | kernel_goldelico_gta04-acde31dc467797ccae3a55b791a77af446cce018.zip kernel_goldelico_gta04-acde31dc467797ccae3a55b791a77af446cce018.tar.gz kernel_goldelico_gta04-acde31dc467797ccae3a55b791a77af446cce018.tar.bz2 |
kmemleak: Ignore the aperture memory hole on x86_64
This block is allocated with alloc_bootmem() and scanned by kmemleak but
the kernel direct mapping may no longer exist. This patch tells kmemleak
to ignore this memory hole. The dma32_bootmem_ptr in
dma32_reserve_bootmem() is also ignored.
Signed-off-by: Catalin Marinas <catalin.marinas@arm.com>
Acked-by: Ingo Molnar <mingo@elte.hu>
Diffstat (limited to 'arch/x86/kernel/pci-dma.c')
-rw-r--r-- | arch/x86/kernel/pci-dma.c | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/arch/x86/kernel/pci-dma.c b/arch/x86/kernel/pci-dma.c index 1a041bc..fa80f60 100644 --- a/arch/x86/kernel/pci-dma.c +++ b/arch/x86/kernel/pci-dma.c @@ -3,6 +3,7 @@ #include <linux/dmar.h> #include <linux/bootmem.h> #include <linux/pci.h> +#include <linux/kmemleak.h> #include <asm/proto.h> #include <asm/dma.h> @@ -88,6 +89,11 @@ void __init dma32_reserve_bootmem(void) size = roundup(dma32_bootmem_size, align); dma32_bootmem_ptr = __alloc_bootmem_nopanic(size, align, 512ULL<<20); + /* + * Kmemleak should not scan this block as it may not be mapped via the + * kernel direct mapping. + */ + kmemleak_ignore(dma32_bootmem_ptr); if (dma32_bootmem_ptr) dma32_bootmem_size = size; else |