bugfix: 修复HAL获取cpu厂商失败

This commit is contained in:
wangmenglan
2023-12-14 15:29:35 +08:00
committed by 付明卫
parent 7a05ca86ed
commit 1045ef78e5

View File

@@ -166,11 +166,12 @@ set_cpu_list()
{
local vendor
vendor=$(lscpu | grep "^Vendor ID" | awk '{print $3}')
if [ -n "$NIC_CPU_Affinity_Switch" ] && [ "$NIC_CPU_Affinity_Switch" == "1" ]; then
. /opt/tsg/tsg-os-HAL/scripts/cpu_amd.sh
elif [ -n "$NIC_CPU_Affinity_Switch" ] && [ "$NIC_CPU_Affinity_Switch" == "0" ]; then
. /opt/tsg/tsg-os-HAL/scripts/cpu_default.sh
elif [ $vendor == 'AuthenticAMD' ]; then
elif [ "$vendor" == 'AuthenticAMD' ]; then
. /opt/tsg/tsg-os-HAL/scripts/cpu_amd.sh
else
. /opt/tsg/tsg-os-HAL/scripts/cpu_default.sh