[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [PATCH for-8.1 2/3] target/arm: Fix S1_ptw_translate() debug path
From: |
Peter Maydell |
Subject: |
Re: [PATCH for-8.1 2/3] target/arm: Fix S1_ptw_translate() debug path |
Date: |
Mon, 10 Jul 2023 17:46:42 +0100 |
On Mon, 10 Jul 2023 at 16:21, Peter Maydell <peter.maydell@linaro.org> wrote:
>
> In commit XXX we rearranged the logic in S1_ptw_translate() so that
Should read "commit fe4a5472ccd6" -- I put in the Fixes:
tag below but forgot to update the placeholder in the
commit message text...
> the debug-access "call get_phys_addr_*" codepath is used both when S1
> is doing ptw reads from stage 2 and when it is doing ptw reads from
> physical memory. However, we didn't update the calculation of
> s2ptw->in_space and s2ptw->in_secure to account for the "ptw reads
> from physical memory" case. This meant that debug accesses when in
> Secure state broke.
>
> Create a new function S2_security_space() which returns the
> correct security space to use for the ptw load, and use it to
> determine the correct .in_secure and .in_space fields for the
> stage 2 lookup for the ptw load.
>
> Reported-by: Jean-Philippe Brucker <jean-philippe@linaro.org>
> Fixes: fe4a5472ccd6 ("target/arm: Use get_phys_addr_with_struct in
> S1_ptw_translate")
> Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
-- PMM