[PATCH 1/2] Provide mechansim to disable PIN2 on QMI modems

Aleksander Morgado aleksander at aleksander.es
Mon Sep 15 06:07:01 PDT 2014


On Mon, Sep 15, 2014 at 1:10 PM, David McCullough
<david.mccullough at accelecon.com> wrote:
>
> Some modems report PIN2 support via QMI even though they do not actually
> support PIN2.  Here is a snippet of debug on the Sierra Wireless MC7354
> sghowing this.  mmcli would incorrectly report PIN unlocking errors.
>

The thing here is that some modems may report PIN2-locked, which is
true, BUT which doesn't prevent going on with enabling the modem and
getting a connection. ModemManager handles this case already, by
ensuring that even if the modem says it is PIN2-locked, the modem
state doesn't got to LOCKED.

In your case you have PIN1 disabled, PIN2 locked, so the modem will
(should) directly go to the DISABLED state when it's detected.

If instead you have PIN1 enabled you'll get PIN1-locked first (so
modem will go to LOCKED until PIN1 is unlocked), and once that happens
it will go to PIN2 locked (so DISABLED).

All modems in DISABLED state can all directly be ENABLED with Enable().

Note that UnlockRequired property will still say PIN2; even if it went
into DISABLED state.


>     <debug> [1410404595.230075] [mm-broadband-modem-qmi.c:1535] modem_load_unlock_required(): loading unlock required...
>     [/dev/cdc-wdm0] Sent message...
>     <<<<<< RAW:
>     <<<<<<   length = 13
>     <<<<<<   data   = 01:0C:00:00:02:02:00:09:00:2B:00:00:00
>     [/dev/cdc-wdm0] Sent message (translated)...
>     <<<<<< QMUX:
>     <<<<<<   length  = 12
>     <<<<<<   flags   = 0x00
>     <<<<<<   service = "dms"
>     <<<<<<   client  = 2
>     <<<<<< QMI:
>     <<<<<<   flags       = "none"
>     <<<<<<   transaction = 9
>     <<<<<<   tlv_length  = 0
>     <<<<<<   message     = "UIM Get PIN Status" (0x002B)
>     [/dev/cdc-wdm0] Received message...
>     >>>>>> RAW:
>     >>>>>>   length = 32
>     >>>>>>   data   = 01:1F:00:80:02:02:02:09:00:2B:00:13:00:02:04:00:00:00:00:00:12:03:00:01:03:0A:11:03:00:03:03:0A
>     [/dev/cdc-wdm0] Received message (translated)...
>     >>>>>> QMUX:
>     >>>>>>   length  = 31
>     >>>>>>   flags   = 0x80
>     >>>>>>   service = "dms"
>     >>>>>>   client  = 2
>     >>>>>> QMI:
>     >>>>>>   flags       = "response"
>     >>>>>>   transaction = 9
>     >>>>>>   tlv_length  = 19
>     >>>>>>   message     = "UIM Get PIN Status" (0x002B)
>     >>>>>> TLV:
>     >>>>>>   type       = "Result" (0x02)
>     >>>>>>   length     = 4
>     >>>>>>   value      = 00:00:00:00
>     >>>>>>   translated = SUCCESS
>     >>>>>> TLV:
>     >>>>>>   type       = "PIN2 Status" (0x12)
>     >>>>>>   length     = 3
>     >>>>>>   value      = 01:03:0A
>     >>>>>>   translated = [ current_status = 'enabled-not-verified' verify_retries_left = '3' unblock_retries_left = '10' ]
>     >>>>>> TLV:
>     >>>>>>   type       = "PIN1 Status" (0x11)
>     >>>>>>   length     = 3
>     >>>>>>   value      = 03:03:0A
>     >>>>>>   translated = [ current_status = 'disabled' verify_retries_left = '3' unblock_retries_left = '10' ]
>

Ok, so this is good. We get PIN1 disabled and PIN2 locked. The modem
should go into DISABLED state right just after being detected.

Isn't this the case?

-- 
Aleksander
https://aleksander.es


More information about the ModemManager-devel mailing list