2 * linux/arch/arm/mach-pxa/cm-x255.c
4 * Copyright (C) 2007, 2008 CompuLab, Ltd.
5 * Mike Rapoport <mike@compulab.co.il>
7 * This program is free software; you can redistribute it and/or modify
8 * it under the terms of the GNU General Public License version 2 as
9 * published by the Free Software Foundation.
12 #include <linux/platform_device.h>
13 #include <linux/irq.h>
14 #include <linux/gpio.h>
16 #include <linux/spi/spi.h>
18 #include <asm/mach/arch.h>
19 #include <asm/mach-types.h>
20 #include <asm/mach/map.h>
22 #include <mach/pxa2xx-regs.h>
23 #include <mach/mfp-pxa25x.h>
24 #include <mach/pxa2xx_spi.h>
25 #include <mach/bitfield.h>
29 static unsigned long cmx255_pin_config[] = {
32 GPIO29_AC97_SDATA_IN_0,
33 GPIO30_AC97_SDATA_OUT,
92 /* SDRAM and local bus */
101 GPIO0_GPIO | WAKEUP_ON_EDGE_BOTH,
102 GPIO9_GPIO, /* PC card reset */
105 GPIO5_GPIO | MFP_LPM_DRIVE_HIGH, /* NAND CE# */
106 GPIO4_GPIO | MFP_LPM_DRIVE_LOW, /* NAND ALE */
107 GPIO3_GPIO | MFP_LPM_DRIVE_LOW, /* NAND CLE */
108 GPIO10_GPIO, /* NAND Ready/Busy */
111 GPIO22_GPIO, /* DM9000 interrupt */
114 #if defined(CONFIG_SPI_PXA2XX)
115 static struct pxa2xx_spi_master pxa_ssp_master_info = {
119 static struct spi_board_info spi_board_info[] __initdata = {
121 .modalias = "rtc-max6902",
122 .max_speed_hz = 1000000,
128 static void __init cmx255_init_rtc(void)
130 pxa2xx_set_spi_info(1, &pxa_ssp_master_info);
131 spi_register_board_info(ARRAY_AND_SIZE(spi_board_info));
134 static inline void cmx255_init_rtc(void) {}
137 void __init cmx255_init(void)
139 pxa2xx_mfp_config(ARRAY_AND_SIZE(cmx255_pin_config));