All of lore.kernel.org
 help / color / mirror / Atom feed
From: Andrew Jones <andrew.jones@linux.dev>
To: Alexandru Elisei <alexandru.elisei@arm.com>
Cc: kvm@vger.kernel.org, kvmarm@lists.linux.dev,
	kvmarm@lists.cs.columbia.edu
Subject: Re: [kvm-unit-tests PATCH v2 0/2] arm/arm64: teach virt_to_pte_phys() about block descriptors
Date: Tue, 14 Feb 2023 21:23:34 +0100	[thread overview]
Message-ID: <20230214202334.dk22gk4fzy2rkdty@orel> (raw)
In-Reply-To: <20221124152816.22305-1-alexandru.elisei@arm.com>

On Thu, Nov 24, 2022 at 03:28:14PM +0000, Alexandru Elisei wrote:
> I was writing a quick test when I noticed that arm's implementation of
> __virt_to_phys(), which ends up calling virt_to_pte_phys(), doesn't handle
> block mappings and returns a bogus value. When fixing it I got confused
> about mmu_get_pte() and get_pte(), so I (hopefully) improved things by
> renaming mmu_get_pte() to follow_pte().
> 
> Changes since v1:
> 
> - Dropped patch #1 ("lib/vmalloc: Treat virt_to_pte_phys() as returning a
>   physical address") because it was incorrect.
> - Dropped the check for pte_valid() for the return value of mmu_get_pte() in
>   patch #1 because mmu_get_pte() returns NULL for an invalid descriptor.
> 
> Lightly tested on a rockpro64 (4k and 64k pages, arm64 and arm, qemu only)
> because the changes from the previous version are trivial.
> 
> Alexandru Elisei (2):
>   arm/arm64: mmu: Teach virt_to_pte_phys() about block descriptors
>   arm/arm64: mmu: Rename mmu_get_pte() -> follow_pte()
> 
>  lib/arm/asm/mmu-api.h |  2 +-
>  lib/arm/mmu.c         | 88 +++++++++++++++++++++++++------------------
>  2 files changed, 53 insertions(+), 37 deletions(-)
> 
> -- 
> 2.37.0
>

Applied, thanks

      parent reply	other threads:[~2023-02-14 20:23 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-11-24 15:28 [kvm-unit-tests PATCH v2 0/2] arm/arm64: teach virt_to_pte_phys() about block descriptors Alexandru Elisei
2022-11-24 15:28 ` Alexandru Elisei
2022-11-24 15:28 ` [kvm-unit-tests PATCH v2 1/2] arm/arm64: mmu: Teach " Alexandru Elisei
2022-11-24 15:28   ` Alexandru Elisei
2022-11-24 15:28 ` [kvm-unit-tests PATCH v2 2/2] arm/arm64: mmu: Rename mmu_get_pte() -> follow_pte() Alexandru Elisei
2022-11-24 15:28   ` Alexandru Elisei
2023-02-14 20:23 ` Andrew Jones [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20230214202334.dk22gk4fzy2rkdty@orel \
    --to=andrew.jones@linux.dev \
    --cc=alexandru.elisei@arm.com \
    --cc=kvm@vger.kernel.org \
    --cc=kvmarm@lists.cs.columbia.edu \
    --cc=kvmarm@lists.linux.dev \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.