Skip to content

Commit

Permalink
dbgutil+limine: fix booting under QEMU with new limine version
Browse files Browse the repository at this point in the history
  • Loading branch information
Qix- committed Jan 17, 2025
1 parent f6a6fd1 commit 2901e69
Show file tree
Hide file tree
Showing 4 changed files with 26 additions and 17 deletions.
2 changes: 1 addition & 1 deletion dbgutil/oro_debug_suite/bootstrap/limine.py
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
from . import get_site_packages_dir

LIMINE_GIT_URL = "https://github.com/oro-os/limine.git"
LIMINE_REF = "v7.0.3-binary"
LIMINE_REF = "v8.7.0-binary"


def fetch_limine():
Expand Down
37 changes: 22 additions & 15 deletions dbgutil/oro_debug_suite/cmd/boot.py
Original file line number Diff line number Diff line change
Expand Up @@ -341,24 +341,25 @@ def copyfile(src, dst):
copy_limine("limine-bios-cd.bin")
copy_limine("limine-bios.sys")

module_config = "\n".join([f"MODULE_PATH=boot:///{k}" for (k, _) in modules])
module_config = "\n".join([f"module_path: boot():/{k}" for (k, _) in modules])

with open(path.join(iso_dir, "limine.cfg"), "w") as f:
with open(path.join(iso_dir, "limine.conf"), "w") as f:
f.write(
f"""
TIMEOUT=0
GRAPHICS=no
VERBOSE=yes
RANDOMISE_MEMORY=no
INTERFACE_BRANDING=Oro Operating System
INTERFACE_BRANDING_COLOR=5
SERIAL=yes
KASLR=no
:Oro Operating System
PROTOCOL=limine
KERNEL_PATH=boot:///oro-limine
SERIAL=yes
timeout: 0
quiet: no
graphics: yes
verbose: yes
randomise_memory: no
interface_branding: Oro Operating System
interface_branding_color: 5
serial: yes
/Oro Operating System
protocol: limine
path: boot():/oro-limine
serial: yes
kasler: no
{module_config}
"""
)
Expand All @@ -384,12 +385,18 @@ def copyfile(src, dst):
"xorriso",
"-as",
"mkisofs",
"-r",
"-R",
"-J",
"-b",
"limine-bios-cd.bin",
"-no-emul-boot",
"-boot-load-size",
"4",
"-boot-info-table",
"-hfsplus",
"-apm-block-size",
"2048",
"--efi-boot",
"limine-uefi-cd.bin",
"-efi-boot-part",
Expand Down
2 changes: 2 additions & 0 deletions oro-arch-x86_64/src/boot/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -120,8 +120,10 @@ pub unsafe fn boot_primary() -> ! {
dbg!("local APIC ID: {lapic_id}");

{
#[doc(hidden)]
#[cfg(not(feature = "force-singlecore"))]
const MULTICORE_ENABLED: bool = true;
#[doc(hidden)]
#[cfg(feature = "force-singlecore")]
const MULTICORE_ENABLED: bool = false;

Expand Down
2 changes: 1 addition & 1 deletion oro-bootloader-limine/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ const KERNEL_STACK_PAGES: usize = 16;
/// The path to where the Oro kernel is expected.
/// The bootloader does **not** expect it to be listed
/// as a module (but it can be).
const KERNEL_PATH: &CStr = limine::cstr!("/boot/oro-kernel");
const KERNEL_PATH: &CStr = limine::cstr!("/oro-kernel");

/// The path to where the DeviceTree blob is expected,
/// if provided. The bootloader does **not** expect it to be
Expand Down

0 comments on commit 2901e69

Please sign in to comment.