mirror of
https://github.com/S3NEO/android_device_samsung_msm8226-common.git
synced 2024-11-06 21:55:45 +00:00
update for oreo stable mr1
This commit is contained in:
parent
e3deb6ad34
commit
22b0dffa0d
10 changed files with 7757 additions and 397 deletions
|
@ -1,3 +1,3 @@
|
||||||
# Radio
|
# Radio
|
||||||
BOARD_PROVIDES_LIBRIL := false
|
BOARD_PROVIDES_LIBRIL := true
|
||||||
TARGET_RIL_VARIANT := caf
|
TARGET_RIL_VARIANT := caf
|
||||||
|
|
7359
include/telephony/ril.h
Normal file
7359
include/telephony/ril.h
Normal file
File diff suppressed because it is too large
Load diff
|
@ -47,7 +47,7 @@ void RilSapSocket::sOnRequestComplete (RIL_Token t,
|
||||||
RilSapSocket *sap_socket;
|
RilSapSocket *sap_socket;
|
||||||
SapSocketRequest *request = (SapSocketRequest*) t;
|
SapSocketRequest *request = (SapSocketRequest*) t;
|
||||||
|
|
||||||
RLOGE("Socket id:%d", request->socketId);
|
RLOGD("Socket id:%d", request->socketId);
|
||||||
|
|
||||||
sap_socket = getSocketById(request->socketId);
|
sap_socket = getSocketById(request->socketId);
|
||||||
|
|
||||||
|
@ -86,10 +86,10 @@ void RilSapSocket::sOnUnsolicitedResponse(int unsolResponse,
|
||||||
|
|
||||||
void RilSapSocket::printList() {
|
void RilSapSocket::printList() {
|
||||||
RilSapSocketList *current = head;
|
RilSapSocketList *current = head;
|
||||||
RLOGE("Printing socket list");
|
RLOGD("Printing socket list");
|
||||||
while(NULL != current) {
|
while(NULL != current) {
|
||||||
RLOGE("SocketName:%s",current->socket->name);
|
RLOGD("SocketName:%s",current->socket->name);
|
||||||
RLOGE("Socket id:%d",current->socket->id);
|
RLOGD("Socket id:%d",current->socket->id);
|
||||||
current = current->next;
|
current = current->next;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -98,7 +98,7 @@ RilSapSocket *RilSapSocket::getSocketById(RIL_SOCKET_ID socketId) {
|
||||||
RilSapSocket *sap_socket;
|
RilSapSocket *sap_socket;
|
||||||
RilSapSocketList *current = head;
|
RilSapSocketList *current = head;
|
||||||
|
|
||||||
RLOGE("Entered getSocketById");
|
RLOGD("Entered getSocketById");
|
||||||
printList();
|
printList();
|
||||||
|
|
||||||
while(NULL != current) {
|
while(NULL != current) {
|
||||||
|
@ -161,7 +161,7 @@ void RilSapSocket::addSocketToList(const char *socketName, RIL_SOCKET_ID socketi
|
||||||
listItem->socket = socket;
|
listItem->socket = socket;
|
||||||
listItem->next = NULL;
|
listItem->next = NULL;
|
||||||
|
|
||||||
RLOGE("Adding socket with id: %d", socket->id);
|
RLOGD("Adding socket with id: %d", socket->id);
|
||||||
|
|
||||||
if(NULL == head) {
|
if(NULL == head) {
|
||||||
head = listItem;
|
head = listItem;
|
||||||
|
|
|
@ -535,7 +535,7 @@ checkAndDequeueRequestInfoIfAck(struct RequestInfo *pRI, bool isAck) {
|
||||||
ret = 1;
|
ret = 1;
|
||||||
if (isAck) { // Async ack
|
if (isAck) { // Async ack
|
||||||
if (pRI->wasAckSent == 1) {
|
if (pRI->wasAckSent == 1) {
|
||||||
RLOGE("Ack was already sent for %s", requestToString(pRI->pCI->requestNumber));
|
RLOGD("Ack was already sent for %s", requestToString(pRI->pCI->requestNumber));
|
||||||
} else {
|
} else {
|
||||||
pRI->wasAckSent = 1;
|
pRI->wasAckSent = 1;
|
||||||
}
|
}
|
||||||
|
@ -567,7 +567,7 @@ RIL_onRequestAck(RIL_Token t) {
|
||||||
socket_id = pRI->socket_id;
|
socket_id = pRI->socket_id;
|
||||||
|
|
||||||
#if VDBG
|
#if VDBG
|
||||||
RLOGE("Request Ack, %s", rilSocketIdToString(socket_id));
|
RLOGD("Request Ack, %s", rilSocketIdToString(socket_id));
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
appendPrintBuf("Ack [%04d]< %s", pRI->token, requestToString(pRI->pCI->requestNumber));
|
appendPrintBuf("Ack [%04d]< %s", pRI->token, requestToString(pRI->pCI->requestNumber));
|
||||||
|
@ -599,13 +599,13 @@ RIL_onRequestComplete(RIL_Token t, RIL_Errno e, void *response, size_t responsel
|
||||||
|
|
||||||
socket_id = pRI->socket_id;
|
socket_id = pRI->socket_id;
|
||||||
#if VDBG
|
#if VDBG
|
||||||
RLOGE("RequestComplete, %s", rilSocketIdToString(socket_id));
|
RLOGD("RequestComplete, %s", rilSocketIdToString(socket_id));
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
if (pRI->local > 0) {
|
if (pRI->local > 0) {
|
||||||
// Locally issued command...void only!
|
// Locally issued command...void only!
|
||||||
// response does not go back up the command socket
|
// response does not go back up the command socket
|
||||||
RLOGE("C[locl]< %s", requestToString(pRI->pCI->requestNumber));
|
RLOGD("C[locl]< %s", requestToString(pRI->pCI->requestNumber));
|
||||||
|
|
||||||
free(pRI);
|
free(pRI);
|
||||||
return;
|
return;
|
||||||
|
|
|
@ -72,10 +72,10 @@ static struct ril_event * watch_table[MAX_FD_EVENTS];
|
||||||
static struct ril_event timer_list;
|
static struct ril_event timer_list;
|
||||||
static struct ril_event pending_list;
|
static struct ril_event pending_list;
|
||||||
|
|
||||||
#define DEBUG 1
|
#define DEBUG 0
|
||||||
|
|
||||||
#if DEBUG
|
#if DEBUG
|
||||||
#define dlog(x...) RLOGE( x )
|
#define dlog(x...) RLOGD( x )
|
||||||
static void dump_event(struct ril_event * ev)
|
static void dump_event(struct ril_event * ev)
|
||||||
{
|
{
|
||||||
dlog("~~~~ Event %x ~~~~", (unsigned int)ev);
|
dlog("~~~~ Event %x ~~~~", (unsigned int)ev);
|
||||||
|
|
|
@ -33,7 +33,7 @@ namespace android {
|
||||||
#define RESPONSE_UNSOLICITED_ACK_EXP 4
|
#define RESPONSE_UNSOLICITED_ACK_EXP 4
|
||||||
|
|
||||||
// Enable verbose logging
|
// Enable verbose logging
|
||||||
#define VDBG 1
|
#define VDBG 0
|
||||||
|
|
||||||
#define MIN(a,b) ((a)<(b) ? (a) : (b))
|
#define MIN(a,b) ((a)<(b) ? (a) : (b))
|
||||||
|
|
||||||
|
|
File diff suppressed because it is too large
Load diff
|
@ -86,7 +86,7 @@ void SapImpl::checkReturnStatus(Return<void>& ret) {
|
||||||
}
|
}
|
||||||
|
|
||||||
Return<void> SapImpl::setCallback(const ::android::sp<ISapCallback>& sapCallbackParam) {
|
Return<void> SapImpl::setCallback(const ::android::sp<ISapCallback>& sapCallbackParam) {
|
||||||
RLOGE("SapImpl::setCallback for slotId %d", slotId);
|
RLOGD("SapImpl::setCallback for slotId %d", slotId);
|
||||||
sapCallback = sapCallbackParam;
|
sapCallback = sapCallbackParam;
|
||||||
return Void();
|
return Void();
|
||||||
}
|
}
|
||||||
|
@ -117,7 +117,7 @@ Return<void> SapImpl::addPayloadAndDispatchRequest(MsgHeader *msg, uint16_t reqL
|
||||||
|
|
||||||
RilSapSocket *sapSocket = RilSapSocket::getSocketById(rilSocketId);
|
RilSapSocket *sapSocket = RilSapSocket::getSocketById(rilSocketId);
|
||||||
if (sapSocket) {
|
if (sapSocket) {
|
||||||
RLOGE("SapImpl::addPayloadAndDispatchRequest: calling dispatchRequest");
|
RLOGD("SapImpl::addPayloadAndDispatchRequest: calling dispatchRequest");
|
||||||
sapSocket->dispatchRequest(msg);
|
sapSocket->dispatchRequest(msg);
|
||||||
} else {
|
} else {
|
||||||
RLOGE("SapImpl::addPayloadAndDispatchRequest: sapSocket is null");
|
RLOGE("SapImpl::addPayloadAndDispatchRequest: sapSocket is null");
|
||||||
|
@ -184,7 +184,7 @@ void SapImpl::sendFailedResponse(MsgId msgId, int32_t token, int numPointers, ..
|
||||||
}
|
}
|
||||||
|
|
||||||
Return<void> SapImpl::connectReq(int32_t token, int32_t maxMsgSize) {
|
Return<void> SapImpl::connectReq(int32_t token, int32_t maxMsgSize) {
|
||||||
RLOGE("SapImpl::connectReq");
|
RLOGD("SapImpl::connectReq");
|
||||||
MsgHeader *msg = createMsgHeader(MsgId_RIL_SIM_SAP_CONNECT, token);
|
MsgHeader *msg = createMsgHeader(MsgId_RIL_SIM_SAP_CONNECT, token);
|
||||||
if (msg == NULL) {
|
if (msg == NULL) {
|
||||||
RLOGE("SapImpl::connectReq: Error allocating memory for msg");
|
RLOGE("SapImpl::connectReq: Error allocating memory for msg");
|
||||||
|
@ -212,7 +212,7 @@ Return<void> SapImpl::connectReq(int32_t token, int32_t maxMsgSize) {
|
||||||
}
|
}
|
||||||
pb_ostream_t stream = pb_ostream_from_buffer(buffer, encodedSize);
|
pb_ostream_t stream = pb_ostream_from_buffer(buffer, encodedSize);
|
||||||
|
|
||||||
RLOGE("SapImpl::connectReq calling pb_encode");
|
RLOGD("SapImpl::connectReq calling pb_encode");
|
||||||
if (!pb_encode(&stream, RIL_SIM_SAP_CONNECT_REQ_fields, &req)) {
|
if (!pb_encode(&stream, RIL_SIM_SAP_CONNECT_REQ_fields, &req)) {
|
||||||
RLOGE("SapImpl::connectReq: Error encoding RIL_SIM_SAP_CONNECT_REQ");
|
RLOGE("SapImpl::connectReq: Error encoding RIL_SIM_SAP_CONNECT_REQ");
|
||||||
sendFailedResponse(MsgId_RIL_SIM_SAP_CONNECT, token, 2, buffer, msg);
|
sendFailedResponse(MsgId_RIL_SIM_SAP_CONNECT, token, 2, buffer, msg);
|
||||||
|
@ -225,7 +225,7 @@ Return<void> SapImpl::connectReq(int32_t token, int32_t maxMsgSize) {
|
||||||
}
|
}
|
||||||
|
|
||||||
Return<void> SapImpl::disconnectReq(int32_t token) {
|
Return<void> SapImpl::disconnectReq(int32_t token) {
|
||||||
RLOGE("SapImpl::disconnectReq");
|
RLOGD("SapImpl::disconnectReq");
|
||||||
MsgHeader *msg = createMsgHeader(MsgId_RIL_SIM_SAP_DISCONNECT, token);
|
MsgHeader *msg = createMsgHeader(MsgId_RIL_SIM_SAP_DISCONNECT, token);
|
||||||
if (msg == NULL) {
|
if (msg == NULL) {
|
||||||
RLOGE("SapImpl::disconnectReq: Error allocating memory for msg");
|
RLOGE("SapImpl::disconnectReq: Error allocating memory for msg");
|
||||||
|
@ -253,7 +253,7 @@ Return<void> SapImpl::disconnectReq(int32_t token) {
|
||||||
|
|
||||||
pb_ostream_t stream = pb_ostream_from_buffer(buffer, encodedSize);
|
pb_ostream_t stream = pb_ostream_from_buffer(buffer, encodedSize);
|
||||||
|
|
||||||
RLOGE("SapImpl::disconnectReq calling pb_encode");
|
RLOGD("SapImpl::disconnectReq calling pb_encode");
|
||||||
if (!pb_encode(&stream, RIL_SIM_SAP_DISCONNECT_REQ_fields, &req)) {
|
if (!pb_encode(&stream, RIL_SIM_SAP_DISCONNECT_REQ_fields, &req)) {
|
||||||
RLOGE("SapImpl::disconnectReq: Error encoding RIL_SIM_SAP_DISCONNECT_REQ");
|
RLOGE("SapImpl::disconnectReq: Error encoding RIL_SIM_SAP_DISCONNECT_REQ");
|
||||||
sendFailedResponse(MsgId_RIL_SIM_SAP_DISCONNECT, token, 2, buffer, msg);
|
sendFailedResponse(MsgId_RIL_SIM_SAP_DISCONNECT, token, 2, buffer, msg);
|
||||||
|
@ -266,7 +266,7 @@ Return<void> SapImpl::disconnectReq(int32_t token) {
|
||||||
}
|
}
|
||||||
|
|
||||||
Return<void> SapImpl::apduReq(int32_t token, SapApduType type, const hidl_vec<uint8_t>& command) {
|
Return<void> SapImpl::apduReq(int32_t token, SapApduType type, const hidl_vec<uint8_t>& command) {
|
||||||
RLOGE("SapImpl::apduReq");
|
RLOGD("SapImpl::apduReq");
|
||||||
MsgHeader *msg = createMsgHeader(MsgId_RIL_SIM_SAP_APDU, token);
|
MsgHeader *msg = createMsgHeader(MsgId_RIL_SIM_SAP_APDU, token);
|
||||||
if (msg == NULL) {
|
if (msg == NULL) {
|
||||||
RLOGE("SapImpl::apduReq: Error allocating memory for msg");
|
RLOGE("SapImpl::apduReq: Error allocating memory for msg");
|
||||||
|
@ -306,7 +306,7 @@ Return<void> SapImpl::apduReq(int32_t token, SapApduType type, const hidl_vec<ui
|
||||||
|
|
||||||
pb_ostream_t stream = pb_ostream_from_buffer(buffer, encodedSize);
|
pb_ostream_t stream = pb_ostream_from_buffer(buffer, encodedSize);
|
||||||
|
|
||||||
RLOGE("SapImpl::apduReq calling pb_encode");
|
RLOGD("SapImpl::apduReq calling pb_encode");
|
||||||
if (!pb_encode(&stream, RIL_SIM_SAP_APDU_REQ_fields, &req)) {
|
if (!pb_encode(&stream, RIL_SIM_SAP_APDU_REQ_fields, &req)) {
|
||||||
RLOGE("SapImpl::apduReq: Error encoding RIL_SIM_SAP_APDU_REQ");
|
RLOGE("SapImpl::apduReq: Error encoding RIL_SIM_SAP_APDU_REQ");
|
||||||
sendFailedResponse(MsgId_RIL_SIM_SAP_APDU, token, 3, req.command, buffer, msg);
|
sendFailedResponse(MsgId_RIL_SIM_SAP_APDU, token, 3, req.command, buffer, msg);
|
||||||
|
@ -319,7 +319,7 @@ Return<void> SapImpl::apduReq(int32_t token, SapApduType type, const hidl_vec<ui
|
||||||
}
|
}
|
||||||
|
|
||||||
Return<void> SapImpl::transferAtrReq(int32_t token) {
|
Return<void> SapImpl::transferAtrReq(int32_t token) {
|
||||||
RLOGE("SapImpl::transferAtrReq");
|
RLOGD("SapImpl::transferAtrReq");
|
||||||
MsgHeader *msg = createMsgHeader(MsgId_RIL_SIM_SAP_TRANSFER_ATR, token);
|
MsgHeader *msg = createMsgHeader(MsgId_RIL_SIM_SAP_TRANSFER_ATR, token);
|
||||||
if (msg == NULL) {
|
if (msg == NULL) {
|
||||||
RLOGE("SapImpl::transferAtrReq: Error allocating memory for msg");
|
RLOGE("SapImpl::transferAtrReq: Error allocating memory for msg");
|
||||||
|
@ -348,7 +348,7 @@ Return<void> SapImpl::transferAtrReq(int32_t token) {
|
||||||
|
|
||||||
pb_ostream_t stream = pb_ostream_from_buffer(buffer, encodedSize);
|
pb_ostream_t stream = pb_ostream_from_buffer(buffer, encodedSize);
|
||||||
|
|
||||||
RLOGE("SapImpl::transferAtrReq calling pb_encode");
|
RLOGD("SapImpl::transferAtrReq calling pb_encode");
|
||||||
if (!pb_encode(&stream, RIL_SIM_SAP_TRANSFER_ATR_REQ_fields, &req)) {
|
if (!pb_encode(&stream, RIL_SIM_SAP_TRANSFER_ATR_REQ_fields, &req)) {
|
||||||
RLOGE("SapImpl::transferAtrReq: Error encoding RIL_SIM_SAP_TRANSFER_ATR_REQ");
|
RLOGE("SapImpl::transferAtrReq: Error encoding RIL_SIM_SAP_TRANSFER_ATR_REQ");
|
||||||
sendFailedResponse(MsgId_RIL_SIM_SAP_TRANSFER_ATR, token, 2, buffer, msg);
|
sendFailedResponse(MsgId_RIL_SIM_SAP_TRANSFER_ATR, token, 2, buffer, msg);
|
||||||
|
@ -361,7 +361,7 @@ Return<void> SapImpl::transferAtrReq(int32_t token) {
|
||||||
}
|
}
|
||||||
|
|
||||||
Return<void> SapImpl::powerReq(int32_t token, bool state) {
|
Return<void> SapImpl::powerReq(int32_t token, bool state) {
|
||||||
RLOGE("SapImpl::powerReq");
|
RLOGD("SapImpl::powerReq");
|
||||||
MsgHeader *msg = createMsgHeader(MsgId_RIL_SIM_SAP_POWER, token);
|
MsgHeader *msg = createMsgHeader(MsgId_RIL_SIM_SAP_POWER, token);
|
||||||
if (msg == NULL) {
|
if (msg == NULL) {
|
||||||
RLOGE("SapImpl::powerReq: Error allocating memory for msg");
|
RLOGE("SapImpl::powerReq: Error allocating memory for msg");
|
||||||
|
@ -390,7 +390,7 @@ Return<void> SapImpl::powerReq(int32_t token, bool state) {
|
||||||
|
|
||||||
pb_ostream_t stream = pb_ostream_from_buffer(buffer, encodedSize);
|
pb_ostream_t stream = pb_ostream_from_buffer(buffer, encodedSize);
|
||||||
|
|
||||||
RLOGE("SapImpl::powerReq calling pb_encode");
|
RLOGD("SapImpl::powerReq calling pb_encode");
|
||||||
if (!pb_encode(&stream, RIL_SIM_SAP_POWER_REQ_fields, &req)) {
|
if (!pb_encode(&stream, RIL_SIM_SAP_POWER_REQ_fields, &req)) {
|
||||||
RLOGE("SapImpl::powerReq: Error encoding RIL_SIM_SAP_POWER_REQ");
|
RLOGE("SapImpl::powerReq: Error encoding RIL_SIM_SAP_POWER_REQ");
|
||||||
sendFailedResponse(MsgId_RIL_SIM_SAP_POWER, token, 2, buffer, msg);
|
sendFailedResponse(MsgId_RIL_SIM_SAP_POWER, token, 2, buffer, msg);
|
||||||
|
@ -403,7 +403,7 @@ Return<void> SapImpl::powerReq(int32_t token, bool state) {
|
||||||
}
|
}
|
||||||
|
|
||||||
Return<void> SapImpl::resetSimReq(int32_t token) {
|
Return<void> SapImpl::resetSimReq(int32_t token) {
|
||||||
RLOGE("SapImpl::resetSimReq");
|
RLOGD("SapImpl::resetSimReq");
|
||||||
MsgHeader *msg = createMsgHeader(MsgId_RIL_SIM_SAP_RESET_SIM, token);
|
MsgHeader *msg = createMsgHeader(MsgId_RIL_SIM_SAP_RESET_SIM, token);
|
||||||
if (msg == NULL) {
|
if (msg == NULL) {
|
||||||
RLOGE("SapImpl::resetSimReq: Error allocating memory for msg");
|
RLOGE("SapImpl::resetSimReq: Error allocating memory for msg");
|
||||||
|
@ -431,7 +431,7 @@ Return<void> SapImpl::resetSimReq(int32_t token) {
|
||||||
|
|
||||||
pb_ostream_t stream = pb_ostream_from_buffer(buffer, encodedSize);
|
pb_ostream_t stream = pb_ostream_from_buffer(buffer, encodedSize);
|
||||||
|
|
||||||
RLOGE("SapImpl::resetSimReq calling pb_encode");
|
RLOGD("SapImpl::resetSimReq calling pb_encode");
|
||||||
if (!pb_encode(&stream, RIL_SIM_SAP_RESET_SIM_REQ_fields, &req)) {
|
if (!pb_encode(&stream, RIL_SIM_SAP_RESET_SIM_REQ_fields, &req)) {
|
||||||
RLOGE("SapImpl::resetSimReq: Error encoding RIL_SIM_SAP_RESET_SIM_REQ");
|
RLOGE("SapImpl::resetSimReq: Error encoding RIL_SIM_SAP_RESET_SIM_REQ");
|
||||||
sendFailedResponse(MsgId_RIL_SIM_SAP_RESET_SIM, token, 2, buffer, msg);
|
sendFailedResponse(MsgId_RIL_SIM_SAP_RESET_SIM, token, 2, buffer, msg);
|
||||||
|
@ -444,7 +444,7 @@ Return<void> SapImpl::resetSimReq(int32_t token) {
|
||||||
}
|
}
|
||||||
|
|
||||||
Return<void> SapImpl::transferCardReaderStatusReq(int32_t token) {
|
Return<void> SapImpl::transferCardReaderStatusReq(int32_t token) {
|
||||||
RLOGE("SapImpl::transferCardReaderStatusReq");
|
RLOGD("SapImpl::transferCardReaderStatusReq");
|
||||||
MsgHeader *msg = createMsgHeader(MsgId_RIL_SIM_SAP_TRANSFER_CARD_READER_STATUS, token);
|
MsgHeader *msg = createMsgHeader(MsgId_RIL_SIM_SAP_TRANSFER_CARD_READER_STATUS, token);
|
||||||
if (msg == NULL) {
|
if (msg == NULL) {
|
||||||
RLOGE("SapImpl::transferCardReaderStatusReq: Error allocating memory for msg");
|
RLOGE("SapImpl::transferCardReaderStatusReq: Error allocating memory for msg");
|
||||||
|
@ -474,7 +474,7 @@ Return<void> SapImpl::transferCardReaderStatusReq(int32_t token) {
|
||||||
|
|
||||||
pb_ostream_t stream = pb_ostream_from_buffer(buffer, encodedSize);
|
pb_ostream_t stream = pb_ostream_from_buffer(buffer, encodedSize);
|
||||||
|
|
||||||
RLOGE("SapImpl::transferCardReaderStatusReq calling pb_encode");
|
RLOGD("SapImpl::transferCardReaderStatusReq calling pb_encode");
|
||||||
if (!pb_encode(&stream, RIL_SIM_SAP_TRANSFER_CARD_READER_STATUS_REQ_fields, &req)) {
|
if (!pb_encode(&stream, RIL_SIM_SAP_TRANSFER_CARD_READER_STATUS_REQ_fields, &req)) {
|
||||||
RLOGE("SapImpl::transferCardReaderStatusReq: Error encoding "
|
RLOGE("SapImpl::transferCardReaderStatusReq: Error encoding "
|
||||||
"RIL_SIM_SAP_TRANSFER_CARD_READER_STATUS_REQ");
|
"RIL_SIM_SAP_TRANSFER_CARD_READER_STATUS_REQ");
|
||||||
|
@ -488,7 +488,7 @@ Return<void> SapImpl::transferCardReaderStatusReq(int32_t token) {
|
||||||
}
|
}
|
||||||
|
|
||||||
Return<void> SapImpl::setTransferProtocolReq(int32_t token, SapTransferProtocol transferProtocol) {
|
Return<void> SapImpl::setTransferProtocolReq(int32_t token, SapTransferProtocol transferProtocol) {
|
||||||
RLOGE("SapImpl::setTransferProtocolReq");
|
RLOGD("SapImpl::setTransferProtocolReq");
|
||||||
MsgHeader *msg = createMsgHeader(MsgId_RIL_SIM_SAP_SET_TRANSFER_PROTOCOL, token);
|
MsgHeader *msg = createMsgHeader(MsgId_RIL_SIM_SAP_SET_TRANSFER_PROTOCOL, token);
|
||||||
if (msg == NULL) {
|
if (msg == NULL) {
|
||||||
RLOGE("SapImpl::setTransferProtocolReq: Error allocating memory for msg");
|
RLOGE("SapImpl::setTransferProtocolReq: Error allocating memory for msg");
|
||||||
|
@ -518,7 +518,7 @@ Return<void> SapImpl::setTransferProtocolReq(int32_t token, SapTransferProtocol
|
||||||
|
|
||||||
pb_ostream_t stream = pb_ostream_from_buffer(buffer, encodedSize);
|
pb_ostream_t stream = pb_ostream_from_buffer(buffer, encodedSize);
|
||||||
|
|
||||||
RLOGE("SapImpl::setTransferProtocolReq calling pb_encode");
|
RLOGD("SapImpl::setTransferProtocolReq calling pb_encode");
|
||||||
if (!pb_encode(&stream, RIL_SIM_SAP_SET_TRANSFER_PROTOCOL_REQ_fields, &req)) {
|
if (!pb_encode(&stream, RIL_SIM_SAP_SET_TRANSFER_PROTOCOL_REQ_fields, &req)) {
|
||||||
RLOGE("SapImpl::setTransferProtocolReq: Error encoding "
|
RLOGE("SapImpl::setTransferProtocolReq: Error encoding "
|
||||||
"RIL_SIM_SAP_SET_TRANSFER_PROTOCOL_REQ");
|
"RIL_SIM_SAP_SET_TRANSFER_PROTOCOL_REQ");
|
||||||
|
@ -662,7 +662,7 @@ void *sapDecodeMessage(MsgId msgId, MsgType msgType, uint8_t *payloadPtr, size_t
|
||||||
sp<SapImpl> getSapImpl(RilSapSocket *sapSocket) {
|
sp<SapImpl> getSapImpl(RilSapSocket *sapSocket) {
|
||||||
switch (sapSocket->getSocketId()) {
|
switch (sapSocket->getSocketId()) {
|
||||||
case RIL_SOCKET_1:
|
case RIL_SOCKET_1:
|
||||||
RLOGE("getSapImpl: returning sapService[0]");
|
RLOGD("getSapImpl: returning sapService[0]");
|
||||||
return sapService[0];
|
return sapService[0];
|
||||||
#if (SIM_COUNT >= 2)
|
#if (SIM_COUNT >= 2)
|
||||||
case RIL_SOCKET_2:
|
case RIL_SOCKET_2:
|
||||||
|
@ -783,14 +783,14 @@ void processResponse(MsgHeader *rsp, RilSapSocket *sapSocket, MsgType msgType) {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
RLOGE("processResponse: sapCallback != NULL; msgId = %d; msgType = %d",
|
RLOGD("processResponse: sapCallback != NULL; msgId = %d; msgType = %d",
|
||||||
msgId, msgType);
|
msgId, msgType);
|
||||||
|
|
||||||
Return<void> retStatus;
|
Return<void> retStatus;
|
||||||
switch (msgId) {
|
switch (msgId) {
|
||||||
case MsgId_RIL_SIM_SAP_CONNECT: {
|
case MsgId_RIL_SIM_SAP_CONNECT: {
|
||||||
RIL_SIM_SAP_CONNECT_RSP *connectRsp = (RIL_SIM_SAP_CONNECT_RSP *)messagePtr;
|
RIL_SIM_SAP_CONNECT_RSP *connectRsp = (RIL_SIM_SAP_CONNECT_RSP *)messagePtr;
|
||||||
RLOGE("processResponse: calling sapCallback->connectResponse %d %d %d",
|
RLOGD("processResponse: calling sapCallback->connectResponse %d %d %d",
|
||||||
rsp->token,
|
rsp->token,
|
||||||
connectRsp->response,
|
connectRsp->response,
|
||||||
connectRsp->max_message_size);
|
connectRsp->max_message_size);
|
||||||
|
@ -802,12 +802,12 @@ void processResponse(MsgHeader *rsp, RilSapSocket *sapSocket, MsgType msgType) {
|
||||||
|
|
||||||
case MsgId_RIL_SIM_SAP_DISCONNECT:
|
case MsgId_RIL_SIM_SAP_DISCONNECT:
|
||||||
if (msgType == MsgType_RESPONSE) {
|
if (msgType == MsgType_RESPONSE) {
|
||||||
RLOGE("processResponse: calling sapCallback->disconnectResponse %d", rsp->token);
|
RLOGD("processResponse: calling sapCallback->disconnectResponse %d", rsp->token);
|
||||||
retStatus = sapImpl->sapCallback->disconnectResponse(rsp->token);
|
retStatus = sapImpl->sapCallback->disconnectResponse(rsp->token);
|
||||||
} else {
|
} else {
|
||||||
RIL_SIM_SAP_DISCONNECT_IND *disconnectInd =
|
RIL_SIM_SAP_DISCONNECT_IND *disconnectInd =
|
||||||
(RIL_SIM_SAP_DISCONNECT_IND *)messagePtr;
|
(RIL_SIM_SAP_DISCONNECT_IND *)messagePtr;
|
||||||
RLOGE("processResponse: calling sapCallback->disconnectIndication %d %d",
|
RLOGD("processResponse: calling sapCallback->disconnectIndication %d %d",
|
||||||
rsp->token, disconnectInd->disconnectType);
|
rsp->token, disconnectInd->disconnectType);
|
||||||
retStatus = sapImpl->sapCallback->disconnectIndication(rsp->token,
|
retStatus = sapImpl->sapCallback->disconnectIndication(rsp->token,
|
||||||
(SapDisconnectType)disconnectInd->disconnectType);
|
(SapDisconnectType)disconnectInd->disconnectType);
|
||||||
|
@ -817,7 +817,7 @@ void processResponse(MsgHeader *rsp, RilSapSocket *sapSocket, MsgType msgType) {
|
||||||
case MsgId_RIL_SIM_SAP_APDU: {
|
case MsgId_RIL_SIM_SAP_APDU: {
|
||||||
RIL_SIM_SAP_APDU_RSP *apduRsp = (RIL_SIM_SAP_APDU_RSP *)messagePtr;
|
RIL_SIM_SAP_APDU_RSP *apduRsp = (RIL_SIM_SAP_APDU_RSP *)messagePtr;
|
||||||
SapResultCode apduResponse = convertApduResponseProtoToHal(apduRsp->response);
|
SapResultCode apduResponse = convertApduResponseProtoToHal(apduRsp->response);
|
||||||
RLOGE("processResponse: calling sapCallback->apduResponse %d %d",
|
RLOGD("processResponse: calling sapCallback->apduResponse %d %d",
|
||||||
rsp->token, apduResponse);
|
rsp->token, apduResponse);
|
||||||
hidl_vec<uint8_t> apduRspVec;
|
hidl_vec<uint8_t> apduRspVec;
|
||||||
if (apduRsp->apduResponse != NULL && apduRsp->apduResponse->size > 0) {
|
if (apduRsp->apduResponse != NULL && apduRsp->apduResponse->size > 0) {
|
||||||
|
@ -832,7 +832,7 @@ void processResponse(MsgHeader *rsp, RilSapSocket *sapSocket, MsgType msgType) {
|
||||||
(RIL_SIM_SAP_TRANSFER_ATR_RSP *)messagePtr;
|
(RIL_SIM_SAP_TRANSFER_ATR_RSP *)messagePtr;
|
||||||
SapResultCode transferAtrResponse =
|
SapResultCode transferAtrResponse =
|
||||||
convertTransferAtrResponseProtoToHal(transferAtrRsp->response);
|
convertTransferAtrResponseProtoToHal(transferAtrRsp->response);
|
||||||
RLOGE("processResponse: calling sapCallback->transferAtrResponse %d %d",
|
RLOGD("processResponse: calling sapCallback->transferAtrResponse %d %d",
|
||||||
rsp->token, transferAtrResponse);
|
rsp->token, transferAtrResponse);
|
||||||
hidl_vec<uint8_t> transferAtrRspVec;
|
hidl_vec<uint8_t> transferAtrRspVec;
|
||||||
if (transferAtrRsp->atr != NULL && transferAtrRsp->atr->size > 0) {
|
if (transferAtrRsp->atr != NULL && transferAtrRsp->atr->size > 0) {
|
||||||
|
@ -847,7 +847,7 @@ void processResponse(MsgHeader *rsp, RilSapSocket *sapSocket, MsgType msgType) {
|
||||||
case MsgId_RIL_SIM_SAP_POWER: {
|
case MsgId_RIL_SIM_SAP_POWER: {
|
||||||
SapResultCode powerResponse = convertPowerResponseProtoToHal(
|
SapResultCode powerResponse = convertPowerResponseProtoToHal(
|
||||||
((RIL_SIM_SAP_POWER_RSP *)messagePtr)->response);
|
((RIL_SIM_SAP_POWER_RSP *)messagePtr)->response);
|
||||||
RLOGE("processResponse: calling sapCallback->powerResponse %d %d",
|
RLOGD("processResponse: calling sapCallback->powerResponse %d %d",
|
||||||
rsp->token, powerResponse);
|
rsp->token, powerResponse);
|
||||||
retStatus = sapImpl->sapCallback->powerResponse(rsp->token, powerResponse);
|
retStatus = sapImpl->sapCallback->powerResponse(rsp->token, powerResponse);
|
||||||
break;
|
break;
|
||||||
|
@ -856,7 +856,7 @@ void processResponse(MsgHeader *rsp, RilSapSocket *sapSocket, MsgType msgType) {
|
||||||
case MsgId_RIL_SIM_SAP_RESET_SIM: {
|
case MsgId_RIL_SIM_SAP_RESET_SIM: {
|
||||||
SapResultCode resetSimResponse = convertResetSimResponseProtoToHal(
|
SapResultCode resetSimResponse = convertResetSimResponseProtoToHal(
|
||||||
((RIL_SIM_SAP_RESET_SIM_RSP *)messagePtr)->response);
|
((RIL_SIM_SAP_RESET_SIM_RSP *)messagePtr)->response);
|
||||||
RLOGE("processResponse: calling sapCallback->resetSimResponse %d %d",
|
RLOGD("processResponse: calling sapCallback->resetSimResponse %d %d",
|
||||||
rsp->token, resetSimResponse);
|
rsp->token, resetSimResponse);
|
||||||
retStatus = sapImpl->sapCallback->resetSimResponse(rsp->token, resetSimResponse);
|
retStatus = sapImpl->sapCallback->resetSimResponse(rsp->token, resetSimResponse);
|
||||||
break;
|
break;
|
||||||
|
@ -864,7 +864,7 @@ void processResponse(MsgHeader *rsp, RilSapSocket *sapSocket, MsgType msgType) {
|
||||||
|
|
||||||
case MsgId_RIL_SIM_SAP_STATUS: {
|
case MsgId_RIL_SIM_SAP_STATUS: {
|
||||||
RIL_SIM_SAP_STATUS_IND *statusInd = (RIL_SIM_SAP_STATUS_IND *)messagePtr;
|
RIL_SIM_SAP_STATUS_IND *statusInd = (RIL_SIM_SAP_STATUS_IND *)messagePtr;
|
||||||
RLOGE("processResponse: calling sapCallback->statusIndication %d %d",
|
RLOGD("processResponse: calling sapCallback->statusIndication %d %d",
|
||||||
rsp->token, statusInd->statusChange);
|
rsp->token, statusInd->statusChange);
|
||||||
retStatus = sapImpl->sapCallback->statusIndication(rsp->token,
|
retStatus = sapImpl->sapCallback->statusIndication(rsp->token,
|
||||||
(SapStatus)statusInd->statusChange);
|
(SapStatus)statusInd->statusChange);
|
||||||
|
@ -877,7 +877,7 @@ void processResponse(MsgHeader *rsp, RilSapSocket *sapSocket, MsgType msgType) {
|
||||||
SapResultCode transferCardReaderStatusResponse =
|
SapResultCode transferCardReaderStatusResponse =
|
||||||
convertTransferCardReaderStatusResponseProtoToHal(
|
convertTransferCardReaderStatusResponseProtoToHal(
|
||||||
transferStatusRsp->response);
|
transferStatusRsp->response);
|
||||||
RLOGE("processResponse: calling sapCallback->transferCardReaderStatusResponse %d %d %d",
|
RLOGD("processResponse: calling sapCallback->transferCardReaderStatusResponse %d %d %d",
|
||||||
rsp->token,
|
rsp->token,
|
||||||
transferCardReaderStatusResponse,
|
transferCardReaderStatusResponse,
|
||||||
transferStatusRsp->CardReaderStatus);
|
transferStatusRsp->CardReaderStatus);
|
||||||
|
@ -888,7 +888,7 @@ void processResponse(MsgHeader *rsp, RilSapSocket *sapSocket, MsgType msgType) {
|
||||||
}
|
}
|
||||||
|
|
||||||
case MsgId_RIL_SIM_SAP_ERROR_RESP: {
|
case MsgId_RIL_SIM_SAP_ERROR_RESP: {
|
||||||
RLOGE("processResponse: calling sapCallback->errorResponse %d", rsp->token);
|
RLOGD("processResponse: calling sapCallback->errorResponse %d", rsp->token);
|
||||||
retStatus = sapImpl->sapCallback->errorResponse(rsp->token);
|
retStatus = sapImpl->sapCallback->errorResponse(rsp->token);
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
@ -901,7 +901,7 @@ void processResponse(MsgHeader *rsp, RilSapSocket *sapSocket, MsgType msgType) {
|
||||||
} else {
|
} else {
|
||||||
setTransferProtocolResponse = SapResultCode::NOT_SUPPORTED;
|
setTransferProtocolResponse = SapResultCode::NOT_SUPPORTED;
|
||||||
}
|
}
|
||||||
RLOGE("processResponse: calling sapCallback->transferProtocolResponse %d %d",
|
RLOGD("processResponse: calling sapCallback->transferProtocolResponse %d %d",
|
||||||
rsp->token, setTransferProtocolResponse);
|
rsp->token, setTransferProtocolResponse);
|
||||||
retStatus = sapImpl->sapCallback->transferProtocolResponse(rsp->token,
|
retStatus = sapImpl->sapCallback->transferProtocolResponse(rsp->token,
|
||||||
setTransferProtocolResponse);
|
setTransferProtocolResponse);
|
||||||
|
@ -958,8 +958,8 @@ void sap::registerService(RIL_RadioFunctions *callbacks) {
|
||||||
sapService[i] = new SapImpl;
|
sapService[i] = new SapImpl;
|
||||||
sapService[i]->slotId = i;
|
sapService[i]->slotId = i;
|
||||||
sapService[i]->rilSocketId = socketIds[i];
|
sapService[i]->rilSocketId = socketIds[i];
|
||||||
RLOGE("registerService: starting ISap %s for slotId %d", serviceNames[i], i);
|
RLOGD("registerService: starting ISap %s for slotId %d", serviceNames[i], i);
|
||||||
android::status_t status = sapService[i]->registerAsService(serviceNames[i]);
|
android::status_t status = sapService[i]->registerAsService(serviceNames[i]);
|
||||||
RLOGE("registerService: started ISap %s status %d", serviceNames[i], status);
|
RLOGD("registerService: started ISap %s status %d", serviceNames[i], status);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -211,6 +211,11 @@ on post-fs-data
|
||||||
# Symlink to bugreport storage location
|
# Symlink to bugreport storage location
|
||||||
symlink /data/data/com.android.shell/files/bugreports /data/bugreports
|
symlink /data/data/com.android.shell/files/bugreports /data/bugreports
|
||||||
|
|
||||||
|
# Remove symlinks to avoid issues with migrate after nandroid restores
|
||||||
|
# Will be recreated at end of boot
|
||||||
|
rm /data/data/com.android.providers.telephony/databases
|
||||||
|
rm /data/data/com.android.providers.telephony/shared_prefs
|
||||||
|
|
||||||
setprop vold.post_fs_data_done 1
|
setprop vold.post_fs_data_done 1
|
||||||
|
|
||||||
on early-boot
|
on early-boot
|
||||||
|
@ -509,6 +514,14 @@ on boot
|
||||||
# Mark wifi driver as unloaded - "ok" indicates loaded
|
# Mark wifi driver as unloaded - "ok" indicates loaded
|
||||||
setprop wlan.driver.status not_ok
|
setprop wlan.driver.status not_ok
|
||||||
|
|
||||||
|
|
||||||
|
on property:sys.boot_completed=1
|
||||||
|
# Symlink directories to access telephony.db and preferred-apn.xml required by libsec-ril
|
||||||
|
symlink /data/user_de/0/com.android.providers.telephony/databases /data/data/com.android.providers.telephony/databases
|
||||||
|
symlink /data/user_de/0/com.android.providers.telephony/shared_prefs /data/data/com.android.providers.telephony/shared_prefs
|
||||||
|
restorecon /data/data/com.android.providers.telephony/databases
|
||||||
|
restorecon /data/data/com.android.providers.telephony/shared_pref
|
||||||
|
|
||||||
on charger
|
on charger
|
||||||
wait /dev/block/platform/msm_sdcc.1/by-name/system
|
wait /dev/block/platform/msm_sdcc.1/by-name/system
|
||||||
mount ext4 /dev/block/platform/msm_sdcc.1/by-name/system /system ro barrier=1
|
mount ext4 /dev/block/platform/msm_sdcc.1/by-name/system /system ro barrier=1
|
||||||
|
|
24
system.prop
24
system.prop
|
@ -70,24 +70,12 @@ ro.nfc.port=I2C
|
||||||
# this prop is only for samsung
|
# this prop is only for samsung
|
||||||
# ro.debug_level=0x4948
|
# ro.debug_level=0x4948
|
||||||
#####
|
#####
|
||||||
rild.libpath=/vendor/lib/libril-qc-qmi-1.so
|
persist.data.netmgrd.qos.enable=true
|
||||||
rild.libargs=-d /dev/smd0
|
persist.data.qmi.adb_logmask=0
|
||||||
persist.rild.nitz_plmn=
|
persist.radio.add_power_save=1
|
||||||
persist.rild.nitz_long_ons_0=
|
rild.libpath=/system/vendor/lib/libsec-ril.so
|
||||||
persist.rild.nitz_long_ons_1=
|
ro.telephony.mms_data_profile=5
|
||||||
persist.rild.nitz_long_ons_2=
|
ro.ril.telephony.qan_resp_strings=6
|
||||||
persist.rild.nitz_long_ons_3=
|
|
||||||
persist.rild.nitz_short_ons_0=
|
|
||||||
persist.rild.nitz_short_ons_1=
|
|
||||||
persist.rild.nitz_short_ons_2=
|
|
||||||
persist.rild.nitz_short_ons_3=
|
|
||||||
ril.subscription.types=NV,RUIM
|
|
||||||
DEVICE_PROVISIONED=1
|
|
||||||
ro.telephony.default_network=9
|
|
||||||
ro.baseband.arch=msm
|
|
||||||
persist.radio.jbims=1
|
|
||||||
persist.rmnet.mux=enabled
|
|
||||||
persist.data.iwlan.enable=true
|
|
||||||
|
|
||||||
# Ril sends only one RIL_UNSOL_CALL_RING, so set call_ring.multiple to false
|
# Ril sends only one RIL_UNSOL_CALL_RING, so set call_ring.multiple to false
|
||||||
ro.telephony.call_ring.multiple=0
|
ro.telephony.call_ring.multiple=0
|
||||||
|
|
Loading…
Reference in a new issue