summaryrefslogtreecommitdiff
path: root/Kernel/Prekernel/multiboot.S
diff options
context:
space:
mode:
authorJakub V. Flasar <38976370+Kubiisek@users.noreply.github.com>2022-03-08 18:21:40 +0100
committerBrian Gianforcaro <b.gianfo@gmail.com>2022-03-12 14:54:12 -0800
commit6d2c298b66a9dedbb0c32623e2aef187edce77b3 (patch)
treede441af6769da016638632af14d472568e210915 /Kernel/Prekernel/multiboot.S
parentf94293f1216f4843dcba87c8809f17cb619e154f (diff)
downloadserenity-6d2c298b66a9dedbb0c32623e2aef187edce77b3.zip
Kernel: Move aarch64 Prekernel into Kernel
As there is no need for a Prekernel on aarch64, the Prekernel code was moved into Kernel itself. The functionality remains the same. SERENITY_KERNEL_AND_INITRD in run.sh specifies a kernel and an inital ramdisk to be used by the emulator. This is needed because aarch64 does not need a Prekernel and the other ones do.
Diffstat (limited to 'Kernel/Prekernel/multiboot.S')
-rw-r--r--Kernel/Prekernel/multiboot.S28
1 files changed, 28 insertions, 0 deletions
diff --git a/Kernel/Prekernel/multiboot.S b/Kernel/Prekernel/multiboot.S
new file mode 100644
index 0000000000..1d43fa799b
--- /dev/null
+++ b/Kernel/Prekernel/multiboot.S
@@ -0,0 +1,28 @@
+.code32
+.set MULTIBOOT_MAGIC, 0x1badb002
+.set MULTIBOOT_PAGE_ALIGN, 0x1
+.set MULTIBOOT_MEMORY_INFO, 0x2
+.set MULTIBOOT_VIDEO_MODE, 0x4
+.set multiboot_flags, MULTIBOOT_PAGE_ALIGN | MULTIBOOT_MEMORY_INFO
+.set multiboot_checksum, -(MULTIBOOT_MAGIC + multiboot_flags)
+
+.section .multiboot, "a"
+.align 4
+
+.long MULTIBOOT_MAGIC
+.long multiboot_flags
+.long multiboot_checksum
+
+
+/* for MULTIBOOT_MEMORY_INFO */
+.long 0x00000000 /* header_addr */
+.long 0x00000000 /* load_addr */
+.long 0x00000000 /* load_end_addr */
+.long 0x00000000 /* bss_end_addr */
+.long 0x00000000 /* entry_addr */
+
+/* for MULTIBOOT_VIDEO_MODE */
+.long 0x00000000 /* mode_type */
+.long 1280 /* width */
+.long 1024 /* height */
+.long 32 /* depth */