[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <20180220115527.1806578-22-arnd@arndb.de>
Date: Tue, 20 Feb 2018 12:55:08 +0100
From: Arnd Bergmann <arnd@...db.de>
To: stable@...r.kernel.org
Cc: Greg KH <gregkh@...uxfoundation.org>, linux-kernel@...r.kernel.org,
Sudip Mukherjee <sudipm.mukherjee@...il.com>,
Sudip Mukherjee <sudip@...torindia.org>,
Daniel Vetter <daniel.vetter@...el.com>,
Arnd Bergmann <arnd@...db.de>,
Patrik Jakobsson <patrik.r.jakobsson@...il.com>,
David Airlie <airlied@...ux.ie>,
dri-devel@...ts.freedesktop.org
Subject: [4.4-stable 21/22] drm/gma500: remove helper function
From: Sudip Mukherjee <sudipm.mukherjee@...il.com>
commit db9b60400f9253c25ae639797df2d0ff7a35d9d8 upstream.
We were getting build warning about:
drivers/gpu/drm/gma500/mdfld_dsi_output.c:407:2: warning: initialization
from incompatible pointer type
The callback to dpms was pointing to a helper function which had a
return type of void, whereas the callback should point to a function
which has a return type of int.
On closer look it turned out that we do not need the helper function
since if we call drm_helper_connector_dpms() directly, the first check
that drm_helper_connector_dpms() does is: if (mode == connector->dpms)
Signed-off-by: Sudip Mukherjee <sudip@...torindia.org>
Link: http://patchwork.freedesktop.org/patch/msgid/1454393155-13142-1-git-send-email-sudipm.mukherjee@gmail.com
Acked-by: Patrik Jakobsson <patrik.r.jakobsson@...il.com>
Signed-off-by: Daniel Vetter <daniel.vetter@...el.com>
[arnd: rebased to 4.4]
Signed-off-by: Arnd Bergmann <arnd@...db.de>
---
drivers/gpu/drm/gma500/mdfld_dsi_output.c | 12 +-----------
1 file changed, 1 insertion(+), 11 deletions(-)
diff --git a/drivers/gpu/drm/gma500/mdfld_dsi_output.c b/drivers/gpu/drm/gma500/mdfld_dsi_output.c
index 89f705c3a5eb..910a2f253990 100644
--- a/drivers/gpu/drm/gma500/mdfld_dsi_output.c
+++ b/drivers/gpu/drm/gma500/mdfld_dsi_output.c
@@ -382,16 +382,6 @@ static int mdfld_dsi_connector_mode_valid(struct drm_connector *connector,
return MODE_OK;
}
-static void mdfld_dsi_connector_dpms(struct drm_connector *connector, int mode)
-{
- if (mode == connector->dpms)
- return;
-
- /*first, execute dpms*/
-
- drm_helper_connector_dpms(connector, mode);
-}
-
static struct drm_encoder *mdfld_dsi_connector_best_encoder(
struct drm_connector *connector)
{
@@ -404,7 +394,7 @@ static struct drm_encoder *mdfld_dsi_connector_best_encoder(
/*DSI connector funcs*/
static const struct drm_connector_funcs mdfld_dsi_connector_funcs = {
- .dpms = /*drm_helper_connector_dpms*/mdfld_dsi_connector_dpms,
+ .dpms = drm_helper_connector_dpms,
.save = mdfld_dsi_connector_save,
.restore = mdfld_dsi_connector_restore,
.detect = mdfld_dsi_connector_detect,
--
2.9.0
Powered by blists - more mailing lists