summaryrefslogtreecommitdiffstats
path: root/plugins/udev.c
diff options
context:
space:
mode:
authorMichael Schloh von Bennewitz <ofonoconn@encambio.com>2011-06-30 00:39:44 -0500
committerDenis Kenzior <denkenz@gmail.com>2011-06-30 00:39:44 -0500
commita90d81e310b65e25dc893c06b82577462ea920a6 (patch)
tree729cfdbbc1168100472b5c223125c2b929ead658 /plugins/udev.c
parentc19dea98892d213b53ae1e26326c5b490fd37300 (diff)
downloadofono-a90d81e310b65e25dc893c06b82577462ea920a6.tar.bz2
udev: fix detection of HP HS2330 (3607gw)
commit 6a2847f7aba5d84b06940ee29300d4b6fd31d682 introduced basic detection of HP HS2330 based on OEM Ericsson F3607gw modems. Because some (or all?) HS2330 modems contain flawed text identifiers containing strange (probably erroneous) binary sequences in place of the ASCII space '\x20' character, the previous commit is incomplete. The following logic detects the modem properly, by comparing binary data as well as ASCII text values.
Diffstat (limited to 'plugins/udev.c')
-rw-r--r--plugins/udev.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/plugins/udev.c b/plugins/udev.c
index 8ea937c7..4faf63e1 100644
--- a/plugins/udev.c
+++ b/plugins/udev.c
@@ -134,6 +134,7 @@ static void add_mbm(struct ofono_modem *modem,
(g_str_has_suffix(desc, "Minicard Data Modem") ||
g_str_has_suffix(desc, "Mini-Card Data Modem") ||
g_str_has_suffix(desc, "Module Data Modem") ||
+ g_str_has_suffix(desc, "Module\xc2\xa0""Data Modem") ||
g_str_has_suffix(desc, "Broadband Data Modem"))) {
devnode = udev_device_get_devnode(udev_device);
ofono_modem_set_string(modem, DATA_DEVICE, devnode);