feat(gui): Enable direct boot to GUI Desktop with emergency kernel TTY fallback

- Integrate Bochs/QEMU VBE physical LFB mapping directly to hardware video memory (0xFD000000)
- Update kernel boot sequence to directly boot into GUI Desktop by default
- Fall back to Emergency Kernel TTY Mode upon GUI exit (Esc key / Exit menu item)
- Support 'nogui', 'text', 'emergency', and 'single' boot arguments to boot directly into text mode
- Remove frame limits so GUI runs persistently
This commit is contained in:
subhobhai943 committed 2026-08-21 03:08:31 +05:30
1 parent 81a17aae37
commit 56d8b3af1a
5 files changed
+75 -49

No files matched your search

+15 -1
View File
@@ -66,6 +66,8 @@
#include <drivers/virtio_gpu.h>
#include <drivers/cpufreq.h>
#include <drivers/virtio_input.h>
#include <gui/gui.h>
#include <init/init.h>
#include <kernel/rust.h>
#include <kernel/sub_lang.h>
#include <kernel/cpp_kernel.h>
@@ -216,7 +218,19 @@ static void subos_modular_core_boot(void) {
arch_enable_interrupts();
printk(ANSI_BRIGHT_GREEN "ACTIVE\n" ANSI_RESET);
// Launch Shell
// Boot directly into GUI Desktop unless emergency text mode is requested
bool emergency_text = init_has_param("nogui") || init_has_param("text") ||
init_has_param("emergency") || init_has_param("single");
if (!emergency_text) {
printk(KERN_INFO "INIT: Booting directly into SUB-OS Graphical Desktop Environment...\n");
gui_start_desktop();
printk(KERN_INFO "INIT: GUI session closed. Entering Emergency Kernel TTY Mode.\n");
} else {
printk(KERN_INFO "INIT: Emergency text/kernel TTY mode requested via boot parameters.\n");
}
// Launch Shell (Emergency TTY Mode)
shell_run();
while (1) {