]> git.kernelconcepts.de Git - karo-tx-linux.git/commit
vfio-pci: Move idle devices to D3hot power state
authorAlex Williamson <alex.williamson@redhat.com>
Tue, 7 Apr 2015 17:14:46 +0000 (11:14 -0600)
committerAlex Williamson <alex.williamson@redhat.com>
Tue, 7 Apr 2015 17:14:46 +0000 (11:14 -0600)
commit6eb7018705de09b4138ca05d6a157203e0ea791a
tree3febc7c9c86ca1ec65c57529501f70c26d9322ba
parent561d72ddbbe480e2cae6c1a63c688986586ef2b1
vfio-pci: Move idle devices to D3hot power state

We can save some power by putting devices that are bound to vfio-pci
but not in use by the user in the D3hot power state.  Devices get
woken into D0 when opened by the user.  Resets return the device to
D0, so we need to re-apply the low power state after a bus reset.
It's tempting to try to use D3cold, but we have no reason to inhibit
hotplug of idle devices and we might get into a loop of having the
device disappear before we have a chance to try to use it.

A new module parameter allows this feature to be disabled if there are
devices that misbehave as a result of this change.

Signed-off-by: Alex Williamson <alex.williamson@redhat.com>
drivers/vfio/pci/vfio_pci.c