Modem Manager gets into a funny state with CDMA modems
- From: Jason Glasgow <jglasgow google com>
- To: NetworkManager-list gnome org
- Subject: Modem Manager gets into a funny state with CDMA modems
- Date: Wed, 10 Mar 2010 18:03:13 -0500
I've been working with a Novatel Modem on a 2.6.31 kernel using the generic CDMA driver. If I enable the modem via ModemManager and then connect, everything works fine. But if I disconnect the modem using the DBUS API, and shut down ppp, ModemManager gets confused. The internal modem state indicates that the modem is now REGISTERED, but the kernel appears to have sent a hangup (G_IO_HUP) to the usb port, so mm-serial-port.c has closed the port (->fd == -1).
Other than Disable(), no command works because the ->fd is now -1.
Do you have any thoughts on the best way to fix this? And what the semantics of receiving a HUP on the modem port should be. My thought is that disconnect() should leave the modem in a registered (or enabled) state, and that fp should still be valid.
- Might it be reasonable to ignore the G_IO_HUP?
- Should we automatically reopen then port for all commands that are issued? Seems like a bad idea.
- Should we automatically reopen the port if mm_modem_get_state() > MM_MODEM_STATE_ENABLED?
- Maybe the most logical is to have G_IO_HUP invoke a callback to notify the code that originally opened the serial port that it has been closed. It then can update the state of the modem appropriately.
Thanks for your thoughts,
Jason
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]