From 8a4af51122c41c31d68874bc360eaf4a6db982ab Mon Sep 17 00:00:00 2001 From: Robert Chiras Date: Fri, 17 Feb 2017 14:16:52 +0200 Subject: [PATCH] MLK-13996: lcdif: Use DE polarity specified in DTS Currently, the LCDIF driver (mxsfb.c) is overriding the DE polarity specified in DTS with the one specified in fb_videomode (sync member) by the panel driver. Initially, the panel driver found in drivers/video/fbdev/mxc/mxcfb_hx8363_wvga.c specified the sync in fb_videomode as FB_SYNC_OE_LOW_ACT. But this patch, changed it to 0x0: commit 4deb430fd05a ("MLK-13607-8 video: mipi-panel: hx8363: change DE polarity to active high") Author: Fancy Fang Date: Wed Dec 14 16:21:51 2016 +0800 The NorthWest Logic MIPI DSI only support active low data enable signal on imx7ulp-evk board. The problem is that, the hx8363 panel was working with active low on imx7d-sdb, but with active high on imx7ulp-evk. The above patch broke hx8363 panel on imx7d-sdb board. So, instead of using a hard-coded polarity in panel driver, better use the one defined in device-tree. Signed-off-by: Robert Chiras --- arch/arm/boot/dts/imx7d-sdb.dts | 2 +- drivers/video/fbdev/mxsfb.c | 6 +----- 2 files changed, 2 insertions(+), 6 deletions(-) diff --git a/arch/arm/boot/dts/imx7d-sdb.dts b/arch/arm/boot/dts/imx7d-sdb.dts index 1afc2400bddb..3c68b5328fe3 100644 --- a/arch/arm/boot/dts/imx7d-sdb.dts +++ b/arch/arm/boot/dts/imx7d-sdb.dts @@ -620,7 +620,7 @@ vsync-len = <10>; hsync-active = <0>; vsync-active = <0>; - de-active = <1>; + de-active = <0>; pixelclk-active = <0>; }; }; diff --git a/drivers/video/fbdev/mxsfb.c b/drivers/video/fbdev/mxsfb.c index 62840ec9ddbd..bb74d2be2974 100644 --- a/drivers/video/fbdev/mxsfb.c +++ b/drivers/video/fbdev/mxsfb.c @@ -677,7 +677,6 @@ static void mxsfb_enable_controller(struct fb_info *fb_info) "dispdrv:%s\n", host->dispdrv->drv->name); return; } - host->sync = fb_info->var.sync; } if (host->reg_lcd) { @@ -1323,11 +1322,8 @@ static int mxsfb_init_fbinfo_dt(struct mxsfb_info *host) } ret = of_property_read_string(np, "disp-dev", &disp_dev); - if (!ret) { + if (!ret) memcpy(host->disp_dev, disp_dev, strlen(disp_dev)); - /* Timing is from encoder driver */ - goto put_display_node; - } timings = of_get_display_timings(display_np); if (!timings) { -- 2.17.1