Add CONFIG_GENERATE_* for tables so that the user can select which tables not
[coreboot.git] / src / mainboard / tyan / s2885 / Config.lb
1 ## CONFIG_XIP_ROM_SIZE must be a power of 2.
2 default CONFIG_XIP_ROM_SIZE = 64 * 1024
3 include /config/nofailovercalculation.lb
4
5 arch i386 end 
6
7 ##
8 ## Build the objects we have code for in this directory.
9 ##
10
11 driver mainboard.o
12
13 #dir /drivers/si/3114
14 object get_bus_conf.o
15 if CONFIG_GENERATE_MP_TABLE object mptable.o end
16 if CONFIG_GENERATE_PIRQ_TABLE object irq_tables.o end
17
18 if CONFIG_USE_INIT
19
20 makerule ./auto.o
21         depends "$(CONFIG_MAINBOARD)/cache_as_ram_auto.c option_table.h"
22         action "$(CC) $(DISTRO_CFLAGS) $(CFLAGS) $(CPPFLAGS) -I$(TOP)/src -I. -c $(CONFIG_MAINBOARD)/cache_as_ram_auto.c -o $@"
23 end
24
25 else    
26                 
27 makerule ./auto.inc
28         depends "$(CONFIG_MAINBOARD)/cache_as_ram_auto.c option_table.h"
29         action "$(CC) $(DISTRO_CFLAGS) $(CFLAGS) $(CPPFLAGS) $(DEBUG_CFLAGS) -I$(TOP)/src -I. -c -S $(CONFIG_MAINBOARD)/cache_as_ram_auto.c -o $@"
30         action "perl -e 's/\.rodata/.rom.data/g' -pi $@"
31         action "perl -e 's/\.text/.section .rom.text/g' -pi $@"
32 end
33
34 end
35 ##
36 ## Build our 16 bit and 32 bit coreboot entry code
37 ##
38 if CONFIG_USE_FALLBACK_IMAGE
39         mainboardinit cpu/x86/16bit/entry16.inc
40         ldscript /cpu/x86/16bit/entry16.lds
41 end
42
43 mainboardinit cpu/x86/32bit/entry32.inc
44
45         if CONFIG_USE_INIT
46                 ldscript /cpu/x86/32bit/entry32.lds
47         end
48
49         if CONFIG_USE_INIT
50                 ldscript      /cpu/amd/car/cache_as_ram.lds
51         end
52
53 ##
54 ## Build our reset vector (This is where coreboot is entered)
55 ##
56 if CONFIG_USE_FALLBACK_IMAGE 
57         mainboardinit cpu/x86/16bit/reset16.inc 
58         ldscript /cpu/x86/16bit/reset16.lds 
59 else
60         mainboardinit cpu/x86/32bit/reset32.inc 
61         ldscript /cpu/x86/32bit/reset32.lds 
62 end
63
64 ##
65 ## Include an id string (For safe flashing)
66 ##
67 mainboardinit arch/i386/lib/id.inc
68 ldscript /arch/i386/lib/id.lds
69
70 ##
71 ## Setup Cache-As-Ram
72 ##
73 mainboardinit cpu/amd/car/cache_as_ram.inc
74
75 ###
76 ### This is the early phase of coreboot startup 
77 ### Things are delicate and we test to see if we should
78 ### failover to another image.
79 ###
80 if CONFIG_USE_FALLBACK_IMAGE
81        ldscript /arch/i386/lib/failover.lds
82 end
83
84 ###
85 ### O.k. We aren't just an intermediary anymore!
86 ###
87
88 ##
89 ## Setup RAM
90 ##
91 if CONFIG_USE_INIT
92 initobject auto.o
93 else
94 mainboardinit ./auto.inc
95 end
96
97 ##
98 ## Include the secondary Configuration files 
99 ##
100 config chip.h
101
102 # sample config for tyan/s2885
103 chip northbridge/amd/amdk8/root_complex
104         device apic_cluster 0 on
105                 chip cpu/amd/socket_940
106                         device apic 0 on end
107                 end
108         end
109         device pci_domain 0 on
110                 chip northbridge/amd/amdk8
111                         device pci 18.0 on # LDT0
112                                 chip southbridge/amd/amd8151
113                                         # the on/off keyword is mandatory
114                                         device pci 0.0 on end
115                                         device pci 1.0 on end
116                                 end
117                         end
118                         device pci 18.0 on end # LDT1
119                         device pci 18.0 on #  northbridge 
120                                 #  devices on link 2, link 2 == LDT 2
121                                 chip southbridge/amd/amd8131
122                                         # the on/off keyword is mandatory
123                                         device pci 0.0 on 
124                                                 chip drivers/pci/onboard
125                                                         device pci 9.0 on end # broadcom 5703
126                                                 end
127                                         end
128                                         device pci 0.1 on end
129                                         device pci 1.0 on end
130                                         device pci 1.1 on end
131                                 end
132                                 chip southbridge/amd/amd8111
133                                         # this "device pci 0.0" is the parent the next one
134                                         # PCI bridge
135                                         device pci 0.0 on
136                                                 device pci 0.0 on end
137                                                 device pci 0.1 on end
138                                                 device pci 0.2 off end
139                                                 device pci 1.0 off end
140                                                 chip drivers/pci/onboard
141                                                         device pci b.0 on end # SiI 3114
142                                                 end
143                                         end
144                                         device pci 1.0 on
145                                                 chip superio/winbond/w83627hf
146                                                         device pnp 2e.0 on #  Floppy
147                                                                 io 0x60 = 0x3f0
148                                                                 irq 0x70 = 6
149                                                                 drq 0x74 = 2
150                                                         end
151                                                         device pnp 2e.1 off #  Parallel Port
152                                                                 io 0x60 = 0x378
153                                                                 irq 0x70 = 7
154                                                         end
155                                                         device pnp 2e.2 on #  Com1
156                                                                 io 0x60 = 0x3f8
157                                                                 irq 0x70 = 4
158                                                         end
159                                                         device pnp 2e.3 on #  Com2
160                                                                 io 0x60 = 0x2f8
161                                                                 irq 0x70 = 3
162                                                         end
163                                                         device pnp 2e.5 on #  Keyboard
164                                                                 io 0x60 = 0x60
165                                                                 io 0x62 = 0x64
166                                                                 irq 0x70 = 1
167                                                                 irq 0x72 = 12
168                                                         end
169                                                         device pnp 2e.6 off #  CIR
170                                                                 io 0x60 = 0x100
171                                                         end
172                                                         device pnp 2e.7 off #  GAME_MIDI_GIPO1
173                                                                 io 0x60 = 0x220
174                                                                 io 0x62 = 0x300
175                                                                 irq 0x70 = 9
176                                                         end                                             
177                                                         device pnp 2e.8 off end #  GPIO2
178                                                         device pnp 2e.9 off end #  GPIO3
179                                                         device pnp 2e.a off end #  ACPI
180                                                         device pnp 2e.b on #  HW Monitor
181                                                                 io 0x60 = 0x290
182                                                                 irq 0x70 = 5
183                                                         end
184                                                 end
185                                         end
186                                         device pci 1.1 on end
187                                         device pci 1.2 on end
188                                         device pci 1.3 on
189                                                 chip drivers/generic/generic #dimm 0-0-0
190                                                         device i2c 50 on end
191                                                 end              
192                                                 chip drivers/generic/generic #dimm 0-0-1
193                                                         device i2c 51 on end
194                                                 end     
195                                                 chip drivers/generic/generic #dimm 0-1-0
196                                                         device i2c 52 on end
197                                                 end             
198                                                 chip drivers/generic/generic #dimm 0-1-1
199                                                         device i2c 53 on end
200                                                 end              
201                                                 chip drivers/generic/generic #dimm 1-0-0
202                                                         device i2c 54 on end
203                                                 end     
204                                                 chip drivers/generic/generic #dimm 1-0-1
205                                                         device i2c 55 on end
206                                                 end
207                                                 chip drivers/generic/generic #dimm 1-1-0
208                                                         device i2c 56 on end
209                                                 end     
210                                                 chip drivers/generic/generic #dimm 1-1-1
211                                                         device i2c 57 on end
212                                                 end 
213                                         end # acpi
214                                         device pci 1.5 on end
215                                         device pci 1.6 off end
216                                         register "ide0_enable" = "1"
217                                         register "ide1_enable" = "1"
218                                 end
219                         end #  device pci 18.0 
220                         
221                         device pci 18.1 on end
222                         device pci 18.2 on end
223                         device pci 18.3 on end
224                 end
225
226         end #pci_domain
227
228 #        chip drivers/generic/debug 
229 #                device pnp 0.0 off end
230 #                device pnp 0.1 off end 
231 #                device pnp 0.2 off end
232 #                device pnp 0.3 off end
233 #               device pnp 0.4 off end
234 #               device pnp 0.5 on end
235 #        end
236 end
237