2007-04-30 14:37:19 -04:00
|
|
|
/*
|
|
|
|
* DaVinci IO address definitions
|
|
|
|
*
|
|
|
|
* Copied from include/asm/arm/arch-omap/io.h
|
|
|
|
*
|
|
|
|
* 2007 (c) MontaVista Software, Inc. This file is licensed under
|
|
|
|
* the terms of the GNU General Public License version 2. This program
|
|
|
|
* is licensed "as is" without any warranty of any kind, whether express
|
|
|
|
* or implied.
|
|
|
|
*/
|
|
|
|
#ifndef __ASM_ARCH_IO_H
|
|
|
|
#define __ASM_ARCH_IO_H
|
|
|
|
|
|
|
|
#define IO_SPACE_LIMIT 0xffffffff
|
|
|
|
|
|
|
|
/*
|
|
|
|
* ----------------------------------------------------------------------------
|
|
|
|
* I/O mapping
|
|
|
|
* ----------------------------------------------------------------------------
|
|
|
|
*/
|
|
|
|
#define IO_PHYS 0x01c00000
|
|
|
|
#define IO_OFFSET 0xfd000000 /* Virtual IO = 0xfec00000 */
|
|
|
|
#define IO_SIZE 0x00400000
|
|
|
|
#define IO_VIRT (IO_PHYS + IO_OFFSET)
|
|
|
|
#define io_v2p(va) ((va) - IO_OFFSET)
|
2008-09-15 07:09:14 -04:00
|
|
|
#define __IO_ADDRESS(x) ((x) + IO_OFFSET)
|
2007-04-30 14:37:19 -04:00
|
|
|
|
|
|
|
/*
|
|
|
|
* We don't actually have real ISA nor PCI buses, but there is so many
|
|
|
|
* drivers out there that might just work if we fake them...
|
|
|
|
*/
|
2008-11-30 06:45:54 -05:00
|
|
|
#define __io(a) __typesafe_io(a)
|
2007-04-30 14:37:19 -04:00
|
|
|
#define __mem_pci(a) (a)
|
|
|
|
#define __mem_isa(a) (a)
|
|
|
|
|
2008-09-15 07:09:14 -04:00
|
|
|
#define IO_ADDRESS(pa) IOMEM(__IO_ADDRESS(pa))
|
|
|
|
|
|
|
|
#ifdef __ASSEMBLER__
|
|
|
|
#define IOMEM(x) x
|
|
|
|
#else
|
|
|
|
#define IOMEM(x) ((void __force __iomem *)(x))
|
2007-04-30 14:37:19 -04:00
|
|
|
|
2009-04-14 08:04:16 -04:00
|
|
|
#define __arch_ioremap(p, s, t) davinci_ioremap(p, s, t)
|
|
|
|
#define __arch_iounmap(v) davinci_iounmap(v)
|
2007-04-30 14:37:19 -04:00
|
|
|
|
2009-04-14 08:04:16 -04:00
|
|
|
void __iomem *davinci_ioremap(unsigned long phys, size_t size,
|
|
|
|
unsigned int type);
|
|
|
|
void davinci_iounmap(volatile void __iomem *addr);
|
2007-04-30 14:37:19 -04:00
|
|
|
|
|
|
|
#endif /* __ASSEMBLER__ */
|
|
|
|
#endif /* __ASM_ARCH_IO_H */
|