X-MimeOLE: Produced By Microsoft Exchange V6.5
Received: by onstor-exch02.onstor.net 
	id <01C824DD.B0D31A29@onstor-exch02.onstor.net>; Sun, 11 Nov 2007 19:39:55 -0800
MIME-Version: 1.0
Content-Type: multipart/alternative;
	boundary="----_=_NextPart_001_01C824DD.B0D31A29"
References: <BB375AF679D4A34E9CA8DFA650E2B04E0103C4D8@onstor-exch02.onstor.net><20071109182736.36098c23@ripper.onstor.net><BB375AF679D4A34E9CA8DFA650E2B04E523472@onstor-exch02.onstor.net> <20071111155502.0c01c79b@ripper.onstor.net>
Content-class: urn:content-classes:message
Subject: RE: prom changes
Date: Sun, 11 Nov 2007 19:39:55 -0800
Message-ID: <BB375AF679D4A34E9CA8DFA650E2B04E523475@onstor-exch02.onstor.net>
X-MS-Has-Attach: 
X-MS-TNEF-Correlator: 
Thread-Topic: prom changes
Thread-Index: AcgkvkchmZYTnYDYTxaKlxfPfhBTzQAHl4B8
From: "Brian Stark" <brian.stark@onstor.com>
To: "Andy Sharp" <andy.sharp@onstor.com>
Cc: "Rick Lund" <rick.lund@onstor.com>

This is a multi-part message in MIME format.

------_=_NextPart_001_01C824DD.B0D31A29
Content-Type: text/plain;
	charset="iso-8859-1"
Content-Transfer-Encoding: quoted-printable

The SiByte register where the MAC address can be stored is 0xb006.4208 =
for port 0 and 0xb006.5208 for port 1.  Right now, the PROM isn't =
touching them at all and the mechanism of passing in the MAC address to =
Linux as an env variable isn't enabled either, so I have no idea how =
Linux is getting a MAC address.  I thought it might be the default value =
in the SiByte MAC address register, but clearly it's not.
=20
We can do a simple test of programming the MAC address register to an =
ONStor address (000734...), and then see if Linux is picking it up.  We =
can do this when the Cougars from Pleasanton are set up in Campbell.
=20
=20
Brian
=20

________________________________

From: Andy Sharp
Sent: Sun 11/11/2007 3:55 PM
To: Brian Stark
Cc: Rick Lund
Subject: Re: prom changes



Hi Brian  ~:^)

I'm not sure what register you are talking about, but I'm talking
about the nvram on the Sibyte that is for storing the mac address.  It
makes all the sense in the world that the Linux driver is looking for
the mac address there.  I sincerely doubt that the driver is making
one up out of thin air, although I guess stranger things have been
known to happen.  However you and I had this discussion several weeks
ago and at that time you seemed to recognise where that number was
coming from ... something about old TXRX PROM code or something.

For the sake of simplicity, I think the PROM code should program the
mac address from the SEEP into the Sibyte nvram unless the Sibyte
nvram has a reasonable looking mac address in it already.  Although
perhaps it should do it anytime the two differ, as possibly it can be
changed on the Sibyte from the Linux 'ifconfig' command, and I don't
believe our application software would like that.

Cheers,

a

On Sun, 11 Nov 2007 08:57:17 -0800 "Brian Stark"
<brian.stark@onstor.com> wrote:

