aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAlexander Couzens <lynxis@fe80.eu>2018-09-15 19:54:16 +0200
committerPau Espin Pedrol <pespin@sysmocom.de>2019-03-25 14:38:04 +0100
commite77b82a1bd1986aab42a119e0556c5941795992e (patch)
treed465da2286ef9517fd4e59d4485a8acb98a04778
parentdb0e15dea88f7f7a80448d27b1386392e963a6de (diff)
downloadofono-osmo-gsm-tester.tar.gz
ofono-osmo-gsm-tester.tar.bz2
ofono-osmo-gsm-tester.tar.xz
ofono-osmo-gsm-tester.zip
NOT-FOR-MERGE: ignore disconnecting network interfaceosmo-gsm-tester
when moving a wwanX interface to a lxc container ofono gets "remove" event. Ignoring the "remove" events allow this to work without ofono is removing the whole modem
-rw-r--r--plugins/udevng.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/plugins/udevng.c b/plugins/udevng.c
index f689b756..f334599d 100644
--- a/plugins/udevng.c
+++ b/plugins/udevng.c
@@ -1412,6 +1412,11 @@ static gboolean check_remove(gpointer key, gpointer value, gpointer user_data)
for (list = modem->devices; list; list = list->next) {
struct device_info *info = list->data;
+ /* ignore net subsystem to allow the device to be given into
+ * an lxc container */
+ if (g_strcmp0(info->subsystem, "net") == 0)
+ continue;
+
if (g_strcmp0(info->devpath, devpath) == 0)
return TRUE;
}