1
0
Fork 0
mirror of https://github.com/Ysurac/openmptcprouter-feeds.git synced 2025-03-09 15:40:03 +00:00

update mm

This commit is contained in:
suyuan168 2022-02-10 00:17:48 +08:00
parent 59eb792d64
commit 5e68aa0dd5
5 changed files with 20 additions and 57 deletions

View file

@ -20,7 +20,7 @@ MODEMMANAGER_EVENTS_CACHE="${MODEMMANAGER_RUNDIR}/events.cache"
# Common logging
mm_log() {
[ "$(uci -q get openmptcprouter.settings.debug)" = "true" ] && logger -t "ModemManager" "hotplug: $*"
logger -t "ModemManager" "hotplug: $*"
}
################################################################################
@ -39,14 +39,14 @@ mm_find_physdev_sysfs_path() {
# avoid infinite loops iterating
[ -z "${tmp_path}" ] || [ "${tmp_path}" = "/" ] && return
# for USB devices, the physical device will be that with a idVendor
# and idProduct pair of files
# For USB devices, the physical device will be that with a idVendor
# and idProduct pair of files
[ -f "${tmp_path}"/idVendor ] && [ -f "${tmp_path}"/idProduct ] && {
tmp_path=$(readlink -f "$tmp_path")
echo "${tmp_path}"
return
}
# For PCI devices, the physical device will be that with a vendor
# and device pair of files
[ -f "${tmp_path}"/vendor ] && [ -f "${tmp_path}"/device ] && {