]> git.baikalelectronics.ru Git - kernel.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)
commit4682d0469d83473490d7d05c886aad453b4be331
tree3febc7c9c86ca1ec65c57529501f70c26d9322ba
parent72973a90204792f8658eac15dda9789803cdaba4
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