Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
openeuler
raspberrypi-kernel
提交
c3cf5e8c
R
raspberrypi-kernel
项目概览
openeuler
/
raspberrypi-kernel
通知
13
Star
1
Fork
0
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
0
列表
看板
标记
里程碑
合并请求
0
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
R
raspberrypi-kernel
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
0
Issue
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
Pages
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
提交
Issue看板
提交
c3cf5e8c
编写于
1月 21, 2009
作者:
D
David S. Miller
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
sparc: Probe PMU type and record in sparc_pmu_type.
Signed-off-by:
N
David S. Miller
<
davem@davemloft.net
>
上级
3eb8057b
变更
3
隐藏空白更改
内联
并排
Showing
3 changed file
with
25 addition
and
11 deletion
+25
-11
arch/sparc/kernel/cpu.c
arch/sparc/kernel/cpu.c
+22
-11
arch/sparc/kernel/kernel.h
arch/sparc/kernel/kernel.h
+1
-0
arch/sparc/kernel/setup_64.c
arch/sparc/kernel/setup_64.c
+2
-0
未找到文件。
arch/sparc/kernel/cpu.c
浏览文件 @
c3cf5e8c
...
...
@@ -26,6 +26,7 @@ EXPORT_PER_CPU_SYMBOL(__cpu_data);
struct
cpu_info
{
int
psr_vers
;
const
char
*
name
;
const
char
*
pmu_name
;
};
struct
fpu_info
{
...
...
@@ -45,6 +46,9 @@ struct manufacturer_info {
#define CPU(ver, _name) \
{ .psr_vers = ver, .name = _name }
#define CPU_PMU(ver, _name, _pmu_name) \
{ .psr_vers = ver, .name = _name, .pmu_name = _pmu_name }
#define FPU(ver, _name) \
{ .fp_vers = ver, .name = _name }
...
...
@@ -183,10 +187,10 @@ static const struct manufacturer_info __initconst manufacturer_info[] = {
},{
0x17
,
.
cpu_info
=
{
CPU
(
0x10
,
"TI UltraSparc I (SpitFire)
"
),
CPU
(
0x11
,
"TI UltraSparc II (BlackBird)
"
),
CPU
(
0x12
,
"TI UltraSparc IIi (Sabre)
"
),
CPU
(
0x13
,
"TI UltraSparc IIe (Hummingbird)
"
),
CPU
_PMU
(
0x10
,
"TI UltraSparc I (SpitFire)"
,
"ultra12
"
),
CPU
_PMU
(
0x11
,
"TI UltraSparc II (BlackBird)"
,
"ultra12
"
),
CPU
_PMU
(
0x12
,
"TI UltraSparc IIi (Sabre)"
,
"ultra12
"
),
CPU
_PMU
(
0x13
,
"TI UltraSparc IIe (Hummingbird)"
,
"ultra12
"
),
CPU
(
-
1
,
NULL
)
},
.
fpu_info
=
{
...
...
@@ -199,7 +203,7 @@ static const struct manufacturer_info __initconst manufacturer_info[] = {
},{
0x22
,
.
cpu_info
=
{
CPU
(
0x10
,
"TI UltraSparc I (SpitFire)
"
),
CPU
_PMU
(
0x10
,
"TI UltraSparc I (SpitFire)"
,
"ultra12
"
),
CPU
(
-
1
,
NULL
)
},
.
fpu_info
=
{
...
...
@@ -209,12 +213,12 @@ static const struct manufacturer_info __initconst manufacturer_info[] = {
},{
0x3e
,
.
cpu_info
=
{
CPU
(
0x14
,
"TI UltraSparc III (Cheetah)
"
),
CPU
(
0x15
,
"TI UltraSparc III+ (Cheetah+)
"
),
CPU
(
0x16
,
"TI UltraSparc IIIi (Jalapeno)
"
),
CPU
(
0x18
,
"TI UltraSparc IV (Jaguar)
"
),
CPU
(
0x19
,
"TI UltraSparc IV+ (Panther)
"
),
CPU
(
0x22
,
"TI UltraSparc IIIi+ (Serrano)
"
),
CPU
_PMU
(
0x14
,
"TI UltraSparc III (Cheetah)"
,
"ultra3
"
),
CPU
_PMU
(
0x15
,
"TI UltraSparc III+ (Cheetah+)"
,
"ultra3+
"
),
CPU
_PMU
(
0x16
,
"TI UltraSparc IIIi (Jalapeno)"
,
"ultra3i
"
),
CPU
_PMU
(
0x18
,
"TI UltraSparc IV (Jaguar)"
,
"ultra3+
"
),
CPU
_PMU
(
0x19
,
"TI UltraSparc IV+ (Panther)"
,
"ultra4+
"
),
CPU
_PMU
(
0x22
,
"TI UltraSparc IIIi+ (Serrano)"
,
"ultra3i
"
),
CPU
(
-
1
,
NULL
)
},
.
fpu_info
=
{
...
...
@@ -234,6 +238,7 @@ static const struct manufacturer_info __initconst manufacturer_info[] = {
const
char
*
sparc_cpu_type
;
const
char
*
sparc_fpu_type
;
const
char
*
sparc_pmu_type
;
unsigned
int
fsr_storage
;
...
...
@@ -244,6 +249,7 @@ static void set_cpu_and_fpu(int psr_impl, int psr_vers, int fpu_vers)
sparc_cpu_type
=
NULL
;
sparc_fpu_type
=
NULL
;
sparc_pmu_type
=
NULL
;
manuf
=
NULL
;
for
(
i
=
0
;
i
<
ARRAY_SIZE
(
manufacturer_info
);
i
++
)
...
...
@@ -263,6 +269,7 @@ static void set_cpu_and_fpu(int psr_impl, int psr_vers, int fpu_vers)
{
if
(
cpu
->
psr_vers
==
psr_vers
)
{
sparc_cpu_type
=
cpu
->
name
;
sparc_pmu_type
=
cpu
->
pmu_name
;
sparc_fpu_type
=
"No FPU"
;
break
;
}
...
...
@@ -290,6 +297,8 @@ static void set_cpu_and_fpu(int psr_impl, int psr_vers, int fpu_vers)
psr_impl
,
fpu_vers
);
sparc_fpu_type
=
"Unknown FPU"
;
}
if
(
sparc_pmu_type
==
NULL
)
sparc_pmu_type
=
"Unknown PMU"
;
}
#ifdef CONFIG_SPARC32
...
...
@@ -315,11 +324,13 @@ static void __init sun4v_cpu_probe(void)
case
SUN4V_CHIP_NIAGARA1
:
sparc_cpu_type
=
"UltraSparc T1 (Niagara)"
;
sparc_fpu_type
=
"UltraSparc T1 integrated FPU"
;
sparc_pmu_type
=
"niagara"
;
break
;
case
SUN4V_CHIP_NIAGARA2
:
sparc_cpu_type
=
"UltraSparc T2 (Niagara2)"
;
sparc_fpu_type
=
"UltraSparc T2 integrated FPU"
;
sparc_pmu_type
=
"niagara2"
;
break
;
default:
...
...
arch/sparc/kernel/kernel.h
浏览文件 @
c3cf5e8c
...
...
@@ -5,6 +5,7 @@
/* cpu.c */
extern
const
char
*
sparc_cpu_type
;
extern
const
char
*
sparc_pmu_type
;
extern
const
char
*
sparc_fpu_type
;
extern
unsigned
int
fsr_storage
;
...
...
arch/sparc/kernel/setup_64.c
浏览文件 @
c3cf5e8c
...
...
@@ -354,6 +354,7 @@ static int show_cpuinfo(struct seq_file *m, void *__unused)
seq_printf
(
m
,
"cpu
\t\t
: %s
\n
"
"fpu
\t\t
: %s
\n
"
"pmu
\t\t
: %s
\n
"
"prom
\t\t
: %s
\n
"
"type
\t\t
: %s
\n
"
"ncpus probed
\t
: %d
\n
"
...
...
@@ -366,6 +367,7 @@ static int show_cpuinfo(struct seq_file *m, void *__unused)
,
sparc_cpu_type
,
sparc_fpu_type
,
sparc_pmu_type
,
prom_version
,
((
tlb_type
==
hypervisor
)
?
"sun4v"
:
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录