util: Add BlacklistUtils

Change-Id: Id29990bd95f20f7a3b4eae4e0419f1569d3614c1
Telephony: Add blacklist elements

Change-Id: Icc42a16e13a52c207d2684326adbfaceb639b521
Fix RIL_UNSOL_CDMA_PRL_CHANGED constant typo (2/2)

Change-Id: If3ff32a3974368d9ea2756d3d9a22d4713e704fa
opt/telephony: Fix compile on JDK7

UNEXPECTED TOP-LEVEL EXCEPTION:
com.android.dx.util.ExceptionWithContext
        at
com.android.dx.util.ExceptionWithContext.withContext(ExceptionWithContext.java:46)
        at com.android.dx.dex.cf.CfTranslator.processMethods(CfTranslator.java:344)
        at com.android.dx.dex.cf.CfTranslator.translate0(CfTranslator.java:134)
        at com.android.dx.dex.cf.CfTranslator.translate(CfTranslator.java:87)
        at com.android.dx.command.dexer.Main.processClass(Main.java:487)
        at com.android.dx.command.dexer.Main.processFileBytes(Main.java:459)
        at com.android.dx.command.dexer.Main.access$400(Main.java:67)
        at com.android.dx.command.dexer.Main$1.processFileBytes(Main.java:398)
        at com.android.dx.cf.direct.ClassPathOpener.processArchive(ClassPathOpener.java:245)
        at com.android.dx.cf.direct.ClassPathOpener.processOne(ClassPathOpener.java:131)
        at com.android.dx.cf.direct.ClassPathOpener.process(ClassPathOpener.java:109)
        at com.android.dx.command.dexer.Main.processOne(Main.java:422)
        at com.android.dx.command.dexer.Main.processAllFiles(Main.java:333)
        at com.android.dx.command.dexer.Main.run(Main.java:209)
        at com.android.dx.command.dexer.Main.main(Main.java:174)
        at com.android.dx.command.Main.main(Main.java:91)
Caused by: java.lang.NullPointerException
        at com.android.dx.cf.code.ConcreteMethod.<init>(ConcreteMethod.java:87)
        at com.android.dx.cf.code.ConcreteMethod.<init>(ConcreteMethod.java:75)
        at com.android.dx.dex.cf.CfTranslator.processMethods(CfTranslator.java:247)
        ... 14 more
...while processing <init> (Lcom/android/internal/telephony/gsm/GSMPhone;)V
...while processing com/android/internal/telephony/gsm/GSMPhone$1.class

Change-Id: If39b2067c9190f0f3ed6cd3bb909ccc3201262cb
telephony: Add RILJ wakelock debugging

Patch originally made by Lee Chu against CM10 for the SMDK4210 RIL

Reworked to provide generic RILJ wakelock debugging for all devices

This causes the log to get spammed if an outstanding unresponded RIL request
is causing extended wakelocks.  The wakelock timer is reset every time a new
RIL request gets issued, causing the timeout to reset for "older" requests.

End result is an ongoing RILJ wakelock if the RIL doesn't respond to something.

Rather than purge the offending item, we spam the logs, since a lack of a RIL
response is usually due to a bug on our end.  (e.g. sending a request we should
not.)

Original commit at:
https://github.com/CyanogenMod/android_frameworks_base/commit/44a77728d6576d66ee873d18f72caed8c4cb2732

Change-Id: I2c7c337b9e0b1dba76a13bc40d7319ae0d1ea917
Allow a device to include its own RIL subclass

For cases where a single device needs a subclass, there's no need to
pollute the common core with it: just stick it in the device's own
repository, and add something like
"BOARD_RIL_CLASS := ../../../device/manuf/model/ril/" to the BoardConfig

Change-Id: I9d01ceb6e5587382eb216341e2e373ec0c52848f
telephony: Use reflection to create command interface (RIL class)

Change-Id: Icdc02eaa74b89dbde4ddfb989cc62481d6423312
RIL: Make RIL subclassable

Change-Id: Ibef500b32f4be460c385519a823e7d8513e816e2
fw_opt_telephony: Fix RIL for all Samsung devices

By SferaDev and jakew02

Add Samsung RIL files from CM

Fix dependencies and errors at RIL.java

Create Operators.java

RIL: Add compatibility with qcom's DSDS:
Devices with radio libraries built against a DSDS-enabled qualcomm
BSP (anything in the last 4 or 5 months, apparently) have a slight
incompatibility in the RIL protocol: it expects the first 4 bytes
of the datastream to be the slot's identification (even if the
device isn't dual-SIM). Absence of those 4 bytes will make the
connection hang.

Change-Id: Ie5894e4cf639b57b0e44bf63d6abb414448e9da0
telephony: DataConnection: support old RILs

Older RILs require different technology value

Change-Id: I0249bb597e2592b7e951945bc97d144ee2b2307a
telephony: Sanitize subclassing RILs

