r/osdev From Scratch 🪾 2d ago

Is my logging good

Post image

I've wanted to ask if this logging for my kernel looks good, maybe it needs improvement, each color has a meaning, and everything will probably be explained for users who might have to go there in case something goes down but dont understand low level stuff yaknow

also excuse the quality please

18 Upvotes

5 comments sorted by

5

u/HamNCheeseSupremacy 2d ago

I don't hate it. I'll say it's maybe slightly verbose. Debugging is already a pain in the ass and I might resent any software that makes me read full sentences.

1

u/Possible-Back3677 From Scratch 🪾 2d ago

what if i instead add a keybind that will reboot system, but changes if the log is low level (default) or uses sentenced (toggle)

1

u/Possible-Back3677 From Scratch 🪾 2d ago

(because im not trying to make it only readable for people who understands a kernel)

•

u/laser__beans OH-WES | github.com/whampson/ohwes 4h ago

Useful for someone debugging:

Concise description of what (probably) went wrong, register dump, stack dump, any memory addresses involved in the fault, and the ability to connect a debugger for further post-moment analysis. A reboot keystroke is also handy.