Skip to content

Commit 8b60393

Browse files
authoredJun 22, 2024
Update NetworkManager.py
add LOOPBACK, HSR
1 parent 2022d7f commit 8b60393

File tree

1 file changed

+8
-2
lines changed

1 file changed

+8
-2
lines changed
 

Diff for: ‎NetworkManager.py

+8-2
Original file line numberDiff line numberDiff line change
@@ -396,7 +396,9 @@ def device_class(typ):
396396
NM_DEVICE_TYPE_WIREGUARD: WireGuard,
397397
NM_DEVICE_TYPE_VRF: Vrf,
398398
NM_DEVICE_TYPE_WIFI_P2P: WifiP2p,
399-
}[typ]
399+
NM_DEVICE_TYPE_LOOPBACK: Loopback,
400+
NM_DEVICE_TYPE_HSR: Hsr
401+
}.get(typ, Generic)
400402

401403
class Adsl(Device): pass
402404
class Bluetooth(Device): pass
@@ -427,7 +429,9 @@ class SixLoWpan(Device): pass
427429
class WireGuard(Device): pass
428430
class WifiP2p(Device): pass
429431
class Vrf(Device): pass
430-
432+
class Loopback(Device): pass
433+
class Hsr(Device): pass
434+
431435
class NSP(TransientNMDbusInterface):
432436
interface_names = ['org.freedesktop.NetworkManager.Wimax.NSP']
433437

@@ -821,6 +825,8 @@ def cert_to_dbus(cert):
821825
NM_DEVICE_TYPE_WIREGUARD = 29
822826
NM_DEVICE_TYPE_WIFI_P2P = 30
823827
NM_DEVICE_TYPE_VRF = 31
828+
NM_DEVICE_TYPE_LOOPBACK = 32
829+
NM_DEVICE_TYPE_HSR = 33
824830
NM_DEVICE_CAP_NONE = 0
825831
NM_DEVICE_CAP_NM_SUPPORTED = 1
826832
NM_DEVICE_CAP_CARRIER_DETECT = 2

0 commit comments

Comments
 (0)
Please sign in to comment.