ptos: drivers: Add bootvid driver stub

Signed-off-by: Chloe M. <chloe@yiffware.org>
This commit is contained in:
2026-07-10 06:52:38 +00:00
parent 44f0afaddd
commit 912d262318
4 changed files with 52 additions and 0 deletions
+28
View File
@@ -0,0 +1,28 @@
/*
* Copyright (c) 2026, Chloe M.
* Provided under the BSD-3 clause.
*
* Description: Boot video driver
* Author: Chloe M.
*/
#include <drivers/bootvid/fbio.h>
#include <ex/trace.h>
#include <ke/bpal.h>
#define DTRACE(Fmt, ...) \
TRACE("[ BOOTVID ]: " Fmt, ##__VA_ARGS__)
static BPAL_FRAMEBUFFER Framebuffer;
VOID
BootVidInit(VOID)
{
BPAL_HANDLE Handle;
KeBpalGetHandle(&Handle);
Framebuffer = Handle.Framebuffer;
DTRACE("framebuffer width : %d px\n", Framebuffer.Width);
DTRACE("framebuffer height : %d px\n", Framebuffer.Height);
}
+19
View File
@@ -0,0 +1,19 @@
/*
* Copyright (c) 2026, Chloe M.
* Provided under the BSD-3 clause.
*
* Description: Boot video driver
* Author: Chloe M.
*/
#ifndef _BOOTVID_FBIO_H_
#define _BOOTVID_FBIO_H_ 1
#include <ptdef.h>
/*
* Initialize the boot video driver
*/
VOID BootVidInit(VOID);
#endif /* !_BOOTVID_FBIO_H_ */
+1
View File
@@ -12,6 +12,7 @@ include ../../mk/ptos.mk
CFILES = $(shell find . -name "*.c")
CFILES += $(shell find ../lib -name "*.c")
CFILES += $(shell find ../xt -name "*.c")
CFILES += $(shell find ../drivers -name "*.c")
DFILES = $(CFILES:.c=.d)
OFILES = $(CFILES:.c=.o)
+4
View File
@@ -10,6 +10,7 @@
#include <ke/bpal.h>
#include <ex/trace.h>
#include <hal/serial.h>
#include <drivers/bootvid/fbio.h>
#include <machine/pio.h>
#include <string.h>
@@ -38,4 +39,7 @@ KiKernelInit(VOID)
/* Display the copyright */
Copyright();
/* Initialize the boot video driver */
BootVidInit();
}