From 67343548a71702d5133832d85453074af141f4d5 Mon Sep 17 00:00:00 2001 From: Kevin Lange Date: Wed, 14 Dec 2011 22:30:46 -0600 Subject: [PATCH] Only mount hard disk if requested --- Makefile | 2 +- kernel/main.c | 3 --- kernel/misc/args.c | 3 +++ 3 files changed, 4 insertions(+), 4 deletions(-) diff --git a/Makefile b/Makefile index 41cbd719..26a34513 100644 --- a/Makefile +++ b/Makefile @@ -36,7 +36,7 @@ ERRORSS = >>/tmp/.build-errors || util/mk-error BEGRM = util/mk-beg-rm ENDRM = util/mk-end-rm -EMUARGS = -kernel toaruos-kernel -initrd toaruos-initrd -append "vid=qemu wallpaper=/usr/share/wallpaper.bmp" -serial stdio -vga std -hda toaruos-disk.img +EMUARGS = -kernel toaruos-kernel -initrd toaruos-initrd -append "vid=qemu hdd wallpaper=/usr/share/wallpaper.bmp" -serial stdio -vga std -hda toaruos-disk.img EMUKVM = -enable-kvm .PHONY: all check-toolchain system clean clean-once clean-hard clean-soft clean-docs clean-bin clean-aux clean-core clean-boot install run docs utils diff --git a/kernel/main.c b/kernel/main.c index 55fad04c..1ed26c3b 100644 --- a/kernel/main.c +++ b/kernel/main.c @@ -142,9 +142,6 @@ int main(struct multiboot *mboot, uint32_t mboot_mag, uintptr_t esp) mouse_install(); /* Mouse driver */ - extern void ext2_disk_mount(void); - ext2_disk_mount(); - if (boot_mode == multiboot) { /* Parse the command-line arguments */ parse_args((char *)mboot_ptr->cmdline); diff --git a/kernel/misc/args.c b/kernel/misc/args.c index 253174a3..8a7cc93d 100644 --- a/kernel/misc/args.c +++ b/kernel/misc/args.c @@ -65,6 +65,9 @@ parse_args( } else if (!strcmp(argp[0],"wallpaper")) { if (argc < 2) { kprintf("wallpaper=?\n"); continue; } bochs_install_wallpaper(argp[1]); + } else if (!strcmp(argp[0],"hdd")) { + extern void ext2_disk_mount(void); + ext2_disk_mount(); } } }