gumstixreg.h revision 1.1 1 1.1 kiyohara /*
2 1.1 kiyohara * Copyright (C) 2005, 2006 WIDE Project and SOUM Corporation.
3 1.1 kiyohara * All rights reserved.
4 1.1 kiyohara *
5 1.1 kiyohara * Written by Takashi Kiyohara and Susumu Miki for WIDE Project and SOUM
6 1.1 kiyohara * Corporation.
7 1.1 kiyohara *
8 1.1 kiyohara * Redistribution and use in source and binary forms, with or without
9 1.1 kiyohara * modification, are permitted provided that the following conditions
10 1.1 kiyohara * are met:
11 1.1 kiyohara * 1. Redistributions of source code must retain the above copyright
12 1.1 kiyohara * notice, this list of conditions and the following disclaimer.
13 1.1 kiyohara * 2. Redistributions in binary form must reproduce the above copyright
14 1.1 kiyohara * notice, this list of conditions and the following disclaimer in the
15 1.1 kiyohara * documentation and/or other materials provided with the distribution.
16 1.1 kiyohara * 3. Neither the name of the project nor the name of SOUM Corporation
17 1.1 kiyohara * may be used to endorse or promote products derived from this software
18 1.1 kiyohara * without specific prior written permission.
19 1.1 kiyohara *
20 1.1 kiyohara * THIS SOFTWARE IS PROVIDED BY THE PROJECT and SOUM CORPORATION ``AS IS''
21 1.1 kiyohara * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED
22 1.1 kiyohara * TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
23 1.1 kiyohara * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE PROJECT AND SOUM CORPORATION
24 1.1 kiyohara * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
25 1.1 kiyohara * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
26 1.1 kiyohara * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
27 1.1 kiyohara * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
28 1.1 kiyohara * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
29 1.1 kiyohara * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
30 1.1 kiyohara * POSSIBILITY OF SUCH DAMAGE.
31 1.1 kiyohara */
32 1.1 kiyohara #ifndef _EVBARM_GUMSTIXREG_H_
33 1.1 kiyohara #define _EVBARM_GUMSTIXREG_H_
34 1.1 kiyohara
35 1.1 kiyohara #include <arm/xscale/pxa2x0reg.h>
36 1.1 kiyohara
37 1.1 kiyohara
38 1.1 kiyohara /*
39 1.1 kiyohara * Logical mapping for onboard/integrated peripherals
40 1.1 kiyohara * that are used while bootstrapping.
41 1.1 kiyohara */
42 1.1 kiyohara #define GUMSTIX_IO_AREA_VBASE 0xfd000000
43 1.1 kiyohara #define GUMSTIX_INTCTL_VBASE 0xfd000000
44 1.1 kiyohara #define GUMSTIX_CLKMAN_VBASE 0xfd100000
45 1.1 kiyohara #define GUMSTIX_GPIO_VBASE 0xfd200000
46 1.1 kiyohara #define GUMSTIX_FFUART_VBASE 0xfd300000
47 1.1 kiyohara #define GUMSTIX_BTUART_VBASE 0xfd400000
48 1.1 kiyohara
49 1.1 kiyohara
50 1.1 kiyohara #define ioreg_read(a) (*(volatile unsigned *)(a))
51 1.1 kiyohara #define ioreg_write(a,v) (*(volatile unsigned *)(a)=(v))
52 1.1 kiyohara
53 1.1 kiyohara #define ioreg16_read(a) (*(volatile uint16_t *)(a))
54 1.1 kiyohara #define ioreg16_write(a,v) (*(volatile uint16_t *)(a)=(v))
55 1.1 kiyohara
56 1.1 kiyohara #define ioreg8_read(a) (*(volatile uint8_t *)(a))
57 1.1 kiyohara #define ioreg8_write(a,v) (*(volatile uint8_t *)(a)=(v))
58 1.1 kiyohara
59 1.1 kiyohara #endif /* _EVBARM_GUMSTIXREG_H_ */
60