Re: [PATCH] sungem: PHY updates pause fixes

2007-01-04 Thread Eric Lemoine

On 1/4/07, David Miller [EMAIL PROTECTED] wrote:

I've applied that patch, thanks.


David, I suppose you've applied the locking patch as well...



--
Eric
-
To unsubscribe from this list: send the line unsubscribe netdev in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html


Re: [PATCH] sungem: PHY updates pause fixes

2007-01-04 Thread David Miller
From: Eric Lemoine [EMAIL PROTECTED]
Date: Thu, 4 Jan 2007 21:06:48 +0100

 On 1/4/07, David Miller [EMAIL PROTECTED] wrote:
  I've applied that patch, thanks.
 
 David, I suppose you've applied the locking patch as well...

No, not yet.

Your locking patches are definitely 2.6.21 material, but
Ben's changes fix PAUSE handling bugs so I want to
put his patch into 2.6.20

I'll put your locking bits into 2.6.21, don't worry :-)
-
To unsubscribe from this list: send the line unsubscribe netdev in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html


Re: [PATCH] sungem: PHY updates pause fixes

2007-01-04 Thread Eric Lemoine

On 1/4/07, David Miller [EMAIL PROTECTED] wrote:

From: Eric Lemoine [EMAIL PROTECTED]
Date: Thu, 4 Jan 2007 21:06:48 +0100

 On 1/4/07, David Miller [EMAIL PROTECTED] wrote:
  I've applied that patch, thanks.

 David, I suppose you've applied the locking patch as well...

No, not yet.

Your locking patches are definitely 2.6.21 material, but
Ben's changes fix PAUSE handling bugs so I want to
put his patch into 2.6.20

I'll put your locking bits into 2.6.21, don't worry :-)


I'm relieved now :-)

I was asking because Ben said his patch applied on top of mine.


--
Eric
-
To unsubscribe from this list: send the line unsubscribe netdev in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html


Re: [PATCH] sungem: PHY updates pause fixes

2007-01-04 Thread Benjamin Herrenschmidt
On Thu, 2007-01-04 at 21:57 +0100, Eric Lemoine wrote:
 On 1/4/07, David Miller [EMAIL PROTECTED] wrote:
  From: Eric Lemoine [EMAIL PROTECTED]
  Date: Thu, 4 Jan 2007 21:06:48 +0100
 
   On 1/4/07, David Miller [EMAIL PROTECTED] wrote:
I've applied that patch, thanks.
  
   David, I suppose you've applied the locking patch as well...
 
  No, not yet.
 
  Your locking patches are definitely 2.6.21 material, but
  Ben's changes fix PAUSE handling bugs so I want to
  put his patch into 2.6.20
 
  I'll put your locking bits into 2.6.21, don't worry :-)
 
 I'm relieved now :-)
 
 I was asking because Ben said his patch applied on top of mine.

Well, I did it with yours applied already but it seems like they don't
really conflict so they can be applied pretty much in any order.

Ben.


-
To unsubscribe from this list: send the line unsubscribe netdev in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html


Re: [PATCH] sungem: PHY updates pause fixes

2007-01-03 Thread David Miller
From: Benjamin Herrenschmidt [EMAIL PROTECTED]
Date: Wed, 03 Jan 2007 16:40:02 +1100

 On the quad G5 which has tg3, I get Flow control is on for TX and on
 for RX. Let me double check if I'm on the same switch...
 
 Heh ! It's not :-)
 
 If I switch the cables, then pause is enabled on the sungem box and
 disabled (both Tx and Rx) on tg3, so at least the behaviour is
 consistent and follow the switches. Let me check the switch models...
 
 The one with only asym. support is a big Cisco Catalyst 3350 (well.. big
 but not that many ports :-)
 
 The one with classic pause support is a tiny Netgear GS116
 
 It's possible that the cisco is just misconfigured though, I'll have to
 ask Keith when he's around tomorrow to take a peek at the mgmnt
 interface.

Thanks for tracking this down :-)

You should try to use flow control, even slower than 1000Mbit links.
   
   Sorry, not sure I parse ;-) You mean allowing pause on 10 and 100 as
   well ? I sure can, it's easy to fix.
  
  That's correct.
 
 On it's way.

I've applied that patch, thanks.
-
To unsubscribe from this list: send the line unsubscribe netdev in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html


Re: [PATCH] sungem: PHY updates pause fixes

