It is using SET_RUNTIME_PM_OPS(), thus we need to care about CONFIG_PM. Otherwise, we will get below error without it. ${Linux}/drivers/media/i2c/imx290.c:1090:12: error:\ 'imx290_runtime_suspend' defined but not used [-Werror=unused-function] 1090 | static int imx290_runtime_suspend(struct device *dev) | ^~~~~~~~~~~~~~~~~~~~~~ ${Linux}/drivers/media/i2c/imx290.c:1082:12: error: \ 'imx290_runtime_resume' defined but not used [-Werror=unused-function] 1082 | static int imx290_runtime_resume(struct device *dev) | ^~~~~~~~~~~~~~~~~~~~~ Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@xxxxxxxxxxx> --- drivers/media/i2c/imx290.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/drivers/media/i2c/imx290.c b/drivers/media/i2c/imx290.c index 49d6c8bdec41..5f15b51dfdd3 100644 --- a/drivers/media/i2c/imx290.c +++ b/drivers/media/i2c/imx290.c @@ -1079,6 +1079,7 @@ static void imx290_power_off(struct imx290 *imx290) regulator_bulk_disable(ARRAY_SIZE(imx290->supplies), imx290->supplies); } +#ifdef CONFIG_PM static int imx290_runtime_resume(struct device *dev) { struct v4l2_subdev *sd = dev_get_drvdata(dev); @@ -1096,6 +1097,7 @@ static int imx290_runtime_suspend(struct device *dev) return 0; } +#endif static const struct dev_pm_ops imx290_pm_ops = { SET_RUNTIME_PM_OPS(imx290_runtime_suspend, imx290_runtime_resume, NULL) -- 2.25.1