Console Drivers¶
A console provides a means of presenting output to the user, allowing the system to display information in a text-based format. A higher-level system component uses the console operations offered by the respective console to, e.g., write output eventually to the screen.
General Considerations¶
In order to separate higher-level console tasks, such as tracking the current write position, from the lower-level hardware interface, the console implementation should be split into what one may call a frontend and a backend:
Higher-level system components interact with the frontend via console
operations (console_operations_t), while the backend immediately
handles the hardware.
The frontend relies on specific backend operations provided by the respective
backend in order to , e.g., write individual characters to certain screen
positions and move the cursor.
The backend is typically implemented somewhere else, like, for instance, the
VGA text video driver.
In order to simplify the interaction, the console driver stores the operations
and – if need be – further information regarding the respective backend in the
driver’s private data field (console_t.driver_data) of the console
data structure (console_t).
This separation allows, hopefully, for swapping the backend, e.g., the VGA text display and a framebuffer text display.
Console Components Provided by tomOSii¶
a basic console used during boot mainly for
printkand later as a console for the tty devices.a serial console as an alternative to the basic console – mainly for debugging or automated testing. It enables output via a serial port that qemu can then redirect to stdout.
a tee console combining the above, simultaneously outputting to the screen and via a serial port.