diff options
| author | David Lechner <[email protected]> | 2026-06-11 18:36:10 -0500 |
|---|---|---|
| committer | Jerome Forissier <[email protected]> | 2026-06-23 13:13:16 +0200 |
| commit | 9f7906a58cf194fc43484f5be4b65e368fa59040 (patch) | |
| tree | 7ba5fcdc3fc8c6ff43c3268fe87f50ae7f714a5f /include | |
| parent | 91911aa0c76e641e673999111fc0aec1fe75b6d2 (diff) | |
net: lwip: introduce net_lwip_eth_stop() function
Add a introduce net_lwip_eth_stop() function and use that to stop the
network interface after each command that uses the network.
This makes the behavior the same as the legacy net code and avoids
potential issues with the network interface being left in an active
state after a command finishes.
The start/stop is reference-counted since there is at least one command
(dhcp) that calls another command (tftp) to avoid starting and stopping
the network interface multiple times in a single command.
Signed-off-by: David Lechner <[email protected]>
Reviewed-by: Jerome Forissier <[email protected]>
Diffstat (limited to 'include')
| -rw-r--r-- | include/net-lwip.h | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/include/net-lwip.h b/include/net-lwip.h index 20cb0992cce..5d0627eb271 100644 --- a/include/net-lwip.h +++ b/include/net-lwip.h @@ -35,6 +35,7 @@ int eth_init_state_only(void); /* Set active state */ int net_lwip_dns_init(void); int net_lwip_eth_start(void); +void net_lwip_eth_stop(void); struct netif *net_lwip_new_netif(struct udevice *udev); struct netif *net_lwip_new_netif_noip(struct udevice *udev); void net_lwip_remove_netif(struct netif *netif); |
