aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorWeiwei Li <liweiwei@iscas.ac.cn>2023-03-27 16:08:55 +0800
committerAlistair Francis <alistair.francis@wdc.com>2023-05-05 10:49:50 +1000
commit628f0ec1ed631594395bda5e79aaf3e4bd641b6e (patch)
treea627bcdb9b65e69d6d980476ec97e42e099c1d92
parentb3c5077befaebf2281515f36ddbf482f3e0818aa (diff)
downloadqemu-628f0ec1ed631594395bda5e79aaf3e4bd641b6e.zip
qemu-628f0ec1ed631594395bda5e79aaf3e4bd641b6e.tar.gz
qemu-628f0ec1ed631594395bda5e79aaf3e4bd641b6e.tar.bz2
target/riscv: Remove redundant parentheses
Remove redundant parentheses in get_physical_address. Signed-off-by: Weiwei Li <liweiwei@iscas.ac.cn> Signed-off-by: Junqiang Wang <wangjunqiang@iscas.ac.cn> Reviewed-by: Richard Henderson <richard.henderson@linaro.org> Reviewed-by: LIU Zhiwei <zhiwei_liu@linux.alibaba.com> Reviewed-by: Alistair Francis <alistair.francis@wdc.com> Message-Id: <20230327080858.39703-8-liweiwei@iscas.ac.cn> Signed-off-by: Alistair Francis <alistair.francis@wdc.com>
-rw-r--r--target/riscv/cpu_helper.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/target/riscv/cpu_helper.c b/target/riscv/cpu_helper.c
index c7bc3fc..9e2be29 100644
--- a/target/riscv/cpu_helper.c
+++ b/target/riscv/cpu_helper.c
@@ -1051,7 +1051,7 @@ restart:
if ((pte & PTE_R) || ((pte & PTE_X) && mxr)) {
*prot |= PAGE_READ;
}
- if ((pte & PTE_X)) {
+ if (pte & PTE_X) {
*prot |= PAGE_EXEC;
}
/* add write permission on stores or if the page is already dirty,