summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorFelix Fietkau <nbd@nbd.name>2020-11-20 13:49:00 +0100
committerFelix Fietkau <nbd@nbd.name>2020-11-20 13:49:42 +0100
commit5e18d5b9ccb189efb914733e7b74073f5c75e0df (patch)
tree97fb861e0fc5bac5dcb409c93d6cd90dd57de006
parentc1c2728946b5bedb7a4757d9dd95744dc7d2f1ec (diff)
downloadnetifd-5e18d5b9ccb189efb914733e7b74073f5c75e0df.tar.gz
interface: do not force link-ext hotplug interfaces to present by default
On wireless interfaces, hostapd can sometimes defer the bringup of secondary virtual interfaces until autochannel or coex scan completes. Do not force the present state in that case in order to avoid attempting to bring up the device before it is ready Signed-off-by: Felix Fietkau <nbd@nbd.name>
-rw-r--r--interface.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/interface.c b/interface.c
index c53c091..ccae915 100644
--- a/interface.c
+++ b/interface.c
@@ -1081,7 +1081,8 @@ interface_handle_link(struct interface *iface, const char *name,
if (add) {
interface_set_device_config(iface, dev);
- device_set_present(dev, true);
+ if (!link_ext)
+ device_set_present(dev, true);
ret = interface_add_link(iface, dev, vlan, link_ext);
} else {