Re: [kvm-unit-tests PATCH v2 3/3] s390x: mvpg-sie: fix virtual-physical address confusion

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Mon,  6 Nov 2023 18:08:02 +0100
Nico Boehr <nrb@xxxxxxxxxxxxx> wrote:

> The addresses reported for the partial execution of mvpg instruction are
> physical addresses. Now that MSO is a virtual address, we can't simply
> compare the PEI fields in the sie block with MSO, but need to do an
> additional translation step.
> 
> Add the necessary virtual-physical translations and expose the
> virt_to_pte_phys() function in mmu.h which is useful for this kind of
> translation.
> 
> Signed-off-by: Nico Boehr <nrb@xxxxxxxxxxxxx>
> ---
>  lib/s390x/mmu.h  |  2 ++
>  s390x/mvpg-sie.c | 15 +++++++++++----
>  2 files changed, 13 insertions(+), 4 deletions(-)
> 
> diff --git a/lib/s390x/mmu.h b/lib/s390x/mmu.h
> index dadc2e600f9a..e9e837236603 100644
> --- a/lib/s390x/mmu.h
> +++ b/lib/s390x/mmu.h
> @@ -95,4 +95,6 @@ static inline void unprotect_page(void *vaddr, unsigned long prot)
>  
>  void *get_dat_entry(pgd_t *pgtable, void *vaddr, enum pgt_level level);
>  
> +phys_addr_t virt_to_pte_phys(pgd_t *pgtable, void *vaddr);

or just #include <vmalloc.h> ?

[...]



[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [Kernel Development]     [Kernel Newbies]     [IDE]     [Security]     [Git]     [Netfilter]     [Bugtraq]     [Yosemite Info]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux ATA RAID]     [Samba]     [Linux Media]     [Device Mapper]

  Powered by Linux