Added panic()/dprintf() calls to the x86 bootloader bindings.

git-svn-id: file:///srv/svn/repos/haiku/trunk/current@7057 a95241bf-73f2-0310-859d-f6bbb57e9c96
This commit is contained in:
Axel Dörfler 2004-03-23 01:03:24 +00:00
parent 38592e0909
commit cdae4b7cf1
2 changed files with 63 additions and 0 deletions

View File

@ -0,0 +1,39 @@
/*
** Copyright 2004, Axel Dörfler, axeld@pinc-software.de. All rights reserved.
** Distributed under the terms of the OpenBeOS License.
*/
#include <boot/platform.h>
#include <boot/stdio.h>
#include <stdarg.h>
/** This works only after console_init() was called.
*/
void
panic(const char *format, ...)
{
va_list list;
puts("*** PANIC ***");
va_start(list, format);
vprintf(format, list);
va_end(list);
for (;;) ;
}
void
dprintf(const char *format, ...)
{
va_list list;
va_start(list, format);
vprintf(format, list);
va_end(list);
}

View File

@ -0,0 +1,24 @@
/*
** Copyright 2004, Axel Dörfler, axeld@pinc-software.de. All rights reserved.
** Distributed under the terms of the OpenBeOS License.
*/
#ifndef MMU_H
#define MMU_H
#include <SupportDefs.h>
#ifdef __cplusplus
extern "C" {
#endif
extern void mmu_init(void);
extern void *mmu_allocate(void *virtualAddress, size_t size);
extern void mmu_free(void *virtualAddress, size_t size);
#ifdef __cplusplus
}
#endif
#endif /* MMU_H */