diff options
author | Uwe Kleine-König <u.kleine-koenig@pengutronix.de> | 2019-09-09 21:40:13 +0200 |
---|---|---|
committer | Sascha Hauer <s.hauer@pengutronix.de> | 2019-09-12 10:30:07 +0200 |
commit | 3b6f72f5b4c8b2f522252006bc1bf9bbc8c9d236 (patch) | |
tree | 3bb36f6788c234a735991d6b6afd4b8da6e71a13 /arch/arm/boards/guf-neso | |
parent | fc45db983faa9b6731c2c57d117339c0063778b4 (diff) | |
download | barebox-3b6f72f5b4c8b2f522252006bc1bf9bbc8c9d236.tar.gz barebox-3b6f72f5b4c8b2f522252006bc1bf9bbc8c9d236.tar.xz |
video: imxfb: make pcr and bpp per-display settings
These settings used to be specified per-mode. But the device tree
bindings have these two values attached to the display and not to each
mode. Also for the supported boards it doesn't matter as they all only
have a single mode.
This is preparatory work to add devicetree support for the imxfb driver.
Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
Diffstat (limited to 'arch/arm/boards/guf-neso')
-rw-r--r-- | arch/arm/boards/guf-neso/board.c | 58 |
1 files changed, 28 insertions, 30 deletions
diff --git a/arch/arm/boards/guf-neso/board.c b/arch/arm/boards/guf-neso/board.c index 2a64bc14fc..6846ba5793 100644 --- a/arch/arm/boards/guf-neso/board.c +++ b/arch/arm/boards/guf-neso/board.c @@ -62,36 +62,18 @@ static struct imx_nand_platform_data nand_info = { .flash_bbt = 1, }; -static struct imx_fb_videomode imxfb_mode = { - .mode = { - .name = "CPT CLAA070LC0JCT", - .refresh = 60, - .xres = 800, - .yres = 480, - .pixclock = KHZ2PICOS(27000), - .hsync_len = 1, /* DE only sync */ - .left_margin = 50, - .right_margin = 50, - .vsync_len = 1, /* DE only sync */ - .upper_margin = 10, - .lower_margin = 10, - }, - /* - * - TFT style panel - * - clk enabled while idle - * - clock inverted - * - data not inverted - * - data enable high active - */ - .pcr = PCR_TFT | - PCR_COLOR | - PCR_PBSIZ_8 | - PCR_BPIX_16 | - PCR_CLKPOL | - PCR_SCLK_SEL | - PCR_LPPOL | - PCR_FLMPOL, - .bpp = 16, /* TODO 32 bit does not work: The 'green' component is lacking in this mode */ +static struct fb_videomode imxfb_mode = { + .name = "CPT CLAA070LC0JCT", + .refresh = 60, + .xres = 800, + .yres = 480, + .pixclock = KHZ2PICOS(27000), + .hsync_len = 1, /* DE only sync */ + .left_margin = 50, + .right_margin = 50, + .vsync_len = 1, /* DE only sync */ + .upper_margin = 10, + .lower_margin = 10, }; static void neso_fb_enable(int enable) @@ -109,6 +91,22 @@ static struct imx_fb_platform_data neso_fb_data = { .dmacr = (0 << 31) | (4 << 16) | 96, .enable = neso_fb_enable, .framebuffer_ovl = (void *)0xa7f00000, + /* + * - TFT style panel + * - clk enabled while idle + * - clock inverted + * - data not inverted + * - data enable high active + */ + .pcr = PCR_TFT | + PCR_COLOR | + PCR_PBSIZ_8 | + PCR_BPIX_16 | + PCR_CLKPOL | + PCR_SCLK_SEL | + PCR_LPPOL | + PCR_FLMPOL, + .bpp = 16, /* TODO 32 bit does not work: The 'green' component is lacking in this mode */ }; #if defined(CONFIG_USB) && defined(CONFIG_USB_ULPI) |