include: Add functions needed by MTK driver

Due to the way the current MTK device plugin handles creation of
atoms, some modem state transitions cannot be handled directly by
the core. This change adds a new function that can be used by a
device plugin to prevent the modem core code from setting the modem
state to PRE-SIM when a SIM lock condition is detected.
src: Implement functions needed by MTK driver

Due to the way the current MTK device plugin handles creation of
atoms, some modem state transitions cannot be handled directly by
the core. This change adds a new function that can be used by a
device plugin to prevent the modem core code from setting the modem
state to PRE-SIM when a SIM lock condition is detected.
mtk: Handle locking of the SIM

Atoms are destroyed when the SIM gets locked after introduction of
wrong password.
src: Check presence of spn_watches on removal

In some cases sim->spn_watches can already be NULL when trying to
remove the watches.
Merge pull request #118 from alfonsosanchezbeato/puk-locked-crash

Fix crash when the modem gets PUK locked
gril: Fix parsing of registration state replies

There were two bugs when parsing voice/data registration state replies:
the status value could be one not recognized by ofono and the max number
of call ids was not being set properly for MTK modems. This commit fixes
both issues.
unit: Add tests for more rild status codes
Merge pull request #120 from alfonsosanchezbeato/fix-empty-status

gril: Fix parsing of registration state replies
plugins: don't require MMS proxy

The current Ubuntu provisioning logic skips MMS
APNs that don't define an MMS proxy.  In fact,
the only required MMS attribute is the message
center.
Merge pull request #121 from tonyespy/lp1362008

plugins: don't require MMS proxy
gril: Add functions for reading a string array
gril: Separate parsing of registration replies

Previously, replies to RIL_REQUEST_VOICE_REGISTRATION_STATE and
RIL_REQUEST_DATA_REGISTRATION_STATE were parsed using the same
function. This change separates the parsing of these replies, as the
data that is different for each type could be eventually needed.
Additionally, state parsing has changed so now all RIL states are
mapped to valid ofono core status values and the right max_cids is
returned for MTK modems.
rilmodem: Adapt drivers to change in reply parsing

gprs and network drivers are affected by the change for separating
the parsing of the replies to data/voice registration state requests.
unit: Adapt to changes in reply parsing