diff options
author | Tore Anderson <tore@fud.no> | 2012-04-13 23:29:17 +0200 |
---|---|---|
committer | Aleksander Morgado <aleksander@lanedo.com> | 2012-05-06 17:12:36 +0200 |
commit | 6b9ee7c83352bb545eab3352b32843a76cde9176 (patch) | |
tree | 0b87fd010462daeca5d3c005db7a71382e664ad2 /libmm-common/mm-bearer-properties.c | |
parent | caeeae27219a91384fa41ac5a1e0f21e1edbaa76 (diff) |
broadband-bearer: derive PDP type from the ip-type bearer property
This patch makes it possible to use MM to set up PDP contexts with
PDP types other than 'IP', which is particularly useful when trying
to use the 'IPV6' or 'IPV4V6' PDP types defined in recent 3GPP specs.
If ip-type isn't specified, 'IP' will be used by default, due to the
fact that modem support for the 'IPV4V6' type is still rather scarce.
The patch applies to Aleksander's 'bearer-properties' branch. It has
been tested using mmcli in this fashion:
mmcli -m 0 --simple-connect=apn=internet # default to 'IP'
mmcli -m 0 --simple-connect=apn=internet,ip-type=IP
mmcli -m 0 --simple-connect=apn=internet,ip-type=IPV6
mmcli -m 0 --simple-connect=apn=internet,ip-type=IPV4V6
Diffstat (limited to 'libmm-common/mm-bearer-properties.c')
-rw-r--r-- | libmm-common/mm-bearer-properties.c | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/libmm-common/mm-bearer-properties.c b/libmm-common/mm-bearer-properties.c index 9afa07f0..8eb665c9 100644 --- a/libmm-common/mm-bearer-properties.c +++ b/libmm-common/mm-bearer-properties.c @@ -473,6 +473,13 @@ mm_bearer_properties_init (MMBearerProperties *self) /* Some defaults */ self->priv->allow_roaming = TRUE; self->priv->rm_protocol = MM_MODEM_CDMA_RM_PROTOCOL_UNKNOWN; + + /* At some point in the future, this default should probably be changed + * to IPV4V6. However, presently support for this PDP type is rare. An + * even better approach would likely be to query which PDP types the + * modem supports (using AT+CGDCONT=?), and set the default accordingly + */ + self->priv->ip_type = g_strdup ("IP"); } static void |