full refactor in kernel/: now its apple-styled; im so fucking tired
This commit is contained in:
+20
-20
@@ -3,35 +3,35 @@
|
||||
|
||||
#pragma once
|
||||
|
||||
typedef unsigned int bi_u32;
|
||||
typedef unsigned long long bi_u64;
|
||||
typedef unsigned int BIUInt32;
|
||||
typedef unsigned long long BIUInt64;
|
||||
|
||||
typedef struct {
|
||||
bi_u32* base;
|
||||
bi_u64 base_size;
|
||||
bi_u64 width;
|
||||
bi_u64 height;
|
||||
bi_u64 pitch;
|
||||
} BI_Framebuffer;
|
||||
BIUInt32* base;
|
||||
BIUInt64 baseSize;
|
||||
BIUInt64 width;
|
||||
BIUInt64 height;
|
||||
BIUInt64 pitch;
|
||||
} BIFramebuffer;
|
||||
|
||||
typedef struct {
|
||||
void* map;
|
||||
bi_u64 map_size;
|
||||
bi_u64 descriptor_size;
|
||||
bi_u32 map_key;
|
||||
bi_u32 descriptor_version;
|
||||
} BI_MemoryMap;
|
||||
BIUInt64 mapSize;
|
||||
BIUInt64 descriptorSize;
|
||||
BIUInt32 mapKey;
|
||||
BIUInt32 descriptorVersion;
|
||||
} BIMemoryMap;
|
||||
|
||||
typedef struct {
|
||||
void* addr;
|
||||
bi_u64 size;
|
||||
} BI_Initramfs;
|
||||
void* address;
|
||||
BIUInt64 size;
|
||||
} BIInitramfs;
|
||||
|
||||
typedef struct {
|
||||
bi_u64 magic;
|
||||
BI_Framebuffer framebuffer;
|
||||
BI_MemoryMap mem;
|
||||
BI_Initramfs initramfs;
|
||||
BIUInt64 magic;
|
||||
BIFramebuffer framebuffer;
|
||||
BIMemoryMap memoryMap;
|
||||
BIInitramfs initramfs;
|
||||
} Bootinfo;
|
||||
|
||||
#define BOOTINFO_MAGIC 0x7465726D // term
|
||||
+19
-19
@@ -1,23 +1,23 @@
|
||||
typedef unsigned char u8;
|
||||
typedef unsigned short u16;
|
||||
typedef unsigned int u32;
|
||||
typedef unsigned long long u64;
|
||||
typedef unsigned char UInt8;
|
||||
typedef unsigned short UInt16;
|
||||
typedef unsigned int UInt32;
|
||||
typedef unsigned long long UInt64;
|
||||
|
||||
#define HOT_MAGIC 0x21544F48
|
||||
|
||||
typedef struct hot_segment {
|
||||
u64 type; // 1 = rx 2 = rw
|
||||
u64 vaddr;
|
||||
u64 offset;
|
||||
u64 filesz;
|
||||
u64 memsz;
|
||||
} hot_segment;
|
||||
typedef struct HOTSegment {
|
||||
UInt64 type; // 1 = rx 2 = rw
|
||||
UInt64 vaddr;
|
||||
UInt64 offset;
|
||||
UInt64 filesz;
|
||||
UInt64 memsz;
|
||||
} HOTSegment;
|
||||
|
||||
typedef struct hot_header {
|
||||
u32 magic; // "HOT!"
|
||||
u8 version; // 1
|
||||
u8 reserved_pad[3];
|
||||
u64 entry_point;
|
||||
u64 segments_count;
|
||||
u64 reserved;
|
||||
} hot_header;
|
||||
typedef struct HOTHeader {
|
||||
UInt32 magic; // "HOT!"
|
||||
UInt8 version; // 1
|
||||
UInt8 reserved_pad[3];
|
||||
UInt64 entry_point;
|
||||
UInt64 segments_count;
|
||||
UInt64 reserved;
|
||||
} HOTHeader;
|
||||
|
||||
Reference in New Issue
Block a user