diff options
author | Marcel Holtmann <marcel@holtmann.org> | 2010-06-06 15:27:34 -0700 |
---|---|---|
committer | Marcel Holtmann <marcel@holtmann.org> | 2010-06-06 15:27:34 -0700 |
commit | f1c209d973795dcd515bfd7fd93a30e88732360c (patch) | |
tree | 2b7b0ad6020b770343b6703346c8d4e5f51ba186 /plugins/hso.c | |
parent | 360abb0f5b91e20d92d8aedde71e569b6334895d (diff) | |
download | ofono-f1c209d973795dcd515bfd7fd93a30e88732360c.tar.bz2 |
Move AT_ODO quirk into HSO driver instead of network registration
Diffstat (limited to 'plugins/hso.c')
-rw-r--r-- | plugins/hso.c | 21 |
1 files changed, 19 insertions, 2 deletions
diff --git a/plugins/hso.c b/plugins/hso.c index 152e20cc..3c587e31 100644 --- a/plugins/hso.c +++ b/plugins/hso.c @@ -90,11 +90,28 @@ static void hso_debug(const char *str, void *user_data) static void cfun_enable(gboolean ok, GAtResult *result, gpointer user_data) { struct ofono_modem *modem = user_data; + struct hso_data *data = ofono_modem_get_data(modem); DBG(""); - if (ok) - ofono_modem_set_powered(modem, TRUE); + ofono_modem_set_powered(modem, ok); + + if (!ok) + return; + + /* + * Option has the concept of Speech Service versus + * Data Service. Problem is that in Data Service mode + * the card will reject all voice calls. This is a + * problem for Multi-SIM cards where one of the SIM + * cards is used in a mobile phone and thus incoming + * calls would be not signalled on the phone. + * + * 0 = Speech Service enabled + * 1 = Data Service only mode + */ + g_at_chat_send(data->app, "AT_ODO?", none_prefix, NULL, NULL, NULL); + g_at_chat_send(data->app, "AT_ODO=0", none_prefix, NULL, NULL, NULL); } static GAtChat *create_port(const char *device) |