|
|
1.1 root 1: \ *****************************************************************************
2: \ * Copyright (c) 2004, 2008 IBM Corporation
3: \ * All rights reserved.
4: \ * This program and the accompanying materials
5: \ * are made available under the terms of the BSD License
6: \ * which accompanies this distribution, and is available at
7: \ * http://www.opensource.org/licenses/bsd-license.php
8: \ *
9: \ * Contributors:
10: \ * IBM Corporation - initial implementation
11: \ ****************************************************************************/
12:
13: my-space pci-class-name type
14:
15: my-space pci-device-generic-setup
16:
17: my-space pci-class-name device-type
18:
19: \ add legacy I/O Ports / Memory regions to assigned-addresses
20: \ see PCI Bus Binding Revision 2.1 Section 7.
21: s" reg" get-my-property
22: IF
23: \ "reg" does not exist, create new
24: encode-start
25: ELSE
26: \ "reg" does exist, copy it
27: encode-bytes
28: THEN
29: \ I/O Range 0x3B0-0x3BB
30: my-space a1000000 or encode-int+ \ non-relocatable, aliased I/O space
31: 3b0 encode-64+ \ addr
32: c encode-64+ \ size
33: \ I/O Range 0x3C0-0x3DF
34: my-space a1000000 or encode-int+ \ non-relocatable, aliased I/O space
35: 3c0 encode-64+ \ addr
36: 20 encode-64+ \ size
37: \ the U4 does not support memory accesses to this region... so we dont put it into "reg"
38: \ maybe with some clever hacking of the address map registers it will be possible to access
39: \ these regions??
40: \ Memory Range 0xA0000-0xBFFFF
41: \ my-space a2000000 or encode-int+ \ non-relocatable, <1MB Memory space
42: \ a0000 encode-64+ \ addr
43: \ 20000 encode-64+ \ size
44:
45: s" reg" property \ store "reg" property
46:
47: \ check wether we have already found a vga-device (vga-device-node? != 0) and if
48: \ this device has Expansion ROM
49: vga-device-node? 0= 30 config-l@ 0<> AND IF
50: \ remember this vga device's phandle
51: get-node to vga-device-node?
52: THEN
53:
54: cr
55:
This archive runs on limited infrastructure. Preserving old code on modern bandwidth. Automated agents are requested to crawl responsibly.