]> git.proxmox.com Git - mirror_ubuntu-focal-kernel.git/commit
powerpc/powernv/ioda: Release opencapi device
authorFrederic Barrat <fbarrat@linux.ibm.com>
Mon, 24 Feb 2020 15:52:26 +0000 (16:52 +0100)
committerSeth Forshee <seth.forshee@canonical.com>
Wed, 26 Feb 2020 02:34:10 +0000 (20:34 -0600)
commit25066f5e78d2161b7caa98e7747f49661e86f2d0
tree90a9b19bfed8066c6d001e6e3b8ae38c6b283c19
parenteb744dac5331fcba6c97aa15caaf5c5d2b9236ec
powerpc/powernv/ioda: Release opencapi device

BugLink: https://bugs.launchpad.net/bugs/1862121
With hotplug, an opencapi device can now go away. It needs to be
released, mostly to clean up its PE state. We were previously not
defining any device callback. We can reuse the standard PCI release
callback, it does a bit too much for an opencapi device, but it's
harmless, and only needs minor tuning.

Also separate the undo of the PELT-V code in a separate function, it
is not needed for NPU devices and it improves a bit the readability of
the code.

Signed-off-by: Frederic Barrat <fbarrat@linux.ibm.com>
Reviewed-by: Andrew Donnellan <ajd@linux.ibm.com>
Signed-off-by: Michael Ellerman <mpe@ellerman.id.au>
Link: https://lore.kernel.org/r/20191121134918.7155-5-fbarrat@linux.ibm.com
(cherry picked from commit f724385fea0136af31a850fbcff01a6e8cf8c889)
Signed-off-by: Frank Heimes <frank.heimes@canonical.com>
Signed-off-by: Seth Forshee <seth.forshee@canonical.com>
arch/powerpc/platforms/powernv/pci-ioda.c