Re: [PATCH v3 30/42] target/arm: Add ptw_idx argument to S1_ptw_translate

2022-10-07 Thread Richard Henderson
On 10/7/22 02:19, Peter Maydell wrote: I don't think this works, because the s2_mmu_idx is not necessarily the same through the whole of a page table walk. See the comment in get_phys_addr_lpae(): /* * Secure accesses start with the page table in secure memory and * can be

Re: [PATCH v3 30/42] target/arm: Add ptw_idx argument to S1_ptw_translate

2022-10-07 Thread Peter Maydell
On Sat, 1 Oct 2022 at 17:42, Richard Henderson wrote: > > Hoist the computation of the mmu_idx for the ptw up to > get_phys_addr_with_secure_debug and get_phys_addr_twostage. > This removes the duplicate check for stage2 disabled > from the middle of the walk, performing it only once. > > Pass

[PATCH v3 30/42] target/arm: Add ptw_idx argument to S1_ptw_translate

2022-10-01 Thread Richard Henderson
Hoist the computation of the mmu_idx for the ptw up to get_phys_addr_with_secure_debug and get_phys_addr_twostage. This removes the duplicate check for stage2 disabled from the middle of the walk, performing it only once. Pass ptw_idx through get_phys_addr_{v5,v6,lpae} and arm_{ldl,ldq}_ptw.