aboutsummaryrefslogtreecommitdiffstats
path: root/arch/x86/kernel/aperture_64.c
diff options
context:
space:
mode:
authorWang YanQing <udknight@gmail.com>2013-04-16 09:37:34 +0800
committerIngo Molnar <mingo@kernel.org>2013-04-16 10:54:40 +0200
commit26bfc540f6f2dcbd93d0b9ed8f37830419ded7e8 (patch)
treea5ede83d7c2eb4b572d19ca12d56ae2ef226cc77 /arch/x86/kernel/aperture_64.c
parentx86/mm/hotplug: Put kernel_physical_mapping_remove() declaration in CONFIG_MEMORY_HOTREMOVE (diff)
downloadlinux-dev-26bfc540f6f2dcbd93d0b9ed8f37830419ded7e8.tar.xz
linux-dev-26bfc540f6f2dcbd93d0b9ed8f37830419ded7e8.zip
x86/mm/gart: Drop unnecessary check
The memblock_find_in_range() return value addr is guaranteed to be within "addr + aper_size" and not beyond GART_MAX_ADDR. Signed-off-by: Wang YanQing <udknight@gmail.com> Cc: yinghai@kernel.org Link: http://lkml.kernel.org/r/20130416013734.GA14641@udknight Signed-off-by: Ingo Molnar <mingo@kernel.org>
Diffstat (limited to 'arch/x86/kernel/aperture_64.c')
-rw-r--r--arch/x86/kernel/aperture_64.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/arch/x86/kernel/aperture_64.c b/arch/x86/kernel/aperture_64.c
index d5fd66f0d4cd..fd972a3e4cbb 100644
--- a/arch/x86/kernel/aperture_64.c
+++ b/arch/x86/kernel/aperture_64.c
@@ -87,7 +87,7 @@ static u32 __init allocate_aperture(void)
*/
addr = memblock_find_in_range(GART_MIN_ADDR, GART_MAX_ADDR,
aper_size, aper_size);
- if (!addr || addr + aper_size > GART_MAX_ADDR) {
+ if (!addr) {
printk(KERN_ERR
"Cannot allocate aperture memory hole (%lx,%uK)\n",
addr, aper_size>>10);