Browse Source

Merge pull request #16936 from aleksander0m/aleksander/mm-wwan-subsystem

modemmanager: add support for wwan subsystem in hotplug
lilik-openwrt-22.03
Florian Eckert 3 years ago
committed by GitHub
parent
commit
9301cf124a
No known key found for this signature in database GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 18 additions and 0 deletions
  1. +3
    -0
      net/modemmanager/Makefile
  2. +15
    -0
      net/modemmanager/files/25-modemmanager-wwan

+ 3
- 0
net/modemmanager/Makefile View File

@ -131,6 +131,9 @@ define Package/modemmanager/install
$(INSTALL_DIR) $(1)/etc/hotplug.d/tty $(INSTALL_DIR) $(1)/etc/hotplug.d/tty
$(INSTALL_DATA) ./files/25-modemmanager-tty $(1)/etc/hotplug.d/tty $(INSTALL_DATA) ./files/25-modemmanager-tty $(1)/etc/hotplug.d/tty
$(INSTALL_DIR) $(1)/etc/hotplug.d/wwan
$(INSTALL_DATA) ./files/25-modemmanager-wwan $(1)/etc/hotplug.d/wwan
$(INSTALL_DIR) $(1)/lib/netifd/proto $(INSTALL_DIR) $(1)/lib/netifd/proto
$(INSTALL_BIN) ./files/modemmanager.proto $(1)/lib/netifd/proto/modemmanager.sh $(INSTALL_BIN) ./files/modemmanager.proto $(1)/lib/netifd/proto/modemmanager.sh
endef endef


+ 15
- 0
net/modemmanager/files/25-modemmanager-wwan View File

@ -0,0 +1,15 @@
#!/bin/sh
# Copyright (C) 2021 Aleksander Morgado <aleksander@aleksander.es>
# Load hotplug common utilities
. /usr/share/ModemManager/modemmanager.common
# We require a device name
[ -n "$DEVNAME" ] || exit
# Always make sure the rundir exists
mkdir -m 0755 -p "${MODEMMANAGER_RUNDIR}"
# Report wwan
mm_log "${ACTION} wwan control port ${DEVNAME}: event processed"
mm_report_event "${ACTION}" "${DEVNAME}" "wwan" "/sys${DEVPATH}"

Loading…
Cancel
Save