fsogsmd: pdp_qmi plugin: check if registered
lukas at htc-linux.org
Sun Mar 13 21:13:54 CET 2011
Am Sonntag, den 13.03.2011, 14:02 +0000 schrieb Lukas-David Gorris:
> Trying to get a data connection up on htcleo machine, I failed because I
> didn't realize one has to wait until the radio is registered to network.
> I tested this using the SHR distribution. Settings/Connectivity menu offers a
> GUI to connect to 'GPRS'. In case of htcleo and other htc machines I
> think this should be handled by fsogsmd/src/plugins/pdp_qmi/plugin.vala
> Turns out this lacks any check for network register state. Despite the
> user not understanding why the connection is failing (no errors: it will
> just say connecting... connected.) this is particularly bad for the
> following reason:
> Once one attempts to connect in unregistered state, the device has to be
> rebooted in order to connect.
> We should add a condition that will check for
> "FreeSmartphone.GSM.DeviceStatus.ALIVE_REGISTERED" and if false, end the
> process with an according error message.
> Additionally a mechanism to check if the connection is truly up would
> be good. Dmesg might be used: it will throw some qmi0: connection
> failed error if it doesn't work.
> Smartphones-userland mailing list
> Smartphones-userland at linuxtogo.org
Ok I just found out another potential improvement to
The plugin expects the RMNET_IFACE (rmnet0) to come up automatically
after modem inits the connection.
Unfortunately this is not happening on htcleo.
So some code has to be inserted that will bring up the interface if the
environment is OK for GPRS connection.
Because we don't know if it's only necessary on htcleo (on nexus the
iface comes up automatically) it was recommended to do it configurable
for the device.
Personally I think it's not needed because it can't harm to bring up the
interface again although it's up already (nothing happens when you do
that using ifconfig afaik). Additionally it might be needed on other
devices so more devices will likely work out of the box if it will be
Conclusion: fsogsmd/src/plugins/pdp_qmi/plugin.vala can be improved by
two patches that will
1) ... check if the radio is registered to the network and
2) bring up the rmnet0 interface
before it tries to connect.
More information about the Smartphones-userland