kvm.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Will Deacon <will@kernel.org>
To: kvm@vger.kernel.org, Alexandru Elisei <alexandru.elisei@arm.com>
Cc: catalin.marinas@arm.com, Will Deacon <will@kernel.org>,
	sami.mujawar@arm.com, andre.przywara@arm.com,
	lorenzo.pieralisi@arm.com, julien.thierry.kdev@gmail.com,
	maz@kernel.org
Subject: Re: [PATCH v4 kvmtool 00/12] Add reassignable BARs
Date: Tue, 19 May 2020 17:46:57 +0100	[thread overview]
Message-ID: <158990628245.2471.9765486874976576804.b4-ty@kernel.org> (raw)
In-Reply-To: <1589470709-4104-1-git-send-email-alexandru.elisei@arm.com>

On Thu, 14 May 2020 16:38:17 +0100, Alexandru Elisei wrote:
> kvmtool uses the Linux-only dt property 'linux,pci-probe-only' to prevent
> it from trying to reassign the BARs. Let's make the BARs reassignable so we
> can get rid of this band-aid.
> 
> During device configuration, Linux can assign a region resource to a BAR
> that temporarily overlaps with another device. This means that the code
> that emulates BAR reassignment must be aware of all the registered PCI
> devices. Because of this, and to avoid re-implementing the same code for
> each emulated device, the algorithm for activating/deactivating emulation
> as BAR addresses change lives completely inside the PCI code. Each device
> registers two callback functions which are called when device emulation is
> activated (for example, to activate emulation for a newly assigned BAR
> address), respectively, when device emulation is deactivated (a previous
> BAR address is changed, and emulation for that region must be deactivated).
> 
> [...]

Applied to kvmtool (master), thanks!

[01/12] ioport: mmio: Use a mutex and reference counting for locking
        https://git.kernel.org/will/kvmtool/c/09577ac58fef
[02/12] pci: Add helpers for BAR values and memory/IO space access
        https://git.kernel.org/will/kvmtool/c/2f6384f924d7
[03/12] virtio/pci: Get emulated region address from BARs
        https://git.kernel.org/will/kvmtool/c/e539f3e425fb
[04/12] vfio: Reserve ioports when configuring the BAR
        https://git.kernel.org/will/kvmtool/c/a05e576f7fd8
[05/12] pci: Limit configuration transaction size to 32 bits
        https://git.kernel.org/will/kvmtool/c/6ea32ebdb84b
[06/12] vfio/pci: Don't write configuration value twice
        https://git.kernel.org/will/kvmtool/c/e1d0285c89ae
[07/12] Don't allow more than one framebuffers
        https://git.kernel.org/will/kvmtool/c/cbf3d16fccba
[08/12] pci: Implement callbacks for toggling BAR emulation
        https://git.kernel.org/will/kvmtool/c/5a8e4f25dd7b
[09/12] pci: Toggle BAR I/O and memory space emulation
        https://git.kernel.org/will/kvmtool/c/46e04130d264
[10/12] pci: Implement reassignable BARs
        https://git.kernel.org/will/kvmtool/c/465edc9d0fab
[11/12] arm/fdt: Remove 'linux,pci-probe-only' property
        https://git.kernel.org/will/kvmtool/c/ad5e9056de0c
[12/12] vfio: Trap MMIO access to BAR addresses which aren't page aligned
        https://git.kernel.org/will/kvmtool/c/b4fc4f605fc6

Cheers,
-- 
Will

https://fixes.arm64.dev
https://next.arm64.dev
https://will.arm64.dev

      parent reply	other threads:[~2020-05-19 16:47 UTC|newest]

Thread overview: 22+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-05-14 15:38 [PATCH v4 kvmtool 00/12] Add reassignable BARs Alexandru Elisei
2020-05-14 15:38 ` [PATCH v4 kvmtool 01/12] ioport: mmio: Use a mutex and reference counting for locking Alexandru Elisei
2020-05-15 10:13   ` André Przywara
2020-05-15 13:18     ` Alexandru Elisei
2020-05-14 15:38 ` [PATCH v4 kvmtool 02/12] pci: Add helpers for BAR values and memory/IO space access Alexandru Elisei
2020-05-14 15:38 ` [PATCH v4 kvmtool 03/12] virtio/pci: Get emulated region address from BARs Alexandru Elisei
2020-05-14 15:38 ` [PATCH v4 kvmtool 04/12] vfio: Reserve ioports when configuring the BAR Alexandru Elisei
2020-05-14 15:38 ` [PATCH v4 kvmtool 05/12] pci: Limit configuration transaction size to 32 bits Alexandru Elisei
2020-05-14 15:38 ` [PATCH v4 kvmtool 06/12] vfio/pci: Don't write configuration value twice Alexandru Elisei
2020-05-14 16:55   ` André Przywara
2020-05-14 15:38 ` [PATCH v4 kvmtool 07/12] Don't allow more than one framebuffers Alexandru Elisei
2020-05-14 16:56   ` André Przywara
2020-05-14 15:38 ` [PATCH v4 kvmtool 08/12] pci: Implement callbacks for toggling BAR emulation Alexandru Elisei
2020-05-14 16:56   ` André Przywara
2020-05-14 15:38 ` [PATCH v4 kvmtool 09/12] pci: Toggle BAR I/O and memory space emulation Alexandru Elisei
2020-05-14 15:38 ` [PATCH v4 kvmtool 10/12] pci: Implement reassignable BARs Alexandru Elisei
2020-05-14 16:56   ` André Przywara
2020-05-15 13:25     ` Alexandru Elisei
2020-05-14 15:38 ` [PATCH v4 kvmtool 11/12] arm/fdt: Remove 'linux,pci-probe-only' property Alexandru Elisei
2020-05-14 15:38 ` [PATCH v4 kvmtool 12/12] vfio: Trap MMIO access to BAR addresses which aren't page aligned Alexandru Elisei
2020-05-15 15:38 ` [PATCH v4 kvmtool 00/12] Add reassignable BARs André Przywara
2020-05-19 16:46 ` Will Deacon [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=158990628245.2471.9765486874976576804.b4-ty@kernel.org \
    --to=will@kernel.org \
    --cc=alexandru.elisei@arm.com \
    --cc=andre.przywara@arm.com \
    --cc=catalin.marinas@arm.com \
    --cc=julien.thierry.kdev@gmail.com \
    --cc=kvm@vger.kernel.org \
    --cc=lorenzo.pieralisi@arm.com \
    --cc=maz@kernel.org \
    --cc=sami.mujawar@arm.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).