可以使用如下代码:
struct uart_state *state = tty->driver_data; struct uart_port *port = state->port; 类似的,由 uart_port 得到tty_struct 则使用如下方法:
struct tty_struct *tty = port.info->port.tty;
博客园 © 2004-2026 浙公网安备 33010602011771号 浙ICP备2021040463号-3