Skip to content

Commit

Permalink
drm/komeda: mark PM functions as __maybe_unused
Browse files Browse the repository at this point in the history
Without this, we get a couple of warnings when CONFIG_PM
is disabled:

drivers/gpu/drm/arm/display/komeda/komeda_drv.c:156:12: error: 'komeda_rt_pm_resume' defined but not used [-Werror=unused-function]
 static int komeda_rt_pm_resume(struct device *dev)
            ^~~~~~~~~~~~~~~~~~~
drivers/gpu/drm/arm/display/komeda/komeda_drv.c:149:12: error: 'komeda_rt_pm_suspend' defined but not used [-Werror=unused-function]
 static int komeda_rt_pm_suspend(struct device *dev)
            ^~~~~~~~~~~~~~~~~~~~

Fixes: efb4650 ("drm/komeda: Add runtime_pm support")
Signed-off-by: Arnd Bergmann <arnd@arndb.de>
Reviewed-by: James Qian Wang (Arm Technology China) <james.qian.wang@arm.com>
Signed-off-by: james qian wang (Arm Technology China) <james.qian.wang@arm.com>
Link: https://patchwork.freedesktop.org/patch/msgid/20200107215327.1579195-1-arnd@arndb.de
  • Loading branch information
Arnd Bergmann authored and james qian wang (Arm Technology China) committed Mar 6, 2020
1 parent e8dca30 commit 9803aac
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions drivers/gpu/drm/arm/display/komeda/komeda_drv.c
Original file line number Diff line number Diff line change
Expand Up @@ -146,14 +146,14 @@ static const struct of_device_id komeda_of_match[] = {

MODULE_DEVICE_TABLE(of, komeda_of_match);

static int komeda_rt_pm_suspend(struct device *dev)
static int __maybe_unused komeda_rt_pm_suspend(struct device *dev)
{
struct komeda_drv *mdrv = dev_get_drvdata(dev);

return komeda_dev_suspend(mdrv->mdev);
}

static int komeda_rt_pm_resume(struct device *dev)
static int __maybe_unused komeda_rt_pm_resume(struct device *dev)
{
struct komeda_drv *mdrv = dev_get_drvdata(dev);

Expand Down

0 comments on commit 9803aac

Please sign in to comment.