summaryrefslogtreecommitdiff
path: root/init
diff options
context:
space:
mode:
authorAndré Fabian Silva Delgado <emulatorman@parabola.nu>2016-03-26 05:33:09 -0300
committerAndré Fabian Silva Delgado <emulatorman@parabola.nu>2016-03-26 05:33:09 -0300
commit4a327fcef90ba27150a3e8741441b68c605ae248 (patch)
treededef84cccbd02054df4cfb844dd3c9d588edf83 /init
parenta156245300d5362a3b4c4afdace9e2b90169fe43 (diff)
Add TuxOnIce support adapted for the 4.5-gnu kernel versionpck-4.5-gnu
Diffstat (limited to 'init')
-rw-r--r--init/do_mounts.c2
-rw-r--r--init/do_mounts_initrd.c6
2 files changed, 8 insertions, 0 deletions
diff --git a/init/do_mounts.c b/init/do_mounts.c
index dea5de95c..1fed72621 100644
--- a/init/do_mounts.c
+++ b/init/do_mounts.c
@@ -597,6 +597,8 @@ void __init prepare_namespace(void)
if (is_floppy && rd_doload && rd_load_disk(0))
ROOT_DEV = Root_RAM0;
+ check_resume_attempted();
+
mount_root();
out:
devtmpfs_mount("dev");
diff --git a/init/do_mounts_initrd.c b/init/do_mounts_initrd.c
index a1000ca29..56b5a0c8a 100644
--- a/init/do_mounts_initrd.c
+++ b/init/do_mounts_initrd.c
@@ -15,6 +15,7 @@
#include <linux/romfs_fs.h>
#include <linux/initrd.h>
#include <linux/sched.h>
+#include <linux/suspend.h>
#include <linux/freezer.h>
#include <linux/kmod.h>
@@ -79,6 +80,11 @@ static void __init handle_initrd(void)
current->flags &= ~PF_FREEZER_SKIP;
+ if (!resume_attempted)
+ printk(KERN_ERR "TuxOnIce: No attempt was made to resume from "
+ "any image that might exist.\n");
+ clear_toi_state(TOI_BOOT_TIME);
+
/* move initrd to rootfs' /old */
sys_mount("..", ".", NULL, MS_MOVE, NULL);
/* switch root and cwd back to / of rootfs */