The Pedigree Project
0.1
src
system
kernel
machine
mach_virt
mach_virt/Trace.cc
1
/*
2
* Copyright (c) 2026, Pedigree Developers
3
*
4
* Permission to use, copy, modify, and distribute this software for any
5
* purpose with or without fee is hereby granted.
6
*/
7
8
#include "pedigree/kernel/machine/Trace.h"
9
10
#include "DeviceTree.h"
11
#include "Serial.h"
12
13
namespace
pedigree_trace {
14
void
trace(
const
char
*
message
) {
15
const
uintptr_t base =
VirtDeviceTree::uartBase
();
16
if
(!base) {
17
return
;
18
}
19
20
for
(; *
message
; ++
message
) {
21
VirtSerial::earlyWrite
(base, *
message
);
22
}
23
VirtSerial::earlyWrite
(base,
'\n'
);
24
}
25
}
// namespace pedigree_trace
VirtDeviceTree::uartBase
static uintptr_t uartBase()
Definition
DeviceTree.cc:634
VirtSerial::earlyWrite
static void earlyWrite(uintptr_t base, char c)
Definition
mach_virt/Serial.cc:46
message
Definition
messages.c:19
Generated on Tue Sep 29 2026 04:30:13 for The Pedigree Project by
1.9.8