From: Denis Kenzior <denkenz@gmail.com>
To: ofono@lists.linux.dev
Cc: Denis Kenzior <denkenz@gmail.com>
Subject: [PATCH 09/13] udevng: Remove non-upstream qmi_wwan_q support
Date: Thu, 31 Oct 2024 17:06:16 -0500 [thread overview]
Message-ID: <20241031220638.1582166-9-denkenz@gmail.com> (raw)
In-Reply-To: <20241031220638.1582166-1-denkenz@gmail.com>
This reverts commit:
fd1b44514315 ("udevng: Detect Quectel devices that use qmi_wwan_q driver")
---
plugins/udevng.c | 71 ++++--------------------------------------------
1 file changed, 5 insertions(+), 66 deletions(-)
diff --git a/plugins/udevng.c b/plugins/udevng.c
index f34cdcb731ee..64875a47752b 100644
--- a/plugins/udevng.c
+++ b/plugins/udevng.c
@@ -1108,19 +1108,6 @@ static gboolean setup_quectel(struct modem_info *modem)
return FALSE;
}
-static gboolean is_premultiplexed(const struct device_info *net)
-{
- struct udev_device *parent = udev_device_get_parent(net->udev_device);
-
- if (!parent)
- return FALSE;
-
- if (g_strcmp0(udev_device_get_subsystem(parent), "net") == 0)
- return TRUE;
-
- return FALSE;
-}
-
static gboolean setup_quectelqmi(struct modem_info *modem)
{
const struct device_info *net = NULL;
@@ -1128,11 +1115,6 @@ static gboolean setup_quectelqmi(struct modem_info *modem)
const char *gps = NULL;
const char *aux = NULL;
GSList *list;
- const char *premux_interfaces[8];
- int n_premux = 0;
- const char *qmap_size;
-
- memset(premux_interfaces, 0, sizeof(premux_interfaces));
DBG("%s", modem->syspath);
@@ -1144,22 +1126,12 @@ static gboolean setup_quectelqmi(struct modem_info *modem)
DBG("%s %s %s %s %s", info->devnode, info->interface,
info->number, info->label, subsystem);
- if (g_strcmp0(info->interface, "255/255/255") == 0) {
- if (g_strcmp0(subsystem, "usbmisc") == 0) {
+ if (g_strcmp0(info->interface, "255/255/255") == 0 &&
+ g_strcmp0(info->number, "04") == 0) {
+ if (g_strcmp0(subsystem, "net") == 0)
+ net = info;
+ else if (g_strcmp0(subsystem, "usbmisc") == 0)
qmi = info;
- continue;
- }
-
- if (g_strcmp0(subsystem, "net"))
- continue;
-
- if (is_premultiplexed(info)) {
- premux_interfaces[n_premux] = info->devnode;
- n_premux += 1;
- continue;
- }
-
- net = info;
} else if (g_strcmp0(info->interface, "255/0/0") == 0 &&
g_strcmp0(info->number, "01") == 0) {
gps = info->devnode;
@@ -1177,44 +1149,12 @@ static gboolean setup_quectelqmi(struct modem_info *modem)
if (setup_qmi_qmux(modem, qmi, net) < 0)
return FALSE;
- qmap_size = udev_device_get_sysattr_value(net->udev_device,
- "qmap_size");
- if (qmap_size) {
- uint32_t max_aggregation_size;
-
- if (l_safe_atou32(qmap_size, &max_aggregation_size) == 0)
- ofono_modem_set_integer(modem->modem,
- "MaxAggregationSize",
- max_aggregation_size);
- }
-
if (gps)
ofono_modem_set_string(modem->modem, "GPS", gps);
if (aux)
ofono_modem_set_string(modem->modem, "Aux", aux);
- if (n_premux) {
- char buf[256];
- int i;
-
- ofono_modem_set_integer(modem->modem,
- "NumPremuxInterfaces", n_premux);
- for (i = 0; i < n_premux; i++) {
- const char *device = premux_interfaces[i];
- int len = strlen(device);
-
- if (!len)
- continue;
-
- sprintf(buf, "PremuxInterface%d", i + 1);
- ofono_modem_set_string(modem->modem, buf, device);
- sprintf(buf, "PremuxInterface%dMuxId", i + 1);
- ofono_modem_set_integer(modem->modem, buf,
- 0x80 + device[len - 1] - '0');
- }
- }
-
return TRUE;
}
@@ -2160,7 +2100,6 @@ static struct {
{ "quectelqmi", "qmi_wwan", "2c7c", "0800" },
{ "quectelqmi", "qcserial", "2c7c", "0800" },
{ "quectelqmi", "option", "2c7c", "0800" },
- { "quectelqmi", "qmi_wwan_q", "2c7c", "0452" },
{ "ublox", "cdc_acm", "1546", "1010" },
{ "ublox", "cdc_ncm", "1546", "1010" },
{ "ublox", "cdc_acm", "1546", "1102" },
--
2.45.2
next prev parent reply other threads:[~2024-10-31 22:06 UTC|newest]
Thread overview: 14+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-10-31 22:06 [PATCH 01/13] qmi: validate TLV length Denis Kenzior
2024-10-31 22:06 ` [PATCH 02/13] gobi: Clear out service request queue on shutdown Denis Kenzior
2024-10-31 22:06 ` [PATCH 03/13] simutil: Return early if file is not found Denis Kenzior
2024-10-31 22:06 ` [PATCH 04/13] simfs: Quiet sanitizer runtime error Denis Kenzior
2024-10-31 22:06 ` [PATCH 05/13] radio-settings: quiet " Denis Kenzior
2024-10-31 22:06 ` [PATCH 06/13] gprs: Default CID range to 1..NUM_CONTEXTS -1 Denis Kenzior
2024-10-31 22:06 ` [PATCH 07/13] qmimodem: Drop call to ofono_gprs_set_cid_range Denis Kenzior
2024-10-31 22:06 ` [PATCH 08/13] gobi: Remove support for qmi_wwan_q Denis Kenzior
2024-10-31 22:06 ` Denis Kenzior [this message]
2024-10-31 22:06 ` [PATCH 10/13] gobi: Bring down the main interface at startup Denis Kenzior
2024-10-31 22:06 ` [PATCH 11/13] gobi: Support only "usb" Bus values Denis Kenzior
2024-10-31 22:06 ` [PATCH 12/13] gobi: document and validate "interfaceNumber" Denis Kenzior
2024-10-31 22:06 ` [PATCH 13/13] qmi: wda: Convert #defines to an enum Denis Kenzior
2024-11-04 22:20 ` [PATCH 01/13] qmi: validate TLV length patchwork-bot+ofono
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20241031220638.1582166-9-denkenz@gmail.com \
--to=denkenz@gmail.com \
--cc=ofono@lists.linux.dev \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.