blob: 3e9a87eb77f037a5c38201d6eafbbba0e53c9de3 [file] [log] [blame]
Yinghai Lu13f1c2a2005-07-08 02:49:49 +00001##
2## Only use the option table in a normal image
3##
Stefan Reinauer08670622009-06-30 15:17:49 +00004default CONFIG_USE_OPTION_TABLE = !CONFIG_USE_FALLBACK_IMAGE
Yinghai Lu13f1c2a2005-07-08 02:49:49 +00005
Stefan Reinauer08670622009-06-30 15:17:49 +00006## CONFIG_XIP_ROM_SIZE must be a power of 2.
Patrick Georgib339e102009-08-11 17:35:02 +00007default CONFIG_XIP_ROM_SIZE = 64 * 1024
Carl-Daniel Hailfingercff071a2009-06-06 16:50:38 +00008include /config/nofailovercalculation.lb
Yinghai Lu13f1c2a2005-07-08 02:49:49 +00009
10##
11## Set all of the defaults for an x86 architecture
12##
13
14arch i386 end
15
16##
17## Build the objects we have code for in this directory.
18##
19
20driver mainboard.o
Stefan Reinauer08670622009-06-30 15:17:49 +000021if CONFIG_HAVE_MP_TABLE object mptable.o end
22if CONFIG_HAVE_PIRQ_TABLE object irq_tables.o end
Yinghai Lu13f1c2a2005-07-08 02:49:49 +000023object reset.o
24
25##
26## Romcc output
27##
28makerule ./failover.E
Stefan Reinauer08670622009-06-30 15:17:49 +000029 depends "$(CONFIG_MAINBOARD)/failover.c ../romcc"
30 action "../romcc -E -O --label-prefix=failover -I$(TOP)/src -I. $(CPPFLAGS) $(CONFIG_MAINBOARD)/failover.c -o $@"
Yinghai Lu13f1c2a2005-07-08 02:49:49 +000031end
32
33makerule ./failover.inc
Stefan Reinauer08670622009-06-30 15:17:49 +000034 depends "$(CONFIG_MAINBOARD)/failover.c ../romcc"
35 action "../romcc -O --label-prefix=failover -I$(TOP)/src -I. $(CPPFLAGS) $(CONFIG_MAINBOARD)/failover.c -o $@"
Yinghai Lu13f1c2a2005-07-08 02:49:49 +000036end
37
38makerule ./auto.E
Stefan Reinauer08670622009-06-30 15:17:49 +000039 depends "$(CONFIG_MAINBOARD)/auto.c option_table.h ../romcc"
40 action "../romcc -E -mcpu=p4 -O2 -I$(TOP)/src -I. $(CPPFLAGS) $(CONFIG_MAINBOARD)/auto.c -o $@"
Yinghai Lu13f1c2a2005-07-08 02:49:49 +000041end
42makerule ./auto.inc
Stefan Reinauer08670622009-06-30 15:17:49 +000043 depends "$(CONFIG_MAINBOARD)/auto.c option_table.h ../romcc"
44 action "../romcc -mcpu=p4 -O2 -I$(TOP)/src -I. $(CPPFLAGS) $(CONFIG_MAINBOARD)/auto.c -o $@"
Yinghai Lu13f1c2a2005-07-08 02:49:49 +000045end
46
47##
Stefan Reinauerf8ee1802008-01-18 15:08:58 +000048## Build our 16 bit and 32 bit coreboot entry code
Yinghai Lu13f1c2a2005-07-08 02:49:49 +000049##
50mainboardinit cpu/x86/16bit/entry16.inc
51mainboardinit cpu/x86/32bit/entry32.inc
52ldscript /cpu/x86/16bit/entry16.lds
53ldscript /cpu/x86/32bit/entry32.lds
54
55##
Stefan Reinauerf8ee1802008-01-18 15:08:58 +000056## Build our reset vector (This is where coreboot is entered)
Yinghai Lu13f1c2a2005-07-08 02:49:49 +000057##
Stefan Reinauer08670622009-06-30 15:17:49 +000058if CONFIG_USE_FALLBACK_IMAGE
Yinghai Lu13f1c2a2005-07-08 02:49:49 +000059 mainboardinit cpu/x86/16bit/reset16.inc
60 ldscript /cpu/x86/16bit/reset16.lds
61else
62 mainboardinit cpu/x86/32bit/reset32.inc
63 ldscript /cpu/x86/32bit/reset32.lds
64end
65
66### Should this be in the northbridge code?
67mainboardinit arch/i386/lib/cpu_reset.inc
68
69##
70## Include an id string (For safe flashing)
71##
72mainboardinit arch/i386/lib/id.inc
73ldscript /arch/i386/lib/id.lds
74
75###
Stefan Reinauerf8ee1802008-01-18 15:08:58 +000076### This is the early phase of coreboot startup
Yinghai Lu13f1c2a2005-07-08 02:49:49 +000077### Things are delicate and we test to see if we should
78### failover to another image.
79###
Stefan Reinauer08670622009-06-30 15:17:49 +000080if CONFIG_USE_FALLBACK_IMAGE
Yinghai Lu13f1c2a2005-07-08 02:49:49 +000081 ldscript /arch/i386/lib/failover.lds
82 mainboardinit ./failover.inc
83end
84
85###
86### O.k. We aren't just an intermediary anymore!
87###
88
89##
90## Setup RAM
91##
92mainboardinit cpu/x86/fpu/enable_fpu.inc
93mainboardinit cpu/x86/mmx/enable_mmx.inc
94mainboardinit cpu/x86/sse/enable_sse.inc
95mainboardinit ./auto.inc
96mainboardinit cpu/x86/sse/disable_sse.inc
97mainboardinit cpu/x86/mmx/disable_mmx.inc
98
99##
100## Include the secondary Configuration files
101##
102dir /pc80
103config chip.h
104
Uwe Hermann586470c2006-10-27 11:38:22 +0000105chip northbridge/intel/e7525 # mch
Yinghai Lu13f1c2a2005-07-08 02:49:49 +0000106 device pci_domain 0 on
107 chip southbridge/intel/esb6300 # esb6300
108 register "pirq_a_d" = "0x0b0a0a05"
109 register "pirq_e_h" = "0x0a0b0c80"
110
111 device pci 1c.0 on end
112
113 device pci 1d.0 on end
114 device pci 1d.1 on end
115 device pci 1d.4 on end
116 device pci 1d.5 on end
117 device pci 1d.7 on end
118
119 device pci 1e.0 on end
120
121 device pci 1f.0 on
122 chip superio/winbond/w83627hf
123 device pnp 2e.0 off end
124 device pnp 2e.1 off end
125 device pnp 2e.2 on
126 io 0x60 = 0x3f8
127 irq 0x70 = 4
128 end
129 device pnp 2e.3 on
130 io 0x60 = 0x2f8
131 irq 0x70 = 3
132 end
133 device pnp 2e.4 off end
134 device pnp 2e.5 off end
135 device pnp 2e.6 off end
136 device pnp 2e.7 off end
137 device pnp 2e.9 off end
138 device pnp 2e.a on end
139 device pnp 2e.b off end
140 device pnp 2e.f off end
141 device pnp 2e.10 off end
142 device pnp 2e.14 off end
143 end
144 end
145 device pci 1f.1 on end
146 device pci 1f.2 on end
147 device pci 1f.3 on end
148 device pci 1f.5 off end
149 device pci 1f.6 on end
150 end
151 device pci 00.0 on end
152 device pci 00.1 on end
153 device pci 00.2 on end
154 device pci 02.0 on end
155 device pci 03.0 on end
156 device pci 04.0 on end
157 device pci 08.0 on end
158 end
159 device apic_cluster 0 on
Stefan Reinauer953253f2009-04-22 08:56:50 +0000160 chip cpu/intel/socket_mPGA604 # cpu0
Yinghai Lu13f1c2a2005-07-08 02:49:49 +0000161 device apic 0 on end
162 end
Stefan Reinauer953253f2009-04-22 08:56:50 +0000163 chip cpu/intel/socket_mPGA604 # cpu1
Yinghai Lu13f1c2a2005-07-08 02:49:49 +0000164 device apic 6 on end
165 end
166 end
167end
168