device: fix default initialization for RPS/XPS
authorFelix Fietkau <nbd@openwrt.org>
Sun, 22 Mar 2015 17:09:49 +0000 (18:09 +0100)
committerFelix Fietkau <nbd@openwrt.org>
Sun, 22 Mar 2015 17:09:49 +0000 (18:09 +0100)
Signed-off-by: Felix Fietkau <nbd@openwrt.org>
device.c
system-linux.c

index 3ca867c68fb2a20950d369de3481293b8c22b78b..24c7fe3b3c184e396b3bc8d4f9c0a63df6321cb4 100644 (file)
--- a/device.c
+++ b/device.c
@@ -371,6 +371,8 @@ int device_init(struct device *dev, const struct device_type *type, const char *
 
        system_if_clear_state(dev);
        device_check_state(dev);
+       dev->settings.rps = true;
+       dev->settings.xps = true;
 
        return 0;
 }
index 9ff1532ce512f1b18e3b0664a0fe2bb28a0c5fc1..7a443adeb183736588d1fe2b25998650c0f63e42 100644 (file)
@@ -1093,9 +1093,6 @@ system_if_apply_settings(struct device *dev, struct device_settings *s, unsigned
 {
        struct ifreq ifr;
 
-       if (!apply_mask)
-               return;
-
        memset(&ifr, 0, sizeof(ifr));
        strncpy(ifr.ifr_name, dev->ifname, sizeof(ifr.ifr_name));
        if (s->flags & DEV_OPT_MTU & apply_mask) {