OSDN Git Service

android-x86/hardware-ril.git
8 years agoreference-ril: Stop using pthread_cond_timedwait_relative_np()
Yu Ning [Thu, 31 Mar 2016 13:49:59 +0000 (21:49 +0800)]
reference-ril: Stop using pthread_cond_timedwait_relative_np()

pthread_cond_timedwait_relative_np() is deprecated, and is only
available in the 32-bit ABI (see bionic/libc/include/pthread.h). It is
still used by the 32-bit version of reference-ril. Thanks to a recent
bugfix for 64-bit [1], it is now safe to replace the deprecated
function with the standard pthread_cond_timedwait(). Doing so also
simplifies the code, as there is now a unified logic for 32 and 64-bit
targets.

[1] https://android-review.googlesource.com/210301

Change-Id: I0895bbf65ddb71965018d6945dfb8baa786d5d89
Signed-off-by: Yu Ning <yu.ning@intel.com>
8 years agoMerge "reference-ril/atchannel.c: Fix time conversion"
Bo Hu [Wed, 30 Mar 2016 05:46:57 +0000 (05:46 +0000)]
Merge "reference-ril/atchannel.c: Fix time conversion"

8 years agoreference-ril/atchannel.c: Fix time conversion
Jinhui Li [Thu, 24 Mar 2016 00:55:10 +0000 (08:55 +0800)]
reference-ril/atchannel.c: Fix time conversion

setTimespecRelative() converts a relative time to an absolute time, by
adding the relative time to current system time. However, it fails to
handle the case where the nanosecond component (tv_nsec) of the
conversion result exceeds 10^9, which can cause a subsequent call to
pthread_cond_timedwait() to return EINVAL.

This bug is the root cause of the "no SIM card" error seen occasionally
on x86_64 Android emulator. In fact, all 64-bit targets use
setTimespecRelative() in conjunction with pthread_cond_timedwait()
during AT handshake, but an EINVAL return value from the latter will
lead to an infinite loop and hang the communication. With this fix,
x86_64 emulator can boot with functional 3G networking every time.

Signed-off-by: Jinhui Li <jinhui.li@intel.com>
[Revised code and commit message]
Signed-off-by: Yu Ning <yu.ning@intel.com>
Change-Id: If04ba560e350bc4e13b22c51f8d215a673230667

8 years agoMerge "Subject: [PATCH] Fix heap-use-after-free in reference-ril.c found by AddressSa...
Dan Albert [Thu, 28 Jan 2016 18:32:17 +0000 (18:32 +0000)]
Merge "Subject: [PATCH] Fix heap-use-after-free in reference-ril.c found by AddressSaniziter."

8 years agoSubject: [PATCH] Fix heap-use-after-free in reference-ril.c found by
Ivan Krasin [Wed, 27 Jan 2016 19:17:58 +0000 (11:17 -0800)]
Subject: [PATCH] Fix heap-use-after-free in reference-ril.c found by
AddressSaniziter.

BUG=26012424

(cherry picked from commit 7c0165ee3b769ed6a67b58b7c6e2f60bd6f8fbf6)

Change-Id: I108f01229b5fe6a368129e608195ba5833f2ea91

8 years agoMerge "Use GID "wakelock" to control access to kernel wakelock"
Pavlin Radoslavov [Tue, 29 Dec 2015 01:24:15 +0000 (01:24 +0000)]
Merge "Use GID "wakelock" to control access to kernel wakelock"

8 years agoUse GID "wakelock" to control access to kernel wakelock
Pavlin Radoslavov [Tue, 24 Nov 2015 03:19:32 +0000 (19:19 -0800)]
Use GID "wakelock" to control access to kernel wakelock

Bug: 25864142
Change-Id: I9c68defed9a47ddb33f70e73e29edcfa713da056

8 years agoMerge "Properly export ril_ex.h"
Colin Cross [Wed, 16 Dec 2015 23:04:21 +0000 (23:04 +0000)]
Merge "Properly export ril_ex.h"

8 years agoProperly export ril_ex.h
Colin Cross [Wed, 16 Dec 2015 22:15:42 +0000 (14:15 -0800)]
Properly export ril_ex.h

Copying headers makes fixing compile errors hard, and breaks dependency
restrictions.  Move ril_ex.h to an exported include directory instead of
copying it.

Bug: 18903857
Change-Id: I4b59a01e442db0d3198def69a5a5ff17b2a41c66

8 years agoMerge "rild: add to readproc group"
Nick Kralevich [Wed, 18 Nov 2015 01:46:29 +0000 (01:46 +0000)]
Merge "rild: add to readproc group"

8 years agorild: add to readproc group
Nick Kralevich [Wed, 18 Nov 2015 01:19:24 +0000 (17:19 -0800)]
rild: add to readproc group

At least on shamu, rild scans through /proc looking for the
netmgr process. Make sure rild is in the appropriate group to
examine /proc entries.

