target/riscv: Fix CSR perm checking for HS mode
commit0a42f4c4408824dc7cb9ff60c9bdce6dcc0d24a5
authorAlistair Francis <alistair.francis@wdc.com>
Sat, 1 Feb 2020 01:01:56 +0000 (31 17:01 -0800)
committerPalmer Dabbelt <palmerdabbelt@google.com>
Thu, 27 Feb 2020 21:45:30 +0000 (27 13:45 -0800)
treedb795a9ed7bc6f8cee2bf8c3ac16abffa4ded30e
parentc7b1bbc80fc2af17395d3986c346fd2307e57829
target/riscv: Fix CSR perm checking for HS mode

Update the CSR permission checking to work correctly when we are in
HS-mode.

Signed-off-by: Alistair Francis <alistair.francis@wdc.com>
Reviewed-by: Palmer Dabbelt <palmerdabbelt@google.com>
Signed-off-by: Palmer Dabbelt <palmerdabbelt@google.com>
target/riscv/csr.c