diff options
author | Marvin Borner | 2019-12-14 00:26:49 +0100 |
---|---|---|
committer | Marvin Borner | 2019-12-14 00:26:49 +0100 |
commit | 31aaf43b77bb86d3668f6903ca48ffdb0812cfe2 (patch) | |
tree | 2365961919f39eedd6f9725610e5a9db2c9ba418 /src/kernel/graphics/vesa.c | |
parent | e7d88df7a5a7e11677b68303a0d05455bf9a60d6 (diff) |
idk
Diffstat (limited to 'src/kernel/graphics/vesa.c')
-rw-r--r-- | src/kernel/graphics/vesa.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/kernel/graphics/vesa.c b/src/kernel/graphics/vesa.c index c74b34b..da8a61b 100644 --- a/src/kernel/graphics/vesa.c +++ b/src/kernel/graphics/vesa.c @@ -189,13 +189,13 @@ void set_optimal_resolution() vbe_set_mode(highest); uint32_t fb_size = vbe_width * vbe_height * vbe_bpl; - cursor_buffer = kmalloc(fb_size); - paging_set_user((uint32_t) fb, fb_size / 4096); + cursor_buffer = umalloc(fb_size); for (uint32_t z = 0; z < fb_size; z += 4096) { paging_map((uint32_t) fb + z, (uint32_t) fb + z, PT_PRESENT | PT_RW | PT_USED | PT_ALL_PRIV); paging_map((uint32_t) cursor_buffer + z, (uint32_t) cursor_buffer + z, PT_PRESENT | PT_RW | PT_USED); } - serial_write_hex((int) &fb); + paging_set_user((uint32_t) paging_get_phys((uint32_t) fb), fb_size / 4096); + serial_write_hex((int) cursor_buffer); serial_write("\n"); if (vbe_height > 1440) vesa_set_font(32); |