sierra: early detect non-AT ports
Detect the parser filter errors during our custom_init(), and set the port as not being AT if the error found.
This commit is contained in:
@@ -86,6 +86,12 @@ gcap_ready (MMAtSerialPort *port,
|
||||
g_error_matches (error, MM_SERIAL_ERROR, MM_SERIAL_ERROR_RESPONSE_TIMEOUT)) {
|
||||
mm_port_probe_set_result_at (ctx->probe, FALSE);
|
||||
}
|
||||
/* If reported a hard parse error, this port is definitely not an AT
|
||||
* port, skip trying. */
|
||||
else if (g_error_matches (error, MM_SERIAL_ERROR, MM_SERIAL_ERROR_PARSE_FAILED)) {
|
||||
mm_port_probe_set_result_at (ctx->probe, FALSE);
|
||||
ctx->retries = 0;
|
||||
}
|
||||
|
||||
/* Just retry... */
|
||||
sierra_custom_init_step (ctx);
|
||||
|
Reference in New Issue
Block a user