Bug: 25608126
Bug: 23310674
Change-Id: I9d0aecf91bcec326a51c08bd3f08b27d81bb81d6

8 years agoam c06e3c6d: am 7436ac31: Merge "libril: fix a syntax error"
Robert Greenwalt [Fri, 2 Oct 2015 22:07:04 +0000 (22:07 +0000)]
am c06e3c6d: am 7436ac31: Merge "libril: fix a syntax error"

* commit 'c06e3c6d08d90e585c75f91ccf2a5d135b26f784':
  libril: fix a syntax error

8 years agoam 7436ac31: Merge "libril: fix a syntax error"
Robert Greenwalt [Fri, 2 Oct 2015 21:59:37 +0000 (21:59 +0000)]
am 7436ac31: Merge "libril: fix a syntax error"

* commit '7436ac31914fcf010d039c725d8810a04e5d6440':
  libril: fix a syntax error

8 years agoMerge "libril: fix a syntax error"
Robert Greenwalt [Fri, 2 Oct 2015 21:55:34 +0000 (21:55 +0000)]
Merge "libril: fix a syntax error"

8 years agolibril: fix a syntax error
Chih-Wei Huang [Fri, 2 Oct 2015 07:09:52 +0000 (15:09 +0800)]
libril: fix a syntax error

The trivial error was hidden since RILC_LOG is disabled.

Change-Id: Ie25fecedb2e8f27da7f19d35ccc4dd1f250cfd9c
Signed-off-by: Chih-Wei Huang <cwhuang@linux.org.tw>
8 years agoam 3cf0775d: resolved conflicts for ba95966e to stage-aosp-master
Dan Willemsen [Mon, 28 Sep 2015 21:51:02 +0000 (21:51 +0000)]
am 3cf0775d: resolved conflicts for ba95966e to stage-aosp-master

* commit '3cf0775dd1233eb52f3ff21ddff0a5e5e6631d66':
  Prepare to remove ril from global include paths

8 years agoresolved conflicts for ba95966e to stage-aosp-master
Dan Willemsen [Mon, 28 Sep 2015 21:33:14 +0000 (14:33 -0700)]
resolved conflicts for ba95966e to stage-aosp-master

Change-Id: Id468b025222853e5a421300b6e669de999bf737e

8 years agoMerge "Prepare to remove ril from global include paths"
Dan Willemsen [Mon, 28 Sep 2015 21:23:11 +0000 (21:23 +0000)]
Merge "Prepare to remove ril from global include paths"

8 years agoPrepare to remove ril from global include paths
Dan Willemsen [Thu, 24 Sep 2015 23:18:04 +0000 (16:18 -0700)]
Prepare to remove ril from global include paths

Bug: 18903857
Change-Id: I3051dd5d3947dda346406841853eac8213a3eb55

8 years agoam d33397be: Fix memory leaks and use of uninitialized pointers.
Pavel Zhamaitsiak [Fri, 28 Aug 2015 22:46:05 +0000 (22:46 +0000)]
am d33397be: Fix memory leaks and use of uninitialized pointers.

* commit 'd33397bed7bab16991d2a9d83d84d157b1e02b29':
  Fix memory leaks and use of uninitialized pointers.

8 years agoam 536a38fe: (-s ours) update bundled rc files to their contents from rootdir/init.rc
Tom Cherry [Thu, 27 Aug 2015 12:07:50 +0000 (12:07 +0000)]
am 536a38fe: (-s ours) update bundled rc files to their contents from rootdir/init.rc

* commit '536a38fe3317047e9b51813a04ae3a74c3df5d60':
  update bundled rc files to their contents from rootdir/init.rc

8 years agoam 6f230a10: (-s ours) am 45da9118: Merge "bundle init.rc contents with its service"
Tom Cherry [Thu, 27 Aug 2015 12:07:50 +0000 (12:07 +0000)]
am 6f230a10: (-s ours) am 45da9118: Merge "bundle init.rc contents with its service"

* commit '6f230a10d241a270c787596b1bfba65f45ae15f7':

8 years agoam e5faca1d: (-s ours) am bdb15a2a: Merge "Use _WIN32 rather than HAVE_WINSOCK in...
Elliott Hughes [Thu, 27 Aug 2015 12:07:49 +0000 (12:07 +0000)]
am e5faca1d: (-s ours) am bdb15a2a: Merge "Use _WIN32 rather than HAVE_WINSOCK in librilutils."

* commit 'e5faca1d4ac0de0920d379dca656c0f809045640':

8 years agoupdate bundled rc files to their contents from rootdir/init.rc
Tom Cherry [Fri, 21 Aug 2015 19:36:48 +0000 (12:36 -0700)]
update bundled rc files to their contents from rootdir/init.rc

Bug 23186545

Change-Id: Id180e0ed47f0706322580305dddbbc3b92865827
(cherry picked from commit 4b1c2e3687e9651e3cb882e03fec743d24e46f93)

