aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/gpu/drm/pl111/pl111_display.c
diff options
context:
space:
mode:
authorLinus Walleij <linus.walleij@linaro.org>2017-09-08 14:47:05 +0200
committerLinus Walleij <linus.walleij@linaro.org>2017-09-10 23:58:02 +0200
commit001485d5255cb17e99aa9e3712e43865b92d6adc (patch)
treee67a32160eff08c51704475087c928bb05c28e49 /drivers/gpu/drm/pl111/pl111_display.c
parentdrm/pl111: Add all registers to debugfs (diff)
downloadlinux-dev-001485d5255cb17e99aa9e3712e43865b92d6adc.tar.xz
linux-dev-001485d5255cb17e99aa9e3712e43865b92d6adc.zip
drm/pl111: Replace custom connector with panel bridge
This replaces the custom connector in the PL111 with the panel bridge helper. This works nicely for all standard panels, but since there are several PL11x-based systems that will need to use the dumb VGA connector bridge we use drm_of_find_panel_or_bridge() and make some headroom for dealing with bridges that are not panels as well, and drop a TODO in the code. Reviewed-by: Eric Anholt <eric@anholt.net> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> Link: https://patchwork.freedesktop.org/patch/msgid/20170908124709.4758-3-linus.walleij@linaro.org
Diffstat (limited to 'drivers/gpu/drm/pl111/pl111_display.c')
-rw-r--r--drivers/gpu/drm/pl111/pl111_display.c13
1 files changed, 2 insertions, 11 deletions
diff --git a/drivers/gpu/drm/pl111/pl111_display.c b/drivers/gpu/drm/pl111/pl111_display.c
index b58c988d9da0..9caf50d130f4 100644
--- a/drivers/gpu/drm/pl111/pl111_display.c
+++ b/drivers/gpu/drm/pl111/pl111_display.c
@@ -21,7 +21,6 @@
#include <linux/of_graph.h>
#include <drm/drmP.h>
-#include <drm/drm_panel.h>
#include <drm/drm_gem_cma_helper.h>
#include <drm/drm_gem_framebuffer_helper.h>
#include <drm/drm_fb_cma_helper.h>
@@ -94,7 +93,7 @@ static void pl111_display_enable(struct drm_simple_display_pipe *pipe,
struct pl111_drm_dev_private *priv = drm->dev_private;
const struct drm_display_mode *mode = &cstate->mode;
struct drm_framebuffer *fb = plane->state->fb;
- struct drm_connector *connector = &priv->connector.connector;
+ struct drm_connector *connector = priv->connector;
u32 cntl;
u32 ppl, hsw, hfp, hbp;
u32 lpp, vsw, vfp, vbp;
@@ -156,8 +155,6 @@ static void pl111_display_enable(struct drm_simple_display_pipe *pipe,
writel(0, priv->regs + CLCD_TIM3);
- drm_panel_prepare(priv->connector.panel);
-
/* Enable and Power Up */
cntl = CNTL_LCDEN | CNTL_LCDTFT | CNTL_LCDPWR | CNTL_LCDVCOMP(1);
@@ -204,8 +201,6 @@ static void pl111_display_enable(struct drm_simple_display_pipe *pipe,
writel(cntl, priv->regs + CLCD_PL111_CNTL);
- drm_panel_enable(priv->connector.panel);
-
drm_crtc_vblank_on(crtc);
}
@@ -217,13 +212,9 @@ void pl111_display_disable(struct drm_simple_display_pipe *pipe)
drm_crtc_vblank_off(crtc);
- drm_panel_disable(priv->connector.panel);
-
/* Disable and Power Down */
writel(0, priv->regs + CLCD_PL111_CNTL);
- drm_panel_unprepare(priv->connector.panel);
-
clk_disable_unprepare(priv->clk);
}
@@ -458,7 +449,7 @@ int pl111_display_init(struct drm_device *drm)
ret = drm_simple_display_pipe_init(drm, &priv->pipe,
&pl111_display_funcs,
formats, ARRAY_SIZE(formats),
- NULL, &priv->connector.connector);
+ NULL, priv->connector);
if (ret)
return ret;