> Here's the MAC address that's present in that register while in PROM:
>=20
> Mac ethernet addr                 :00000100000c28001
>=20
> So either Linux is resetting the MAC address register from the one
> shown in your email or it's inserting the MAC on every packet that's
> being sent.  If it's the latter, then it's probably defaulting to
> that address since we're not passing it in from PROM.
>
> ________________________________
>
> From: Andy Sharp
> Sent: Fri 11/9/2007 6:27 PM
> To: Brian Stark
> Cc: Rick Lund
> Subject: Re: prom changes
>
>
>
> My comments were written with full understanding of that.  The short
> version: set the value in the MAC and Linux will take care of the
> rest.
>
> Currently on the cougarz, the mac addr comes out like thus:
>
> coolcat:~# ifconfig
> eth0      Link encap:Ethernet  HWaddr 40:00:00:00:01:00
>
> Which I believe is what's sitting in the MAC when the linux driver
> gets to it.
>
> On Fri, 9 Nov 2007 18:09:05 -0800 "Brian Stark"
> <brian.stark@onstor.com> wrote:
>
> > It's not as simple as setting the mac addr register.  The transmit
> > descriptor needs to tell the ethernet engine to use the value in
> > this register.  Setting this bit in the descriptor has to be done
> > in the driver, both the one in prom and linux...
> >
> >
> >
> >
> >
> > -----Original Message-----
> > From: Andy Sharp
> > To: Brian Stark
> > CC: Rick Lund
> > Sent: Fri Nov 09 17:56:23 2007
> > Subject: Re: prom changes
> >
> > On Fri, 9 Nov 2007 17:38:41 -0800 "Brian Stark"
> > <brian.stark@onstor.com> wrote:
> >
> > > FYI, if we want to use the mac addr programmed into the SiByte
> > > MAC, then the transmit descriptor needs to be modified to replace
> > > the source address inserted by the DMA engine.  Right now in
> > > PROM, we rely on the networking code to use the address from the
> > > SEEP.
> > >
> > > Andy, do you know how the driver is working in Linux?  Does it
> > > setup the MAC address for each packet or does it set the bit in
> > > the descriptor to use the register value?
> >
> > It gets it from the MAC.  What it does after that, I don't know, but
> > that's the important part.  If I were going to implement the code to
> > use the seep, I would just take the value in the seep and write it
> > into the MAC, the end.  Might make your PROM networking code go a
> > lot faster to do the same?  Just a thought.
> >
> > >
> > > Brian
> > >
> > >
> > > > -----Original Message-----
> > > > From: Andy Sharp
> > > > Sent: Monday, October 29, 2007 4:35 PM
> > > > To: Brian Stark; Rick Lund
> > > > Subject: prom changes
> > > >
> > > > Hello Boyeeeeez,
> > > >
> > > > Just dropping a note to remind of the prom changes:
> > > >
> > > > * Map the RTC space in.
> > > >
> > > > * One of the following: program the mac addr into the
> > > > ethernet controller or get the argument/environment stuff
> > > > working.  Preferably the former.  Because the latter might
> > > > actually be a kernel issue.
> > > >
> > > > Cheers,
> > > >
> > > > a
> > > >
>
>



------_=_NextPart_001_01C824DD.B0D31A29
Content-Type: text/html;
	charset="iso-8859-1"
Content-Transfer-Encoding: quoted-printable

