mirror of
https://github.com/Evolution-X/hardware_interfaces
synced 2026-02-01 11:36:00 +00:00
Merge "Radio HAL : Support N3IWF"
This commit is contained in:
committed by
Android (Google) Code Review
commit
f71279a2ab
@@ -461,7 +461,7 @@
|
||||
</hal>
|
||||
<hal format="aidl" optional="true">
|
||||
<name>android.hardware.radio.data</name>
|
||||
<version>1</version>
|
||||
<version>2</version>
|
||||
<interface>
|
||||
<name>IRadioData</name>
|
||||
<instance>slot1</instance>
|
||||
|
||||
@@ -36,7 +36,7 @@ aidl_interface {
|
||||
host_supported: true,
|
||||
srcs: ["android/hardware/radio/config/*.aidl"],
|
||||
stability: "vintf",
|
||||
imports: ["android.hardware.radio-V1"],
|
||||
imports: ["android.hardware.radio-V2"],
|
||||
backend: {
|
||||
cpp: {
|
||||
enabled: true,
|
||||
@@ -48,7 +48,7 @@ aidl_interface {
|
||||
versions_with_info: [
|
||||
{
|
||||
version: "1",
|
||||
imports: ["android.hardware.radio-V1"],
|
||||
imports: ["android.hardware.radio-V2"],
|
||||
},
|
||||
],
|
||||
|
||||
@@ -60,7 +60,7 @@ aidl_interface {
|
||||
host_supported: true,
|
||||
srcs: ["android/hardware/radio/data/*.aidl"],
|
||||
stability: "vintf",
|
||||
imports: ["android.hardware.radio-V1"],
|
||||
imports: ["android.hardware.radio-V2"],
|
||||
backend: {
|
||||
cpp: {
|
||||
enabled: true,
|
||||
@@ -72,7 +72,7 @@ aidl_interface {
|
||||
versions_with_info: [
|
||||
{
|
||||
version: "1",
|
||||
imports: ["android.hardware.radio-V1"],
|
||||
imports: ["android.hardware.radio-V2"],
|
||||
},
|
||||
],
|
||||
|
||||
@@ -84,7 +84,7 @@ aidl_interface {
|
||||
host_supported: true,
|
||||
srcs: ["android/hardware/radio/messaging/*.aidl"],
|
||||
stability: "vintf",
|
||||
imports: ["android.hardware.radio-V1"],
|
||||
imports: ["android.hardware.radio-V2"],
|
||||
backend: {
|
||||
cpp: {
|
||||
enabled: true,
|
||||
@@ -96,7 +96,7 @@ aidl_interface {
|
||||
versions_with_info: [
|
||||
{
|
||||
version: "1",
|
||||
imports: ["android.hardware.radio-V1"],
|
||||
imports: ["android.hardware.radio-V2"],
|
||||
},
|
||||
],
|
||||
|
||||
@@ -108,7 +108,7 @@ aidl_interface {
|
||||
host_supported: true,
|
||||
srcs: ["android/hardware/radio/modem/*.aidl"],
|
||||
stability: "vintf",
|
||||
imports: ["android.hardware.radio-V1"],
|
||||
imports: ["android.hardware.radio-V2"],
|
||||
backend: {
|
||||
cpp: {
|
||||
enabled: true,
|
||||
@@ -120,7 +120,7 @@ aidl_interface {
|
||||
versions_with_info: [
|
||||
{
|
||||
version: "1",
|
||||
imports: ["android.hardware.radio-V1"],
|
||||
imports: ["android.hardware.radio-V2"],
|
||||
},
|
||||
],
|
||||
|
||||
@@ -132,7 +132,7 @@ aidl_interface {
|
||||
host_supported: true,
|
||||
srcs: ["android/hardware/radio/network/*.aidl"],
|
||||
stability: "vintf",
|
||||
imports: ["android.hardware.radio-V1"],
|
||||
imports: ["android.hardware.radio-V2"],
|
||||
backend: {
|
||||
cpp: {
|
||||
enabled: true,
|
||||
@@ -144,7 +144,7 @@ aidl_interface {
|
||||
versions_with_info: [
|
||||
{
|
||||
version: "1",
|
||||
imports: ["android.hardware.radio-V1"],
|
||||
imports: ["android.hardware.radio-V2"],
|
||||
},
|
||||
],
|
||||
|
||||
@@ -157,7 +157,7 @@ aidl_interface {
|
||||
srcs: ["android/hardware/radio/sim/*.aidl"],
|
||||
stability: "vintf",
|
||||
imports: [
|
||||
"android.hardware.radio-V1",
|
||||
"android.hardware.radio-V2",
|
||||
"android.hardware.radio.config",
|
||||
],
|
||||
backend: {
|
||||
@@ -172,7 +172,7 @@ aidl_interface {
|
||||
{
|
||||
version: "1",
|
||||
imports: [
|
||||
"android.hardware.radio-V1",
|
||||
"android.hardware.radio-V2",
|
||||
"android.hardware.radio.config-V1",
|
||||
],
|
||||
},
|
||||
@@ -186,7 +186,7 @@ aidl_interface {
|
||||
host_supported: true,
|
||||
srcs: ["android/hardware/radio/voice/*.aidl"],
|
||||
stability: "vintf",
|
||||
imports: ["android.hardware.radio-V1"],
|
||||
imports: ["android.hardware.radio-V2"],
|
||||
backend: {
|
||||
cpp: {
|
||||
enabled: true,
|
||||
@@ -198,7 +198,7 @@ aidl_interface {
|
||||
versions_with_info: [
|
||||
{
|
||||
version: "1",
|
||||
imports: ["android.hardware.radio-V1"],
|
||||
imports: ["android.hardware.radio-V2"],
|
||||
},
|
||||
],
|
||||
|
||||
|
||||
@@ -37,6 +37,10 @@ interface IRadioDataIndication {
|
||||
oneway void dataCallListChanged(in android.hardware.radio.RadioIndicationType type, in android.hardware.radio.data.SetupDataCallResult[] dcList);
|
||||
oneway void keepaliveStatus(in android.hardware.radio.RadioIndicationType type, in android.hardware.radio.data.KeepaliveStatus status);
|
||||
oneway void pcoData(in android.hardware.radio.RadioIndicationType type, in android.hardware.radio.data.PcoDataInfo pco);
|
||||
/**
|
||||
* @deprecated use unthrottleDataProfile to clarify access network for this event.
|
||||
*/
|
||||
oneway void unthrottleApn(in android.hardware.radio.RadioIndicationType type, in android.hardware.radio.data.DataProfileInfo dataProfileInfo);
|
||||
oneway void slicingConfigChanged(in android.hardware.radio.RadioIndicationType type, in android.hardware.radio.data.SlicingConfig slicingConfig);
|
||||
oneway void unthrottleDataProfile(in android.hardware.radio.RadioIndicationType type, in android.hardware.radio.AccessNetwork accessNetwork, in android.hardware.radio.data.DataProfileInfo dataProfileInfo);
|
||||
}
|
||||
|
||||
@@ -40,6 +40,9 @@ interface IRadioNetwork {
|
||||
oneway void getBarringInfo(in int serial);
|
||||
oneway void getCdmaRoamingPreference(in int serial);
|
||||
oneway void getCellInfoList(in int serial);
|
||||
/**
|
||||
* @deprecated use getRegistrationState()
|
||||
*/
|
||||
oneway void getDataRegistrationState(in int serial);
|
||||
oneway void getImsRegistrationState(in int serial);
|
||||
oneway void getNetworkSelectionMode(in int serial);
|
||||
@@ -47,6 +50,9 @@ interface IRadioNetwork {
|
||||
oneway void getSignalStrength(in int serial);
|
||||
oneway void getSystemSelectionChannels(in int serial);
|
||||
oneway void getVoiceRadioTechnology(in int serial);
|
||||
/**
|
||||
* @deprecated use getRegistrationState()
|
||||
*/
|
||||
oneway void getVoiceRegistrationState(in int serial);
|
||||
oneway void isNrDualConnectivityEnabled(in int serial);
|
||||
oneway void responseAcknowledgement();
|
||||
@@ -74,4 +80,5 @@ interface IRadioNetwork {
|
||||
oneway void triggerEmergencyNetworkScan(int serial, in android.hardware.radio.network.EmergencyNetworkScanTrigger request);
|
||||
oneway void cancelEmergencyNetworkScan(in int serial);
|
||||
oneway void exitEmergencyMode(in int serial);
|
||||
oneway void getRegistrationState(in int serial, in android.hardware.radio.RadioTechnologyFamily ratFamily, in android.hardware.radio.network.Domain domain);
|
||||
}
|
||||
|
||||
@@ -41,6 +41,9 @@ interface IRadioNetworkResponse {
|
||||
oneway void getBarringInfoResponse(in android.hardware.radio.RadioResponseInfo info, in android.hardware.radio.network.CellIdentity cellIdentity, in android.hardware.radio.network.BarringInfo[] barringInfos);
|
||||
oneway void getCdmaRoamingPreferenceResponse(in android.hardware.radio.RadioResponseInfo info, in android.hardware.radio.network.CdmaRoamingType type);
|
||||
oneway void getCellInfoListResponse(in android.hardware.radio.RadioResponseInfo info, in android.hardware.radio.network.CellInfo[] cellInfo);
|
||||
/**
|
||||
* @deprecated use getRegistrationStateResponse()
|
||||
*/
|
||||
oneway void getDataRegistrationStateResponse(in android.hardware.radio.RadioResponseInfo info, in android.hardware.radio.network.RegStateResult dataRegResponse);
|
||||
oneway void getImsRegistrationStateResponse(in android.hardware.radio.RadioResponseInfo info, in boolean isRegistered, in android.hardware.radio.RadioTechnologyFamily ratFamily);
|
||||
oneway void getNetworkSelectionModeResponse(in android.hardware.radio.RadioResponseInfo info, in boolean manual);
|
||||
@@ -48,6 +51,9 @@ interface IRadioNetworkResponse {
|
||||
oneway void getSignalStrengthResponse(in android.hardware.radio.RadioResponseInfo info, in android.hardware.radio.network.SignalStrength signalStrength);
|
||||
oneway void getSystemSelectionChannelsResponse(in android.hardware.radio.RadioResponseInfo info, in android.hardware.radio.network.RadioAccessSpecifier[] specifiers);
|
||||
oneway void getVoiceRadioTechnologyResponse(in android.hardware.radio.RadioResponseInfo info, in android.hardware.radio.RadioTechnology rat);
|
||||
/**
|
||||
* @deprecated use getRegistrationStateResponse()
|
||||
*/
|
||||
oneway void getVoiceRegistrationStateResponse(in android.hardware.radio.RadioResponseInfo info, in android.hardware.radio.network.RegStateResult voiceRegResponse);
|
||||
oneway void isNrDualConnectivityEnabledResponse(in android.hardware.radio.RadioResponseInfo info, in boolean isEnabled);
|
||||
oneway void setAllowedNetworkTypesBitmapResponse(in android.hardware.radio.RadioResponseInfo info);
|
||||
@@ -73,4 +79,5 @@ interface IRadioNetworkResponse {
|
||||
oneway void triggerEmergencyNetworkScanResponse(in android.hardware.radio.RadioResponseInfo info);
|
||||
oneway void exitEmergencyModeResponse(in android.hardware.radio.RadioResponseInfo info);
|
||||
oneway void cancelEmergencyNetworkScanResponse(in android.hardware.radio.RadioResponseInfo info);
|
||||
oneway void getRegistrationStateResponse(in android.hardware.radio.RadioResponseInfo info, in android.hardware.radio.network.RegStateResult regResponse);
|
||||
}
|
||||
|
||||
@@ -41,6 +41,7 @@ parcelable NrVopsInfo {
|
||||
const byte EMC_INDICATOR_NR_CONNECTED_TO_5GCN = 1;
|
||||
const byte EMC_INDICATOR_EUTRA_CONNECTED_TO_5GCN = 2;
|
||||
const byte EMC_INDICATOR_BOTH_NR_EUTRA_CONNECTED_TO_5GCN = 3;
|
||||
const byte EMC_INDICATOR_EMC_OVER_NON_3GPP = 4;
|
||||
const byte EMF_INDICATOR_NOT_SUPPORTED = 0;
|
||||
const byte EMF_INDICATOR_NR_CONNECTED_TO_5GCN = 1;
|
||||
const byte EMF_INDICATOR_EUTRA_CONNECTED_TO_5GCN = 2;
|
||||
|
||||
@@ -40,4 +40,5 @@ parcelable RegStateResult {
|
||||
android.hardware.radio.network.CellIdentity cellIdentity;
|
||||
String registeredPlmn;
|
||||
android.hardware.radio.network.AccessTechnologySpecificInfo accessTechnologySpecificInfo;
|
||||
android.hardware.radio.AccessNetwork accessNetwork = android.hardware.radio.AccessNetwork.UNKNOWN;
|
||||
}
|
||||
|
||||
@@ -39,6 +39,11 @@ enum AccessNetwork {
|
||||
UTRAN = 2,
|
||||
EUTRAN = 3,
|
||||
CDMA2000 = 4,
|
||||
/**
|
||||
* @deprecated should use N3ANEPS or N3AN5GS based on N3AN selection.
|
||||
*/
|
||||
IWLAN = 5,
|
||||
NGRAN = 6,
|
||||
N3ANEPS = 5,
|
||||
N3AN5GS = 7,
|
||||
}
|
||||
|
||||
@@ -36,4 +36,5 @@ package android.hardware.radio;
|
||||
enum RadioTechnologyFamily {
|
||||
THREE_GPP = 0,
|
||||
THREE_GPP2 = 1,
|
||||
NON_3GPP = 2,
|
||||
}
|
||||
|
||||
@@ -23,30 +23,39 @@ enum AccessNetwork {
|
||||
/**
|
||||
* Unknown access network
|
||||
*/
|
||||
UNKNOWN,
|
||||
UNKNOWN = 0,
|
||||
/**
|
||||
* GSM EDGE Radio Access Network
|
||||
*/
|
||||
GERAN,
|
||||
GERAN = 1,
|
||||
/**
|
||||
* Universal Terrestrial Radio Access Network
|
||||
*/
|
||||
UTRAN,
|
||||
UTRAN = 2,
|
||||
/**
|
||||
* Evolved Universal Terrestrial Radio Access Network
|
||||
*/
|
||||
EUTRAN,
|
||||
EUTRAN = 3,
|
||||
/**
|
||||
* CDMA 2000 network
|
||||
*/
|
||||
CDMA2000,
|
||||
CDMA2000 = 4,
|
||||
/**
|
||||
* Interworking Wireless LAN
|
||||
* Interworking Wireless LAN.
|
||||
* @deprecated should use N3ANEPS or N3AN5GS based on N3AN selection.
|
||||
*/
|
||||
IWLAN,
|
||||
IWLAN = 5,
|
||||
/**
|
||||
* Next-Generation Radio Access Network (NGRAN).
|
||||
* Note NGRAN is only for standalone mode. Non-standalone mode uses AccessNetwork EUTRAN.
|
||||
*/
|
||||
NGRAN,
|
||||
NGRAN = 6,
|
||||
/**
|
||||
* Non-3GPP Access Network for EPS.
|
||||
*/
|
||||
N3ANEPS = 5,
|
||||
/**
|
||||
* Non-3GPP Access Network for 5GS.
|
||||
*/
|
||||
N3AN5GS = 7,
|
||||
}
|
||||
|
||||
@@ -28,4 +28,8 @@ enum RadioTechnologyFamily {
|
||||
* 3GPP2 Technologies - CDMA
|
||||
*/
|
||||
THREE_GPP2,
|
||||
/**
|
||||
* Non 3GPP Technologies - IWLAN, N3IWF
|
||||
*/
|
||||
NON_3GPP,
|
||||
}
|
||||
|
||||
@@ -16,6 +16,7 @@
|
||||
|
||||
package android.hardware.radio.data;
|
||||
|
||||
import android.hardware.radio.AccessNetwork;
|
||||
import android.hardware.radio.RadioIndicationType;
|
||||
import android.hardware.radio.data.DataProfileInfo;
|
||||
import android.hardware.radio.data.KeepaliveStatus;
|
||||
@@ -71,6 +72,7 @@ oneway interface IRadioDataIndication {
|
||||
*
|
||||
* @param type Type of radio indication
|
||||
* @param dataProfileInfo Data profile info.
|
||||
* @deprecated use unthrottleDataProfile to clarify access network for this event.
|
||||
*/
|
||||
void unthrottleApn(in RadioIndicationType type, in DataProfileInfo dataProfileInfo);
|
||||
|
||||
@@ -86,4 +88,19 @@ oneway interface IRadioDataIndication {
|
||||
*
|
||||
*/
|
||||
void slicingConfigChanged(in RadioIndicationType type, in SlicingConfig slicingConfig);
|
||||
|
||||
/**
|
||||
* The modem can explicitly set SetupDataCallResult::suggestedRetryTime after a failure in
|
||||
* IRadioData.SetupDataCall. During that time, no new calls are allowed to
|
||||
* IRadioData.SetupDataCall that use the same APN(or DNN) in DataProfile.
|
||||
* When IRadioDataIndication.unthrottleDataProfile is sent, AOSP will no longer throttle calls
|
||||
* to IRadioData.SetupDataCall for the given APN(or DNN) in DataProfile.
|
||||
*
|
||||
* @param type Type of radio indication
|
||||
* @param accessNetwork Access network this throttling occurred, this must match the access
|
||||
* network passed in setup data call request.
|
||||
* @param dataProfileInfo Data profile info.
|
||||
*/
|
||||
void unthrottleDataProfile(in RadioIndicationType type, in AccessNetwork accessNetwork,
|
||||
in DataProfileInfo dataProfileInfo);
|
||||
}
|
||||
|
||||
@@ -17,7 +17,11 @@
|
||||
package android.hardware.radio.network;
|
||||
|
||||
import android.hardware.radio.AccessNetwork;
|
||||
import android.hardware.radio.RadioTechnologyFamily;
|
||||
import android.hardware.radio.network.CdmaRoamingType;
|
||||
import android.hardware.radio.network.Domain;
|
||||
import android.hardware.radio.network.EmergencyMode;
|
||||
import android.hardware.radio.network.EmergencyNetworkScanTrigger;
|
||||
import android.hardware.radio.network.IRadioNetworkIndication;
|
||||
import android.hardware.radio.network.IRadioNetworkResponse;
|
||||
import android.hardware.radio.network.IndicationFilter;
|
||||
@@ -27,8 +31,6 @@ import android.hardware.radio.network.RadioAccessSpecifier;
|
||||
import android.hardware.radio.network.RadioBandMode;
|
||||
import android.hardware.radio.network.SignalThresholdInfo;
|
||||
import android.hardware.radio.network.UsageSetting;
|
||||
import android.hardware.radio.network.EmergencyNetworkScanTrigger;
|
||||
import android.hardware.radio.network.EmergencyMode;
|
||||
|
||||
/**
|
||||
* This interface is used by telephony and telecom to talk to cellular radio for network APIs.
|
||||
@@ -103,6 +105,7 @@ oneway interface IRadioNetwork {
|
||||
* @param serial Serial number of request.
|
||||
*
|
||||
* Response function is IRadioNetworkResponse.getDataRegistrationStateResponse()
|
||||
* @deprecated use getRegistrationState()
|
||||
*/
|
||||
void getDataRegistrationState(in int serial);
|
||||
|
||||
@@ -167,6 +170,7 @@ oneway interface IRadioNetwork {
|
||||
* @param serial Serial number of request.
|
||||
*
|
||||
* Response function is IRadioNetworkResponse.getVoiceRegistrationStateResponse()
|
||||
* @deprecated use getRegistrationState()
|
||||
*/
|
||||
void getVoiceRegistrationState(in int serial);
|
||||
|
||||
@@ -449,7 +453,7 @@ oneway interface IRadioNetwork {
|
||||
*
|
||||
* Response function is IRadioEmergencyResponse.setEmergencyModeResponse()
|
||||
*/
|
||||
void setEmergencyMode(int serial, in EmergencyMode emcModeType );
|
||||
void setEmergencyMode(int serial, in EmergencyMode emcModeType);
|
||||
|
||||
/**
|
||||
* Triggers an Emergency network scan.
|
||||
@@ -460,7 +464,7 @@ oneway interface IRadioNetwork {
|
||||
*
|
||||
* Response function is IRadioEmergencyResponse.triggerEmergencyNetworkScanResponse()
|
||||
*/
|
||||
void triggerEmergencyNetworkScan( int serial, in EmergencyNetworkScanTrigger request);
|
||||
void triggerEmergencyNetworkScan(int serial, in EmergencyNetworkScanTrigger request);
|
||||
|
||||
/**
|
||||
* Cancels ongoing Emergency network scan
|
||||
@@ -479,4 +483,15 @@ oneway interface IRadioNetwork {
|
||||
* Response function is IRadioEmergencyResponse.exitEmergencyModeResponse()
|
||||
*/
|
||||
void exitEmergencyMode(in int serial);
|
||||
|
||||
/**
|
||||
* Request current registration state.
|
||||
*
|
||||
* @param serial Serial number of request.
|
||||
* @param ratFamily RadioTechnologyFamily of request.
|
||||
* @param domain Domain PS or CS of request.
|
||||
*
|
||||
* Response function is IRadioNetworkResponse.getRegistrationStateResponse()
|
||||
*/
|
||||
void getRegistrationState(in int serial, in RadioTechnologyFamily ratFamily, in Domain domain);
|
||||
}
|
||||
|
||||
@@ -23,13 +23,13 @@ import android.hardware.radio.network.BarringInfo;
|
||||
import android.hardware.radio.network.CdmaRoamingType;
|
||||
import android.hardware.radio.network.CellIdentity;
|
||||
import android.hardware.radio.network.CellInfo;
|
||||
import android.hardware.radio.network.EmergencyRegResult;
|
||||
import android.hardware.radio.network.OperatorInfo;
|
||||
import android.hardware.radio.network.RadioAccessSpecifier;
|
||||
import android.hardware.radio.network.RadioBandMode;
|
||||
import android.hardware.radio.network.RegStateResult;
|
||||
import android.hardware.radio.network.SignalStrength;
|
||||
import android.hardware.radio.network.UsageSetting;
|
||||
import android.hardware.radio.network.EmergencyRegResult;
|
||||
|
||||
/**
|
||||
* Interface declaring response functions to solicited radio requests for network APIs.
|
||||
@@ -153,6 +153,8 @@ oneway interface IRadioNetworkResponse {
|
||||
* RadioError:RADIO_NOT_AVAILABLE
|
||||
* RadioError:INTERNAL_ERR
|
||||
* RadioError:NOT_PROVISIONED
|
||||
*
|
||||
* @deprecated use getRegistrationStateResponse()
|
||||
*/
|
||||
void getDataRegistrationStateResponse(
|
||||
in RadioResponseInfo info, in RegStateResult dataRegResponse);
|
||||
@@ -259,6 +261,8 @@ oneway interface IRadioNetworkResponse {
|
||||
* RadioError:NONE
|
||||
* RadioError:RADIO_NOT_AVAILABLE
|
||||
* RadioError:INTERNAL_ERR
|
||||
*
|
||||
* @deprecated use getRegistrationStateResponse()
|
||||
*/
|
||||
void getVoiceRegistrationStateResponse(
|
||||
in RadioResponseInfo info, in RegStateResult voiceRegResponse);
|
||||
@@ -616,4 +620,16 @@ oneway interface IRadioNetworkResponse {
|
||||
* RadioError:MODEM_ERR
|
||||
*/
|
||||
void cancelEmergencyNetworkScanResponse(in RadioResponseInfo info);
|
||||
|
||||
/**
|
||||
* @param info Response info struct containing response type, serial no. and error
|
||||
* @param regResponse Current registration response as defined by RegStateResult
|
||||
*
|
||||
* Valid errors returned:
|
||||
* RadioError:NONE
|
||||
* RadioError:RADIO_NOT_AVAILABLE
|
||||
* RadioError:INTERNAL_ERR
|
||||
* RadioError:NOT_PROVISIONED
|
||||
*/
|
||||
void getRegistrationStateResponse(in RadioResponseInfo info, in RegStateResult regResponse);
|
||||
}
|
||||
|
||||
@@ -39,6 +39,10 @@ parcelable NrVopsInfo {
|
||||
* Emergency services supported in NR connected to 5GCN and E-UTRA connected to 5GCN
|
||||
*/
|
||||
const byte EMC_INDICATOR_BOTH_NR_EUTRA_CONNECTED_TO_5GCN = 3;
|
||||
/**
|
||||
* Emergency services supported over 5G N3GPP access.
|
||||
*/
|
||||
const byte EMC_INDICATOR_EMC_OVER_NON_3GPP = 4;
|
||||
|
||||
/**
|
||||
* Emergency services fallback not supported
|
||||
@@ -96,6 +100,7 @@ parcelable NrVopsInfo {
|
||||
* NR REGISTRATION ACCEPT.
|
||||
* Refer 3GPP 24.501 EPS 5GS network feature support -> EMF
|
||||
* Values are EMF_INDICATOR_ from TS 24.501 sec 9.10.3.5.
|
||||
* Not Applicable for the registration via non-3GPP access.
|
||||
*/
|
||||
byte emfSupported;
|
||||
}
|
||||
|
||||
@@ -16,6 +16,7 @@
|
||||
|
||||
package android.hardware.radio.network;
|
||||
|
||||
import android.hardware.radio.AccessNetwork;
|
||||
import android.hardware.radio.RadioTechnology;
|
||||
import android.hardware.radio.network.AccessTechnologySpecificInfo;
|
||||
import android.hardware.radio.network.CellIdentity;
|
||||
@@ -59,4 +60,8 @@ parcelable RegStateResult {
|
||||
* Access-technology-specific registration information, such as for CDMA2000.
|
||||
*/
|
||||
AccessTechnologySpecificInfo accessTechnologySpecificInfo;
|
||||
/**
|
||||
* Indicates the access network used for this registration.
|
||||
*/
|
||||
AccessNetwork accessNetwork = AccessNetwork.UNKNOWN;
|
||||
}
|
||||
|
||||
@@ -31,12 +31,13 @@ cc_library {
|
||||
"-DANDROID_UTILS_REF_BASE_DISABLE_IMPLICIT_CONSTRUCTION",
|
||||
],
|
||||
shared_libs: [
|
||||
"android.hardware.radio-V2-ndk",
|
||||
"android.hardware.radio.config-V1-ndk",
|
||||
"android.hardware.radio.config@1.0",
|
||||
"android.hardware.radio.config@1.1",
|
||||
"android.hardware.radio.config@1.2",
|
||||
"android.hardware.radio.config@1.3",
|
||||
"android.hardware.radio.data-V1-ndk",
|
||||
"android.hardware.radio.data-V2-ndk",
|
||||
"android.hardware.radio.messaging-V1-ndk",
|
||||
"android.hardware.radio.modem-V1-ndk",
|
||||
"android.hardware.radio.network-V2-ndk",
|
||||
|
||||
@@ -99,6 +99,9 @@ class RadioNetwork : public RadioCompatBase,
|
||||
scanTrigger) override;
|
||||
::ndk::ScopedAStatus cancelEmergencyNetworkScan(int32_t serial) override;
|
||||
::ndk::ScopedAStatus exitEmergencyMode(int32_t serial) override;
|
||||
::ndk::ScopedAStatus getRegistrationState(
|
||||
int32_t serial, ::aidl::android::hardware::radio::RadioTechnologyFamily ratFamily,
|
||||
::aidl::android::hardware::radio::network::Domain domain) override;
|
||||
|
||||
protected:
|
||||
std::shared_ptr<::aidl::android::hardware::radio::network::IRadioNetworkResponse> respond();
|
||||
|
||||
@@ -340,4 +340,16 @@ ScopedAStatus RadioNetwork::exitEmergencyMode(int32_t serial) {
|
||||
return ok();
|
||||
}
|
||||
|
||||
ScopedAStatus RadioNetwork::getRegistrationState(
|
||||
int32_t serial, ::aidl::android::hardware::radio::RadioTechnologyFamily ratFamily,
|
||||
aidl::Domain domain) {
|
||||
LOG_CALL << serial;
|
||||
if (ratFamily == ::aidl::android::hardware::radio::RadioTechnologyFamily::THREE_GPP &&
|
||||
domain == aidl::Domain::PS) {
|
||||
LOG_CALL << " Radio Technology Family 3GPP and Domain PS";
|
||||
}
|
||||
LOG(ERROR) << " geRegistrationState is unsupported by HIDL HALs";
|
||||
respond()->getRegistrationStateResponse(notSupported(serial), {});
|
||||
return ok();
|
||||
}
|
||||
} // namespace android::hardware::radio::compat
|
||||
|
||||
@@ -34,12 +34,13 @@ cc_binary {
|
||||
],
|
||||
shared_libs: [
|
||||
"android.hardware.radio-library.compat",
|
||||
"android.hardware.radio-V2-ndk",
|
||||
"android.hardware.radio.config-V1-ndk",
|
||||
"android.hardware.radio.config@1.0",
|
||||
"android.hardware.radio.config@1.1",
|
||||
"android.hardware.radio.config@1.2",
|
||||
"android.hardware.radio.config@1.3",
|
||||
"android.hardware.radio.data-V1-ndk",
|
||||
"android.hardware.radio.data-V2-ndk",
|
||||
"android.hardware.radio.messaging-V1-ndk",
|
||||
"android.hardware.radio.modem-V1-ndk",
|
||||
"android.hardware.radio.network-V2-ndk",
|
||||
|
||||
@@ -63,9 +63,9 @@ cc_test {
|
||||
"libvintf",
|
||||
],
|
||||
static_libs: [
|
||||
"android.hardware.radio-V1-ndk",
|
||||
"android.hardware.radio-V2-ndk",
|
||||
"android.hardware.radio.config-V1-ndk",
|
||||
"android.hardware.radio.data-V1-ndk",
|
||||
"android.hardware.radio.data-V2-ndk",
|
||||
"android.hardware.radio.messaging-V1-ndk",
|
||||
"android.hardware.radio.modem-V1-ndk",
|
||||
"android.hardware.radio.network-V2-ndk",
|
||||
|
||||
@@ -42,3 +42,10 @@ ndk::ScopedAStatus RadioDataIndication::slicingConfigChanged(
|
||||
RadioIndicationType /*type*/, const SlicingConfig& /*slicingConfig*/) {
|
||||
return ndk::ScopedAStatus::ok();
|
||||
}
|
||||
|
||||
ndk::ScopedAStatus RadioDataIndication::unthrottleDataProfile(
|
||||
RadioIndicationType /*type*/,
|
||||
::aidl::android::hardware::radio::AccessNetwork /*accessNetwork*/,
|
||||
const DataProfileInfo& /*dataProfileInfo*/) {
|
||||
return ndk::ScopedAStatus::ok();
|
||||
}
|
||||
|
||||
@@ -97,6 +97,9 @@ class RadioDataIndication : public BnRadioDataIndication {
|
||||
const DataProfileInfo& dataProfile) override;
|
||||
virtual ndk::ScopedAStatus slicingConfigChanged(RadioIndicationType type,
|
||||
const SlicingConfig& slicingConfig) override;
|
||||
virtual ndk::ScopedAStatus unthrottleDataProfile(
|
||||
RadioIndicationType type, ::aidl::android::hardware::radio::AccessNetwork accessNetwork,
|
||||
const DataProfileInfo& dataProfile) override;
|
||||
};
|
||||
|
||||
// The main test class for Radio AIDL Data.
|
||||
|
||||
@@ -293,3 +293,11 @@ ndk::ScopedAStatus RadioNetworkResponse::cancelEmergencyNetworkScanResponse(
|
||||
parent_network.notify(info.serial);
|
||||
return ndk::ScopedAStatus::ok();
|
||||
}
|
||||
|
||||
ndk::ScopedAStatus RadioNetworkResponse::getRegistrationStateResponse(
|
||||
const RadioResponseInfo& info, const RegStateResult& regResponse) {
|
||||
rspInfo = info;
|
||||
regResp = regResponse;
|
||||
parent_network.notify(info.serial);
|
||||
return ndk::ScopedAStatus::ok();
|
||||
}
|
||||
|
||||
@@ -15,7 +15,9 @@
|
||||
*/
|
||||
|
||||
#include <aidl/android/hardware/radio/RadioAccessFamily.h>
|
||||
#include <aidl/android/hardware/radio/RadioTechnologyFamily.h>
|
||||
#include <aidl/android/hardware/radio/config/IRadioConfig.h>
|
||||
#include <aidl/android/hardware/radio/network/Domain.h>
|
||||
#include <aidl/android/hardware/radio/network/IndicationFilter.h>
|
||||
#include <android-base/logging.h>
|
||||
#include <android/binder_manager.h>
|
||||
@@ -1911,3 +1913,91 @@ TEST_P(RadioNetworkTest, exitEmergencyMode) {
|
||||
{RadioError::NONE, RadioError::RADIO_NOT_AVAILABLE, RadioError::MODEM_ERR}));
|
||||
LOG(DEBUG) << "exitEmergencyMode finished";
|
||||
}
|
||||
|
||||
/*
|
||||
* Test IRadioNetwork.getRegistrationState() for the response returned.
|
||||
*/
|
||||
TEST_P(RadioNetworkTest, getRegistrationState) {
|
||||
serial = GetRandomSerialNumber();
|
||||
|
||||
ndk::ScopedAStatus res = radio_network->getRegistrationState(
|
||||
serial, RadioTechnologyFamily::THREE_GPP, Domain::PS);
|
||||
ASSERT_OK(res);
|
||||
EXPECT_EQ(std::cv_status::no_timeout, wait());
|
||||
EXPECT_EQ(RadioResponseType::SOLICITED, radioRsp_network->rspInfo.type);
|
||||
EXPECT_EQ(serial, radioRsp_network->rspInfo.serial);
|
||||
|
||||
ALOGI("getRegistrationStateResponse, rspInfo.error = %s\n",
|
||||
toString(radioRsp_network->rspInfo.error).c_str());
|
||||
ASSERT_TRUE(CheckAnyOfErrors(
|
||||
radioRsp_network->rspInfo.error,
|
||||
{RadioError::NONE, RadioError::RADIO_NOT_AVAILABLE, RadioError::NOT_PROVISIONED}));
|
||||
// Check the mcc [0, 999] and mnc [0, 999].
|
||||
std::string mcc;
|
||||
std::string mnc;
|
||||
bool checkMccMnc = true;
|
||||
CellIdentity cellIdentity = radioRsp_network->regResp.cellIdentity;
|
||||
switch (cellIdentity.getTag()) {
|
||||
case CellIdentity::noinit: {
|
||||
checkMccMnc = false;
|
||||
break;
|
||||
}
|
||||
case CellIdentity::gsm: {
|
||||
CellIdentityGsm cig = cellIdentity.get<CellIdentity::gsm>();
|
||||
mcc = cig.mcc;
|
||||
mnc = cig.mnc;
|
||||
break;
|
||||
}
|
||||
case CellIdentity::wcdma: {
|
||||
CellIdentityWcdma ciw = cellIdentity.get<CellIdentity::wcdma>();
|
||||
mcc = ciw.mcc;
|
||||
mnc = ciw.mnc;
|
||||
break;
|
||||
}
|
||||
case CellIdentity::tdscdma: {
|
||||
CellIdentityTdscdma cit = cellIdentity.get<CellIdentity::tdscdma>();
|
||||
mcc = cit.mcc;
|
||||
mnc = cit.mnc;
|
||||
break;
|
||||
}
|
||||
case CellIdentity::cdma: {
|
||||
// CellIdentityCdma has no mcc/mnc
|
||||
CellIdentityCdma cic = cellIdentity.get<CellIdentity::cdma>();
|
||||
checkMccMnc = false;
|
||||
break;
|
||||
}
|
||||
case CellIdentity::lte: {
|
||||
CellIdentityLte cil = cellIdentity.get<CellIdentity::lte>();
|
||||
mcc = cil.mcc;
|
||||
mnc = cil.mnc;
|
||||
break;
|
||||
}
|
||||
case CellIdentity::nr: {
|
||||
CellIdentityNr cin = cellIdentity.get<CellIdentity::nr>();
|
||||
mcc = cin.mcc;
|
||||
mnc = cin.mnc;
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
// 32 bit system might return invalid mcc and mnc string "\xff\xff..."
|
||||
if (checkMccMnc && mcc.size() < 4 && mnc.size() < 4) {
|
||||
int mcc_int = stoi(mcc);
|
||||
int mnc_int = stoi(mnc);
|
||||
EXPECT_TRUE(mcc_int >= 0 && mcc_int <= 999);
|
||||
EXPECT_TRUE(mnc_int >= 0 && mnc_int <= 999);
|
||||
}
|
||||
|
||||
// Check for access technology specific info
|
||||
AccessTechnologySpecificInfo info = radioRsp_network->regResp.accessTechnologySpecificInfo;
|
||||
RadioTechnology rat = radioRsp_network->regResp.rat;
|
||||
// TODO: add logic for cdmaInfo
|
||||
if (rat == RadioTechnology::LTE || rat == RadioTechnology::LTE_CA) {
|
||||
ASSERT_EQ(info.getTag(), AccessTechnologySpecificInfo::eutranInfo);
|
||||
} else if (rat == RadioTechnology::NR) {
|
||||
ASSERT_EQ(info.getTag(), AccessTechnologySpecificInfo::ngranNrVopsInfo);
|
||||
}
|
||||
AccessNetwork an = radioRsp_network->regResp.accessNetwork;
|
||||
ASSERT_NE(an, AccessNetwork::N3AN5GS);
|
||||
ASSERT_NE(an, AccessNetwork::N3ANEPS);
|
||||
}
|
||||
|
||||
@@ -42,6 +42,7 @@ class RadioNetworkResponse : public BnRadioNetworkResponse {
|
||||
int networkTypeBitmapResponse;
|
||||
RegStateResult voiceRegResp;
|
||||
RegStateResult dataRegResp;
|
||||
RegStateResult regResp;
|
||||
CellIdentity barringCellIdentity;
|
||||
std::vector<BarringInfo> barringInfoList;
|
||||
UsageSetting usageSetting;
|
||||
@@ -158,6 +159,9 @@ class RadioNetworkResponse : public BnRadioNetworkResponse {
|
||||
|
||||
virtual ndk::ScopedAStatus cancelEmergencyNetworkScanResponse(
|
||||
const RadioResponseInfo& info) override;
|
||||
|
||||
virtual ndk::ScopedAStatus getRegistrationStateResponse(
|
||||
const RadioResponseInfo& info, const RegStateResult& regResponse) override;
|
||||
};
|
||||
|
||||
/* Callback class for radio network indication */
|
||||
|
||||
Reference in New Issue
Block a user