8 years agoupdate bundled rc files to their contents from rootdir/init.rc
Tom Cherry [Fri, 21 Aug 2015 19:36:48 +0000 (12:36 -0700)]
update bundled rc files to their contents from rootdir/init.rc

Bug 23186545

Change-Id: Id180e0ed47f0706322580305dddbbc3b92865827
(cherry picked from commit 4b1c2e3687e9651e3cb882e03fec743d24e46f93)

8 years agoam 45da9118: Merge "bundle init.rc contents with its service"
Tom Cherry [Fri, 21 Aug 2015 18:24:27 +0000 (18:24 +0000)]
am 45da9118: Merge "bundle init.rc contents with its service"

* commit '45da91185bbfbc01569f682f65c03fc4629aa579':
  bundle init.rc contents with its service

8 years agoam 45da9118: Merge "bundle init.rc contents with its service"
Tom Cherry [Fri, 21 Aug 2015 18:20:26 +0000 (18:20 +0000)]
am 45da9118: Merge "bundle init.rc contents with its service"

* commit '45da91185bbfbc01569f682f65c03fc4629aa579':
  bundle init.rc contents with its service

8 years agoMerge "bundle init.rc contents with its service"
Tom Cherry [Fri, 21 Aug 2015 17:42:32 +0000 (17:42 +0000)]
Merge "bundle init.rc contents with its service"

8 years agobundle init.rc contents with its service
Tom Cherry [Fri, 14 Aug 2015 20:01:45 +0000 (13:01 -0700)]
bundle init.rc contents with its service

Bug: 23186545
Change-Id: Id35f5348b64204ff6127865dcfc61edb3ef210c2

8 years agoFix memory leaks and use of uninitialized pointers.
Pavel Zhamaitsiak [Tue, 18 Aug 2015 18:40:01 +0000 (11:40 -0700)]
Fix memory leaks and use of uninitialized pointers.

Bug: 23187886
Change-Id: Ic15a02a902b591362b5c52c20afabe511fb0bbb7

8 years agoam bdb15a2a: Merge "Use _WIN32 rather than HAVE_WINSOCK in librilutils."
Elliott Hughes [Thu, 30 Jul 2015 15:17:37 +0000 (15:17 +0000)]
am bdb15a2a: Merge "Use _WIN32 rather than HAVE_WINSOCK in librilutils."

* commit 'bdb15a2afe89fd2458224accf59ed9a8bda7d3e6':
  Use _WIN32 rather than HAVE_WINSOCK in librilutils.

8 years agoam bdb15a2a: Merge "Use _WIN32 rather than HAVE_WINSOCK in librilutils."
Elliott Hughes [Thu, 30 Jul 2015 15:17:05 +0000 (15:17 +0000)]
am bdb15a2a: Merge "Use _WIN32 rather than HAVE_WINSOCK in librilutils."

* commit 'bdb15a2afe89fd2458224accf59ed9a8bda7d3e6':
  Use _WIN32 rather than HAVE_WINSOCK in librilutils.

8 years agoMerge "Use _WIN32 rather than HAVE_WINSOCK in librilutils."
Elliott Hughes [Thu, 30 Jul 2015 14:50:42 +0000 (14:50 +0000)]
Merge "Use _WIN32 rather than HAVE_WINSOCK in librilutils."

8 years agoUse _WIN32 rather than HAVE_WINSOCK in librilutils.
Elliott Hughes [Thu, 30 Jul 2015 00:47:06 +0000 (17:47 -0700)]
Use _WIN32 rather than HAVE_WINSOCK in librilutils.