2007-01-02 Thread David Miller
From: Benjamin Herrenschmidt [EMAIL PROTECTED]
Date: Wed, 03 Jan 2007 15:58:05 +1100

 This patch adds support for a few more PHYs used by Apple and fixes
 advertising and detecting of Pause (we were missing setting the bit in
 MII_ADVERTISE and weren't testing in LPA for all PHYs). I only do it for
 gigabit capable PHYs for now.
 
 Note that I currently only advertise pause, not asymetric pause. I don't
 know for sure the details there, I suppose I should read a bit more
 802.3 references, and I don't now what sungem is capable of, but I
 noticed the PCS code (originated from you) does the same.
 
 Unfortunately, whatever switches we have here also seem to only support
 asym. pause, so while I did a quick test to verify that pause is
 properly enabled on a cross-over cable to another machine, I still get
 occasional RX fifo overflows due to pause support lacking on our
 internal network.
 
 So let me know if asym. pause is something we can support with sungem.
 In which case, it shouldn't be very hard to add in a subsequent patch.
 
 Signed-off-by: Benjamin Herrenschmidt [EMAIL PROTECTED]

Thanks for finding these bugs, although that's really strange pause
behavior you are seeing on your switches.

By default, we advertise PAUSE but not ASYM PAUSE in the tg3 driver,
and I get flow control on every switch I have here.

You should try to use flow control, even slower than 1000Mbit links.
That's the only problem I can see, would you mind fixing that and
I'll put your change into my net-2.6 tree and perhaps play around
with PAUSE on my switches here?

Thanks!

-
To unsubscribe from this list: send the line unsubscribe netdev in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html


Re: [PATCH] sungem: PHY updates pause fixes

2007-01-02 Thread Benjamin Herrenschmidt

 Thanks for finding these bugs, although that's really strange pause
 behavior you are seeing on your switches.
 
 By default, we advertise PAUSE but not ASYM PAUSE in the tg3 driver,
 and I get flow control on every switch I have here.

Yeah, that's strange. I still have the debug values at hand:

 - I advertise 0x5e1
 - I read in LPA 0xc9e1 from the switch
(and my bcm PHY tells me Rx and Tx pause disabled in a separate
register)

Now, I cross-over with a TG3 and I get:

 - I advertise 0x5e1 (hopefully same value)
 - I read in LPA 0xc5e1 from the TG3
(and that other register tells me Rx and Tx pause can be enabled).

 You should try to use flow control, even slower than 1000Mbit links.

Sorry, not sure I parse ;-) You mean allowing pause on 10 and 100 as
well ? I sure can, it's easy to fix.

 That's the only problem I can see, would you mind fixing that and
 I'll put your change into my net-2.6 tree and perhaps play around
 with PAUSE on my switches here?

Sure will do.

Ben.


-
To unsubscribe from this list: send the line unsubscribe netdev in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html


Re: [PATCH] sungem: PHY updates pause fixes

2007-01-02 Thread David Miller
From: Benjamin Herrenschmidt [EMAIL PROTECTED]
Date: Wed, 03 Jan 2007 16:20:14 +1100

 Now, I cross-over with a TG3 and I get:
 
  - I advertise 0x5e1 (hopefully same value)
  - I read in LPA 0xc5e1 from the TG3
 (and that other register tells me Rx and Tx pause can be enabled).

Does flow control get enabled with the TG3 on these
switches?  Just curious.

  You should try to use flow control, even slower than 1000Mbit links.
 
 Sorry, not sure I parse ;-) You mean allowing pause on 10 and 100 as
 well ? I sure can, it's easy to fix.

That's correct.

  That's the only problem I can see, would you mind fixing that and
  I'll put your change into my net-2.6 tree and perhaps play around
  with PAUSE on my switches here?
 
 Sure will do.

Thanks a lot.
-
To unsubscribe from this list: send the line unsubscribe netdev in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html


Re: [PATCH] sungem: PHY updates pause fixes

2007-01-02 Thread Benjamin Herrenschmidt
 The one with only asym. support is a big Cisco Catalyst 3350 (well.. big
 but not that many ports :-)

Ok, I got in the config of the switch with somebody who knows how to
speak ciscong, and it seems that it defaults to flow control desired
for send and off for receive on all ports, which means it will indeed
only advertise support for asymetrical flow control.

We've changed the setting for the port on which my sungem g5 is
connected to desired on both send and receive, and it now advertises
flow control on both, and sungem does pick it up properly.

So it's indeed the default setting of those cisco switches that seem to
not quite match what drivers like sungem or tg3 like.

Ben.


-
To unsubscribe from this list: send the line unsubscribe netdev in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html