Hi I am trying to understand the vt tty driver. I have been trying to read the code and have been referring to Linux Device Drivers book. I have read this http://www.linusakesson.net/programming/ttyto get an idea of what ttys are etc.
I have many doubts and would be very greatful if someone could help me out. I am not sure where this driver fits into the rest of things. I mean, from where are the functions in this driver called, and what does the driver actually do? Does it interact with the screen hardware? If it does, how? >From what I understand, the vt driver does the work of the 'Terminal emulator' in this http://www.linusakesson.net/programming/tty/case3.png . Am I right? The LDD3 book says that after the driver registers itself, it registers the devices it controls through the tty_register_device function. But I cannot see this being done in the vt.c file. Why? Also, there are two functions con_write and vt_console_print that write. I was told that vt_console_print is high level. It is called by the console code. con_write is low level. It writes to the tty. But I still cannot understand what each one does. Also I do not know how to find out from where these functions are called: con_write is assigned to .write of the struct tty_operations con_ops, vt_console_print .write of struct console vt_console_driver. But from where are these .write s called? This is the first time I am working with a driver or anything to do with the kernel, so even if my doubts are stupid please help me out. Thank you. -- Regards, Chinmay Bapat
_______________________________________________ Kernelnewbies mailing list [email protected] http://lists.kernelnewbies.org/mailman/listinfo/kernelnewbies
