target/mips: Add missing CP0 check to nanoMIPS RDPGPR / WRPGPR opcodes
commit298d43c96b0f7dc7ea6550ea73b128b3d4ed67f9
authorPhilippe Mathieu-Daudé <f4bug@amsat.org>
Wed, 21 Apr 2021 18:39:15 +0000 (21 20:39 +0200)
committerPhilippe Mathieu-Daudé <f4bug@amsat.org>
Sun, 2 May 2021 14:49:34 +0000 (2 16:49 +0200)
treeea6978eb693ae02460b7f78bfdfd1047136c9d15
parent84c2fdc397b6609d1cef76aec2f1367139d1372e
target/mips: Add missing CP0 check to nanoMIPS RDPGPR / WRPGPR opcodes

Per the nanoMIPS32 Instruction Set Technical Reference Manual,
Revision 01.01, Chapter 3. "Instruction Definitions":

The Read/Write Previous GPR opcodes "require CP0 privilege".

Add the missing CP0 checks.

Signed-off-by: Philippe Mathieu-Daudé <f4bug@amsat.org>
Reviewed-by: Richard Henderson <richard.henderson@linaro.org>
Message-Id: <20210421185007.2231855-1-f4bug@amsat.org>
target/mips/translate.c