[PATCH] drm/imx: imx-ldb: Disable both channels for split mode in enc->disable()
Marco Felsch
m.felsch at pengutronix.de
Thu May 28 09:31:45 UTC 2020
Hi Liu
On 20-05-28 10:58, Liu Ying wrote:
> Gentle ping...
Please check my "spring cleanup series" [1] which do the split:
[1] https://www.spinics.net/lists/arm-kernel/msg789309.html
Regards,
Marco
> On Tue, 2020-05-12 at 15:31 +0800, Liu Ying wrote:
> > Both of the two LVDS channels should be disabled for split mode
> > in the encoder's ->disable() callback, because they are enabled
> > in the encoder's ->enable() callback.
> >
> > Fixes: 6556f7f82b9c ("drm: imx: Move imx-drm driver out of staging")
> > Cc: Philipp Zabel <p.zabel at pengutronix.de>
> > Cc: Sascha Hauer <s.hauer at pengutronix.de>
> > Cc: Pengutronix Kernel Team <kernel at pengutronix.de>
> > Cc: NXP Linux Team <linux-imx at nxp.com>
> > Cc: <stable at vger.kernel.org>
> > Signed-off-by: Liu Ying <victor.liu at nxp.com>
> > ---
> > drivers/gpu/drm/imx/imx-ldb.c | 7 ++++---
> > 1 file changed, 4 insertions(+), 3 deletions(-)
> >
> > diff --git a/drivers/gpu/drm/imx/imx-ldb.c b/drivers/gpu/drm/imx/imx-
> > ldb.c
> > index 4da22a9..af4d0d8 100644
> > --- a/drivers/gpu/drm/imx/imx-ldb.c
> > +++ b/drivers/gpu/drm/imx/imx-ldb.c
> > @@ -303,18 +303,19 @@ static void imx_ldb_encoder_disable(struct
> > drm_encoder *encoder)
> > {
> > struct imx_ldb_channel *imx_ldb_ch =
> > enc_to_imx_ldb_ch(encoder);
> > struct imx_ldb *ldb = imx_ldb_ch->ldb;
> > + int dual = ldb->ldb_ctrl & LDB_SPLIT_MODE_EN;
> > int mux, ret;
> >
> > drm_panel_disable(imx_ldb_ch->panel);
> >
> > - if (imx_ldb_ch == &ldb->channel[0])
> > + if (imx_ldb_ch == &ldb->channel[0] || dual)
> > ldb->ldb_ctrl &= ~LDB_CH0_MODE_EN_MASK;
> > - else if (imx_ldb_ch == &ldb->channel[1])
> > + if (imx_ldb_ch == &ldb->channel[1] || dual)
> > ldb->ldb_ctrl &= ~LDB_CH1_MODE_EN_MASK;
> >
> > regmap_write(ldb->regmap, IOMUXC_GPR2, ldb->ldb_ctrl);
> >
> > - if (ldb->ldb_ctrl & LDB_SPLIT_MODE_EN) {
> > + if (dual) {
> > clk_disable_unprepare(ldb->clk[0]);
> > clk_disable_unprepare(ldb->clk[1]);
> > }
>
> _______________________________________________
> dri-devel mailing list
> dri-devel at lists.freedesktop.org
> https://lists.freedesktop.org/mailman/listinfo/dri-devel
>
--
Pengutronix e.K. | |
Steuerwalder Str. 21 | http://www.pengutronix.de/ |
31137 Hildesheim, Germany | Phone: +49-5121-206917-0 |
Amtsgericht Hildesheim, HRA 2686 | Fax: +49-5121-206917-5555 |
More information about the dri-devel
mailing list