aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorLinus Torvalds <torvalds@linux-foundation.org>2010-08-14 14:59:44 -0400
committerLinus Torvalds <torvalds@linux-foundation.org>2010-08-14 14:59:44 -0400
commitbbbfb910d14988963fbc0b3fc5fc460daf21bf24 (patch)
treed06629217c7b91f678ef821295f133c0ef6781fa
parentd0a0c28cf178943afaf22f87957b73c47497cb4b (diff)
parenta739260d4e3d88c5c810b14231dbdce73665b0b2 (diff)
Merge branch 'for-linus/samsung-2635' of git://git.fluff.org/bjdooks/linux
* 'for-linus/samsung-2635' of git://git.fluff.org/bjdooks/linux: DMAENGINE: correct PL080 register header file ARM: SAMSUNG: Fix on build warning about dependency in Kconfig ARM: SMDK6410: Make virtual screen twice depth of real ARM: S3C64XX: Update consistent DMA size to 8MiB ARM: S3C64XX: Add audio support to SmartQ ARM: S3C64XX: Framebuffer fix for SmartQ5 ARM: S3C64XX: Set wifi and iNAND as permanently connected SD devices on SmartQ boards ARM: S3C64XX: Move SmartQ LCD control platform definition to shared file ARM: mach-real6410: add sdhc device support ARM: mach-real6410: add dm9000 ethernet support for mach-real6410 ARM: S3C64XX: Support for Real6410 Fix up trivial conflicts in arch/arm/mach-s3c64xx/mach-smartq5.c ("remove pixclock" vs "Framebuffer fix for SmartQ5")
-rw-r--r--arch/arm/include/asm/hardware/pl080.h4
-rw-r--r--arch/arm/mach-s3c64xx/Kconfig9
-rw-r--r--arch/arm/mach-s3c64xx/Makefile1
-rw-r--r--arch/arm/mach-s3c64xx/dma.c2
-rw-r--r--arch/arm/mach-s3c64xx/include/mach/memory.h2
-rw-r--r--arch/arm/mach-s3c64xx/mach-real6410.c152
-rw-r--r--arch/arm/mach-s3c64xx/mach-smartq.c40
-rw-r--r--arch/arm/mach-s3c64xx/mach-smartq5.c36
-rw-r--r--arch/arm/mach-s3c64xx/mach-smartq7.c28
-rw-r--r--arch/arm/mach-s3c64xx/mach-smdk6410.c2
-rw-r--r--arch/arm/plat-samsung/Kconfig2
11 files changed, 213 insertions, 65 deletions
diff --git a/arch/arm/include/asm/hardware/pl080.h b/arch/arm/include/asm/hardware/pl080.h
index 6a6c66be7f65..f35b86e68dd5 100644
--- a/arch/arm/include/asm/hardware/pl080.h
+++ b/arch/arm/include/asm/hardware/pl080.h
@@ -43,7 +43,7 @@
43 43
44/* Per channel configuration registers */ 44/* Per channel configuration registers */
45 45
46#define PL008_Cx_STRIDE (0x20) 46#define PL080_Cx_STRIDE (0x20)
47#define PL080_Cx_BASE(x) ((0x100 + (x * 0x20))) 47#define PL080_Cx_BASE(x) ((0x100 + (x * 0x20)))
48#define PL080_Cx_SRC_ADDR(x) ((0x100 + (x * 0x20))) 48#define PL080_Cx_SRC_ADDR(x) ((0x100 + (x * 0x20)))
49#define PL080_Cx_DST_ADDR(x) ((0x104 + (x * 0x20))) 49#define PL080_Cx_DST_ADDR(x) ((0x104 + (x * 0x20)))
@@ -68,6 +68,8 @@
68#define PL080_CONTROL_TC_IRQ_EN (1 << 31) 68#define PL080_CONTROL_TC_IRQ_EN (1 << 31)
69#define PL080_CONTROL_PROT_MASK (0x7 << 28) 69#define PL080_CONTROL_PROT_MASK (0x7 << 28)
70#define PL080_CONTROL_PROT_SHIFT (28) 70#define PL080_CONTROL_PROT_SHIFT (28)
71#define PL080_CONTROL_PROT_CACHE (1 << 30)
72#define PL080_CONTROL_PROT_BUFF (1 << 29)
71#define PL080_CONTROL_PROT_SYS (1 << 28) 73#define PL080_CONTROL_PROT_SYS (1 << 28)
72#define PL080_CONTROL_DST_INCR (1 << 27) 74#define PL080_CONTROL_DST_INCR (1 << 27)
73#define PL080_CONTROL_SRC_INCR (1 << 26) 75#define PL080_CONTROL_SRC_INCR (1 << 26)
diff --git a/arch/arm/mach-s3c64xx/Kconfig b/arch/arm/mach-s3c64xx/Kconfig
index 071e8a1e0765..1e4d78af7d84 100644
--- a/arch/arm/mach-s3c64xx/Kconfig
+++ b/arch/arm/mach-s3c64xx/Kconfig
@@ -98,6 +98,15 @@ config MACH_ANW6410
98 help 98 help
99 Machine support for the A&W6410 99 Machine support for the A&W6410
100 100
101config MACH_REAL6410
102 bool "REAL6410"
103 select CPU_S3C6410
104 select S3C_DEV_HSMMC
105 select S3C_DEV_HSMMC1
106 select S3C64XX_SETUP_SDHCI
107 help
108 Machine support for the CoreWind REAL6410
109
101config MACH_SMDK6410 110config MACH_SMDK6410
102 bool "SMDK6410" 111 bool "SMDK6410"
103 select CPU_S3C6410 112 select CPU_S3C6410
diff --git a/arch/arm/mach-s3c64xx/Makefile b/arch/arm/mach-s3c64xx/Makefile
index 48d3dfac8dd7..90221a2e0c55 100644
--- a/arch/arm/mach-s3c64xx/Makefile
+++ b/arch/arm/mach-s3c64xx/Makefile
@@ -52,6 +52,7 @@ obj-$(CONFIG_PM) += irq-pm.o
52obj-$(CONFIG_MACH_ANW6410) += mach-anw6410.o 52obj-$(CONFIG_MACH_ANW6410) += mach-anw6410.o
53obj-$(CONFIG_MACH_SMDK6400) += mach-smdk6400.o 53obj-$(CONFIG_MACH_SMDK6400) += mach-smdk6400.o
54obj-$(CONFIG_MACH_SMDK6410) += mach-smdk6410.o 54obj-$(CONFIG_MACH_SMDK6410) += mach-smdk6410.o
55obj-$(CONFIG_MACH_REAL6410) += mach-real6410.o
55obj-$(CONFIG_MACH_NCP) += mach-ncp.o 56obj-$(CONFIG_MACH_NCP) += mach-ncp.o
56obj-$(CONFIG_MACH_HMT) += mach-hmt.o 57obj-$(CONFIG_MACH_HMT) += mach-hmt.o
57obj-$(CONFIG_MACH_SMARTQ) += mach-smartq.o 58obj-$(CONFIG_MACH_SMARTQ) += mach-smartq.o
diff --git a/arch/arm/mach-s3c64xx/dma.c b/arch/arm/mach-s3c64xx/dma.c
index 5567e037b0d1..e7d03ab41d80 100644
--- a/arch/arm/mach-s3c64xx/dma.c
+++ b/arch/arm/mach-s3c64xx/dma.c
@@ -697,7 +697,7 @@ static int s3c64xx_dma_init1(int chno, enum dma_ch chbase,
697 chptr->number = chno; 697 chptr->number = chno;
698 chptr->dmac = dmac; 698 chptr->dmac = dmac;
699 chptr->regs = regptr; 699 chptr->regs = regptr;
700 regptr += PL008_Cx_STRIDE; 700 regptr += PL080_Cx_STRIDE;
701 } 701 }
702 702
703 /* for the moment, permanently enable the controller */ 703 /* for the moment, permanently enable the controller */
diff --git a/arch/arm/mach-s3c64xx/include/mach/memory.h b/arch/arm/mach-s3c64xx/include/mach/memory.h
index a3ac84a65480..42cc54e2ee30 100644
--- a/arch/arm/mach-s3c64xx/include/mach/memory.h
+++ b/arch/arm/mach-s3c64xx/include/mach/memory.h
@@ -15,4 +15,6 @@
15 15
16#define PHYS_OFFSET UL(0x50000000) 16#define PHYS_OFFSET UL(0x50000000)
17 17
18#define CONSISTENT_DMA_SIZE SZ_8M
19
18#endif 20#endif
diff --git a/arch/arm/mach-s3c64xx/mach-real6410.c b/arch/arm/mach-s3c64xx/mach-real6410.c
new file mode 100644
index 000000000000..5c07d013b23d
--- /dev/null
+++ b/arch/arm/mach-s3c64xx/mach-real6410.c
@@ -0,0 +1,152 @@
1/* linux/arch/arm/mach-s3c64xx/mach-real6410.c
2 *
3 * Copyright 2010 Darius Augulis <augulis.darius@gmail.com>
4 * Copyright 2008 Openmoko, Inc.
5 * Copyright 2008 Simtec Electronics
6 * Ben Dooks <ben@simtec.co.uk>
7 * http://armlinux.simtec.co.uk/
8 *
9 * This program is free software; you can redistribute it and/or modify
10 * it under the terms of the GNU General Public License version 2 as
11 * published by the Free Software Foundation.
12 *
13*/
14
15#include <linux/kernel.h>
16#include <linux/types.h>
17#include <linux/interrupt.h>
18#include <linux/list.h>
19#include <linux/init.h>
20#include <linux/dm9000.h>
21#include <linux/serial_core.h>
22#include <linux/platform_device.h>
23#include <asm/mach-types.h>
24#include <asm/mach/arch.h>
25#include <asm/mach/map.h>
26#include <mach/map.h>
27#include <mach/s3c6410.h>
28#include <mach/regs-srom.h>
29#include <plat/cpu.h>
30#include <plat/devs.h>
31#include <plat/regs-serial.h>
32
33#define UCON S3C2410_UCON_DEFAULT | S3C2410_UCON_UCLK
34#define ULCON S3C2410_LCON_CS8 | S3C2410_LCON_PNONE | S3C2410_LCON_STOPB
35#define UFCON S3C2410_UFCON_RXTRIG8 | S3C2410_UFCON_FIFOMODE
36
37static struct s3c2410_uartcfg real6410_uartcfgs[] __initdata = {
38 [0] = {
39 .hwport = 0,
40 .flags = 0,
41 .ucon = UCON,
42 .ulcon = ULCON,
43 .ufcon = UFCON,
44 },
45 [1] = {
46 .hwport = 1,
47 .flags = 0,
48 .ucon = UCON,
49 .ulcon = ULCON,
50 .ufcon = UFCON,
51 },
52 [2] = {
53 .hwport = 2,
54 .flags = 0,
55 .ucon = UCON,
56 .ulcon = ULCON,
57 .ufcon = UFCON,
58 },
59 [3] = {
60 .hwport = 3,
61 .flags = 0,
62 .ucon = UCON,
63 .ulcon = ULCON,
64 .ufcon = UFCON,
65 },
66};
67
68/* DM9000AEP 10/100 ethernet controller */
69
70static struct resource real6410_dm9k_resource[] = {
71 [0] = {
72 .start = S3C64XX_PA_XM0CSN1,
73 .end = S3C64XX_PA_XM0CSN1 + 1,
74 .flags = IORESOURCE_MEM
75 },
76 [1] = {
77 .start = S3C64XX_PA_XM0CSN1 + 4,
78 .end = S3C64XX_PA_XM0CSN1 + 5,
79 .flags = IORESOURCE_MEM
80 },
81 [2] = {
82 .start = S3C_EINT(7),
83 .end = S3C_EINT(7),
84 .flags = IORESOURCE_IRQ,
85 }
86};
87
88static struct dm9000_plat_data real6410_dm9k_pdata = {
89 .flags = (DM9000_PLATF_16BITONLY | DM9000_PLATF_NO_EEPROM),
90};
91
92static struct platform_device real6410_device_eth = {
93 .name = "dm9000",
94 .id = -1,
95 .num_resources = ARRAY_SIZE(real6410_dm9k_resource),
96 .resource = real6410_dm9k_resource,
97 .dev = {
98 .platform_data = &real6410_dm9k_pdata,
99 },
100};
101
102static struct platform_device *real6410_devices[] __initdata = {
103 &real6410_device_eth,
104 &s3c_device_hsmmc0,
105 &s3c_device_hsmmc1,
106};
107
108static void __init real6410_map_io(void)
109{
110 s3c64xx_init_io(NULL, 0);
111 s3c24xx_init_clocks(12000000);
112 s3c24xx_init_uarts(real6410_uartcfgs, ARRAY_SIZE(real6410_uartcfgs));
113}
114
115static void __init real6410_machine_init(void)
116{
117 u32 cs1;
118
119 /* configure nCS1 width to 16 bits */
120
121 cs1 = __raw_readl(S3C64XX_SROM_BW) &
122 ~(S3C64XX_SROM_BW__CS_MASK << S3C64XX_SROM_BW__NCS1__SHIFT);
123 cs1 |= ((1 << S3C64XX_SROM_BW__DATAWIDTH__SHIFT) |
124 (1 << S3C64XX_SROM_BW__WAITENABLE__SHIFT) |
125 (1 << S3C64XX_SROM_BW__BYTEENABLE__SHIFT)) <<
126 S3C64XX_SROM_BW__NCS1__SHIFT;
127 __raw_writel(cs1, S3C64XX_SROM_BW);
128
129 /* set timing for nCS1 suitable for ethernet chip */
130
131 __raw_writel((0 << S3C64XX_SROM_BCX__PMC__SHIFT) |
132 (6 << S3C64XX_SROM_BCX__TACP__SHIFT) |
133 (4 << S3C64XX_SROM_BCX__TCAH__SHIFT) |
134 (1 << S3C64XX_SROM_BCX__TCOH__SHIFT) |
135 (13 << S3C64XX_SROM_BCX__TACC__SHIFT) |
136 (4 << S3C64XX_SROM_BCX__TCOS__SHIFT) |
137 (0 << S3C64XX_SROM_BCX__TACS__SHIFT), S3C64XX_SROM_BC1);
138
139 platform_add_devices(real6410_devices, ARRAY_SIZE(real6410_devices));
140}
141
142MACHINE_START(REAL6410, "REAL6410")
143 /* Maintainer: Darius Augulis <augulis.darius@gmail.com> */
144 .phys_io = S3C_PA_UART & 0xfff00000,
145 .io_pg_offst = (((u32)S3C_VA_UART) >> 18) & 0xfffc,
146 .boot_params = S3C64XX_PA_SDRAM + 0x100,
147
148 .init_irq = s3c6410_init_irq,
149 .map_io = real6410_map_io,
150 .init_machine = real6410_machine_init,
151 .timer = &s3c24xx_timer,
152MACHINE_END
diff --git a/arch/arm/mach-s3c64xx/mach-smartq.c b/arch/arm/mach-s3c64xx/mach-smartq.c
index 028d080dcd35..3a9639bc3d9b 100644
--- a/arch/arm/mach-s3c64xx/mach-smartq.c
+++ b/arch/arm/mach-s3c64xx/mach-smartq.c
@@ -16,6 +16,7 @@
16#include <linux/platform_device.h> 16#include <linux/platform_device.h>
17#include <linux/pwm_backlight.h> 17#include <linux/pwm_backlight.h>
18#include <linux/serial_core.h> 18#include <linux/serial_core.h>
19#include <linux/spi/spi_gpio.h>
19#include <linux/usb/gpio_vbus.h> 20#include <linux/usb/gpio_vbus.h>
20 21
21#include <asm/mach-types.h> 22#include <asm/mach-types.h>
@@ -166,7 +167,7 @@ static struct s3c2410_ts_mach_info smartq_touchscreen_pdata __initdata = {
166 167
167static struct s3c_sdhci_platdata smartq_internal_hsmmc_pdata = { 168static struct s3c_sdhci_platdata smartq_internal_hsmmc_pdata = {
168 .max_width = 4, 169 .max_width = 4,
169 /*.broken_card_detection = true,*/ 170 .cd_type = S3C_SDHCI_CD_PERMANENT,
170}; 171};
171 172
172static struct s3c_hwmon_pdata smartq_hwmon_pdata __initdata = { 173static struct s3c_hwmon_pdata smartq_hwmon_pdata __initdata = {
@@ -184,6 +185,33 @@ static struct s3c_hwmon_pdata smartq_hwmon_pdata __initdata = {
184 }, 185 },
185}; 186};
186 187
188static int __init smartq_lcd_setup_gpio(void)
189{
190 int ret;
191
192 ret = gpio_request(S3C64XX_GPM(3), "LCD power");
193 if (ret < 0)
194 return ret;
195
196 /* turn power off */
197 gpio_direction_output(S3C64XX_GPM(3), 0);
198
199 return 0;
200}
201
202/* GPM0 -> CS */
203static struct spi_gpio_platform_data smartq_lcd_control = {
204 .sck = S3C64XX_GPM(1),
205 .mosi = S3C64XX_GPM(2),
206 .miso = S3C64XX_GPM(2),
207};
208
209static struct platform_device smartq_lcd_control_device = {
210 .name = "spi-gpio",
211 .id = 1,
212 .dev.platform_data = &smartq_lcd_control,
213};
214
187static void smartq_lcd_power_set(struct plat_lcd_data *pd, unsigned int power) 215static void smartq_lcd_power_set(struct plat_lcd_data *pd, unsigned int power)
188{ 216{
189 gpio_direction_output(S3C64XX_GPM(3), power); 217 gpio_direction_output(S3C64XX_GPM(3), power);
@@ -199,6 +227,9 @@ static struct platform_device smartq_lcd_power_device = {
199 .dev.platform_data = &smartq_lcd_power_data, 227 .dev.platform_data = &smartq_lcd_power_data,
200}; 228};
201 229
230static struct i2c_board_info smartq_i2c_devs[] __initdata = {
231 { I2C_BOARD_INFO("wm8987", 0x1a), },
232};
202 233
203static struct platform_device *smartq_devices[] __initdata = { 234static struct platform_device *smartq_devices[] __initdata = {
204 &s3c_device_hsmmc1, /* Init iNAND first, ... */ 235 &s3c_device_hsmmc1, /* Init iNAND first, ... */
@@ -213,7 +244,9 @@ static struct platform_device *smartq_devices[] __initdata = {
213 &s3c_device_timer[1], 244 &s3c_device_timer[1],
214 &s3c_device_ts, 245 &s3c_device_ts,
215 &s3c_device_usb_hsotg, 246 &s3c_device_usb_hsotg,
247 &s3c64xx_device_iis0,
216 &smartq_backlight_device, 248 &smartq_backlight_device,
249 &smartq_lcd_control_device,
217 &smartq_lcd_power_device, 250 &smartq_lcd_power_device,
218 &smartq_usb_otg_vbus_dev, 251 &smartq_usb_otg_vbus_dev,
219}; 252};
@@ -252,7 +285,6 @@ static int __init smartq_power_off_init(void)
252 /* leave power on */ 285 /* leave power on */
253 gpio_direction_output(S3C64XX_GPK(15), 0); 286 gpio_direction_output(S3C64XX_GPK(15), 0);
254 287
255
256 pm_power_off = smartq_power_off; 288 pm_power_off = smartq_power_off;
257 289
258 return ret; 290 return ret;
@@ -354,6 +386,10 @@ void __init smartq_machine_init(void)
354 s3c_sdhci2_set_platdata(&smartq_internal_hsmmc_pdata); 386 s3c_sdhci2_set_platdata(&smartq_internal_hsmmc_pdata);
355 s3c24xx_ts_set_platdata(&smartq_touchscreen_pdata); 387 s3c24xx_ts_set_platdata(&smartq_touchscreen_pdata);
356 388
389 i2c_register_board_info(0, smartq_i2c_devs,
390 ARRAY_SIZE(smartq_i2c_devs));
391
392 WARN_ON(smartq_lcd_setup_gpio());
357 WARN_ON(smartq_power_off_init()); 393 WARN_ON(smartq_power_off_init());
358 WARN_ON(smartq_usb_host_init()); 394 WARN_ON(smartq_usb_host_init());
359 WARN_ON(smartq_usb_otg_init()); 395 WARN_ON(smartq_usb_otg_init());
diff --git a/arch/arm/mach-s3c64xx/mach-smartq5.c b/arch/arm/mach-s3c64xx/mach-smartq5.c
index a065062ec2a4..a4d59b076e3d 100644
--- a/arch/arm/mach-s3c64xx/mach-smartq5.c
+++ b/arch/arm/mach-s3c64xx/mach-smartq5.c
@@ -12,7 +12,6 @@
12#include <linux/fb.h> 12#include <linux/fb.h>
13#include <linux/gpio.h> 13#include <linux/gpio.h>
14#include <linux/gpio_keys.h> 14#include <linux/gpio_keys.h>
15#include <linux/i2c-gpio.h>
16#include <linux/init.h> 15#include <linux/init.h>
17#include <linux/input.h> 16#include <linux/input.h>
18#include <linux/leds.h> 17#include <linux/leds.h>
@@ -33,31 +32,6 @@
33 32
34#include "mach-smartq.h" 33#include "mach-smartq.h"
35 34
36static void __init smartq5_lcd_setup_gpio(void)
37{
38 gpio_request(S3C64XX_GPM(0), "LCD SCEN pin");
39 gpio_request(S3C64XX_GPM(1), "LCD SCL pin");
40 gpio_request(S3C64XX_GPM(2), "LCD SDA pin");
41 gpio_request(S3C64XX_GPM(3), "LCD power");
42
43 /* turn power off */
44 gpio_direction_output(S3C64XX_GPM(0), 1);
45 gpio_direction_input(S3C64XX_GPM(1));
46 gpio_direction_input(S3C64XX_GPM(2));
47 gpio_direction_output(S3C64XX_GPM(3), 0);
48}
49
50static struct i2c_gpio_platform_data smartq5_lcd_control = {
51 .sda_pin = S3C64XX_GPM(2),
52 .scl_pin = S3C64XX_GPM(1),
53};
54
55static struct platform_device smartq5_lcd_control_device = {
56 .name = "i2c-gpio",
57 .id = 1,
58 .dev.platform_data = &smartq5_lcd_control,
59};
60
61static struct gpio_led smartq5_leds[] __initdata = { 35static struct gpio_led smartq5_leds[] __initdata = {
62 { 36 {
63 .name = "smartq5:green", 37 .name = "smartq5:green",
@@ -134,10 +108,10 @@ static struct platform_device smartq5_buttons_device = {
134 108
135static struct s3c_fb_pd_win smartq5_fb_win0 = { 109static struct s3c_fb_pd_win smartq5_fb_win0 = {
136 .win_mode = { 110 .win_mode = {
137 .left_margin = 40, 111 .left_margin = 216,
138 .right_margin = 216, 112 .right_margin = 40,
139 .upper_margin = 10, 113 .upper_margin = 35,
140 .lower_margin = 35, 114 .lower_margin = 10,
141 .hsync_len = 1, 115 .hsync_len = 1,
142 .vsync_len = 1, 116 .vsync_len = 1,
143 .xres = 800, 117 .xres = 800,
@@ -159,7 +133,6 @@ static struct s3c_fb_platdata smartq5_lcd_pdata __initdata = {
159static struct platform_device *smartq5_devices[] __initdata = { 133static struct platform_device *smartq5_devices[] __initdata = {
160 &smartq5_leds_device, 134 &smartq5_leds_device,
161 &smartq5_buttons_device, 135 &smartq5_buttons_device,
162 &smartq5_lcd_control_device,
163}; 136};
164 137
165static void __init smartq5_machine_init(void) 138static void __init smartq5_machine_init(void)
@@ -167,7 +140,6 @@ static void __init smartq5_machine_init(void)
167 s3c_fb_set_platdata(&smartq5_lcd_pdata); 140 s3c_fb_set_platdata(&smartq5_lcd_pdata);
168 141
169 smartq_machine_init(); 142 smartq_machine_init();
170 smartq5_lcd_setup_gpio();
171 143
172 platform_add_devices(smartq5_devices, ARRAY_SIZE(smartq5_devices)); 144 platform_add_devices(smartq5_devices, ARRAY_SIZE(smartq5_devices));
173} 145}
diff --git a/arch/arm/mach-s3c64xx/mach-smartq7.c b/arch/arm/mach-s3c64xx/mach-smartq7.c
index 0ecf45137546..e50a7d781732 100644
--- a/arch/arm/mach-s3c64xx/mach-smartq7.c
+++ b/arch/arm/mach-s3c64xx/mach-smartq7.c
@@ -12,7 +12,6 @@
12#include <linux/fb.h> 12#include <linux/fb.h>
13#include <linux/gpio.h> 13#include <linux/gpio.h>
14#include <linux/gpio_keys.h> 14#include <linux/gpio_keys.h>
15#include <linux/i2c-gpio.h>
16#include <linux/init.h> 15#include <linux/init.h>
17#include <linux/input.h> 16#include <linux/input.h>
18#include <linux/leds.h> 17#include <linux/leds.h>
@@ -33,31 +32,6 @@
33 32
34#include "mach-smartq.h" 33#include "mach-smartq.h"
35 34
36static void __init smartq7_lcd_setup_gpio(void)
37{
38 gpio_request(S3C64XX_GPM(0), "LCD CSB pin");
39 gpio_request(S3C64XX_GPM(3), "LCD power");
40 gpio_request(S3C64XX_GPM(4), "LCD power status");
41
42 /* turn power off */
43 gpio_direction_output(S3C64XX_GPM(0), 1);
44 gpio_direction_output(S3C64XX_GPM(3), 0);
45 gpio_direction_input(S3C64XX_GPM(4));
46}
47
48static struct i2c_gpio_platform_data smartq7_lcd_control = {
49 .sda_pin = S3C64XX_GPM(2),
50 .scl_pin = S3C64XX_GPM(1),
51 .sda_is_open_drain = 1,
52 .scl_is_open_drain = 1,
53};
54
55static struct platform_device smartq7_lcd_control_device = {
56 .name = "i2c-gpio",
57 .id = 1,
58 .dev.platform_data = &smartq7_lcd_control,
59};
60
61static struct gpio_led smartq7_leds[] __initdata = { 35static struct gpio_led smartq7_leds[] __initdata = {
62 { 36 {
63 .name = "smartq7:red", 37 .name = "smartq7:red",
@@ -175,7 +149,6 @@ static struct s3c_fb_platdata smartq7_lcd_pdata __initdata = {
175static struct platform_device *smartq7_devices[] __initdata = { 149static struct platform_device *smartq7_devices[] __initdata = {
176 &smartq7_leds_device, 150 &smartq7_leds_device,
177 &smartq7_buttons_device, 151 &smartq7_buttons_device,
178 &smartq7_lcd_control_device,
179}; 152};
180 153
181static void __init smartq7_machine_init(void) 154static void __init smartq7_machine_init(void)
@@ -183,7 +156,6 @@ static void __init smartq7_machine_init(void)
183 s3c_fb_set_platdata(&smartq7_lcd_pdata); 156 s3c_fb_set_platdata(&smartq7_lcd_pdata);
184 157
185 smartq_machine_init(); 158 smartq_machine_init();
186 smartq7_lcd_setup_gpio();
187 159
188 platform_add_devices(smartq7_devices, ARRAY_SIZE(smartq7_devices)); 160 platform_add_devices(smartq7_devices, ARRAY_SIZE(smartq7_devices));
189} 161}
diff --git a/arch/arm/mach-s3c64xx/mach-smdk6410.c b/arch/arm/mach-s3c64xx/mach-smdk6410.c
index 2d43128f939f..d498219fff1b 100644
--- a/arch/arm/mach-s3c64xx/mach-smdk6410.c
+++ b/arch/arm/mach-s3c64xx/mach-smdk6410.c
@@ -155,6 +155,8 @@ static struct s3c_fb_pd_win smdk6410_fb_win0 = {
155 }, 155 },
156 .max_bpp = 32, 156 .max_bpp = 32,
157 .default_bpp = 16, 157 .default_bpp = 16,
158 .virtual_y = 480 * 2,
159 .virtual_x = 800,
158}; 160};
159 161
160/* 405566 clocks per frame => 60Hz refresh requires 24333960Hz clock */ 162/* 405566 clocks per frame => 60Hz refresh requires 24333960Hz clock */
diff --git a/arch/arm/plat-samsung/Kconfig b/arch/arm/plat-samsung/Kconfig
index 4529dd6232bc..7c0bde781167 100644
--- a/arch/arm/plat-samsung/Kconfig
+++ b/arch/arm/plat-samsung/Kconfig
@@ -6,7 +6,7 @@
6 6
7config PLAT_SAMSUNG 7config PLAT_SAMSUNG
8 bool 8 bool
9 depends on ARCH_S3C2410 || ARCH_S3C24A0 || ARCH_S3C64XX 9 depends on PLAT_S3C24XX || ARCH_S3C64XX || PLAT_S5P
10 select NO_IOPORT 10 select NO_IOPORT
11 default y 11 default y
12 help 12 help