Skip to content

Commit

Permalink
[media] s5p-cec: mark PM functions as __maybe_unused again
Browse files Browse the repository at this point in the history
A bugfix removed the two callers of s5p_cec_runtime_suspend
and s5p_cec_runtime_resume, leading to the return of a harmless
warning that I had previously fixed in commit aee8937
("[media] s5p_cec: mark suspend/resume as __maybe_unused"):

staging/media/s5p-cec/s5p_cec.c:234:12: error: ‘s5p_cec_runtime_suspend’ defined but not used [-Werror=unused-function]
staging/media/s5p-cec/s5p_cec.c:242:12: error: ‘s5p_cec_runtime_resume’ defined but not used [-Werror=unused-function]

This adds the __maybe_unused annotations to the function that
were not removed and that are now unused when CONFIG_PM
is disabled.

Fixes: 57b978a ("[media] s5p-cec: fix system and runtime PM integration")

Signed-off-by: Arnd Bergmann <arnd@arndb.de>
Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
  • Loading branch information
Arnd Bergmann authored and Mauro Carvalho Chehab committed Nov 16, 2016
1 parent ea0e437 commit eadf081
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions drivers/staging/media/s5p-cec/s5p_cec.c
Original file line number Diff line number Diff line change
Expand Up @@ -231,15 +231,15 @@ static int s5p_cec_remove(struct platform_device *pdev)
return 0;
}

static int s5p_cec_runtime_suspend(struct device *dev)
static int __maybe_unused s5p_cec_runtime_suspend(struct device *dev)
{
struct s5p_cec_dev *cec = dev_get_drvdata(dev);

clk_disable_unprepare(cec->clk);
return 0;
}

static int s5p_cec_runtime_resume(struct device *dev)
static int __maybe_unused s5p_cec_runtime_resume(struct device *dev)
{
struct s5p_cec_dev *cec = dev_get_drvdata(dev);
int ret;
Expand Down

0 comments on commit eadf081

Please sign in to comment.