diff options
author | Dan Williams <dcbw@redhat.com> | 2010-03-08 18:04:14 -0800 |
---|---|---|
committer | Dan Williams <dcbw@redhat.com> | 2010-03-08 18:04:14 -0800 |
commit | 29a67e9d89f2f4538ae9b0e3e09db6d087b84f61 (patch) | |
tree | d83592b6ddf4aaa19cb9975eafd4197b9b6e9e39 | |
parent | cdf9279ee8cb52d13242dbfad0e8c07c6d7270f3 (diff) |
huawei: unify GSM device probing
Using the USB product ID to direct certain modems to the generic
driver is wrong since even new modems like the E1550 are 0x1001
after the modeswitch. Instead, lets assume that most current modes
use the Huawei-specific AT command set.
-rw-r--r-- | plugins/mm-plugin-huawei.c | 15 |
1 files changed, 4 insertions, 11 deletions
diff --git a/plugins/mm-plugin-huawei.c b/plugins/mm-plugin-huawei.c index ad799f0a..96edc086 100644 --- a/plugins/mm-plugin-huawei.c +++ b/plugins/mm-plugin-huawei.c @@ -283,16 +283,9 @@ grab_port (MMPluginBase *base, caps = mm_plugin_base_supports_task_get_probed_capabilities (task); if (!existing) { if (caps & MM_PLUGIN_BASE_PORT_CAP_GSM) { - if (product == 0x1001) { - /* This modem is handled by generic GSM driver */ - modem = mm_generic_gsm_new (sysfs_path, - mm_plugin_base_supports_task_get_driver (task), - mm_plugin_get_name (MM_PLUGIN (base))); - } else { - modem = mm_modem_huawei_gsm_new (sysfs_path, - mm_plugin_base_supports_task_get_driver (task), - mm_plugin_get_name (MM_PLUGIN (base))); - } + modem = mm_modem_huawei_gsm_new (sysfs_path, + mm_plugin_base_supports_task_get_driver (task), + mm_plugin_get_name (MM_PLUGIN (base))); } else if (caps & CAP_CDMA) { modem = mm_modem_huawei_cdma_new (sysfs_path, mm_plugin_base_supports_task_get_driver (task), @@ -312,7 +305,7 @@ grab_port (MMPluginBase *base, MMPortType ptype = MM_PORT_TYPE_UNKNOWN; info = g_object_get_data (G_OBJECT (task), TAG_SUPPORTS_INFO); - if (info && info->secondary && (product != 0x1001)) + if (info && info->secondary) ptype = MM_PORT_TYPE_SECONDARY; modem = existing; |