Bug 8117 - 使用龙蜥23.0,执行lscpu命令,在BIOS Model name:属性中多出来cpu频率的信息
Summary: 使用龙蜥23.0,执行lscpu命令,在BIOS Model name:属性中多出来cpu频率的信息
Status: RESOLVED BYDESIGN
Alias: None
Product: Anolis OS 23
Classification: Anolis OS
Component: BaseOS Packages (show other bugs) BaseOS Packages
Version: 23.0
Hardware: All Linux
: P3-Medium S3-normal
Target Milestone: ---
Assignee: happy_orange
QA Contact: bolong_tbl
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2024-01-31 18:44 UTC by HerbWei
Modified: 2024-02-22 16:36 UTC (History)
2 users (show)

See Also:


Attachments
log (1.91 MB, application/vnd.openxmlformats-officedocument.wordprocessingml.document)
2024-01-31 18:44 UTC, HerbWei
Details

Note You need to log in before you can comment on or make changes to this bug.
Description HerbWei inspur_group 2024-01-31 18:44:18 UTC
Created attachment 997 [details]
log

Description of problem:

搭配龙蜥23.0版本,执行lscpu命令,在BIOS Model name:属性中多出来cpu频率的信息.
详细描述请参考附件

Version-Release number of selected component (if applicable):
util-linux-2.38.1-1.an23.

How reproducible:


Steps to Reproduce:
1.
2.
3.

Actual results:


Expected results:


Additional info:
Comment 1 葛立伟 alibaba_cloud_group 2024-02-19 10:13:55 UTC
(In reply to HerbWei from comment #0)
> Created attachment 997 [details]
> log
> 
> Description of problem:
> 
> 搭配龙蜥23.0版本,执行lscpu命令,在BIOS Model name:属性中多出来cpu频率的信息.
> 详细描述请参考附件
> 
> Version-Release number of selected component (if applicable):
> util-linux-2.38.1-1.an23.
> 
> How reproducible:
> 
> 
> Steps to Reproduce:
> 1.
> 2.
> 3.
> 
> Actual results:
> 
> 
> Expected results:
> 
> 
> Additional info:

https://github.com/util-linux/util-linux/commit/a772d7c493afcec32f0123fc947013f74db6e45d
Comment 2 HerbWei inspur_group 2024-02-20 14:18:43 UTC
您好:
这个问题是否有进展?多谢!
Comment 3 扣肉 2024-02-20 21:37:08 UTC
(In reply to HerbWei from comment #2)
> 您好:
> 这个问题是否有进展?多谢!
第一条注释,说的很清楚,是上游的更改:
https://github.com/util-linux/util-linux/commit/a772d7c493afcec32f0123fc947013f74db6e45d
两年半前已经更改了。
Comment 4 HerbWei inspur_group 2024-02-21 09:05:01 UTC
上游的更新看着是与arm相关的,这是x86的机器。就如附件中说的,这个值是不会发生变化的,为什么要添加?
Comment 5 HerbWei inspur_group 2024-02-22 16:36:13 UTC
根据如下链接内容:
https://github.com/util-linux/util-linux/commit/a772d7c493afcec32f0123fc947013f74db6e45d
BIOS Model name的是由如下内容打印的:
snprintf(buf, sizeof(buf),

"%s %s CPU @ %d.%dGHz", di.processor_version, di.part_num,

di.current_speed/1000, (di.current_speed % 1000) / 100);


ct->bios_modelname = xstrdup(buf);
此函数的参数是由如下代码从dmi的type4中获取的
case 4:

/* Get the first processor information */

if (di->sockets == 0) {

di->processor_manufacturer = dmi_string(&h, data[0x7]);

di->processor_version = dmi_string(&h, data[0x10]);

di->current_speed = *((uint16_t *)(&data[0x16]));

di->part_num = dmi_string(&h, data[0x22]);

}
使用dmidecode -t 4命令查看amp cpu的信息,发现versions中已经存在了频率,所以此patch是不是一个无效的?
Amp cpu dmi信息如下:
Handle 0x00F0, DMI type 4, 48 bytes
Processor Information
	Socket Designation: CPU0
	Type: Central Processor
	Family: ARMv8
	Manufacturer: Ampere(R)
	ID: 01 00 16 0A A1 00 00 00
	Signature: Implementor 0x0a, Variant 0x1, Architecture 6, Part 0x000, Revision 1
	Version: Ampere(R) Altra(R) Processor Q80-30 3.00GHz
	Voltage: 0.9 V
	External Clock: 1650 MHz
	Max Speed: 3000 MHz
	Current Speed: 3000 MHz
	Status: Populated, Enabled
	Upgrade: None
	L1 Cache Handle: Not Provided
	L2 Cache Handle: Not Provided
	L3 Cache Handle: Not Provided
	Serial Number: 000000000000000090C90503033865B0
	Asset Tag: 00000001
	Part Number: Q80-30
	Core Count: 80
	Core Enabled: 80
	Thread Count: 80
	Characteristics:
		64-bit capable
		Multi-Core
		Power/Performance Control
		128-bit Capable
		Arm64 SoC ID