[ARM] 3831/1: iop3xx: factor out common register defines
[linux-2.6/kvm.git] / include / asm-arm / arch-iop32x / iop321.h
blob1757222a4cad93ddf95098e327b0130ebce4b1a8
1 /*
2 * linux/include/asm/arch-iop32x/iop321.h
4 * Intel IOP321 Chip definitions
6 * Author: Rory Bolt <rorybolt@pacbell.net>
7 * Copyright (C) 2002 Rory Bolt
8 * Copyright (C) 2004 Intel Corp.
10 * This program is free software; you can redistribute it and/or modify
11 * it under the terms of the GNU General Public License version 2 as
12 * published by the Free Software Foundation.
15 #ifndef _IOP321_HW_H_
16 #define _IOP321_HW_H_
20 * This is needed for mixed drivers that need to work on all
21 * IOP3xx variants but behave slightly differently on each.
23 #ifndef __ASSEMBLY__
24 #define iop_is_321() 1
25 #endif
28 * IOP321 chipset registers
30 #define IOP321_VIRT_MEM_BASE 0xfeffe000 /* chip virtual mem address*/
31 #define IOP321_PHYS_MEM_BASE 0xffffe000 /* chip physical memory address */
32 #define IOP321_REG_ADDR(reg) (IOP321_VIRT_MEM_BASE | (reg))
34 /* Reserved 0x00000000 through 0x000000FF */
36 /* Address Translation Unit 0x00000100 through 0x000001FF */
38 /* Messaging Unit 0x00000300 through 0x000003FF */
40 /* DMA Controller 0x00000400 through 0x000004FF */
42 /* Memory controller 0x00000500 through 0x0005FF */
44 /* Peripheral bus interface unit 0x00000680 through 0x0006FF */
46 /* Peripheral performance monitoring unit 0x00000700 through 0x00077F */
48 /* Internal arbitration unit 0x00000780 through 0x0007BF */
49 #define IOP321_IACR (volatile u32 *)IOP321_REG_ADDR(0x00000780)
50 #define IOP321_MTTR1 (volatile u32 *)IOP321_REG_ADDR(0x00000784)
51 #define IOP321_MTTR2 (volatile u32 *)IOP321_REG_ADDR(0x00000788)
53 /* General Purpose I/O Registers */
54 #define IOP321_GPOE (volatile u32 *)IOP321_REG_ADDR(0x000007C4)
55 #define IOP321_GPID (volatile u32 *)IOP321_REG_ADDR(0x000007C8)
56 #define IOP321_GPOD (volatile u32 *)IOP321_REG_ADDR(0x000007CC)
58 /* Interrupt Controller */
59 #define IOP321_INTCTL (volatile u32 *)IOP321_REG_ADDR(0x000007D0)
60 #define IOP321_INTSTR (volatile u32 *)IOP321_REG_ADDR(0x000007D4)
61 #define IOP321_IINTSRC (volatile u32 *)IOP321_REG_ADDR(0x000007D8)
62 #define IOP321_FINTSRC (volatile u32 *)IOP321_REG_ADDR(0x000007DC)
64 /* Application accelerator unit 0x00000800 - 0x000008FF */
66 /* SSP serial port unit 0x00001600 - 0x0000167F */
67 /* I2C bus interface unit 0x00001680 - 0x000016FF */
69 /* for I2C bit defs see drivers/i2c/i2c-iop3xx.h */
72 * Peripherals that are shared between the iop32x and iop33x but
73 * located at different addresses.
75 #define IOP3XX_GPIO_REG(reg) (IOP3XX_PERIPHERAL_VIRT_BASE + 0x07c0 + (reg))
76 #define IOP3XX_TIMER_REG(reg) (IOP3XX_PERIPHERAL_VIRT_BASE + 0x07e0 + (reg))
78 #include <asm/hardware/iop3xx.h>
81 #ifndef __ASSEMBLY__
82 extern void iop321_init_irq(void);
83 extern void iop321_time_init(void);
84 #endif
86 #endif // _IOP321_HW_H_