<html><head><meta http-equiv="Content-Type" content="text/html; charset=utf-8"></head><body style="word-wrap: break-word; -webkit-nbsp-mode: space; line-break: after-white-space;" class=""><br class=""><div><br class=""><blockquote type="cite" class=""><div class="">On Dec 18, 2017, at 12:20 AM, Tarl Neustaedter <<a href="mailto:tarl-b2@tarl.net" class="">tarl-b2@tarl.net</a>> wrote:</div><br class="Apple-interchange-newline"><div class=""><div class="">On 2017-Dec-18 00:05 , Jd Lyons wrote:<br class="">[...]<br class=""><blockquote type="cite" class="">0 > dev /pci  ok<br class="">0 > dev @10  ok<br class="">0 > words close open <br class=""> ok<br class="">0 > " /pci/pci10de,141@10" open-dev  ok<br class="">1 > load hd:,\ppc\6600.fcode  ok<br class="">1 > 4000040 1 byte-load open isn't unique.<br class="">close isn't unique.<br class=""><br class="">byte-load: exception caught!<br class=""></blockquote><br class="">Well, the good news is that you're getting far enough into the fcode<br class="">that it is clearly creating the open and close words (the complaint that<br class="">they aren't unique means something is overwriting them).<br class=""><br class="">So we know it's happy with what it's been able to read from the card and<br class="">it's been creating properties.<br class=""><br class="">Unfortunately, now it's going to be a matter of trying to debug the<br class="">nvidia fcode to figure out what's blowing up. All we know is that<br class="">byte-load is getting an exception, and that almost certainly means the<br class="">FCode did something to cause a throw.<br class=""><br class=""><br class=""></div></div></blockquote><div><br class=""></div><div>I maybe off base here, just taking a shot in the dark, the place where it catching the exception seems to point to 0xe34, that pretty close to the map-in function in the Rom. Just after the assigned address function.</div><div><br class=""></div><div>Old World Mac’s had a bug in the map-in function, and both nVidia/ATI FCode Option Roms include a workaround for it.</div><div><br class=""></div><div>So, and I’m just guessing here, it maybe the map-in workaround that we’re tripping over?</div><div><br class=""></div><div>
                
        
        
                <div class="page" title="Page 28">
                        <div class="layoutArea">
                                <div class="column"><p class=""><span style="font-size: 12.000000pt; font-family: 'Times'; font-weight: 700" class="">13. Example of use of add-ranges check
</span></p><p class=""><span style="font-size: 9.000000pt; font-family: 'Courier'" class="">\ Flag is true if the parent's map-in method doesn't work with
\ relocatable addresses.
</span></p><p class=""><span style="font-size: 9.000000pt; font-family: 'Courier'" class="">: map-in-broken? ( -- flag )<br class="">
\ Look for the method that is present when the bug is present
</span></p>
                                </div>
                        </div>
                        <div class="layoutArea">
                                <div class="column"><p class=""><span style="font-size: 9.000000pt; font-family: 'Courier'" class="">;
</span></p>
                                </div>
                        </div>
                        <div class="layoutArea">
                                <div class="column"><p class=""><span style="font-size: 9.000000pt; font-family: 'Courier'" class="">;
</span></p>
                                </div>
                        </div>
                        <div class="layoutArea">
                                <div class="column"><p class=""><span style="font-size: 9.000000pt; font-family: 'Courier'" class="">" add-range" my-parent ihandle>phandle
find-method dup if nip then
</span></p>
                                </div>
                                <div class="column"><p class=""><span style="font-size: 9.000000pt; font-family: 'Courier'" class="">( adr len phandle )<br class="">
( flag ) \ Discard xt if present
</span></p>
                                </div>
                        </div>
                        <div class="layoutArea">
                                <div class="column"><p class=""><span style="font-size: 9.000000pt; font-family: 'Courier'" class="">\ Return phys.lo and phys.mid of the address assigned to the PCI base address
\ register indicated by phys.hi .
</span></p><p class=""><span style="font-size: 9.000000pt; font-family: 'Courier'" class="">: get-base-address ( phys.hi -- phys.lo phys.mid phys.hi )
</span></p>
                                </div>
                        </div>
                        <div class="layoutArea">
                                <div class="column"><p class=""><span style="font-size: 9.000000pt; font-family: 'Courier'" class="">" assigned-addresses" get-my-property if
