coreboot
coreboot is an Open Source project aimed at replacing the proprietary BIOS found in most computers.
platform_cfg.h
Go to the documentation of this file.
1
/* SPDX-License-Identifier: GPL-2.0-only */
2
3
#ifndef _PLATFORM_CFG_H_
4
#define _PLATFORM_CFG_H_
5
6
/* APU has no legacy P/S2 controller */
7
#define LEGACY_FREE 0
/* setting legacy free disables I/O access to 0x3F8 */
8
9
/**
10
* @def BIOS_SIZE
11
* BIOS_SIZE_{1,2,4,8,16}M
12
*
13
* In SB800, default ROM size is 1M Bytes, if your platform ROM
14
* bigger than 1M you have to set the ROM size outside CIMx module and
15
* before AGESA module get call.
16
*/
17
#ifndef BIOS_SIZE
18
#define BIOS_SIZE ((CONFIG_COREBOOT_ROMSIZE_KB >> 10) - 1)
19
#endif
/* BIOS_SIZE */
20
21
/**
22
* @def SPREAD_SPECTRUM
23
* @brief
24
* 0 - Disable Spread Spectrum function
25
* 1 - Enable Spread Spectrum function
26
*/
27
#define SPREAD_SPECTRUM 0
28
29
/**
30
* @def SB_HPET_TIMER
31
* @brief
32
* 0 - Disable hpet
33
* 1 - Enable hpet
34
*/
35
#define HPET_TIMER 1
36
37
/**
38
* @def USB_CONFIG
39
* @brief bit[0-6] used to control USB
40
* 0 - Disable
41
* 1 - Enable
42
* Usb Ohci1 Controller (Bus 0 Dev 18 Func0) is defined at BIT0
43
* Usb Ehci1 Controller (Bus 0 Dev 18 Func2) is defined at BIT1
44
* Usb Ohci2 Controller (Bus 0 Dev 19 Func0) is defined at BIT2
45
* Usb Ehci2 Controller (Bus 0 Dev 19 Func2) is defined at BIT3
46
* Usb Ohci3 Controller (Bus 0 Dev 22 Func0) is defined at BIT4
47
* Usb Ehci3 Controller (Bus 0 Dev 22 Func2) is defined at BIT5
48
* Usb Ohci4 Controller (Bus 0 Dev 20 Func5) is defined at BIT6
49
*/
50
#define USB_CONFIG 0x7F
51
52
/**
53
* @def PCI_CLOCK_CTRL
54
* @brief bit[0-4] used for PCI Slots Clock Control,
55
* 0 - disable
56
* 1 - enable
57
* PCI SLOT 0 define at BIT0
58
* PCI SLOT 1 define at BIT1 -> connected to LPC devices
59
* PCI SLOT 2 define at BIT2
60
* PCI SLOT 3 define at BIT3
61
* PCI SLOT 4 define at BIT4
62
*/
63
#define PCI_CLOCK_CTRL 0x02
64
65
/**
66
* @def SATA_CONTROLLER
67
* @brief INCHIP Sata Controller
68
*/
69
#define SATA_CONTROLLER CIMX_OPTION_ENABLED
70
71
/**
72
* @def SATA_MODE
73
* @brief INCHIP Sata Controller Mode
74
* NOTE: DO NOT ALLOW SATA & IDE use same mode
75
*/
76
#define SATA_MODE CONFIG_SB800_SATA_MODE
77
78
/**
79
* @brief INCHIP Sata IDE Controller Mode
80
*/
81
#define IDE_LEGACY_MODE 0
82
#define IDE_NATIVE_MODE 1
83
84
/**
85
* @def SATA_IDE_MODE
86
* @brief INCHIP Sata IDE Controller Mode
87
* NOTE: DO NOT ALLOW SATA & IDE use same mode
88
*/
89
#define SATA_IDE_MODE IDE_LEGACY_MODE
90
91
/**
92
* @def EXTERNAL_CLOCK
93
* @brief 00/10: Reference clock from crystal oscillator via
94
* PAD_XTALI and PAD_XTALO
95
*
96
* @def INTERNAL_CLOCK
97
* @brief 01/11: Reference clock from internal clock through
98
* CP_PLL_REFCLK_P and CP_PLL_REFCLK_N via RDL
99
*/
100
#define EXTERNAL_CLOCK 0x00
101
#define INTERNAL_CLOCK 0x01
102
103
/* NOTE: inagua have to using internal clock,
104
* otherwise can not detect sata drive
105
*/
106
#define SATA_CLOCK_SOURCE INTERNAL_CLOCK
107
108
/**
109
* @def SATA_PORT_MULT_CAP_RESERVED
110
* @brief 1 ON, 0 0FF
111
*/
112
#define SATA_PORT_MULT_CAP_RESERVED 1
113
114
/**
115
* @def AZALIA_AUTO
116
* @brief Detect Azalia controller automatically.
117
*
118
* @def AZALIA_DISABLE
119
* @brief Disable Azalia controller.
120
121
* @def AZALIA_ENABLE
122
* @brief Enable Azalia controller.
123
*/
124
#define AZALIA_AUTO 0
125
#define AZALIA_DISABLE 1
126
#define AZALIA_ENABLE 2
127
128
/**
129
* @brief INCHIP HDA controller
130
*/
131
#define AZALIA_CONTROLLER AZALIA_AUTO
132
133
/**
134
* @def AZALIA_PIN_CONFIG
135
* @brief
136
* 0 - disable
137
* 1 - enable
138
*/
139
#define AZALIA_PIN_CONFIG 1
140
141
/**
142
* @def AZALIA_SDIN_PIN
143
* @brief
144
* SDIN0 is defined at BIT0 & BIT1
145
* 00 - GPIO PIN
146
* 01 - Reserved
147
* 10 - As a Azalia SDIN pin
148
* SDIN1 is defined at BIT2 & BIT3
149
* SDIN2 is defined at BIT4 & BIT5
150
* SDIN3 is defined at BIT6 & BIT7
151
*/
152
//#define AZALIA_SDIN_PIN 0xAA
153
#define AZALIA_SDIN_PIN 0x2A
154
155
/**
156
* @def GPP_CONTROLLER
157
*/
158
#define GPP_CONTROLLER CIMX_OPTION_ENABLED
159
160
/**
161
* @def GPP_CFGMODE
162
* @brief GPP Link Configuration
163
* four possible configuration:
164
* GPP_CFGMODE_X4000
165
* GPP_CFGMODE_X2200
166
* GPP_CFGMODE_X2110
167
* GPP_CFGMODE_X1111
168
*/
169
#define GPP_CFGMODE GPP_CFGMODE_X1111
170
171
/**
172
* @def NB_SB_GEN2
173
* 0 - Disable
174
* 1 - Enable
175
*/
176
#define NB_SB_GEN2 TRUE
177
178
/**
179
* @def SB_GPP_GEN2
180
* 0 - Disable
181
* 1 - Enable
182
*/
183
#define SB_GPP_GEN2 TRUE
184
185
/**
186
* @def SB_GPP_UNHIDE_PORTS
187
* TRUE - ports visible always, even port empty
188
* FALSE - ports invisible if port empty
189
*/
190
#define SB_GPP_UNHIDE_PORTS FALSE
191
192
/**
193
* @def GEC_CONFIG
194
* 0 - Enable
195
* 1 - Disable
196
*/
197
#define GEC_CONFIG 0
198
199
/**
200
* @def USB_RX_MODE
201
* 0x00 - leave Cg2Pll voltage at default value (1.222V)
202
* 0x01 - lower Cg2Pll voltage to 1.1V
203
*
204
* Workaround for reset issues via outb(0x6, 0xcf9).
205
* For details check:
206
* AMD SB800 Family Product Errata,
207
* Section 15. USB Resets Asynchronously With Port CF9h Hard Reset
208
*
209
*/
210
211
#define USB_RX_MODE 0x00
212
213
#endif
/* _PLATFORM_CFG_H_ */
src
mainboard
pcengines
apu1
platform_cfg.h
Generated by
1.9.1