<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<HTML xmlns:o = "urn:schemas-microsoft-com:office:office" xmlns:st1><HEAD>
<META http-equiv=Content-Type content="text/html; charset=iso-8859-1">
<META content="MSHTML 6.00.2900.2523" name=GENERATOR></HEAD>
<BODY>
<DIV dir=ltr align=left><SPAN class=890412417-24082006><FONT face=Arial 
size=2>John,</FONT></SPAN></DIV>
<DIV dir=ltr align=left><SPAN class=890412417-24082006><FONT face=Arial 
size=2></FONT></SPAN>&nbsp;</DIV>
<DIV dir=ltr align=left><SPAN class=890412417-24082006><FONT face=Arial 
size=2>Normally you have to first open the device node (whose pci config space 
you wish to read).</FONT></SPAN></DIV>
<DIV dir=ltr align=left><SPAN class=890412417-24082006><FONT face=Arial 
size=2>That will give you a non-zero value in my-self, ie. an instance handle of 
the opened node</FONT></SPAN></DIV>
<DIV dir=ltr align=left><SPAN class=890412417-24082006><FONT face=Arial 
size=2>will be created and assigned to my-self.</FONT></SPAN></DIV>
<DIV dir=ltr align=left><SPAN class=890412417-24082006><FONT face=Arial 
size=2>Example on a SPARC system:</FONT></SPAN></DIV>
<DIV dir=ltr align=left><SPAN class=890412417-24082006><FONT face=Arial 
size=2></FONT></SPAN>&nbsp;</DIV>
<DIV dir=ltr align=left><SPAN class=890412417-24082006><FONT size=2><FONT 
face="Courier New">" </FONT><A><FONT 
face="Courier New">/pci@1f,4000/network@2</FONT></A><FONT face="Courier New">" 
begin-select-dev</FONT></FONT></SPAN></DIV>
<DIV dir=ltr align=left><SPAN class=890412417-24082006><FONT face="Courier New" 
size=2>my-space " config-w@" $call-parent .</FONT></SPAN></DIV>
<DIV dir=ltr align=left><SPAN class=890412417-24082006><FONT face=Arial 
size=2></FONT></SPAN>&nbsp;</DIV>
<DIV dir=ltr align=left><SPAN class=890412417-24082006><FONT face=Arial 
size=2>That should print out the contents of the register at offset 0 in config 
space of the <A href="mailto:network@2"><FONT color=#000000>network@2</FONT></A> 
node.</FONT></SPAN></DIV>
<DIV dir=ltr align=left><SPAN class=890412417-24082006><FONT face=Arial 
size=2>But most of the words in the example may not exist in the OpenBios 
implementation.</FONT></SPAN></DIV>
<DIV dir=ltr align=left><SPAN class=890412417-24082006><FONT face=Arial size=2>I 
have been wanting to try out OpenBIOS, but I have'nt been able to get to it 
yet.</FONT></SPAN></DIV>
<DIV dir=ltr align=left><SPAN class=890412417-24082006>
<DIV class=Section1>
<P style="MARGIN: 0in 0in 0pt"><SPAN 
style="FONT-SIZE: 10pt; FONT-FAMILY: 'Courier New'; mso-bidi-font-family: Arial">_____________<o:p></o:p></SPAN></P>
<P style="MARGIN: 0in 0in 0pt"><SPAN 
style="FONT-SIZE: 10pt; FONT-FAMILY: 'Courier New'; mso-bidi-font-family: Tahoma">Äsif 
Haswaréy<o:p></o:p></SPAN></P>
<P style="MARGIN: 0in 0in 0pt"><SPAN 
style="FONT-SIZE: 10pt; FONT-FAMILY: 'Courier New'; mso-bidi-font-family: Tahoma">QLogic 
Corporation<o:p></o:p></SPAN></P>
<P style="MARGIN: 0in 0in 0pt"><st1:Street w:st="on"><st1:address 
style="BACKGROUND-POSITION: left bottom; BACKGROUND-IMAGE: url(res://ietag.dll/#34/#1001); BACKGROUND-REPEAT: repeat-x" 
tabIndex=0 w:st="on"><SPAN 
style="FONT-SIZE: 10pt; FONT-FAMILY: 'Courier New'; mso-bidi-font-family: Tahoma">FCode 
Driver Development</SPAN></st1:address></st1:Street><SPAN 
style="FONT-FAMILY: 'Courier New'; mso-bidi-font-family: 'Times New Roman'"><o:p></o:p></SPAN></P>
<P style="MARGIN: 0in 0in 0pt"><SPAN 
style="FONT-SIZE: 10pt; FONT-FAMILY: 'Courier New'; mso-bidi-font-family: Tahoma">Phone: 
949.389.7607<o:p></o:p></SPAN></P>
<P style="MARGIN: 0in 0in 0pt"><SPAN 
style="FONT-SIZE: 10pt; FONT-FAMILY: 'Courier New'; mso-bidi-font-family: Tahoma">&nbsp; 
Fax: 949.389.6308</SPAN><SPAN 
style="FONT-FAMILY: 'Courier New'; mso-bidi-font-family: 'Times New Roman'"><o:p></o:p></SPAN></P>
<P style="MARGIN: 0in 0in 0pt"><SPAN 
style="FONT-SIZE: 10pt; FONT-FAMILY: 'Courier New'; mso-bidi-font-family: Tahoma"><A 
href="mailto:asif.haswarey@qlogic.com">asif.haswarey@qlogic.com</A></SPAN><SPAN 
style="FONT-FAMILY: 'Courier New'; mso-bidi-font-family: 'Times New Roman'"><o:p></o:p></SPAN></P>
<P style="MARGIN: 0in 0in 0pt"><SPAN 
style="FONT-SIZE: 10pt; FONT-FAMILY: 'Courier New'; mso-bidi-font-family: Tahoma"><o:p>&nbsp;</o:p></SPAN></P></DIV></SPAN></DIV><BR>
<DIV class=OutlookMessageHeader lang=en-us dir=ltr align=left>
<HR tabIndex=-1>
<FONT face=Tahoma size=2><B>From:</B> openbios-bounces@openbios.org 
[mailto:openbios-bounces@openbios.org] <B>On Behalf Of </B>Fusco, John (GE 
Healthcare)<BR><B>Sent:</B> Thursday, August 24, 2006 8:13 AM<BR><B>To:</B> Asif 
Haswarey<BR><B>Cc:</B> openbios@openbios.org<BR><B>Subject:</B> Re: [OpenBIOS] 
Basic Questions<BR></FONT><BR></DIV>
<DIV></DIV>
<DIV dir=ltr align=left><SPAN class=097091814-24082006><FONT face=Arial 
color=#0000ff size=2>I have a console with an "ok" prompt that I boot with grub. 
It's an Intel Westville II motherboard - dual Xeon with 7500 
chipset.</FONT></SPAN></DIV>
<DIV dir=ltr align=left><SPAN class=097091814-24082006><FONT face=Arial 
color=#0000ff size=2></FONT></SPAN>&nbsp;</DIV>
<DIV dir=ltr align=left><SPAN class=097091814-24082006><FONT face=Arial 
color=#0000ff size=2>Here is where I am stuck. The PCI commands that come with 
openbios do not comply with the standard, so they are largely undocumented. 
Looking at the source, I can muddle through although I'm new at Forth. Mabye you 
can help me with the syntax.</FONT></SPAN></DIV>
<DIV dir=ltr align=left><SPAN class=097091814-24082006><FONT face=Arial 
color=#0000ff size=2></FONT></SPAN>&nbsp;</DIV>
<DIV dir=ltr align=left><SPAN class=097091814-24082006><FONT face=Arial 
color=#0000ff size=2>Here is the output from lspci on Linux for 
Westville:</FONT></SPAN></DIV>
<DIV dir=ltr align=left><SPAN class=097091814-24082006><FONT face=Courier 
size=2>&nbsp;&nbsp;&nbsp; $ lspci -n<BR>&nbsp;&nbsp;&nbsp; 00:00.0 0600: 
8086:254c (rev 01)<BR></FONT></SPAN></DIV>
<DIV dir=ltr align=left><SPAN class=097091814-24082006><FONT face=Arial 
size=2>So bus 0 device 0, function 0 has a PCI device. If I read config word 
zero, I expect something like 8086 or 254c, but what I get is always FFFF. Here 
is the syntax I am using:</FONT></SPAN></DIV>
<DIV dir=ltr align=left><SPAN class=097091814-24082006><FONT face=Arial 
size=2></FONT></SPAN>&nbsp;</DIV>
<DIV dir=ltr align=left><SPAN class=097091814-24082006><FONT face="Courier New" 
size=2>0 0 pci-c@ . ff</FONT></SPAN></DIV>
<DIV dir=ltr align=left><SPAN class=097091814-24082006><FONT face="Courier New" 
size=2>0 0 pci-w@ . ffff</FONT></SPAN></DIV>
<DIV dir=ltr align=left><SPAN class=097091814-24082006><FONT face="Courier New" 
size=2>0 0 pci-l@ . -1</FONT></SPAN></DIV>
<DIV dir=ltr align=left><FONT face="Courier New"><SPAN 
class=097091814-24082006><FONT size=2><FONT 
face=Arial></FONT>&nbsp;</DIV></FONT></SPAN></FONT>
<DIV dir=ltr align=left><SPAN class=097091814-24082006><FONT face=Arial 
size=2>What am I doing wrong?</FONT></SPAN></DIV>
<DIV dir=ltr align=left><SPAN class=097091814-24082006><FONT face=Arial 
size=2></FONT></SPAN>&nbsp;</DIV>
<DIV dir=ltr align=left><SPAN class=097091814-24082006><FONT face=Arial 
size=2>Thanks,</FONT></SPAN></DIV>
<DIV dir=ltr align=left><SPAN class=097091814-24082006><FONT face=Arial 
size=2>John</FONT></SPAN></DIV>
<DIV dir=ltr align=left><SPAN class=097091814-24082006><FONT face=Arial 
color=#0000ff size=2></FONT></SPAN>&nbsp;</DIV>
<DIV dir=ltr align=left><SPAN class=097091814-24082006></SPAN>&nbsp;</DIV><BR>
<BLOCKQUOTE dir=ltr 
style="PADDING-LEFT: 5px; MARGIN-LEFT: 5px; BORDER-LEFT: #0000ff 2px solid; MARGIN-RIGHT: 0px">
  <DIV class=OutlookMessageHeader lang=en-us dir=ltr align=left>
  <HR tabIndex=-1>
  <FONT face=Tahoma size=2><B>From:</B> Asif Haswarey 
  [mailto:asif.haswarey@qlogic.com] <BR><B>Sent:</B> Wednesday, August 23, 2006 
  5:24 PM<BR><B>To:</B> Fusco, John (GE Healthcare)<BR><B>Cc:</B> 
  openbios@openbios.org<BR><B>Subject:</B> RE: [OpenBIOS] Basic 
  Questions<BR></FONT><BR></DIV>
  <DIV></DIV>
  <DIV dir=ltr align=left><SPAN class=796552222-23082006><FONT face=Arial 
  color=#0000ff size=2>John,</FONT></SPAN></DIV>
  <DIV dir=ltr align=left><SPAN class=796552222-23082006><FONT face=Arial 
  color=#0000ff size=2></FONT></SPAN>&nbsp;</DIV>
  <DIV dir=ltr align=left><SPAN class=796552222-23082006><FONT face=Arial 
  color=#0000ff size=2>I do not have an environment that you are persuing, ie. 
  Qemu.</FONT></SPAN></DIV>
  <DIV dir=ltr align=left><SPAN class=796552222-23082006><FONT face=Arial 
  color=#0000ff size=2>So you will need to clarify a little 
  more.</FONT></SPAN></DIV>
  <DIV dir=ltr align=left><SPAN class=796552222-23082006><FONT face=Arial 
  color=#0000ff size=2>Do you have a running OpenBIOS system such that you get 
  to the</FONT></SPAN></DIV>
  <DIV dir=ltr align=left><SPAN class=796552222-23082006><FONT face=Arial 
  color=#0000ff size=2>OpenFirmware console specifically at the "ok" 
  prompt?</FONT></SPAN></DIV>
  <DIV dir=ltr align=left><SPAN class=796552222-23082006><FONT face=Arial 
  color=#0000ff size=2></FONT></SPAN>&nbsp;</DIV>
  <DIV dir=ltr align=left><SPAN class=796552222-23082006><FONT face=Arial 
  color=#0000ff size=2>-Asif</FONT></SPAN></DIV><BR>
  <DIV class=OutlookMessageHeader lang=en-us dir=ltr align=left>
  <HR tabIndex=-1>
  <FONT face=Tahoma size=2><B>From:</B> Fusco, John (GE Healthcare) 
  [mailto:John.Fusco@med.ge.com] <BR><B>Sent:</B> Wednesday, August 23, 2006 
  11:02 AM<BR><B>To:</B> Asif Haswarey<BR><B>Cc:</B> 
  openbios@openbios.org<BR><B>Subject:</B> RE: [OpenBIOS] Basic 
  Questions<BR></FONT><BR></DIV>
  <DIV></DIV>
  <DIV dir=ltr align=left><SPAN class=529020018-23082006><FONT face=Arial 
  color=#0000ff size=2>Yes, that's essentially what I want.&nbsp;The runiso 
  target in the makefile uses qemu. So that part was easy.</FONT></SPAN></DIV>
  <DIV dir=ltr align=left><SPAN class=529020018-23082006><FONT face=Arial 
  color=#0000ff size=2></FONT></SPAN>&nbsp;</DIV>
  <DIV dir=ltr align=left><SPAN class=529020018-23082006><FONT face=Arial 
  color=#0000ff size=2>Trying to decipher all the rest of it is where I'm 
  stuck.</FONT></SPAN></DIV>
  <DIV dir=ltr align=left><SPAN class=529020018-23082006><FONT face=Arial 
  color=#0000ff size=2></FONT></SPAN>&nbsp;</DIV>
  <DIV dir=ltr align=left><SPAN class=529020018-23082006><FONT face=Arial 
  color=#0000ff size=2>John</FONT></SPAN></DIV><BR>
  <BLOCKQUOTE dir=ltr 
  style="PADDING-LEFT: 5px; MARGIN-LEFT: 5px; BORDER-LEFT: #0000ff 2px solid; MARGIN-RIGHT: 0px">
    <DIV class=OutlookMessageHeader lang=en-us dir=ltr align=left>
    <HR tabIndex=-1>
    <FONT face=Tahoma size=2><B>From:</B> Asif Haswarey 
    [mailto:asif.haswarey@qlogic.com] <BR><B>Sent:</B> Wednesday, August 23, 
    2006 12:31 PM<BR><B>To:</B> Fusco, John (GE Healthcare)<BR><B>Subject:</B> 
    RE: [OpenBIOS] Basic Questions<BR></FONT><BR></DIV>
    <DIV></DIV>
    <DIV dir=ltr align=left><FONT face=Arial color=#0000ff size=2><SPAN 
    class=937392817-23082006>John,</SPAN></FONT></DIV>
    <DIV dir=ltr align=left><FONT face=Arial color=#0000ff size=2><SPAN 
    class=937392817-23082006></SPAN></FONT>&nbsp;</DIV>
    <DIV dir=ltr align=left><FONT face=Arial color=#0000ff size=2><SPAN 
    class=937392817-23082006>Exercising the PCI config space is probably what 
    you are looking to do.</SPAN></FONT></DIV>
    <DIV dir=ltr align=left><FONT face=Arial color=#0000ff size=2><SPAN 
    class=937392817-23082006>Have you actually been able to install OpenBIOS in 
    your Qemu environment/platform?</SPAN></FONT></DIV>
    <DIV class=Section1>
    <P style="MARGIN: 0in 0in 0pt"><SPAN 
    style="FONT-SIZE: 10pt; FONT-FAMILY: 'Courier New'; mso-bidi-font-family: Arial">_____________<o:p></o:p></SPAN></P>
    <P style="MARGIN: 0in 0in 0pt"><SPAN 
    style="FONT-SIZE: 10pt; FONT-FAMILY: 'Courier New'; mso-bidi-font-family: Tahoma">Äsif 
    Haswaréy<o:p></o:p></SPAN></P>
    <P style="MARGIN: 0in 0in 0pt"><SPAN 
    style="FONT-SIZE: 10pt; FONT-FAMILY: 'Courier New'; mso-bidi-font-family: Tahoma">QLogic 
    Corporation<o:p></o:p></SPAN></P>
    <P style="MARGIN: 0in 0in 0pt"><st1:Street w:st="on"><st1:address 
    style="BACKGROUND-POSITION: left bottom; BACKGROUND-IMAGE: url(res://ietag.dll/#34/#1001); BACKGROUND-REPEAT: repeat-x" 
    tabIndex=0 w:st="on"><SPAN 
    style="FONT-SIZE: 10pt; FONT-FAMILY: 'Courier New'; mso-bidi-font-family: Tahoma">FCode 
    Driver Development</SPAN></st1:address></st1:Street><SPAN 
    style="FONT-FAMILY: 'Courier New'; mso-bidi-font-family: 'Times New Roman'"><o:p></o:p></SPAN></P>
    <P style="MARGIN: 0in 0in 0pt"><SPAN 
    style="FONT-SIZE: 10pt; FONT-FAMILY: 'Courier New'; mso-bidi-font-family: Tahoma">Phone: 
    949.389.7607<o:p></o:p></SPAN></P>
    <P style="MARGIN: 0in 0in 0pt"><SPAN 
    style="FONT-SIZE: 10pt; FONT-FAMILY: 'Courier New'; mso-bidi-font-family: Tahoma">&nbsp; 
    Fax: 949.389.6308</SPAN><SPAN 
    style="FONT-FAMILY: 'Courier New'; mso-bidi-font-family: 'Times New Roman'"><o:p></o:p></SPAN></P>
    <P style="MARGIN: 0in 0in 0pt"><SPAN 
    style="FONT-SIZE: 10pt; FONT-FAMILY: 'Courier New'; mso-bidi-font-family: Tahoma"><A 
    href="mailto:asif.haswarey@qlogic.com">asif.haswarey@qlogic.com</A></SPAN><SPAN 
    style="FONT-FAMILY: 'Courier New'; mso-bidi-font-family: 'Times New Roman'"><o:p></o:p></SPAN></P>
    <P style="MARGIN: 0in 0in 0pt"><SPAN 
    style="FONT-SIZE: 10pt; FONT-FAMILY: 'Courier New'; mso-bidi-font-family: Tahoma"><o:p>&nbsp;</o:p></SPAN></P></DIV><BR>
    <DIV class=OutlookMessageHeader lang=en-us dir=ltr align=left>
    <HR tabIndex=-1>
    <FONT face=Tahoma size=2><B>From:</B> openbios-bounces@openbios.org 
    [mailto:openbios-bounces@openbios.org] <B>On Behalf Of </B>Fusco, John (GE 
    Healthcare)<BR><B>Sent:</B> Wednesday, August 23, 2006 10:12 
    AM<BR><B>To:</B> openbios@openbios.org<BR><B>Subject:</B> [OpenBIOS] Basic 
    Questions<BR></FONT><BR></DIV>
    <DIV></DIV>
    <DIV><SPAN class=273160517-23082006><FONT face=Arial size=2>I am 
    investigating the possiblity of using Openbios as a tool to verify our 
    custom PCI designs.</FONT></SPAN></DIV>
    <DIV><SPAN class=273160517-23082006><FONT face=Arial 
    size=2></FONT></SPAN>&nbsp;</DIV>
    <DIV><SPAN class=273160517-23082006><FONT face=Arial size=2>Specifically 
    what I am interested in is the ability to modify the PCI base address 
    registers and excercise the address decoders on the cards. What I'm after is 
    some basic PCI compliance testing that is hard to do with a full blown 
    OS.</FONT></SPAN></DIV>
    <DIV><SPAN class=273160517-23082006><FONT face=Arial 
    size=2></FONT></SPAN>&nbsp;</DIV>
    <DIV><SPAN class=273160517-23082006><FONT face=Arial size=2>My problem is 
    that I'm having a tough time with the learning curve of openbios. I'm having 
    trouble figuring out how to do some basic things, like query the BARs of a 
    PCI device. I'm using Qemu as a sandbox to play with openbios, but I can't 
    even figure out how print the value of configuration register zero of a 
    particular device!</FONT></SPAN></DIV>
    <DIV><SPAN class=273160517-23082006><FONT face=Arial 
    size=2></FONT></SPAN>&nbsp;</DIV>
    <DIV><SPAN class=273160517-23082006><FONT face=Arial size=2>Can anyone steer 
    me in the right direction? Am I wasting my time, or does it sound like 
    Openbios is going to do what I want.</FONT></SPAN></DIV>
    <DIV><SPAN class=273160517-23082006><FONT face=Arial 
    size=2></FONT></SPAN>&nbsp;</DIV>
    <DIV><SPAN class=273160517-23082006><FONT face=Arial 
    size=2>Thanks,</FONT></SPAN></DIV>
    <DIV><SPAN class=273160517-23082006><FONT face=Arial 
    size=2>John</FONT></SPAN></DIV></BLOCKQUOTE></BLOCKQUOTE></BODY></HTML>