Avoid copypasting loads of unchanged code
Splitted processSolicited method.
Added bit of Samcrappyness into main RIL class.

Change-Id: I65f476544a8c84601ea827427f91e99bec6ea201
Telephony: introduce CDMA class for HTC M7

Change-Id: Id1f2fe73ec09435576ec9befe8526f200071426c
RIL: squashed support for old RIL

	commit 6536e023ed1523b6184da5d5704570fb3e24f01a
	Author: Emilio López <turl@tuxfamily.org>
	Date:   Fri Oct 12 16:45:29 2012 +0000

	    telephony: let us write just the aid on getIMSIForApp

	    This implements a new RIL compatibility feature, "writeaidonly", that
	    lets us write just the aid, without the preceding 1. This is needed to
	    be able to read the IMSI correctly on some Motorola RILs

	    Change-Id: I48e9d76db6730571c01d59313fc7a5e79845f922

	commit e470d722cc6fc5705d6e407a90f34692f019129f
	Author: Hashcode <hashcode0f@gmail.com>
	Date:   Mon Sep 24 11:29:48 2012 -0700

	    ril: avoid sending null aid string in getIMSI

	    A change to how getIMSI works in JB causes null aid strings
	    to be sent.  The result for RILs older than v7 is a corrupt
	    ril response in SIMRecords::fetchSimRecords.  This corruption
	    ends up setting mImsi to null (in SIMRecords) and that causes
	    havoc w/ 3g/4g data connections.

	    This patch avoids sending null aid strings and has fixed
	    data connection issues on several Motorola devices.

	    This new patch is implemented as an opt-in old ril feature

	    Change-Id: I6682ea10c8b216e2adc5abffbcc50f3cb6c9d7b8

	commit 16cd02ad6f9679ed5895d53e9d07fef3ee9d3240
	Author: Robert Burns <burnsra@gmail.com>
	Date:   Tue Sep 25 09:33:24 2012 -0400

	    Revert "ril: avoid sending null aid string in getIMSI"

	    This reverts commit 4b785569b338d150dccdb5bb6d3a290b068e603c.

	    This change has been verified as breaking network for toro/toroplus.

	    Change-Id: I74e43acd10d4b38e149acf55e08537430f871139

	commit 814e909c879621101640128fe0a0c9f0ad2ef504
	Author: codeworkx <codeworkx@cyanogenmod.com>
	Date:   Tue Sep 25 13:06:15 2012 +0200

	    ril: dedup mRilVer

	    Change-Id: I665b5c1c502d3cc49d2b3343a2e9eafc8b8e5a77

	commit 69292881c8c120c90852d306a5c312a07dd19c10
	Author: codeworkx <codeworkx@cyanogenmod.com>
	Date:   Tue Sep 25 02:51:18 2012 +0200

	    fix build: add missing instance variable mRilVer

	    Fixes commit 4b785569b338d150dccdb5bb6d3a290b068e603c

	    Change-Id: Id239285aff6997eaa42521b695b6812029f580c1

	commit 4b785569b338d150dccdb5bb6d3a290b068e603c
	Author: Hashcode <hashcode0f@gmail.com>
	Date:   Mon Sep 24 11:29:48 2012 -0700

	    ril: avoid sending null aid string in getIMSI

	    A change to how getIMSI works in JB causes null aid strings
	    to be sent.  The result for RILs older than v7 is a corrupt
	    ril response in SIMRecords::fetchSimRecords.  This corruption
	    ends up setting mImsi to null (in SIMRecords) and that causes
	    havoc w/ 3g/4g data connections.

	    This patch avoids sending null aid strings and has fixed
	    data connection issues on several Motorola devices.

	    Change-Id: Ic1fc363e35d79793c48d19080a2e028e428b888f

	commit 154221766ac6bcb1c0af549377e65a8c8ec5d0a0
	Author: Ethan Chen <intervigil@gmail.com>
	Date:   Mon Sep 3 01:21:04 2012 -0700

	    RIL: make data call APN a selectable RIL feature

	    Disabling this for all RIL versions above 3 can cause issues with some
	    device RILs and establishing a data connection.

	    Change-Id: I7be41b120663b0839beec95c22d0615f5e79c582

	commit d76a3247a3547e7c7a95a13db7cfa1ec2a061f3d
	Author: Mike Kasick <mike@kasick.org>
	Date:   Thu Aug 30 13:42:27 2012 -0400

	    RILs: Eliminate repeated overrides of responseOperatorInfos.

	    - Add mQANElements field, default to 4 in RIL, use in responseOperatorInfos.
	      This may be set to 5 in subclassed RIL constructors.

	    - Remove repeated overrides of responseOperatorInfos by subclassed RILs, as
	      there's no logic change, just a disagreement as to whether the
	      QUERY_AVAILABLE_NETWORKS response is an array with 4 or 5 per-network
	      elements.

	    - Size OperatorInfo ArrayList appropriately in SemcRIL and SonyQualcommRIL.

	    Change-Id: I1254a670d8611f76aad13a6f197c67012c7d4c47

	commit b40a14246e50429d91e603a64d6baac7813699d1
	Author: Janne Grunau <j@jannau.net>
	Date:   Tue Aug 14 22:32:08 2012 +0200

	    RIL: fix protocol mismatch for DataConnectionState_v4

	    The apn got dropped in DataConnectionState v4.

	    Avoids UnknownHostExceptions in DataCallState.setLinkProperties().

	    Change-Id: Icd0a1ba1c77cead13b15b3749965edead5f59135

	commit 431c19a5ef39003383de3fc44c636f8d03e74a17
	Author: isimobile <isimobile@ismaakit.com>
	Date:   Wed Jan 11 21:34:47 2012 +0200

	    telephony: Added support for use of Honeycomb Radio (Modem).

	    -squashed (RIL: reference ICS and GB):
	    https://github.com/isimobile/android_frameworks_base/commit/7507127287aa8cf84b5e811977d95400b029f95b
	    https://github.com/isimobile/android_frameworks_base/commit/af2b84d1860b38952784ae116172e00a4b445a1d
	    https://github.com/isimobile/android_frameworks_base/commit/872156a81fb4185217e7642d10ec33da4893a2b3
	    https://github.com/isimobile/android_frameworks_base/commit/400bbc4e3ce8e9e0219b31bb985e6628c50d0f07
	    https://github.com/isimobile/android_frameworks_base/commit/7cb289d9e59ac69350dd2377eff63940641df603

	    -cleaned up some whitespace

	    Change-Id: I3a3474245bb336bc3f275605648f5f94f3f9b6e7

	    Conflicts:

	    	telephony/java/com/android/internal/telephony/DataConnection.java

	commit 87ee134d8a0a09ff5c824450969207fa66531f2f
	Author: Emilio López <turl@tuxfamily.org>
	Date:   Thu Dec 1 21:35:21 2011 +0000

	    RIL: skip broken RIL_UNSOL_DATA_CALL_LIST_CHANGED

	    Some old RILs might produce events with type 'IP' containing the remote IP
	    address, normally 10.64.64.64. These events mismatch with the previously
	    generated ones and cause the system to take the connection down, even if
	    it was up and working correctly.

	    Add skipbrokendatacall to ro.telephony.ril.v3 to enable the workaround.

	    Change-Id: I3bc3c84735201a797011aafba2718638a826f31d

	commit b2cfc6f82f75fe47e5ca66ac7ee5bab1740f4a45
	Author: Tom Giordano <tomgiordano83@gmail.com>
	Date:   Mon Nov 28 02:51:53 2011 +1100

	    v3 RIL: another getDataCallState fix

	    Change-Id: Ie4e69e231956f46bc1b82550fdf4863c1367efaf

	commit 16330ce5c921792115bc796a3229057491524915
	Author: Pawit Pornkitprasan <p.pawit@gmail.com>
	Date:   Sun Nov 27 09:17:19 2011 +0700

	    v3 RIL: Fix getDataCallState and PIN setting

	    Change-Id: Icf5cee33aeec58cffb23430f0f7b06b9971a71ad

	commit 3f730cc1055739dc4cbf53b44acf9c254c43a52b
	Author: Koushik Dutta <koushd@gmail.com>
	Date:   Fri Nov 25 17:23:58 2011 -0800

	    Break the legacy ril shims into specific features. The ICC feature breaks crespo, but crepso needs the signal strength feature.

	commit 6b09342ad9131754eeaa733364c2f4474a10bde7
	Author: Emilio López <turl@tuxfamily.org>
	Date:   Sun Nov 20 22:12:28 2011 +0000

	    RIL: handle the lack of version gracefully on older RILs

	    Change-Id: I8227c55968f502112c5b6ac334eee505c29924c2

	commit 913255a820cfcb99a6d89ca036eba53c110adea2
	Author: Kolja Dummann <k.dummann@gmail.com>
	Date:   Mon Nov 21 22:27:45 2011 +0100

	    RIL: fix pin unlock for old ril

	    Change-Id: I27eb348233d41618875473ca9bdb93d339c359f9

	commit 27b873d14816282bab22db8a5920ca01466d36d0
	Author: Ricardo Cerqueira <github@cerqueira.org>
	Date:   Thu Nov 17 11:16:23 2011 +0000

	    RIL: Support signal strength format from v3 vendor RILs

	    Enable by setting property ro.telephony.ril.v3=1

Change-Id: I2eb23ab5d17d15ed71e5777dcd368d47c87e29ef

Conflicts:
	src/java/com/android/internal/telephony/CommandsInterface.java
	src/java/com/android/internal/telephony/RIL.java
	src/java/com/android/internal/telephony/sip/SipCommandInterface.java
	src/java/com/android/internal/telephony/test/SimulatedCommands.java

Change-Id: Ie84aa61964f8af35673536efba7b433f273fd248