From: "Durrant, Paul" <pdurrant@amazon.co.uk>
To: Paul Durrant <paul@xen.org>,
"xen-devel@lists.xenproject.org" <xen-devel@lists.xenproject.org>
Cc: "Kevin Tian" <kevin.tian@intel.com>,
"Stefano Stabellini" <sstabellini@kernel.org>,
"Julien Grall" <julien@xen.org>,
"Jun Nakajima" <jun.nakajima@intel.com>, "Wei Liu" <wl@xen.org>,
"Andrew Cooper" <andrew.cooper3@citrix.com>,
"Ian Jackson" <ian.jackson@eu.citrix.com>,
"George Dunlap" <george.dunlap@citrix.com>,
"Jan Beulich" <jbeulich@suse.com>,
"Roger Pau Monné" <roger.pau@citrix.com>
Subject: RE: [PATCH v2 08/10] remove remaining uses of iommu_legacy_map/unmap
Date: Fri, 31 Jul 2020 09:21:58 +0000 [thread overview]
Message-ID: <ccd1e0d3ba334dc5b1ba37734f581b3b@EX13D32EUC003.ant.amazon.com> (raw)
In-Reply-To: <20200730142926.6051-9-paul@xen.org>
> -----Original Message-----
> From: Paul Durrant <paul@xen.org>
> Sent: 30 July 2020 15:29
> To: xen-devel@lists.xenproject.org
> Cc: Durrant, Paul <pdurrant@amazon.co.uk>; Jan Beulich <jbeulich@suse.com>; Andrew Cooper
> <andrew.cooper3@citrix.com>; Wei Liu <wl@xen.org>; Roger Pau Monné <roger.pau@citrix.com>; George
> Dunlap <george.dunlap@citrix.com>; Ian Jackson <ian.jackson@eu.citrix.com>; Julien Grall
> <julien@xen.org>; Stefano Stabellini <sstabellini@kernel.org>; Jun Nakajima <jun.nakajima@intel.com>;
> Kevin Tian <kevin.tian@intel.com>
> Subject: [EXTERNAL] [PATCH v2 08/10] remove remaining uses of iommu_legacy_map/unmap
>
> CAUTION: This email originated from outside of the organization. Do not click links or open
> attachments unless you can confirm the sender and know the content is safe.
>
>
>
> From: Paul Durrant <pdurrant@amazon.com>
>
> The 'legacy' functions do implicit flushing so amend the callers to do the
> appropriate flushing.
>
> Unfortunately, because of the structure of the P2M code, we cannot remove
> the per-CPU 'iommu_dont_flush_iotlb' global and the optimization it
> facilitates. It is now checked directly iommu_iotlb_flush(). Also, it is
> now declared as bool (rather than bool_t) and setting/clearing it are no
> longer pointlessly gated on is_iommu_enabled() returning true. (Arguably
> it is also pointless to gate the call to iommu_iotlb_flush() on that
> condition - since it is a no-op in that case - but the if clause allows
> the scope of a stack variable to be restricted).
>
> NOTE: The code in memory_add() now fails if the number of pages passed to
> a single call overflows an unsigned int. I don't believe this will
> ever happen in practice.
>
> Signed-off-by: Paul Durrant <pdurrant@amazon.com>
I realise now that I completely forgot to address Jan's comments on grant table locking and flush batching, so there will be a v3 of at least this patch.
Paul
next prev parent reply other threads:[~2020-07-31 9:22 UTC|newest]
Thread overview: 12+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-07-30 14:29 [PATCH v2 00/10] IOMMU cleanup Paul Durrant
2020-07-30 14:29 ` [PATCH v2 01/10] x86/iommu: re-arrange arch_iommu to separate common fields Paul Durrant
2020-07-30 14:29 ` [PATCH v2 02/10] x86/iommu: add common page-table allocator Paul Durrant
2020-07-30 14:29 ` [PATCH v2 03/10] x86/iommu: convert VT-d code to use new page table allocator Paul Durrant
2020-07-30 14:29 ` [PATCH v2 04/10] x86/iommu: convert AMD IOMMU " Paul Durrant
2020-07-30 14:29 ` [PATCH v2 05/10] iommu: remove unused iommu_ops method and tasklet Paul Durrant
2020-07-30 14:29 ` [PATCH v2 06/10] iommu: flush I/O TLB if iommu_map() or iommu_unmap() fail Paul Durrant
2020-07-30 14:29 ` [PATCH v2 07/10] iommu: make map, unmap and flush all take both an order and a count Paul Durrant
2020-07-30 14:29 ` [PATCH v2 08/10] remove remaining uses of iommu_legacy_map/unmap Paul Durrant
2020-07-31 9:21 ` Durrant, Paul [this message]
2020-07-30 14:29 ` [PATCH v2 09/10] iommu: remove the share_p2m operation Paul Durrant
2020-07-30 14:29 ` [PATCH v2 10/10] iommu: stop calling IOMMU page tables 'p2m tables' Paul Durrant
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=ccd1e0d3ba334dc5b1ba37734f581b3b@EX13D32EUC003.ant.amazon.com \
--to=pdurrant@amazon.co.uk \
--cc=andrew.cooper3@citrix.com \
--cc=george.dunlap@citrix.com \
--cc=ian.jackson@eu.citrix.com \
--cc=jbeulich@suse.com \
--cc=julien@xen.org \
--cc=jun.nakajima@intel.com \
--cc=kevin.tian@intel.com \
--cc=paul@xen.org \
--cc=roger.pau@citrix.com \
--cc=sstabellini@kernel.org \
--cc=wl@xen.org \
--cc=xen-devel@lists.xenproject.org \
/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.