395 Star 1.4K Fork 1.3K

GVPopenEuler / kernel

 / 详情

【kernel bug】arm机器上lscpu命令无法显示cpu主频,cpu cache错误

已完成
缺陷
创建于  
2020-03-13 14:49

测试机器:泰山2280 V2

测试步骤:执行lscpu

预期结果:显示正常的cpu个数和cache值

[root@localhost UnixBench]# lscpu
Architecture: aarch64
CPU op-mode(s): 64-bit
Byte Order: Little Endian
CPU(s): 96
On-line CPU(s) list: 0-95
Thread(s) per core: 1
Core(s) per socket: 48
Socket(s): 2
NUMA node(s): 4
Vendor ID: 0x48
Model: 0
Stepping: 0x1
BogoMIPS: 200.00
L1d cache: 6 MiB
L1i cache: 6 MiB
L2 cache: 48 MiB
L3 cache: 192 MiB

NUMA node0 CPU(s): 0-23
NUMA node1 CPU(s): 24-47
NUMA node2 CPU(s): 48-71
NUMA node3 CPU(s): 72-95
Vulnerability Itlb multihit: Not affected
Vulnerability L1tf: Not affected
Vulnerability Mds: Not affected
Vulnerability Meltdown: Not affected
Vulnerability Spec store bypass: Vulnerable
Vulnerability Spectre v1: Mitigation; __user pointer sanitization
Vulnerability Spectre v2: Not affected
Vulnerability Tsx async abort: Not affected
Flags: fp asimd evtstrm aes pmull sha1 sha2 crc32 atomics fphp asimdhp cpuid asimdrdm jscvt fcma dcpop asimddp asimdfhm

评论 (6)

solarhu 创建了缺陷
solarhu 负责人设置为Xie XiuQi
solarhu 计划开始日期设置为2020-03-13
solarhu 计划截止日期设置为2020-03-14
solarhu 优先级设置为严重
solarhu 关联仓库设置为openEuler/kernel
展开全部操作日志

Hey @solarhu, Welcome to openEuler Community.
All of the projects in openEuler Community are maintained by @openeuler-ci-bot.
That means the developpers can comment below every pull request or issue to trigger Bot Commands.
Please follow instructions at https://gitee.com/openeuler/community/blob/master/en/command.md to find the details.

内核中无
/sys/devices/system/cpu/cpu0/cache
无法获取数值,使用默认值。

@hexiaowen

我使用 util-linux-2.32.1-1.h1 中的 lscpu 就没有问题:

[root@localhost ~]# ./lscpu
Architecture:        aarch64
Byte Order:          Little Endian
CPU(s):              96
On-line CPU(s) list: 0-95
Thread(s) per core:  1
Core(s) per socket:  48
Socket(s):           2
NUMA node(s):        4
Vendor ID:           0x48
Model:               0
Stepping:            0x1
BogoMIPS:            200.00
L1d cache:           64K
L1i cache:           64K
L2 cache:            512K
L3 cache:            49152K
NUMA node0 CPU(s):   0-23
NUMA node1 CPU(s):   24-47
NUMA node2 CPU(s):   48-71
NUMA node3 CPU(s):   72-95
hexiaowen 任务状态待办的 修改为已确认
hexiaowen 任务状态已确认 修改为待办的

这个高版本util-linux lscpu新机制,会显示所有cpu cache合,而非单个cpu的cache,在2.34版本有,2.32版本没有合入,所以2.32显示的还是单个cpu cache
详见上游社区提交
https://git.kernel.org/pub/scm/utils/util-linux/util-linux.git/commit/sys-utils/lscpu.c?id=e5f721132ec8b8c933a396d8dcb3efcb67854f13
谢谢。

syyhao 任务状态待办的 修改为已完成

登录 后才可以发表评论

状态
负责人
项目
里程碑
Pull Requests
关联的 Pull Requests 被合并后可能会关闭此 issue
分支
开始日期   -   截止日期
-
置顶选项
优先级
预计工期 (小时)
参与者(5)
5329419 openeuler ci bot 1632792936 5324761 overweight 1578984558
C
1
https://gitee.com/openeuler/kernel.git
git@gitee.com:openeuler/kernel.git
openeuler
kernel
kernel

搜索帮助