Commit | Line | Data |
---|---|---|
86530b38 AT |
1 | /* |
2 | * ========== Copyright Header Begin ========================================== | |
3 | * | |
4 | * OpenSPARC T2 Processor File: spc_flush0.s | |
5 | * Copyright (C) 1995-2007 Sun Microsystems, Inc. All Rights Reserved | |
6 | * 4150 Network Circle, Santa Clara, California 95054, U.S.A. | |
7 | * | |
8 | * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. | |
9 | * | |
10 | * This program is free software; you can redistribute it and/or modify | |
11 | * it under the terms of the GNU General Public License as published by | |
12 | * the Free Software Foundation; version 2 of the License. | |
13 | * | |
14 | * This program is distributed in the hope that it will be useful, | |
15 | * but WITHOUT ANY WARRANTY; without even the implied warranty of | |
16 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | |
17 | * GNU General Public License for more details. | |
18 | * | |
19 | * You should have received a copy of the GNU General Public License | |
20 | * along with this program; if not, write to the Free Software | |
21 | * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA | |
22 | * | |
23 | * For the avoidance of doubt, and except that if any non-GPL license | |
24 | * choice is available it will apply instead, Sun elects to use only | |
25 | * the General Public License version 2 (GPLv2) at this time for any | |
26 | * software where a choice of GPL license versions is made | |
27 | * available with the language indicating that GPLv2 or any later version | |
28 | * may be used, or where a choice of which version of the GPL is applied is | |
29 | * otherwise unspecified. | |
30 | * | |
31 | * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara, | |
32 | * CA 95054 USA or visit www.sun.com if you need additional information or | |
33 | * have any questions. | |
34 | * | |
35 | * | |
36 | * ========== Copyright Header End ============================================ | |
37 | */ | |
38 | #include "defines.h" | |
39 | #include "old_boot.s" | |
40 | ||
41 | .text | |
42 | .global main | |
43 | ||
44 | main: | |
45 | /* | |
46 | ***************************************** | |
47 | * Initialize all the registers | |
48 | ***************************************** | |
49 | */ | |
50 | set 0x3009b3e4, %l0 | |
51 | set 0x957f43e9, %l1 | |
52 | set 0xeef55c5d, %l2 | |
53 | set 0xf29039ca, %l3 | |
54 | set 0x926f8329, %l4 | |
55 | set 0x3d6172cd, %l5 | |
56 | set 0xcb84ab9b, %l6 | |
57 | set 0xe92be485, %l7 | |
58 | set 0xc04c977d, %i0 | |
59 | set 0x6492e2d0, %i1 | |
60 | set 0xbe33ddd8, %i2 | |
61 | set 0xd0fb061f, %i3 | |
62 | set 0xaa1a6a9f, %i4 | |
63 | set 0x17492ca0, %i5 | |
64 | set 0x9abec99c, %i6 | |
65 | set 0x48c19ef4, %i7 | |
66 | set 0x4478dc0f, %o0 | |
67 | set 0xc4d9756a, %o1 | |
68 | set 0x4392b7d9, %o2 | |
69 | set 0xde4928d2, %o3 | |
70 | set 0xf8ffc02c, %o4 | |
71 | set 0xcdee525b, %o5 | |
72 | set 0xd6d8db1b, %o6 | |
73 | set 0x9ede1023, %o7 | |
74 | set 0x1, %g1 | |
75 | ||
76 | tc_0: | |
77 | add %l0, %l1, %i0 | |
78 | add %l2, %l3, %i1 | |
79 | add %l4, %l5, %i2 | |
80 | add %l6, %l7, %i3 | |
81 | ||
82 | brnz %g1, tc_1 | |
83 | nop | |
84 | ||
85 | setx tc_1, %l0, %l1 | |
86 | set 0xa0060019, %i4 | |
87 | set 0xa206801b, %i5 | |
88 | set 0xa406001a, %i6 | |
89 | set 0xa606401b, %i7 | |
90 | st %i4, [%l1] | |
91 | add %l1, 0x4, %l1 | |
92 | st %i5, [%l1] | |
93 | add %l1, 0x4, %l1 | |
94 | st %i6, [%l1] | |
95 | add %l1, 0x4, %l1 | |
96 | st %i7, [%l1] | |
97 | flush %l1 | |
98 | tc_1: | |
99 | add %i0, %i2, %l0 | |
100 | add %i1, %i3, %l1 | |
101 | add %i0, %i1, %l2 | |
102 | add %i2, %i3, %l3 | |
103 | ||
104 | brnz %g1, tc_0 | |
105 | sub %g1, 1, %g1 | |
106 | ||
107 | EXIT_GOOD | |
108 | ||
109 | .data | |
110 | .xword 0123456789abcdef | |
111 | .end | |
112 |