]> git.baikalelectronics.ru Git - kernel.git/commit
Ensure that kernel_init_freeable() is not inlined into non __init code
authorVineet Gupta <Vineet.Gupta1@synopsys.com>
Fri, 21 Dec 2012 06:55:44 +0000 (12:25 +0530)
committerAl Viro <viro@zeniv.linux.org.uk>
Wed, 26 Dec 2012 06:14:12 +0000 (01:14 -0500)
commit3b1c80cf1f944d38b55b597fe35c58b7df67ad68
treea226468f666012471d9a43a8f48c9588a3fd43b3
parenta2e69c3c0f994da1cd5fbfdb8a9cfdb38b9f1ed5
Ensure that kernel_init_freeable() is not inlined into non __init code

Commit 719f4d319ec "make sure that we always have a return path from
kernel_execve()" reshuffled kernel_init()/init_post() to ensure that
kernel_execve() has a caller to return to.

It removed __init annotation for kernel_init() and introduced/calls a
new routine kernel_init_freeable(). Latter however is inlined by any
reasonable compiler (ARC gcc 4.4 in this case), causing slight code
bloat.

This patch forces kernel_init_freeable() as noinline reducing the .text

bloat-o-meter vmlinux vmlinux_new
add/remove: 1/0 grow/shrink: 0/1 up/down: 374/-334 (40)
function                        old     new   delta
kernel_init_freeable              -     374    +374 (.init.text)
kernel_init                     628     294    -334 (.text)

Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
init/main.c