diff options
author | Imre Kaloz <kaloz@openwrt.org> | 2012-05-01 07:00:17 +0000 |
---|---|---|
committer | Imre Kaloz <kaloz@openwrt.org> | 2012-05-01 07:00:17 +0000 |
commit | 880de62f91bcffe7f1c7f16c9463e10853fa2524 (patch) | |
tree | 058bb1c73786a7bf492cc1a554effe4692a9b50e /target/linux/coldfire/patches/101-kernel-2.6.38-Fix-LCD-framebuffer-driver-data-swap-bug-for-MCF5441.patch | |
parent | 7a8d12bafaf8b882d0278156e5f22d0a396687e2 (diff) | |
download | upstream-880de62f91bcffe7f1c7f16c9463e10853fa2524.tar.gz upstream-880de62f91bcffe7f1c7f16c9463e10853fa2524.tar.bz2 upstream-880de62f91bcffe7f1c7f16c9463e10853fa2524.zip |
switch to 2.6.38
SVN-Revision: 31546
Diffstat (limited to 'target/linux/coldfire/patches/101-kernel-2.6.38-Fix-LCD-framebuffer-driver-data-swap-bug-for-MCF5441.patch')
-rw-r--r-- | target/linux/coldfire/patches/101-kernel-2.6.38-Fix-LCD-framebuffer-driver-data-swap-bug-for-MCF5441.patch | 49 |
1 files changed, 49 insertions, 0 deletions
diff --git a/target/linux/coldfire/patches/101-kernel-2.6.38-Fix-LCD-framebuffer-driver-data-swap-bug-for-MCF5441.patch b/target/linux/coldfire/patches/101-kernel-2.6.38-Fix-LCD-framebuffer-driver-data-swap-bug-for-MCF5441.patch new file mode 100644 index 0000000000..b948d1f833 --- /dev/null +++ b/target/linux/coldfire/patches/101-kernel-2.6.38-Fix-LCD-framebuffer-driver-data-swap-bug-for-MCF5441.patch @@ -0,0 +1,49 @@ +From 633531cdbaa3ed70a364db78fd7f8ae11da3e394 Mon Sep 17 00:00:00 2001 +From: Wang Huan <wanghuan@zch06.freescale.net> +Date: Wed, 14 Sep 2011 17:40:41 +0800 +Subject: [PATCH] Fix LCD framebuffer driver data swap bug for MCF54418 + +This patch fixed LCD framebuffer driver data swap bug +for MCF54418. + +Signed-off-by: Alison Wang <b18965@freescale.com> +--- + drivers/video/fsl-ssd1289-fb.c | 13 ++++++++++--- + 1 files changed, 10 insertions(+), 3 deletions(-) + +--- a/drivers/video/fsl-ssd1289-fb.c ++++ b/drivers/video/fsl-ssd1289-fb.c +@@ -54,8 +54,10 @@ static int ssd1289_spi_writeblock(struct + for (i = 0; i < SPI_LCD_BLOCK_SIZE; i++) { + if (i % 2 == 0) + spi_block_buffer[i] = 0x01; +- else if (flag == 1) +- spi_block_buffer[i] = *(daddr + (i >> 1)); ++ else if ((flag == 1) && (i % 4 == 1)) ++ spi_block_buffer[i] = *(daddr + (i >> 1) + 1); ++ else if ((flag == 1) && (i % 4 == 3)) ++ spi_block_buffer[i] = *(daddr + (i >> 1) - 1); + else if (flag == 0) + spi_block_buffer[i] = 0; + } +@@ -331,6 +333,9 @@ static int ssd1289fbd(void *arg) + int i; + unsigned short *buf_p; + struct fsl_ssd1289_fb_info *fbinfo = info->par; ++#if defined(CONFIG_SSD1289_FLEXBUS_MODE) ++ unsigned short tmp; ++#endif + #if defined(CONFIG_SSD1289_SPI_MODE) + unsigned char *bufspi_p; + int count; +@@ -344,7 +349,9 @@ static int ssd1289fbd(void *arg) + + #if defined(CONFIG_SSD1289_FLEXBUS_MODE) + for (i = 0; i < info->screen_size; i += 2) { +- ssd1289_write(info, *buf_p, 1); ++ tmp = ((((*buf_p) & 0x00ff) << 8) | ++ (((*buf_p) & 0xff00) >> 8)); ++ ssd1289_write(info, tmp, 1); + buf_p++; + } + #elif defined(CONFIG_SSD1289_SPI_MODE) |