diff options
author | Sanket Padawe <sanketpadawe@google.com> | 2016-01-27 15:09:12 -0800 |
---|---|---|
committer | Sanket Padawe <sanketpadawe@google.com> | 2016-01-27 15:09:12 -0800 |
commit | 6ff9a87b250598ea9e383f06a4257512bd0c8046 (patch) | |
tree | 2cc70255c0d5cbcd5bae1e1477922a9a1ab9db49 /include | |
parent | f53c5fa96381915e20353cfedc798c0e3c52289b (diff) | |
download | android_hardware_ril-6ff9a87b250598ea9e383f06a4257512bd0c8046.tar.gz android_hardware_ril-6ff9a87b250598ea9e383f06a4257512bd0c8046.tar.bz2 android_hardware_ril-6ff9a87b250598ea9e383f06a4257512bd0c8046.zip |
Improve wakelock symantics in RIL.
Bug: 22127517
Change-Id: I13fce25c8c6b27987e576b29a2ca5cd813f5b06f
Diffstat (limited to 'include')
-rw-r--r-- | include/telephony/ril.h | 44 |
1 files changed, 40 insertions, 4 deletions
diff --git a/include/telephony/ril.h b/include/telephony/ril.h index f7141cc..cfa7138 100644 --- a/include/telephony/ril.h +++ b/include/telephony/ril.h @@ -60,11 +60,12 @@ extern "C" { * RIL_VERSION = 12 : This version corresponds to updated data structures namely * RIL_Data_Call_Response_v11, RIL_SIM_IO_v6, RIL_CardStatus_v6, * RIL_SimRefreshResponse_v7, RIL_CDMA_CallWaiting_v6, - * RIL_LTE_SignalStrength_v8, RIL_SignalStrength_v10, RIL_SignalStrength_v10, - * RIL_CellIdentityGsm_v12, RIL_CellIdentityWcdma_v12, RIL_CellIdentityLte_v12, - * RIL_CellInfoGsm_v12, RIL_CellInfoWcdma_v12, RIL_CellInfoLte_v12, RIL_CellInfo_v12. + * RIL_LTE_SignalStrength_v8, RIL_SignalStrength_v10, RIL_CellIdentityGsm_v12 + * RIL_CellIdentityWcdma_v12, RIL_CellIdentityLte_v12,RIL_CellInfoGsm_v12, + * RIL_CellInfoWcdma_v12, RIL_CellInfoLte_v12, RIL_CellInfo_v12. * - * RIL_VERSION = 13 : This version includes new wakelock semantics. + * RIL_VERSION = 13 : This version includes new wakelock semantics and as the first + * strongly versioned version it enforces structure use. */ #define RIL_VERSION 12 #define LAST_IMPRECISE_RIL_VERSION 12 // Better self-documented name @@ -4618,6 +4619,22 @@ typedef struct { /***********************************************************************/ +/** + * RIL_RESPONSE_ACKNOWLEDGEMENT + * + * This is used by Asynchronous solicited messages and Unsolicited messages + * to acknowledge the receipt of those messages in RIL.java so that the ack + * can be used to let ril.cpp to release wakelock. + * + * Valid errors + * SUCCESS + * RADIO_NOT_AVAILABLE + */ + +#define RIL_RESPONSE_ACKNOWLEDGEMENT 800 + +/***********************************************************************/ + #define RIL_UNSOL_RESPONSE_BASE 1000 @@ -5368,6 +5385,13 @@ struct RIL_Env { void (*RequestTimedCallback) (RIL_TimedCallback callback, void *param, const struct timeval *relativeTime); + /** + * "t" is parameter passed in on previous call RIL_Notification routine + * + * RIL_onRequestAck will be called by vendor when an Async RIL request was received + * by them and an ack needs to be sent back to java ril. + */ + void (*OnRequestAck) (RIL_Token t); }; @@ -5408,6 +5432,18 @@ void RIL_register (const RIL_RadioFunctions *callbacks); void RIL_onRequestComplete(RIL_Token t, RIL_Errno e, void *response, size_t responselen); +/** + * RIL_onRequestAck will be called by vendor when an Async RIL request was received by them and + * an ack needs to be sent back to java ril. This doesn't mark the end of the command or it's + * results, just that the command was received and will take a while. After sending this Ack + * its vendor's responsibility to make sure that AP is up whenever needed while command is + * being processed. + * + * @param t is parameter passed in on previous call to RIL_Notification + * routine. + */ +void RIL_onRequestAck(RIL_Token t); + #if defined(ANDROID_MULTI_SIM) /** * @param unsolResponse is one of RIL_UNSOL_RESPONSE_* |