mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git
synced 2024-09-29 22:02:02 +00:00
media: ipu3-cio2: Fix PM runtime usage_count in driver unbind
commit909d3096ac
upstream. Get the PM runtime usage_count and forbid PM runtime at driver unbind. The opposite is being done in probe() already. Fixes: commitc2a6a07afe
("media: intel-ipu3: cio2: add new MIPI-CSI2 driver") Cc: stable@vger.kernel.org # for >= 4.16 Signed-off-by: Sakari Ailus <sakari.ailus@linux.intel.com> Reviewed-by: Bingbu Cao <bingbu.cao@intel.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@kernel.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
This commit is contained in:
parent
e39c25b0c1
commit
9b15b558cd
1 changed files with 3 additions and 0 deletions
|
@ -1843,6 +1843,9 @@ static void cio2_pci_remove(struct pci_dev *pci_dev)
|
|||
v4l2_device_unregister(&cio2->v4l2_dev);
|
||||
media_device_cleanup(&cio2->media_dev);
|
||||
mutex_destroy(&cio2->lock);
|
||||
|
||||
pm_runtime_forbid(&pci_dev->dev);
|
||||
pm_runtime_get_noresume(&pci_dev->dev);
|
||||
}
|
||||
|
||||
static int __maybe_unused cio2_runtime_suspend(struct device *dev)
|
||||
|
|
Loading…
Reference in a new issue