<div dir="ltr">Hi, has this change already merged?</div><br><div class="gmail_quote"><div dir="ltr">On Fri, 13 May 2016 at 20:05 Aleksander Morgado <<a href="mailto:aleksander@aleksander.es">aleksander@aleksander.es</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">On Fri, May 13, 2016 at 5:15 PM, Carlo Lobrano <<a href="mailto:c.lobrano@gmail.com" target="_blank">c.lobrano@gmail.com</a>> wrote:<br>
> Inverted steps UPDATE_LOCK_INFO_CONTEXT_STEP_RETRIES and<br>
> UPDATE_LOCK_INFO_CONTEXT_STEP_AFTER_UNLOCK.<br>
><br>
> Soon after the unlock, the SIM can be busy and<br>
> loading unlock retries might fail.<br>
><br>
> When implemented, let run "after unlock" logic before any other step in<br>
> update lock info, when SIM is not locked this change does not have any<br>
> effect since "after unlock" is not executed.<br>
> ---<br>
<br>
Yeah, I think this makes sense.<br>
<br>
> src/mm-iface-modem.c | 32 ++++++++++++++++----------------<br>
> 1 file changed, 16 insertions(+), 16 deletions(-)<br>
><br>
> diff --git a/src/mm-iface-modem.c b/src/mm-iface-modem.c<br>
> index 516ed78..bbc76ae 100644<br>
> --- a/src/mm-iface-modem.c<br>
> +++ b/src/mm-iface-modem.c<br>
> @@ -2907,8 +2907,8 @@ update_unlock_retries (MMIfaceModem *self,<br>
> typedef enum {<br>
> UPDATE_LOCK_INFO_CONTEXT_STEP_FIRST = 0,<br>
> UPDATE_LOCK_INFO_CONTEXT_STEP_LOCK,<br>
> - UPDATE_LOCK_INFO_CONTEXT_STEP_RETRIES,<br>
> UPDATE_LOCK_INFO_CONTEXT_STEP_AFTER_UNLOCK,<br>
> + UPDATE_LOCK_INFO_CONTEXT_STEP_RETRIES,<br>
> UPDATE_LOCK_INFO_CONTEXT_STEP_LAST<br>
> } UpdateLockInfoContextStep;<br>
><br>
> @@ -3073,21 +3073,7 @@ update_lock_info_context_step (UpdateLockInfoContext *ctx)<br>
><br>
> /* Fall down to next step */<br>
> ctx->step++;<br>
> -<br>
> - case UPDATE_LOCK_INFO_CONTEXT_STEP_RETRIES:<br>
> - /* Load unlock retries if possible */<br>
> - if (MM_IFACE_MODEM_GET_INTERFACE (ctx->self)->load_unlock_retries &&<br>
> - MM_IFACE_MODEM_GET_INTERFACE (ctx->self)->load_unlock_retries_finish) {<br>
> - MM_IFACE_MODEM_GET_INTERFACE (ctx->self)->load_unlock_retries (<br>
> - ctx->self,<br>
> - (GAsyncReadyCallback)load_unlock_retries_ready,<br>
> - ctx);<br>
> - return;<br>
> - }<br>
> -<br>
> - /* Fall down to next step */<br>
> - ctx->step++;<br>
> -<br>
> +<br>
> case UPDATE_LOCK_INFO_CONTEXT_STEP_AFTER_UNLOCK:<br>
> /* If we get that no lock is required, run the after SIM unlock step<br>
> * in order to wait for the SIM to get ready. Skip waiting on<br>
> @@ -3113,6 +3099,20 @@ update_lock_info_context_step (UpdateLockInfoContext *ctx)<br>
> /* Fall down to next step */<br>
> ctx->step++;<br>
><br>
> + case UPDATE_LOCK_INFO_CONTEXT_STEP_RETRIES:<br>
> + /* Load unlock retries if possible */<br>
> + if (MM_IFACE_MODEM_GET_INTERFACE (ctx->self)->load_unlock_retries &&<br>
> + MM_IFACE_MODEM_GET_INTERFACE (ctx->self)->load_unlock_retries_finish) {<br>
> + MM_IFACE_MODEM_GET_INTERFACE (ctx->self)->load_unlock_retries (<br>
> + ctx->self,<br>
> + (GAsyncReadyCallback)load_unlock_retries_ready,<br>
> + ctx);<br>
> + return;<br>
> + }<br>
> +<br>
> + /* Fall down to next step */<br>
> + ctx->step++;<br>
> +<br>
> case UPDATE_LOCK_INFO_CONTEXT_STEP_LAST:<br>
> if (ctx->saved_error) {<br>
> /* Return saved error */<br>
> --<br>
> 2.1.4<br>
><br>
> _______________________________________________<br>
> ModemManager-devel mailing list<br>
> <a href="mailto:ModemManager-devel@lists.freedesktop.org" target="_blank">ModemManager-devel@lists.freedesktop.org</a><br>
> <a href="https://lists.freedesktop.org/mailman/listinfo/modemmanager-devel" rel="noreferrer" target="_blank">https://lists.freedesktop.org/mailman/listinfo/modemmanager-devel</a><br>
<br>
<br>
<br>
--<br>
Aleksander<br>
<a href="https://aleksander.es" rel="noreferrer" target="_blank">https://aleksander.es</a><br>
</blockquote></div>