From: Jason Gunthorpe <jgg@nvidia.com>
To: Shameer Kolothum <shameerali.kolothum.thodi@huawei.com>
Cc: iommu@lists.linux.dev, linux-arm-kernel@lists.infradead.org,
robin.murphy@arm.com, will@kernel.org, joro@8bytes.org,
ryan.roberts@arm.com, kevin.tian@intel.com, nicolinc@nvidia.com,
mshavit@google.com, eric.auger@redhat.com,
joao.m.martins@oracle.com, jiangkunkun@huawei.com,
zhukeqian1@huawei.com, linuxarm@huawei.com
Subject: Re: [PATCH v4 5/7] iommu/io-pgtable-arm: Add read_and_clear_dirty() support
Date: Sat, 1 Jun 2024 18:17:01 -0300 [thread overview]
Message-ID: <ZluPzQL/qF9A77du@nvidia.com> (raw)
In-Reply-To: <20240528071831.17560-6-shameerali.kolothum.thodi@huawei.com>
On Tue, May 28, 2024 at 08:18:29AM +0100, Shameer Kolothum wrote:
> .read_and_clear_dirty() IOMMU domain op takes care of reading the dirty
> bits (i.e. PTE has DBM set and AP[2] clear) and marshalling into a
> bitmap of a given page size.
>
> While reading the dirty bits we also set the PTE AP[2] bit to mark it
> as writeable-clean depending on read_and_clear_dirty() flags.
>
> PTE states with respect to DBM bit:
>
> DBM bit AP[2]("RDONLY" bit)
> 1. writable_clean 1 1
> 2. writable_dirty 1 0
> 3. read-only 0 1
>
> Reviewed-by: Ryan Roberts <ryan.roberts@arm.com>
> Signed-off-by: Shameer Kolothum <shameerali.kolothum.thodi@huawei.com>
> ---
> drivers/iommu/io-pgtable-arm.c | 114 ++++++++++++++++++++++++++++++++-
> 1 file changed, 112 insertions(+), 2 deletions(-)
Reviewed-by: Jason Gunthorpe <jgg@nvidia.com>
Jason
_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel
next prev parent reply other threads:[~2024-06-01 21:32 UTC|newest]
Thread overview: 12+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-05-28 7:18 [PATCH v4 0/7] iommu/smmuv3: Add IOMMUFD dirty tracking support for SMMUv3 Shameer Kolothum
2024-05-28 7:18 ` [PATCH v4 1/7] iommu/arm-smmu-v3: Convert to domain_alloc_sva() Shameer Kolothum
2024-05-28 7:18 ` [PATCH v4 2/7] iommu/arm-smmu-v3: Factor out a common arm_smmu_domain_alloc() Shameer Kolothum
2024-06-01 21:06 ` Jason Gunthorpe
2024-06-05 15:19 ` Shameerali Kolothum Thodi
2024-05-28 7:18 ` [PATCH v4 3/7] iommu/arm-smmu-v3: Add support for domain_alloc_user fn Shameer Kolothum
2024-06-01 21:08 ` Jason Gunthorpe
2024-05-28 7:18 ` [PATCH v4 4/7] iommu/arm-smmu-v3: Add feature detection for HTTU Shameer Kolothum
2024-05-28 7:18 ` [PATCH v4 5/7] iommu/io-pgtable-arm: Add read_and_clear_dirty() support Shameer Kolothum
2024-06-01 21:17 ` Jason Gunthorpe [this message]
2024-05-28 7:18 ` [PATCH v4 6/7] iommu/arm-smmu-v3: Add support for dirty tracking in domain alloc Shameer Kolothum
2024-05-28 7:18 ` [PATCH v4 7/7] iommu/arm-smmu-v3: Enable HTTU for stage1 with io-pgtable mapping Shameer Kolothum
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=ZluPzQL/qF9A77du@nvidia.com \
--to=jgg@nvidia.com \
--cc=eric.auger@redhat.com \
--cc=iommu@lists.linux.dev \
--cc=jiangkunkun@huawei.com \
--cc=joao.m.martins@oracle.com \
--cc=joro@8bytes.org \
--cc=kevin.tian@intel.com \
--cc=linux-arm-kernel@lists.infradead.org \
--cc=linuxarm@huawei.com \
--cc=mshavit@google.com \
--cc=nicolinc@nvidia.com \
--cc=robin.murphy@arm.com \
--cc=ryan.roberts@arm.com \
--cc=shameerali.kolothum.thodi@huawei.com \
--cc=will@kernel.org \
--cc=zhukeqian1@huawei.com \
/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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).