From 6164729d068500e873c982a3e1dc6dd606757f87 Mon Sep 17 00:00:00 2001 From: Liav A Date: Fri, 12 Aug 2022 08:37:23 +0300 Subject: [PATCH] Everywhere: Get rid of the fbdev kernel boot argument remainders --- .github/workflows/cmake.yml | 2 +- Base/usr/share/man/man7/boot_parameters.md | 2 +- Documentation/BareMetalInstallation.md | 3 +-- Documentation/NetworkBoot.md | 4 ++-- Documentation/RunningTests.md | 2 +- Kernel/CommandLine.cpp | 2 +- Meta/Azure/Serenity.yml | 2 +- Meta/export-argsparser-manpages.sh | 2 +- Meta/extlinux.conf | 2 +- Meta/grub-ebr.cfg | 2 +- Meta/grub-gpt.cfg | 2 +- Meta/grub-mbr.cfg | 2 +- Meta/limine.cfg | 2 +- Meta/serenity.sh | 2 +- 14 files changed, 15 insertions(+), 16 deletions(-) diff --git a/.github/workflows/cmake.yml b/.github/workflows/cmake.yml index bdad969019a..53eb64f8c12 100644 --- a/.github/workflows/cmake.yml +++ b/.github/workflows/cmake.yml @@ -191,7 +191,7 @@ jobs: working-directory: ${{ github.workspace }}/Build/${{ matrix.arch }} env: SERENITY_QEMU_CPU: "max,vmx=off" - SERENITY_KERNEL_CMDLINE: "fbdev=off panic=shutdown system_mode=self-test" + SERENITY_KERNEL_CMDLINE: "graphics_subsystem_mode=off panic=shutdown system_mode=self-test" SERENITY_RUN: "ci" run: | echo "::group::ninja run # Qemu output" diff --git a/Base/usr/share/man/man7/boot_parameters.md b/Base/usr/share/man/man7/boot_parameters.md index 4aa0a6d4f3d..e0466c125d6 100644 --- a/Base/usr/share/man/man7/boot_parameters.md +++ b/Base/usr/share/man/man7/boot_parameters.md @@ -81,7 +81,7 @@ has set up before booting the Kernel, don't initialize any driver. * **`system_mode`** - This parameter is not interpreted by the Kernel, and is made available at `/proc/system_mode`. SystemServer uses it to select the set of services that should be started. Common values are: - **`graphical`** (default) - Boots the system in the normal graphical mode. - **`self-test`** - Boots the system in self-test, validation mode. - - **`text`** - Boots the system in text only mode. (You may need to also set **`fbdev=off`**.) + - **`text`** - Boots the system in text only mode. (You may need to also set **`graphics_subsystem_mode=off`**.) * **`time`** - This parameter expects one of the following values. **`modern`** - This configures the system to attempt to use High Precision Event Timer (HPET) on boot. **`legacy`** - Configures the system to use the legacy programmable interrupt diff --git a/Documentation/BareMetalInstallation.md b/Documentation/BareMetalInstallation.md index e09e2f419d4..fba1c581f15 100644 --- a/Documentation/BareMetalInstallation.md +++ b/Documentation/BareMetalInstallation.md @@ -56,7 +56,6 @@ framebuffer with 8x8 font glyphs. You can force capable multiboot bootloaders to boot Serenity into high resolution mode by editing **Kernel/Arch/i386/Boot/boot.S** and adding **| MULTIBOOT_VIDEO_MODE** to the end of the **multiboot_flags** before building Serenity. -Setting a boot argument of `fbdev=off` will force the kernel to not initialize any framebuffer devices, hence allowing the system -to boot into console-only mode as `SystemServer` will detect this condition and will not initialize `WindowServer`. +Setting a boot argument of `graphics_subsystem_mode=limited` will force the kernel to not initialize any framebuffer devices, hence allowing the system to boot into console-only mode as `SystemServer` will detect this condition and will not initialize `WindowServer`. If you do not see any output, it's possible that the Kernel panics before any video is initialized. In that case, you might try debugging the init sequence with the PC speaker to see where it gets stuck. diff --git a/Documentation/NetworkBoot.md b/Documentation/NetworkBoot.md index b3777ba6002..9f16dd603b7 100644 --- a/Documentation/NetworkBoot.md +++ b/Documentation/NetworkBoot.md @@ -87,7 +87,7 @@ menuentry 'SerenityOS - netboot diskless text mode' { set gfxkeep=text terminal_output console echo 'Loading prekernel...' - multiboot (tftp)/serenity/prekernel root=/dev/ramdisk0 fbdev=off + multiboot (tftp)/serenity/prekernel root=/dev/ramdisk0 graphics_subsystem_mode=off echo 'Loading kernel...' module (tftp)/serenity/kernel echo 'Loading ramdisk...' @@ -179,7 +179,7 @@ For troubleshooting purposes, you can add the following command line arguments i - `disable_uhci_controller` Because iPXE (unlike GRUB) doesn't support VESA VBE modesetting when booting a multiboot kernel, -you might not see any output, so add the `fbdev=off` argument as well to boot into VGA text mode. +you might not see any output, so add the `graphics_subsystem_mode=off` argument as well to boot into VGA text mode. Afterwards you will need to enable the `console` iPXE command by uncommenting the following line in `src/config/general.h`: ```c diff --git a/Documentation/RunningTests.md b/Documentation/RunningTests.md index 3df54d0b6cb..18d3e258bc5 100644 --- a/Documentation/RunningTests.md +++ b/Documentation/RunningTests.md @@ -116,6 +116,6 @@ the default value `halt` keeps qemu around, which allows you to inspect the stat ```sh export SERENITY_RUN=ci -export SERENITY_KERNEL_CMDLINE="fbdev=off system_mode=self-test" +export SERENITY_KERNEL_CMDLINE="graphics_subsystem_mode=off system_mode=self-test" ninja run ``` diff --git a/Kernel/CommandLine.cpp b/Kernel/CommandLine.cpp index fec0e11c2a5..19f35ae1558 100644 --- a/Kernel/CommandLine.cpp +++ b/Kernel/CommandLine.cpp @@ -49,7 +49,7 @@ UNMAP_AFTER_INIT void CommandLine::initialize() // I know, we don't do legacy, but even though I eliminated 'boot_mode' from the codebase, there // is a good chance that someone's still using it. Let's be nice and tell them where to look. // TODO: Remove this in 2022. - PANIC("'boot_mode' is now split into panic=[halt|shutdown], fbdev=[on|off], and system_mode=[graphical|text|selftest]."); + PANIC("'boot_mode' is now split into panic=[halt|shutdown], graphics_subsystem_mode=[on|limited|off], and system_mode=[graphical|text|selftest]."); } } diff --git a/Meta/Azure/Serenity.yml b/Meta/Azure/Serenity.yml index 680d8a58ca7..5303a2cbe02 100644 --- a/Meta/Azure/Serenity.yml +++ b/Meta/Azure/Serenity.yml @@ -90,7 +90,7 @@ jobs: timeoutInMinutes: 60 env: SERENITY_QEMU_CPU: 'max,vmx=off' - SERENITY_KERNEL_CMDLINE: 'fbdev=off panic=shutdown system_mode=self-test' + SERENITY_KERNEL_CMDLINE: 'graphics_subsystem_mode=off panic=shutdown system_mode=self-test' SERENITY_RUN: 'ci' - script: | diff --git a/Meta/export-argsparser-manpages.sh b/Meta/export-argsparser-manpages.sh index e1f11f17ed3..791ce5ba752 100755 --- a/Meta/export-argsparser-manpages.sh +++ b/Meta/export-argsparser-manpages.sh @@ -49,7 +49,7 @@ fi echo "Using 'ninja run' to generate manpages ..." export SERENITY_RUN="ci" -export SERENITY_KERNEL_CMDLINE="fbdev=off panic=shutdown system_mode=generate-manpages" +export SERENITY_KERNEL_CMDLINE="graphics_subsystem_mode=off panic=shutdown system_mode=generate-manpages" # The 'sed' gets rid of the clear-screen escape sequence. ninja -C "$BUILD_DIR" -- run | sed -re 's,''c,,' echo diff --git a/Meta/extlinux.conf b/Meta/extlinux.conf index 3a2ed93ce74..855a5004957 100644 --- a/Meta/extlinux.conf +++ b/Meta/extlinux.conf @@ -13,7 +13,7 @@ LABEL SerenityOS LABEL SerenityOSText MENU LABEL SerenityOS (text mode) KERNEL mboot.c32 - APPEND ../Prekernel root=/dev/hda1 fbdev=off --- ../Kernel + APPEND ../Prekernel root=/dev/hda1 graphics_subsystem_mode=off --- ../Kernel LABEL SerenityOSNoACPI MENU LABEL SerenityOS (No ACPI) diff --git a/Meta/grub-ebr.cfg b/Meta/grub-ebr.cfg index d70e838c157..ce3f0e6de47 100644 --- a/Meta/grub-ebr.cfg +++ b/Meta/grub-ebr.cfg @@ -8,7 +8,7 @@ menuentry 'SerenityOS (normal)' { menuentry 'SerenityOS (text mode)' { root=hd0,5 - multiboot /boot/Prekernel fbdev=off root=/dev/hda4 + multiboot /boot/Prekernel graphics_subsystem_mode=off root=/dev/hda4 module /boot/Kernel } diff --git a/Meta/grub-gpt.cfg b/Meta/grub-gpt.cfg index c46256a85fc..84542255573 100644 --- a/Meta/grub-gpt.cfg +++ b/Meta/grub-gpt.cfg @@ -8,7 +8,7 @@ menuentry 'SerenityOS (normal)' { menuentry 'SerenityOS (text mode)' { root=hd0,2 - multiboot /boot/Prekernel fbdev=off root=/dev/hda2 + multiboot /boot/Prekernel graphics_subsystem_mode=off root=/dev/hda2 module /boot/Kernel } diff --git a/Meta/grub-mbr.cfg b/Meta/grub-mbr.cfg index 05e83598796..3d221e24b4c 100644 --- a/Meta/grub-mbr.cfg +++ b/Meta/grub-mbr.cfg @@ -8,7 +8,7 @@ menuentry 'SerenityOS (normal)' { menuentry 'SerenityOS (text mode)' { root=hd0,1 - multiboot /boot/Prekernel fbdev=off root=/dev/hda1 + multiboot /boot/Prekernel graphics_subsystem_mode=off root=/dev/hda1 module /boot/Kernel } diff --git a/Meta/limine.cfg b/Meta/limine.cfg index afe4f308d8e..bca48838feb 100644 --- a/Meta/limine.cfg +++ b/Meta/limine.cfg @@ -8,7 +8,7 @@ MODULE_PATH=boot://2/boot/Kernel :SerenityOS (text mode) PROTOCOL=multiboot1 -CMDLINE=fbdev=off root=/dev/hda2 +CMDLINE=graphics_subsystem_mode=off root=/dev/hda2 KERNEL_PATH=boot://2/boot/Prekernel MODULE_PATH=boot://2/boot/Kernel diff --git a/Meta/serenity.sh b/Meta/serenity.sh index 522cb24bff4..6bd7166f1ed 100755 --- a/Meta/serenity.sh +++ b/Meta/serenity.sh @@ -433,7 +433,7 @@ if [[ "$CMD" =~ ^(build|install|image|copy-src|run|gdb|test|rebuild|recreate|kad build_image # In contrast to CI, we don't set 'panic=shutdown' here, # in case the user wants to inspect qemu some more. - export SERENITY_KERNEL_CMDLINE="fbdev=off system_mode=self-test" + export SERENITY_KERNEL_CMDLINE="graphics_subsystem_mode=off system_mode=self-test" export SERENITY_RUN="ci" build_target run fi