gemalto: add detection of ALS3 modem

The product ID is added to the list of
modems to be detected by Ofono.
The gemalto plugin is used to handle the
ALS3 modem.
This commit is contained in:
Gabriel Lucas 2018-03-15 13:49:25 +01:00 committed by Denis Kenzior
parent 5d346349fb
commit 245d6a8a77
1 changed files with 18 additions and 0 deletions

View File

@ -1132,6 +1132,7 @@ static gboolean setup_gemalto(struct modem_info* modem)
DBG("%s %s %s %s %s", info->devnode, info->interface,
info->number, info->label, info->subsystem);
/* PHS8-P */
if (g_strcmp0(info->interface, "255/255/255") == 0) {
if (g_strcmp0(info->number, "01") == 0)
gps = info->devnode;
@ -1144,6 +1145,20 @@ static gboolean setup_gemalto(struct modem_info* modem)
else if (g_strcmp0(info->subsystem, "usbmisc") == 0)
qmi = info->devnode;
}
/* ALS3 */
if (g_strcmp0(info->interface, "2/2/1") == 0) {
if (g_strcmp0(info->number, "00") == 0)
mdm = info->devnode;
else if (g_strcmp0(info->number, "02") == 0)
app = info->devnode;
else if (g_strcmp0(info->number, "04") == 0)
gps = info->devnode;
}
if (g_strcmp0(info->interface, "2/6/0") == 0) {
if (g_strcmp0(info->subsystem, "net") == 0)
net = info->devnode;
}
}
DBG("application=%s gps=%s modem=%s network=%s qmi=%s",
@ -1156,6 +1171,7 @@ static gboolean setup_gemalto(struct modem_info* modem)
ofono_modem_set_string(modem->modem, "GPS", gps);
ofono_modem_set_string(modem->modem, "Modem", mdm);
ofono_modem_set_string(modem->modem, "Device", qmi);
ofono_modem_set_string(modem->modem, "Model", modem->model);
ofono_modem_set_string(modem->modem, "NetworkInterface", net);
return TRUE;
@ -1601,6 +1617,8 @@ static struct {
{ "gemalto", "option", "1e2d", "0053" },
{ "gemalto", "cdc_wdm", "1e2d", "0053" },
{ "gemalto", "qmi_wwan", "1e2d", "0053" },
{ "gemalto", "cdc_acm", "1e2d", "0061" },
{ "gemalto", "cdc_ether", "1e2d", "0061" },
{ "telit", "cdc_ncm", "1bc7", "0036" },
{ "telit", "cdc_acm", "1bc7", "0036" },
{ "xmm7xxx", "cdc_acm", "8087", "0930" },