device: apply initial settings when creating an external device
authorFelix Fietkau <nbd@openwrt.org>
Sat, 18 Jul 2015 23:09:56 +0000 (01:09 +0200)
committerFelix Fietkau <nbd@openwrt.org>
Sat, 18 Jul 2015 23:09:59 +0000 (01:09 +0200)
Fixes RPS/XPS settings for wlan devices

Signed-off-by: Felix Fietkau <nbd@openwrt.org>
device.c

index fec5bce1eda0d557b012b16d3caef45490d42faf..b5bee117ff0624c64d5e9ecdf80c2c12ee3bbde6 100644 (file)
--- a/device.c
+++ b/device.c
@@ -410,6 +410,8 @@ device_create_default(const char *name, bool external)
        dev->set_state = simple_device_set_state;
        device_init(dev, &simple_device_type, name);
        dev->default_config = true;
+       if (external)
+               system_if_apply_settings(dev, &dev->settings, dev->settings.flags);
        return dev;
 }