Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
openeuler
qemu
提交
10055562
Q
qemu
项目概览
openeuler
/
qemu
通知
10
Star
0
Fork
0
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
0
列表
看板
标记
里程碑
合并请求
0
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
Q
qemu
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
0
Issue
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
Pages
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
提交
Issue看板
体验新版 GitCode,发现更多精彩内容 >>
提交
10055562
编写于
11月 19, 2009
作者:
P
Paul Brook
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
ARM Cortex-A9 cpu support
Basic Cortex-A9 support. Signed-off-by:
N
Paul Brook
<
paul@codesourcery.com
>
上级
60011498
变更
2
显示空白变更内容
内联
并排
Showing
2 changed file
with
36 addition
and
1 deletion
+36
-1
target-arm/cpu.h
target-arm/cpu.h
+1
-0
target-arm/helper.c
target-arm/helper.c
+35
-1
未找到文件。
target-arm/cpu.h
浏览文件 @
10055562
...
...
@@ -389,6 +389,7 @@ void cpu_arm_set_cp_io(CPUARMState *env, int cpnum,
#define ARM_CPUID_ARM1136_R2 0x4107b362
#define ARM_CPUID_ARM11MPCORE 0x410fb022
#define ARM_CPUID_CORTEXA8 0x410fc080
#define ARM_CPUID_CORTEXA9 0x410fc090
#define ARM_CPUID_CORTEXM3 0x410fc231
#define ARM_CPUID_ANY 0xffffffff
...
...
target-arm/helper.c
浏览文件 @
10055562
...
...
@@ -9,6 +9,12 @@
#include "qemu-common.h"
#include "host-utils.h"
static
uint32_t
cortexa9_cp15_c0_c1
[
8
]
=
{
0x1031
,
0x11
,
0x000
,
0
,
0x00100103
,
0x20000000
,
0x01230000
,
0x00002111
};
static
uint32_t
cortexa9_cp15_c0_c2
[
8
]
=
{
0x00101111
,
0x13112111
,
0x21232041
,
0x11112131
,
0x00111142
,
0
,
0
,
0
};
static
uint32_t
cortexa8_cp15_c0_c1
[
8
]
=
{
0x1031
,
0x11
,
0x400
,
0
,
0x31100003
,
0x20000000
,
0x01202000
,
0x11
};
...
...
@@ -101,6 +107,27 @@ static void cpu_reset_model_id(CPUARMState *env, uint32_t id)
env
->
cp15
.
c0_ccsid
[
1
]
=
0x2007e01a
;
/* 16k L1 icache. */
env
->
cp15
.
c0_ccsid
[
2
]
=
0xf0000000
;
/* No L2 icache. */
break
;
case
ARM_CPUID_CORTEXA9
:
set_feature
(
env
,
ARM_FEATURE_V6
);
set_feature
(
env
,
ARM_FEATURE_V6K
);
set_feature
(
env
,
ARM_FEATURE_V7
);
set_feature
(
env
,
ARM_FEATURE_AUXCR
);
set_feature
(
env
,
ARM_FEATURE_THUMB2
);
set_feature
(
env
,
ARM_FEATURE_VFP
);
set_feature
(
env
,
ARM_FEATURE_VFP3
);
set_feature
(
env
,
ARM_FEATURE_VFP_FP16
);
set_feature
(
env
,
ARM_FEATURE_NEON
);
set_feature
(
env
,
ARM_FEATURE_THUMB2EE
);
env
->
vfp
.
xregs
[
ARM_VFP_FPSID
]
=
0x41034000
;
/* Guess */
env
->
vfp
.
xregs
[
ARM_VFP_MVFR0
]
=
0x11110222
;
env
->
vfp
.
xregs
[
ARM_VFP_MVFR1
]
=
0x01111111
;
memcpy
(
env
->
cp15
.
c0_c1
,
cortexa9_cp15_c0_c1
,
8
*
sizeof
(
uint32_t
));
memcpy
(
env
->
cp15
.
c0_c2
,
cortexa9_cp15_c0_c2
,
8
*
sizeof
(
uint32_t
));
env
->
cp15
.
c0_cachetype
=
0x80038003
;
env
->
cp15
.
c0_clid
=
(
1
<<
27
)
|
(
1
<<
24
)
|
3
;
env
->
cp15
.
c0_ccsid
[
0
]
=
0xe00fe015
;
/* 16k L1 dcache. */
env
->
cp15
.
c0_ccsid
[
1
]
=
0x200fe015
;
/* 16k L1 icache. */
break
;
case
ARM_CPUID_CORTEXM3
:
set_feature
(
env
,
ARM_FEATURE_V6
);
set_feature
(
env
,
ARM_FEATURE_THUMB2
);
...
...
@@ -287,6 +314,7 @@ static const struct arm_cpu_t arm_cpu_names[] = {
{
ARM_CPUID_ARM11MPCORE
,
"arm11mpcore"
},
{
ARM_CPUID_CORTEXM3
,
"cortex-m3"
},
{
ARM_CPUID_CORTEXA8
,
"cortex-a8"
},
{
ARM_CPUID_CORTEXA9
,
"cortex-a9"
},
{
ARM_CPUID_TI925T
,
"ti925t"
},
{
ARM_CPUID_PXA250
,
"pxa250"
},
{
ARM_CPUID_PXA255
,
"pxa255"
},
...
...
@@ -1633,7 +1661,11 @@ uint32_t HELPER(get_cp15)(CPUState *env, uint32_t insn)
case
3
:
/* TLB type register. */
return
0
;
/* No lockable TLB entries. */
case
5
:
/* CPU ID */
if
(
ARM_CPUID
(
env
)
==
ARM_CPUID_CORTEXA9
)
{
return
env
->
cpu_index
|
0x80000900
;
}
else
{
return
env
->
cpu_index
;
}
default:
goto
bad_reg
;
}
...
...
@@ -1697,6 +1729,8 @@ uint32_t HELPER(get_cp15)(CPUState *env, uint32_t insn)
return
1
;
case
ARM_CPUID_CORTEXA8
:
return
2
;
case
ARM_CPUID_CORTEXA9
:
return
0
;
default:
goto
bad_reg
;
}
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录