# Include <Linux/tty_driver.h>
The header file contains the definition and declaration of struct tty_driver and some different symbols in this structure.
# Include <Linux/tty. h>
The header file contains the definition of the tty_struct structure and several different macro definitions to facilitate access to a single value of the members of the struct termios. It also contains the TTY drive core function declaration.
# Include <Linux/tty_flip.h>
The header file contains several tty flip buffer inline functions, making it easy to operate the flip Buffer structure.
# Include <ASM/termios. h>
Header file, including the definition of struct termio, used for the specific hardware platform created by the kernel.
Struct tty_driver * alloc_tty_driver (INT lines );
Create a struct tty_driver, which can be passed to the tty_register_driver and tty_unregister_driver functions.
Void put_tty_driver (struct tty_driver * driver );
Function to clear the struct tty_driver structure that has not been successfully registered to the TTY kernel.
Void tty_set_operations (struct tty_driver * driver, struct tty_operations * op );
Function to initialize the function callback of struct tty_driver. It is necessary to call this function before tty_register_driver can be called.
Int tty_register_driver (struct tty_driver * driver );
Int tty_unregister_driver (struct tty_driver * driver );
Function, register and deregister a tty driver from the TTY core.
Void tty_register_device (struct tty_driver * driver, unsigned minor, struct device * Device );
Void tty_unregister_device (struct tty_driver * driver, unsigned minor );
Register and deregister a single tty device for the TTY core.
Void tty_insert_flip_char (struct tty_struct * tty, unsigned char CH, char flag );
The function that inserts characters into the tty device's flip buffer to be read by the user.
Tty_normal
Tty_break
Tty_frame
Tty_parity
Tty_overrun
Different flag values are used in the tty_insert_flip_char function.
Int tty_get_baud_rate (struct tty_struct * tty );
Function to obtain the baud rate currently set for a specific tty device.
Void tty_flip_buffer_push (struct tty_struct * tty );
Function to push data in the current flip buffer to the user.
Tty_std_termios
Variable, uses a set of common default line settings to initialize a termios Structure