aboutsummaryrefslogtreecommitdiffstats
path: root/arch/arm/mach-pxa/spitz.c
diff options
context:
space:
mode:
authorRichard Purdie <rpurdie@rpsys.net>2005-11-12 13:53:48 -0500
committerRussell King <rmk+kernel@arm.linux.org.uk>2005-11-12 13:53:48 -0500
commit94cabd003e989556d8bf84027d96284dc2d99c76 (patch)
treef4f1d6ba9a6389c83f8d028c4a8c8aa6890c128b /arch/arm/mach-pxa/spitz.c
parenta1510210c45c9af5784d64596c7025997e1add7d (diff)
[ARM] 3149/1: SharpSL: Add Akita (SL-C1000) machine support
Patch from Richard Purdie Add the core machine support for the Sharp SL-C1000 (Akita) and enable the Kconfig selection for it. Signed-off-by: Richard Purdie <rpurdie@rpsys.net> Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
Diffstat (limited to 'arch/arm/mach-pxa/spitz.c')
-rw-r--r--arch/arm/mach-pxa/spitz.c49
1 files changed, 49 insertions, 0 deletions
diff --git a/arch/arm/mach-pxa/spitz.c b/arch/arm/mach-pxa/spitz.c
index 4e9a699ee428..2df1b56615b1 100644
--- a/arch/arm/mach-pxa/spitz.c
+++ b/arch/arm/mach-pxa/spitz.c
@@ -345,6 +345,16 @@ static void spitz_irda_transceiver_mode(struct device *dev, int mode)
345 reset_scoop_gpio(&spitzscoop2_device.dev, SPITZ_SCP2_IR_ON); 345 reset_scoop_gpio(&spitzscoop2_device.dev, SPITZ_SCP2_IR_ON);
346} 346}
347 347
348#ifdef CONFIG_MACH_AKITA
349static void akita_irda_transceiver_mode(struct device *dev, int mode)
350{
351 if (mode & IR_OFF)
352 akita_set_ioexp(&akitaioexp_device.dev, AKITA_IOEXP_IR_ON);
353 else
354 akita_reset_ioexp(&akitaioexp_device.dev, AKITA_IOEXP_IR_ON);
355}
356#endif
357
348static struct pxaficp_platform_data spitz_ficp_platform_data = { 358static struct pxaficp_platform_data spitz_ficp_platform_data = {
349 .transceiver_cap = IR_SIRMODE | IR_OFF, 359 .transceiver_cap = IR_SIRMODE | IR_OFF,
350 .transceiver_mode = spitz_irda_transceiver_mode, 360 .transceiver_mode = spitz_irda_transceiver_mode,
@@ -417,6 +427,32 @@ static void __init spitz_init(void)
417 platform_device_register(&spitzscoop2_device); 427 platform_device_register(&spitzscoop2_device);
418} 428}
419 429
430#ifdef CONFIG_MACH_AKITA
431/*
432 * Akita IO Expander
433 */
434struct platform_device akitaioexp_device = {
435 .name = "akita-ioexp",
436 .id = -1,
437};
438
439static void __init akita_init(void)
440{
441 spitz_ficp_platform_data.transceiver_mode = akita_irda_transceiver_mode;
442
443 /* We just pretend the second element of the array doesn't exist */
444 spitz_pcmcia_config.num_devs = 1;
445 platform_scoop_config = &spitz_pcmcia_config;
446 spitz_bl_machinfo.set_bl_intensity = akita_bl_set_intensity;
447
448 platform_device_register(&akitaioexp_device);
449
450 spitzscoop_device.dev.parent = &akitaioexp_device.dev;
451 common_init();
452}
453#endif
454
455
420static void __init fixup_spitz(struct machine_desc *desc, 456static void __init fixup_spitz(struct machine_desc *desc,
421 struct tag *tags, char **cmdline, struct meminfo *mi) 457 struct tag *tags, char **cmdline, struct meminfo *mi)
422{ 458{
@@ -452,3 +488,16 @@ MACHINE_START(BORZOI, "SHARP Borzoi")
452 .timer = &pxa_timer, 488 .timer = &pxa_timer,
453MACHINE_END 489MACHINE_END
454#endif 490#endif
491
492#ifdef CONFIG_MACH_AKITA
493MACHINE_START(AKITA, "SHARP Akita")
494 .phys_ram = 0xa0000000,
495 .phys_io = 0x40000000,
496 .io_pg_offst = (io_p2v(0x40000000) >> 18) & 0xfffc,
497 .fixup = fixup_spitz,
498 .map_io = pxa_map_io,
499 .init_irq = pxa_init_irq,
500 .init_machine = akita_init,
501 .timer = &pxa_timer,
502MACHINE_END
503#endif