]> git.karo-electronics.de Git - karo-tx-linux.git/commit
Replace the bubble sort in sanitize_e820_map() with a call to the generic
authorMike Ditto <mditto@google.com>
Tue, 26 Jul 2011 10:14:39 +0000 (20:14 +1000)
committerStephen Rothwell <sfr@canb.auug.org.au>
Thu, 28 Jul 2011 02:56:24 +0000 (12:56 +1000)
commit8aa00b92ebbce4a582cc7338392a6499e01e0a6d
treef9ba3ea19bb572ec00192181a66e6544b6caeeeb
parent2ef18c0887f9e98e0dae031e2b1d97efc562b6c2
Replace the bubble sort in sanitize_e820_map() with a call to the generic
kernel sort function to avoid pathological performance with large maps.

On large (thousands of entries) E820 maps, the previous code took minutes
to run; with this change it's now milliseconds.

Signed-off-by: Mike Ditto <mditto@google.com>
Cc: Stefan Assmann <sassmann@kpanic.de>
Cc: Nancy Yuen <yuenn@google.com>
Cc: Ingo Molnar <mingo@elte.hu>
Cc: Thomas Gleixner <tglx@linutronix.de>
Cc: "H. Peter Anvin" <hpa@zytor.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
arch/x86/kernel/e820.c