Linux-2.6.12-rc2
[linux-2.6] / arch / ppc / platforms / 4xx / ibmstbx25.c
1 /*
2  * arch/ppc/platforms/4xx/ibmstbx25.c
3  *
4  * Author: Armin Kuster <akuster@mvista.com>
5  *
6  * 2000-2002 (c) MontaVista, Software, Inc.  This file is licensed under
7  * the terms of the GNU General Public License version 2.  This program
8  * is licensed "as is" without any warranty of any kind, whether express
9  * or implied.
10  */
11
12 #include <linux/init.h>
13 #include <asm/ocp.h>
14 #include <platforms/4xx/ibmstbx25.h>
15 #include <asm/ppc4xx_pic.h>
16
17 static struct ocp_func_iic_data ibmstbx25_iic0_def = {
18         .fast_mode      = 0,            /* Use standad mode (100Khz) */
19 };
20 OCP_SYSFS_IIC_DATA()
21
22 struct ocp_def core_ocp[] __initdata = {
23         { .vendor       = OCP_VENDOR_IBM,
24           .function     = OCP_FUNC_16550,
25           .index        = 0,
26           .paddr        = UART0_IO_BASE,
27           .irq          = UART0_INT,
28           .pm           = IBM_CPM_UART0,
29         },
30         { .vendor       = OCP_VENDOR_IBM,
31           .function     = OCP_FUNC_16550,
32           .index        = 1,
33           .paddr        = UART1_IO_BASE,
34           .irq          = UART1_INT,
35           .pm           = IBM_CPM_UART1,
36         },
37         { .vendor       = OCP_VENDOR_IBM,
38           .function     = OCP_FUNC_16550,
39           .index        = 2,
40           .paddr        = UART2_IO_BASE,
41           .irq          = UART2_INT,
42           .pm           = IBM_CPM_UART2,
43         },
44         { .vendor       = OCP_VENDOR_IBM,
45           .function     = OCP_FUNC_IIC,
46           .paddr        = IIC0_BASE,
47           .irq          = IIC0_IRQ,
48           .pm           = IBM_CPM_IIC0,
49           .additions    = &ibmstbx25_iic0_def,
50           .show         = &ocp_show_iic_data
51         },
52         { .vendor       = OCP_VENDOR_IBM,
53           .function     = OCP_FUNC_GPIO,
54           .paddr        = GPIO0_BASE,
55           .irq          = OCP_IRQ_NA,
56           .pm           = IBM_CPM_GPIO0,
57         },
58         { .vendor       = OCP_VENDOR_INVALID
59         }
60 };
61
62 /* Polarity and triggering settings for internal interrupt sources */
63 struct ppc4xx_uic_settings ppc4xx_core_uic_cfg[] __initdata = {
64         { .polarity     = 0xffff8f80,
65           .triggering   = 0x00000000,
66           .ext_irq_mask = 0x0000707f,   /* IRQ7 - IRQ9, IRQ0 - IRQ6 */
67         }
68 };