diff options
author | Dan Williams <dcbw@redhat.com> | 2012-09-03 23:00:11 -0500 |
---|---|---|
committer | Aleksander Morgado <aleksander@lanedo.com> | 2012-09-08 10:34:13 +0200 |
commit | b165e39a9e30787ccddb592f22c3aa5bd4af6a55 (patch) | |
tree | 10bb357c4692b3673d4ce37e578f24582dffd896 | |
parent | ba4e131c896d35e075f00c15e424a7085e967f80 (diff) |
wds: implement "Get Current Settings" request/response
-rw-r--r-- | data/qmi-service-wds.json | 204 | ||||
-rw-r--r-- | libqmi-glib/qmi-enums-wds.h | 112 |
2 files changed, 316 insertions, 0 deletions
diff --git a/data/qmi-service-wds.json b/data/qmi-service-wds.json index f5738e8..7c0f0ee 100644 --- a/data/qmi-service-wds.json +++ b/data/qmi-service-wds.json @@ -183,6 +183,210 @@ "prerequisites" : [ { "common-ref" : "Success" } ] } ] }, // ********************************************************************************* + { "name" : "Get Current Settings", + "type" : "Message", + "service" : "WDS", + "id" : "0x002D", + "version" : "1.2", + "input" : [ { "name" : "Requested Settings", + "id" : "0x10", + "mandatory" : "yes", + "type" : "TLV", + "format" : "guint32", + "public-format" : "QmiWdsGetCurrentSettingsRequestedSettings" } ], + "output" : [ { "common-ref" : "Operation Result" }, + { "name" : "Profile Name", + "id" : "0x10", + "mandatory" : "no", + "type" : "TLV", + "format" : "string", + "prerequisites" : [ { "common-ref" : "Success" } ] }, + { "name" : "PDP Type", + "id" : "0x11", + "mandatory" : "no", + "type" : "TLV", + "format" : "guint8", + "public-format" : "QmiWdsPdpType", + "prerequisites" : [ { "common-ref" : "Success" } ] }, + { "name" : "APN Name", + "id" : "0x14", + "mandatory" : "no", + "type" : "TLV", + "format" : "string", + "prerequisites" : [ { "common-ref" : "Success" } ] }, + { "name" : "Primary IPv4 DNS Address", + "id" : "0x15", + "mandatory" : "no", + "type" : "TLV", + "format" : "guint32", + "prerequisites" : [ { "common-ref" : "Success" } ] }, + { "name" : "Secondary IPv4 DNS Address", + "id" : "0x16", + "mandatory" : "no", + "type" : "TLV", + "format" : "guint32", + "prerequisites" : [ { "common-ref" : "Success" } ] }, + { "name" : "GPRS Granted QoS", + "id" : "0x19", + "mandatory" : "no", + "type" : "TLV", + "format" : "sequence", + "contents" : [ { "name" : "Precedence Class", + "format" : "guint32" }, + { "name" : "Delay Class", + "format" : "guint32" }, + { "name" : "Reliability Class", + "format" : "guint32" }, + { "name" : "Peak Throughput Class", + "format" : "guint32" }, + { "name" : "Mean Throughput Class", + "format" : "guint32" } ], + "prerequisites" : [ { "common-ref" : "Success" } ] }, + { "name" : "Username", + "id" : "0x1B", + "mandatory" : "no", + "type" : "TLV", + "format" : "string", + "prerequisites" : [ { "common-ref" : "Success" } ] }, + { "name" : "Authentication", + "id" : "0x1D", + "mandatory" : "no", + "type" : "TLV", + "format" : "guint8", + "public-format" : "QmiWdsAuthentication", + "prerequisites" : [ { "common-ref" : "Success" } ] }, + { "name" : "IPv4 Address", + "id" : "0x1E", + "mandatory" : "no", + "type" : "TLV", + "format" : "guint32", + "prerequisites" : [ { "common-ref" : "Success" } ] }, + { "name" : "Profile ID", + "id" : "0x1F", + "mandatory" : "no", + "type" : "TLV", + "format" : "sequence", + "contents" : [ { "name" : "Profile Type", + "format" : "guint8", + "public-format" : "QmiWdsProfileType" }, + { "name" : "Profile Index", + "format" : "guint8" } ], + "prerequisites" : [ { "common-ref" : "Success" } ] }, + { "name" : "IPv4 Gateway Address", + "id" : "0x20", + "mandatory" : "no", + "type" : "TLV", + "format" : "guint32", + "prerequisites" : [ { "common-ref" : "Success" } ] }, + { "name" : "IPv4 Gateway Subnet Mask", + "id" : "0x21", + "mandatory" : "no", + "type" : "TLV", + "format" : "guint32", + "prerequisites" : [ { "common-ref" : "Success" } ] }, + { "name" : "PCSCF Address Using PCO", + "id" : "0x22", + "mandatory" : "no", + "type" : "TLV", + "format" : "guint8", + "prerequisites" : [ { "common-ref" : "Success" } ] }, + { "name" : "PCSCF Server Address List", + "id" : "0x23", + "mandatory" : "no", + "type" : "TLV", + "format" : "array", + "array-size" : { "format" : "guint8" }, + "array-element" : { "name" : "IPv4 Address", + "format" : "guint32" }, + "prerequisites" : [ { "common-ref" : "Success" } ] }, + { "name" : "PCSCF Domain Name List", + "id" : "0x24", + "mandatory" : "no", + "type" : "TLV", + "format" : "array", + "array-size" : { "format" : "guint8" }, + "array-element" : { "name" : "FQDN", + "length-prefix-size" : "16", + "format" : "string" }, + "prerequisites" : [ { "common-ref" : "Success" } ] }, + { "name" : "IPv6 Address", + "id" : "0x25", + "mandatory" : "no", + "type" : "TLV", + "format" : "sequence", + "contents" : [ { "name" : "Address", + "format" : "array", + "fixed-size" : "8", + "array-element" : { "format": "guint16" } }, + { "name" : "Prefix Length", + "format" : "guint8" } ], + "prerequisites" : [ { "common-ref" : "Success" } ] }, + { "name" : "IPv6 Gateway Address", + "id" : "0x26", + "mandatory" : "no", + "type" : "TLV", + "format" : "sequence", + "contents" : [ { "name" : "Address", + "format" : "array", + "fixed-size" : "8", + "array-element" : { "format": "guint16" } }, + { "name" : "Prefix Length", + "format" : "guint8" } ], + "prerequisites" : [ { "common-ref" : "Success" } ] }, + { "name" : "IPv6 Primary DNS Address", + "id" : "0x27", + "mandatory" : "no", + "type" : "TLV", + "format" : "array", + "fixed-size": "8", + "array-element" : { "format": "guint16" }, + "prerequisites" : [ { "common-ref" : "Success" } ] }, + { "name" : "IPv6 Secondary DNS Address", + "id" : "0x28", + "mandatory" : "no", + "type" : "TLV", + "format" : "array", + "fixed-size": "8", + "array-element" : { "format": "guint16" }, + "prerequisites" : [ { "common-ref" : "Success" } ] }, + { "name" : "MTU", + "id" : "0x29", + "mandatory" : "no", + "type" : "TLV", + "format" : "guint32", + "prerequisites" : [ { "common-ref" : "Success" } ] }, + { "name" : "Domain Name List", + "id" : "0x2A", + "mandatory" : "no", + "type" : "TLV", + "format" : "array", + "array-size" : { "format" : "guint8" }, + "array-element" : { "name" : "Domain Name", + "length-prefix-size" : "16", + "format" : "string" }, + "prerequisites" : [ { "common-ref" : "Success" } ] }, + { "name" : "IP Family", + "id" : "0x2B", + "mandatory" : "no", + "type" : "TLV", + "format" : "guint8", + "public-format" : "QmiWdsIpFamily", + "prerequisites" : [ { "common-ref" : "Success" } ] }, + { "name" : "IMCN Flag", + "id" : "0x2C", + "mandatory" : "no", + "type" : "TLV", + "format" : "gint8", + "prerequisites" : [ { "common-ref" : "Success" } ] }, + { "name" : "Extended Technology Preference", + "id" : "0x2D", + "mandatory" : "no", + "type" : "TLV", + "format" : "guint16", + "public-format" : "QmiWdsExtendedTechnologyPreference", + "prerequisites" : [ { "common-ref" : "Success" } ] } ] }, + + // ********************************************************************************* { "name" : "Get Data Bearer Technology", "type" : "Message", "service" : "WDS", diff --git a/libqmi-glib/qmi-enums-wds.h b/libqmi-glib/qmi-enums-wds.h index efd8c32..f5bffc9 100644 --- a/libqmi-glib/qmi-enums-wds.h +++ b/libqmi-glib/qmi-enums-wds.h @@ -826,4 +826,116 @@ typedef enum { /*< underscore_name=qmi_wds_so_evdo_reva >*/ QMI_WDS_SO_EVDO_REVA_EMPA_EHRPD = 1 << 3 } QmiWdsSoEvdoRevA; + +/*****************************************************************************/ +/* Helper enums for the 'QMI WDS Get Current Settings' message */ + +/** + * QmiWdsGetCurrentSettingsRequestedSettings: + * @QMI_WDS_GET_CURRENT_SETTINGS_REQUESTED_SETTINGS_NONE: no settings requested + * @QMI_WDS_GET_CURRENT_SETTINGS_REQUESTED_SETTINGS_PROFILE_ID: request profile ID + * @QMI_WDS_GET_CURRENT_SETTINGS_REQUESTED_SETTINGS_PROFILE_NAME: request profile name + * @QMI_WDS_GET_CURRENT_SETTINGS_REQUESTED_SETTINGS_PDP_TYPE: request PDP context type + * @QMI_WDS_GET_CURRENT_SETTINGS_REQUESTED_SETTINGS_APN_NAME: request APN name + * @QMI_WDS_GET_CURRENT_SETTINGS_REQUESTED_SETTINGS_DNS_ADDRESS: request DNS server addresses + * @QMI_WDS_GET_CURRENT_SETTINGS_REQUESTED_SETTINGS_GRANTED_QOS: request granted QoS + * @QMI_WDS_GET_CURRENT_SETTINGS_REQUESTED_SETTINGS_USERNAME: request username + * @QMI_WDS_GET_CURRENT_SETTINGS_REQUESTED_SETTINGS_AUTH_PROTOCOL: request authentication protocol (ie PAP/CHAP/none) + * @QMI_WDS_GET_CURRENT_SETTINGS_REQUESTED_SETTINGS_IP_ADDRESS: request IP address + * @QMI_WDS_GET_CURRENT_SETTINGS_REQUESTED_SETTINGS_GATEWAY_INFO: request gateway address + * @QMI_WDS_GET_CURRENT_SETTINGS_REQUESTED_SETTINGS_PCSCF_ADDRESS: request PCSCF address + * @QMI_WDS_GET_CURRENT_SETTINGS_REQUESTED_SETTINGS_PCSCF_SERVER_ADDRESS_LIST: request PCSCF server address list + * @QMI_WDS_GET_CURRENT_SETTINGS_REQUESTED_SETTINGS_PCSCF_DOMAIN_NAME_LIST: request PCSCF domain name list + * @QMI_WDS_GET_CURRENT_SETTINGS_REQUESTED_SETTINGS_MTU: request MTU + * @QMI_WDS_GET_CURRENT_SETTINGS_REQUESTED_SETTINGS_DOMAIN_NAME_LIST: request domain name list + * @QMI_WDS_GET_CURRENT_SETTINGS_REQUESTED_SETTINGS_IP_FAMILY: request IP family (ie IPv4 or IPv6) + * @QMI_WDS_GET_CURRENT_SETTINGS_REQUESTED_SETTINGS_IMCN_FLAG: request IMCN flag + * @QMI_WDS_GET_CURRENT_SETTINGS_REQUESTED_SETTINGS_EXTENDED_TECHNOLOGY: request extended technology info + * + * Flags specifying which specific settings to return when requesting the + * current WDS bearer settings. + */ +typedef enum { /*< underscore_name=qmi_wds_get_current_settings_requested_settings >*/ + QMI_WDS_GET_CURRENT_SETTINGS_REQUESTED_SETTINGS_NONE = 0, + QMI_WDS_GET_CURRENT_SETTINGS_REQUESTED_SETTINGS_PROFILE_ID = 1 << 0, + QMI_WDS_GET_CURRENT_SETTINGS_REQUESTED_SETTINGS_PROFILE_NAME = 1 << 1, + QMI_WDS_GET_CURRENT_SETTINGS_REQUESTED_SETTINGS_PDP_TYPE = 1 << 2, + QMI_WDS_GET_CURRENT_SETTINGS_REQUESTED_SETTINGS_APN_NAME = 1 << 3, + QMI_WDS_GET_CURRENT_SETTINGS_REQUESTED_SETTINGS_DNS_ADDRESS = 1 << 4, + QMI_WDS_GET_CURRENT_SETTINGS_REQUESTED_SETTINGS_GRANTED_QOS = 1 << 5, + QMI_WDS_GET_CURRENT_SETTINGS_REQUESTED_SETTINGS_USERNAME = 1 << 6, + QMI_WDS_GET_CURRENT_SETTINGS_REQUESTED_SETTINGS_AUTH_PROTOCOL = 1 << 7, + QMI_WDS_GET_CURRENT_SETTINGS_REQUESTED_SETTINGS_IP_ADDRESS = 1 << 8, + QMI_WDS_GET_CURRENT_SETTINGS_REQUESTED_SETTINGS_GATEWAY_INFO = 1 << 9, + QMI_WDS_GET_CURRENT_SETTINGS_REQUESTED_SETTINGS_PCSCF_ADDRESS = 1 << 10, + QMI_WDS_GET_CURRENT_SETTINGS_REQUESTED_SETTINGS_PCSCF_SERVER_ADDRESS_LIST = 1 << 11, + QMI_WDS_GET_CURRENT_SETTINGS_REQUESTED_SETTINGS_PCSCF_DOMAIN_NAME_LIST = 1 << 12, + QMI_WDS_GET_CURRENT_SETTINGS_REQUESTED_SETTINGS_MTU = 1 << 13, + QMI_WDS_GET_CURRENT_SETTINGS_REQUESTED_SETTINGS_DOMAIN_NAME_LIST = 1 << 14, + QMI_WDS_GET_CURRENT_SETTINGS_REQUESTED_SETTINGS_IP_FAMILY = 1 << 15, + QMI_WDS_GET_CURRENT_SETTINGS_REQUESTED_SETTINGS_IMCN_FLAG = 1 << 16, + QMI_WDS_GET_CURRENT_SETTINGS_REQUESTED_SETTINGS_EXTENDED_TECHNOLOGY = 1 << 17, +} QmiWdsGetCurrentSettingsRequestedSettings; + +/** + * QmiWdsPdpType: + * @QMI_WDS_PDP_TYPE_IPV4: IPv4 + * @QMI_WDS_PDP_TYPE_PPP: PPP + * @QMI_WDS_PDP_TYPE_IPV6: IPv6 + * @QMI_WDS_PDP_TYPE_IPV4_OR_IPV6: IPv4 and IPv6 combined context + * + * PDP context type. + */ +typedef enum { /*< underscore_name=qmi_wds_pdp_type >*/ + QMI_WDS_PDP_TYPE_IPV4 = 0, + QMI_WDS_PDP_TYPE_PPP = 1, + QMI_WDS_PDP_TYPE_IPV6 = 2, + QMI_WDS_PDP_TYPE_IPV4_OR_IPV6 = 3 +} QmiWdsPdpType; + +/** + * QmiWdsTrafficClass: + * @QMI_WDS_TRAFFIC_CLASS_SUBSCRIBED: default (?) class, best-effort + * @QMI_WDS_TRAFFIC_CLASS_CONVERSATIONAL: two-way video/voice, most delay sensitive + * @QMI_WDS_TRAFFIC_CLASS_STREAMING: one-way video/audio, delay sensitive + * @QMI_WDS_TRAFFIC_CLASS_INTERACTIVE: delay-insensitive (browsing, SSH) + * @QMI_WDS_TRAFFIC_CLASS_BACKGROUND: delay-insensitive (downloads, email) + * + * QoS Traffic Classes. + */ +typedef enum { /*< underscore_name=qmi_wds_traffic_class >*/ + QMI_WDS_TRAFFIC_CLASS_SUBSCRIBED = 0, + QMI_WDS_TRAFFIC_CLASS_CONVERSATIONAL = 1, + QMI_WDS_TRAFFIC_CLASS_STREAMING = 2, + QMI_WDS_TRAFFIC_CLASS_INTERACTIVE = 3, + QMI_WDS_TRAFFIC_CLASS_BACKGROUND = 4 +} QmiWdsTrafficClass; + +/** + * QmiWdsAuthentication: + * @QMI_WDS_AUTHENTICATION_NONE: no authentication + * @QMI_WDS_AUTHENTICATION_PAP: PAP authentication + * @QMI_WDS_AUTHENTICATION_CHAP: CHAP authentication + * + * PDP context authentication protocols. + */ +typedef enum { /*< underscore_name=qmi_wds_authentication >*/ + QMI_WDS_AUTHENTICATION_NONE = 0, + QMI_WDS_AUTHENTICATION_PAP = 1 << 0, + QMI_WDS_AUTHENTICATION_CHAP = 1 << 1 +} QmiWdsAuthentication; + + +/** + * QmiWdsProfileType: + * @QMI_WDS_PROFILE_TYPE_3GPP: 3GPP profile type. + * @QMI_WDS_PROFILE_TYPE_3GPP2: 3GPP2 profile type. + * + * Profile network type family. + */ +typedef enum { + QMI_WDS_PROFILE_TYPE_3GPP = 0, + QMI_WDS_PROFILE_TYPE_3GPP2 = 1 +} QmiWdsProfileType; + #endif /* _LIBQMI_GLIB_QMI_ENUMS_WDS_H_ */ |