genode/repos/base-sel4/src/include/base/internal/raw_write_string.h
Norman Feske 2030ae678e Supplement base/log.h with raw output function
This patch introduces the Genode::raw function that prints output
directly via a low-level kernel mechanism, if available.

On base-linux, it replaces the former 'raw_write_str' function.
On base-hw, it replaces the former kernel/log.h interface.

Fixes #2012
2016-06-22 12:21:42 +02:00

31 lines
659 B
C++

/*
* \brief Kernel-specific raw-output back end
* \author Norman Feske
* \date 2016-03-08
*/
/*
* Copyright (C) 2016 Genode Labs GmbH
*
* This file is part of the Genode OS framework, which is distributed
* under the terms of the GNU General Public License version 2.
*/
#ifndef _INCLUDE__BASE__INTERNAL__RAW_WRITE_STRING_H_
#define _INCLUDE__BASE__INTERNAL__RAW_WRITE_STRING_H_
/* seL4 includes */
#include <sel4/arch/functions.h>
#include <sel4/arch/syscalls.h>
namespace Genode {
void raw_write_string(char const *str)
{
while (char c = *str++)
seL4_DebugPutChar(c);
}
}
#endif /* _INCLUDE__BASE__INTERNAL__RAW_WRITE_STRING_H_ */