mirror of
https://github.com/coolsnowwolf/lede
synced 2025-01-08 13:57:31 +08:00
autocore: x86 change RPS/XPS handling to all CPUs
This commit is contained in:
parent
351441834c
commit
88aed2924e
@ -229,7 +229,7 @@ menu "Target Images"
|
||||
config GRUB_TIMEOUT
|
||||
string "Seconds to wait before booting the default entry"
|
||||
depends on GRUB_IMAGES || GRUB_EFI_IMAGES
|
||||
default "5"
|
||||
default "0"
|
||||
help
|
||||
If you don't know, 5 seconds is a reasonable default.
|
||||
|
||||
|
@ -9,7 +9,7 @@ include $(TOPDIR)/rules.mk
|
||||
|
||||
PKG_NAME:=autocore
|
||||
PKG_VERSION:=1
|
||||
PKG_RELEASE:=31
|
||||
PKG_RELEASE:=33
|
||||
|
||||
|
||||
include $(INCLUDE_DIR)/package.mk
|
||||
|
@ -8,22 +8,20 @@ start()
|
||||
rfc=4096
|
||||
cc=$(grep -c processor /proc/cpuinfo)
|
||||
rsfe=$(echo $cc*$rfc | bc)
|
||||
sysctl -w net.core.rps_sock_flow_entries=$rsfe
|
||||
sysctl -w net.core.rps_sock_flow_entries=$rsfe >/dev/null
|
||||
for fileRps in $(ls /sys/class/net/eth*/queues/rx-*/rps_cpus)
|
||||
do
|
||||
echo $cc > $fileRps
|
||||
done
|
||||
|
||||
|
||||
for fileRfc in $(ls /sys/class/net/eth*/queues/rx-*/rps_flow_cnt)
|
||||
do
|
||||
echo $rfc > $fileRfc
|
||||
done
|
||||
|
||||
for fileRps in $(ls /sys/class/net/eth*/queues/tx-*/xps_cpus)
|
||||
do
|
||||
echo $cc > $fileRps
|
||||
done
|
||||
|
||||
|
||||
uci set network.@globals[0].packet_steering=1
|
||||
uci commit network
|
||||
|
||||
a=$(cat /proc/cpuinfo | grep name | cut -f2 -d: | uniq)
|
||||
b=$(echo -n ' : ')
|
||||
c=$(cat /proc/cpuinfo | grep 'core id' | sort -u | wc -l)
|
||||
|
@ -5,7 +5,7 @@ info()
|
||||
MHz=`grep 'MHz' /proc/cpuinfo | cut -c11- |sed -n '1p'`
|
||||
#获取CPU工作频率
|
||||
|
||||
sensors >/dev/null
|
||||
sensors 2>/dev/null
|
||||
|
||||
if [ $? -eq 0 ];then
|
||||
a=`sensors | grep 'Core 0' | cut -c10-24`
|
||||
|
Loading…
Reference in New Issue
Block a user