From: Paul Durrant <Paul.Durrant@citrix.com>
To: Roger Pau Monne <roger.pau@citrix.com>
Cc: Kevin Tian <kevin.tian@intel.com>,
Stefano Stabellini <sstabellini@kernel.org>,
Wei Liu <wei.liu2@citrix.com>,
Suravee Suthikulpanit <suravee.suthikulpanit@amd.com>,
Andrew Cooper <Andrew.Cooper3@citrix.com>,
"Tim (Xen.org)" <tim@xen.org>,
George Dunlap <George.Dunlap@citrix.com>,
Julien Grall <julien.grall@arm.com>,
Jan Beulich <JBeulich@suse.com>,
xen-devel <xen-devel@lists.xenproject.org>,
Ian Jackson <Ian.Jackson@citrix.com>,
Brian Woods <brian.woods@amd.com>
Subject: Re: [PATCH v2 2/5] iommu: introduce dom0-iommu option
Date: Fri, 3 Aug 2018 09:05:19 +0000 [thread overview]
Message-ID: <90d7eeeaeac34829bb636c2b4b4d19e9@AMSPEX02CL03.citrite.net> (raw)
In-Reply-To: <20180803085204.qld2rb3xqyxgycyo@mac>
> -----Original Message-----
> From: Roger Pau Monne
> Sent: 03 August 2018 09:52
> To: Paul Durrant <Paul.Durrant@citrix.com>
> Cc: Jan Beulich <JBeulich@suse.com>; Kevin Tian <kevin.tian@intel.com>;
> Stefano Stabellini <sstabellini@kernel.org>; Wei Liu <wei.liu2@citrix.com>;
> George Dunlap <George.Dunlap@citrix.com>; Andrew Cooper
> <Andrew.Cooper3@citrix.com>; Ian Jackson <Ian.Jackson@citrix.com>; Tim
> (Xen.org) <tim@xen.org>; Julien Grall <julien.grall@arm.com>; Suravee
> Suthikulpanit <suravee.suthikulpanit@amd.com>; xen-devel <xen-
> devel@lists.xenproject.org>; Brian Woods <brian.woods@amd.com>
> Subject: Re: [Xen-devel] [PATCH v2 2/5] iommu: introduce dom0-iommu
> option
>
> On Fri, Aug 03, 2018 at 09:35:58AM +0100, Paul Durrant wrote:
> > > -----Original Message-----
> > > From: Xen-devel [mailto:xen-devel-bounces@lists.xenproject.org] On
> Behalf
> > > Of Roger Pau Monné
> > > Sent: 03 August 2018 09:14
> > > To: Jan Beulich <JBeulich@suse.com>
> > > Cc: Kevin Tian <kevin.tian@intel.com>; Stefano Stabellini
> > > <sstabellini@kernel.org>; Wei Liu <wei.liu2@citrix.com>; George Dunlap
> > > <George.Dunlap@citrix.com>; Andrew Cooper
> > > <Andrew.Cooper3@citrix.com>; Ian Jackson <Ian.Jackson@citrix.com>;
> Tim
> > > (Xen.org) <tim@xen.org>; Julien Grall <julien.grall@arm.com>; Suravee
> > > Suthikulpanit <suravee.suthikulpanit@amd.com>; xen-devel <xen-
> > > devel@lists.xenproject.org>; Brian Woods <brian.woods@amd.com>
> > > Subject: Re: [Xen-devel] [PATCH v2 2/5] iommu: introduce dom0-iommu
> > > option
> > >
> > > On Thu, Aug 02, 2018 at 02:23:23AM -0600, Jan Beulich wrote:
> > > > >>> On 02.08.18 at 09:46, <kevin.tian@intel.com> wrote:
> > > > >> From: Roger Pau Monne [mailto:roger.pau@citrix.com]
> > > > >> Sent: Wednesday, August 1, 2018 7:04 PM
> > > > >> --- a/docs/misc/xen-command-line.markdown
> > > > >> +++ b/docs/misc/xen-command-line.markdown
> > > > >> @@ -1150,12 +1150,18 @@ detection of systems known to
> misbehave
> > > > >> upon accesses to that port.
> > > > >>
> > > > >> > `dom0-passthrough`
> > > > >>
> > > > >> +> **WARNING: This command line option is deprecated, and
> > > superseded
> > > > >> by
> > > > >> +> _dom0-iommu=none_ - using both options in combination is
> > > > >> undefined.**
> > > > >> +
> > > > >
> > > > > in patch description you said 'supersede'... is it better to say that
> > > > > new dom0_iommu is favored if both options are specified than
> > > > > saying 'undefined'?
> > > >
> > > > That would complicate handling (perhaps just slightly, but anyway),
> > > > since we'd have to maintain a second boolean. Without that the
> > > > order on the command line determines behavior. (And I see that in
> > > > the end you've figured that out.)
> > > >
> > > > >> @@ -1198,6 +1204,32 @@ detection of systems known to
> misbehave
> > > upon
> > > > >> accesses to that port.
> > > > >>
> > > > >> >> Enable IOMMU debugging code (implies `verbose`).
> > > > >>
> > > > >> +### dom0-iommu
> > > > >> +> `= List of [ none | strict | relaxed ]`
> > > > >> +
> > > > >> +> Sub-options are of boolean kind and can be prefixed with `no-` to
> > > effect
> > > > >> the
> > > > >> +> inverse meaning.
> > > > >
> > > > > not important comment, but doesn't "no-none" sound weird? :-)
> > > >
> > > > Only positive (true) values should be permitted for I think all of
> > > > these. I didn't look at the patch yes, so perhaps that's already
> > > > the case.
> > >
> > > For the current set of options introduced in this patch none, strict
> > > or relaxed it doesn't make much sense to allow the no- prefix.
> > >
> > > For options added in later patches (inclusive and reserved) it makes
> > > sense to allow the no- prefix, so that a user can do
> > > 'dom0-iommu=no-inclusive' in order to change the default value.
> > >
> >
> > But what does that mean? 'no-inclusive' clearly means you don't get the
> inclusive map, but what do you get instead? Strict? None?
>
> IMO you always either get no iommu mappings at all (none), only Dom0
> assigned RAM regions (strict) or all RAM except the regions used by
> Xen (relaxed). Those options control what RAM gets mapped into the
> iommu page tables.
>
> Then you can use inclusive to even get more mappings of non-RAM
> regions, but that can be used in conjunction with either strict or
> relaxed and should allow the usage of the no- prefix.
>
> So if you use dom0-iommu=no-inclusive you get the default relaxed RAM
> mappings and that's all.
>
> I hope this makes sense, I will try to clarify the documentation.
>
Actually I wonder whether we should rename 'inclusive' to 'reserved'. Essentially 'none', 'strict' or 'relaxed' are all about mappings of RAM, and then we need to decide whether to map the E820 reserved regions. So I think the inclusive map as it stands today is equivalent to 'relaxed' + 'reserved'.
Paul
> Roger.
_______________________________________________
Xen-devel mailing list
Xen-devel@lists.xenproject.org
https://lists.xenproject.org/mailman/listinfo/xen-devel
next prev parent reply other threads:[~2018-08-03 9:05 UTC|newest]
Thread overview: 29+ messages / expand[flat|nested] mbox.gz Atom feed top
2018-08-01 11:03 [PATCH v2 0/5] x86/iommu: PVH Dom0 workarounds for missing RMRR entries Roger Pau Monne
2018-08-01 11:03 ` [PATCH v2 1/5] iommu/vtd: cleanup vtd_set_hwdom_mapping after ia64 removal Roger Pau Monne
2018-08-01 11:16 ` Paul Durrant
2018-08-02 7:36 ` Tian, Kevin
2018-08-01 11:03 ` [PATCH v2 2/5] iommu: introduce dom0-iommu option Roger Pau Monne
2018-08-01 11:15 ` Paul Durrant
2018-08-01 11:16 ` Andrew Cooper
2018-08-02 7:46 ` Tian, Kevin
2018-08-02 8:23 ` Jan Beulich
2018-08-03 8:14 ` Roger Pau Monné
2018-08-03 8:35 ` Paul Durrant
2018-08-03 8:52 ` Roger Pau Monné
2018-08-03 9:05 ` Paul Durrant [this message]
2018-08-03 9:08 ` Roger Pau Monné
2018-08-03 9:14 ` Paul Durrant
2018-08-03 9:32 ` Roger Pau Monné
2018-08-03 9:37 ` Paul Durrant
2018-08-06 3:19 ` Tian, Kevin
2018-08-06 7:51 ` Paul Durrant
2018-08-06 9:09 ` Roger Pau Monné
2018-08-01 11:03 ` [PATCH v2 3/5] iommu: make iommu_inclusive_mapping a suboption of dom0-iommu Roger Pau Monne
2018-08-01 11:21 ` Paul Durrant
2018-08-02 7:58 ` Tian, Kevin
2018-08-03 10:39 ` Roger Pau Monné
2018-08-03 9:09 ` Julien Grall
2018-08-01 11:03 ` [PATCH v2 4/5] dom0/pvh: change the order of the MMCFG initialization Roger Pau Monne
2018-08-01 11:03 ` [PATCH v2 5/5] x86/iommu: add PVH support to the inclusive options Roger Pau Monne
2018-08-01 11:27 ` Paul Durrant
2018-08-02 8:03 ` Tian, Kevin
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=90d7eeeaeac34829bb636c2b4b4d19e9@AMSPEX02CL03.citrite.net \
--to=paul.durrant@citrix.com \
--cc=Andrew.Cooper3@citrix.com \
--cc=George.Dunlap@citrix.com \
--cc=Ian.Jackson@citrix.com \
--cc=JBeulich@suse.com \
--cc=brian.woods@amd.com \
--cc=julien.grall@arm.com \
--cc=kevin.tian@intel.com \
--cc=roger.pau@citrix.com \
--cc=sstabellini@kernel.org \
--cc=suravee.suthikulpanit@amd.com \
--cc=tim@xen.org \
--cc=wei.liu2@citrix.com \
--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 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).