swissChili | 3546639 | 2021-06-15 21:15:45 -0700 | [diff] [blame] | 1 | Kernel Logging |
| 2 | ============== |
| 3 | |
| 4 | Drivers and other kernel components may write log messages to the default output |
| 5 | (currently only VGA since it is the only display target implemented) using |
| 6 | ``kprintf`` in ``include/kernel/log.h``. Additional defines in the same file may |
| 7 | help differentiate different types of log messages (i.e. errors, debug |
swissChili | c3b56c1 | 2021-07-02 20:52:09 -0700 | [diff] [blame] | 8 | information, etc). |
| 9 | |
| 10 | .. code-block:: c |
swissChili | 3546639 | 2021-06-15 21:15:45 -0700 | [diff] [blame] | 11 | |
| 12 | kprintf(OKAY "Something succeeded\n"); |
swissChili | c3b56c1 | 2021-07-02 20:52:09 -0700 | [diff] [blame] | 13 | kprintf(ERROR "Something failed :(\n"); |
| 14 | // etc, see log.h for details |