Kernel: VESA driver has now second buffer for fast scrolling

This allows us to not read from video memory, since it was very slow

I also implemented fast path for graphics clearing and scrolling if bpp is 32
This commit is contained in:
2022-12-20 14:01:04 +02:00
parent 5e2680cade
commit 3f7a61a4d2
6 changed files with 155 additions and 65 deletions

View File

@@ -33,7 +33,7 @@ struct ParsedCommandLine
ParsedCommandLine ParseCommandLine(const char* command_line)
{
auto args = MUST(StringView(command_line).Split([](char c) { return c == ' ' || c == '\t'; }));
ParsedCommandLine result;
result.force_pic = args.Has("noapic");
return result;
@@ -52,7 +52,7 @@ extern "C" void kernel_main(multiboot_info_t* mbi, uint32_t magic)
s_multiboot_info = mbi;
if (!VESA::Initialize())
if (!VESA::PreInitialize())
{
dprintln("Could not initialize VESA");
return;
@@ -61,6 +61,7 @@ extern "C" void kernel_main(multiboot_info_t* mbi, uint32_t magic)
kmalloc_initialize();
VESA::Initialize();
ParsedCommandLine cmdline;
if (mbi->flags & 0x02)