summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorNiklas Söderlund <niklas.soderlund+renesas@ragnatech.se>2019-06-12 19:45:41 -0400
committerMauro Carvalho Chehab <mchehab+samsung@kernel.org>2019-06-21 16:40:02 -0400
commitb2ef816c3db01f365448e8623c4f1d51cc2ba610 (patch)
tree1f11396dcf961516ced458cbcfbbd4011c952183
parenta244fabc15ffba245f80fd49ab486b9881e9e6de (diff)
downloadlinux-b2ef816c3db01f365448e8623c4f1d51cc2ba610.tar.bz2
media: rcar-vin: Remove unneeded calls to pm_runtime_{enable, disable}
Runtime PM is already enabled unconditionally when the driver is probed and disabled when it's removed. There is no point in doing it again for Gen2 when opening and closing the video device. Signed-off-by: Niklas Söderlund <niklas.soderlund+renesas@ragnatech.se> Reviewed-by: Ulrich Hecht <uli+renesas@fpond.eu> Signed-off-by: Hans Verkuil <hverkuil-cisco@xs4all.nl> Signed-off-by: Mauro Carvalho Chehab <mchehab+samsung@kernel.org>
-rw-r--r--drivers/media/platform/rcar-vin/rcar-v4l2.c7
1 files changed, 1 insertions, 6 deletions
diff --git a/drivers/media/platform/rcar-vin/rcar-v4l2.c b/drivers/media/platform/rcar-vin/rcar-v4l2.c
index b821ea01786e..0841f1a0bfd7 100644
--- a/drivers/media/platform/rcar-vin/rcar-v4l2.c
+++ b/drivers/media/platform/rcar-vin/rcar-v4l2.c
@@ -797,8 +797,6 @@ static int rvin_initialize_device(struct file *file)
if (ret < 0)
return ret;
- pm_runtime_enable(&vin->vdev.dev);
-
/*
* Try to configure with default parameters. Notice: this is the
* very first open, so, we cannot race against other calls,
@@ -813,7 +811,6 @@ static int rvin_initialize_device(struct file *file)
return 0;
esfmt:
- pm_runtime_disable(&vin->vdev.dev);
rvin_power_off(vin);
return ret;
@@ -863,10 +860,8 @@ static int rvin_release(struct file *file)
* If this was the last open file.
* Then de-initialize hw module.
*/
- if (fh_singular) {
- pm_runtime_disable(&vin->vdev.dev);
+ if (fh_singular)
rvin_power_off(vin);
- }
mutex_unlock(&vin->lock);