OTOH, you need c[N_OUTBUF] in the console case (hvc_console_print), butIt is ok for me.
not whole hvc_struct. So cons_hvcs should be an array of structs
composed of only the lock and the buffer.
=============
And I would do it even simpler now. One c[N_OUTBUF] buffer for all consoles and a single lock.
And "char c" in struct hvc_struct.
No need for the complex logic in hvc_console_print.
So you will implement this?