diff mbox series

[2/3] media: i2c: imx290: fix the order of the args in SET_RUNTIME_PM_OPS()

Message ID 20200226215913.10631-3-andrey.konovalov@linaro.org (mailing list archive)
State New, archived
Headers show
Series IMX290 sensor driver fixes | expand

Commit Message

Andrey Konovalov Feb. 26, 2020, 9:59 p.m. UTC
This macro is defined as SET_RUNTIME_PM_OPS(suspend_fn, resume_fn, idle_fn),
so imx290_power_off must be the 1st arg, and imx290_power_on the 2nd.

Signed-off-by: Andrey Konovalov <andrey.konovalov@linaro.org>
---
 drivers/media/i2c/imx290.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

Comments

Manivannan Sadhasivam March 3, 2020, 9:39 a.m. UTC | #1
On Thu, Feb 27, 2020 at 12:59:12AM +0300, Andrey Konovalov wrote:
> This macro is defined as SET_RUNTIME_PM_OPS(suspend_fn, resume_fn, idle_fn),
> so imx290_power_off must be the 1st arg, and imx290_power_on the 2nd.
>

Oops. That's a mistake.
 
> Signed-off-by: Andrey Konovalov <andrey.konovalov@linaro.org>

Reviewed-by: Manivannan Sadhasivam <manivannan.sadhasivam@linaro.org>

Thanks,
Mani

> ---
>  drivers/media/i2c/imx290.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/drivers/media/i2c/imx290.c b/drivers/media/i2c/imx290.c
> index 2d8c38ffe2f0..d0322f9a8856 100644
> --- a/drivers/media/i2c/imx290.c
> +++ b/drivers/media/i2c/imx290.c
> @@ -648,7 +648,7 @@ static int imx290_power_off(struct device *dev)
>  }
>  
>  static const struct dev_pm_ops imx290_pm_ops = {
> -	SET_RUNTIME_PM_OPS(imx290_power_on, imx290_power_off, NULL)
> +	SET_RUNTIME_PM_OPS(imx290_power_off, imx290_power_on, NULL)
>  };
>  
>  static const struct v4l2_subdev_video_ops imx290_video_ops = {
> -- 
> 2.17.1
>
diff mbox series

Patch

diff --git a/drivers/media/i2c/imx290.c b/drivers/media/i2c/imx290.c
index 2d8c38ffe2f0..d0322f9a8856 100644
--- a/drivers/media/i2c/imx290.c
+++ b/drivers/media/i2c/imx290.c
@@ -648,7 +648,7 @@  static int imx290_power_off(struct device *dev)
 }
 
 static const struct dev_pm_ops imx290_pm_ops = {
-	SET_RUNTIME_PM_OPS(imx290_power_on, imx290_power_off, NULL)
+	SET_RUNTIME_PM_OPS(imx290_power_off, imx290_power_on, NULL)
 };
 
 static const struct v4l2_subdev_video_ops imx290_video_ops = {