diff options
author | Mike Cailean <mcailean@codeaurora.org> | 2018-03-13 10:11:02 -0700 |
---|---|---|
committer | Gerrit - the friendly Code Review server <code-review@localhost> | 2018-06-11 14:13:04 -0700 |
commit | 88688a85a365e716b369a7525dc810a66628b241 (patch) | |
tree | 9a3286f79f8e063a364873a4b10b65d1d15205ef /utils | |
parent | 17015dd790b13345c547709ef8b6144a3526d079 (diff) | |
download | gps-88688a85a365e716b369a7525dc810a66628b241.tar.gz |
SUPL connection enhancements
Adding enhancement to ATL messages to allow
sending bearer type and apn type mask values.
CRs-fixed: 2206014
Change-Id: I28f6583d842e82c9e26d40be55312f8aaf01193e
Diffstat (limited to 'utils')
-rw-r--r-- | utils/gps_extended_c.h | 48 | ||||
-rw-r--r-- | utils/loc_gps.h | 6 |
2 files changed, 35 insertions, 19 deletions
diff --git a/utils/gps_extended_c.h b/utils/gps_extended_c.h index ed4a1b8..f2b5b9f 100644 --- a/utils/gps_extended_c.h +++ b/utils/gps_extended_c.h @@ -1,4 +1,4 @@ -/* Copyright (c) 2013-2017 The Linux Foundation. All rights reserved. +/* Copyright (c) 2013-2018 The Linux Foundation. All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions are @@ -160,17 +160,27 @@ typedef int16_t AGpsBearerType; #define AGPS_APN_BEARER_IPV6 2 #define AGPS_APN_BEARER_IPV4V6 3 -typedef uint64_t LocApnTypeMask; -#define LOC_APN_TYPE_MASK_DEFAULT ((LocApnTypeMask)0x0000000000000001ull) /**< Denotes APN type for Default/Internet traffic */ -#define LOC_APN_TYPE_MASK_IMS ((LocApnTypeMask)0x0000000000000002ull) /**< Denotes APN type for IP Multimedia Subsystem */ -#define LOC_APN_TYPE_MASK_MMS ((LocApnTypeMask)0x0000000000000004ull) /**< Denotes APN type for Multimedia Messaging Service */ -#define LOC_APN_TYPE_MASK_DUN ((LocApnTypeMask)0x0000000000000008ull) /**< Denotes APN type for Dial Up Network */ -#define LOC_APN_TYPE_MASK_SUPL ((LocApnTypeMask)0x0000000000000010ull) /**< Denotes APN type for Secure User Plane Location */ -#define LOC_APN_TYPE_MASK_HIPRI ((LocApnTypeMask)0x0000000000000020ull) /**< Denotes APN type for High Priority Mobile Data */ -#define LOC_APN_TYPE_MASK_FOTA ((LocApnTypeMask)0x0000000000000040ull) /**< Denotes APN type for over the air administration */ -#define LOC_APN_TYPE_MASK_CBS ((LocApnTypeMask)0x0000000000000080ull) /**< Denotes APN type for Carrier Branded Services */ -#define LOC_APN_TYPE_MASK_IA ((LocApnTypeMask)0x0000000000000100ull) /**< Denotes APN type for Initial Attach */ -#define LOC_APN_TYPE_MASK_EMERGENCY ((LocApnTypeMask)0x0000000000000200ull) /**< Denotes APN type for emergency */ +typedef uint32_t LocApnTypeMask; +/**< Denotes APN type for Default/Internet traffic */ +#define LOC_APN_TYPE_MASK_DEFAULT ((LocApnTypeMask)0x00000001) +/**< Denotes APN type for IP Multimedia Subsystem */ +#define LOC_APN_TYPE_MASK_IMS ((LocApnTypeMask)0x00000002) +/**< Denotes APN type for Multimedia Messaging Service */ +#define LOC_APN_TYPE_MASK_MMS ((LocApnTypeMask)0x00000004) +/**< Denotes APN type for Dial Up Network */ +#define LOC_APN_TYPE_MASK_DUN ((LocApnTypeMask)0x00000008) +/**< Denotes APN type for Secure User Plane Location */ +#define LOC_APN_TYPE_MASK_SUPL ((LocApnTypeMask)0x00000010) +/**< Denotes APN type for High Priority Mobile Data */ +#define LOC_APN_TYPE_MASK_HIPRI ((LocApnTypeMask)0x00000020) +/**< Denotes APN type for over the air administration */ +#define LOC_APN_TYPE_MASK_FOTA ((LocApnTypeMask)0x00000040) +/**< Denotes APN type for Carrier Branded Services */ +#define LOC_APN_TYPE_MASK_CBS ((LocApnTypeMask)0x00000080) +/**< Denotes APN type for Initial Attach */ +#define LOC_APN_TYPE_MASK_IA ((LocApnTypeMask)0x00000100) +/**< Denotes APN type for emergency */ +#define LOC_APN_TYPE_MASK_EMERGENCY ((LocApnTypeMask)0x00000200) typedef enum { AGPS_CB_PRIORITY_LOW = 1, @@ -1490,24 +1500,26 @@ typedef std::function<void( * Represents the status of AGNSS augmented to support IPv4. */ struct AGnssExtStatusIpV4 { - AGpsExtType type; - LocAGpsStatusValue status; + AGpsExtType type; + LocApnTypeMask apnTypeMask; + LocAGpsStatusValue status; /* * 32-bit IPv4 address. */ - uint32_t ipV4Addr; + uint32_t ipV4Addr; }; /* * Represents the status of AGNSS augmented to support IPv6. */ struct AGnssExtStatusIpV6 { - AGpsExtType type; - LocAGpsStatusValue status; + AGpsExtType type; + LocApnTypeMask apnTypeMask; + LocAGpsStatusValue status; /* * 128-bit IPv6 address. */ - uint8_t ipV6Addr[16]; + uint8_t ipV6Addr[16]; }; /* ODCPI Request Info */ diff --git a/utils/loc_gps.h b/utils/loc_gps.h index aaeea23..95d0c21 100644 --- a/utils/loc_gps.h +++ b/utils/loc_gps.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2010 The Android Open Source Project + * Copyright (C) 2010, 2018 The Android Open Source Project * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. @@ -156,8 +156,12 @@ typedef uint16_t LocGpsAidingData; /** AGPS type */ typedef uint16_t LocAGpsType; +#define LOC_AGPS_TYPE_ANY 0 #define LOC_AGPS_TYPE_SUPL 1 #define LOC_AGPS_TYPE_C2K 2 +#define LOC_AGPS_TYPE_WWAN_ANY 3 +#define LOC_AGPS_TYPE_WIFI 4 +#define LOC_AGPS_TYPE_SUPL_ES 5 typedef uint16_t LocAGpsSetIDType; #define LOC_AGPS_SETID_TYPE_NONE 0 |