diff options
Diffstat (limited to 'arch/arm/mach-s3c64xx/mach-smdk6410.c')
-rw-r--r-- | arch/arm/mach-s3c64xx/mach-smdk6410.c | 34 |
1 files changed, 33 insertions, 1 deletions
diff --git a/arch/arm/mach-s3c64xx/mach-smdk6410.c b/arch/arm/mach-s3c64xx/mach-smdk6410.c index d9a03555f88b..2d43128f939f 100644 --- a/arch/arm/mach-s3c64xx/mach-smdk6410.c +++ b/arch/arm/mach-s3c64xx/mach-smdk6410.c | |||
@@ -17,6 +17,7 @@ | |||
17 | #include <linux/list.h> | 17 | #include <linux/list.h> |
18 | #include <linux/timer.h> | 18 | #include <linux/timer.h> |
19 | #include <linux/init.h> | 19 | #include <linux/init.h> |
20 | #include <linux/input.h> | ||
20 | #include <linux/serial_core.h> | 21 | #include <linux/serial_core.h> |
21 | #include <linux/platform_device.h> | 22 | #include <linux/platform_device.h> |
22 | #include <linux/io.h> | 23 | #include <linux/io.h> |
@@ -56,6 +57,7 @@ | |||
56 | #include <mach/regs-gpio.h> | 57 | #include <mach/regs-gpio.h> |
57 | #include <mach/regs-sys.h> | 58 | #include <mach/regs-sys.h> |
58 | #include <mach/regs-srom.h> | 59 | #include <mach/regs-srom.h> |
60 | #include <plat/ata.h> | ||
59 | #include <plat/iic.h> | 61 | #include <plat/iic.h> |
60 | #include <plat/fb.h> | 62 | #include <plat/fb.h> |
61 | #include <plat/gpio-cfg.h> | 63 | #include <plat/gpio-cfg.h> |
@@ -66,6 +68,7 @@ | |||
66 | #include <plat/cpu.h> | 68 | #include <plat/cpu.h> |
67 | #include <plat/adc.h> | 69 | #include <plat/adc.h> |
68 | #include <plat/ts.h> | 70 | #include <plat/ts.h> |
71 | #include <plat/keypad.h> | ||
69 | 72 | ||
70 | #define UCON S3C2410_UCON_DEFAULT | S3C2410_UCON_UCLK | 73 | #define UCON S3C2410_UCON_DEFAULT | S3C2410_UCON_UCLK |
71 | #define ULCON S3C2410_LCON_CS8 | S3C2410_LCON_PNONE | S3C2410_LCON_STOPB | 74 | #define ULCON S3C2410_LCON_CS8 | S3C2410_LCON_PNONE | S3C2410_LCON_STOPB |
@@ -141,7 +144,6 @@ static struct platform_device smdk6410_lcd_powerdev = { | |||
141 | static struct s3c_fb_pd_win smdk6410_fb_win0 = { | 144 | static struct s3c_fb_pd_win smdk6410_fb_win0 = { |
142 | /* this is to ensure we use win0 */ | 145 | /* this is to ensure we use win0 */ |
143 | .win_mode = { | 146 | .win_mode = { |
144 | .pixclock = 41094, | ||
145 | .left_margin = 8, | 147 | .left_margin = 8, |
146 | .right_margin = 13, | 148 | .right_margin = 13, |
147 | .upper_margin = 7, | 149 | .upper_margin = 7, |
@@ -242,6 +244,29 @@ static struct platform_device smdk6410_b_pwr_5v = { | |||
242 | }; | 244 | }; |
243 | #endif | 245 | #endif |
244 | 246 | ||
247 | static struct s3c_ide_platdata smdk6410_ide_pdata __initdata = { | ||
248 | .setup_gpio = s3c64xx_ide_setup_gpio, | ||
249 | }; | ||
250 | |||
251 | static uint32_t smdk6410_keymap[] __initdata = { | ||
252 | /* KEY(row, col, keycode) */ | ||
253 | KEY(0, 3, KEY_1), KEY(0, 4, KEY_2), KEY(0, 5, KEY_3), | ||
254 | KEY(0, 6, KEY_4), KEY(0, 7, KEY_5), | ||
255 | KEY(1, 3, KEY_A), KEY(1, 4, KEY_B), KEY(1, 5, KEY_C), | ||
256 | KEY(1, 6, KEY_D), KEY(1, 7, KEY_E) | ||
257 | }; | ||
258 | |||
259 | static struct matrix_keymap_data smdk6410_keymap_data __initdata = { | ||
260 | .keymap = smdk6410_keymap, | ||
261 | .keymap_size = ARRAY_SIZE(smdk6410_keymap), | ||
262 | }; | ||
263 | |||
264 | static struct samsung_keypad_platdata smdk6410_keypad_data __initdata = { | ||
265 | .keymap_data = &smdk6410_keymap_data, | ||
266 | .rows = 2, | ||
267 | .cols = 8, | ||
268 | }; | ||
269 | |||
245 | static struct map_desc smdk6410_iodesc[] = {}; | 270 | static struct map_desc smdk6410_iodesc[] = {}; |
246 | 271 | ||
247 | static struct platform_device *smdk6410_devices[] __initdata = { | 272 | static struct platform_device *smdk6410_devices[] __initdata = { |
@@ -257,6 +282,7 @@ static struct platform_device *smdk6410_devices[] __initdata = { | |||
257 | &s3c_device_ohci, | 282 | &s3c_device_ohci, |
258 | &s3c_device_usb_hsotg, | 283 | &s3c_device_usb_hsotg, |
259 | &s3c64xx_device_iisv4, | 284 | &s3c64xx_device_iisv4, |
285 | &samsung_device_keypad, | ||
260 | 286 | ||
261 | #ifdef CONFIG_REGULATOR | 287 | #ifdef CONFIG_REGULATOR |
262 | &smdk6410_b_pwr_5v, | 288 | &smdk6410_b_pwr_5v, |
@@ -265,6 +291,8 @@ static struct platform_device *smdk6410_devices[] __initdata = { | |||
265 | 291 | ||
266 | &smdk6410_smsc911x, | 292 | &smdk6410_smsc911x, |
267 | &s3c_device_adc, | 293 | &s3c_device_adc, |
294 | &s3c_device_cfcon, | ||
295 | &s3c_device_rtc, | ||
268 | &s3c_device_ts, | 296 | &s3c_device_ts, |
269 | &s3c_device_wdt, | 297 | &s3c_device_wdt, |
270 | }; | 298 | }; |
@@ -636,6 +664,8 @@ static void __init smdk6410_machine_init(void) | |||
636 | s3c_i2c1_set_platdata(NULL); | 664 | s3c_i2c1_set_platdata(NULL); |
637 | s3c_fb_set_platdata(&smdk6410_lcd_pdata); | 665 | s3c_fb_set_platdata(&smdk6410_lcd_pdata); |
638 | 666 | ||
667 | samsung_keypad_set_platdata(&smdk6410_keypad_data); | ||
668 | |||
639 | s3c24xx_ts_set_platdata(&s3c_ts_platform); | 669 | s3c24xx_ts_set_platdata(&s3c_ts_platform); |
640 | 670 | ||
641 | /* configure nCS1 width to 16 bits */ | 671 | /* configure nCS1 width to 16 bits */ |
@@ -665,6 +695,8 @@ static void __init smdk6410_machine_init(void) | |||
665 | i2c_register_board_info(0, i2c_devs0, ARRAY_SIZE(i2c_devs0)); | 695 | i2c_register_board_info(0, i2c_devs0, ARRAY_SIZE(i2c_devs0)); |
666 | i2c_register_board_info(1, i2c_devs1, ARRAY_SIZE(i2c_devs1)); | 696 | i2c_register_board_info(1, i2c_devs1, ARRAY_SIZE(i2c_devs1)); |
667 | 697 | ||
698 | s3c_ide_set_platdata(&smdk6410_ide_pdata); | ||
699 | |||
668 | platform_add_devices(smdk6410_devices, ARRAY_SIZE(smdk6410_devices)); | 700 | platform_add_devices(smdk6410_devices, ARRAY_SIZE(smdk6410_devices)); |
669 | } | 701 | } |
670 | 702 | ||