]> git.karo-electronics.de Git - karo-tx-linux.git/commit
mtrr, x86: remove a wrong address check in __mtrr_type_lookup()
authorToshi Kani <toshi.kani@hp.com>
Tue, 7 Apr 2015 23:57:07 +0000 (09:57 +1000)
committerStephen Rothwell <sfr@canb.auug.org.au>
Thu, 9 Apr 2015 09:07:13 +0000 (19:07 +1000)
commit0074b7df5f3583976f8a14fd0cf2a9c0bfbdd482
tree33c743b26e01c7e6f5544318f6c6bd4ff7ae4b61
parent67d7dc076d1e14724d3d8b5e31298fef8220542f
mtrr, x86: remove a wrong address check in __mtrr_type_lookup()

__mtrr_type_lookup() checks MTRR fixed ranges when mtrr_state.have_fixed
is set and start is less than 0x100000.  However, the 'else if (start <
0x1000000)' in the code checks with a wrong address as it has an
extra-zero in the address.  The code still runs correctly as this check is
meaningless, though.

This patch replaces the wrong address check with 'else' with no condition.

Signed-off-by: Toshi Kani <toshi.kani@hp.com>
Cc: Dave Hansen <dave.hansen@intel.com>
Cc: Robert Elliott <Elliott@hp.com>
Cc: Paul Bolle <pebolle@tiscali.nl>
Cc: "H. Peter Anvin" <hpa@zytor.com>
Cc: Thomas Gleixner <tglx@linutronix.de>
Cc: Ingo Molnar <mingo@redhat.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
arch/x86/kernel/cpu/mtrr/generic.c