[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Qemu-devel] [PATCH v2 14/14] target-arm: Check watchpoints against
From: |
Alex Bennée |
Subject: |
Re: [Qemu-devel] [PATCH v2 14/14] target-arm: Check watchpoints against CPU security state |
Date: |
Tue, 21 Apr 2015 10:37:55 +0100 |
Peter Maydell <address@hidden> writes:
> Fix a TODO in bp_wp_matches() now that we have a function for
> testing whether the CPU is currently in Secure mode or not.
>
> Signed-off-by: Peter Maydell <address@hidden>
> Reviewed-by: Edgar E. Iglesias <address@hidden>
Reviewed-by: Alex Bennée <address@hidden>
> ---
> target-arm/op_helper.c | 6 ++++--
> 1 file changed, 4 insertions(+), 2 deletions(-)
>
> diff --git a/target-arm/op_helper.c b/target-arm/op_helper.c
> index 4a8c4e0..3df9c57 100644
> --- a/target-arm/op_helper.c
> +++ b/target-arm/op_helper.c
> @@ -600,8 +600,10 @@ static bool bp_wp_matches(ARMCPU *cpu, int n, bool is_wp)
> CPUARMState *env = &cpu->env;
> uint64_t cr;
> int pac, hmc, ssc, wt, lbn;
> - /* TODO: check against CPU security state when we implement TrustZone */
> - bool is_secure = false;
> + /* Note that for watchpoints the check is against the CPU security
> + * state, not the S/NS attribute on the offending data access.
> + */
> + bool is_secure = arm_is_secure(env);
> int access_el = arm_current_el(env);
>
> if (is_wp) {
--
Alex Bennée
- [Qemu-devel] [PATCH v2 00/14] Add memory attributes and use them in ARM, Peter Maydell, 2015/04/13
- [Qemu-devel] [PATCH v2 14/14] target-arm: Check watchpoints against CPU security state, Peter Maydell, 2015/04/13
- Re: [Qemu-devel] [PATCH v2 14/14] target-arm: Check watchpoints against CPU security state,
Alex Bennée <=
- [Qemu-devel] [PATCH v2 02/14] memory: Replace io_mem_read/write with memory_region_dispatch_read/write, Peter Maydell, 2015/04/13
- [Qemu-devel] [PATCH v2 10/14] target-arm: Honour NS bits in page tables, Peter Maydell, 2015/04/13
- [Qemu-devel] [PATCH v2 03/14] Make CPU iotlb a structure rather than a plain hwaddr, Peter Maydell, 2015/04/13
- [Qemu-devel] [PATCH v2 07/14] exec.c: Add new address_space_ld*/st* functions, Peter Maydell, 2015/04/13
- [Qemu-devel] [PATCH v2 11/14] target-arm: Use correct memory attributes for page table walks, Peter Maydell, 2015/04/13