Rev 2901 | Go to most recent revision | Show entire file | Regard whitespace | Details | Blame | Last modification | View Log | RSS feed
Rev 2901 | Rev 2902 | ||
---|---|---|---|
Line 14... | Line 14... | ||
14 | 14 | ||
Line 15... | Line 15... | ||
15 | 15 | ||
16 | format MS COFF |
16 | format MS COFF |
17 | - | ||
Line 18... | Line 17... | ||
18 | DEBUG equ 1 |
17 | |
19 | FAST_WRITE equ 0 |
18 | DEBUG equ 1 |
Line 20... | Line 19... | ||
20 | SIDE_BAND_ADDRESSING equ 0 |
19 | FAST_WRITE equ 0 ; may cause problems with some motherboards |
Line 148... | Line 147... | ||
148 | mov [bus], eax |
147 | mov [bus], eax |
149 | cmp eax, [last_bus] |
148 | cmp eax, [last_bus] |
150 | jna .next_bus |
149 | jna .next_bus |
Line 151... | Line 150... | ||
151 | 150 | ||
152 | .error: |
- | |
153 | if DEBUG |
151 | .error: |
154 | mov esi, msgFail |
152 | mov esi, msgFail |
155 | call SysMsgBoardStr |
- | |
Line 156... | Line 153... | ||
156 | end if |
153 | call SysMsgBoardStr |
157 | 154 | ||
158 | xor eax, eax |
155 | xor eax, eax |
Line 235... | Line 232... | ||
235 | call SysMsgBoardStr |
232 | call SysMsgBoardStr |
Line 236... | Line 233... | ||
236 | 233 | ||
237 | stdcall PciRead32, [bus], [devfn], edi ; read AGP status |
234 | stdcall PciRead32, [bus], [devfn], edi ; read AGP status |
238 | test al, 1 shl 3 |
235 | test al, 1 shl 3 |
- | 236 | jz .agp_2m |
|
239 | jz .agp_2m |
237 | |
240 | test eax, 10b |
238 | test eax, 10b |
241 | jnz .8x |
239 | jnz .8x |
242 | mov [cmd], 01b |
240 | mov [cmd], 01b |
243 | mov esi, msg4 |
241 | mov esi, msg4 |
Line 257... | Line 255... | ||
257 | or [cmd], 1 shl 4 |
255 | or [cmd], 1 shl 4 |
258 | mov esi, msgfast |
256 | mov esi, msgfast |
259 | call SysMsgBoardStr |
257 | call SysMsgBoardStr |
260 | @@: |
258 | @@: |
261 | end if |
259 | end if |
262 | if SIDE_BAND_ADDRESSING |
- | |
- | 260 | ||
263 | test ax, 1 shl 9 |
261 | test ax, 1 shl 9 ; Side band addressing |
264 | jz @f |
262 | jz @f |
265 | or [cmd], 1 shl 9 |
263 | or [cmd], 1 shl 9 |
266 | mov esi, msgside |
264 | mov esi, msgside |
267 | call SysMsgBoardStr |
265 | call SysMsgBoardStr |
268 | @@: |
266 | @@: |
269 | end if |
- | |
270 | add edi, 4 |
- | |
271 | mov eax, [cmd] |
- | |
272 | stdcall PciWrite32, [bus], [devfn], edi, eax ; write AGP cmd |
- | |
Line -... | Line 267... | ||
- | 267 | ||
273 | 268 | add edi, 4 |
|
274 | mov eax, [cmd] |
269 | mov eax, [cmd] |
275 | or eax, 1 shl 8 ; enable AGP |
270 | or eax, 1 shl 8 ; enable AGP |
Line 276... | Line -... | ||
276 | stdcall PciWrite32, [bus], [devfn], edi, eax ; write AGP cmd |
- | |
277 | 271 | stdcall PciWrite32, [bus], [devfn], edi, eax ; write AGP cmd |
|
278 | if DEBUG |
272 | |
279 | mov esi, msgOK |
- | |
Line 280... | Line 273... | ||
280 | call SysMsgBoardStr |
273 | mov esi, msgOK |
Line 281... | Line 274... | ||
281 | end if |
274 | call SysMsgBoardStr |