getty on g_serial (ttygs) / hotplug for gadgets
Hamish Moffatt <[email protected]>
| Newsgroups | gmane.linux.usb.devel |
|---|---|
| Message-ID | <[email protected]> |
I'd like to run a getty on /dev/ttygs to allow logins over to the g_serial gadget. However I note a couple of issues; When the link is not up, opening the device returns ENODEV, so the getty respawns continuously. Also, g_serial itself logs the following each time: gs_open: (0,c3ffc000,c3c05320) device is not connected gs_close: NULL port pointer Next, if you disconnect the link while the device is open, blocking reads don't appear to fail, so the getty (or shell or whatever) doesn't notice. I think it would be useful to have g_serial (optionally) pretend to userspace that the link was always connected; if the link is down, discard (or buffer) written data, and fail/block reads. Does this sound useful? Another way to solve this would be to launch the getty when the link comes up (and also act on link down) however I don't see any hotplug events for this. Would it make sense to have events for this case? thanks Hamish -- Hamish Moffatt VK3SB <[email protected]> <[email protected]> ------------------------------------------------------------------------- This SF.net email is sponsored by DB2 Express Download DB2 Express C - the FREE version of DB2 express and take control of your XML. No limits. Just data. Click to get it now. http://sourceforge.net/powerbar/db2/ _______________________________________________ [email protected] To unsubscribe, use the last form field at: https://lists.sourceforge.net/lists/listinfo/linux-usb-devel