2 * flashasm.S: flash magic for LART
4 * Copyright (C) 1999 2000 2001 Jan-Derk bakker (J.D.Bakker@its.tudelft.nl)
6 * This program is free software; you can redistribute it and/or modify
7 * it under the terms of the GNU General Public License as published by
8 * the Free Software Foundation; either version 2 of the License, or
9 * (at your option) any later version.
11 * This program is distributed in the hope that it will be useful,
12 * but WITHOUT ANY WARRANTY; without even the implied warranty of
13 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14 * GNU General Public License for more details.
16 * You should have received a copy of the GNU General Public License
17 * along with this program; if not, write to the Free Software
18 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
26 .globl data_from_flash
27 /* Subroutine that takes data in r0 and formats it so it will be in */
28 /* the correct order for the internal flash */
29 /* used for LART only */
34 orrne r1, r1, #0x00001000
36 orrne r1, r1, #0x00004000
38 orrne r1, r1, #0x00000800
40 orrne r1, r1, #0x00000200
42 orrne r1, r1, #0x00000001
44 orrne r1, r1, #0x00000004
46 orrne r1, r1, #0x00000080
48 orrne r1, r1, #0x00000020
51 orrne r1, r1, #0x00002000
53 orrne r1, r1, #0x00008000
55 orrne r1, r1, #0x00000400
57 orrne r1, r1, #0x00000100
59 orrne r1, r1, #0x00000002
61 orrne r1, r1, #0x00000008
63 orrne r1, r1, #0x00000040
65 orrne r1, r1, #0x00000010
68 orrne r1, r1, #0x00100000
70 orrne r1, r1, #0x00400000
72 orrne r1, r1, #0x00080000
74 orrne r1, r1, #0x00020000
76 orrne r1, r1, #0x01000000
78 orrne r1, r1, #0x04000000
80 orrne r1, r1, #0x80000000
82 orrne r1, r1, #0x20000000
85 orrne r1, r1, #0x00200000
87 orrne r1, r1, #0x00800000
89 orrne r1, r1, #0x00040000
91 orrne r1, r1, #0x00010000
93 orrne r1, r1, #0x02000000
95 orrne r1, r1, #0x08000000
97 orrne r1, r1, #0x40000000
99 orrne r1, r1, #0x10000000
104 /* Takes data received from the flash, and unshuffles it. */
109 orrne r1, r1, #0x00000010
111 orrne r1, r1, #0x00001000
113 orrne r1, r1, #0x00000020
115 orrne r1, r1, #0x00002000
117 orrne r1, r1, #0x00008000
119 orrne r1, r1, #0x00000080
121 orrne r1, r1, #0x00004000
123 orrne r1, r1, #0x00000040
126 orrne r1, r1, #0x00000800
128 orrne r1, r1, #0x00000008
130 orrne r1, r1, #0x00000400
132 orrne r1, r1, #0x00000004
134 orrne r1, r1, #0x00000001
136 orrne r1, r1, #0x00000100
138 orrne r1, r1, #0x00000002
140 orrne r1, r1, #0x00000200
143 orrne r1, r1, #0x08000000
145 orrne r1, r1, #0x00080000
147 orrne r1, r1, #0x04000000
149 orrne r1, r1, #0x00040000
151 orrne r1, r1, #0x00010000
153 orrne r1, r1, #0x01000000
155 orrne r1, r1, #0x00020000
157 orrne r1, r1, #0x02000000
160 orrne r1, r1, #0x00100000
162 orrne r1, r1, #0x10000000
164 orrne r1, r1, #0x00200000
166 orrne r1, r1, #0x20000000
168 orrne r1, r1, #0x80000000
170 orrne r1, r1, #0x00800000
172 orrne r1, r1, #0x40000000
174 orrne r1, r1, #0x00400000