From f5eaf8a3fba9178d5b55f9968a7935134641677c Mon Sep 17 00:00:00 2001 From: Marcel Holtmann Date: Sat, 25 Sep 2010 14:20:32 +0900 Subject: ifx: Allow +XSIM notification to arrive during AT+XSIMSTATE=1 When not using none_prefix for matching the responses of AT+XSIMSTATE call, it will consume all notifications. And this includes the initial SIM state that the modem sends at that point. Without this notification the SIM will never be marked as inserted. --- plugins/ifx.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'plugins') diff --git a/plugins/ifx.c b/plugins/ifx.c index 5ef947eb..451658cd 100644 --- a/plugins/ifx.c +++ b/plugins/ifx.c @@ -73,6 +73,8 @@ static char *dlc_prefixes[NUM_DLC] = { "Voice: ", "Net: ", "GPRS: ", "Aux: " }; static const char *dlc_nodes[NUM_DLC] = { "/dev/ttyGSM1", "/dev/ttyGSM2", "/dev/ttyGSM7", "/dev/ttyGSM8" }; +static const char *none_prefix[] = { NULL }; + struct ifx_data { GIOChannel *device; GAtMux *mux; @@ -246,7 +248,7 @@ static void cfun_enable(gboolean ok, GAtResult *result, gpointer user_data) FALSE, modem, NULL); /* enable XSIM and XLOCK notifications */ - g_at_chat_send(data->dlcs[AUX_DLC], "AT+XSIMSTATE=1", NULL, + g_at_chat_send(data->dlcs[AUX_DLC], "AT+XSIMSTATE=1", none_prefix, NULL, NULL, NULL); } -- cgit v1.2.3