[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [PATCH v2] target/riscv: Do not include 'pmp.h' in user emulation
From: |
Alistair Francis |
Subject: |
Re: [PATCH v2] target/riscv: Do not include 'pmp.h' in user emulation |
Date: |
Tue, 18 May 2021 16:33:02 +1000 |
On Mon, May 17, 2021 at 6:53 AM Philippe Mathieu-Daudé <f4bug@amsat.org> wrote:
>
> Physical Memory Protection is a system feature.
> Avoid polluting the user-mode emulation by its definitions.
>
> Signed-off-by: Philippe Mathieu-Daudé <f4bug@amsat.org>
Reviewed-by: Alistair Francis <alistair.francis@wdc.com>
Alistair
> ---
> target/riscv/cpu.h | 2 ++
> 1 file changed, 2 insertions(+)
>
> diff --git a/target/riscv/cpu.h b/target/riscv/cpu.h
> index 7e879fb9ca5..0619b491a42 100644
> --- a/target/riscv/cpu.h
> +++ b/target/riscv/cpu.h
> @@ -97,7 +97,9 @@ enum {
>
> typedef struct CPURISCVState CPURISCVState;
>
> +#if !defined(CONFIG_USER_ONLY)
> #include "pmp.h"
> +#endif
>
> #define RV_VLEN_MAX 256
>
> --
> 2.26.3
>
>