I am new to the OSDev world and currently writing a 64-bit OS in rust. I split the project into a bootloader which uses the uefi-rs crate and the kernel. Based on online resources, I decided to make the kernel a higher half kernel. Unfortunately, I cannot load the kernel since the VMA in the linker script is the higher half address, which can't be accessed from the bootloader. If I understand correctly uefi provides identity mapping for the entire physical address space, therefore the higher half address (in my case: 0xFFFFFFFF80000000) is not mapped to a physical one. After some more research I found 2 ways around this problem:
1. setup custom paging in my bootloader and then map the virtual address.
2. add a section in the linker script that has a valid physical address and add an assembly stub that enables paging there, maps the higher half address and calls the kernel entry
I am currently struggling with the implementation but will try to work it out. Nevertheless, I still wonder why uefi-rs does not make a method for independently mapping memory available. Is this not possible?
Thanks in advance
