diff options
Diffstat (limited to 'libril/ril.cpp')
-rw-r--r-- | libril/ril.cpp | 190 |
1 files changed, 95 insertions, 95 deletions
diff --git a/libril/ril.cpp b/libril/ril.cpp index d1d5d3b..5fba532 100644 --- a/libril/ril.cpp +++ b/libril/ril.cpp @@ -92,11 +92,11 @@ namespace android { #define startRequest sprintf(printBuf, "(") #define closeRequest sprintf(printBuf, "%s)", printBuf) #define printRequest(token, req) \ - LOGD("[%04d]> %s %s", token, requestToString(req), printBuf) + ALOGD("[%04d]> %s %s", token, requestToString(req), printBuf) #define startResponse sprintf(printBuf, "%s {", printBuf) #define closeResponse sprintf(printBuf, "%s}", printBuf) - #define printResponse LOGD("%s", printBuf) + #define printResponse ALOGD("%s", printBuf) #define clearPrintBuf printBuf[0] = 0 #define removeLastChar printBuf[strlen(printBuf)-1] = 0 @@ -312,7 +312,7 @@ issueLocalRequest(int request, void *data, int len) { ret = pthread_mutex_unlock(&s_pendingRequestsMutex); assert (ret == 0); - LOGD("C[locl]> %s", requestToString(request)); + ALOGD("C[locl]> %s", requestToString(request)); s_callbacks.onRequest(request, data, len, pRI); } @@ -335,12 +335,12 @@ processCommandBuffer(void *buffer, size_t buflen) { status = p.readInt32 (&token); if (status != NO_ERROR) { - LOGE("invalid request block"); + ALOGE("invalid request block"); return 0; } if (request < 1 || request >= (int32_t)NUM_ELEMS(s_commands)) { - LOGE("unsupported request code %d token %d", request, token); + ALOGE("unsupported request code %d token %d", request, token); // FIXME this should perhaps return a response return 0; } @@ -369,7 +369,7 @@ processCommandBuffer(void *buffer, size_t buflen) { static void invalidCommandBlock (RequestInfo *pRI) { - LOGE("invalid command block for token %d request %s", + ALOGE("invalid command block for token %d request %s", pRI->token, requestToString(pRI->pCI->requestNumber)); } @@ -1236,7 +1236,7 @@ blockingWrite(int fd, const void *buffer, size_t len) { if (written >= 0) { writeOffset += written; } else { // written < 0 - LOGE ("RIL Response: unexpected error on write errno:%d", errno); + ALOGE ("RIL Response: unexpected error on write errno:%d", errno); close(fd); return -1; } @@ -1256,7 +1256,7 @@ sendResponseRaw (const void *data, size_t dataSize) { } if (dataSize > MAX_COMMAND_BYTES) { - LOGE("RIL: packet larger than %u (%u)", + ALOGE("RIL: packet larger than %u (%u)", MAX_COMMAND_BYTES, (unsigned int )dataSize); return -1; @@ -1298,11 +1298,11 @@ responseInts(Parcel &p, void *response, size_t responselen) { int numInts; if (response == NULL && responselen != 0) { - LOGE("invalid response: NULL"); + ALOGE("invalid response: NULL"); return RIL_ERRNO_INVALID_RESPONSE; } if (responselen % sizeof(int) != 0) { - LOGE("invalid response length %d expected multiple of %d\n", + ALOGE("invalid response length %d expected multiple of %d\n", (int)responselen, (int)sizeof(int)); return RIL_ERRNO_INVALID_RESPONSE; } @@ -1336,11 +1336,11 @@ static int responseStrings(Parcel &p, void *response, size_t responselen) { int numStrings; if (response == NULL && responselen != 0) { - LOGE("invalid response: NULL"); + ALOGE("invalid response: NULL"); return RIL_ERRNO_INVALID_RESPONSE; } if (responselen % sizeof(char *) != 0) { - LOGE("invalid response length %d expected multiple of %d\n", + ALOGE("invalid response length %d expected multiple of %d\n", (int)responselen, (int)sizeof(char *)); return RIL_ERRNO_INVALID_RESPONSE; } @@ -1391,12 +1391,12 @@ static int responseCallList(Parcel &p, void *response, size_t responselen) { int num; if (response == NULL && responselen != 0) { - LOGE("invalid response: NULL"); + ALOGE("invalid response: NULL"); return RIL_ERRNO_INVALID_RESPONSE; } if (responselen % sizeof (RIL_Call *) != 0) { - LOGE("invalid response length %d expected multiple of %d\n", + ALOGE("invalid response length %d expected multiple of %d\n", (int)responselen, (int)sizeof (RIL_Call *)); return RIL_ERRNO_INVALID_RESPONSE; } @@ -1459,12 +1459,12 @@ static int responseCallList(Parcel &p, void *response, size_t responselen) { static int responseSMS(Parcel &p, void *response, size_t responselen) { if (response == NULL) { - LOGE("invalid response: NULL"); + ALOGE("invalid response: NULL"); return RIL_ERRNO_INVALID_RESPONSE; } if (responselen != sizeof (RIL_SMS_Response) ) { - LOGE("invalid response length %d expected %d", + ALOGE("invalid response length %d expected %d", (int)responselen, (int)sizeof (RIL_SMS_Response)); return RIL_ERRNO_INVALID_RESPONSE; } @@ -1486,12 +1486,12 @@ static int responseSMS(Parcel &p, void *response, size_t responselen) { static int responseDataCallListV4(Parcel &p, void *response, size_t responselen) { if (response == NULL && responselen != 0) { - LOGE("invalid response: NULL"); + ALOGE("invalid response: NULL"); return RIL_ERRNO_INVALID_RESPONSE; } if (responselen % sizeof(RIL_Data_Call_Response_v4) != 0) { - LOGE("invalid response length %d expected multiple of %d", + ALOGE("invalid response length %d expected multiple of %d", (int)responselen, (int)sizeof(RIL_Data_Call_Response_v4)); return RIL_ERRNO_INVALID_RESPONSE; } @@ -1529,12 +1529,12 @@ static int responseDataCallList(Parcel &p, void *response, size_t responselen) return responseDataCallListV4(p, response, responselen); } else { if (response == NULL && responselen != 0) { - LOGE("invalid response: NULL"); + ALOGE("invalid response: NULL"); return RIL_ERRNO_INVALID_RESPONSE; } if (responselen % sizeof(RIL_Data_Call_Response_v6) != 0) { - LOGE("invalid response length %d expected multiple of %d", + ALOGE("invalid response length %d expected multiple of %d", (int)responselen, (int)sizeof(RIL_Data_Call_Response_v6)); return RIL_ERRNO_INVALID_RESPONSE; } @@ -1583,7 +1583,7 @@ static int responseSetupDataCall(Parcel &p, void *response, size_t responselen) static int responseRaw(Parcel &p, void *response, size_t responselen) { if (response == NULL && responselen != 0) { - LOGE("invalid response: NULL with responselen != 0"); + ALOGE("invalid response: NULL with responselen != 0"); return RIL_ERRNO_INVALID_RESPONSE; } @@ -1601,12 +1601,12 @@ static int responseRaw(Parcel &p, void *response, size_t responselen) { static int responseSIM_IO(Parcel &p, void *response, size_t responselen) { if (response == NULL) { - LOGE("invalid response: NULL"); + ALOGE("invalid response: NULL"); return RIL_ERRNO_INVALID_RESPONSE; } if (responselen != sizeof (RIL_SIM_IO_Response) ) { - LOGE("invalid response length was %d expected %d", + ALOGE("invalid response length was %d expected %d", (int)responselen, (int)sizeof (RIL_SIM_IO_Response)); return RIL_ERRNO_INVALID_RESPONSE; } @@ -1629,12 +1629,12 @@ static int responseCallForwards(Parcel &p, void *response, size_t responselen) { int num; if (response == NULL && responselen != 0) { - LOGE("invalid response: NULL"); + ALOGE("invalid response: NULL"); return RIL_ERRNO_INVALID_RESPONSE; } if (responselen % sizeof(RIL_CallForwardInfo *) != 0) { - LOGE("invalid response length %d expected multiple of %d", + ALOGE("invalid response length %d expected multiple of %d", (int)responselen, (int)sizeof(RIL_CallForwardInfo *)); return RIL_ERRNO_INVALID_RESPONSE; } @@ -1667,12 +1667,12 @@ static int responseCallForwards(Parcel &p, void *response, size_t responselen) { static int responseSsn(Parcel &p, void *response, size_t responselen) { if (response == NULL) { - LOGE("invalid response: NULL"); + ALOGE("invalid response: NULL"); return RIL_ERRNO_INVALID_RESPONSE; } if (responselen != sizeof(RIL_SuppSvcNotification)) { - LOGE("invalid response length was %d expected %d", + ALOGE("invalid response length was %d expected %d", (int)responselen, (int)sizeof (RIL_SuppSvcNotification)); return RIL_ERRNO_INVALID_RESPONSE; } @@ -1698,12 +1698,12 @@ static int responseCellList(Parcel &p, void *response, size_t responselen) { int num; if (response == NULL && responselen != 0) { - LOGE("invalid response: NULL"); + ALOGE("invalid response: NULL"); return RIL_ERRNO_INVALID_RESPONSE; } if (responselen % sizeof (RIL_NeighboringCell *) != 0) { - LOGE("invalid response length %d expected multiple of %d\n", + ALOGE("invalid response length %d expected multiple of %d\n", (int)responselen, (int)sizeof (RIL_NeighboringCell *)); return RIL_ERRNO_INVALID_RESPONSE; } @@ -1747,12 +1747,12 @@ static int responseCdmaInformationRecords(Parcel &p, RIL_CDMA_InformationRecord *infoRec; if (response == NULL && responselen != 0) { - LOGE("invalid response: NULL"); + ALOGE("invalid response: NULL"); return RIL_ERRNO_INVALID_RESPONSE; } if (responselen != sizeof (RIL_CDMA_InformationRecords)) { - LOGE("invalid response length %d expected multiple of %d\n", + ALOGE("invalid response length %d expected multiple of %d\n", (int)responselen, (int)sizeof (RIL_CDMA_InformationRecords *)); return RIL_ERRNO_INVALID_RESPONSE; } @@ -1772,7 +1772,7 @@ static int responseCdmaInformationRecords(Parcel &p, case RIL_CDMA_EXTENDED_DISPLAY_INFO_REC: if (infoRec->rec.display.alpha_len > CDMA_ALPHA_INFO_BUFFER_LENGTH) { - LOGE("invalid display info response length %d \ + ALOGE("invalid display info response length %d \ expected not more than %d\n", (int)infoRec->rec.display.alpha_len, CDMA_ALPHA_INFO_BUFFER_LENGTH); @@ -1792,7 +1792,7 @@ static int responseCdmaInformationRecords(Parcel &p, case RIL_CDMA_CALLING_PARTY_NUMBER_INFO_REC: case RIL_CDMA_CONNECTED_NUMBER_INFO_REC: if (infoRec->rec.number.len > CDMA_NUMBER_INFO_BUFFER_LENGTH) { - LOGE("invalid display info response length %d \ + ALOGE("invalid display info response length %d \ expected not more than %d\n", (int)infoRec->rec.number.len, CDMA_NUMBER_INFO_BUFFER_LENGTH); @@ -1829,7 +1829,7 @@ static int responseCdmaInformationRecords(Parcel &p, case RIL_CDMA_REDIRECTING_NUMBER_INFO_REC: if (infoRec->rec.redir.redirectingNumber.len > CDMA_NUMBER_INFO_BUFFER_LENGTH) { - LOGE("invalid display info response length %d \ + ALOGE("invalid display info response length %d \ expected not more than %d\n", (int)infoRec->rec.redir.redirectingNumber.len, CDMA_NUMBER_INFO_BUFFER_LENGTH); @@ -1884,10 +1884,10 @@ static int responseCdmaInformationRecords(Parcel &p, break; case RIL_CDMA_T53_RELEASE_INFO_REC: // TODO(Moto): See David Krause, he has the answer:) - LOGE("RIL_CDMA_T53_RELEASE_INFO_REC: return INVALID_RESPONSE"); + ALOGE("RIL_CDMA_T53_RELEASE_INFO_REC: return INVALID_RESPONSE"); return RIL_ERRNO_INVALID_RESPONSE; default: - LOGE("Incorrect name value"); + ALOGE("Incorrect name value"); return RIL_ERRNO_INVALID_RESPONSE; } } @@ -1899,7 +1899,7 @@ static int responseCdmaInformationRecords(Parcel &p, static int responseRilSignalStrength(Parcel &p, void *response, size_t responselen) { if (response == NULL && responselen != 0) { - LOGE("invalid response: NULL"); + ALOGE("invalid response: NULL"); return RIL_ERRNO_INVALID_RESPONSE; } @@ -1946,7 +1946,7 @@ static int responseRilSignalStrength(Parcel &p, closeResponse; } else { - LOGE("invalid response length"); + ALOGE("invalid response length"); return RIL_ERRNO_INVALID_RESPONSE; } @@ -1963,12 +1963,12 @@ static int responseCallRing(Parcel &p, void *response, size_t responselen) { static int responseCdmaSignalInfoRecord(Parcel &p, void *response, size_t responselen) { if (response == NULL || responselen == 0) { - LOGE("invalid response: NULL"); + ALOGE("invalid response: NULL"); return RIL_ERRNO_INVALID_RESPONSE; } if (responselen != sizeof (RIL_CDMA_SignalInfoRecord)) { - LOGE("invalid response length %d expected sizeof (RIL_CDMA_SignalInfoRecord) of %d\n", + ALOGE("invalid response length %d expected sizeof (RIL_CDMA_SignalInfoRecord) of %d\n", (int)responselen, (int)sizeof (RIL_CDMA_SignalInfoRecord)); return RIL_ERRNO_INVALID_RESPONSE; } @@ -1993,12 +1993,12 @@ static int responseCdmaSignalInfoRecord(Parcel &p, void *response, size_t respon static int responseCdmaCallWaiting(Parcel &p, void *response, size_t responselen) { if (response == NULL && responselen != 0) { - LOGE("invalid response: NULL"); + ALOGE("invalid response: NULL"); return RIL_ERRNO_INVALID_RESPONSE; } if (responselen < sizeof(RIL_CDMA_CallWaiting_v6)) { - LOGW("Upgrade to ril version %d\n", RIL_VERSION); + ALOGW("Upgrade to ril version %d\n", RIL_VERSION); } RIL_CDMA_CallWaiting_v6 *p_cur = ((RIL_CDMA_CallWaiting_v6 *) response); @@ -2083,7 +2083,7 @@ static int responseSimStatus(Parcel &p, void *response, size_t responselen) { int i; if (response == NULL && responselen != 0) { - LOGE("invalid response: NULL"); + ALOGE("invalid response: NULL"); return RIL_ERRNO_INVALID_RESPONSE; } @@ -2108,7 +2108,7 @@ static int responseSimStatus(Parcel &p, void *response, size_t responselen) { sendSimStatusAppInfo(p, p_cur->num_applications, p_cur->applications); } else { - LOGE("responseSimStatus: A RilCardStatus_v6 or _v5 expected\n"); + ALOGE("responseSimStatus: A RilCardStatus_v6 or _v5 expected\n"); return RIL_ERRNO_INVALID_RESPONSE; } @@ -2170,15 +2170,15 @@ static int responseCdmaSms(Parcel &p, void *response, size_t responselen) { uint8_t uct; void* dest; - LOGD("Inside responseCdmaSms"); + ALOGD("Inside responseCdmaSms"); if (response == NULL && responselen != 0) { - LOGE("invalid response: NULL"); + ALOGE("invalid response: NULL"); return RIL_ERRNO_INVALID_RESPONSE; } if (responselen != sizeof(RIL_CDMA_SMS_Message)) { - LOGE("invalid response length was %d expected %d", + ALOGE("invalid response length was %d expected %d", (int)responselen, (int)sizeof(RIL_CDMA_SMS_Message)); return RIL_ERRNO_INVALID_RESPONSE; } @@ -2230,7 +2230,7 @@ static void processWakeupCallback(int fd, short flags, void *param) { char buff[16]; int ret; - LOGV("processWakeupCallback"); + ALOGV("processWakeupCallback"); /* empty our wakeup socket out */ do { @@ -2287,9 +2287,9 @@ static void processCommandsCallback(int fd, short flags, void *param) { if (ret == 0 || !(errno == EAGAIN || errno == EINTR)) { /* fatal error or end-of-stream */ if (ret != 0) { - LOGE("error on reading command socket errno:%d\n", errno); + ALOGE("error on reading command socket errno:%d\n", errno); } else { - LOGW("EOS. Closing command socket."); + ALOGW("EOS. Closing command socket."); } close(s_fdCommand); @@ -2329,11 +2329,11 @@ static void onNewCommandConnect() { if (s_callbacks.getVersion != NULL) { const char *version; version = s_callbacks.getVersion(); - LOGI("RIL Daemon version: %s\n", version); + ALOGI("RIL Daemon version: %s\n", version); property_set(PROPERTY_RIL_IMPL, version); } else { - LOGI("RIL Daemon version: unavailable\n"); + ALOGI("RIL Daemon version: unavailable\n"); property_set(PROPERTY_RIL_IMPL, "unavailable"); } @@ -2359,7 +2359,7 @@ static void listenCallback (int fd, short flags, void *param) { s_fdCommand = accept(s_fdListen, (sockaddr *) &peeraddr, &socklen); if (s_fdCommand < 0 ) { - LOGE("Error on accept() errno:%d", errno); + ALOGE("Error on accept() errno:%d", errno); /* start listening for new connections again */ rilEventAddWakeup(&s_listen_event); return; @@ -2380,17 +2380,17 @@ static void listenCallback (int fd, short flags, void *param) { if (strcmp(pwd->pw_name, PHONE_PROCESS) == 0) { is_phone_socket = 1; } else { - LOGE("RILD can't accept socket from process %s", pwd->pw_name); + ALOGE("RILD can't accept socket from process %s", pwd->pw_name); } } else { - LOGE("Error on getpwuid() errno: %d", errno); + ALOGE("Error on getpwuid() errno: %d", errno); } } else { - LOGD("Error on getsockopt() errno: %d", errno); + ALOGD("Error on getsockopt() errno: %d", errno); } if ( !is_phone_socket ) { - LOGE("RILD must accept socket from %s", PHONE_PROCESS); + ALOGE("RILD must accept socket from %s", PHONE_PROCESS); close(s_fdCommand); s_fdCommand = -1; @@ -2406,10 +2406,10 @@ static void listenCallback (int fd, short flags, void *param) { ret = fcntl(s_fdCommand, F_SETFL, O_NONBLOCK); if (ret < 0) { - LOGE ("Error setting O_NONBLOCK errno:%d", errno); + ALOGE ("Error setting O_NONBLOCK errno:%d", errno); } - LOGI("libril: new connection"); + ALOGI("libril: new connection"); p_rs = record_stream_new(s_fdCommand, MAX_COMMAND_BYTES); @@ -2446,12 +2446,12 @@ static void debugCallback (int fd, short flags, void *param) { acceptFD = accept (fd, (sockaddr *) &peeraddr, &socklen); if (acceptFD < 0) { - LOGE ("error accepting on debug port: %d\n", errno); + ALOGE ("error accepting on debug port: %d\n", errno); return; } if (recv(acceptFD, &number, sizeof(int), 0) != sizeof(int)) { - LOGE ("error reading on socket: number of Args: \n"); + ALOGE ("error reading on socket: number of Args: \n"); return; } args = (char **) malloc(sizeof(char*) * number); @@ -2459,7 +2459,7 @@ static void debugCallback (int fd, short flags, void *param) { for (int i = 0; i < number; i++) { int len; if (recv(acceptFD, &len, sizeof(int), 0) != sizeof(int)) { - LOGE ("error reading on socket: Len of Args: \n"); + ALOGE ("error reading on socket: Len of Args: \n"); freeDebugCallbackArgs(i, args); return; } @@ -2467,7 +2467,7 @@ static void debugCallback (int fd, short flags, void *param) { args[i] = (char *) malloc((sizeof(char) * len) + 1); if (recv(acceptFD, args[i], sizeof(char) * len, 0) != (int)sizeof(char) * len) { - LOGE ("error reading on socket: Args[%d] \n", i); + ALOGE ("error reading on socket: Args[%d] \n", i); freeDebugCallbackArgs(i, args); return; } @@ -2477,11 +2477,11 @@ static void debugCallback (int fd, short flags, void *param) { switch (atoi(args[0])) { case 0: - LOGI ("Connection on debug port: issuing reset."); + ALOGI ("Connection on debug port: issuing reset."); issueLocalRequest(RIL_REQUEST_RESET_RADIO, NULL, 0); break; case 1: - LOGI ("Connection on debug port: issuing radio power off."); + ALOGI ("Connection on debug port: issuing radio power off."); data = 0; issueLocalRequest(RIL_REQUEST_RADIO_POWER, &data, sizeof(int)); // Close the socket @@ -2489,12 +2489,12 @@ static void debugCallback (int fd, short flags, void *param) { s_fdCommand = -1; break; case 2: - LOGI ("Debug port: issuing unsolicited voice network change."); + ALOGI ("Debug port: issuing unsolicited voice network change."); RIL_onUnsolicitedResponse(RIL_UNSOL_RESPONSE_VOICE_NETWORK_STATE_CHANGED, NULL, 0); break; case 3: - LOGI ("Debug port: QXDM log enable."); + ALOGI ("Debug port: QXDM log enable."); qxdm_data[0] = 65536; // head.func_tag qxdm_data[1] = 16; // head.len qxdm_data[2] = 1; // mode: 1 for 'start logging' @@ -2505,7 +2505,7 @@ static void debugCallback (int fd, short flags, void *param) { 6 * sizeof(int)); break; case 4: - LOGI ("Debug port: QXDM log disable."); + ALOGI ("Debug port: QXDM log disable."); qxdm_data[0] = 65536; qxdm_data[1] = 16; qxdm_data[2] = 0; // mode: 0 for 'stop logging' @@ -2516,7 +2516,7 @@ static void debugCallback (int fd, short flags, void *param) { 6 * sizeof(int)); break; case 5: - LOGI("Debug port: Radio On"); + ALOGI("Debug port: Radio On"); data = 1; issueLocalRequest(RIL_REQUEST_RADIO_POWER, &data, sizeof(int)); sleep(2); @@ -2524,33 +2524,33 @@ static void debugCallback (int fd, short flags, void *param) { issueLocalRequest(RIL_REQUEST_SET_NETWORK_SELECTION_AUTOMATIC, NULL, 0); break; case 6: - LOGI("Debug port: Setup Data Call, Apn :%s\n", args[1]); + ALOGI("Debug port: Setup Data Call, Apn :%s\n", args[1]); actData[0] = args[1]; issueLocalRequest(RIL_REQUEST_SETUP_DATA_CALL, &actData, sizeof(actData)); break; case 7: - LOGI("Debug port: Deactivate Data Call"); + ALOGI("Debug port: Deactivate Data Call"); issueLocalRequest(RIL_REQUEST_DEACTIVATE_DATA_CALL, &deactData, sizeof(deactData)); break; case 8: - LOGI("Debug port: Dial Call"); + ALOGI("Debug port: Dial Call"); dialData.clir = 0; dialData.address = args[1]; issueLocalRequest(RIL_REQUEST_DIAL, &dialData, sizeof(dialData)); break; case 9: - LOGI("Debug port: Answer Call"); + ALOGI("Debug port: Answer Call"); issueLocalRequest(RIL_REQUEST_ANSWER, NULL, 0); break; case 10: - LOGI("Debug port: End Call"); + ALOGI("Debug port: End Call"); issueLocalRequest(RIL_REQUEST_HANGUP, &hangupData, sizeof(hangupData)); break; default: - LOGE ("Invalid request"); + ALOGE ("Invalid request"); break; } freeDebugCallbackArgs(number, args); @@ -2592,7 +2592,7 @@ eventLoop(void *param) { ret = pipe(filedes); if (ret < 0) { - LOGE("Error in pipe() errno:%d", errno); + ALOGE("Error in pipe() errno:%d", errno); return NULL; } @@ -2608,7 +2608,7 @@ eventLoop(void *param) { // Only returns on error ril_event_loop(); - LOGE ("error in event_loop_base errno:%d", errno); + ALOGE ("error in event_loop_base errno:%d", errno); // kill self to restart on error kill(0, SIGKILL); @@ -2635,7 +2635,7 @@ RIL_startEventLoop(void) { pthread_mutex_unlock(&s_startupMutex); if (ret < 0) { - LOGE("Failed to create dispatch thread errno:%d", errno); + ALOGE("Failed to create dispatch thread errno:%d", errno); return; } } @@ -2651,23 +2651,23 @@ RIL_register (const RIL_RadioFunctions *callbacks) { int flags; if (callbacks == NULL) { - LOGE("RIL_register: RIL_RadioFunctions * null"); + ALOGE("RIL_register: RIL_RadioFunctions * null"); return; } if (callbacks->version < RIL_VERSION_MIN) { - LOGE("RIL_register: version %d is to old, min version is %d", + ALOGE("RIL_register: version %d is to old, min version is %d", callbacks->version, RIL_VERSION_MIN); return; } if (callbacks->version > RIL_VERSION) { - LOGE("RIL_register: version %d is too new, max version is %d", + ALOGE("RIL_register: version %d is too new, max version is %d", callbacks->version, RIL_VERSION); return; } - LOGE("RIL_register: RIL version %d", callbacks->version); + ALOGE("RIL_register: RIL version %d", callbacks->version); if (s_registerCalled > 0) { - LOGE("RIL_register has been called more than once. " + ALOGE("RIL_register has been called more than once. " "Subsequent call ignored"); return; } @@ -2701,7 +2701,7 @@ RIL_register (const RIL_RadioFunctions *callbacks) { ANDROID_SOCKET_NAMESPACE_ABSTRACT, SOCK_STREAM); if (ret < 0) { - LOGE("Unable to bind socket errno:%d", errno); + ALOGE("Unable to bind socket errno:%d", errno); exit (-1); } s_fdListen = ret; @@ -2709,14 +2709,14 @@ RIL_register (const RIL_RadioFunctions *callbacks) { #else s_fdListen = android_get_control_socket(SOCKET_NAME_RIL); if (s_fdListen < 0) { - LOGE("Failed to get socket '" SOCKET_NAME_RIL "'"); + ALOGE("Failed to get socket '" SOCKET_NAME_RIL "'"); exit(-1); } ret = listen(s_fdListen, 4); if (ret < 0) { - LOGE("Failed to listen on control socket '%d': %s", + ALOGE("Failed to listen on control socket '%d': %s", s_fdListen, strerror(errno)); exit(-1); } @@ -2734,14 +2734,14 @@ RIL_register (const RIL_RadioFunctions *callbacks) { s_fdDebug = android_get_control_socket(SOCKET_NAME_RIL_DEBUG); if (s_fdDebug < 0) { - LOGE("Failed to get socket '" SOCKET_NAME_RIL_DEBUG "' errno:%d", errno); + ALOGE("Failed to get socket '" SOCKET_NAME_RIL_DEBUG "' errno:%d", errno); exit(-1); } ret = listen(s_fdDebug, 4); if (ret < 0) { - LOGE("Failed to listen on ril debug socket '%d': %s", + ALOGE("Failed to listen on ril debug socket '%d': %s", s_fdDebug, strerror(errno)); exit(-1); } @@ -2791,14 +2791,14 @@ RIL_onRequestComplete(RIL_Token t, RIL_Errno e, void *response, size_t responsel pRI = (RequestInfo *)t; if (!checkAndDequeueRequestInfo(pRI)) { - LOGE ("RIL_onRequestComplete: invalid RIL_Token"); + ALOGE ("RIL_onRequestComplete: invalid RIL_Token"); return; } if (pRI->local > 0) { // Locally issued command...void only! // response does not go back up the command socket - LOGD("C[locl]< %s", requestToString(pRI->pCI->requestNumber)); + ALOGD("C[locl]< %s", requestToString(pRI->pCI->requestNumber)); goto done; } @@ -2831,7 +2831,7 @@ RIL_onRequestComplete(RIL_Token t, RIL_Errno e, void *response, size_t responsel } if (s_fdCommand < 0) { - LOGD ("RIL onRequestComplete: Command channel closed"); + ALOGD ("RIL onRequestComplete: Command channel closed"); } sendResponse(p); } @@ -2858,11 +2858,11 @@ static void wakeTimeoutCallback (void *param) { // We're using "param != NULL" as a cancellation mechanism if (param == NULL) { - //LOGD("wakeTimeout: releasing wake lock"); + //ALOGD("wakeTimeout: releasing wake lock"); releaseWakeLock(); } else { - //LOGD("wakeTimeout: releasing wake lock CANCELLED"); + //ALOGD("wakeTimeout: releasing wake lock CANCELLED"); } } @@ -2877,7 +2877,7 @@ void RIL_onUnsolicitedResponse(int unsolResponse, void *data, if (s_registerCalled == 0) { // Ignore RIL_onUnsolicitedResponse before RIL_register - LOGW("RIL_onUnsolicitedResponse called before RIL_register"); + ALOGW("RIL_onUnsolicitedResponse called before RIL_register"); return; } @@ -2885,7 +2885,7 @@ void RIL_onUnsolicitedResponse(int unsolResponse, void *data, if ((unsolResponseIndex < 0) || (unsolResponseIndex >= (int32_t)NUM_ELEMS(s_unsolResponses))) { - LOGE("unsupported unsolicited response code %d", unsolResponse); + ALOGE("unsupported unsolicited response code %d", unsolResponse); return; } |