diff options
author | Aleksander Morgado <aleksander@lanedo.com> | 2013-06-20 23:45:12 +0200 |
---|---|---|
committer | Aleksander Morgado <aleksander@lanedo.com> | 2013-06-24 19:44:57 +0200 |
commit | 3206e9566392e8a9678bbd49e0de9bb21ed75291 (patch) | |
tree | 20c5321317ccf6968b9de0c50a7fd7b8df853c65 /include/ModemManager-enums.h | |
parent | 30fe6eab4844966a9ad99599aeac910fd9898798 (diff) |
api,introspection: new 'Ports' property in the Modem interface
We will expose a new 'Ports' property listing all ports currently known by a
given modem. Ports which are not used but are detected as being part of the
modem will be listed with an 'unknown' port type.
This change uses the new 'MMModemPortType' enum and the new 'MMModemPortInfo'
helper struct to handle these values in libmm-glib. The already available
'MMPortType' enum hasn't been re-used for the interface because it contains
values that we don't need (e.g. IGNORED).
The port list is now also included in the modem information command of mmcli:
$ sudo mmcli -m 0
/org/freedesktop/ModemManager1/Modem/0 (device id '97b7b99e3e2bea103880545b619fb05a3cc81b26')
-------------------------
System | device: '/sys/devices/pci0000:00/0000:00:1d.0/usb2/2-1/2-1.4'
| drivers: 'qcserial, qmi_wwan'
| plugin: 'Gobi'
| primary port: 'cdc-wdm0'
| ports: 'ttyUSB0 (qcdm), ttyUSB1 (at), cdc-wdm0 (qmi), wwp0s29u1u4 (net)'
https://bugzilla.gnome.org/show_bug.cgi?id=702678
Diffstat (limited to 'include/ModemManager-enums.h')
-rw-r--r-- | include/ModemManager-enums.h | 22 |
1 files changed, 22 insertions, 0 deletions
diff --git a/include/ModemManager-enums.h b/include/ModemManager-enums.h index b268925c..f90b223b 100644 --- a/include/ModemManager-enums.h +++ b/include/ModemManager-enums.h @@ -395,6 +395,28 @@ typedef enum { /*< underscore_name=mm_modem_band >*/ } MMModemBand; /** + * MMModemPortType: + * @MM_MODEM_PORT_TYPE_UNKNOWN: Unknown. + * @MM_MODEM_PORT_TYPE_NET: Net port. + * @MM_MODEM_PORT_TYPE_AT: AT port. + * @MM_MODEM_PORT_TYPE_QCDM: QCDM port. + * @MM_MODEM_PORT_TYPE_GPS: GPS port. + * @MM_MODEM_PORT_TYPE_QMI: QMI port. + * @MM_MODEM_PORT_TYPE_MBIM: MBIM port. + * + * Type of modem port. + */ +typedef enum { /*< underscore_name=mm_modem_port_type >*/ + MM_MODEM_PORT_TYPE_UNKNOWN = 1, + MM_MODEM_PORT_TYPE_NET = 2, + MM_MODEM_PORT_TYPE_AT = 3, + MM_MODEM_PORT_TYPE_QCDM = 4, + MM_MODEM_PORT_TYPE_GPS = 5, + MM_MODEM_PORT_TYPE_QMI = 6, + MM_MODEM_PORT_TYPE_MBIM = 7 +} MMModemPortType; + +/** * MMSmsPduType: * @MM_SMS_PDU_TYPE_UNKNOWN: Unknown type. * @MM_SMS_PDU_TYPE_DELIVER: SMS has been received from the SMSC. |