Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 100835
b: refs/heads/master
c: c2c1708
h: refs/heads/master
i:
  100833: 61df027
  100831: 045b703
v: v3
  • Loading branch information
Ben Dooks committed Jul 3, 2008
1 parent 94cdfb3 commit 3e924cc
Show file tree
Hide file tree
Showing 2 changed files with 41 additions and 1 deletion.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: a2ed4065159d87d88f2bdc5a3a53e96b76f5a198
refs/heads/master: c2c1708f9d2d0435ff136acbb98f8cfbeded09e4
40 changes: 40 additions & 0 deletions trunk/arch/arm/mach-s3c2412/mach-jive.c
Original file line number Diff line number Diff line change
Expand Up @@ -17,9 +17,12 @@
#include <linux/timer.h>
#include <linux/init.h>
#include <linux/sysdev.h>
#include <linux/delay.h>
#include <linux/serial_core.h>
#include <linux/platform_device.h>

#include <video/ili9320.h>

#include <linux/spi/spi.h>

#include <linux/mtd/mtd.h>
Expand Down Expand Up @@ -349,6 +352,42 @@ struct s3c2410fb_mach_info jive_lcd_config = {
S3C2410_GPDCON_MASK(14) | S3C2410_GPDCON_MASK(15)),
};

/* ILI9320 support. */

static void jive_lcm_reset(unsigned int set)
{
printk(KERN_DEBUG "%s(%d)\n", __func__, set);

s3c2410_gpio_setpin(S3C2410_GPG13, set);
s3c2410_gpio_cfgpin(S3C2410_GPG13, S3C2410_GPIO_OUTPUT);
}

#undef LCD_UPPER_MARGIN
#define LCD_UPPER_MARGIN 2

static struct ili9320_platdata jive_lcm_config = {
.hsize = LCD_XRES,
.vsize = LCD_YRES,

.reset = jive_lcm_reset,
.suspend = ILI9320_SUSPEND_DEEP,

.entry_mode = ILI9320_ENTRYMODE_ID(3) | ILI9320_ENTRYMODE_BGR,
.display2 = (ILI9320_DISPLAY2_FP(LCD_UPPER_MARGIN) |
ILI9320_DISPLAY2_BP(LCD_LOWER_MARGIN)),
.display3 = 0x0,
.display4 = 0x0,
.rgb_if1 = (ILI9320_RGBIF1_RIM_RGB18 |
ILI9320_RGBIF1_RM | ILI9320_RGBIF1_CLK_RGBIF),
.rgb_if2 = ILI9320_RGBIF2_DPL,
.interface2 = 0x0,
.interface3 = 0x3,
.interface4 = (ILI9320_INTERFACE4_RTNE(16) |
ILI9320_INTERFACE4_DIVE(1)),
.interface5 = 0x0,
.interface6 = 0x0,
};

/* LCD SPI support */

static void jive_lcd_spi_chipselect(struct s3c2410_spigpio_info *spi, int cs)
Expand Down Expand Up @@ -380,6 +419,7 @@ static struct spi_board_info __initdata jive_spi_devs[] = {
.chip_select = 0,
.mode = SPI_MODE_3, /* CPOL=1, CPHA=1 */
.max_speed_hz = 100000,
.platform_data = &jive_lcm_config,
},
};

Expand Down

0 comments on commit 3e924cc

Please sign in to comment.