<HTML dir=3Dltr><HEAD><TITLE>Re: prom changes</TITLE>=0A=
<META http-equiv=3DContent-Type content=3D"text/html; charset=3Dunicode">=0A=
<META content=3D"MSHTML 6.00.6000.16525" name=3DGENERATOR></HEAD>=0A=
<BODY>=0A=
<DIV id=3DidOWAReplyText62911 dir=3Dltr>=0A=
<DIV dir=3Dltr><FONT face=3DArial color=3D#000000 size=3D2>The SiByte =
register where the MAC address can be stored is 0xb006.4208 for port 0 =
and 0xb006.5208 for port 1.&nbsp; Right now, the PROM isn't touching =
them at all and the mechanism of passing in the MAC address to Linux as =
an env variable isn't enabled either, so I have no idea how Linux is =
getting a MAC address.&nbsp; I thought it might be the default value in =
the SiByte MAC address register, but clearly it's not.</FONT></DIV>=0A=
<DIV dir=3Dltr><FONT face=3DArial size=3D2></FONT>&nbsp;</DIV>=0A=
<DIV dir=3Dltr><FONT face=3DArial size=3D2>We can do a simple test of =
programming the MAC address register to an ONStor address (000734...), =
and then see if Linux is picking it up.&nbsp; We can do this when the =
Cougars from Pleasanton are set up in Campbell.</FONT></DIV>=0A=
<DIV dir=3Dltr><FONT face=3DArial size=3D2></FONT>&nbsp;</DIV>=0A=
<DIV dir=3Dltr><FONT face=3DArial size=3D2></FONT>&nbsp;</DIV>=0A=
<DIV dir=3Dltr><FONT face=3DArial size=3D2>Brian</FONT></DIV>=0A=
<DIV dir=3Dltr><FONT face=3DArial size=3D2></FONT>&nbsp;</DIV></DIV>=0A=
<DIV dir=3Dltr><BR>=0A=
<HR tabIndex=3D-1>=0A=
<FONT face=3DTahoma size=3D2><B>From:</B> Andy Sharp<BR><B>Sent:</B> Sun =
11/11/2007 3:55 PM<BR><B>To:</B> Brian Stark<BR><B>Cc:</B> Rick =
Lund<BR><B>Subject:</B> Re: prom changes<BR></FONT><BR></DIV>=0A=
<DIV>=0A=
<P><FONT size=3D2>Hi Brian&nbsp; ~:^)<BR><BR>I'm not sure what register =
you are talking about, but I'm talking<BR>about the nvram on the Sibyte =
that is for storing the mac address.&nbsp; It<BR>makes all the sense in =
the world that the Linux driver is looking for<BR>the mac address =
there.&nbsp; I sincerely doubt that the driver is making<BR>one up out =
of thin air, although I guess stranger things have been<BR>known to =
happen.&nbsp; However you and I had this discussion several weeks<BR>ago =
and at that time you seemed to recognise where that number was<BR>coming =
from ... something about old TXRX PROM code or something.<BR><BR>For the =
sake of simplicity, I think the PROM code should program the<BR>mac =
address from the SEEP into the Sibyte nvram unless the Sibyte<BR>nvram =
has a reasonable looking mac address in it already.&nbsp; =
Although<BR>perhaps it should do it anytime the two differ, as possibly =
it can be<BR>changed on the Sibyte from the Linux 'ifconfig' command, =
and I don't<BR>believe our application software would like =
that.<BR><BR>Cheers,<BR><BR>a<BR><BR>On Sun, 11 Nov 2007 08:57:17 -0800 =
"Brian Stark"<BR>&lt;brian.stark@onstor.com&gt; wrote:<BR><BR>&gt; =
Here's the MAC address that's present in that register while in =
PROM:<BR>&gt;&nbsp;<BR>&gt; Mac ethernet =
addr&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nb=
sp;&nbsp;&nbsp;&nbsp;&nbsp; :00000100000c28001<BR>&gt;&nbsp;<BR>&gt; So =
either Linux is resetting the MAC address register from the one<BR>&gt; =
shown in your email or it's inserting the MAC on every packet =
that's<BR>&gt; being sent.&nbsp; If it's the latter, then it's probably =
defaulting to<BR>&gt; that address since we're not passing it in from =
PROM.<BR>&gt;<BR>&gt; ________________________________<BR>&gt;<BR>&gt; =
From: Andy Sharp<BR>&gt; Sent: Fri 11/9/2007 6:27 PM<BR>&gt; To: Brian =
Stark<BR>&gt; Cc: Rick Lund<BR>&gt; Subject: Re: prom =
changes<BR>&gt;<BR>&gt;<BR>&gt;<BR>&gt; My comments were written with =
full understanding of that.&nbsp; The short<BR>&gt; version: set the =
value in the MAC and Linux will take care of the<BR>&gt; =
rest.<BR>&gt;<BR>&gt; Currently on the cougarz, the mac addr comes out =
like thus:<BR>&gt;<BR>&gt; coolcat:~# ifconfig<BR>&gt; =
eth0&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Link encap:Ethernet&nbsp; HWaddr =
40:00:00:00:01:00<BR>&gt;<BR>&gt; Which I believe is what's sitting in =
the MAC when the linux driver<BR>&gt; gets to it.<BR>&gt;<BR>&gt; On =
Fri, 9 Nov 2007 18:09:05 -0800 "Brian Stark"<BR>&gt; =
&lt;brian.stark@onstor.com&gt; wrote:<BR>&gt;<BR>&gt; &gt; It's not as =
simple as setting the mac addr register.&nbsp; The transmit<BR>&gt; &gt; =
descriptor needs to tell the ethernet engine to use the value in<BR>&gt; =
&gt; this register.&nbsp; Setting this bit in the descriptor has to be =
done<BR>&gt; &gt; in the driver, both the one in prom and =
linux...<BR>&gt; &gt;<BR>&gt; &gt;<BR>&gt; &gt;<BR>&gt; &gt;<BR>&gt; =
&gt;<BR>&gt; &gt; -----Original Message-----<BR>&gt; &gt; From: Andy =
Sharp<BR>&gt; &gt; To: Brian Stark<BR>&gt; &gt; CC: Rick Lund<BR>&gt; =
&gt; Sent: Fri Nov 09 17:56:23 2007<BR>&gt; &gt; Subject: Re: prom =
changes<BR>&gt; &gt;<BR>&gt; &gt; On Fri, 9 Nov 2007 17:38:41 -0800 =
"Brian Stark"<BR>&gt; &gt; &lt;brian.stark@onstor.com&gt; wrote:<BR>&gt; =
&gt;<BR>&gt; &gt; &gt; FYI, if we want to use the mac addr programmed =
into the SiByte<BR>&gt; &gt; &gt; MAC, then the transmit descriptor =
needs to be modified to replace<BR>&gt; &gt; &gt; the source address =
inserted by the DMA engine.&nbsp; Right now in<BR>&gt; &gt; &gt; PROM, =
we rely on the networking code to use the address from the<BR>&gt; &gt; =
&gt; SEEP.<BR>&gt; &gt; &gt;<BR>&gt; &gt; &gt; Andy, do you know how the =
driver is working in Linux?&nbsp; Does it<BR>&gt; &gt; &gt; setup the =
MAC address for each packet or does it set the bit in<BR>&gt; &gt; &gt; =
the descriptor to use the register value?<BR>&gt; &gt;<BR>&gt; &gt; It =
gets it from the MAC.&nbsp; What it does after that, I don't know, =
but<BR>&gt; &gt; that's the important part.&nbsp; If I were going to =
implement the code to<BR>&gt; &gt; use the seep, I would just take the =
value in the seep and write it<BR>&gt; &gt; into the MAC, the end.&nbsp; =
Might make your PROM networking code go a<BR>&gt; &gt; lot faster to do =
the same?&nbsp; Just a thought.<BR>&gt; &gt;<BR>&gt; &gt; &gt;<BR>&gt; =
&gt; &gt; Brian<BR>&gt; &gt; &gt;<BR>&gt; &gt; &gt;<BR>&gt; &gt; &gt; =
&gt; -----Original Message-----<BR>&gt; &gt; &gt; &gt; From: Andy =
Sharp<BR>&gt; &gt; &gt; &gt; Sent: Monday, October 29, 2007 4:35 =
PM<BR>&gt; &gt; &gt; &gt; To: Brian Stark; Rick Lund<BR>&gt; &gt; &gt; =
&gt; Subject: prom changes<BR>&gt; &gt; &gt; &gt;<BR>&gt; &gt; &gt; &gt; =
Hello Boyeeeeez,<BR>&gt; &gt; &gt; &gt;<BR>&gt; &gt; &gt; &gt; Just =
dropping a note to remind of the prom changes:<BR>&gt; &gt; &gt; =
&gt;<BR>&gt; &gt; &gt; &gt; * Map the RTC space in.<BR>&gt; &gt; &gt; =
&gt;<BR>&gt; &gt; &gt; &gt; * One of the following: program the mac addr =
into the<BR>&gt; &gt; &gt; &gt; ethernet controller or get the =
argument/environment stuff<BR>&gt; &gt; &gt; &gt; working.&nbsp; =
Preferably the former.&nbsp; Because the latter might<BR>&gt; &gt; &gt; =
&gt; actually be a kernel issue.<BR>&gt; &gt; &gt; &gt;<BR>&gt; &gt; =
&gt; &gt; Cheers,<BR>&gt; &gt; &gt; &gt;<BR>&gt; &gt; &gt; &gt; =
a<BR>&gt; &gt; &gt; =
&gt;<BR>&gt;<BR>&gt;<BR></FONT></P></DIV></BODY></HTML>
------_=_NextPart_001_01C824DD.B0D31A29--
