qemu-x86_64: cleanup device description
{ config, lib, pkgs, ... }:
-let
- # This device description is a bit configurable through
- # mobile options...
-
- # Enabling the splash changes some settings.
- splash = config.mobile.boot.stage-1.splash.enable;
-
- kernel = pkgs.linuxPackages_5_4.kernel;
-
- modules = [
- # Disk images
- "ata_piix"
- "sd_mod"
-
- # Networking
- "e1000"
-
- # Keyboard
- "hid_generic"
- "pcips2" "atkbd" "i8042"
-
- # Mouse
- "mousedev"
-
- # Input within X11
- "uinput" "evdev"
-
- # USB
- "usbcore" "usbhid" "ehci_pci" "ehci_hcd"
-
- # x86 RTC needed by the stage 2 init script.
- "rtc_cmos"
-
- # Video
- "bochs_drm"
- ];
-in
{
mobile.device.name = "qemu-x86_64";
mobile.device.identity = {
@@ -46,7 +9,7 @@ in
mobile.device.info = {
# TODO : make kernel part of options.
- inherit kernel;
+ kernel = pkgs.linuxPackages_5_4.kernel;
};
mobile.hardware = {
@@ -68,10 +31,37 @@ in
];
mobile.system.type = "qemu-startscript";
+
mobile.boot.stage-1 = {
kernel = {
modular = true;
- inherit modules;
+ modules = [
+ # Disk images
+ "ata_piix"
+ "sd_mod"
+
+ # Networking
+ "e1000"
+
+ # Keyboard
+ "hid_generic"
+ "pcips2" "atkbd" "i8042"
+
+ # Mouse
+ "mousedev"
+
+ # Input within X11
+ "uinput" "evdev"
+
+ # USB
+ "usbcore" "usbhid" "ehci_pci" "ehci_hcd"
+
+ # x86 RTC needed by the stage 2 init script.
+ "rtc_cmos"
+
+ # Video
+ "bochs_drm"
+ ];
};
};
}
