From: Linus Torvalds Date: Mon, 23 May 2011 04:37:01 +0000 (-0700) Subject: x86: setup_smep needs to be __cpuinit X-Git-Tag: v3.0-rc1~360 X-Git-Url: http://git.openpandora.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=82da65dab5f438ac7df28eeb43e2f5b742aa00ef;p=pandora-kernel.git x86: setup_smep needs to be __cpuinit The setup_smep function gets calle at resume time too, and is thus not a pure __init function. When marked as __init, it gets thrown out after the kernel has initialized, and when the kernel is suspended and resumed, the code will no longer be around, and we'll get a nice "kernel tried to execute NX-protected page" oops because the page is no longer marked executable. Reported-and-tested-by: Parag Warudkar Cc: Fenghua Yu Cc: "H. Peter Anvin" Cc: Ingo Molnar Signed-off-by: Linus Torvalds --- Reading git-diff-tree failed