aboutsummaryrefslogtreecommitdiffstats
path: root/block/genhd.c
diff options
context:
space:
mode:
authorLinus Torvalds <torvalds@linux-foundation.org>2008-08-25 14:10:26 -0400
committerLinus Torvalds <torvalds@linux-foundation.org>2008-08-25 14:10:26 -0400
commitffb4ba76a25ab6c9deeec33e4f58395586ca747c (patch)
tree378ee35adc486466c88c7423dbb0ecc6f027ef45 /block/genhd.c
parent83097aca8567a0bd593534853b71fe0fa9a75d69 (diff)
[module] Don't let gcc inline load_module()
'load_module()' is a complex function that contains all the ELF section logic, and inlining it is utterly insane. But gcc will do it, simply because there is only one call-site. As a result, all the stack space that is allocated for all the work to load the module will still be active when we actually call the module init sequence, and the deep call chain makes stack overflows happen. And stack overflows are really hard to debug, because they not only corrupt random pages below the stack, but also corrupt the thread_info structure that is allocated under the stack. In this case, Alan Brunelle reported some crazy oopses at bootup, after loading the processor module that ends up doing complex ACPI stuff and has quite a deep callchain. This should fix it, and is the sane thing to do regardless. Cc: Alan D. Brunelle <Alan.Brunelle@hp.com> Cc: Arjan van de Ven <arjan@linux.intel.com> Cc: Rusty Russell <rusty@rustcorp.com.au> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'block/genhd.c')
0 files changed, 0 insertions, 0 deletions