2 * Copyright (c) 2016 The Android Open Source Project
4 * Licensed under the Apache License, Version 2.0 (the "License");
5 * you may not use this file except in compliance with the License.
6 * You may obtain a copy of the License at
8 * http://www.apache.org/licenses/LICENSE-2.0
10 * Unless required by applicable law or agreed to in writing, software
11 * distributed under the License is distributed on an "AS IS" BASIS,
12 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 * See the License for the specific language governing permissions and
14 * limitations under the License.
20 #include <telephony/ril.h>
21 #include <ril_internal.h>
24 void registerService(RIL_RadioFunctions *callbacks, android::CommandInfo *commands);
26 int getIccCardStatusResponse(int slotId, int responseType,
27 int token, RIL_Errno e, void *response, size_t responselen);
29 int supplyIccPinForAppResponse(int slotId,
30 int responseType, int serial, RIL_Errno e, void *response,
33 int supplyIccPukForAppResponse(int slotId,
34 int responseType, int serial, RIL_Errno e, void *response,
37 int supplyIccPin2ForAppResponse(int slotId,
38 int responseType, int serial, RIL_Errno e, void *response,
41 int supplyIccPuk2ForAppResponse(int slotId,
42 int responseType, int serial, RIL_Errno e, void *response,
45 int changeIccPinForAppResponse(int slotId,
46 int responseType, int serial, RIL_Errno e, void *response,
49 int changeIccPin2ForAppResponse(int slotId,
50 int responseType, int serial, RIL_Errno e, void *response,
53 int supplyNetworkDepersonalizationResponse(int slotId,
54 int responseType, int serial, RIL_Errno e,
55 void *response, size_t responselen);
57 int getCurrentCallsResponse(int slotId,
58 int responseType, int serial, RIL_Errno e, void *response,
61 int dialResponse(int slotId,
62 int responseType, int serial, RIL_Errno e, void *response, size_t responselen);
64 int getIMSIForAppResponse(int slotId, int responseType,
65 int serial, RIL_Errno e, void *response, size_t responselen);
67 int hangupConnectionResponse(int slotId, int responseType,
68 int serial, RIL_Errno e, void *response, size_t responselen);
70 int hangupWaitingOrBackgroundResponse(int slotId,
71 int responseType, int serial, RIL_Errno e, void *response,
74 int hangupForegroundResumeBackgroundResponse(int slotId,
75 int responseType, int serial, RIL_Errno e,
76 void *response, size_t responselen);
78 int switchWaitingOrHoldingAndActiveResponse(int slotId,
79 int responseType, int serial, RIL_Errno e,
80 void *response, size_t responselen);
82 int conferenceResponse(int slotId, int responseType,
83 int serial, RIL_Errno e, void *response, size_t responselen);
85 int rejectCallResponse(int slotId, int responseType,
86 int serial, RIL_Errno e, void *response, size_t responselen);
88 int getLastCallFailCauseResponse(int slotId,
89 int responseType, int serial, RIL_Errno e, void *response,
92 int getSignalStrengthResponse(int slotId,
93 int responseType, int serial, RIL_Errno e,
94 void *response, size_t responseLen);
96 int getVoiceRegistrationStateResponse(int slotId,
97 int responseType, int serial, RIL_Errno e, void *response,
100 int getDataRegistrationStateResponse(int slotId,
101 int responseType, int serial, RIL_Errno e, void *response,
104 int getOperatorResponse(int slotId,
105 int responseType, int serial, RIL_Errno e, void *response,
108 int setRadioPowerResponse(int slotId,
109 int responseType, int serial, RIL_Errno e, void *response,
112 int sendDtmfResponse(int slotId,
113 int responseType, int serial, RIL_Errno e, void *response,
116 int sendSmsResponse(int slotId,
117 int responseType, int serial, RIL_Errno e, void *response,
120 int sendSMSExpectMoreResponse(int slotId,
121 int responseType, int serial, RIL_Errno e, void *response,
124 int setupDataCallResponse(int slotId,
125 int responseType, int serial, RIL_Errno e, void *response,
128 int iccIOForAppResponse(int slotId,
129 int responseType, int serial, RIL_Errno e, void *response,
132 int sendUssdResponse(int slotId,
133 int responseType, int serial, RIL_Errno e, void *response,
136 int cancelPendingUssdResponse(int slotId,
137 int responseType, int serial, RIL_Errno e, void *response,
140 int getClirResponse(int slotId,
141 int responseType, int serial, RIL_Errno e, void *response, size_t responselen);
143 int setClirResponse(int slotId,
144 int responseType, int serial, RIL_Errno e, void *response, size_t responselen);
146 int getCallForwardStatusResponse(int slotId,
147 int responseType, int serial, RIL_Errno e, void *response,
150 int setCallForwardResponse(int slotId,
151 int responseType, int serial, RIL_Errno e, void *response,
154 int getCallWaitingResponse(int slotId,
155 int responseType, int serial, RIL_Errno e, void *response,
158 int setCallWaitingResponse(int slotId,
159 int responseType, int serial, RIL_Errno e, void *response,
162 int acknowledgeLastIncomingGsmSmsResponse(int slotId,
163 int responseType, int serial, RIL_Errno e, void *response,
166 int acceptCallResponse(int slotId,
167 int responseType, int serial, RIL_Errno e, void *response,
170 int deactivateDataCallResponse(int slotId,
171 int responseType, int serial, RIL_Errno e, void *response,
174 int getFacilityLockForAppResponse(int slotId,
175 int responseType, int serial, RIL_Errno e, void *response,
178 int setFacilityLockForAppResponse(int slotId,
179 int responseType, int serial, RIL_Errno e, void *response,
182 int setBarringPasswordResponse(int slotId,
183 int responseType, int serial, RIL_Errno e, void *response,
186 int getNetworkSelectionModeResponse(int slotId,
187 int responseType, int serial, RIL_Errno e, void *response,
190 int setNetworkSelectionModeAutomaticResponse(int slotId,
191 int responseType, int serial, RIL_Errno e,
192 void *response, size_t responselen);
194 int setNetworkSelectionModeManualResponse(int slotId,
195 int responseType, int serial, RIL_Errno e, void *response,
198 int getAvailableNetworksResponse(int slotId,
199 int responseType, int serial, RIL_Errno e, void *response,
202 int startNetworkScanResponse(int slotId,
203 int responseType, int serial, RIL_Errno e, void *response,
206 int stopNetworkScanResponse(int slotId,
207 int responseType, int serial, RIL_Errno e, void *response,
210 int startDtmfResponse(int slotId,
211 int responseType, int serial, RIL_Errno e, void *response,
214 int stopDtmfResponse(int slotId,
215 int responseType, int serial, RIL_Errno e, void *response,
218 int getBasebandVersionResponse(int slotId,
219 int responseType, int serial, RIL_Errno e, void *response,
222 int separateConnectionResponse(int slotId,
223 int responseType, int serial, RIL_Errno e, void *response,
226 int setMuteResponse(int slotId,
227 int responseType, int serial, RIL_Errno e, void *response,
230 int getMuteResponse(int slotId,
231 int responseType, int serial, RIL_Errno e, void *response,
234 int getClipResponse(int slotId,
235 int responseType, int serial, RIL_Errno e, void *response,
238 int getDataCallListResponse(int slotId,
239 int responseType, int serial, RIL_Errno e,
240 void *response, size_t responseLen);
242 int setSuppServiceNotificationsResponse(int slotId,
243 int responseType, int serial, RIL_Errno e, void *response,
246 int writeSmsToSimResponse(int slotId,
247 int responseType, int serial, RIL_Errno e, void *response,
250 int deleteSmsOnSimResponse(int slotId,
251 int responseType, int serial, RIL_Errno e, void *response,
254 int setBandModeResponse(int slotId,
255 int responseType, int serial, RIL_Errno e, void *response,
258 int getAvailableBandModesResponse(int slotId,
259 int responseType, int serial, RIL_Errno e, void *response,
262 int sendEnvelopeResponse(int slotId,
263 int responseType, int serial, RIL_Errno e, void *response,
266 int sendTerminalResponseToSimResponse(int slotId,
267 int responseType, int serial, RIL_Errno e, void *response,
270 int handleStkCallSetupRequestFromSimResponse(int slotId,
271 int responseType, int serial, RIL_Errno e,
272 void *response, size_t responselen);
274 int explicitCallTransferResponse(int slotId,
275 int responseType, int serial, RIL_Errno e, void *response,
278 int setPreferredNetworkTypeResponse(int slotId,
279 int responseType, int serial, RIL_Errno e, void *response,
282 int getPreferredNetworkTypeResponse(int slotId,
283 int responseType, int serial, RIL_Errno e, void *response,
286 int getNeighboringCidsResponse(int slotId,
287 int responseType, int serial, RIL_Errno e, void *response,
290 int setLocationUpdatesResponse(int slotId,
291 int responseType, int serial, RIL_Errno e, void *response,
294 int setCdmaSubscriptionSourceResponse(int slotId,
295 int responseType, int serial, RIL_Errno e, void *response,
298 int setCdmaRoamingPreferenceResponse(int slotId,
299 int responseType, int serial, RIL_Errno e, void *response,
302 int getCdmaRoamingPreferenceResponse(int slotId,
303 int responseType, int serial, RIL_Errno e, void *response,
306 int setTTYModeResponse(int slotId,
307 int responseType, int serial, RIL_Errno e, void *response,
310 int getTTYModeResponse(int slotId,
311 int responseType, int serial, RIL_Errno e, void *response,
314 int setPreferredVoicePrivacyResponse(int slotId,
315 int responseType, int serial, RIL_Errno e, void *response,
318 int getPreferredVoicePrivacyResponse(int slotId,
319 int responseType, int serial, RIL_Errno e, void *response,
322 int sendCDMAFeatureCodeResponse(int slotId,
323 int responseType, int serial, RIL_Errno e,
324 void *response, size_t responselen);
326 int sendBurstDtmfResponse(int slotId,
327 int responseType, int serial, RIL_Errno e, void *response,
330 int sendCdmaSmsResponse(int slotId,
331 int responseType, int serial, RIL_Errno e, void *response,
334 int acknowledgeLastIncomingCdmaSmsResponse(int slotId,
335 int responseType, int serial, RIL_Errno e, void *response,
338 int getGsmBroadcastConfigResponse(int slotId,
339 int responseType, int serial, RIL_Errno e, void *response,
342 int setGsmBroadcastConfigResponse(int slotId,
343 int responseType, int serial, RIL_Errno e, void *response,
346 int setGsmBroadcastActivationResponse(int slotId,
347 int responseType, int serial, RIL_Errno e, void *response,
350 int getCdmaBroadcastConfigResponse(int slotId,
351 int responseType, int serial, RIL_Errno e, void *response,
354 int setCdmaBroadcastConfigResponse(int slotId,
355 int responseType, int serial, RIL_Errno e, void *response,
358 int setCdmaBroadcastActivationResponse(int slotId,
359 int responseType, int serial, RIL_Errno e,
360 void *response, size_t responselen);
362 int getCDMASubscriptionResponse(int slotId,
363 int responseType, int serial, RIL_Errno e, void *response,
366 int writeSmsToRuimResponse(int slotId,
367 int responseType, int serial, RIL_Errno e, void *response,
370 int deleteSmsOnRuimResponse(int slotId,
371 int responseType, int serial, RIL_Errno e, void *response,
374 int getDeviceIdentityResponse(int slotId,
375 int responseType, int serial, RIL_Errno e, void *response,
378 int exitEmergencyCallbackModeResponse(int slotId,
379 int responseType, int serial, RIL_Errno e, void *response,
382 int getSmscAddressResponse(int slotId,
383 int responseType, int serial, RIL_Errno e, void *response,
386 int setCdmaBroadcastActivationResponse(int slotId,
387 int responseType, int serial, RIL_Errno e,
388 void *response, size_t responselen);
390 int setSmscAddressResponse(int slotId,
391 int responseType, int serial, RIL_Errno e,
392 void *response, size_t responselen);
394 int reportSmsMemoryStatusResponse(int slotId,
395 int responseType, int serial, RIL_Errno e,
396 void *response, size_t responselen);
398 int reportStkServiceIsRunningResponse(int slotId,
399 int responseType, int serial, RIL_Errno e,
400 void *response, size_t responseLen);
402 int getCdmaSubscriptionSourceResponse(int slotId,
403 int responseType, int serial, RIL_Errno e, void *response,
406 int requestIsimAuthenticationResponse(int slotId,
407 int responseType, int serial, RIL_Errno e, void *response,
410 int acknowledgeIncomingGsmSmsWithPduResponse(int slotId,
411 int responseType, int serial, RIL_Errno e,
412 void *response, size_t responselen);
414 int sendEnvelopeWithStatusResponse(int slotId,
415 int responseType, int serial, RIL_Errno e, void *response,
418 int getVoiceRadioTechnologyResponse(int slotId,
419 int responseType, int serial, RIL_Errno e,
420 void *response, size_t responselen);
422 int getCellInfoListResponse(int slotId,
424 int serial, RIL_Errno e, void *response,
427 int setCellInfoListRateResponse(int slotId,
428 int responseType, int serial, RIL_Errno e,
429 void *response, size_t responselen);
431 int setInitialAttachApnResponse(int slotId,
432 int responseType, int serial, RIL_Errno e,
433 void *response, size_t responselen);
435 int getImsRegistrationStateResponse(int slotId,
436 int responseType, int serial, RIL_Errno e,
437 void *response, size_t responselen);
439 int sendImsSmsResponse(int slotId, int responseType,
440 int serial, RIL_Errno e, void *response, size_t responselen);
442 int iccTransmitApduBasicChannelResponse(int slotId,
443 int responseType, int serial, RIL_Errno e,
444 void *response, size_t responselen);
446 int iccOpenLogicalChannelResponse(int slotId,
447 int responseType, int serial, RIL_Errno e, void *response,
451 int iccCloseLogicalChannelResponse(int slotId,
452 int responseType, int serial, RIL_Errno e,
453 void *response, size_t responselen);
455 int iccTransmitApduLogicalChannelResponse(int slotId,
456 int responseType, int serial, RIL_Errno e,
457 void *response, size_t responselen);
459 int nvReadItemResponse(int slotId,
460 int responseType, int serial, RIL_Errno e,
461 void *response, size_t responselen);
464 int nvWriteItemResponse(int slotId,
465 int responseType, int serial, RIL_Errno e,
466 void *response, size_t responselen);
468 int nvWriteCdmaPrlResponse(int slotId,
469 int responseType, int serial, RIL_Errno e,
470 void *response, size_t responselen);
472 int nvResetConfigResponse(int slotId,
473 int responseType, int serial, RIL_Errno e,
474 void *response, size_t responselen);
476 int setUiccSubscriptionResponse(int slotId,
477 int responseType, int serial, RIL_Errno e,
478 void *response, size_t responselen);
480 int setDataAllowedResponse(int slotId,
481 int responseType, int serial, RIL_Errno e,
482 void *response, size_t responselen);
484 int getHardwareConfigResponse(int slotId,
485 int responseType, int serial, RIL_Errno e,
486 void *response, size_t responseLen);
488 int requestIccSimAuthenticationResponse(int slotId,
489 int responseType, int serial, RIL_Errno e,
490 void *response, size_t responselen);
492 int setDataProfileResponse(int slotId,
493 int responseType, int serial, RIL_Errno e,
494 void *response, size_t responselen);
496 int requestShutdownResponse(int slotId,
497 int responseType, int serial, RIL_Errno e,
498 void *response, size_t responselen);
500 int getRadioCapabilityResponse(int slotId,
501 int responseType, int serial, RIL_Errno e,
502 void *response, size_t responseLen);
504 int setRadioCapabilityResponse(int slotId,
505 int responseType, int serial, RIL_Errno e,
506 void *response, size_t responseLen);
508 int startLceServiceResponse(int slotId,
509 int responseType, int serial, RIL_Errno e,
510 void *response, size_t responselen);
512 int stopLceServiceResponse(int slotId,
513 int responseType, int serial, RIL_Errno e,
514 void *response, size_t responselen);
516 int pullLceDataResponse(int slotId,
517 int responseType, int serial, RIL_Errno e,
518 void *response, size_t responseLen);
520 int getModemActivityInfoResponse(int slotId,
521 int responseType, int serial, RIL_Errno e,
522 void *response, size_t responselen);
524 int setAllowedCarriersResponse(int slotId,
525 int responseType, int serial, RIL_Errno e,
526 void *response, size_t responselen);
528 int getAllowedCarriersResponse(int slotId,
529 int responseType, int serial, RIL_Errno e,
530 void *response, size_t responselen);
532 int sendDeviceStateResponse(int slotId,
533 int responseType, int serial, RIL_Errno e,
534 void *response, size_t responselen);
536 int setIndicationFilterResponse(int slotId,
537 int responseType, int serial, RIL_Errno e,
538 void *response, size_t responselen);
540 int setSimCardPowerResponse(int slotId,
541 int responseType, int serial, RIL_Errno e,
542 void *response, size_t responselen);
544 int startKeepaliveResponse(int slotId,
545 int responseType, int serial, RIL_Errno e,
546 void *response, size_t responselen);
548 int stopKeepaliveResponse(int slotId,
549 int responseType, int serial, RIL_Errno e,
550 void *response, size_t responselen);
552 void acknowledgeRequest(int slotId, int serial);
554 int radioStateChangedInd(int slotId,
555 int indicationType, int token, RIL_Errno e, void *response,
558 int callStateChangedInd(int slotId, int indType, int token,
559 RIL_Errno e, void *response, size_t responselen);
561 int networkStateChangedInd(int slotId, int indType,
562 int token, RIL_Errno e, void *response, size_t responselen);
564 int newSmsInd(int slotId, int indicationType,
565 int token, RIL_Errno e, void *response, size_t responselen);
567 int newSmsStatusReportInd(int slotId, int indicationType,
568 int token, RIL_Errno e, void *response, size_t responselen);
570 int newSmsOnSimInd(int slotId, int indicationType,
571 int token, RIL_Errno e, void *response, size_t responselen);
573 int onUssdInd(int slotId, int indicationType,
574 int token, RIL_Errno e, void *response, size_t responselen);
576 int nitzTimeReceivedInd(int slotId, int indicationType,
577 int token, RIL_Errno e, void *response, size_t responselen);
579 int currentSignalStrengthInd(int slotId,
580 int indicationType, int token, RIL_Errno e,
581 void *response, size_t responselen);
583 int dataCallListChangedInd(int slotId, int indicationType,
584 int token, RIL_Errno e, void *response, size_t responselen);
586 int suppSvcNotifyInd(int slotId, int indicationType,
587 int token, RIL_Errno e, void *response, size_t responselen);
589 int stkSessionEndInd(int slotId, int indicationType,
590 int token, RIL_Errno e, void *response, size_t responselen);
592 int stkProactiveCommandInd(int slotId, int indicationType,
593 int token, RIL_Errno e, void *response, size_t responselen);
595 int stkEventNotifyInd(int slotId, int indicationType,
596 int token, RIL_Errno e, void *response, size_t responselen);
598 int stkCallSetupInd(int slotId, int indicationType,
599 int token, RIL_Errno e, void *response, size_t responselen);
601 int simSmsStorageFullInd(int slotId, int indicationType,
602 int token, RIL_Errno e, void *response, size_t responselen);
604 int simRefreshInd(int slotId, int indicationType,
605 int token, RIL_Errno e, void *response, size_t responselen);
607 int callRingInd(int slotId, int indicationType,
608 int token, RIL_Errno e, void *response, size_t responselen);
610 int simStatusChangedInd(int slotId, int indicationType,
611 int token, RIL_Errno e, void *response, size_t responselen);
613 int cdmaNewSmsInd(int slotId, int indicationType,
614 int token, RIL_Errno e, void *response, size_t responselen);
616 int newBroadcastSmsInd(int slotId,
617 int indicationType, int token, RIL_Errno e, void *response,
620 int cdmaRuimSmsStorageFullInd(int slotId,
621 int indicationType, int token, RIL_Errno e, void *response,
624 int restrictedStateChangedInd(int slotId,
625 int indicationType, int token, RIL_Errno e, void *response,
628 int enterEmergencyCallbackModeInd(int slotId,
629 int indicationType, int token, RIL_Errno e, void *response,
632 int cdmaCallWaitingInd(int slotId,
633 int indicationType, int token, RIL_Errno e, void *response,
636 int cdmaOtaProvisionStatusInd(int slotId,
637 int indicationType, int token, RIL_Errno e, void *response,
640 int cdmaInfoRecInd(int slotId,
641 int indicationType, int token, RIL_Errno e, void *response,
644 int oemHookRawInd(int slotId,
645 int indicationType, int token, RIL_Errno e, void *response,
648 int indicateRingbackToneInd(int slotId,
649 int indicationType, int token, RIL_Errno e, void *response,
652 int resendIncallMuteInd(int slotId,
653 int indicationType, int token, RIL_Errno e, void *response,
656 int cdmaSubscriptionSourceChangedInd(int slotId,
657 int indicationType, int token, RIL_Errno e,
658 void *response, size_t responselen);
660 int cdmaPrlChangedInd(int slotId,
661 int indicationType, int token, RIL_Errno e, void *response,
664 int exitEmergencyCallbackModeInd(int slotId,
665 int indicationType, int token, RIL_Errno e, void *response,
668 int rilConnectedInd(int slotId,
669 int indicationType, int token, RIL_Errno e, void *response,
672 int voiceRadioTechChangedInd(int slotId,
673 int indicationType, int token, RIL_Errno e, void *response,
676 int cellInfoListInd(int slotId,
677 int indicationType, int token, RIL_Errno e, void *response,
680 int imsNetworkStateChangedInd(int slotId,
681 int indicationType, int token, RIL_Errno e, void *response,
684 int subscriptionStatusChangedInd(int slotId,
685 int indicationType, int token, RIL_Errno e, void *response,
688 int srvccStateNotifyInd(int slotId,
689 int indicationType, int token, RIL_Errno e, void *response,
692 int hardwareConfigChangedInd(int slotId,
693 int indicationType, int token, RIL_Errno e, void *response,
696 int radioCapabilityIndicationInd(int slotId,
697 int indicationType, int token, RIL_Errno e, void *response,
700 int onSupplementaryServiceIndicationInd(int slotId,
701 int indicationType, int token, RIL_Errno e,
702 void *response, size_t responselen);
704 int stkCallControlAlphaNotifyInd(int slotId,
705 int indicationType, int token, RIL_Errno e, void *response,
708 int lceDataInd(int slotId,
709 int indicationType, int token, RIL_Errno e, void *response,
712 int pcoDataInd(int slotId,
713 int indicationType, int token, RIL_Errno e, void *response,
716 int modemResetInd(int slotId,
717 int indicationType, int token, RIL_Errno e, void *response,
720 int networkScanResultInd(int slotId,
721 int indicationType, int token, RIL_Errno e, void *response,
724 int keepaliveStatusInd(int slotId,
725 int indicationType, int token, RIL_Errno e, void *response,
728 int sendRequestRawResponse(int slotId,
729 int responseType, int serial, RIL_Errno e,
730 void *response, size_t responseLen);
732 int sendRequestStringsResponse(int slotId,
733 int responseType, int serial, RIL_Errno e,
734 void *response, size_t responseLen);
736 int setCarrierInfoForImsiEncryptionResponse(int slotId,
737 int responseType, int serial, RIL_Errno e,
738 void *response, size_t responseLen);
740 int carrierInfoForImsiEncryption(int slotId,
741 int responseType, int serial, RIL_Errno e,
742 void *response, size_t responseLen);
744 pthread_rwlock_t * getRadioServiceRwlock(int slotId);
748 #endif // RIL_SERVICE_H