mirror of
https://github.com/DragonOS-Community/DragonOS.git
synced 2025-06-19 00:46:31 +00:00
🆕 切换为grub2引导,能进入Start_Kernel函数(未能完成初始化)
This commit is contained in:
@ -13,10 +13,10 @@
|
||||
#include "syscall/syscall.h"
|
||||
|
||||
unsigned int *FR_address = (unsigned int *)0xffff800000a00000; //帧缓存区的地址
|
||||
// char fxsave_region[512] __attribute__((aligned(16)));
|
||||
// char fxsave_region[512] __attribute__((aligned(16)));
|
||||
|
||||
struct memory_desc memory_management_struct = {{0}, 0};
|
||||
//struct Global_Memory_Descriptor memory_management_struct = {{0}, 0};
|
||||
struct memory_desc memory_management_struct = {{0}, 0};
|
||||
// struct Global_Memory_Descriptor memory_management_struct = {{0}, 0};
|
||||
|
||||
void show_welcome()
|
||||
{
|
||||
@ -37,7 +37,6 @@ void show_welcome()
|
||||
printk_color(0x00e0ebeb, 0x00e0ebeb, " \n\n");
|
||||
}
|
||||
|
||||
|
||||
// 测试内存管理单元
|
||||
/*
|
||||
void test_mm()
|
||||
@ -63,18 +62,16 @@ void test_mm()
|
||||
// 初始化系统各模块
|
||||
void system_initialize()
|
||||
{
|
||||
// 初始化printk
|
||||
init_printk(1440, 900, FR_address, 1440 * 900 * 4, 8, 16);
|
||||
|
||||
// 初始化printk
|
||||
init_printk(1024, 768, FR_address, 1024 * 768 * 4, 8, 16);
|
||||
printk("11111\n");
|
||||
load_TR(10); // 加载TR寄存器
|
||||
|
||||
while(1);
|
||||
// 初始化任务状态段表
|
||||
ul tss_item_addr = 0xffff800000007c00;
|
||||
|
||||
|
||||
set_TSS64(_stack_start, _stack_start, _stack_start, tss_item_addr, tss_item_addr,
|
||||
tss_item_addr, tss_item_addr, tss_item_addr, tss_item_addr, tss_item_addr);
|
||||
|
||||
|
||||
|
||||
// 初始化中断描述符表
|
||||
init_sys_vector();
|
||||
@ -96,12 +93,10 @@ void Start_Kernel(void)
|
||||
{
|
||||
|
||||
system_initialize();
|
||||
|
||||
|
||||
// show_welcome();
|
||||
// test_mm();
|
||||
|
||||
|
||||
|
||||
while (1)
|
||||
;
|
||||
}
|
||||
|
Reference in New Issue
Block a user