diff --git a/my-default-settings/files/etc/hotplug.d/iface/95-network b/my-default-settings/files/etc/hotplug.d/iface/99-network similarity index 99% rename from my-default-settings/files/etc/hotplug.d/iface/95-network rename to my-default-settings/files/etc/hotplug.d/iface/99-network index 991d2ce41..a160500ce 100644 --- a/my-default-settings/files/etc/hotplug.d/iface/95-network +++ b/my-default-settings/files/etc/hotplug.d/iface/99-network @@ -1,7 +1,6 @@ #!/bin/sh # - [ "$(uci -q get network.lan.ifname)" ] || (uci -q set network.lan.ifname="`uci -q get network.lan.device`";uci commit network) [ "$(uci -q get network.wan.ifname)" ] || (uci -q set network.wan.ifname="`uci -q get network.wan.device`";uci commit network) [ "$(uci -q get network.wan6.ifname)" ] || (uci -q set network.wan6.ifname="`uci -q get network.wan6.device`";uci commit network) diff --git a/my-default-settings/target/x86/files/etc/hotplug.d/iface/99-autoneg b/my-default-settings/target/x86/files/etc/hotplug.d/iface/99-autoneg new file mode 100644 index 000000000..f0f72ae40 --- /dev/null +++ b/my-default-settings/target/x86/files/etc/hotplug.d/iface/99-autoneg @@ -0,0 +1,6 @@ +#!/bin/sh +# + +for eth in $(ip address | grep ^[0-9] | awk -F: '{print $2}' | sed "s/ //g" | grep '^[e]' | grep -vE "(@|\.)"); do + [[ "$(ethtool -i $eth | grep 'r8125')" && ! "$(ubus call system board | grep VMware)" ]] && ethtool -s $eth autoneg on +done