Merge pull request #21992 from osedl/pr/20230901-modemmanager-fix-permission-denied
modemmanager: Fix Permission Denied error
This commit is contained in:
commit
a2f2d6a5d3
3 changed files with 9 additions and 17 deletions
|
@ -9,7 +9,7 @@ include $(TOPDIR)/rules.mk
|
|||
|
||||
PKG_NAME:=modemmanager
|
||||
PKG_SOURCE_VERSION:=1.20.6
|
||||
PKG_RELEASE:=12
|
||||
PKG_RELEASE:=13
|
||||
|
||||
PKG_SOURCE_PROTO:=git
|
||||
PKG_SOURCE_URL:=https://gitlab.freedesktop.org/mobile-broadband/ModemManager.git
|
||||
|
|
|
@ -29,7 +29,12 @@ MODEM_DEVICE=$(modemmanager_get_field "${MODEM_STATUS}" "modem.generic.device")
|
|||
CFG=$(mm_get_modem_config "${MODEM_DEVICE}")
|
||||
[ -n "${CFG}" ] || exit 3
|
||||
|
||||
logger -t "modemmanager" "interface ${CFG} (network device ${INTERFACE}) ${STATE}"
|
||||
proto_init_update $INTERFACE 0
|
||||
proto_send_update $CFG
|
||||
IFUP=$(ifstatus "${CFG}" | jsonfilter -e "@.up")
|
||||
|
||||
[ "${IFUP}" = "true" ] && {
|
||||
logger -t "modemmanager" "interface ${CFG} (network device ${INTERFACE}) ${STATE}"
|
||||
proto_init_update $INTERFACE 0
|
||||
proto_send_update $CFG
|
||||
}
|
||||
|
||||
exit 0
|
||||
|
|
|
@ -323,15 +323,6 @@ modemmanager_connected_method_static_ipv6() {
|
|||
proto_send_update "${interface}"
|
||||
}
|
||||
|
||||
modemmanager_disconnected_method_common() {
|
||||
local interface="$1"
|
||||
|
||||
echo "running disconnection (common)"
|
||||
|
||||
proto_init_update "*" 0
|
||||
proto_send_update "${interface}"
|
||||
}
|
||||
|
||||
proto_modemmanager_init_config() {
|
||||
available=1
|
||||
no_device=1
|
||||
|
@ -628,7 +619,6 @@ proto_modemmanager_teardown() {
|
|||
|
||||
# disconnection handling only requires special treatment in IPv4/PPP
|
||||
[ "${bearermethod_ipv4}" = "ppp" ] && modemmanager_disconnected_method_ppp_ipv4 "${interface}"
|
||||
modemmanager_disconnected_method_common "${interface}"
|
||||
|
||||
# disconnect
|
||||
mmcli --modem="${device}" --simple-disconnect ||
|
||||
|
@ -640,9 +630,6 @@ proto_modemmanager_teardown() {
|
|||
# low power, only if requested
|
||||
[ "${lowpower:-0}" -lt 1 ] ||
|
||||
mmcli --modem="${device}" --set-power-state-low
|
||||
|
||||
proto_init_update "*" 0
|
||||
proto_send_update "$interface"
|
||||
}
|
||||
|
||||
[ -n "$INCLUDE_ONLY" ] || {
|
||||
|
|
Loading…
Reference in a new issue