summaryrefslogtreecommitdiffstats
path: root/mdk-stage1/stage1.c
diff options
context:
space:
mode:
authorColin Guthrie <colin@mageia.org>2013-10-28 23:35:35 +0000
committerColin Guthrie <colin@mageia.org>2013-10-29 20:29:08 +0000
commit33a891128a5ac6fa2c581ef4106fe569f47eb867 (patch)
tree7cbc7f1ba8f9674b5244010bf2fde0b1db2645c6 /mdk-stage1/stage1.c
parent065557f6287bd87a4e52bea28db5a0b9c4a98b76 (diff)
downloaddrakx-33a891128a5ac6fa2c581ef4106fe569f47eb867.tar
drakx-33a891128a5ac6fa2c581ef4106fe569f47eb867.tar.gz
drakx-33a891128a5ac6fa2c581ef4106fe569f47eb867.tar.bz2
drakx-33a891128a5ac6fa2c581ef4106fe569f47eb867.tar.xz
drakx-33a891128a5ac6fa2c581ef4106fe569f47eb867.zip
stage1: Switch to a new mode of knowing when to re-exec init.
Now that dracut runs stage1 earlier, we need to store it's exit code for later reuse. In this, the separate dracut module will just write a flag file in /run/drakx/ to indicate that we want to re-exec /sbin/init (after doing some symlinks and /usr bind mount) rather than run the install. As a result there is no need to return 0x35 ('procced') so just return 0 and keep 0x35 return code for when we really do need to restart stage1 (e.g. on a fatal error). The dracut module should loop if 0x35 is ever returned.
Diffstat (limited to 'mdk-stage1/stage1.c')
-rw-r--r--mdk-stage1/stage1.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/mdk-stage1/stage1.c b/mdk-stage1/stage1.c
index 4439b7d37..94bb1e0df 100644
--- a/mdk-stage1/stage1.c
+++ b/mdk-stage1/stage1.c
@@ -437,7 +437,7 @@ int main(int argc __attribute__ ((unused)), char **argv __attribute__ ((unused))
if (IS_RESCUE)
return 66; /* ask init to exec new init */
- else
- return 0x35; /* ask init to run stage2 binary */
+
+ return 0;
#endif
}