11 #include <linux/input.h>
12 #include <linux/i2c.h>
17 #include <linux/module.h>
41 static int db1300_gpio_pins[] __initdata = {
49 static int db1300_dev_pins[] __initdata = {
98 static void __init db1300_gpio_config(
void)
102 i = &db1300_dev_pins[0];
106 i = &db1300_gpio_pins[0];
108 au1300_gpio_direction_input(*i++);
115 static void au1300_nand_cmd_ctrl(
struct mtd_info *mtd,
int cmd,
121 ioaddr &= 0xffffff00;
138 static int au1300_nand_device_ready(
struct mtd_info *mtd)
147 .size = 8 * 1024 * 1024,
160 .nr_partitions =
ARRAY_SIZE(db1300_nand_parts),
161 .partitions = db1300_nand_parts,
165 .dev_ready = au1300_nand_device_ready,
166 .cmd_ctrl = au1300_nand_cmd_ctrl,
170 static struct resource db1300_nand_res[] = {
181 .resource = db1300_nand_res,
190 static struct resource db1300_eth_res[] = {
214 .resource = db1300_eth_res,
216 .platform_data = &db1300_eth_config,
222 static struct resource au1300_psc1_res[] = {
246 .name =
"au1xpsc_ac97",
249 .resource = au1300_psc1_res,
254 static struct resource au1300_psc2_res[] = {
278 .name =
"au1xpsc_i2s",
281 .resource = au1300_psc2_res,
286 static struct resource au1300_psc3_res[] = {
310 .name =
"au1xpsc_smbus",
313 .resource = au1300_psc3_res,
327 .debounce_interval = 1,
329 .desc =
"5waysw-down",
335 .debounce_interval = 1,
343 .debounce_interval = 1,
345 .desc =
"5waysw-right",
351 .debounce_interval = 1,
353 .desc =
"5waysw-left",
359 .debounce_interval = 1,
361 .desc =
"5waysw-push",
366 .buttons = db1300_5waysw_arrowkeys,
367 .nbuttons =
ARRAY_SIZE(db1300_5waysw_arrowkeys),
369 .name =
"db1300-5wayswitch",
375 .platform_data = &db1300_5waysw_data,
385 #define IDE_ALT_START (14 << DB1300_IDE_REG_SHIFT)
386 static struct resource db1300_ide_res[] = {
406 .platform_data = &db1300_ide_info,
408 .name =
"pata_platform",
409 .resource = db1300_ide_res,
438 static int db1300_mmc_card_readonly(
void *
mmc_host)
444 static int db1300_mmc_card_inserted(
void *
mmc_host)
449 static int db1300_mmc_cd_setup(
void *
mmc_host,
int en)
455 "sd_insert", mmc_host);
460 "sd_eject", mmc_host);
466 if (db1300_mmc_card_inserted(mmc_host))
490 .brightness_set = db1300_mmcled_set,
494 .cd_setup = db1300_mmc_cd_setup,
495 .card_inserted = db1300_mmc_card_inserted,
496 .card_readonly = db1300_mmc_card_readonly,
497 .led = &db1300_mmc_led,
500 static struct resource au1300_sd1_res[] = {
527 .name =
"au1xxx-mmc",
529 .resource = au1300_sd1_res,
535 static int db1300_movinand_inserted(
void *mmc_host)
540 static int db1300_movinand_readonly(
void *mmc_host)
545 static void db1300_movinand_led_set(
struct led_classdev *led,
555 .brightness_set = db1300_movinand_led_set,
559 .card_inserted = db1300_movinand_inserted,
560 .card_readonly = db1300_movinand_readonly,
561 .led = &db1300_movinand_led,
565 static struct resource au1300_sd0_res[] = {
592 .name =
"au1xxx-mmc",
594 .resource = au1300_sd0_res,
601 .name =
"wm9712-codec",
606 .name =
"au1xpsc-pcm",
611 .name =
"au1xpsc-pcm",
616 .name =
"db1300-ac97",
620 .name =
"db1300-i2s",
625 static int db1300fb_panel_index(
void)
630 static int db1300fb_panel_init(
void)
638 static int db1300fb_panel_shutdown(
void)
647 .panel_index = db1300fb_panel_index,
648 .panel_init = db1300fb_panel_init,
649 .panel_shutdown = db1300fb_panel_shutdown,
652 static struct resource au1300_lcd_res[] = {
668 .name =
"au1200-lcd",
671 .dma_mask = &au1300_lcd_dmamask,
673 .platform_data = &db1300fb_pd,
676 .resource = au1300_lcd_res,
701 int swapped, cpldirq;
760 unsigned short whoami;
762 db1300_gpio_config();
768 "BoardID %d CPLD Rev %d DaughtercardID %d\n",