stos: bootvid: Add bootvid driver stub
Signed-off-by: Chloe M. <chloe@mensia.org>
This commit is contained in:
@@ -0,0 +1,28 @@
|
||||
/*
|
||||
* Copyright (c) 2026, Chloe M.
|
||||
* Provided under the BSD-3 clause.
|
||||
*
|
||||
* Description: Bootvid driver
|
||||
* Author: Chloe M.
|
||||
*/
|
||||
|
||||
#include <drivers/bootvid/fbio.h>
|
||||
#include <ke/bpal.h>
|
||||
#include <ex/trace.h>
|
||||
|
||||
#define DTRACE(Fmt, ...) \
|
||||
TRACE("[ BOOTVID ]: " Fmt, ##__VA_ARGS__)
|
||||
|
||||
static BPAL_FRAMEBUFFER Framebuffer;
|
||||
|
||||
VOID
|
||||
BootVidInit(VOID)
|
||||
{
|
||||
BPAL_HANDLE BpalHandle;
|
||||
|
||||
KeBpalGetHandle(&BpalHandle);
|
||||
Framebuffer = BpalHandle.Framebuffer;
|
||||
|
||||
DTRACE("framebuffer width: %d\n", Framebuffer.Width);
|
||||
DTRACE("framebuffer height: %d\n", Framebuffer.Height);
|
||||
}
|
||||
@@ -0,0 +1,19 @@
|
||||
/*
|
||||
* Copyright (c) 2026, Chloe M.
|
||||
* Provided under the BSD-3 clause.
|
||||
*
|
||||
* Description: Bootvid driver
|
||||
* Author: Chloe M.
|
||||
*/
|
||||
|
||||
#ifndef _BOOTVID_FBIO_H_
|
||||
#define _BOOTVID_FBIO_H_ 1
|
||||
|
||||
#include <stdef.h>
|
||||
|
||||
/*
|
||||
* Initialize the boot video driver
|
||||
*/
|
||||
VOID BootVidInit(VOID);
|
||||
|
||||
#endif /* !_BOOTVID_FBIO_H_ */
|
||||
@@ -10,6 +10,7 @@
|
||||
#include <ke/stos.h>
|
||||
#include <ke/bpal.h>
|
||||
#include <hal/serial.h>
|
||||
#include <drivers/bootvid/fbio.h>
|
||||
#include <stdef.h>
|
||||
|
||||
#define DTRACE(Fmt, ...) \
|
||||
@@ -36,4 +37,7 @@ KiKernelEntry(VOID)
|
||||
|
||||
/* Initialize BPAL */
|
||||
KeBpalInit();
|
||||
|
||||
/* Initialize boot video */
|
||||
BootVidInit();
|
||||
}
|
||||
|
||||
@@ -12,6 +12,7 @@ include ../../mk/stos.mk
|
||||
CFILES = $(shell find ../init -name "*.c")
|
||||
CFILES += $(shell find ../xt -name "*.c")
|
||||
CFILES += $(shell find ../lib -name "*.c")
|
||||
CFILES += $(shell find ../drivers -name "*.c")
|
||||
CFILES += $(shell find bpal -name "*.c")
|
||||
DFILES = $(CFILES:.c=.d)
|
||||
OFILES = $(CFILES:.c=.o)
|
||||
|
||||
Reference in New Issue
Block a user