Initial commit
This commit is contained in:
14
target/linux/mediatek/base-files/etc/hotplug.d/iface/99-mtk-lro
Executable file
14
target/linux/mediatek/base-files/etc/hotplug.d/iface/99-mtk-lro
Executable file
@@ -0,0 +1,14 @@
|
||||
[ ifup = "$ACTION" ] && {
|
||||
[ -n "$DEVICE" ] && {
|
||||
if [ "$INTERFACE" == "lan" ]; then
|
||||
if [ -f /usr/sbin/ethtool ]; then
|
||||
ifname=eth0
|
||||
lan_ip=`uci -q get network.lan.ipaddr`
|
||||
ethdrv=`ethtool -i $ifname | grep mtk_soc_eth`
|
||||
[ -n "$ethdrv" ] && {
|
||||
ethtool -N $ifname flow-type tcp4 dst-ip $lan_ip loc 0
|
||||
}
|
||||
fi
|
||||
fi
|
||||
}
|
||||
}
|
||||
3
target/linux/mediatek/base-files/etc/inittab
Normal file
3
target/linux/mediatek/base-files/etc/inittab
Normal file
@@ -0,0 +1,3 @@
|
||||
::sysinit:/etc/init.d/rcS S boot
|
||||
::shutdown:/etc/init.d/rcS K shutdown
|
||||
::askconsole:/usr/libexec/login.sh
|
||||
@@ -0,0 +1,15 @@
|
||||
set_preinit_iface() {
|
||||
ip link set eth0 up
|
||||
|
||||
case $(board_name) in
|
||||
ubnt,unifi-6-lr)
|
||||
ifname=eth0
|
||||
;;
|
||||
*)
|
||||
ifname=lan1
|
||||
;;
|
||||
esac
|
||||
}
|
||||
|
||||
boot_hook_add preinit_main set_preinit_iface
|
||||
|
||||
@@ -0,0 +1,6 @@
|
||||
set_rps_sock_flow() {
|
||||
echo 1024 > /proc/sys/net/core/rps_sock_flow_entries
|
||||
}
|
||||
|
||||
boot_hook_add preinit_main set_rps_sock_flow
|
||||
|
||||
Reference in New Issue
Block a user