Avoid beyond bounds copy while caching ACL
[zen-stable.git] / arch / unicore32 / include / asm / io.h
blobadddf6d640771ac88ab0c5b016ad96769cca6a9e
1 /*
2 * linux/arch/unicore32/include/asm/io.h
4 * Code specific to PKUnity SoC and UniCore ISA
6 * Copyright (C) 2001-2010 GUAN Xue-tao
8 * This program is free software; you can redistribute it and/or modify
9 * it under the terms of the GNU General Public License version 2 as
10 * published by the Free Software Foundation.
12 #ifndef __UNICORE_IO_H__
13 #define __UNICORE_IO_H__
15 #ifdef __KERNEL__
17 #include <asm/byteorder.h>
18 #include <asm/memory.h>
19 #include <asm/system.h>
21 #define PCI_IOBASE PKUNITY_PCILIO_BASE
22 #include <asm-generic/io.h>
25 * __uc32_ioremap and __uc32_ioremap_cached takes CPU physical address.
27 extern void __iomem *__uc32_ioremap(unsigned long, size_t);
28 extern void __iomem *__uc32_ioremap_cached(unsigned long, size_t);
29 extern void __uc32_iounmap(volatile void __iomem *addr);
32 * ioremap and friends.
34 * ioremap takes a PCI memory address, as specified in
35 * Documentation/io-mapping.txt.
38 #define ioremap(cookie, size) __uc32_ioremap(cookie, size)
39 #define ioremap_cached(cookie, size) __uc32_ioremap_cached(cookie, size)
40 #define ioremap_nocache(cookie, size) __uc32_ioremap(cookie, size)
41 #define iounmap(cookie) __uc32_iounmap(cookie)
43 #define HAVE_ARCH_PIO_SIZE
44 #define PIO_OFFSET (unsigned int)(PCI_IOBASE)
45 #define PIO_MASK (unsigned int)(IO_SPACE_LIMIT)
46 #define PIO_RESERVED (PIO_OFFSET + PIO_MASK + 1)
48 #endif /* __KERNEL__ */
49 #endif /* __UNICORE_IO_H__ */