Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 100836
b: refs/heads/master
c: fd2de27
h: refs/heads/master
v: v3
  • Loading branch information
Ben Dooks committed Jul 3, 2008
1 parent 3e924cc commit c262168
Show file tree
Hide file tree
Showing 2 changed files with 34 additions and 3 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: c2c1708f9d2d0435ff136acbb98f8cfbeded09e4
refs/heads/master: fd2de272b23bbb866294ff72f55d3731fe6a4c92
35 changes: 33 additions & 2 deletions trunk/arch/arm/mach-s3c2412/mach-jive.c
Original file line number Diff line number Diff line change
Expand Up @@ -409,8 +409,28 @@ static struct platform_device jive_device_lcdspi = {
.dev.platform_data = &jive_lcd_spi,
};

/* JIVE SPI devices. */
/* WM8750 audio code SPI definition */

static void jive_wm8750_chipselect(struct s3c2410_spigpio_info *spi, int cs)
{
s3c2410_gpio_setpin(S3C2410_GPH10, cs ? 0 : 1);
}

static struct s3c2410_spigpio_info jive_wm8750_spi = {
.bus_num = 2,
.pin_clk = S3C2410_GPB4,
.pin_mosi = S3C2410_GPB9,
.chip_select = jive_wm8750_chipselect,
};

static struct platform_device jive_device_wm8750 = {
.name = "s3c24xx-spi-gpio",
.id = 2,
.num_resources = 0,
.dev.platform_data = &jive_wm8750_spi,
};

/* JIVE SPI devices. */

static struct spi_board_info __initdata jive_spi_devs[] = {
[0] = {
Expand All @@ -420,17 +440,23 @@ static struct spi_board_info __initdata jive_spi_devs[] = {
.mode = SPI_MODE_3, /* CPOL=1, CPHA=1 */
.max_speed_hz = 100000,
.platform_data = &jive_lcm_config,
}, {
.modalias = "WM8750",
.bus_num = 2,
.chip_select = 0,
.mode = SPI_MODE_0, /* CPOL=0, CPHA=0 */
.max_speed_hz = 100000,
},
};


static struct platform_device *jive_devices[] __initdata = {
&s3c_device_usb,
&s3c_device_rtc,
&s3c_device_wdt,
&s3c_device_i2c,
&s3c_device_lcd,
&jive_device_lcdspi,
&jive_device_wm8750,
&s3c_device_nand,
&s3c_device_usbgadget,
};
Expand Down Expand Up @@ -595,6 +621,11 @@ static void __init jive_machine_init(void)
s3c2410_gpio_setpin(S3C2410_GPG8, 1);
s3c2410_gpio_cfgpin(S3C2410_GPG8, S3C2410_GPIO_OUTPUT);

/* initialise the WM8750 spi */

s3c2410_gpio_setpin(S3C2410_GPH10, 1);
s3c2410_gpio_cfgpin(S3C2410_GPH10, S3C2410_GPIO_OUTPUT);

/* Turn off suspend on both USB ports, and switch the
* selectable USB port to USB device mode. */

Expand Down

0 comments on commit c262168

Please sign in to comment.