Script 'mail_helper' called by obssrc Hello community, here is the log from the commit of package limine for openSUSE:Factory checked in at 2026-04-10 23:45:02 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Comparing /work/SRC/openSUSE:Factory/limine (Old) and /work/SRC/openSUSE:Factory/.limine.new.21863 (New) ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Package is "limine" Fri Apr 10 23:45:02 2026 rev:39 rq:1345939 version:11.3.1 Changes: -------- --- /work/SRC/openSUSE:Factory/limine/limine.changes 2026-04-04 19:08:58.200944470 +0200 +++ /work/SRC/openSUSE:Factory/.limine.new.21863/limine.changes 2026-04-10 23:45:11.888027664 +0200 @@ -1,0 +2,21 @@ +Fri Apr 10 18:22:39 UTC 2026 - Marvin Friedrich <[email protected]> + +- Update to 11.3.1: + * Implement "TSC Frequency" feature of the Limine boot protocol. + * Add PIT-based TSC calibration for BIOS. + * Do not clear framebuffer in quiet mode. + * Make "Keep IOMMU" Limine boot protocol feature x86-64-only. + * Do not clear framebuffer on modeset as Flanterm immediately repaints + it, wasting time. + * Allow menu recovery on overflow panics in the multiboot protocols. + * Significantly improve TSC calibration accuracy. + * Do not force-start uninitialised GOP outputs if a framebuffer is + * already available, for compatibility with quirky firmwares (Apple + Macs). + * Call Apple set_os protocol on UEFI to try to keep iGPU alive on + dual-GPU Apple Macs. + * Migrated to GitHub alongside with several subprojects. + * Build limine.exe using i486 MinGW from osdev0/mingw-binary-builds + in binary builds for better compatibility. + +------------------------------------------------------------------- Old: ---- limine-11.2.0.tar.gz New: ---- limine-11.3.1.tar.gz ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Other differences: ------------------ ++++++ limine.spec ++++++ --- /var/tmp/diff_new_pack.yzOR3X/_old 2026-04-10 23:45:12.716061728 +0200 +++ /var/tmp/diff_new_pack.yzOR3X/_new 2026-04-10 23:45:12.720061892 +0200 @@ -15,12 +15,12 @@ # Name: limine -Version: 11.2.0 +Version: 11.3.1 Release: 0 Summary: Modern, advanced, portable, multiprotocol bootloader and boot manager License: BSD-2-Clause Group: System/Boot -URL: https://codeberg.org/limine/limine +URL: https://github.com/Limine-Bootloader/Limine Source: %{url}/releases/download/v%{version}/%{name}-%{version}.tar.gz BuildRequires: make BuildRequires: autoconf ++++++ limine-11.2.0.tar.gz -> limine-11.3.1.tar.gz ++++++ diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/limine-11.2.0/3RDPARTY.md new/limine-11.3.1/3RDPARTY.md --- old/limine-11.2.0/3RDPARTY.md 2026-04-02 23:32:53.000000000 +0200 +++ new/limine-11.3.1/3RDPARTY.md 2026-04-09 13:44:49.000000000 +0200 @@ -19,18 +19,18 @@ A non-binding, informal summary of all projects Limine depends on, and the licenses used by said projects, in SPDX format, is as follows: -- [cc-runtime](https://codeberg.org/OSDev/cc-runtime) +- [cc-runtime](https://github.com/osdev0/cc-runtime) (Apache-2.0 WITH LLVM-exception) is used to provide runtime libgcc-like routines. -- [0BSD Freestanding C Headers](https://codeberg.org/OSDev/freestnd-c-hdrs-0bsd) +- [0BSD Freestanding C Headers](https://github.com/osdev0/freestnd-c-hdrs-0bsd) (0BSD) provide GCC and Clang compatible freestanding C headers. -- [Limine Boot Protocol](https://codeberg.org/Limine/limine-protocol) +- [Limine Boot Protocol](https://github.com/Limine-Bootloader/limine-protocol) (0BSD) has the C/C++ header and the specification text of the Limine Boot Protocol. -- [PicoEFI](https://codeberg.org/PicoEFI/PicoEFI) (multiple licenses, see list +- [PicoEFI](https://github.com/PicoEFI/PicoEFI) (multiple licenses, see list below) provides headers and build-time support for UEFI. - BSD-2-Clause - BSD-2-Clause-Patent @@ -52,13 +52,13 @@ - [tinf](https://github.com/jibsen/tinf) (Zlib) is used in early x86 BIOS stages for GZIP decompression of stage2. -- [Flanterm](https://codeberg.org/Mintsuki/Flanterm) (BSD-2-Clause) is used for +- [Flanterm](https://github.com/Mintsuki/Flanterm) (BSD-2-Clause) is used for text related screen drawing. - [stb_image](https://github.com/nothings/stb/blob/master/stb_image.h) (MIT) is used for wallpaper image loading. -- [libfdt](https://codeberg.org/OSDev/libfdt) (BSD-2-Clause) is used for +- [libfdt](https://github.com/osdev0/libfdt) (BSD-2-Clause) is used for manipulating Flat Device Trees. Note that some of these projects, or parts of them, are provided under diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/limine-11.2.0/CONFIG.md new/limine-11.3.1/CONFIG.md --- old/limine-11.2.0/CONFIG.md 2026-04-02 23:32:53.000000000 +0200 +++ new/limine-11.3.1/CONFIG.md 2026-04-09 13:44:49.000000000 +0200 @@ -115,8 +115,7 @@ Limine, this will only randomise memory below 4GiB. * `randomize_memory` - Alias of `randomise_memory`. * `hash_mismatch_panic` - If set to `no`, do not panic if there is a hash - mismatch for a file, but print a warning instead. Forced to `yes` when - Secure Boot is active. + mismatch for a file, but print a warning instead. Limine interface control options: @@ -196,8 +195,7 @@ Editor control options: * `editor_enabled` - If set to `no`, the editor will not be accessible. - Defaults to `yes` unless a config hash is enrolled. Unconditionally - disabled when Secure Boot is active. + Defaults to `yes` unless a config hash is enrolled. * `editor_highlighting` - If set to `no`, syntax highlighting in the editor will be disabled. Defaults to `yes`. * `editor_validation` - If set to `no`, the editor will not alert you about @@ -344,9 +342,6 @@ A path can optionally be suffixed with a blake2b hash for the referenced file, by appending a pound character (`#`) followed by the blake2b hash. E.g.: `boot():/somemodule.tar#ca6914d2...446b470a`. -When Secure Boot is active, all file paths **must** have a hash appended or -Limine will panic (except for wallpapers and fonts, which are silently skipped -instead, falling back to defaults). ## Macros diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/limine-11.2.0/ChangeLog new/limine-11.3.1/ChangeLog --- old/limine-11.2.0/ChangeLog 2026-04-02 23:32:53.000000000 +0200 +++ new/limine-11.3.1/ChangeLog 2026-04-09 13:44:49.000000000 +0200 @@ -1,3 +1,45 @@ +2026-04-09 Mintsuki <[email protected]> + + *** Release 11.3.1 *** + + (Note: 11.3.0 was skipped due to GHA migration issues) + + Noteworthy changes compared to the previous release, 11.2.1: + + New features: + - Implement "TSC Frequency" feature of the Limine boot protocol. + - Add PIT-based TSC calibration for BIOS. + - Do not clear framebuffer in quiet mode. + + Bug fixes: + - Make "Keep IOMMU" Limine boot protocol feature x86-64-only. + - Do not clear framebuffer on modeset as Flanterm immediately repaints + it, wasting time. + - Allow menu recovery on overflow panics in the multiboot protocols. + - Significantly improve TSC calibration accuracy. + + Miscellaneous: + - Do not force-start uninitialised GOP outputs if a framebuffer is + already available, for compatibility with quirky firmwares (Apple + Macs). + - Call Apple set_os protocol on UEFI to try to keep iGPU alive on + dual-GPU Apple Macs. + - Migrated to GitHub alongside with several subprojects. + - Build limine.exe using i486 MinGW from osdev0/mingw-binary-builds + in binary builds for better compatibility. + +2026-04-04 Mintsuki <[email protected]> + + *** Release 11.2.1 *** + + Noteworthy changes compared to the previous release, 11.2.0: + + Bug fixes: + - Revert Secure Boot enforcement policy for configuration file hash + and other file hashes. This broke semantic versioning, so the fair + thing to do is to revert it and move on to 12.x afterwards. + - Add workaround for VMware optical drive detection on BIOS. + 2026-04-02 Mintsuki <[email protected]> *** Release 11.2.0 *** diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/limine-11.2.0/FAQ.md new/limine-11.3.1/FAQ.md --- old/limine-11.2.0/FAQ.md 2026-04-02 23:32:53.000000000 +0200 +++ new/limine-11.3.1/FAQ.md 2026-04-09 13:44:49.000000000 +0200 @@ -27,11 +27,6 @@ a key added to the firmware's keychain. This prevents modifications to the config file (and in turn the checksums contained there) from going unnoticed. -Additionally, when Limine detects that UEFI Secure Boot is active, it enforces -that a config checksum is enrolled, that all loaded files have BLAKE2B hashes -in their paths, and disables the config editor. See [USAGE.md](USAGE.md) for -details. - ### I do not want to have a separate FAT boot partition! What can I do? It is `$year_following_2012` now and most PCs are equipped with UEFI and simply diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/limine-11.2.0/GNUmakefile.in new/limine-11.3.1/GNUmakefile.in --- old/limine-11.2.0/GNUmakefile.in 2026-04-02 23:32:53.000000000 +0200 +++ new/limine-11.3.1/GNUmakefile.in 2026-04-09 13:44:49.000000000 +0200 @@ -305,7 +305,7 @@ rm -rf '$(call SHESCAPE,$(BUILDDIR))'/"$(DIST_OUTPUT)/common/lib/stb_image.h.nopatch" rm -rf '$(call SHESCAPE,$(BUILDDIR))'/"$(DIST_OUTPUT)/.git" rm -rf '$(call SHESCAPE,$(BUILDDIR))'/"$(DIST_OUTPUT)/.gitignore" - rm -rf '$(call SHESCAPE,$(BUILDDIR))'/"$(DIST_OUTPUT)/.forgejo" + rm -rf '$(call SHESCAPE,$(BUILDDIR))'/"$(DIST_OUTPUT)/.github" rm -rf '$(call SHESCAPE,$(BUILDDIR))'/"$(DIST_OUTPUT)/README.md" rm -rf '$(call SHESCAPE,$(BUILDDIR))'/"$(DIST_OUTPUT)/autom4te.cache" rm -rf '$(call SHESCAPE,$(BUILDDIR))'/"$(DIST_OUTPUT)/test" diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/limine-11.2.0/INSTALL.md new/limine-11.3.1/INSTALL.md --- old/limine-11.2.0/INSTALL.md 2026-04-02 23:32:53.000000000 +0200 +++ new/limine-11.3.1/INSTALL.md 2026-04-09 13:44:49.000000000 +0200 @@ -15,7 +15,8 @@ ## Configure If using a release tarball (recommended, see -https://codeberg.org/Limine/Limine/releases), run `./configure` directly. +https://github.com/Limine-Bootloader/Limine/releases), run `./configure` +directly. If checking out from the repository, run `./bootstrap` first in order to download the necessary [dependencies](3RDPARTY.md) and generate the configure diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/limine-11.2.0/USAGE.md new/limine-11.3.1/USAGE.md --- old/limine-11.2.0/USAGE.md 2026-04-02 23:32:53.000000000 +0200 +++ new/limine-11.3.1/USAGE.md 2026-04-09 13:44:49.000000000 +0200 @@ -14,27 +14,13 @@ [CONFIG.md](CONFIG.md). ## Secure Boot -Limine can be booted with Secure Boot if the executable is signed and the key +Limine can be booted with secure boot if the executable is signed and the key used to sign it is added to the firmware's keychain. This should be done in combination with enrolling the BLAKE2B hash of the Limine config file into the Limine EFI executable image itself for verification purposes. For more information see the `limine enroll-config` program and [the FAQ](FAQ.md). -When Limine detects that UEFI Secure Boot is active (the `SecureBoot` variable -is set and `SetupMode` is not), the following security policies are enforced: - -* The config file **must** have a BLAKE2B checksum enrolled in the Limine EFI - executable. If no checksum is enrolled, Limine will panic. -* All file paths (kernels, modules, DTBs, fonts, etc.) **must** have a BLAKE2B - hash appended (e.g. `boot():/kernel#<hash>`). Loading a file without a hash - will cause a panic. The exception is EFI chainloading, where the firmware's - own Secure Boot image verification is used instead. -* Wallpaper and font files without an associated hash are silently skipped - (falling back to defaults) rather than causing a panic. -* The config editor is unconditionally disabled. -* `hash_mismatch_panic` is forced to `yes` regardless of the config setting. - ## BIOS/MBR In order to install Limine on a MBR device (which can just be a raw image file), run `limine bios-install` as such: diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/limine-11.2.0/bootstrap new/limine-11.3.1/bootstrap --- old/limine-11.2.0/bootstrap 2026-04-02 23:32:53.000000000 +0200 +++ new/limine-11.3.1/bootstrap 2026-04-09 13:44:49.000000000 +0200 @@ -71,26 +71,26 @@ if ! test -f version; then clone_repo_commit \ - https://codeberg.org/OSDev/freestnd-c-hdrs-0bsd.git \ + https://github.com/osdev0/freestnd-c-hdrs-0bsd.git \ freestnd-c-hdrs \ 097259a899d30f0a4b7a694de2de5fdda942e923 clone_repo_commit \ - https://codeberg.org/OSDev/cc-runtime.git \ + https://github.com/osdev0/cc-runtime.git \ cc-runtime \ dae79833b57a01b9fd3e359ee31def69f5ae899b cp cc-runtime/src/cc-runtime.c common/cc-runtime.s2.c cp cc-runtime/src/cc-runtime.c decompressor/cc-runtime.c clone_repo_commit \ - https://codeberg.org/Limine/limine-protocol.git \ + https://github.com/Limine-Bootloader/limine-protocol.git \ limine-protocol \ - c5a7f597afa5da2b45f1edb1fd8f22c5ac6c57a7 + 6f3fafe337c30f94e7c2f5c4a21498346c5604bf clone_repo_commit \ - https://codeberg.org/PicoEFI/PicoEFI.git \ + https://github.com/PicoEFI/PicoEFI.git \ picoefi \ - 8b79fdaa72ee548a8ea24e3dc4d87bf281312865 + 9c99f66e4c15aebfd72e7becb72358473b484fcf clone_repo_commit \ https://github.com/jibsen/tinf.git \ @@ -102,7 +102,7 @@ rm -f decompressor/tinf/*.orig clone_repo_commit \ - https://codeberg.org/Mintsuki/Flanterm.git \ + https://github.com/Mintsuki/Flanterm.git \ flanterm \ 112434532822dde252c84b25a6798a9c00515d66 @@ -115,7 +115,7 @@ rm -f common/lib/stb_image.h.orig clone_repo_commit \ - https://codeberg.org/OSDev/libfdt.git \ + https://github.com/osdev0/libfdt.git \ libfdt \ 7bf94e6347129d17eca263112296ad170dec28a9 fi diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/limine-11.2.0/common/drivers/disk.s2.c new/limine-11.3.1/common/drivers/disk.s2.c --- old/limine-11.2.0/common/drivers/disk.s2.c 2026-04-02 23:32:53.000000000 +0200 +++ new/limine-11.3.1/common/drivers/disk.s2.c 2026-04-09 13:44:49.000000000 +0200 @@ -266,6 +266,13 @@ bool is_atapi = (dpte != NULL && (dpte->flags & (1 << 6))); block->is_optical = is_atapi || (block->sector_size == 2048 && is_removable); + // Ugly workaround for VMware, because it puts the optical drive at 0x9f but does + // not expose DPTE. + if (drive == 0x9f && block->sector_size == 2048) { + is_removable = true; + block->is_optical = true; + } + if (!is_removable && !block->is_optical) { if (consumed_bda_disks == bda_disk_count) { pmm_free(block, sizeof(struct volume)); diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/limine-11.2.0/common/drivers/gop.c new/limine-11.3.1/common/drivers/gop.c --- old/limine-11.2.0/common/drivers/gop.c 2026-04-02 23:32:53.000000000 +0200 +++ new/limine-11.3.1/common/drivers/gop.c 2026-04-09 13:44:49.000000000 +0200 @@ -286,6 +286,9 @@ &mode_info_size, &mode_info); if (status == EFI_NOT_STARTED) { + if (fbs_count > 0) { + continue; + } status = gop->SetMode(gop, 0); if (status) { continue; diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/limine-11.2.0/common/entry.s3.c new/limine-11.3.1/common/entry.s3.c --- old/limine-11.2.0/common/entry.s3.c 2026-04-02 23:32:53.000000000 +0200 +++ new/limine-11.3.1/common/entry.s3.c 2026-04-09 13:44:49.000000000 +0200 @@ -31,6 +31,48 @@ extern symbol __slide, __image_base, __image_end; extern symbol _start; +#if defined (__x86_64__) +static void apple_set_os(void) { + if (gST->FirmwareVendor == NULL) { + return; + } + + static const CHAR16 apple[] = L"Apple"; + for (size_t i = 0; i < SIZEOF_ARRAY(apple) - 1; i++) { + if (gST->FirmwareVendor[i] != apple[i]) { + return; + } + } + + EFI_GUID apple_set_os_guid = { + 0xc5c5da95, 0x7d5c, 0x45e6, + { 0xb2, 0xf1, 0x3f, 0xd5, 0x2b, 0xb1, 0x00, 0x77 } + }; + + struct apple_set_os_iface { + uint64_t version; + EFI_STATUS (EFIAPI *set_os_version)(const char *version); + EFI_STATUS (EFIAPI *set_os_vendor)(const char *vendor); + } *set_os = NULL; + + EFI_STATUS status = gBS->LocateProtocol( + &apple_set_os_guid, NULL, (void **)&set_os); + if (status || set_os == NULL) { + return; + } + + if (set_os->version >= 2) { + set_os->set_os_vendor("Apple Inc."); + } + if (set_os->version > 0) { + set_os->set_os_version("Mac OS X 10.9"); + } + + printv("apple: Set OS version via Apple set_os protocol (version %u)\n", + (uint32_t)set_os->version); +} +#endif + noreturn void uefi_entry(EFI_HANDLE ImageHandle, EFI_SYSTEM_TABLE *SystemTable) { gST = SystemTable; gBS = SystemTable->BootServices; @@ -76,6 +118,10 @@ term_fallback(); +#if defined (__x86_64__) + apple_set_os(); +#endif + status = gBS->SetWatchdogTimer(0, 0x10000, 0, NULL); if (status) { print("WARNING: Failed to disable watchdog timer!\n"); @@ -91,22 +137,6 @@ disk_create_index(); - // Detect UEFI Secure Boot - { - EFI_GUID global_variable = EFI_GLOBAL_VARIABLE; - UINT8 secure_boot = 0; - UINTN sb_size = sizeof(secure_boot); - EFI_STATUS sb_status = gRT->GetVariable(L"SecureBoot", &global_variable, NULL, &sb_size, &secure_boot); - if (sb_status == EFI_SUCCESS && secure_boot == 1) { - UINT8 setup_mode = 0; - UINTN sm_size = sizeof(setup_mode); - EFI_STATUS sm_status = gRT->GetVariable(L"SetupMode", &global_variable, NULL, &sm_size, &setup_mode); - if (sm_status != EFI_SUCCESS || setup_mode == 0) { - secure_boot_active = true; - } - } - } - boot_volume = NULL; EFI_HANDLE current_handle = ImageHandle; diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/limine-11.2.0/common/lib/config.c new/limine-11.3.1/common/lib/config.c --- old/limine-11.2.0/common/lib/config.c 2026-04-02 23:32:53.000000000 +0200 +++ new/limine-11.3.1/common/lib/config.c 2026-04-09 13:44:49.000000000 +0200 @@ -353,10 +353,6 @@ int init_config(size_t config_size) { config_b2sum += sizeof(CONFIG_B2SUM_SIGNATURE) - 1; - if (secure_boot_active && memcmp((void *)config_b2sum, CONFIG_B2SUM_EMPTY, 128) == 0) { - panic(false, "!!! SECURE BOOT IS ACTIVE BUT NO CONFIG CHECKSUM IS ENROLLED !!!"); - } - if (memcmp((void *)config_b2sum, CONFIG_B2SUM_EMPTY, 128) != 0) { editor_enabled = false; diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/limine-11.2.0/common/lib/fb.c new/limine-11.3.1/common/lib/fb.c --- old/limine-11.2.0/common/lib/fb.c 2026-04-02 23:32:53.000000000 +0200 +++ new/limine-11.3.1/common/lib/fb.c 2026-04-09 13:44:49.000000000 +0200 @@ -14,6 +14,10 @@ void fb_init(struct fb_info **ret, size_t *_fbs_count, uint64_t target_width, uint64_t target_height, uint16_t target_bpp, bool preserve_screen) { + if (quiet) { + preserve_screen = true; + } + #if defined (BIOS) *ret = ext_mem_alloc(sizeof(struct fb_info)); if (init_vbe(*ret, target_width, target_height, target_bpp, preserve_screen)) { diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/limine-11.2.0/common/lib/gterm.c new/limine-11.3.1/common/lib/gterm.c --- old/limine-11.2.0/common/lib/gterm.c 2026-04-02 23:32:53.000000000 +0200 +++ new/limine-11.3.1/common/lib/gterm.c 2026-04-09 13:44:49.000000000 +0200 @@ -584,14 +584,10 @@ if (wallpaper_count > 0) { char *background_path = config_get_value(config, rand32() % wallpaper_count, "WALLPAPER"); if (background_path != NULL) { - if (secure_boot_active && strchr(background_path, '#') == NULL) { - print("Wallpaper skipped: Secure Boot is active and no hash is associated.\n"); - } else { - struct file_handle *bg_file; - if ((bg_file = uri_open(background_path)) != NULL) { - background = image_open(bg_file); - fclose(bg_file); - } + struct file_handle *bg_file; + if ((bg_file = uri_open(background_path)) != NULL) { + background = image_open(bg_file); + fclose(bg_file); } } } @@ -658,10 +654,6 @@ char *menu_font = config_get_value(config, 0, "TERM_FONT"); if (menu_font != NULL) { - if (secure_boot_active && strchr(menu_font, '#') == NULL) { - print("Font skipped: Secure Boot is active and no hash is associated.\n"); - goto config_no_load_font; - } struct file_handle *f; if ((f = uri_open(menu_font)) == NULL) { print("menu: Could not open font file.\n"); @@ -784,7 +776,7 @@ term_notready(); // We force bpp to 32 - fb_init(&fbs, &fbs_count, width, height, 32, false); + fb_init(&fbs, &fbs_count, width, height, 32, true); if (_fbs != NULL) { *_fbs = fbs; diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/limine-11.2.0/common/lib/misc.c new/limine-11.3.1/common/lib/misc.c --- old/limine-11.2.0/common/lib/misc.c 2026-04-02 23:32:53.000000000 +0200 +++ new/limine-11.3.1/common/lib/misc.c 2026-04-09 13:44:49.000000000 +0200 @@ -25,7 +25,6 @@ bool editor_enabled = true; bool help_hidden = false; -bool secure_boot_active = false; uint64_t usec_at_bootloader_entry; diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/limine-11.2.0/common/lib/misc.h new/limine-11.3.1/common/lib/misc.h --- old/limine-11.2.0/common/lib/misc.h 2026-04-02 23:32:53.000000000 +0200 +++ new/limine-11.3.1/common/lib/misc.h 2026-04-09 13:44:49.000000000 +0200 @@ -38,7 +38,7 @@ extern bool stage3_loaded; #endif -extern bool quiet, serial, editor_enabled, help_hidden, hash_mismatch_panic, secure_boot_active; +extern bool quiet, serial, editor_enabled, help_hidden, hash_mismatch_panic; extern uint64_t usec_at_bootloader_entry; @@ -100,7 +100,7 @@ #define ALIGN_UP(x, a, onerror) ({ \ __auto_type ALIGN_UP_value = (x); \ __auto_type ALIGN_UP_align = (a); \ - ALIGN_UP_value = DIV_ROUNDUP(ALIGN_UP_value, ALIGN_UP_align, onerror) * ALIGN_UP_align; \ + ALIGN_UP_value = CHECKED_MUL(DIV_ROUNDUP(ALIGN_UP_value, ALIGN_UP_align, onerror), ALIGN_UP_align, onerror); \ ALIGN_UP_value; \ }) diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/limine-11.2.0/common/lib/term.c new/limine-11.3.1/common/lib/term.c --- old/limine-11.2.0/common/lib/term.c 2026-04-02 23:32:53.000000000 +0200 +++ new/limine-11.3.1/common/lib/term.c 2026-04-09 13:44:49.000000000 +0200 @@ -270,6 +270,10 @@ flanterm_context_reinit(term); #if defined (UEFI) + cursor_x = 0; + cursor_y = 0; + gST->ConOut->SetCursorPosition(gST->ConOut, 0, 0); + term->set_text_fg = fallback_set_text_fg; term->set_text_bg = fallback_set_text_bg; term->set_text_fg_bright = fallback_set_text_fg_bright; diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/limine-11.2.0/common/lib/uri.c new/limine-11.3.1/common/lib/uri.c --- old/limine-11.2.0/common/lib/uri.c 2026-04-02 23:32:53.000000000 +0200 +++ new/limine-11.3.1/common/lib/uri.c 2026-04-09 13:44:49.000000000 +0200 @@ -252,10 +252,6 @@ panic(true, "Resource `%s` not valid.", resource); } - if (secure_boot_active && hash == NULL && ret != NULL) { - panic(true, "Secure Boot is active and URI `%#` has no associated hash!", uri); - } - if (hash != NULL && ret != NULL) { uint8_t out_buf[BLAKE2B_OUT_BYTES]; #if defined (UEFI) && defined (__x86_64__) diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/limine-11.2.0/common/menu.c new/limine-11.3.1/common/menu.c --- old/limine-11.2.0/common/menu.c 2026-04-02 23:32:53.000000000 +0200 +++ new/limine-11.3.1/common/menu.c 2026-04-09 13:44:49.000000000 +0200 @@ -1030,11 +1030,6 @@ char *hash_mismatch_panic_str = config_get_value(NULL, 0, "HASH_MISMATCH_PANIC"); hash_mismatch_panic = hash_mismatch_panic_str == NULL || strcmp(hash_mismatch_panic_str, "yes") == 0; - if (secure_boot_active) { - hash_mismatch_panic = true; - editor_enabled = false; - } - char *randomise_mem_str = config_get_value(NULL, 0, "RANDOMISE_MEMORY"); if (randomise_mem_str == NULL) randomise_mem_str = config_get_value(NULL, 0, "RANDOMIZE_MEMORY"); @@ -1044,7 +1039,7 @@ } char *editor_enabled_str = config_get_value(NULL, 0, "EDITOR_ENABLED"); - if (editor_enabled_str != NULL && !secure_boot_active) { + if (editor_enabled_str != NULL) { editor_enabled = strcmp(editor_enabled_str, "yes") == 0; } @@ -1075,9 +1070,9 @@ { uint32_t eax, ebx, ecx, edx; if (!cpuid(0x80000001, 0, &eax, &ebx, &ecx, &edx) || !(edx & (1 << 29))) { - menu_branding = strdup("Limine " LIMINE_VERSION " (ia-32, BIOS)"); + menu_branding = "Limine " LIMINE_VERSION " (ia-32, BIOS)"; } else { - menu_branding = strdup("Limine " LIMINE_VERSION " (x86-64, BIOS)"); + menu_branding = "Limine " LIMINE_VERSION " (x86-64, BIOS)"; } } #elif defined (UEFI) @@ -1085,13 +1080,13 @@ { uint32_t eax, ebx, ecx, edx; if (!cpuid(0x80000001, 0, &eax, &ebx, &ecx, &edx) || !(edx & (1 << 29))) { - menu_branding = strdup("Limine " LIMINE_VERSION " (ia-32, UEFI32)"); + menu_branding = "Limine " LIMINE_VERSION " (ia-32, UEFI32)"; } else { - menu_branding = strdup("Limine " LIMINE_VERSION " (x86-64, UEFI32)"); + menu_branding = "Limine " LIMINE_VERSION " (x86-64, UEFI32)"; } } #else - menu_branding = strdup("Limine " LIMINE_VERSION " (" + menu_branding = "Limine " LIMINE_VERSION " (" #if defined (__x86_64__) "x86-64" #elif defined (__riscv) @@ -1101,19 +1096,11 @@ #elif defined (__loongarch64) "loongarch64" #endif - ", UEFI)"); + ", UEFI)"; #endif #endif } - if (secure_boot_active) { - const char *suffix = ", Secure Boot)"; - size_t suffix_len = strlen(suffix) + 1; - size_t old_len = strlen(menu_branding); - menu_branding = pmm_realloc(menu_branding, old_len + 1, old_len + suffix_len); - memcpy(menu_branding + old_len - 1, suffix, suffix_len); - } - { char *tmp = config_get_value(NULL, 0, "INTERFACE_BRANDING_COLOUR"); if (tmp == NULL) diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/limine-11.2.0/common/protos/chainload.c new/limine-11.3.1/common/protos/chainload.c --- old/limine-11.2.0/common/protos/chainload.c 2026-04-02 23:32:53.000000000 +0200 +++ new/limine-11.3.1/common/protos/chainload.c 2026-04-09 13:44:49.000000000 +0200 @@ -265,18 +265,10 @@ panic(true, "efi: Image path not specified"); } - // The firmware's LoadImage will verify the Secure Boot signature of the - // chainloaded EFI application, so Limine does not need to enforce its - // own hash check here. - bool saved_secure_boot_active = secure_boot_active; - secure_boot_active = false; - struct file_handle *image; if ((image = uri_open(image_path)) == NULL) panic(true, "efi: Failed to open image with path `%s`. Is the path correct?", image_path); - secure_boot_active = saved_secure_boot_active; - EFI_STATUS status; EFI_HANDLE efi_part_handle = image->efi_part_handle; diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/limine-11.2.0/common/protos/limine.c new/limine-11.3.1/common/protos/limine.c --- old/limine-11.2.0/common/protos/limine.c 2026-04-02 23:32:53.000000000 +0200 +++ new/limine-11.3.1/common/protos/limine.c 2026-04-09 13:44:49.000000000 +0200 @@ -945,18 +945,18 @@ entrypoint_request->response = reported_addr(entrypoint_response); FEAT_END - // Keep IOMMU feature + // x86-64 Keep IOMMU feature #if defined (__x86_64__) || defined (__i386__) bool keep_iommu = false; FEAT_START - struct limine_keep_iommu_request *keep_iommu_request = - get_request(LIMINE_KEEP_IOMMU_REQUEST_ID); + struct limine_x86_64_keep_iommu_request *keep_iommu_request = + get_request(LIMINE_X86_64_KEEP_IOMMU_REQUEST_ID); if (keep_iommu_request == NULL) { break; } - struct limine_keep_iommu_response *keep_iommu_response = - ext_mem_alloc(sizeof(struct limine_keep_iommu_response)); + struct limine_x86_64_keep_iommu_response *keep_iommu_response = + ext_mem_alloc(sizeof(struct limine_x86_64_keep_iommu_response)); keep_iommu_request->response = reported_addr(keep_iommu_response); keep_iommu = true; @@ -1594,8 +1594,26 @@ } #endif + // TSC Frequency +FEAT_START + if (tsc_freq == 0) { + break; + } + + struct limine_tsc_frequency_request *tsc_freq_request = get_request(LIMINE_TSC_FREQUENCY_REQUEST_ID); + if (tsc_freq_request == NULL) { + break; + } + + struct limine_tsc_frequency_response *tsc_freq_response = + ext_mem_alloc(sizeof(struct limine_tsc_frequency_response)); + + tsc_freq_response->frequency = tsc_freq; + + tsc_freq_request->response = reported_addr(tsc_freq_response); +FEAT_END + // Bootloader Performance - // rdtsc_usec depends on EFI boot services FEAT_START if (usec_at_bootloader_entry == 0) { break; diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/limine-11.2.0/common/protos/linux_risc.c new/limine-11.3.1/common/protos/linux_risc.c --- old/limine-11.2.0/common/protos/linux_risc.c 2026-04-02 23:32:53.000000000 +0200 +++ new/limine-11.3.1/common/protos/linux_risc.c 2026-04-09 13:44:49.000000000 +0200 @@ -151,13 +151,14 @@ size_t offset = 0; for (size_t i = 0; i < module_count; i++) { - fread(modules[i], p->module_base + offset, 0, modules[i]->size); - offset += modules[i]->size; + size_t module_size = modules[i]->size; + fread(modules[i], p->module_base + offset, 0, module_size); fclose(modules[i]); char *module_path = config_get_value(config, i, "MODULE_PATH"); printv("linux: loaded module `%s` at %p, size %U\n", module_path, - p->module_base + offset - modules[i]->size, (uint64_t)modules[i]->size); + p->module_base + offset, (uint64_t)module_size); + offset += module_size; } pmm_free(modules, module_count * sizeof(struct file_handle *)); @@ -510,7 +511,7 @@ #endif p.kernel_base = ext_mem_alloc_type_aligned( - ALIGN_UP(text_offset + kernel_alloc_size, 4096, panic(true, "linux: Alignment overflow")), + ALIGN_UP(CHECKED_ADD(text_offset, kernel_alloc_size, panic(true, "linux: Kernel size overflow")), 4096, panic(true, "linux: Alignment overflow")), MEMMAP_KERNEL_AND_MODULES, 2 * 1024 * 1024); p.kernel_base += text_offset; fread(kernel_file, p.kernel_base, 0, p.kernel_size); diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/limine-11.2.0/common/protos/multiboot1.c new/limine-11.3.1/common/protos/multiboot1.c --- old/limine-11.2.0/common/protos/multiboot1.c 2026-04-02 23:32:53.000000000 +0200 +++ new/limine-11.3.1/common/protos/multiboot1.c 2026-04-09 13:44:49.000000000 +0200 @@ -35,7 +35,7 @@ size_t modules_count, size_t modules_cmdlines_size, uint32_t section_entry_size, uint32_t section_num ) { -#define OVERFLOW panic(false, "multiboot1: info size overflow") +#define OVERFLOW panic(true, "multiboot1: info size overflow") return ALIGN_UP(sizeof(struct multiboot1_info), 16, OVERFLOW) + ALIGN_UP(strlen(cmdline) + 1, 16, OVERFLOW) + ALIGN_UP(sizeof(LIMINE_BRAND), 16, OVERFLOW) + @@ -48,7 +48,7 @@ static void *mb1_info_alloc(void **mb1_info_raw, size_t size) { void *ret = *mb1_info_raw; - *mb1_info_raw += ALIGN_UP(size, 16, panic(false, "multiboot: info alloc overflow")); + *mb1_info_raw += ALIGN_UP(size, 16, panic(true, "multiboot: info alloc overflow")); return ret; } @@ -191,7 +191,7 @@ char *module_cmdline = conf_tuple.value2; if (!module_cmdline) module_cmdline = ""; - modules_cmdlines_size += ALIGN_UP(strlen(module_cmdline) + 1, 16, panic(false, "multiboot: info size overflow")); + modules_cmdlines_size += ALIGN_UP(strlen(module_cmdline) + 1, 16, panic(true, "multiboot: info size overflow")); } size_t mb1_info_size = get_multiboot1_info_size( diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/limine-11.2.0/common/protos/multiboot2.c new/limine-11.3.1/common/protos/multiboot2.c --- old/limine-11.2.0/common/protos/multiboot2.c 2026-04-02 23:32:53.000000000 +0200 +++ new/limine-11.3.1/common/protos/multiboot2.c 2026-04-09 13:44:49.000000000 +0200 @@ -40,7 +40,7 @@ uint32_t section_entry_size, uint32_t section_num, uint32_t smbios_tag_size ) { -#define OVERFLOW panic(false, "multiboot2: info size overflow") +#define OVERFLOW panic(true, "multiboot2: info size overflow") return ALIGN_UP(sizeof(struct multiboot2_start_tag), MULTIBOOT_TAG_ALIGN, OVERFLOW) + ALIGN_UP(sizeof(struct multiboot_tag_string) + strlen(cmdline) + 1, MULTIBOOT_TAG_ALIGN, OVERFLOW) + ALIGN_UP(sizeof(struct multiboot_tag_string) + sizeof(LIMINE_BRAND), MULTIBOOT_TAG_ALIGN, OVERFLOW) + @@ -69,7 +69,7 @@ } #define append_tag(P, TAG) do { \ - (P) += ALIGN_UP((TAG)->size, MULTIBOOT_TAG_ALIGN, panic(false, "multiboot2: tag size overflow")); \ + (P) += ALIGN_UP((TAG)->size, MULTIBOOT_TAG_ALIGN, panic(true, "multiboot2: tag size overflow")); \ } while (0) noreturn void multiboot2_load(char *config, char* cmdline) { @@ -455,7 +455,7 @@ char *module_cmdline = conf_tuple.value2; if (!module_cmdline) module_cmdline = ""; - modules_size += ALIGN_UP(sizeof(struct multiboot_tag_module) + strlen(module_cmdline) + 1, MULTIBOOT_TAG_ALIGN, panic(false, "multiboot2: modules size overflow")); + modules_size += ALIGN_UP(sizeof(struct multiboot_tag_module) + strlen(module_cmdline) + 1, MULTIBOOT_TAG_ALIGN, panic(true, "multiboot2: modules size overflow")); } struct smbios_entry_point_32* smbios_entry_32 = NULL; @@ -466,9 +466,9 @@ uint32_t smbios_tag_size = 0; if (smbios_entry_32 != NULL) - smbios_tag_size += ALIGN_UP(sizeof(struct multiboot_tag_smbios) + smbios_entry_32->length, MULTIBOOT_TAG_ALIGN, panic(false, "multiboot2: tag size overflow")); + smbios_tag_size += ALIGN_UP(sizeof(struct multiboot_tag_smbios) + smbios_entry_32->length, MULTIBOOT_TAG_ALIGN, panic(true, "multiboot2: tag size overflow")); if (smbios_entry_64 != NULL) - smbios_tag_size += ALIGN_UP(sizeof(struct multiboot_tag_smbios) + smbios_entry_64->length, MULTIBOOT_TAG_ALIGN, panic(false, "multiboot2: tag size overflow")); + smbios_tag_size += ALIGN_UP(sizeof(struct multiboot_tag_smbios) + smbios_entry_64->length, MULTIBOOT_TAG_ALIGN, panic(true, "multiboot2: tag size overflow")); size_t mb2_info_size = get_multiboot2_info_size( cmdline, diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/limine-11.2.0/common/sys/cpu.h new/limine-11.3.1/common/sys/cpu.h --- old/limine-11.2.0/common/sys/cpu.h 2026-04-02 23:32:53.000000000 +0200 +++ new/limine-11.3.1/common/sys/cpu.h 2026-04-09 13:44:49.000000000 +0200 @@ -504,15 +504,6 @@ } static inline void stall(uint64_t us) { -#if defined(BIOS) - if (tsc_freq == 0) { - // ~1 us per inb on ISA/LPC bus - for (uint64_t i = 0; i < us; i++) { - inb(0x80); - } - return; - } -#endif uint64_t ticks = (tsc_freq * us + 999999) / 1000000; uint64_t next_stop = rdtsc() + ticks; while (rdtsc() < next_stop); diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/limine-11.2.0/common/sys/cpu.s2.c new/limine-11.3.1/common/sys/cpu.s2.c --- old/limine-11.2.0/common/sys/cpu.s2.c 2026-04-02 23:32:53.000000000 +0200 +++ new/limine-11.3.1/common/sys/cpu.s2.c 2026-04-09 13:44:49.000000000 +0200 @@ -15,12 +15,63 @@ } #if defined(UEFI) - uint64_t tsc_start = rdtsc(); - gBS->Stall(1000); - uint64_t tsc_end = rdtsc(); + // Calibrate over 10ms. Run multiple rounds and take the smallest + // (least SMI-disrupted) delta. + #define EFI_CALIBRATION_STALL 10000 + #define EFI_CALIBRATION_ROUNDS 3 - if (tsc_end > tsc_start) { - tsc_freq = (tsc_end - tsc_start) * 1000ULL; + uint64_t best_delta = 0; + for (int round = 0; round < EFI_CALIBRATION_ROUNDS; round++) { + uint64_t tsc_start = rdtsc(); + gBS->Stall(EFI_CALIBRATION_STALL); + uint64_t tsc_end = rdtsc(); + + if (tsc_end > tsc_start) { + uint64_t delta = tsc_end - tsc_start; + if (delta < best_delta || best_delta == 0) { + best_delta = delta; + } + } + } + + if (best_delta != 0) { + tsc_freq = best_delta * (1000000ULL / EFI_CALIBRATION_STALL); + } +#elif defined(BIOS) + // Calibrate TSC using PIT channel 2. + // PIT oscillator frequency: 1193182 Hz + // Count of 11932 gives ~10ms calibration interval. + // Run multiple rounds and take the highest (least SMI-disrupted) result. + #define PIT_CALIBRATION_COUNT 11932 + #define PIT_CALIBRATION_ROUNDS 3 + + uint8_t port61 = inb(0x61); + + uint64_t best_delta = 0; + for (int round = 0; round < PIT_CALIBRATION_ROUNDS; round++) { + outb(0x61, port61 & ~0x03); // disable gate and speaker + outb(0x43, 0xb0); // channel 2, lobyte/hibyte, mode 0, binary + outb(0x42, PIT_CALIBRATION_COUNT & 0xff); + outb(0x42, (PIT_CALIBRATION_COUNT >> 8) & 0xff); + + outb(0x61, (inb(0x61) | 0x01)); // enable gate to start counting + uint64_t tsc_start = rdtsc(); + + while ((inb(0x61) & 0x20) == 0); // wait for output high + uint64_t tsc_end = rdtsc(); + + if (tsc_end > tsc_start) { + uint64_t delta = tsc_end - tsc_start; + if (delta < best_delta || best_delta == 0) { + best_delta = delta; + } + } + } + + outb(0x61, port61); // restore + + if (best_delta != 0) { + tsc_freq = best_delta * 1193182 / PIT_CALIBRATION_COUNT; } #endif } diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/limine-11.2.0/configure new/limine-11.3.1/configure --- old/limine-11.2.0/configure 2026-04-02 23:33:07.000000000 +0200 +++ new/limine-11.3.1/configure 2026-04-09 13:44:53.000000000 +0200 @@ -1,8 +1,8 @@ #! /bin/sh # Guess values for system-dependent variables and create Makefiles. -# Generated by GNU Autoconf 2.73 for Limine 11.2.0. +# Generated by GNU Autoconf 2.73 for Limine 11.3.1. # -# Report bugs to <https://codeberg.org/Limine/Limine/issues>. +# Report bugs to <https://github.com/Limine-Bootloader/Limine/issues>. # # # Copyright (C) 1992-1996, 1998-2017, 2020-2026 Free Software Foundation, @@ -277,10 +277,11 @@ printf '%s\n' "$0: be upgraded to zsh 4.3.4 or later." else printf '%s\n' "$0: Please tell [email protected] and -$0: https://codeberg.org/Limine/Limine/issues about your -$0: system, including any error possibly output before this -$0: message. Then install a modern shell, or manually run -$0: the script under such a shell if you do have one." +$0: https://github.com/Limine-Bootloader/Limine/issues +$0: about your system, including any error possibly output +$0: before this message. Then install a modern shell, or +$0: manually run the script under such a shell if you do +$0: have one." fi exit 1 fi ;; @@ -588,9 +589,9 @@ # Identity of this package. PACKAGE_NAME='Limine' PACKAGE_TARNAME='limine' -PACKAGE_VERSION='11.2.0' -PACKAGE_STRING='Limine 11.2.0' -PACKAGE_BUGREPORT='https://codeberg.org/Limine/Limine/issues' +PACKAGE_VERSION='11.3.1' +PACKAGE_STRING='Limine 11.3.1' +PACKAGE_BUGREPORT='https://github.com/Limine-Bootloader/Limine/issues' PACKAGE_URL='https://limine-bootloader.org/' # Factoring default headers for most tests. @@ -1308,7 +1309,7 @@ # Omit some internal or obsolete options to make the list less imposing. # This message is too long to be a string in the A/UX 3.1 sh. cat <<_ACEOF -'configure' configures Limine 11.2.0 to adapt to many kinds of systems. +'configure' configures Limine 11.3.1 to adapt to many kinds of systems. Usage: $0 [OPTION]... [VAR=VALUE]... @@ -1374,7 +1375,7 @@ if test -n "$ac_init_help"; then case $ac_init_help in - short | recursive ) echo "Configuration of Limine 11.2.0:";; + short | recursive ) echo "Configuration of Limine 11.3.1:";; esac cat <<\_ACEOF @@ -1428,7 +1429,7 @@ Use these variables to override the choices made by 'configure' or to help it to find libraries and programs with nonstandard names/locations. -Report bugs to <https://codeberg.org/Limine/Limine/issues>. +Report bugs to <https://github.com/Limine-Bootloader/Limine/issues>. Limine home page: <https://limine-bootloader.org/>. _ACEOF ac_status=$? @@ -1493,7 +1494,7 @@ test -n "$ac_init_help" && exit $ac_status if $ac_init_version; then cat <<\_ACEOF -Limine configure 11.2.0 +Limine configure 11.3.1 generated by GNU Autoconf 2.73 Copyright (C) 2026 Free Software Foundation, Inc. @@ -1605,7 +1606,7 @@ This file contains any messages produced by compilers while running configure, to aid debugging if configure makes a mistake. -It was created by Limine $as_me 11.2.0, which was +It was created by Limine $as_me 11.3.1, which was generated by GNU Autoconf 2.73. Invocation command line was $ $0$ac_configure_args_raw @@ -6453,7 +6454,7 @@ # report actual input values of CONFIG_FILES etc. instead of their # values after options handling. ac_log=" -This file was extended by Limine $as_me 11.2.0, which was +This file was extended by Limine $as_me 11.3.1, which was generated by GNU Autoconf 2.73. Invocation command line was CONFIG_FILES = $CONFIG_FILES @@ -6500,7 +6501,7 @@ Configuration files: $config_files -Report bugs to <https://codeberg.org/Limine/Limine/issues>. +Report bugs to <https://github.com/Limine-Bootloader/Limine/issues>. Limine home page: <https://limine-bootloader.org/>." _ACEOF @@ -6509,7 +6510,7 @@ cat >>"$CONFIG_STATUS" <<_ACEOF || ac_write_fail=1 ac_cs_config='$ac_cs_config_escaped' ac_cs_version="\\ -Limine config.status 11.2.0 +Limine config.status 11.3.1 configured by $0, generated by GNU Autoconf 2.73, with options \\"\$ac_cs_config\\" diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/limine-11.2.0/configure.ac new/limine-11.3.1/configure.ac --- old/limine-11.2.0/configure.ac 2026-04-02 23:32:53.000000000 +0200 +++ new/limine-11.3.1/configure.ac 2026-04-09 13:44:49.000000000 +0200 @@ -1,4 +1,4 @@ -AC_INIT([Limine], [m4_esyscmd([./version.sh])], [https://codeberg.org/Limine/Limine/issues], [limine], [https://limine-bootloader.org/]) +AC_INIT([Limine], [m4_esyscmd([./version.sh])], [https://github.com/Limine-Bootloader/Limine/issues], [limine], [https://limine-bootloader.org/]) AC_PREREQ([2.69]) diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/limine-11.2.0/limine-protocol/PROTOCOL.md new/limine-11.3.1/limine-protocol/PROTOCOL.md --- old/limine-11.2.0/limine-protocol/PROTOCOL.md 2026-04-02 23:33:00.000000000 +0200 +++ new/limine-11.3.1/limine-protocol/PROTOCOL.md 2026-04-09 13:44:50.000000000 +0200 @@ -7,7 +7,7 @@ collection of [features](#features) that the Limine boot protocol is comprised of. Bootloaders may support extra unofficial features, but it is strongly recommended to avoid fragmentation and submit new features by opening a pull request to the -[limine-protocol Codeberg repository](https://codeberg.org/Limine/limine-protocol). +[limine-protocol GitHub repository](https://github.com/Limine-Bootloader/limine-protocol). The [limine.h](include/limine.h) file provides an implementation of all the structures and constants described in this document, for the C and C++ @@ -67,6 +67,7 @@ - [Device Tree Blob](#device-tree-blob-feature) - [Bootloader Performance](#bootloader-performance-feature) - [Keep IOMMU](#keep-iommu-feature) + - [TSC (Timestamp Counter) Frequency](#tsc-timestamp-counter-frequency-feature) - [Flanterm FB Init Params](#flanterm-fb-init-params-feature) - [File Structure](#file-structure) @@ -1831,46 +1832,85 @@ > system reset, due to implementation or platform restrictions. `reset_usec` > will usually be 0 or a > value near zero, but may be any value relative to any point in the past. -### Keep IOMMU Feature +### x86-64 Keep IOMMU Feature ID: ```c -#define LIMINE_KEEP_IOMMU_REQUEST_ID { LIMINE_COMMON_MAGIC, 0x8ebaabe51f490179, 0x2aa86a59ffb4ab0f } +#define LIMINE_X86_64_KEEP_IOMMU_REQUEST_ID { LIMINE_COMMON_MAGIC, 0x8ebaabe51f490179, 0x2aa86a59ffb4ab0f } ``` Request: ```c -struct limine_keep_iommu_request { +struct limine_x86_64_keep_iommu_request { uint64_t id[4]; uint64_t revision; - struct limine_keep_iommu_response *response; + struct limine_x86_64_keep_iommu_response *response; }; ``` Response: ```c -struct limine_keep_iommu_response { +struct limine_x86_64_keep_iommu_response { uint64_t revision; }; ``` -If this feature is requested, the bootloader will not disable IOMMUs (e.g. Intel VT-d, AMD-Vi, -ARM SMMU, ...) that were left enabled by the firmware at bootloader hand-off, before executable -handoff. This is intended for security-conscious executables that wish to preserve DMA protection -and such set up by firmware. +If this feature is requested, the bootloader will not disable IOMMUs (Intel VT-d, AMD-Vi) +that were left enabled by the firmware at hand-off. This is intended for security-conscious +executables that wish to preserve DMA protection set up by firmware. If this feature is not requested, the bootloader reserves the right to disable any active IOMMUs -before handing control to the executable, for compatibility with kernels that do not support +before handing control to the executable, for compatibility with executables that do not support these. > [!NOTE] > Not passing this request does not imply that the bootloader is mandated to > disable the IOMMUs, -> though newly implemented bootloaders are strongly recommended to, and should, disable it. +> though newly implemented bootloaders are strongly recommended to, and should, disable them. + +> [!NOTE] +> On non-x86 platforms, no response will be provided. + +### TSC (Timestamp Counter) Frequency Feature + +ID: +```c +#define LIMINE_TSC_FREQUENCY_REQUEST_ID { LIMINE_COMMON_MAGIC, 0x10f2ee1d87d195e4, 0xf747a2b78f6ddb31 } +``` + +Request: +```c +struct limine_tsc_frequency_request { + uint64_t id[4]; + uint64_t revision; + struct limine_tsc_frequency_response *response; +}; +``` + +Response: +```c +struct limine_tsc_frequency_response { + uint64_t revision; + uint64_t frequency; +}; +``` + +* `frequency` - The frequency of the primary timestamp counter, in Hz. + +The primary timestamp counter is the counter read by the `RDTSC` instruction on x86-64, +`CNTPCT_EL0` on aarch64, `RDTIME` on riscv64, and `RDTIME.D` on loongarch64. + +> [!NOTE] +> The frequency value provided by this feature is best-effort, and may not be fully precise +> depending on the platform and the method used by the bootloader to determine it. + +> [!NOTE] +> If the bootloader is unable to determine the timestamp counter frequency, no response +> will be provided. ### Flanterm FB Init Params Feature This feature provides the parameters used by the bootloader to initialise its -[Flanterm](https://codeberg.org/Mintsuki/Flanterm) framebuffer terminal instances. +[Flanterm](https://github.com/Mintsuki/Flanterm) framebuffer terminal instances. This allows the executable to initialise Flanterm in the same way as the bootloader, reproducing the same terminal appearance (wallpaper, colours, font, etc.). diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/limine-11.2.0/limine-protocol/include/limine.h new/limine-11.3.1/limine-protocol/include/limine.h --- old/limine-11.2.0/limine-protocol/include/limine.h 2026-04-02 23:33:00.000000000 +0200 +++ new/limine-11.3.1/limine-protocol/include/limine.h 2026-04-09 13:44:50.000000000 +0200 @@ -615,16 +615,31 @@ LIMINE_PTR(struct limine_bootloader_performance_response *) response; }; -#define LIMINE_KEEP_IOMMU_REQUEST_ID { LIMINE_COMMON_MAGIC, 0x8ebaabe51f490179, 0x2aa86a59ffb4ab0f } +#define LIMINE_X86_64_KEEP_IOMMU_REQUEST_ID { LIMINE_COMMON_MAGIC, 0x8ebaabe51f490179, 0x2aa86a59ffb4ab0f } -struct limine_keep_iommu_response { +struct limine_x86_64_keep_iommu_response { uint64_t revision; }; -struct limine_keep_iommu_request { +struct limine_x86_64_keep_iommu_request { uint64_t id[4]; uint64_t revision; - LIMINE_PTR(struct limine_keep_iommu_response *) response; + LIMINE_PTR(struct limine_x86_64_keep_iommu_response *) response; +}; + +/* TSC (Timestamp Counter) Frequency */ + +#define LIMINE_TSC_FREQUENCY_REQUEST_ID { LIMINE_COMMON_MAGIC, 0x10f2ee1d87d195e4, 0xf747a2b78f6ddb31 } + +struct limine_tsc_frequency_response { + uint64_t revision; + uint64_t frequency; +}; + +struct limine_tsc_frequency_request { + uint64_t id[4]; + uint64_t revision; + LIMINE_PTR(struct limine_tsc_frequency_response *) response; }; #ifdef __cplusplus diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/limine-11.2.0/picoefi/README new/limine-11.3.1/picoefi/README --- old/limine-11.2.0/picoefi/README 2026-04-02 23:33:00.000000000 +0200 +++ new/limine-11.3.1/picoefi/README 2026-04-09 13:44:50.000000000 +0200 @@ -7,4 +7,4 @@ relocation stubs, and provides updated linker scripts. For an example on how to use this, see: -https://codeberg.org/PicoEFI/picoefi-c-template +https://github.com/PicoEFI/picoefi-c-template diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/limine-11.2.0/timestamps new/limine-11.3.1/timestamps --- old/limine-11.2.0/timestamps 2026-04-02 23:33:04.000000000 +0200 +++ new/limine-11.3.1/timestamps 2026-04-09 13:44:51.000000000 +0200 @@ -1,3 +1,3 @@ REGEN_DATE="April 2026" -SOURCE_DATE_EPOCH="1775164760" -SOURCE_DATE_EPOCH_TOUCH="202604022319" +SOURCE_DATE_EPOCH="1775734855" +SOURCE_DATE_EPOCH_TOUCH="202604091340" diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/limine-11.2.0/version new/limine-11.3.1/version --- old/limine-11.2.0/version 2026-04-02 23:33:07.000000000 +0200 +++ new/limine-11.3.1/version 2026-04-09 13:44:53.000000000 +0200 @@ -1 +1 @@ -11.2.0 +11.3.1
