target-mips: add UHI semihosting support
cover target-mips: add UHI semihosting support
Hi,
This patch series introduces the Unified Hosting Interface [1] support to QEMU. UHI is a common bare metal semi-hosting interface for the MIPS architecture and in QEMU it comes down to reserving SDBBP 1 instruction which triggers semi-hosting syscalls.
Since we are already in soft-freeze these patches are not intended for 2.3. I'm submitting it now as I would like to get your feedback. I'm particularly interested in your opinion about the new command line option for semihosting input arguments.
When QEMU is executed with -semihosting option the SDBBP instruction with code = 1 will not cause a debug exception, but instead it will call one of the UHI operations which are handled in target-mips/mips-semi.c file. Input arguments as well as return values are passed via GPRs as specified in the manual.
UHI provides 3 operations allowing to construct argv and argc:
* Argc: returns number of arguments.
* Argnlen: returns the length of the n'th argument.
* Argn: copies the n'th argument to the provided buffer.
In order to keep it simple it would be ideal to be able to pass multiple input arguments which can contain any character to the guest program without having to care about separators and escape characters (they might be quite unintuitive if we also consider Windows environment). Therefore rather than using existing "-append" I would like to introduce "-semihosting-arg" option which can occur multiple times in the command line.
For those who want to test the implementation -- here are the steps for building simple hello world bare metal program and running it on Malta board.
Bare Metal Toolchain containing UHI support can be obtained from:
http://codescape-mips-sdk.imgtec.com/components/toolchain/2014.07-1/
* Source file:
$ cat main.c #include <stdio.h>
int main()
{
printf("Hello world!\n");
return 0;
}* Build:
$ mips-mti-elf-gcc -T mti32-uhi.ld -mips32r2 -EL main.c
* Run:
$ qemu-system-mipsel -cpu 24Kf -M malta -semihosting -nographic -kernel a.out Hello world!
References:
[1] "MIPS Toolchain, MD01069 UHI Reference Manual", Version: 1.0.14
The manual is available here:
http://prplfoundation.org/wiki/MIPS_documentation
Regards,
Leon
Leon Alrae (2):
target-mips: add Unified Hosting Interface (UHI) support
target-mips: add "-semihosting-arg" option and implement UHI Arg* ops
Maciej W. Rozycki (1):
include/softmmu-semi.h: Make semihosting support 64-bit clean
Matthew Fortune (1):
hw/mips: Do not clear BEV for MIPS malta kernel load
hw/mips/mips_malta.c | 10 +- include/exec/softmmu-semi.h | 13 +- include/sysemu/sysemu.h | 2 + qemu-options.hx | 13 +- target-mips/Makefile.objs | 2 +- target-mips/helper.h | 2 + target-mips/mips-semi.c | 340 ++++++++++++++++++++++++++++++++++++++++++++ target-mips/translate.c | 82 +++++++---- vl.c | 28 ++++ 9 files changed, 456 insertions(+), 36 deletions(-) create mode 100644 target-mips/mips-semi.c
Signature · 1 line
2.1.0
PATCH 1/4 include/softmmu-semi.h: Make semihosting support 64-bit clean
From: "Maciej W. Rozycki" <[email protected]>
Correct addresses passed around in semihosting to use a data type suitable for both 32-bit and 64-bit targets.
---
Maciej,
I kept the same fix locally. I'm replacing it in this patchset with your patch since you submitted it first :)
Leon
--- include/exec/softmmu-semi.h | 13 +++++++------ 1 file changed, 7 insertions(+), 6 deletions(-)
include/exec/softmmu-semi.h +7 -6
@@ -9,14 +9,14 @@#ifndef SOFTMMU_SEMI_H #define SOFTMMU_SEMI_H 1 -static inline uint32_t softmmu_tget32 (CPUArchState *env,uint32_t addr) +static inline uint32_t softmmu_tget32 (CPUArchState *env,target_ulong addr) {uint32_t val;cpu_memory_rw_debug (ENV_GET_CPU (env), addr, (uint8_t *)&val,4 ,0 );return tswap32 (val); } -static inline uint32_t softmmu_tget8 (CPUArchState *env,uint32_t addr) +static inline uint32_t softmmu_tget8 (CPUArchState *env,target_ulong addr) {uint8_t val;
@@ -28,7 +28,8 @@ static inline uint32_t softmmu_tget8(CPUArchState *env, uint32_t addr)#define get_user_u8 (arg, p) ({ arg = softmmu_tget8(env, p) ; 0; })#define get_user_ual (arg, p) get_user_u32(arg, p) -static inline void softmmu_tput32 (CPUArchState *env,uint32_t addr,uint32_t val) +static inline void softmmu_tput32 (CPUArchState *env, +target_ulong addr,uint32_t val) { val =tswap32 (val);cpu_memory_rw_debug (ENV_GET_CPU (env), addr, (uint8_t *)&val,4 ,1 );
@@ -36,8 +37,8 @@ static inline void softmmu_tput32(CPUArchState *env, uint32_t addr, uint32_t val#define put_user_u32 (arg, p) ({ softmmu_tput32(env, p, arg) ; 0; })#define put_user_ual (arg, p) put_user_u32(arg, p) -static void *softmmu_lock_user (CPUArchState *env,uint32_t addr,uint32_t len, -int copy) +static void *softmmu_lock_user (CPUArchState *env, +target_ulong addr,target_ulong len,int copy) {uint8_t *p;/* TODO: Make this something that isn't fixed size. */
@@ -48,7 +49,7 @@ static void *softmmu_lock_user(CPUArchState *env, uint32_t addr, uint32_t len,return p; }#define lock_user (type, p, len, copy) softmmu_lock_user(env, p, len, copy) -static char *softmmu_lock_user_string (CPUArchState *env,uint32_t addr) +static char *softmmu_lock_user_string (CPUArchState *env,target_ulong addr) {char *p;char *s;
Signature · 1 line
2.1.0
PATCH 2/4 target-mips: add Unified Hosting Interface (UHI) support
In reply to Leon AlraeAdd UHI semihosting support for MIPS. QEMU run with "-semihosting" option will alter the behaviour of SDBBP 1 instruction -- UHI operation will be called instead of generating a debug exception.
This commit implements all UHI operations apart from Argc, Argnlen and Argn.
--- qemu-options.hx | 5 +- target-mips/Makefile.objs | 2 +- target-mips/helper.h | 2 + target-mips/mips-semi.c | 304 ++++++++++++++++++++++++++++++++++++++++++++++ target-mips/translate.c | 75 ++++++++---- 5 files changed, 360 insertions(+), 28 deletions(-) create mode 100644 target-mips/mips-semi.c
qemu-options.hx +3 -2
@@ -3223,11 +3223,12 @@ Set OpenBIOS nvram @var{variable} to given @var{value} (PPC, SPARC only). ETEXI DEF("semihosting", 0, QEMU_OPTION_semihosting, "-semihosting semihosting mode\n", - QEMU_ARCH_ARM | QEMU_ARCH_M68K | QEMU_ARCH_XTENSA | QEMU_ARCH_LM32) + QEMU_ARCH_ARM | QEMU_ARCH_M68K | QEMU_ARCH_XTENSA | QEMU_ARCH_LM32 | + QEMU_ARCH_MIPS) STEXI @item -semihosting @findex -semihosting -Enable semihosting mode (ARM, M68K, Xtensa only). +Enable semihosting mode (ARM, M68K, Xtensa, MIPS only). ETEXI DEF("semihosting-config", HAS_ARG, QEMU_OPTION_semihosting_config, "-semihosting-config [enable=on|off,]target=native|gdb|auto semihosting configuration\n",
target-mips/Makefile.objs +1 -1
@@ -1,4 +1,4 @@ obj-y += translate.o dsp_helper.o op_helper.o lmi_helper.o helper.o cpu.o -obj-y += gdbstub.o msa_helper.o +obj-y += gdbstub.o msa_helper.o mips-semi.o obj-$(CONFIG_SOFTMMU) += machine.o obj-$(CONFIG_KVM) += kvm.o
target-mips/helper.h +2 -0
@@ -1,6 +1,8 @@ DEF_HELPER_3(raise_exception_err, noreturn, env, i32, int) DEF_HELPER_2(raise_exception, noreturn, env, i32) +DEF_HELPER_1(do_semihosting, void, env) +#ifdef TARGET_MIPS64 DEF_HELPER_4(sdl, void, env, tl, tl, int)DEF_HELPER_4 (sdr, void, env, tl, tl, int)
target-mips/mips-semi.c new file +304 -0
304 lines not on this page · raw message
target-mips/translate.c +50 -25
116 lines not on this page · raw message
Signature · 1 line
2.1.0
Re: [Qemu-devel] [PATCH 2/4] target-mips: add Unified Hosting Interface (UHI) support
Hi Leon,
Many thanks for implementing this interface in QEMU. I haven't reviewed in great detail as I am not familiar enough with QEMU internals to do so. Overall it seems to match the UHI spec. The one potential issue is translation of errno values, I suspect some do not map 1:1.
A couple of minor review comments below:
Quoted 1 line
+ * Copyright (c) 2014 Imagination Technologies
Dates need updating.
target-mips/mips-semi.c line 132
Quoted 8 lines
+static int write_to_file(CPUMIPSState *env,
target_ulongfd,target_ulongvaddr,target-mips/mips-semi.c new file +6
-0+ target_ulong len, target_ulong offset) { + int num_of_bytes; +void *dst =lock_user (VERIFY_READ , vaddr, len,1 ); +if (!dst) { +return 0 ; + }
Ideally I think this this should return -1 and fake an errno but I may not understand what case this code is dealing with.
target-mips/mips-semi.c line 156
Quoted 8 lines
target-mips/mips-semi.c new file +8
-0+static int read_from_file (CPUMIPSState *env,target_ulong fd, +target_ulong vaddr,target_ulong len, +target_ulong offset) { +int num_of_bytes; +void *dst =lock_user (VERIFY_WRITE , vaddr, len,0 ); +if (!dst) { +return 0 ; + }
Likewise.
target-mips/mips-semi.c line 267
Quoted 13 lines
target-mips/mips-semi.c new file +13
-0+case UHI_plog: +GET_TARGET_STRING (p, gpr[4 ]); + p2 =strstr (p,"%d" ); +if (p2) { +int char_num = p2 - p; +char *buf =g_malloc (char_num +1 ); +strncpy (buf, p, char_num); + buf[char_num] ='\0' ; + gpr[2 ] =printf ("%s%d%s" , buf, (int )gpr[5 ], p2 +2 ); +g_free (buf); + }else { + gpr[2 ] =printf ("%s" , p); + }
Is all this necessary vs just: printf(p, (int)gpr[5])? I guess you may want to do the scan for %d and choose between that and just printf(p).
Thanks,
Matthew
Re: [Qemu-devel] [PATCH 2/4] target-mips: add Unified Hosting Interface (UHI) support
Hi Matthew,
Quoted 22 lines · Matthew Fortune
Hi Leon,
Many thanks for implementing this interface in QEMU. I haven't reviewed in great detail as I am not familiar enough with QEMU internals to do so. Overall it seems to match the UHI spec. The one potential issue is translation of errno values, I suspect some do not map 1:1.
A couple of minor review comments below:
Quoted 1 line
+ * Copyright (c) 2014 Imagination Technologies
Dates need updating.
target-mips/mips-semi.c line 132
Quoted 8 lines
+static int write_to_file(CPUMIPSState *env,
target_ulongfd,target_ulongvaddr,target-mips/mips-semi.c new file +6
-0+ target_ulong len, target_ulong offset) { + int num_of_bytes; +void *dst =lock_user (VERIFY_READ , vaddr, len,1 ); +if (!dst) { +return 0 ; + }
Quoted 2 lines
Ideally I think this this should return -1 and fake an errno but I may not understand what case this code is dealing with.
Indeed, indicating an error by returning -1 would be better. Thanks for spotting that.
Quoted 25 lines
target-mips/mips-semi.c line 156
Quoted 8 lines
target-mips/mips-semi.c new file +8
-0+static int read_from_file (CPUMIPSState *env,target_ulong fd, +target_ulong vaddr,target_ulong len, +target_ulong offset) { +int num_of_bytes; +void *dst =lock_user (VERIFY_WRITE , vaddr, len,0 ); +if (!dst) { +return 0 ; + }Likewise.
target-mips/mips-semi.c line 267
Quoted 13 lines
target-mips/mips-semi.c new file +13
-0+case UHI_plog: +GET_TARGET_STRING (p, gpr[4 ]); + p2 =strstr (p,"%d" ); +if (p2) { +int char_num = p2 - p; +char *buf =g_malloc (char_num +1 ); +strncpy (buf, p, char_num); + buf[char_num] ='\0' ; + gpr[2 ] =printf ("%s%d%s" , buf, (int )gpr[5 ], p2 +2 ); +g_free (buf); + }else { + gpr[2 ] =printf ("%s" , p); + }
Quoted 3 lines
Is all this necessary vs just:
printf(p, (int)gpr[5])? I guess you may want to do the scan for %d and choose between that and just printf(p).
I don't think we should use p as a format string directly as it might contain more/different format specifiers. Presumably we would need additional logic for checking this and returning an error for such cases -- and this new implementation wouldn't be much simpler than current I believe.
Current implementation allows any string given by the guest to be printed out. If there are multiple format specifiers then only the first occurrence of %d will be replaced with the integer.
Leon
Re: [Qemu-devel] [PATCH 2/4] target-mips: add Unified Hosting Interface (UHI) support
Quoted 24 lines · Leon Alrae
Quoted 14 lines · Matthew Fortune
target-mips/mips-semi.c line 267
Quoted 13 lines
target-mips/mips-semi.c new file +13
-0+case UHI_plog: +GET_TARGET_STRING (p, gpr[4 ]); + p2 =strstr (p,"%d" ); +if (p2) { +int char_num = p2 - p; +char *buf =g_malloc (char_num +1 ); +strncpy (buf, p, char_num); + buf[char_num] ='\0' ; + gpr[2 ] =printf ("%s%d%s" , buf, (int )gpr[5 ], p2 +2 ); +g_free (buf); + }else { + gpr[2 ] =printf ("%s" , p); + }Quoted 2 lines
Is all this necessary vs just:
printf(p, (int)gpr[5])? I guess you may want to do the scan for %d and choose between that and just printf(p).I don't think we should use p as a format string directly as it might contain more/different format specifiers. Presumably we would need additional logic for checking this and returning an error for such cases -- and this new implementation wouldn't be much simpler than current I believe.
Quoted 3 lines
Current implementation allows any string given by the guest to be printed out. If there are multiple format specifiers then only the first occurrence of %d will be replaced with the integer.
Good point. That makes sense.
Matthew
PATCH 3/4 target-mips: add "-semihosting-arg" option and implement UHI Arg* ops
In reply to Leon AlraeAdd new command line option "-semihosting-arg". It is used for passing input arguments to the guest in semihosting mode. The option can be used multiple times. If n arguments are passed, then argument count (semihosting_argc) will be equal to n+1 as semihosting_argv[0] points at the program name. However, if no arguments are passed then argument count will be 0.
Also tweak Malta's pseudo-bootloader. On CPU reset the $4 register is set to -1 when semihosting is enabled in order to indicate that the UHI operations should be used to obtain input arguments.
--- hw/mips/mips_malta.c | 8 +++++++- include/sysemu/sysemu.h | 2 ++ qemu-options.hx | 8 ++++++++ target-mips/mips-semi.c | 38 +++++++++++++++++++++++++++++++++++++- target-mips/translate.c | 7 +++++++ vl.c | 28 ++++++++++++++++++++++++++++ 6 files changed, 89 insertions(+), 2 deletions(-)
hw/mips/mips_malta.c +7 -1
@@ -634,7 +634,13 @@ static void write_bootloader (CPUMIPSState *env, uint8_t *base,/* Second part of the bootloader */ p = (uint32_t *) (base +0x580 ); -stl_p (p++,0x24040002 );/* addiu a0, zero, 2 */ + +if (semihosting_enabled) { +/* Preserve a0 content when semihosting is enabled. */ +stl_p (p++,0x00000000 );/* nop */ + }else { +stl_p (p++,0x24040002 );/* addiu a0, zero, 2 */ + }stl_p (p++,0x3c1d0000 | (((ENVP_ADDR -64 ) >>16 ) &0xffff ));/* lui sp, high(ENVP_ADDR) */ stl_p (p++,0x37bd0000 | ((ENVP_ADDR -64 ) &0xffff ));/* ori sp, sp, low(ENVP_ADDR) */ stl_p (p++,0x3c050000 | ((ENVP_ADDR >>16 ) &0xffff ));/* lui a1, high(ENVP_ADDR) */
include/sysemu/sysemu.h +2 -0
@@ -125,6 +125,8 @@ extern int graphic_rotate;extern int no_quit;extern int no_shutdown;extern int semihosting_enabled; +extern const char **semihosting_argv; +extern int semihosting_argc;extern int old_param;extern int boot_menu;extern bool boot_strict;
qemu-options.hx +8 -0
@@ -3240,6 +3240,14 @@ Enable semihosting and define where the semihosting calls will be addressed, to QEMU (@code{native}) or to GDB (@code{gdb}). The default is @code{auto}, which means @code{gdb} during debug sessions and @code{native} otherwise (ARM, M68K, Xtensa only). ETEXI +DEF("semihosting-arg", HAS_ARG, QEMU_OPTION_semihosting_arg, + "-semihosting-arg arguments passed to the guest program\n", + QEMU_ARCH_MIPS) +STEXI +@item -semihosting-arg +@findex -semihosting-arg +Arguments passed to the guest program (MIPS only). +ETEXI DEF("old-param", 0, QEMU_OPTION_old_param, "-old-param old param mode\n", QEMU_ARCH_ARM) STEXI
target-mips/mips-semi.c +37 -1
@@ -21,6 +21,9 @@#include "cpu.h" #include "exec/helper-proto.h" #include "exec/softmmu-semi.h" +#ifndef CONFIG_USER_ONLY +#include "sysemu/sysemu.h" +#endif typedef enum UHIOp { UHI_exit = 1,
@@ -71,6 +74,12 @@ enum UHIOpenFlags { UHIOpen_EXCL = 0x800 }; +#ifdef CONFIG_USER_ONLY +/* Suppress compiler errors in linux-user. */ +static const char **semihosting_argv; +static int semihosting_argc; +#endif +static int copy_stat_to_target (CPUMIPSState *env,const struct stat *src,target_ulong vaddr) {
@@ -169,6 +178,21 @@ static int read_from_file(CPUMIPSState *env, target_ulong fd,return num_of_bytes; } +static int copy_argn_to_target (CPUMIPSState *env,int arg_num, +target_ulong vaddr) +{ +int strsize =strlen (semihosting_argv[arg_num]) +1 ; +char *dst =lock_user (VERIFY_WRITE , vaddr, strsize,0 ); +if (!dst) { +return -1 ; + } + +strcpy (dst, semihosting_argv[arg_num]); + +unlock_user (dst, vaddr, strsize); +return 0 ; +} +#define GET_TARGET_STRING (p, addr) \ do { \ p = lock_user_string(addr); \
@@ -248,9 +272,21 @@ void helper_do_semihosting(CPUMIPSState *env) }break ;case UHI_argc: + gpr[2 ] = semihosting_argc; +break ;case UHI_argnlen: +if (gpr[4 ] >= semihosting_argc) { + gpr[2 ] =-1 ; + goto uhi_done; + } + gpr[2 ] =strlen (semihosting_argv[gpr[4 ]]); +break ;case UHI_argn: -/* TODO */ +if (gpr[4 ] >= semihosting_argc) { + gpr[2 ] =-1 ; + goto uhi_done; + } + gpr[2 ] =copy_argn_to_target (env, gpr[4 ], gpr[5 ]);break ;case UHI_plog:GET_TARGET_STRING (p, gpr[4 ]);
target-mips/translate.c +7 -0
@@ -19652,6 +19652,13 @@ void cpu_state_reset(CPUMIPSState *env)restore_rounding_mode (env);restore_flush_mode (env); cs->exception_index =EXCP_NONE ; + +#ifndef CONFIG_USER_ONLY +if (semihosting_enabled) { +/* When $4 is -1 the UHI interface will be used for argc and argv */ + env->active_tc.gpr[4 ] =-1 ; + } +#endif }void restore_state_to_opc (CPUMIPSState *env,TranslationBlock *tb,int pc_pos)
vl.c +28 -0
@@ -169,6 +169,8 @@ const char *watchdog;QEMUOptionRom option_rom[MAX_OPTION_ROMS ];int nb_option_roms;int semihosting_enabled =0 ; +const char **semihosting_argv; +int semihosting_argc;int old_param =0 ;const char *qemu_name;int alt_grab =0 ;
@@ -3560,6 +3562,22 @@ int main(int argc, char **argv, char **envp)exit (1 ); }break ; +case QEMU_OPTION_semihosting_arg: +if (semihosting_argc ==0 ) { +/* If arguments are present then the first argument goes to +argv[1] as argv[0] is reserved for the program name */ + semihosting_argc =2 ; + semihosting_argv = +g_malloc (semihosting_argc *sizeof (void *)); + semihosting_argv[1 ] = optarg; + }else { + semihosting_argc++; + semihosting_argv = +g_realloc (semihosting_argv, + semihosting_argc *sizeof (void *)); + semihosting_argv[semihosting_argc -1 ] = optarg; + } +break ;case QEMU_OPTION_tdf:fprintf (stderr,"Warning: user space PIT time drift fix " "is no longer supported.\n" );
@@ -4078,6 +4096,16 @@ int main(int argc, char **argv, char **envp) current_machine->kernel_cmdline = (char *)kernel_cmdline; } +if (semihosting_argc) { +if (kernel_filename) { + semihosting_argv[0 ] = kernel_filename; + }else if (bios_name) { + semihosting_argv[0 ] = bios_name; + }else { + semihosting_argv[0 ] ="" ; + } + } + linux_boot = (kernel_filename !=NULL );if (!linux_boot && *kernel_cmdline !='\0' ) {
Signature · 1 line
2.1.0
Re: [Qemu-devel] [PATCH 3/4] target-mips: add "-semihosting-arg" option and implement UHI Arg* ops
Quoted 6 lines
Add new command line option "-semihosting-arg". It is used for passing input arguments to the guest in semihosting mode. The option can be used multiple times. If n arguments are passed, then argument count (
semihosting_argc) will be equal to n+1 as semihosting_argv[0] points at the program name. However, if no arguments are passed then argument count will be 0.
Is there any specific reason for not passing the name of the executable even if no -semihosting-arg is present?
I think there are the following cases:
1) one or more -semihosting-arg options are given. So n+1 arguments are passed with the first one being kernel/boot name if available. The arguments are passed using UHI argc/argn operations (a0 == -1).
2) No -semihosting-arg options are given but the kernel/boot name is known. This could be passed either via the normal argument passing conventions that are already in place or via argc/argn operations.
3) No -semihosting arg options and unknown application name. For this you could again either do what is already done and pass kernel/append options or set a0=0 and indicate that there is no information at all.
I wonder if there should be some detection of using both -semihosting-arg and -append? I think they are in direct conflict. It would probably be good to have cases 2/3 above do the same as what happened before and pass kernel name + append options. (By that I also mean setting up the argv array directly and setting a0 to a positive value (2) rather than using the new interface).
While it may not be used, this would theoretically allow a kernel to be booted with -semihosting enabled, pass arguments in the same way they always have and allow very early boot to emit messages using UHI. I.e. the kernel will almost certainly never use the argc/argn/argnlen interface.
I don't have any comments on the code except to say it looks to match the spec for argc/argn/argnlen.
Thanks,
Matthew
PATCH 4/4 hw/mips: Do not clear BEV for MIPS malta kernel load
In reply to Leon AlraeFrom: Matthew Fortune <[email protected]>
The BEV flag controls whether the boot exception vector is still in place when starting a kernel. When cleared the exception vector at EBASE (or hard coded address of 0x80000000) is used instead.
The early stages of the linux kernel would benefit from BEV still being set to ensure any faults get handled by the boot rom exception handlers. This is a moot point for system qemu as there aren't really any BEV handlers, but there are other good reasons to change this...
The UHI (semi-hosting interface) defines special behaviours depending on whether an application starts in an environment with BEV set or cleared. When BEV is set then UHI assumes that a bootloader is relatively dumb and has no advanced exception handling logic. However, when BEV is cleared then UHI assumes that the bootloader has the ability to handle UHI exceptions with its exception handlers and will unwind and forward UHI SYSCALL exceptions to the exception vector that was installed prior to running the application.
--- hw/mips/mips_malta.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
hw/mips/mips_malta.c +1 -1
@@ -890,7 +890,7 @@ static void main_cpu_reset(void *opaque)read only location. The kernel location and the arguments table location does not change. */ if (loaderparams.kernel_filename) { - env->CP0_Status &= ~((1 << CP0St_BEV) | (1 << CP0St_ERL)); + env->CP0_Status &= ~(1 << CP0St_ERL); }malta_mips_config (cpu);
Signature · 1 line
2.1.0