From c5a3798288fdb67917e0cfed951ad2209672a866 Mon Sep 17 00:00:00 2001 From: Sarah Chin Date: Wed, 3 Feb 2021 12:02:14 -0800 Subject: [PATCH] API updates for TrafficDescriptr fields Bug: 179312227 Test: atest VtsHalRadioV1_6TargetTest Change-Id: I33018ad413875f4fae1497ed5acc8ee50df7c942 --- radio/1.6/IRadio.hal | 9 +++++- radio/1.6/types.hal | 29 ++++++++++--------- .../1.6/vts/functional/radio_hidl_hal_api.cpp | 2 +- radio/1.6/vts/functional/radio_response.cpp | 1 + 4 files changed, 25 insertions(+), 16 deletions(-) diff --git a/radio/1.6/IRadio.hal b/radio/1.6/IRadio.hal index b756ce1261..996a1fcc41 100644 --- a/radio/1.6/IRadio.hal +++ b/radio/1.6/IRadio.hal @@ -103,6 +103,12 @@ interface IRadio extends @1.5::IRadio { * - Support simultaneous data call contexts up to DataRegStateResult.maxDataCalls specified * in the response of getDataRegistrationState. * + * The differences relative to the 1.5 version of the API are: + * - The addition of new parameters pduSessionId, sliceInfo, trafficDescriptor, and + * matchAllRuleAllowed. + * - If an existing data call should be used for the request, that must be indicated in the + * response by setting SetupDataCallResult::cid to the context id of that call. + * * @param serial Serial number of request. * @param accessNetwork The access network to setup the data call. If the data connection cannot * be established on the specified access network then it should be responded with an error. @@ -122,7 +128,8 @@ interface IRadio extends @1.5::IRadio { * Reference: 3GPP TS 24.007 section 11.2.3.1b * @param sliceInfo SliceInfo to be used for the data connection when a handover occurs from * EPDG to 5G. It is valid only when accessNetwork is AccessNetwork:NGRAN. If the slice - * passed from EPDG is rejected, then the data failure cause must be DataCallFailCause:SLICE_REJECTED. + * passed from EPDG is rejected, then the data failure cause must be + * DataCallFailCause:SLICE_REJECTED. * @param trafficDescriptor TrafficDescriptor for which data connection needs to be * established. It is used for URSP traffic matching as described in TS 24.526 * Section 4.2.2. It includes an optional DNN which, if present, must be used for traffic diff --git a/radio/1.6/types.hal b/radio/1.6/types.hal index 6c23650dde..9bb3b55298 100644 --- a/radio/1.6/types.hal +++ b/radio/1.6/types.hal @@ -273,7 +273,8 @@ enum HandoverFailureMode : int32_t { /** * Overwritten from @1.5::SetupDataCallResult in order to change the suggestedRetryTime * to 64-bit value. In the future, this must be extended instead of overwritten. - * Also added defaultQos, qosSessions, and handoverFailureMode in this version. + * Also added defaultQos, qosSessions, handoverFailureMode, pduSessionId, sliceInfo, + * and traffic descriptors in this version. */ struct SetupDataCallResult { /** Data call fail cause. DataCallFailCause.NONE if no error. */ @@ -846,7 +847,7 @@ enum DataCallFailCause : @1.4::DataCallFailCause { MATCH_ALL_RULE_NOT_ALLOWED = 0x8CD, /** - * If connection failed for all matching URSP rules + * If connection failed for all matching URSP rules. */ ALL_MATCHING_RULES_FAILED = 0x8CE, }; @@ -922,17 +923,17 @@ enum NgranBands : @1.5::NgranBands { * This safe_union represents an optional DNN. DNN stands for Data Network Name * and represents an APN as defined in 3GPP TS 23.003. */ -safe_union OptionalDNN { +safe_union OptionalDnn { Monostate noinit; string value; }; /** - * This safe_union represents an optional OSAppId. + * This safe_union represents an optional OsAppId. */ -safe_union OptionalOSAppId { +safe_union OptionalOsAppId { Monostate noinit; - OSAppId value; + OsAppId value; }; /** @@ -953,21 +954,21 @@ struct TrafficDescriptor { * DNN stands for Data Network Name and represents an APN as defined in * 3GPP TS 23.003. */ - OptionalDNN dnn; + OptionalDnn dnn; /** - * Indicates the OSId + OSAppId (used as category in Android). + * Indicates the OsId + OsAppId (used as category in Android). */ - OptionalOSAppId osAppId; + OptionalOsAppId osAppId; }; /** - * This struct represents the OSId + OSAppId as defined in TS 24.526 Section 5.2 + * This struct represents the OsId + OsAppId as defined in TS 24.526 Section 5.2 */ -struct OSAppId { +struct OsAppId { /** - * Byte array representing OSId + OSAppId. The minimum length of the array is - * 18 and maximum length is 272 (16 bytes for OSId + 1 byte for OSAppId length - * + up to 255 bytes for OSAppId). + * Byte array representing OsId + OsAppId. The minimum length of the array is + * 18 and maximum length is 272 (16 bytes for OsId + 1 byte for OsAppId length + * + up to 255 bytes for OsAppId). */ vec osAppId; }; diff --git a/radio/1.6/vts/functional/radio_hidl_hal_api.cpp b/radio/1.6/vts/functional/radio_hidl_hal_api.cpp index 07b8ccb035..716a10b17d 100644 --- a/radio/1.6/vts/functional/radio_hidl_hal_api.cpp +++ b/radio/1.6/vts/functional/radio_hidl_hal_api.cpp @@ -130,7 +130,7 @@ TEST_P(RadioHidlTest_v1_6, setupDataCall_1_6_osAppId) { memset(&optionalTrafficDescriptor, 0, sizeof(optionalTrafficDescriptor)); ::android::hardware::radio::V1_6::TrafficDescriptor trafficDescriptor; - ::android::hardware::radio::V1_6::OSAppId osAppId; + ::android::hardware::radio::V1_6::OsAppId osAppId; osAppId.osAppId = 1; trafficDescriptor.osAppId.value(osAppId); optionalTrafficDescriptor.value(trafficDescriptor); diff --git a/radio/1.6/vts/functional/radio_response.cpp b/radio/1.6/vts/functional/radio_response.cpp index fad3f12e2b..87b83c8b86 100644 --- a/radio/1.6/vts/functional/radio_response.cpp +++ b/radio/1.6/vts/functional/radio_response.cpp @@ -1059,6 +1059,7 @@ Return RadioResponse_v1_6::setupDataCallResponse_1_6( parent_v1_6.notify(info.serial); return Void(); } + Return RadioResponse_v1_6::setNrDualConnectivityStateResponse( const ::android::hardware::radio::V1_6::RadioResponseInfo& info) { rspInfo = info;