Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > linux.kernel > #1271300 > unrolled thread
| Started by | Arnd Bergmann <arnd@arndb.de> |
|---|---|
| First post | 2015-11-17 16:10 +0100 |
| Last post | 2015-11-17 16:50 +0100 |
| Articles | 2 — 1 participant |
Back to article view | Back to linux.kernel
[PATCH] drm/exynos: fix building without CONFIG_PM_SLEEP Arnd Bergmann <arnd@arndb.de> - 2015-11-17 16:10 +0100
[PATCH] drm/exynos: remove unused variables Arnd Bergmann <arnd@arndb.de> - 2015-11-17 16:50 +0100
| From | Arnd Bergmann <arnd@arndb.de> |
|---|---|
| Date | 2015-11-17 16:10 +0100 |
| Subject | [PATCH] drm/exynos: fix building without CONFIG_PM_SLEEP |
| Message-ID | <qvQ3p-6Fs-23@gated-at.bofh.it> |
The runtime PM operations use the suspend/resume functions
even when CONFIG_PM_SLEEP is not set, but this now fails
for the exynos DRM driver:
exynos_mixer.c:1289:61: error: 'exynos_mixer_resume' undeclared here (not in a function)
SET_RUNTIME_PM_OPS(exynos_mixer_suspend, exynos_mixer_resume, NULL)
This removes the #ifdef and instead marks the functions as
__maybe_unused, which does the right thing in all cases and
also looks nicer.
Signed-off-by: Arnd Bergmann <arnd@arndb.de>
Fixes: ("drm/exynos: add pm_runtime to Mixer")
diff --git a/drivers/gpu/drm/exynos/exynos_mixer.c b/drivers/gpu/drm/exynos/exynos_mixer.c
index 7498c6e76a53..fcaf71df77c1 100644
--- a/drivers/gpu/drm/exynos/exynos_mixer.c
+++ b/drivers/gpu/drm/exynos/exynos_mixer.c
@@ -1230,8 +1230,7 @@ static int mixer_remove(struct platform_device *pdev)
return 0;
}
-#ifdef CONFIG_PM_SLEEP
-static int exynos_mixer_suspend(struct device *dev)
+static int __maybe_unused exynos_mixer_suspend(struct device *dev)
{
struct mixer_context *ctx = dev_get_drvdata(dev);
struct mixer_resources *res = &ctx->mixer_res;
@@ -1247,7 +1246,7 @@ static int exynos_mixer_suspend(struct device *dev)
return 0;
}
-static int exynos_mixer_resume(struct device *dev)
+static int __maybe_unused exynos_mixer_resume(struct device *dev)
{
struct mixer_context *ctx = dev_get_drvdata(dev);
struct mixer_resources *res = &ctx->mixer_res;
@@ -1283,7 +1282,6 @@ static int exynos_mixer_resume(struct device *dev)
return 0;
}
-#endif
static const struct dev_pm_ops exynos_mixer_pm_ops = {
SET_RUNTIME_PM_OPS(exynos_mixer_suspend, exynos_mixer_resume, NULL)
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
[toc] | [next] | [standalone]
| From | Arnd Bergmann <arnd@arndb.de> |
|---|---|
| Date | 2015-11-17 16:50 +0100 |
| Subject | [PATCH] drm/exynos: remove unused variables |
| Message-ID | <qvQG5-6Vs-11@gated-at.bofh.it> |
| In reply to | #1271300 |
After a recent change, two variables were left unused:
exynos/exynos5433_drm_decon.c: In function 'decon_enable':
exynos/exynos5433_drm_decon.c:381:6: warning: unused variable 'i' [-Wunused-variable]
exynos/exynos5433_drm_decon.c:380:6: warning: unused variable 'ret' [-Wunused-variable]
This removes them too.
Signed-off-by: Arnd Bergmann <arnd@arndb.de>
Fixes: 186ba87a6e31 ("drm/exynos: add pm_runtime to DECON 5433")
diff --git a/drivers/gpu/drm/exynos/exynos5433_drm_decon.c b/drivers/gpu/drm/exynos/exynos5433_drm_decon.c
index edfd6e390ef7..2ac1d4d14368 100644
--- a/drivers/gpu/drm/exynos/exynos5433_drm_decon.c
+++ b/drivers/gpu/drm/exynos/exynos5433_drm_decon.c
@@ -377,8 +377,6 @@ static void decon_swreset(struct decon_context *ctx)
static void decon_enable(struct exynos_drm_crtc *crtc)
{
struct decon_context *ctx = crtc->ctx;
- int ret;
- int i;
if (!test_and_clear_bit(BIT_SUSPENDED, &ctx->flags))
return;
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
[toc] | [prev] | [standalone]
Back to top | Article view | linux.kernel
csiph-web