summaryrefslogtreecommitdiffstats
path: root/drivers/mbmmodem/location-reporting.c
diff options
context:
space:
mode:
authorMarcel Holtmann <marcel@holtmann.org>2011-07-29 20:50:37 +0200
committerMarcel Holtmann <marcel@holtmann.org>2011-07-29 20:50:37 +0200
commit14806ba5271835271d6fc4c33c2760b5dd0841fe (patch)
tree36443fda6c78c5a92529ecaf3a49f40c26a42079 /drivers/mbmmodem/location-reporting.c
parent90ee6542e66a1663cd1fdbaa2e4e3eea5c0fa785 (diff)
downloadofono-14806ba5271835271d6fc4c33c2760b5dd0841fe.tar.bz2
mbmmodem: Set baud rate to 115200 for GPS interface
Diffstat (limited to 'drivers/mbmmodem/location-reporting.c')
-rw-r--r--drivers/mbmmodem/location-reporting.c12
1 files changed, 11 insertions, 1 deletions
diff --git a/drivers/mbmmodem/location-reporting.c b/drivers/mbmmodem/location-reporting.c
index 1080e62a..e167de9c 100644
--- a/drivers/mbmmodem/location-reporting.c
+++ b/drivers/mbmmodem/location-reporting.c
@@ -98,6 +98,7 @@ static int enable_data_stream(struct ofono_location_reporting *lr)
{
struct ofono_modem *modem;
const char *gps_dev;
+ GHashTable *options;
GIOChannel *channel;
GIOStatus status;
gsize written;
@@ -106,7 +107,16 @@ static int enable_data_stream(struct ofono_location_reporting *lr)
modem = ofono_location_reporting_get_modem(lr);
gps_dev = ofono_modem_get_string(modem, "GPSDevice");
- channel = g_at_tty_open(gps_dev, NULL);
+ options = g_hash_table_new(g_str_hash, g_str_equal);
+ if (options == NULL)
+ return -1;
+
+ g_hash_table_insert(options, "Baud", "115200");
+
+ channel = g_at_tty_open(gps_dev, options);
+
+ g_hash_table_destroy(options);
+
if (channel == NULL)
return -1;