1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-06-01 06:38:10 +00:00
serenity/Kernel/Arch
Daniel Bertalan 81dd29f713 Kernel/aarch64: Support reading the command line via the RPi Mailbox
This reuses the existing `RPi::Mailbox` interface to read the command
line via a VideoCore-specific mailbox message. This will have to be
replaced if that interface starts being smarter, as this is needed very
early, and nothing guarantees that a smarter Mailbox interface wouldn't
need to allocate or log, which is a no-no during early boot.

As the response string can be arbitrarily long, it's the caller's job to
provide a long enough buffer for `Mailbox::query_kernel_command_line`.
This commit chose 512 bytes, as it provides a large enough headroom over
the 150-200 characters implicitly added by the VC firmware.

The portable way would be to parse the `/chosen/bootargs` property of
the device tree, but we currently lack the scaffolding for doing that.

Support for this in QEMU relies on a patch that has not yet been
accepted upstream, but is available via our `Toolchain/BuildQEMU.sh`
script. It should, however, work on bare metal.

Tested-By: Timon Kruiper <timonkruiper@gmail.com>
2023-04-29 08:24:18 +02:00
..
aarch64 Kernel/aarch64: Support reading the command line via the RPi Mailbox 2023-04-29 08:24:18 +02:00
x86_64 Revert "Kernel/x86: Bake the Prekernel and the Kernel into one image" 2023-04-28 23:24:19 +02:00
CPU.h Kernel: Reorganize Arch/x86 directory to Arch/x86_64 after i686 removal 2022-12-28 11:53:41 +01:00
CurrentTime.h Kernel: Abstract platform-specific current time methods from Scheduler 2022-10-14 14:13:51 +02:00
DebugOutput.h Kernel: Abstract platform-specific serial port access from kprintf 2022-09-20 18:43:05 +01:00
DeferredCallEntry.h Kernel: Extract DeferredCallEntry from Arch/Processor.h 2021-12-11 13:23:27 -08:00
DeferredCallPool.cpp Kernel: Move deferred call code into separate DeferredCallPool class 2023-04-03 20:01:28 -06:00
DeferredCallPool.h Kernel: Move deferred call code into separate DeferredCallPool class 2023-04-03 20:01:28 -06:00
Delay.h Kernel: Move IO delay code to x86 architecture subdirectory 2022-09-20 18:43:05 +01:00
init.cpp Kernel/aarch64: Support reading the command line via the RPi Mailbox 2023-04-29 08:24:18 +02:00
InterruptManagement.h Kernel: Reorganize Arch/x86 directory to Arch/x86_64 after i686 removal 2022-12-28 11:53:41 +01:00
Interrupts.h Kernel: Reorganize Arch/x86 directory to Arch/x86_64 after i686 removal 2022-12-28 11:53:41 +01:00
IRQController.h Kernel: Reorganize Arch/x86 directory to Arch/x86_64 after i686 removal 2022-12-28 11:53:41 +01:00
mcontext.h Kernel+Userland: Remove uses of the __i386__ compiler macro 2022-12-28 11:53:41 +01:00
PageDirectory.h Kernel: Reorganize Arch/x86 directory to Arch/x86_64 after i686 removal 2022-12-28 11:53:41 +01:00
PageFault.cpp Kernel: Remove heuristics for detecting malformed malloc memory access 2023-03-01 19:36:53 -07:00
PageFault.h Kernel/aarch64: Handle instruction aborts 2023-02-08 18:19:48 +00:00
Processor.cpp Kernel: Add enum InterruptsState and helper functions 2022-08-26 12:51:57 +02:00
Processor.h Kernel: Reorganize Arch/x86 directory to Arch/x86_64 after i686 removal 2022-12-28 11:53:41 +01:00
ProcessorSpecificDataID.h Kernel: Extract ProcessorSpecificDataID from from Arch/Processor.h 2021-12-11 13:23:27 -08:00
RegisterState.h Kernel: Reorganize Arch/x86 directory to Arch/x86_64 after i686 removal 2022-12-28 11:53:41 +01:00
SafeMem.h Everywhere: Fix order of includes and #pragma once 2022-09-18 18:30:05 -07:00
SmapDisabler.h Kernel: Split SmapDisabler so header is platform independent 2021-10-15 21:48:45 +01:00
ThreadRegisters.h Kernel: Move ThreadRegisters into arch-specific directory 2022-12-29 19:32:20 -07:00
TrapFrame.h Kernel: Reorganize Arch/x86 directory to Arch/x86_64 after i686 removal 2022-12-28 11:53:41 +01:00