diff options
author | Marcel Holtmann <marcel@holtmann.org> | 2009-09-02 19:37:55 -0700 |
---|---|---|
committer | Marcel Holtmann <marcel@holtmann.org> | 2009-09-02 19:37:55 -0700 |
commit | 057860c4c7731a490c451b8c7c3d68e4257159ee (patch) | |
tree | f770d4b7df8c3e411d09e1c86884c1ec0f2da578 /plugins/g1.c | |
parent | 9c45f2e74b3defa854f2c1556231f70bdc76fb13 (diff) | |
download | ofono-057860c4c7731a490c451b8c7c3d68e4257159ee.tar.bz2 |
Parse and use Device option from modem.conf
Diffstat (limited to 'plugins/g1.c')
-rw-r--r-- | plugins/g1.c | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/plugins/g1.c b/plugins/g1.c index c5155757..c0f35f35 100644 --- a/plugins/g1.c +++ b/plugins/g1.c @@ -143,11 +143,16 @@ static int g1_probe(struct ofono_modem *modem) { GAtSyntax *syntax; GAtChat *chat; + const char *device; DBG(""); + device = ofono_modem_get_string(modem, "Device"); + if (device == NULL) + return -EINVAL; + syntax = g_at_syntax_new_full(g1_feed, g1_hint, G1_STATE_IDLE); - chat = g_at_chat_new_from_tty("/dev/smd0", syntax); + chat = g_at_chat_new_from_tty(device, syntax); g_at_syntax_unref(syntax); if (chat == NULL) |