]> git.sur5r.net Git - freertos/blob - FreeRTOS/Demo/CORTEX_A9_Zynq_ZC702/RTOSDemo_bsp/ps7_cortexa9_0/libsrc/standalone_v5_4/src/translation_table.S
xTaskGenericNotify() now sets xYieldPending to pdTRUE even when the 'higher priority...
[freertos] / FreeRTOS / Demo / CORTEX_A9_Zynq_ZC702 / RTOSDemo_bsp / ps7_cortexa9_0 / libsrc / standalone_v5_4 / src / translation_table.S
1 /******************************************************************************
2 *
3 * Copyright (C) 2009 - 2015 Xilinx, Inc.  All rights reserved.
4 *
5 * Permission is hereby granted, free of charge, to any person obtaining a copy
6 * of this software and associated documentation files (the "Software"), to deal
7 * in the Software without restriction, including without limitation the rights
8 * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9 * copies of the Software, and to permit persons to whom the Software is
10 * furnished to do so, subject to the following conditions:
11 *
12 * The above copyright notice and this permission notice shall be included in
13 * all copies or substantial portions of the Software.
14 *
15 * Use of the Software is limited solely to applications:
16 * (a) running on a Xilinx device, or
17 * (b) that interact with a Xilinx device through a bus or interconnect.
18 *
19 * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
20 * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
21 * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
22 * XILINX  BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
23 * WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF
24 * OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
25 * SOFTWARE.
26 *
27 * Except as contained in this notice, the name of the Xilinx shall not be used
28 * in advertising or otherwise to promote the sale, use or other dealings in
29 * this Software without prior written authorization from Xilinx.
30 *
31 ******************************************************************************/
32 /*****************************************************************************/
33 /**
34 * @file translation_table.s
35 *
36 * This file contains the initialization for the MMU table in RAM
37 * needed by the Cortex A9 processor
38 *
39 * <pre>
40 * MODIFICATION HISTORY:
41 *
42 * Ver   Who  Date     Changes
43 * ----- ---- -------- ---------------------------------------------------
44 * 1.00a ecm  10/20/09 Initial version
45 * 3.04a sdm  01/13/12 Updated MMU table to mark DDR memory as Shareable
46 * 3.07a sgd  07/05/2012 Configuring device address spaces as shareable device
47 *                      instead of strongly-ordered.
48 * 3.07a asa  07/17/2012 Changed the property of the ".mmu_tbl" section.
49 * 4.2   pkp  09/02/2014 added entries for 0xfe000000 to 0xffefffff as reserved
50 *                       and  0xe0000000 - 0xe1ffffff is broken down into
51 *                       0xe0000000 - 0xe02fffff (memory mapped devides)
52 *                       0xe0300000 - 0xe0ffffff (reserved) and
53 *                       0xe1000000 - 0xe1ffffff (NAND)
54 * 5.2   pkp  06/08/2015 put a check for XPAR_PS7_DDR_0_S_AXI_BASEADDR to confirm
55 *                       if DDR is present or not and accordingly generate the
56 *                       translation table
57 * </pre>
58 *
59 * @note
60 *
61 * None.
62 *
63 ******************************************************************************/
64 #include "xparameters.h"
65         .globl  MMUTable
66
67         .section .mmu_tbl,"a"
68
69 MMUTable:
70         /* Each table entry occupies one 32-bit word and there are
71          * 4096 entries, so the entire table takes up 16KB.
72          * Each entry covers a 1MB section.
73          */
74 .set SECT, 0
75
76 #ifdef XPAR_PS7_DDR_0_S_AXI_BASEADDR
77 .set DDR_START, XPAR_PS7_DDR_0_S_AXI_BASEADDR
78 .set DDR_END, XPAR_PS7_DDR_0_S_AXI_HIGHADDR
79 .set DDR_SIZE, (DDR_END - DDR_START)+1
80 .set DDR_REG, DDR_SIZE/0x100000
81 #else
82 .set DDR_REG, 0
83 #endif
84
85 .set UNDEF_REG, 0x3FF - DDR_REG
86
87                                 /*0x00000000 - 0x00100000 (cacheable )*/
88 .word   SECT + 0x15de6          /* S=b1 TEX=b101 AP=b11, Domain=b1111, C=b0, B=b1 */
89 .set    SECT, SECT+0x100000
90
91 .rept   DDR_REG                 /*  (DDR Cacheable) */
92 .word   SECT + 0x15de6          /* S=b1 TEX=b101 AP=b11, Domain=b1111, C=b0, B=b1 */
93 .set    SECT, SECT+0x100000
94 .endr
95
96 .rept   UNDEF_REG                       /*  (unassigned/reserved).
97                                  * Generates a translation fault if accessed */
98 .word   SECT + 0x0              /* S=b0 TEX=b000 AP=b00, Domain=b0, C=b0, B=b0 */
99 .set    SECT, SECT+0x100000
100 .endr
101
102
103 .rept   0x0400                  /* 0x40000000 - 0x7fffffff (FPGA slave0) */
104 .word   SECT + 0xc02            /* S=b0 TEX=b000 AP=b11, Domain=b0, C=b0, B=b1 */
105 .set    SECT, SECT+0x100000
106 .endr
107
108 .rept   0x0400                  /* 0x80000000 - 0xbfffffff (FPGA slave1) */
109 .word   SECT + 0xc02            /* S=b0 TEX=b000 AP=b11, Domain=b0, C=b0, B=b1 */
110 .set    SECT, SECT+0x100000
111 .endr
112
113 .rept   0x0200                  /* 0xc0000000 - 0xdfffffff (unassigned/reserved).
114                                  * Generates a translation fault if accessed */
115 .word   SECT + 0x0              /* S=b0 TEX=b000 AP=b00, Domain=b0, C=b0, B=b0 */
116 .set    SECT, SECT+0x100000
117 .endr
118
119 .rept   0x003                   /* 0xe0000000 - 0xe02fffff (Memory mapped devices)
120                                  * UART/USB/IIC/SPI/CAN/GEM/GPIO/QSPI/SD/NAND */
121 .word   SECT + 0xc06            /* S=b0 TEX=b000 AP=b11, Domain=b0, C=b0, B=b1 */
122 .set    SECT, SECT+0x100000
123 .endr
124
125 .rept   0x0D                    /* 0xe0300000 - 0xe0ffffff (unassigned/reserved).
126                                  * Generates a translation fault if accessed */
127 .word   SECT + 0x0              /* S=b0 TEX=b000 AP=b00, Domain=b0, C=b0, B=b0 */
128 .set    SECT, SECT+0x100000
129 .endr
130
131 .rept   0x0010                  /* 0xe1000000 - 0xe1ffffff (NAND) */
132 .word   SECT + 0xc06            /* S=b0 TEX=b000 AP=b11, Domain=b0, C=b0, B=b1 */
133 .set    SECT, SECT+0x100000
134 .endr
135
136 .rept   0x0020                  /* 0xe2000000 - 0xe3ffffff (NOR) */
137 .word   SECT + 0xc06            /* S=b0 TEX=b000 AP=b11, Domain=b0, C=b0, B=b1 */
138 .set    SECT, SECT+0x100000
139 .endr
140
141 .rept   0x0020                  /* 0xe4000000 - 0xe5ffffff (SRAM) */
142 .word   SECT + 0xc0e            /* S=b0 TEX=b000 AP=b11, Domain=b0, C=b1, B=b1 */
143 .set    SECT, SECT+0x100000
144 .endr
145
146 .rept   0x0120                  /* 0xe6000000 - 0xf7ffffff (unassigned/reserved).
147                                  * Generates a translation fault if accessed */
148 .word   SECT + 0x0              /* S=b0 TEX=b000 AP=b00, Domain=b0, C=b0, B=b0 */
149 .set    SECT, SECT+0x100000
150 .endr
151
152 /* 0xf8000c00 to 0xf8000fff, 0xf8010000 to 0xf88fffff and
153    0xf8f03000 to 0xf8ffffff are reserved  but due to granual size of
154    1MB, it is not possible to define separate regions for them */
155
156 .rept   0x0010                  /* 0xf8000000 - 0xf8ffffff (AMBA APB Peripherals) */
157
158 .word   SECT + 0xc06            /* S=b0 TEX=b000 AP=b11, Domain=b0, C=b0, B=b1 */
159 .set    SECT, SECT+0x100000
160 .endr
161
162 .rept   0x0030                  /* 0xf9000000 - 0xfbffffff (unassigned/reserved).
163                                  * Generates a translation fault if accessed */
164 .word   SECT + 0x0              /* S=b0 TEX=b000 AP=b00, Domain=b0, C=b0, B=b0 */
165 .set    SECT, SECT+0x100000
166 .endr
167
168 .rept   0x0020                  /* 0xfc000000 - 0xfdffffff (Linear QSPI - XIP) */
169 .word   SECT + 0xc0a            /* S=b0 TEX=b000 AP=b11, Domain=b0, C=b1, B=b1 */
170 .set    SECT, SECT+0x100000
171 .endr
172
173 .rept   0x001F                  /* 0xfe000000 - 0xffefffff (unassigned/reserved).
174                                  * Generates a translation fault if accessed */
175 .word   SECT + 0x0              /* S=b0 TEX=b000 AP=b00, Domain=b0, C=b0, B=b0 */
176 .set    SECT, SECT+0x100000
177 .endr
178
179 /* 0xfff00000 to 0xfffb0000 is reserved but due to granual size of
180    1MB, it is not possible to define separate region for  it
181
182 /* 0xfff00000 - 0xffffffff
183    256K OCM when mapped to high address space
184    inner-cacheable */
185 .word   SECT + 0x4c0e           /* S=b0 TEX=b100 AP=b11, Domain=b0, C=b1, B=b1 */
186 .set    SECT, SECT+0x100000
187
188 .end