drivers: ppp: Enable PPP interface when connection is ready

By default PPP interface is not taken up automatically but only
after the PPP connection to modem is ready.

Signed-off-by: Jukka Rissanen <jukka.rissanen@linux.intel.com>
This commit is contained in:
Jukka Rissanen 2020-04-01 12:49:48 +03:00
parent 420b195b5e
commit 900c0e1c7f

View file

@ -680,6 +680,13 @@ use_random_mac:
if (!IS_ENABLED(CONFIG_NET_TEST)) {
uart_pipe_register(ppp->buf, sizeof(ppp->buf), ppp_recv_cb);
}
/* If we have a GSM modem with PPP support, then do not start the
* interface automatically but only after the modem is ready.
*/
if (IS_ENABLED(CONFIG_MODEM_GSM_PPP)) {
net_if_flag_set(iface, NET_IF_NO_AUTO_START);
}
}
#if defined(CONFIG_NET_STATISTICS_PPP)