master
c 21 lines 457 Bytes
Raw
1 /* SPDX-License-Identifier: GPL-2.0-or-later */
2
3 #include "qemu/osdep.h"
4 #include "qemu.h"
5 #include "loader.h"
6 #include "target_elf.h"
7
8
9 const char *get_elf_cpu_model(uint32_t eflags)
10 {
11 return "any";
12 }
13
14 void elf_core_copy_regs(target_elf_gregset_t *r, const CPUOpenRISCState *env)
15 {
16 for (int i = 0; i < 32; i++) {
17 r->pt.gpr[i] = tswapal(cpu_get_gpr(env, i));
18 }
19 r->pt.pc = tswapal(env->pc);
20 r->pt.sr = tswapal(cpu_get_sr(env));
21 }