Skip to content

Commit 4b93835

Browse files
krishna Tkrish2718
authored andcommitted
[nrf noup] zephyr: Restart DHCP for every association
After every successful association, restart DHCP to get a fresh lease. For the initial association this avoid delay due to DHCP exponential retries, and also handles the case where interface has changed IP subnet. Signed-off-by: Krishna T <[email protected]>
1 parent df25844 commit 4b93835

File tree

1 file changed

+1
-3
lines changed

1 file changed

+1
-3
lines changed

src/drivers/driver_zephyr.c

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1277,9 +1277,7 @@ static int wpa_drv_zep_set_supp_port(void *priv,
12771277

12781278
#ifdef CONFIG_NET_DHCPV4
12791279
if (authorized) {
1280-
net_dhcpv4_stop(iface);
1281-
k_msleep(500);
1282-
net_dhcpv4_start(iface);
1280+
net_dhcpv4_restart(iface);
12831281
}
12841282
#endif
12851283

0 commit comments

Comments
 (0)