A bit of cleanup
This commit is contained in:
parent
fef9a11d16
commit
d80e87991e
@ -9,6 +9,7 @@ OBJ := $(patsubst %, %.o, $(basename $(SRC)))
|
|||||||
|
|
||||||
CFLAGS ?= -Wall -Wextra
|
CFLAGS ?= -Wall -Wextra
|
||||||
CFLAGS += -ffreestanding
|
CFLAGS += -ffreestanding
|
||||||
|
CPPFLAGS += -I include
|
||||||
|
|
||||||
all: kernel
|
all: kernel
|
||||||
|
|
||||||
|
@ -1,14 +1,4 @@
|
|||||||
#define MBOOT1_MAGIC 0x1BADB002
|
#include <multiboot.h>
|
||||||
#define MBOOT1_PALIGN 0x01
|
|
||||||
#define MBOOT1_MEMINFO 0x02
|
|
||||||
#define MBOOT1_FLAGS (MBOOT1_PALIGN | MBOOT1_MEMINFO)
|
|
||||||
#define MBOOT1_CS -(MBOOT1_FLAGS + MBOOT1_MAGIC)
|
|
||||||
|
|
||||||
#define MBOOT2_MAGIC 0xE85250D6
|
|
||||||
#define MBOOT2_ARCH 0
|
|
||||||
#define MBOOT2_LENGTH (MultiBootHeader2End - MultiBootHeader2)
|
|
||||||
#define MBOOT2_CHECKSUM -(MBOOT2_MAGIC + MBOOT2_ARCH + MBOOT2_LENGTH)
|
|
||||||
|
|
||||||
.intel_syntax noprefix
|
.intel_syntax noprefix
|
||||||
|
|
||||||
.section .multiboot
|
.section .multiboot
|
||||||
|
12
src/kernel/include/multiboot.h
Normal file
12
src/kernel/include/multiboot.h
Normal file
@ -0,0 +1,12 @@
|
|||||||
|
#pragma once
|
||||||
|
|
||||||
|
#define MBOOT1_MAGIC 0x1BADB002
|
||||||
|
#define MBOOT1_PALIGN 0x01
|
||||||
|
#define MBOOT1_MEMINFO 0x02
|
||||||
|
#define MBOOT1_FLAGS (MBOOT1_PALIGN | MBOOT1_MEMINFO)
|
||||||
|
#define MBOOT1_CS -(MBOOT1_FLAGS + MBOOT1_MAGIC)
|
||||||
|
|
||||||
|
#define MBOOT2_MAGIC 0xE85250D6
|
||||||
|
#define MBOOT2_ARCH 0
|
||||||
|
#define MBOOT2_LENGTH (MultiBootHeader2End - MultiBootHeader2)
|
||||||
|
#define MBOOT2_CHECKSUM -(MBOOT2_MAGIC + MBOOT2_ARCH + MBOOT2_LENGTH)
|
Loading…
x
Reference in New Issue
Block a user