Commit Graph

522 Commits

Author SHA1 Message Date
Andy-Python-Programmer cce7fa4e1e
acpi_get_rsdp: UEFI RSDP lookup return RSDPv1
* This commit makes the acpi_get_rsdp function to return the RSDPv1 if
avaliable (in UEFI) to match this functions behaviour under BIOS where
it returns the XSDP or the RSDP depending on which one is avaliable.

Signed-off-by: Andy-Python-Programmer <andypythonappdeveloper@gmail.com>
2021-10-05 09:34:51 +11:00
Andy-Python-Programmer 60180f7eaf
multiboot2: add the EFI image handle tag
Signed-off-by: Andy-Python-Programmer <andypythonappdeveloper@gmail.com>
2021-10-04 11:39:37 +11:00
mintsuki 10438e51c0 multiboot: Zero out all undefined GPRs before handoff 2021-10-02 22:17:22 +02:00
mintsuki 0e9d145b2a elf: Fix off-by-1 comparisons 2021-10-02 21:32:47 +02:00
mintsuki a6acfb7606 pmm: Workaround for cases in which AllocatePages fails during initialisation 2021-10-02 21:14:42 +02:00
mintsuki 244b461700 gterm: Cursor print bug fix 2021-10-01 07:08:02 +02:00
mintsuki 624f193421 ntfs: Fix compilation errors 2021-09-29 17:47:24 +02:00
Itay Almog f2486dcded Added support for resident directory indexes 2021-09-29 18:04:08 +03:00
Itay Almog 02ea23abfa Runlist elements are relative to the last runlist, so make that work 2021-09-29 18:04:08 +03:00
Itay Almog 893020f303 cleanup and bufixes
ntfs is weird so we can't trust the names in the index since sometimes they are wrong (?)
also the read function should return 0 for success and not read size...
2021-09-29 00:31:59 +03:00
Itay Almog 0cb083b3e4 ntfs is now fully working, or at least we can boot limine with it 2021-09-29 00:31:59 +03:00
Itay Almog 3f37d82cdd got directory reading and more specifically root directory reading 2021-09-29 00:31:59 +03:00
Itay Almog 66564de7e0 We can now get file records from the MFT 2021-09-29 00:31:59 +03:00
Itay Almog 10caa22bbc got basic mft parsing 2021-09-29 00:31:59 +03:00
Itay Almog eced64231d Added test to makefile 2021-09-29 00:31:59 +03:00
Itay Almog f59f18458c Starting to work on NTFS 2021-09-29 00:31:59 +03:00
mintsuki 34cfd0e55b term: Fix bug related to scrolling regions 2021-09-28 06:17:42 +02:00
mintsuki bca6f924ba term: Overhaul (4) 2021-09-28 02:05:47 +02:00
mintsuki 1332be4e2a term: Overhaul (3) 2021-09-27 23:43:25 +02:00
mintsuki bd4646f0ad chainload: Misc bug fixes and improvements 2021-09-27 04:04:15 +02:00
mintsuki fabf2aef8c term: Overhaul (2) 2021-09-26 20:59:38 +02:00
mintsuki ea2665c53b term: Overhaul (1) 2021-09-26 18:16:55 +02:00
mintsuki 46e1380f02 menu: Misc editor improvements 2021-09-25 04:52:18 +02:00
mintsuki b7176d5cfa bmp: Ensure that bf_offset + bf_size <= file size 2021-09-25 02:02:21 +02:00
mintsuki 5374e4e1f2 bios: Call a20_enable() before doing anything else 2021-09-23 00:17:15 +02:00
mintsuki dbab5f6063 apic: Do not attempt an APIC flush for protocols that don't mask IRQs 2021-09-22 12:33:56 +02:00
mintsuki 5a4a6151b9 stivale: Pass the right number of arguments to common_spinup() 2021-09-21 20:01:02 +02:00
mintsuki 4d40e73692 efi: Disable watchdog timer 2021-09-21 18:56:20 +02:00
mintsuki 56ceffb44b entry: Move some initialisation calls to after config initialisation 2021-09-21 18:40:23 +02:00
mintsuki 46be45fabc spinup64: Don't smash argument registers when calling flush_irqs() 2021-09-21 18:34:41 +02:00
mintsuki 21b926fb70 idt: Move flush_irq() logic to stage 3 2021-09-21 17:44:01 +02:00
mintsuki c2e279db66 protos: Remove now-useless pic_flush() calls 2021-09-21 17:34:24 +02:00
mintsuki 7637f94efa apic: Improve pending IRQ flushing mechanism 2021-09-21 17:28:32 +02:00
mintsuki 289030a105 build: Resolve some potential dependency race on gnu-efi 2021-09-21 15:02:37 +02:00
mintsuki f73a19b5d5 apic: Do not panic if APIC not found 2021-09-21 14:49:48 +02:00
mintsuki b29a513e6c apic: Add logic to mask all IO APIC GSIs. Fixes #111 2021-09-21 11:11:52 +02:00
mintsuki 521cb1728a stivale: Make unaligned stack request a warning rather than a panic 2021-09-19 14:42:40 +02:00
mintsuki 04732c6221 multiboot2: Add support for EFI system table tag 2021-09-14 23:12:34 +02:00
mintsuki 33692555a7 multiboot2: Add support for a.out kludge and other enhancements 2021-09-14 22:12:22 +02:00
mintsuki 35273093ba term: Cursor should flip palette 2021-09-14 20:02:09 +02:00
mintsuki ab19d6ccad menu: Clear line before reprinting timeout message 2021-09-14 18:35:42 +02:00
mintsuki fe882a8b2e multiboot1 and 2: General fixes and cleanup 2021-09-14 07:43:17 +02:00
mintsuki fa5fa057bd term: Do not parse escape-abort characters when not in runtime mode 2021-09-13 09:49:43 +02:00
mintsuki 05eb70e9f0 smp: Use rdtsc to delay rather than dummy port IO 2021-09-13 05:13:02 +02:00
mintsuki ae02de7902 multiboot2: Fix broken append_tag() invocation 2021-09-13 04:56:00 +02:00
mintsuki 4ad7081e6c multiboot2: Misc adjustments 2021-09-13 04:49:59 +02:00
mint 90bdd0dca0
Merge pull request #109 from Andy-Python-Programmer/trunk
multiboot2: initial support
2021-09-13 04:33:39 +02:00
Andy-Python-Programmer 875d90d7a0
multiboot2: add copyright notice on multiboot2 header file
Signed-off-by: Andy-Python-Programmer <andypythonappdeveloper@gmail.com>
2021-09-13 12:31:21 +10:00
Andy-Python-Programmer dab6504102
multiboot2: add kernel modules support
Signed-off-by: Andy-Python-Programmer <andypythonappdeveloper@gmail.com>
2021-09-13 12:21:31 +10:00
Andy-Python-Programmer 7ce2354c88
mutlboot2: assert that we do not overflow the mmap tags
Signed-off-by: Andy-Python-Programmer <andypythonappdeveloper@gmail.com>
2021-09-13 11:10:45 +10:00
Andy-Python-Programmer e17d34ee70
multiboot2: allocate bootinfo size AOT
Signed-off-by: Andy-Python-Programmer <andypythonappdeveloper@gmail.com>
2021-09-12 17:19:50 +10:00
Andy-Python-Programmer 8b8388b167
elf_section_hdr_info: return the info instead of void
Signed-off-by: Andy-Python-Programmer <andypythonappdeveloper@gmail.com>
2021-09-12 12:54:37 +10:00
mintsuki 7ad45e8daf term: Fix bug introduced when moving from int to size_t for coordinates. Fixes #110 2021-09-11 08:43:39 +02:00
Andy-Python-Programmer 42f821f043
multiboot2: add EFI memory map tag
Signed-off-by: Andy-Python-Programmer <andypythonappdeveloper@gmail.com>
2021-09-11 15:06:51 +10:00
Andy-Python-Programmer 5d2ce0d117
multiboot2: add ACPIv2 info tag
Signed-off-by: Andy-Python-Programmer <andypythonappdeveloper@gmail.com>
2021-09-11 14:34:22 +10:00
Andy-Python-Programmer 6f15587c85
multiboot2: add the framebuffer tag
Signed-off-by: Andy-Python-Programmer <andypythonappdeveloper@gmail.com>
2021-09-10 18:41:01 +10:00
Andy-Python-Programmer 6d034adc5a
multiboot2: implement ELF sections tag
Signed-off-by: Andy-Python-Programmer <andypythonappdeveloper@gmail.com>
2021-09-10 18:02:54 +10:00
Andy-Python-Programmer 60811e70d6
multiboot2: initial support
Signed-off-by: Andy-Python-Programmer <andypythonappdeveloper@gmail.com>
2021-09-10 13:46:41 +10:00
mintsuki 9459207ab3 ext2: Implement triply indirect blocks 2021-09-07 10:35:34 +02:00
mintsuki 3dbd494f87 disk: Signature double checking for EFI volume detection fallback 2021-09-06 08:52:41 +02:00
mintsuki f20457f671 menu: Add option to change the colour of the branding string 2021-09-06 07:31:57 +02:00
mintsuki db25c748f4 stivale1: Copy the memmap to a bootloader reclaimable region to conform with the spec 2021-09-06 03:33:15 +02:00
mintsuki dafc710c60 pmm: Allocate memory map dynamically using EFI 2021-09-03 03:10:23 +02:00
mintsuki 0410e53e3d cpu: Make rdseed() macro actually use rdseed 2021-09-02 22:59:51 +02:00
StaticSaga 62198ba1b0 fat32: fix LFN ignoring bug introduced by 25e1194 2021-09-02 11:53:43 +02:00
mintsuki 5217f50bbd pmm: Increase the max size of the memory map 2021-09-02 04:23:09 +02:00
mintsuki 86780fc776 efi: Improve reclaim memory process 2021-09-02 02:47:08 +02:00
mintsuki b00845fba0 efi: Add fallback in case we do not manage to pair the boot device handle with a volume 2021-09-02 02:11:15 +02:00
mintsuki 1a71851c7d disk: Readd readback detection method as fallback 2021-09-02 01:31:36 +02:00
mintsuki 25e119496e fat: Ignore volume label entries in directories. Fixes #107 2021-09-01 23:34:31 +02:00
mintsuki 134fd3c8bd disk: Use a different method to match EFI_HANDLEs with volumes 2021-09-01 23:01:03 +02:00
mintsuki 0af91feaef disk: Remove bogus pointer 2021-09-01 20:22:28 +02:00
mintsuki 0312020bd2 term: Nul should be ignored 2021-08-29 16:16:32 +02:00
mintsuki 12566c53b3 elf: Make allocation failure simulation more lax 2021-08-29 16:11:56 +02:00
mintsuki 0af1cdb72a readline: UEFI: getchar() rework 2021-08-26 18:22:09 +02:00
mintsuki 0562c8ef70 multiboot1: When on BIOS, set IDTR to BIOS defaults before handoff 2021-08-26 01:41:13 +02:00
mintsuki 605623bd05 disk: Improve algorithm to determine fastest transfer size 2021-08-26 01:33:43 +02:00
mintsuki 57c44befee Revert "term: Reverse video should not make the cursor invisible"
This reverts commit a5def082c3.
2021-08-26 01:23:27 +02:00
mint 9d8fd54127
Merge pull request #104 from ArsenArsen/trunk
readline: re-add emacs key support
2021-08-26 00:17:55 +02:00
Arsen Arsenović 50dcc58a77
readline: re-add emacs key support
This time, we properly check shift flags from both the firmware options,
as to not lead to conflicts with existing code. The logic for checking
whether Ctrl is being held is also a lot cleaner now.
2021-08-26 00:15:42 +02:00
mintsuki a5def082c3 term: Reverse video should not make the cursor invisible 2021-08-25 23:57:19 +02:00
mintsuki 31f52c2b30 efi: Directly use EFI functions instead of using GNU-EFI's call wrapper 2021-08-25 22:03:00 +02:00
mintsuki 23a93a85dc term: Bug fixes 2021-08-24 01:08:08 +02:00
mintsuki 16645dfb48 disk: Misc fixes 2021-08-22 22:07:48 +02:00
mintsuki 483cb4655d misc: Add copyright notice at boot 2021-08-22 18:29:18 +02:00
mintsuki 712f4c02e6 disk: Remove redundant code used to get volume count 2021-08-22 18:05:21 +02:00
mintsuki 9a934eb683 efi: Leave 64MiB to firmware instead of 16MiB 2021-08-22 17:57:52 +02:00
mintsuki 48f7dee672 cpu: Remove static from header inline functions 2021-08-22 17:37:09 +02:00
mintsuki e497c1d7f4 disk: Fix bugs introduced by previous commit 2021-08-22 17:20:22 +02:00
mintsuki 049601814a disk: Add logic to determine fastest transfer size 2021-08-22 16:27:06 +02:00
mintsuki dadca8fe17 efi: Rework EFI memory map sanitisation 2021-08-22 15:02:33 +02:00
mintsuki ee3131bdfa gterm: Rearrange logic to determine font properties 2021-08-20 22:18:15 +02:00
mintsuki cefc4a76ca gterm: Implement TERMINAL_FONT_SPACING and default it to 1 2021-08-20 19:25:42 +02:00
mintsuki f9fe2f96ed misc: Bug fixes 2021-08-20 18:28:51 +02:00
Sebastian 904488c60f
acpi: Fix wrong data type in tables header 2021-08-19 18:13:20 -05:00
mintsuki fa0aa6d7b9 gterm: Add config aliases and other minor fixes 2021-08-18 21:02:03 +02:00
Hannu Hartikainen cd02860fc1 gterm: expand font 9th column like VGA
Implement column expansion like VGA Line Graphics Mode does it, e.g. the
8th column is replicated for characters 0xC0-0xDF. Do this for all
columns above 8 so font sizes like 10x16 are also usable.
2021-08-18 16:07:48 +03:00
Hannu Hartikainen 58d128b9f3 gterm: support font scaling 2021-08-18 16:07:48 +03:00
Hannu Hartikainen c11dc2388d gterm: rename vga_font_{width,height} to lowercase
Now that the values are editable, this is the correct letter case.
However this deserves its own commit so the commit with the logical
change is easier to read.
2021-08-18 16:06:17 +03:00
Hannu Hartikainen a8a8af4c5f gterm: support different font sizes 2021-08-18 16:06:17 +03:00
Hannu Hartikainen 867b4a5fa6 gterm: fix custom MENU_FONT
The default font being already loaded in stage2 prevented a custom font
from being loaded in stage3 (at least in UEFI). If a custom font is
configured, load it.
2021-08-18 16:06:17 +03:00
mintsuki 32192f73a4 docs: Document TEXTMODE option 2021-08-17 00:58:02 +02:00
mintsuki b2e66e5a2d term: Misc improvements and fixes 2021-08-17 00:37:24 +02:00
mintsuki 385af687b3 vga_textmode: Replace BIOS calls to enable and disable hardware cursor with direct VGA port IO 2021-08-17 00:06:20 +02:00
mintsuki 19ecfe9c1e menu: Fix broken change 2021-08-17 00:00:23 +02:00
mintsuki 7e50f302e7 term: Fix broken defines and calls 2021-08-16 22:47:40 +02:00
mintsuki 17c5ec43e0 term: Finish up context control work 2021-08-16 20:56:39 +02:00
mintsuki 0b1c1ccc88 gterm: Add context control logic 2021-08-16 20:00:37 +02:00
mintsuki a3f3f95bd7 term: Implement a bunch of escape sequences 2021-08-16 19:32:09 +02:00
mintsuki 1cd381a3aa stivale2: More reasonable code flow to determine target video mode 2021-08-16 18:34:30 +02:00
mintsuki c7a46830f6 term: Mass backport changes done in Vinix upstream 2021-08-16 18:02:28 +02:00
mintsuki 993a602afb term: Support bold attributes 2021-08-12 07:52:25 +02:00
mintsuki 5f1c34a587 tftp: Overhaul and bug fixes 2021-08-12 07:40:29 +02:00
Andy-Python-Programmer 3b4d7c53fa
Implement the "stivale2_struct_tag_kernel_file_v2" tag
Signed-off-by: Andy-Python-Programmer <andypythonappdeveloper@gmail.com>
2021-08-10 18:33:03 +10:00
mintsuki 7cca9dd42f build: Misc build system improvements 2021-08-07 07:26:34 +02:00
mintsuki 5ffce7c42e term: Support DEC private escape 25 (enable/disable cursor) 2021-08-06 06:16:41 +02:00
mintsuki 6275457af0 toolchain: Use program prefix limine- to avoid collisions with x86_64-elf system toolchains 2021-08-06 05:05:50 +02:00
mintsuki 0dde09bbb9 term: Support bright colours 2021-07-31 23:51:48 +02:00
mintsuki 07dc81bbee build: Pass -mabi=sysv to cc 2021-07-31 21:28:06 +02:00
mintsuki 5d22de7733 term: Misc improvements 2021-07-31 20:52:46 +02:00
ytret 059be24d3b stivale2: set ID of textmode structure tag 2021-07-31 20:59:05 +03:00
mintsuki 9540ea620b elf: Make sure KASLR doesn't result in load addresses higher than 0x80000000 for higher half kernels 2021-07-29 15:44:27 +02:00
mintsuki af28eee1bc build: Prevent gensyms.sh from failing if pipefail is not supported by the shell 2021-07-26 20:19:40 +02:00
mintsuki db561393dd stivale: Add requested stack sanity checks. Closes #95 2021-07-26 19:25:59 +02:00
mintsuki 9d68787fe1 build: OpenBSD compatibility 2021-07-26 18:27:05 +02:00
mintsuki af03050db3 build: Make build system more BSD friendly 2021-07-26 16:09:03 +02:00
mintsuki e9760d2e33 build: Work around gnu-efi build system issue 2021-07-25 16:23:36 +02:00
mintsuki f2fcc38af7 stivale2_rt: Fix mov of the incorrect size 2021-07-25 15:23:29 +02:00
mintsuki 5089bafaf8 pmm: Fix sanitise_entries() bugs 2021-07-25 14:18:35 +02:00
mintsuki 2a4f9eb0c4 elf: Do not enforce segment load address alignment even if PMRs are requested 2021-07-25 01:18:36 +02:00
mintsuki 0e2b9c5776 term: Bound check when setting cursor position 2021-07-20 14:13:56 +02:00
mintsuki 6e1afcd3cb uefi: Initial 32 bit UEFI support 2021-07-20 13:35:43 +02:00
mintsuki f5b0a4ee25 elf: More bug fixes 2021-07-17 08:19:03 +02:00
mintsuki 5fa8ef5d37 elf: Bug fixes 2021-07-17 07:38:19 +02:00
mintsuki de3c7eed67 stivale2: Implement PMRs 2021-07-15 16:20:29 +02:00
mintsuki 79b8c38c8c stivale: Initial infrastructure to support ELF permissions 2021-07-15 14:09:12 +02:00
mintsuki 178f3cea0e elf: Return permission ranges 2021-07-15 13:34:24 +02:00
mintsuki aec537f519 menu: Fix title alignment 2021-07-15 12:51:46 +02:00
mintsuki 1aa5ae13fc misc: Change how bios and uefi macros are defined and tested 2021-07-15 10:03:47 +02:00
mintsuki d478a1b28b stivale2: Add support for text mode struct tag 2021-07-11 10:07:43 +02:00
mintsuki f5ffbdf2cd stivale2: Add support for any video header tag 2021-07-11 09:47:57 +02:00
mintsuki 63a45e2b31 stivale2: Implement max_length field of terminal structure tag 2021-07-11 08:51:22 +02:00
mintsuki f4a47cff02 gterm: Improve text drawing performance on both QEMU TCG and real hardware 2021-07-11 08:30:54 +02:00
mintsuki e5ec3c1fb3 gterm: Reintroduce fast canvas drawing, only.
Co-authored-by: StaticSaga <61866965+StaticSaga@users.noreply.github.com>
2021-07-11 07:28:09 +02:00
mintsuki f4dc6481f1 gterm: Revert recent changes as they make the terminal significantly slower on real hardware 2021-07-11 04:50:15 +02:00
mintsuki 9423860745 Revert "readline: rewrite Ctrl-[pnbf] to arrows"
This reverts commit 9e2d9f1630.
2021-07-11 02:03:10 +02:00
mintsuki f66620052d Revert "readline: exclude the non-ctrl case from checks"
This reverts commit 2fcabe8dfe.
2021-07-11 02:02:50 +02:00
mintsuki 6f17771c53 menu: Disable scrolling when displaying status text 2021-07-11 02:01:03 +02:00
mintsuki 50fd990ece term: Improve logic of disabling scrolling 2021-07-11 01:51:17 +02:00
mintsuki ffac9b1c68 stivale2: Prevent buffer overflows when writing to stivale2 terminal 2021-07-11 01:31:16 +02:00