x86:aperture_64: drop not needed checking
PATCH 1/1 x86:aperture_64: drop not needed checking
The memblock_find_in_range return value, addr, will make sure "addr + aper_size" not beyond GART_MAX_ADDR.
Signed-off-by Wang YanQing <[email protected]>
--- arch/x86/kernel/aperture_64.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
arch/x86/kernel/aperture_64.c +1 -1
@@ -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 );
Signature · 1 line
1.7.12.4.dirty
tip-bot for Wang YanQing
merge bot[tip:x86/mm] x86/mm/gart: Drop unnecessary check
x86/mm/gart: Drop unnecessary check
Commit-ID: 26bfc540f6f2dcbd93d0b9ed8f37830419ded7e8 Gitweb: http://git.kernel.org/tip/26bfc540f6f2dcbd93d0b9ed8f37830419ded7e8 Author: Wang YanQing <[email protected]> AuthorDate: Tue, 16 Apr 2013 09:37:34 +0800 Committer: Ingo Molnar <[email protected]> CommitDate: Tue, 16 Apr 2013 10:54:40 +0200
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 <[email protected]>
Signed-off-by Ingo Molnar <[email protected]>
--- arch/x86/kernel/aperture_64.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
arch/x86/kernel/aperture_64.c +1 -1
@@ -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 );