." No address property found!" cr<br class="">
0 0 rot exit
</span></p><p class=""><span style="font-size: 9.000000pt; font-family: 'Courier'" class="">then
</span></p><p class=""><span style="font-size: 9.000000pt; font-family: 'Courier'" class="">rot>r<br class="">
\ Found assigned-addresses, get address<br class="">
begin dup while ( adr len' ) \ Loop over entries
</span></p><p class=""><span style="font-size: 9.000000pt; font-family: 'Courier'" class="">decode-phys ( adr len' phys.lo phys.mid phys.hi )<br class="">
h# ff and r@ h# ff and = if ( adr len' phys.lo phys.mid ) \ This one?
</span></p>
                                </div>
                        </div>
                        <div class="layoutArea">
                                <div class="column"><p class=""><span style="font-size: 9.000000pt; font-family: 'Courier'" class="">2swap 2drop
</span></p><p class=""><span style="font-size: 9.000000pt; font-family: 'Courier'" class="">r> exit
else
</span></p><p class=""><span style="font-size: 9.000000pt; font-family: 'Courier'" class="">repeat<br class="">
2drop ()
</span></p><p class=""><span style="font-size: 9.000000pt; font-family: 'Courier'" class="">." Base address not assigned!" cr<br class="">
0 0 r> ( 0 0 phys.hi )
</span></p>
                                </div>
                        </div>
                        <div class="layoutArea">
                                <div class="column"><p class=""><span style="font-size: 9.000000pt; font-family: 'Courier'" class="">2drop
then
</span></p>
                                </div>
                                <div class="column"><p class=""><span style="font-size: 9.000000pt; font-family: 'Courier'" class="">( phys.lo phys.mid ) \ This is the one
( phys.lo phys.mid phys.hi )<br class="">
( adr len' phys.lo phys.mid ) \ Not this one
(adrlen')
</span></p>
                                </div>
                        </div>
                        <div class="layoutArea">
                                <div class="column"><p class=""><span style="font-size: 9.000000pt; font-family: 'Courier'" class="">(adrlen')
decode-int drop decode-int drop
</span></p>
                                </div>
                                <div class="column"><p class=""><span style="font-size: 9.000000pt; font-family: 'Courier'" class="">\ Discard boring fields
</span></p>
                                </div>
                        </div>
                        <div class="layoutArea">
                                <div class="column"><p class=""><span style="font-size: 9.000000pt; font-family: 'Courier'" class="">\ Error exit
( phys.hi adr len )
</span></p>
                                </div>
                        </div>
                        <div class="layoutArea">
                                <div class="column"><p class=""><span style="font-size: 9.000000pt; font-family: 'Courier'" class="">(adrlen) (r:phys.hi)
</span></p>
                                </div>
                        </div>
                        <div class="layoutArea">
                                <div class="column"><p class=""><span style="font-size: 9.000000pt; font-family: 'Courier'" class="">\ Example code to compute the phys.lo..hi arguments for "map-in", using the
\ above functions so that the code works both on systems that implement<br class="">
\ map-in according to the PCI binding document, and also on systems whose
\ PCI map-in method requires phys.lo,phys.mid to contain the assigned base
\ address.
</span></p><p class=""><span style="font-size: 9.000000pt; font-family: 'Courier'" class="">\ Compute entire phys.lo..hi address for base address register 10
map-in-broken? if
</span></p>
                                </div>
                        </div>
                        <div class="layoutArea">
                                <div class="column"><p class=""><span style="font-size: 9.000000pt; font-family: 'Courier'" class="">my-space h# 8200.0010 + get-base-address
else
</span></p><p class=""><span style="font-size: 9.000000pt; font-family: 'Courier'" class="">0 0 my-space h# 200.0010 +
then
</span></p>
                                </div>
                                <div class="column"><p class=""><span style="font-size: 9.000000pt; font-family: 'Courier'" class="">( phys.lo,mid,hi )
</span></p><p class=""><span style="font-size: 9.000000pt; font-family: 'Courier'" class="">( phys.lo,mid,hi )
( phys.lo,mid,hi )
</span></p>
                                </div>
                        </div>
                        <div class="layoutArea">
                                <div class="column"><p class=""><span style="font-size: 9.000000pt; font-family: 'Courier'" class="">\ An FCode driver that need not work on systems with the map-in bug could
\ use the following code, omitting the definitions of "map-in-broken?"<br class="">
\ and "get-base-address".<br class="">
\
</span></p>
                                </div>
                        </div>
                        <div class="layoutArea">
                                <div class="column"><p class=""><span style="font-size: 9.000000pt; font-family: 'Courier'" class="">\ 0 0 my-space h# 200.0010 +
</span></p>
                                </div>
                                <div class="column"><p class=""><span style="font-size: 9.000000pt; font-family: 'Courier'" class="">( phys.lo,mid,hi ) </span></p>
                                </div>
                        </div>
                </div></div><blockquote type="cite" class=""><div class=""><div class="">-- <br class="">OpenBIOS                 <a href="http://openbios.org/" class="">http://openbios.org/</a><br class="">Mailinglist:  <a href="http://lists.openbios.org/mailman/listinfo" class="">http://lists.openbios.org/mailman/listinfo</a><br class="">Free your System - May the Forth be with you<br class=""></div></div></blockquote></div><br class=""></body></html>