Attach frame_buffer_console and initialize/enter blue_screen.
This enables early on-screen debug output on the raspberry pi.
This commit is contained in:
parent
94b364b469
commit
75b481f2a4
@ -2,6 +2,7 @@ SubDir HAIKU_TOP src system boot platform raspberrypi_arm ;
|
|||||||
|
|
||||||
SubDirHdrs $(HAIKU_TOP) headers private kernel boot platform $(TARGET_BOOT_PLATFORM) ;
|
SubDirHdrs $(HAIKU_TOP) headers private kernel boot platform $(TARGET_BOOT_PLATFORM) ;
|
||||||
SubDirHdrs $(HAIKU_TOP) src system boot arch $(TARGET_ARCH) ;
|
SubDirHdrs $(HAIKU_TOP) src system boot arch $(TARGET_ARCH) ;
|
||||||
|
SubDirHdrs $(HAIKU_TOP) src system kernel debug ;
|
||||||
|
|
||||||
UsePrivateHeaders [ FDirName kernel disk_device_manager ] ;
|
UsePrivateHeaders [ FDirName kernel disk_device_manager ] ;
|
||||||
UsePrivateHeaders [ FDirName graphics common ] ;
|
UsePrivateHeaders [ FDirName graphics common ] ;
|
||||||
|
@ -8,7 +8,19 @@
|
|||||||
|
|
||||||
#include "arch_framebuffer.h"
|
#include "arch_framebuffer.h"
|
||||||
|
|
||||||
|
#include "blue_screen.h"
|
||||||
|
#include "frame_buffer_console.h"
|
||||||
|
|
||||||
ArchFramebuffer *gFramebuffer = NULL;
|
ArchFramebuffer *gFramebuffer = NULL;
|
||||||
|
static bool sOnScreenDebugOutputAvailable = false;
|
||||||
|
|
||||||
|
|
||||||
|
extern "C" void
|
||||||
|
platform_video_puts(const char* string)
|
||||||
|
{
|
||||||
|
if (sOnScreenDebugOutputAvailable)
|
||||||
|
blue_screen_puts(string);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
extern "C" void
|
extern "C" void
|
||||||
@ -49,6 +61,27 @@ platform_init_video(void)
|
|||||||
if (result != B_OK)
|
if (result != B_OK)
|
||||||
return result;
|
return result;
|
||||||
|
|
||||||
return gFramebuffer->SetDefaultMode();
|
result = gFramebuffer->SetDefaultMode();
|
||||||
|
if (result != B_OK)
|
||||||
|
return result;
|
||||||
|
|
||||||
|
result = frame_buffer_update(gFramebuffer->Base(), gFramebuffer->Width(),
|
||||||
|
gFramebuffer->Height(), gFramebuffer->Depth(),
|
||||||
|
gFramebuffer->BytesPerRow());
|
||||||
|
if (result != B_OK)
|
||||||
|
return result;
|
||||||
|
|
||||||
|
result = blue_screen_init();
|
||||||
|
if (result != B_OK)
|
||||||
|
return result;
|
||||||
|
|
||||||
|
result = blue_screen_enter(false);
|
||||||
|
if (result != B_OK)
|
||||||
|
return result;
|
||||||
|
|
||||||
|
blue_screen_clear_screen();
|
||||||
|
blue_screen_puts("Welcome to very early on-screen debug output on rPi!\n");
|
||||||
|
sOnScreenDebugOutputAvailable = true;
|
||||||
|
return B_OK;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user