Re: Writing a console/tty driver -- how to use tty_port?
From: Timur Tabi
Date: Thu Oct 28 2010 - 15:35:31 EST
Alan Cox wrote:
> drivers/mmc/card/sdio_uart.c
>
> is in some ways the best example, it handles all the horrible cases
> including unloading of hardware v open races, its way more than you'd
> need but does illustrate it all.
Thanks Alan. As always, you're a great help.
I've made some progress adding support for tty_port. I'm registering the ISR in
the tty_port .activate function.
I see something weird, though. I lose the console after I log in:
p4080 login: root
Password:
ehv_bc_tty_open:442 ttys=dce50000 stdout_irq=68
ehv_bc_tty_close:450 tty=dce50000
ls
logout
ehv_bc_tty_close:450 tty=dce50000
ehv_bc_console_device:390
ehv_bc_tty_open:442 ttys=dce50000 stdout_irq=68
p4080 login:
The "ehv_bc_..." lines are my debug printks.
When I type "ls", I don't get a listing. The "logout" occurs after I press ^D.
--
Timur Tabi
Linux kernel developer at Freescale
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/