(This code isn't built for the host, but has a copy of record_stream.c.)

Change-Id: I01ff7f9d138ad83c379e0dbe4abb2447a7ae98fe

8 years agoModify RIL Unsol Message Wakelock to 200ms
Nathan Harold [Tue, 28 Jul 2015 21:54:58 +0000 (14:54 -0700)]
Modify RIL Unsol Message Wakelock to 200ms

bug: 22456054

Change-Id: Id41e001f98b455bec5f004438f5d8498b17aaf2d

8 years agoAdded support for acquiring CAP_BLOCK_SUSPEND capability
Sukanya Rajkhowa [Thu, 15 Jan 2015 01:56:25 +0000 (17:56 -0800)]
Added support for acquiring CAP_BLOCK_SUSPEND capability

- Linux kernel 3.10 onward power service mandates the user
  space processes that use wake_lock service to have
  CAP_BLOCK_SUSPEND capability. Made changes in rild
  process to acquire the same

- Rild: Use division while defining MAX_CAP_NUM

Bug: 21063398

Change-Id: Idf38d9bde398e748139a6e5d7e7d9a1ac106ec8d

8 years agoSupport backward compatibility of new LAST_CALL_FAIL_CAUSE
Sungmin Choi [Wed, 1 Jul 2015 07:22:46 +0000 (16:22 +0900)]
Support backward compatibility of new LAST_CALL_FAIL_CAUSE

Previous fail cause returns integer array. New fail cuase returns integer and
string. RIL framework uses just integer as causeCode.
To support backward compatibility, returns integer instead of integer array
as causeCode.

Bug: 22204818
Change-Id: I77ca55d99a44d129cf401743c34c03754f38dde2

8 years agoAdd an optional vendor_cause string to
Chao Liu [Thu, 14 May 2015 23:13:46 +0000 (16:13 -0700)]
Add an optional vendor_cause string to
RIL_REQUEST_LAST_CALL_FAIL_CAUSE's response.
This vendor cause string will be passed to Telecom's DisconnectCause,
which could help us figure out why we are seeing so many ERROR_UNSPECIFIED.
bug:17701976

Original partner change:
https://partner-android-review.googlesource.com/#/c/215710/

Change-Id: I0c54733a03b2fe2bd48b3d3b21efc5e3ebd9ef66

8 years agoModem activity info
Prerepa Viswanadham [Thu, 28 May 2015 07:37:32 +0000 (00:37 -0700)]
Modem activity info

Change-Id: Iab8fbdeae0867c6e9cb9027b08317b1b5a2c9dfc

8 years agoRIL: Interface to retrieve power stats info
Sooraj Sasindran [Thu, 9 Apr 2015 00:23:07 +0000 (17:23 -0700)]
RIL: Interface to retrieve power stats info

Introduce interface to retrieve modem power stats info

Change-Id: I7ed89e754f733a93e430d64dfe28d7fbed1d4d75

8 years agoLCE RIL comment nit
fenglu [Sat, 2 May 2015 00:05:15 +0000 (17:05 -0700)]
LCE RIL comment nit

cherrypick from mwd to mnc-dev

Bug: 21307103
Change-Id: I0d9dd7bafee24a4853984ebcb665c022a0cbdc6a

9 years agoAdd missing extern "C" declaration.
Chih-Hung Hsieh [Wed, 6 May 2015 22:12:30 +0000 (15:12 -0700)]
Add missing extern "C" declaration.

BUG: 20891299
Change-Id: Iedfd2e8e5bd32014f011352898763bcc0887b6b9

9 years agoRemove verbose logs
Robert Greenwalt [Wed, 29 Apr 2015 23:57:39 +0000 (16:57 -0700)]
Remove verbose logs

Several things are redundent except for the fact
messages are reaching rilc.  Left in in case we need to debug
the layer, but blocked out with #if VDBG

Reduces startup logging to radio buffer by 20%

Change-Id: I95099457ea365ee108e7da8e1f81434531b6b9f0

9 years agoMerge commit '9a4b19c' into merge2
Etan Cohen [Fri, 24 Apr 2015 21:33:31 +0000 (14:33 -0700)]
Merge commit '9a4b19c' into merge2

9 years agoCorrect GET_RADIO_CAP documentation
Abhishek Adappa [Mon, 9 Feb 2015 19:11:12 +0000 (11:11 -0800)]
Correct GET_RADIO_CAP documentation

Change-Id: If9c07105771769b52070a85f93bf6d9a11fa6b80

9 years agoLink Capacity Estimation - RIL support
fenglu [Tue, 14 Apr 2015 21:53:55 +0000 (14:53 -0700)]
Link Capacity Estimation - RIL support

Change-Id: I9c4d4901d823d719be2b8bdec64f08eda342de53

9 years agoLink Capacity Estimation - RIL support
fenglu [Tue, 14 Apr 2015 21:53:55 +0000 (14:53 -0700)]
Link Capacity Estimation - RIL support

Change-Id: I9c4d4901d823d719be2b8bdec64f08eda342de53

9 years agoFix build issues after the merge
Vinit Deshpande [Wed, 15 Apr 2015 20:31:05 +0000 (13:31 -0700)]
Fix build issues after the merge

Change-Id: Ia856311187a0b2168cb859bd8b2300ff59df6569

9 years agoam 27976c4..27976c4 from mirror-m-wireless-internal-release
Vinit Deshpande [Tue, 14 Apr 2015 23:27:44 +0000 (16:27 -0700)]
am 27976c4..27976c4 from mirror-m-wireless-internal-release

27976c4 Introduction of the new SAP-UIM socket

Change-Id: I9ab9d65f230edd83037e2d1779b3bdd3b32a0aa7

9 years agoam 26a79e4e: Merge "libril: tag RILC messages to radio log"
Mark Salyzyn [Thu, 9 Apr 2015 16:45:24 +0000 (16:45 +0000)]
am 26a79e4e: Merge "libril: tag RILC messages to radio log"

* commit '26a79e4eba9a677d446dc767cf1df29f5ca1adb4':
  libril: tag RILC messages to radio log

9 years agoMerge "libril: tag RILC messages to radio log"
Mark Salyzyn [Thu, 9 Apr 2015 16:11:04 +0000 (16:11 +0000)]
Merge "libril: tag RILC messages to radio log"

9 years agolibril: tag RILC messages to radio log
Mark Salyzyn [Thu, 9 Apr 2015 14:18:35 +0000 (07:18 -0700)]
libril: tag RILC messages to radio log

Change-Id: Ia3234aa933249eb9f383c7e45c3f67b3c0c50634

9 years agoIntroduction of the new SAP-UIM socket
Dheeraj Shetty [Wed, 2 Jul 2014 19:27:57 +0000 (21:27 +0200)]
Introduction of the new SAP-UIM socket

Added new socket connection for communication between the SAP module
in Telephony and User Identity Module with DSDA support.

New classes added are:

RilSocket
---------
Base class(virtual) for any type of socket. Has listen
and commands callbacks similar to that of the existing
telephony->rild socket.

RilSapSocket
------------
Derived class for socket for communication between BT SAP
and the sim module in the modem. It initialises
socket, calls Sap_Uim_Init to get the handles and
starts the socket thread.

rilSocketQueue
--------------
Queue for managing socket requests.

Change-Id: I8828173941d6ae76f1f9cc0d567efaf41a77d175

9 years agoresolved conflicts for merge of 66650640 to master
Andreas Gampe [Mon, 6 Apr 2015 23:22:37 +0000 (16:22 -0700)]
resolved conflicts for merge of 66650640 to master

Change-Id: I2ece30436199e695c0f2cd5963586a2279578b9b

9 years agorild: missing include for sys/stat.h
Mark Salyzyn [Mon, 6 Apr 2015 20:51:43 +0000 (13:51 -0700)]
rild: missing include for sys/stat.h

rild.c gets sys/stat.h inherited from
private/android_filesystem_config.h it should
not rely on this in the future. The intent is
to move fs_config function into libcutils and
thus deprecate any need for sys/stat.h in this
include file.

Bug: 19908228
Change-Id: I5b10e9347aa9df8f0523a0ff00287655ca426d18

9 years agoMerge "Ril: Fix missing includes"
Andreas Gampe [Mon, 6 Apr 2015 19:47:54 +0000 (19:47 +0000)]
Merge "Ril: Fix missing includes"

9 years agoRil: Fix missing includes
Andreas Gampe [Mon, 6 Apr 2015 19:20:24 +0000 (12:20 -0700)]
Ril: Fix missing includes

umask requires sys/stat.h and sys/types.h.

Change-Id: Idc44976675c0f178bc860773e0bc1b65b392adcc

9 years agoMerge "Merge remote-tracking branch 'goog/mirror-m-wireless-internal-release'"
Vinit Deshpande [Mon, 16 Mar 2015 08:01:38 +0000 (08:01 +0000)]
Merge "Merge remote-tracking branch 'goog/mirror-m-wireless-internal-release'"

9 years agoMerge remote-tracking branch 'goog/mirror-m-wireless-internal-release'
Vinit Deshpande [Mon, 16 Mar 2015 08:01:02 +0000 (01:01 -0700)]
Merge remote-tracking branch 'goog/mirror-m-wireless-internal-release'

9 years agoAdd sap-api.proto.
Wink Saville [Wed, 21 May 2014 03:26:23 +0000 (20:26 -0700)]
Add sap-api.proto.

Change-Id: Ia526b1c872e5a3b298613387f58ee2aec6d7983c

9 years agoTelephony: Implementation of IWLAN.
Yashdev Singh [Mon, 23 Feb 2015 21:04:28 +0000 (13:04 -0800)]
Telephony: Implementation of IWLAN.

- Introduce IWLAN RAT in ril.h

Change-Id: Iaea12214b8333c6b6a56879c4d3b9417e3c24082

9 years agoAdd sap-api.proto.
Wink Saville [Wed, 21 May 2014 03:26:23 +0000 (20:26 -0700)]
Add sap-api.proto.

Change-Id: Ia526b1c872e5a3b298613387f58ee2aec6d7983c

9 years agoTelephony: Implementation of IWLAN.
Yashdev Singh [Mon, 23 Feb 2015 21:04:28 +0000 (13:04 -0800)]
Telephony: Implementation of IWLAN.

- Introduce IWLAN RAT in ril.h

Change-Id: Iaea12214b8333c6b6a56879c4d3b9417e3c24082

9 years agoam 4f481a54: Merge "Fix missing extern."
Elliott Hughes [Fri, 20 Feb 2015 19:04:57 +0000 (19:04 +0000)]
am 4f481a54: Merge "Fix missing extern."

* commit '4f481a5442c8269440dfbe99459b554e64071259':
  Fix missing extern.

9 years agoMerge "Fix missing extern."
Elliott Hughes [Fri, 20 Feb 2015 19:00:58 +0000 (19:00 +0000)]
Merge "Fix missing extern."

9 years agoFix missing extern.
Elliott Hughes [Fri, 20 Feb 2015 18:52:14 +0000 (10:52 -0800)]
Fix missing extern.

Change-Id: Iaf7c85b49350e0716d40edb36129714ca47fdb11

9 years agoam cb6cd1fb: Merge "ril.cpp: fix misuse of strncat"
Nick Kralevich [Tue, 10 Feb 2015 16:54:01 +0000 (16:54 +0000)]
am cb6cd1fb: Merge "ril.cpp: fix misuse of strncat"

* commit 'cb6cd1fba71fc8f12907b3c66cc7f5fa4de99589':
  ril.cpp: fix misuse of strncat

9 years agoMerge "ril.cpp: fix misuse of strncat"
Nick Kralevich [Tue, 10 Feb 2015 02:39:34 +0000 (02:39 +0000)]
Merge "ril.cpp: fix misuse of strncat"

9 years agoril.cpp: fix misuse of strncat
Nick Kralevich [Sun, 8 Feb 2015 15:54:16 +0000 (07:54 -0800)]
ril.cpp: fix misuse of strncat

strncat(dest,src,size) appends size+1 bytes to the end of
dest, so sizeof(dest) must be greater than
strlen(dest) + size + 1. Passing the buffer size to strncat
instead of sizeof(dest) - strlen(dest) - 1 is a common
strncat bug. Use strlcat instead, as it has more intuitive
behavior and ensures the buffer is properly null terminated.

Addresses the following compiler warning:

  In file included from system/core/include/cutils/sockets.h:22:0,
                   from hardware/ril/libril/ril.cpp:24:
  In function 'char* strncat(char*, const char*, size_t)',
      inlined from 'void android::RIL_register(const RIL_RadioFunctions*)' at hardware/ril/libril/ril.cpp:4258:62:
  bionic/libc/include/string.h:199:61: warning: call to char* __builtin___strncat_chk(char*, const char*, unsigned int, unsigned int) might overflow destination buffer
       return __builtin___strncat_chk(dest, src, n, __bos(dest));
                                                             ^

(line numbers are from internal master and do not match AOSP)

Even with this change, this code feels weird.
MAX_DEBUG_SOCKET_NAME_LENGTH is 12, and rildebug is initialized to be
SOCKET_NAME_RIL_DEBUG ("rild-debug"), which is 11 bytes including null
terminator. The strlcat call here can append a maximum of 1 byte before
the buffer is full. I don't know if this is intended or not.

Change-Id: I49801ad1ea3aa6173bbc9fd7cf00f3d308693253

9 years agoam d8dcd06e: Merge "Removal of dead code and adding log messages to make it easier...
Nick Kralevich [Sun, 8 Feb 2015 15:45:25 +0000 (15:45 +0000)]
am d8dcd06e: Merge "Removal of dead code and adding log messages to make it easier for debugging"

* commit 'd8dcd06e4703dae1927020cbcbafd85226492946':
  Removal of dead code and adding log messages to make it easier for debugging

9 years agoMerge "Removal of dead code and adding log messages to make it easier for debugging"
Nick Kralevich [Sun, 8 Feb 2015 15:32:53 +0000 (15:32 +0000)]
Merge "Removal of dead code and adding log messages to make it easier for debugging"

9 years agoRemoval of dead code and adding log messages to make it easier
Nanik Tolaram [Tue, 3 Feb 2015 01:50:04 +0000 (12:50 +1100)]
Removal of dead code and adding log messages to make it easier
for debugging

- Add more logging using ALOGD(..) for function dispatchSmsWrite,
dispatchDial, dispatchSIM_IO, dispatchSIM_APDU, dispatchCallForward,
dispatchRaw and dispatchCdmaSmsAck. To make it easier for debugging.

- Remove commented log message inside wakeTimeoutCallback () function
and remove the else clause as it's dead not used for anything.

- Modify log message inside removeFromList and removeWatch using +
and - to make it consistent with the other log message.

Change-Id: Ife0212e6a4724d8b06a1dd767484bfdf98b8e1a6
Signed-off-by: Nanik Tolaram <nanikjava@gmail.com>
9 years agoam 7c306fd5: Merge "rild: enable tombstone on RIL crash"
Nick Kralevich [Fri, 23 Jan 2015 22:18:11 +0000 (22:18 +0000)]
am 7c306fd5: Merge "rild: enable tombstone on RIL crash"

* commit '7c306fd58062476e53d3f424b4b7a5797069c235':
  rild: enable tombstone on RIL crash

9 years agoMerge "rild: enable tombstone on RIL crash"
Nick Kralevich [Fri, 23 Jan 2015 21:45:46 +0000 (21:45 +0000)]
Merge "rild: enable tombstone on RIL crash"

9 years agorild: enable tombstone on RIL crash
Julien Vuillaumier [Thu, 22 Jan 2015 13:42:58 +0000 (13:42 +0000)]
rild: enable tombstone on RIL crash

Since Android L, process dumpable flag is verified in case of
crash before requesting tombstone capture by debuggerd.
As setuid operation clears dumpable flag for a process, reenable
flag in rild after its switch to UID radio (debuggable build only)

Change-Id: Id86b697e2a1e11744ccc50a3c9ef04faf079ed94

9 years agoam 97f1dafc: Merge "Remove makefile cruft."
Elliott Hughes [Fri, 9 Jan 2015 23:52:04 +0000 (23:52 +0000)]
am 97f1dafc: Merge "Remove makefile cruft."

* commit '97f1dafc0cd3de51127477b8a0650883c0e657e8':
  Remove makefile cruft.

9 years agoam bdfdd776: Merge "We have POSIX clocks."
Elliott Hughes [Fri, 9 Jan 2015 23:46:05 +0000 (23:46 +0000)]
am bdfdd776: Merge "We have POSIX clocks."

* commit 'bdfdd7761d9f79c9e55a40f818781a69b01848ad':
  We have POSIX clocks.

9 years agoMerge "Remove makefile cruft."
Elliott Hughes [Fri, 9 Jan 2015 23:42:52 +0000 (23:42 +0000)]
Merge "Remove makefile cruft."

9 years agoMerge "We have POSIX clocks."
Elliott Hughes [Fri, 9 Jan 2015 23:39:28 +0000 (23:39 +0000)]
Merge "We have POSIX clocks."

9 years agoRemove makefile cruft.
Elliott Hughes [Fri, 9 Jan 2015 23:29:59 +0000 (15:29 -0800)]
Remove makefile cruft.

Change-Id: Iec07669cc80de041379716c8daa33acc58f7283e

9 years agoWe have POSIX clocks.
Elliott Hughes [Fri, 9 Jan 2015 23:27:28 +0000 (15:27 -0800)]
We have POSIX clocks.

We're probably not running the RIL on a Mac.

Change-Id: Ib6be56cd26d67e2b72b559cb364b1e34ab613016

9 years agoam 257ba4e3: Merge "Modify RIL_Data_Call_Response to include MTU" into lmp-mr1-dev
Robert Greenwalt [Tue, 9 Dec 2014 00:18:09 +0000 (00:18 +0000)]
am 257ba4e3: Merge "Modify RIL_Data_Call_Response to include MTU" into lmp-mr1-dev

* commit '257ba4e389b21e0b56510017d60e90753cb074c1':
  Modify RIL_Data_Call_Response to include MTU

9 years agoMerge "Modify RIL_Data_Call_Response to include MTU" into lmp-mr1-dev
Robert Greenwalt [Mon, 8 Dec 2014 23:33:48 +0000 (23:33 +0000)]
Merge "Modify RIL_Data_Call_Response to include MTU" into lmp-mr1-dev

9 years agoModify RIL_Data_Call_Response to include MTU
Sukanya Rajkhowa [Mon, 2 Jun 2014 21:03:44 +0000 (14:03 -0700)]
Modify RIL_Data_Call_Response to include MTU

Include MTU as part of RIL Data Call Response so that the
framework uses the dynamic MTU value provided by network
and updates LinkProperties accordingly.

Upping RIL version to 11.

bug:18391670
Change-Id: I8a85d7f58c99d73278646cdcb2aa466b85ae9a81

9 years agoam 496a71cf: Merge "Revert "Revert "STK Call Control feature implementation.""" into...
Amit Mahajan [Mon, 24 Nov 2014 18:06:20 +0000 (18:06 +0000)]
am 496a71cf: Merge "Revert "Revert "STK Call Control feature implementation.""" into lmp-mr1-dev

* commit '496a71cfd58fb10b621a6e1b3205929908bcd86d':
  Revert "Revert "STK Call Control feature implementation.""

9 years agoMerge "Revert "Revert "STK Call Control feature implementation.""" into lmp-mr1-dev
Amit Mahajan [Sun, 23 Nov 2014 23:17:11 +0000 (23:17 +0000)]
Merge "Revert "Revert "STK Call Control feature implementation.""" into lmp-mr1-dev

9 years agoam 5526d659: Merge "Turn off RILC REQUEST logging" into lmp-mr1-dev
xinhe [Sat, 22 Nov 2014 02:33:36 +0000 (02:33 +0000)]
am 5526d659: Merge "Turn off RILC REQUEST logging" into lmp-mr1-dev

* commit '5526d659ed3fe69d57317044d04438b28286e3b2':
  Turn off RILC REQUEST logging

9 years agoRevert "Revert "STK Call Control feature implementation.""
Amit Mahajan [Sat, 22 Nov 2014 00:54:49 +0000 (00:54 +0000)]
Revert "Revert "STK Call Control feature implementation.""

This reverts commit 6bfaf64c427b4d48a4fb1931eb8b5c0f79ce20f1.

Change-Id: Ib408f7ef0db0e0fd6a6d501d565726733440b156

9 years agoMerge "Turn off RILC REQUEST logging" into lmp-mr1-dev
xinhe [Fri, 21 Nov 2014 23:38:08 +0000 (23:38 +0000)]
Merge "Turn off RILC REQUEST logging" into lmp-mr1-dev

9 years agoTurn off RILC REQUEST logging
xinhe [Fri, 21 Nov 2014 19:16:40 +0000 (11:16 -0800)]
Turn off RILC REQUEST logging

remove the log

Bug:18481571
Change-Id: I8cc27ab3528904113fc4678f2f6c96f702c55ce2

9 years agoam 6bfaf64c: Revert "STK Call Control feature implementation."
Amit Mahajan [Wed, 19 Nov 2014 02:26:56 +0000 (02:26 +0000)]
am 6bfaf64c: Revert "STK Call Control feature implementation."

* commit '6bfaf64c427b4d48a4fb1931eb8b5c0f79ce20f1':
  Revert "STK Call Control feature implementation."

9 years agoRevert "STK Call Control feature implementation."
Amit Mahajan [Wed, 19 Nov 2014 00:06:53 +0000 (00:06 +0000)]
Revert "STK Call Control feature implementation."

This reverts commit 61bedcf4f339fb2eecb2e50bbd5637d0b70a9004.

Change-Id: I257968ecc3c5e18f3b9cd6371e76846676c82447

9 years agoam 61bedcf4: STK Call Control feature implementation.
Preeti Ahuja [Tue, 18 Nov 2014 21:56:16 +0000 (21:56 +0000)]
am 61bedcf4: STK Call Control feature implementation.

* commit '61bedcf4f339fb2eecb2e50bbd5637d0b70a9004':
  STK Call Control feature implementation.

9 years agoam f34ed01f: Merge "Make the implementations of RIL_onUnsolicitedResponse match the...
Chih-hung Hsieh [Tue, 18 Nov 2014 00:41:06 +0000 (00:41 +0000)]
am f34ed01f: Merge "Make the implementations of RIL_onUnsolicitedResponse match the prototypes"

* commit 'f34ed01f1e1935c67e153916ea27dddae4d067dc':
  Make the implementations of RIL_onUnsolicitedResponse match the prototypes

9 years agoMerge "Make the implementations of RIL_onUnsolicitedResponse match the prototypes"
Chih-hung Hsieh [Tue, 18 Nov 2014 00:30:41 +0000 (00:30 +0000)]
Merge "Make the implementations of RIL_onUnsolicitedResponse match the prototypes"

9 years agoMake the implementations of RIL_onUnsolicitedResponse match the prototypes
Bernhard Rosenkränzer [Mon, 17 Nov 2014 19:52:09 +0000 (20:52 +0100)]
Make the implementations of RIL_onUnsolicitedResponse match the prototypes

Prototypes expect the data as a const void*, whereas the implementation
takes a void*.

This causes the build to break with clang and may also have other
unexpected side effects. (I'd expect to see unresolvable references in
some gcc builds.)

Change-Id: Ic34787da20abd2821730a18e49c0a435a82c2613
Signed-off-by: Bernhard Rosenkränzer <Bernhard.Rosenkranzer@linaro.org>
9 years agoSTK Call Control feature implementation.
Preeti Ahuja [Tue, 15 Nov 2011 20:52:06 +0000 (12:52 -0800)]
STK Call Control feature implementation.

Add support for unsols for Stk Call Control
feature.

Bug: 17646476
Change-Id: I65e8e65e514f00e171086496d86b0c825d3d3d3e

9 years agoam 8caf06fd: [DS] Radio Capability Support. New design of capability switch for L.
Legler Wu [Fri, 31 Oct 2014 00:16:40 +0000 (00:16 +0000)]
am 8caf06fd: [DS] Radio Capability Support. New design of capability switch for L.

* commit '8caf06fd90e877e6c0a4cc1e63bb5b5222704abe':
  [DS] Radio Capability Support. New design of capability switch for L.

9 years ago[DS] Radio Capability Support. New design of capability switch for L.
Legler Wu [Wed, 29 Oct 2014 06:02:14 +0000 (14:02 +0800)]
[DS] Radio Capability Support. New design of capability switch for L.

Modify for changing ModemID from int to string.

Change-Id: Ic5ac096c6335658c5557dd94d659f910f42c8ffb

9 years agoam 60dbcee8: am 760123fc: Fixing the comment for RIL_REQUEST_SIM_OPEN_CHANNEL.
Shishir Agrawal [Mon, 27 Oct 2014 04:21:14 +0000 (04:21 +0000)]
am 60dbcee8: am 760123fc: Fixing the comment for RIL_REQUEST_SIM_OPEN_CHANNEL.

* commit '60dbcee88f599e4ca48d7a4ef4d3ce940f0826cd':