drm/bridge: cdns-dsi: mark PM functions as __maybe_unused
Subsystems (3)
PATCH 1/1 drm/bridge: cdns-dsi: mark PM functions as __maybe_unused
The suspend/resume callbacks are now optional, leading to a warning when they are unused:
drivers/gpu/drm/bridge/cdns-dsi.c:1353:12: warning: ‘cdns_dsi_suspend’
defined but not used [-Wunused-function]
static int cdns_dsi_suspend(struct device *dev)
^~~~~~~~~~~~~~~~
drivers/gpu/drm/bridge/cdns-dsi.c:1340:12: warning: ‘cdns_dsi_resume’
defined but not used [-Wunused-function]
static int cdns_dsi_resume(struct device *dev)
^~~~~~~~~~~~~~~This marks the functions as __maybe_unused to avoid the warning.
Fixes e19233955d9e ("drm/bridge: Add Cadence DSI driver")
Signed-off-by Anders Roxell <[email protected]>
--- drivers/gpu/drm/bridge/cdns-dsi.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-)
drivers/gpu/drm/bridge/cdns-dsi.c +2 -2
@@ -1337,7 +1337,7 @@ static const struct mipi_dsi_host_ops cdns_dsi_ops = { .transfer = cdns_dsi_transfer, }; -static int cdns_dsi_resume (struct device *dev) +static int __maybe_unused cdns_dsi_resume (struct device *dev) {struct cdns_dsi *dsi =dev_get_drvdata (dev);
@@ -1350,7 +1350,7 @@ static int cdns_dsi_resume(struct device *dev)return 0 ; } -static int cdns_dsi_suspend (struct device *dev) +static int __maybe_unused cdns_dsi_suspend (struct device *dev) {struct cdns_dsi *dsi =dev_get_drvdata (dev);
Signature · 1 line
2.17.0