]> git.proxmox.com Git - mirror_ubuntu-bionic-kernel.git/commit
PCI: Prevent sysfs disable of device while driver is attached
authorChristoph Hellwig <hch@lst.de>
Fri, 18 May 2018 16:56:24 +0000 (18:56 +0200)
committerStefan Bader <stefan.bader@canonical.com>
Fri, 1 Mar 2019 13:20:37 +0000 (14:20 +0100)
commitbec1d6604bec49c5d2d95ec4d0e12b75ed1d4035
tree7aa7cbcbd8f80a3f76c772b69f2bc25d33bff00e
parentbf2f71792229f407ed1b69fa0fcb71a6ecde2804
PCI: Prevent sysfs disable of device while driver is attached

BugLink: http://bugs.launchpad.net/bugs/1815234
[ Upstream commit 6f5cdfa802733dcb561bf664cc89d203f2fd958f ]

Manipulating the enable_cnt behind the back of the driver will wreak
complete havoc with the kernel state, so disallow it.

Signed-off-by: Christoph Hellwig <hch@lst.de>
Signed-off-by: Bjorn Helgaas <bhelgaas@google.com>
Reviewed-by: Johannes Thumshirn <jthumshirn@suse.de>
Acked-by: Keith Busch <keith.busch@intel.com>
Signed-off-by: Sasha Levin <alexander.levin@microsoft.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Signed-off-by: Kamal Mostafa <kamal@canonical.com>
Signed-off-by: Stefan Bader <stefan.bader@canonical.com>
drivers/pci/pci-sysfs.c