aboutsummaryrefslogtreecommitdiff
path: root/target/xtensa/cpu.c
diff options
context:
space:
mode:
Diffstat (limited to 'target/xtensa/cpu.c')
-rw-r--r--target/xtensa/cpu.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/target/xtensa/cpu.c b/target/xtensa/cpu.c
index 811d8780d6..cd7f95823f 100644
--- a/target/xtensa/cpu.c
+++ b/target/xtensa/cpu.c
@@ -127,6 +127,12 @@ static void xtensa_cpu_initfn(Object *obj)
cs->env_ptr = env;
env->config = xcc->config;
+ env->address_space_er = g_malloc(sizeof(*env->address_space_er));
+ env->system_er = g_malloc(sizeof(*env->system_er));
+ memory_region_init_io(env->system_er, NULL, NULL, env, "er",
+ UINT64_C(0x100000000));
+ address_space_init(env->address_space_er, env->system_er, "ER");
+
if (tcg_enabled() && !tcg_inited) {
tcg_inited = true;
xtensa_translate_init();