Re: Using module private memory to simulate microkernel's memoryprotection

From: Ingo Molnar
Date: Tue Feb 10 2009 - 09:14:27 EST



* Pengfei Hu <hpfei.cn@xxxxxxxxx> wrote:

> diff -Nurp old/arch/x86/Kconfig.debug new/arch/x86/Kconfig.debug
> --- old/arch/x86/Kconfig.debug 2008-10-10 06:13:53.000000000 +0800
> +++ new/arch/x86/Kconfig.debug 2008-12-07 19:19:40.000000000 +0800
> @@ -67,6 +67,16 @@ config DEBUG_PAGEALLOC
> This results in a large slowdown, but helps to find certain types
> of memory corruptions.
>
> +config DEBUG_KM_PROTECT
> + bool "Debug kernel memory protect"
> + depends on DEBUG_KERNEL
> + select DEBUG_PAGEALLOC
> + select SLUB
> + help
> + Change page table's present flag to prevent other module's accidental
> + access. This results in a large slowdown and waste more memory, but
> + helps to find certain types of memory corruptions.

Hm, are you aware of the kmemcheck project?

Ingo
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/