From: Konrad Rzeszutek Wilk <konrad.wilk@oracle.com>
To: xen-devel@lists.xenproject.org, jbeulich@suse.com
Subject: PCIe devices that are hotplugged after MMIO has been setup fail due to _CRS not covering 64-bit area
Date: Tue, 27 Sep 2016 10:43:38 -0400 [thread overview]
Message-ID: <20160927144338.GH16528@localhost.localdomain> (raw)
Hey!
If the guest is booted with 'pci' we nicely expand the MMIO region below
4GB and try to fit in the BARs in there. If that fails (not enough
space) we move it above the memory (64-bit). And throughout all of this
we also update the _CRS field to cover these ranges.
(Note, I need to check if the 64-bit area is also set, I think it is).
But the situation is different if we hot-plug a device that has too big
BAR to fit in the MMIO region. We move it in the 64-bit area but we
don't update the _CRS. Which means that Linux will complain (unless
booted with pci=nocrs)). Not sure about Windows but I would assume so
to.
I was wondering what would be a good way to solve this? I looked at some
Dell machines to see how they deal with hotplug PCIe devices and they
just declared all the memory in the _CRS (including RAM).
We could do a hybrid - during bootup make the _CRS region have entry from
end of RAM to .. end of memory?
Or perhaps add some extra logic between QEMU and ACPI AML to expand (or
perhaps modify the last _CRS entry) when PCIe devices are hotplugged?
I am wondering what folks think is the best way going forward?
_______________________________________________
Xen-devel mailing list
Xen-devel@lists.xen.org
https://lists.xen.org/xen-devel
next reply other threads:[~2016-09-27 14:43 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-09-27 14:43 Konrad Rzeszutek Wilk [this message]
2016-09-28 9:21 ` PCIe devices that are hotplugged after MMIO has been setup fail due to _CRS not covering 64-bit area Jan Beulich
2016-09-28 9:52 ` Konrad Rzeszutek Wilk
2016-10-12 21:15 ` Konrad Rzeszutek Wilk
2016-10-13 9:20 ` Jan Beulich
2016-11-01 14:39 ` Konrad Rzeszutek Wilk
2016-11-01 14:56 ` Konrad Rzeszutek Wilk
2016-11-02 10:14 ` Jan Beulich
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=20160927144338.GH16528@localhost.localdomain \
--to=konrad.wilk@oracle.com \
--cc=jbeulich@suse.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).