Re: Resending: RT patches expose netdev race [was Re: [RFC] [patch 2/2] powerpc 2.6.21-rt1: fix kernel hang and/or panic

2007-05-16 Thread Benjamin Herrenschmidt
I do not know why sk_buff-head would be null, or would be set in a racy kind of way, or why the rt patches would cause this. But the evidence implicates that. Would it be possible that a locking bug in spidernet would cause it under some circumstances to get a stale skb pointer ? Ben. - To

Re: [Cbe-oss-dev] [PATCH 4/10] spidernet: zero out a pointer.

2007-05-22 Thread Benjamin Herrenschmidt
Here's a delusional reply: I didn't see any point to it. 1) a wmb would add overhead 2) the hardware is supposed to be looking at the status flag, anyway, and not misbehaving. 3) there is a wmb when the descr is actually refilled in such a way as to actually mean something to the

sky2 problem on powerpc

2006-09-03 Thread Benjamin Herrenschmidt
Hi Stephen ! To try to validate some PCIe code we have around, I got myself a SysKonnect SK-9Exx card (one x1 lane one port and one x4 lanes 2 ports actually, though I've only tested the first one at this point, based on a 88E8061 Marvell chip). I've used the sky2 driver as of a random last

Re: sky2 problem on powerpc

2006-09-04 Thread Benjamin Herrenschmidt
Because if you look at the definition for: struct sky2_rx_le { __le32 addr; __le16 length; u8 ctrl; u8 opcode; } __attribute((packed)); (As an example) If the chips does LE accesses, then marking lenght as being an LE value isn't enough. It also

Re: sky2 problem on powerpc

2006-09-04 Thread Benjamin Herrenschmidt
there so I'll let you decide what to do about those. Signed-off-by: Benjamin Herrenschmidt [EMAIL PROTECTED] Index: linux-work/drivers/net/sky2.c === --- linux-work.orig/drivers/net/sky2.c 2006-09-04 17:35:20.0 +1000 +++ linux

Re: sky2 problem on powerpc

2006-09-04 Thread Benjamin Herrenschmidt
On Mon, 2006-09-04 at 23:05 +0200, Segher Boessenkool wrote: The patch has a couple of places where I reversed 2 assignments, they are harmless, it was before I figured out that the chip will (apparently) not access a descriptor before it's been told to do so via MMIO, and thus the

sky2: hw checksum failures

2006-09-04 Thread Benjamin Herrenschmidt
Hi Stephen ! So I now have the driver working with the patches I gave you. However, when I set it up with a 100bT link and transfer a huge file from another machine (about 10MB/sec throughput), I get a few of these in dmesg eth2: hw csum failure. Call Trace: [CFFEF8D0] [C000F460]

Re: sky2: hw checksum failures

2006-09-04 Thread Benjamin Herrenschmidt
On Mon, 2006-09-04 at 20:34 -0700, Stephen Hemminger wrote: Unneeded byte swap was occurring. --- linux-2.6.orig/drivers/net/sky2.c +++ linux-2.6/drivers/net/sky2.c @@ -2001,7 +2001,7 @@ static int sky2_status_intr(struct sky2_ case OP_RXCHKS: skb =

Re: sky2 problem on powerpc

2006-09-04 Thread Benjamin Herrenschmidt
It may not need any swapping, it is hard to tell what the hardware will do without experimentation. Yes... did you have a chance to test the vlan stuff on LE machines (x86) ? did it work with the BE swapping you were doing ? I've purposedly removed in my patches the hardware side swapping of

Re: sky2: hw checksum failures

2006-09-04 Thread Benjamin Herrenschmidt
On Mon, 2006-09-04 at 20:56 -0700, Stephen Hemminger wrote: On Tue, 05 Sep 2006 13:42:38 +1000 Benjamin Herrenschmidt [EMAIL PROTECTED] wrote: On Mon, 2006-09-04 at 20:34 -0700, Stephen Hemminger wrote: Unneeded byte swap was occurring. --- linux-2.6.orig/drivers/net/sky2.c

Re: sky2 problem on powerpc

2006-09-05 Thread Benjamin Herrenschmidt
On Mon, 2006-09-04 at 21:15 -0700, Stephen Hemminger wrote: On Tue, 05 Sep 2006 13:47:52 +1000 Benjamin Herrenschmidt [EMAIL PROTECTED] wrote: It may not need any swapping, it is hard to tell what the hardware will do without experimentation. Yes... did you have a chance to test

Re: sky2: hw checksum failures

2006-09-05 Thread Benjamin Herrenschmidt
Which means that if it worked on x86 with le16_to_cpu, it should work on powerpc... The main difference here however is that you called le16_to_cpu (which is basically a nop) on a 32 bits field, while I called le32_to_cpu() on it. But both should lead to the same ... (x86 will do a

Re: sky2: hw checksum failures

2006-09-05 Thread Benjamin Herrenschmidt
Agreed. Actually the checksum value is same hi/lo because there are two checksum units and we ask for the same offset on both. Ok, that explains the (HLEN 16) | HLEN thing when configuring it... At this point, best is I dig into the actual values and see what's up. I'll let you know (I don't

Re: sky2 problem on powerpc

2006-09-05 Thread Benjamin Herrenschmidt
On Tue, 2006-09-05 at 14:36 -0700, Stephen Hemminger wrote: This is the reduced version of your patch, plus I got rid of the union in tx_le, it is a nuisance. Thanks. I'll give it a go later today. The remaining nit is the inconsitent swapping of the vlan tag which is manipulated at BE at times

Re: [PATCH] FRV: do_gettimeofday() should no longer use tickadj

2006-09-07 Thread Benjamin Herrenschmidt
On Thu, 2006-09-07 at 10:55 +0100, David Howells wrote: Benjamin Herrenschmidt [EMAIL PROTECTED] wrote: Well, genirq gives you more flexibility than the current mecanism so ... No, it doesn't because the FRV arch contains its own mechanism and I can do what ever I like in it. But genirq

Re: [PATCH] FRV: do_gettimeofday() should no longer use tickadj

2006-09-06 Thread Benjamin Herrenschmidt
Under some circumstances I can work out which sources have triggered which interrupts (there are various off-CPU FPGAs which implement auxiliary PICs that do announce their sources), but the aux-PIC channels are grouped together upon delivery to the CPU PIC, so some of the ACK'ing has to be

Re: [PATCH] FRV: do_gettimeofday() should no longer use tickadj

2006-09-08 Thread Benjamin Herrenschmidt
On Fri, 2006-09-08 at 11:25 +0100, David Howells wrote: Benjamin Herrenschmidt [EMAIL PROTECTED] wrote: No, you do a chain handler. Look at how I do it in arch/powerpc/platform/pseries/setup.c for example. It's actually trivial. You install a special flow handler (which means

Re: TG3 data corruption (TSO ?)

2006-09-09 Thread Benjamin Herrenschmidt
On Sat, 2006-09-09 at 02:22 -0700, David Miller wrote: From: Benjamin Herrenschmidt [EMAIL PROTECTED] Date: Sat, 09 Sep 2006 07:46:02 +1000 I don't think that in general, you have ordering guarantees between cacheable and non-cacheable stores unless you use explicit barriers. In fact

Re: TG3 data corruption (TSO ?)

2006-09-09 Thread Benjamin Herrenschmidt
semantics. At least what is implemented currently on PowerPC is the __raw_* versions which not only have no barriers at all (they don't even order between MMIOs, for example, readl might cross writel), and do no endian swap. Quite a mess of semantics if you ask me... Then there has

Re: TG3 data corruption (TSO ?)

2006-09-08 Thread Benjamin Herrenschmidt
Please send me lspci and tg3 probing output so that I know what tg3 hardware you're using. I also want to look at the tcpdump or ethereal on the mirrored port that shows the packet being corrupted. Hi Michael ! It's the dual controller of an Apple Quad G5, thus afaik in an HT2000 chip:

Re: TG3 data corruption (TSO ?)

2006-09-08 Thread Benjamin Herrenschmidt
On Fri, 2006-09-08 at 15:07 -0700, Michael Chan wrote: On Sat, 2006-09-09 at 07:41 +1000, Benjamin Herrenschmidt wrote: As for the tcpdump output, well, I have a 3Gb file for now :) I need to do a bit of surgery on it to get only the interesting part. I'll try to do that later today

Re: TG3 data corruption (TSO ?)

2006-09-08 Thread Benjamin Herrenschmidt
I'd rather not have to do that, or even if I go that way, not have to add that sync at all before the store and thus get back the few percent of perfs lost due to those sync's on some heavy IO benchmarks. Another way to fix this without requiring drivers to add all kinds of barriers in

Re: TG3 data corruption (TSO ?)

2006-09-10 Thread Benjamin Herrenschmidt
On Sun, 2006-09-10 at 22:33 -0700, Michael Chan wrote: Benjamin Herrenschmidt wrote: I've done: #define tw32_rx_mbox(reg, val) do { wmb(); tp-write32_rx_mbox(tp, reg, val); } while(0) #define tw32_tx_mbox(reg, val) do { wmb(); tp-write32_tx_mbox(tp, reg, val); } while(0

Re: TG3 data corruption (TSO ?)

2006-09-11 Thread Benjamin Herrenschmidt
Ok, it seems like we might have more than just the missing barrier in TG3. Possibly some IOMMU problems on some machines as well. Unfortunately, I don't have a tg3 on a PCI-X or PCI-E card to test on a pSeries or some other machine. [Olof: I've disabled the new U4 DART invalidate code (reverted

Re: [PATCH] FRV: do_gettimeofday() should no longer use tickadj

2006-09-10 Thread Benjamin Herrenschmidt
But funky cascading using chained flow handlers doesn't work if the cascade must share an IRQ with some other device, right? Indeed. Best way there is then to have a normal action handler like you do and have it call generic_handle_irq() on the cascaded interrupts. Ben. - To unsubscribe

Re: TG3 data corruption (TSO ?)

2006-09-10 Thread Benjamin Herrenschmidt
Oh, we know about this. The powerpc writel() used to have memory barriers in 2.4 kernels but not any more in 2.6 kernels. Red Hat's version of tg3 has extra wmb()'s to fix this problem. David doesn't think that the upstream version of tg3 should have these wmb()'s, and the problem should

Re: TG3 data corruption (TSO ?)

2006-09-10 Thread Benjamin Herrenschmidt
On Sun, 2006-09-10 at 22:18 -0700, Michael Chan wrote: Benjamin Herrenschmidt wrote: I've added a wmb() in tw32_rx_mbox() and tw32_tx_mbox() and can still reproduce the problem. I've also done a 2 days run without TSO enabled without a failure (my test program normally fails after

Re: Fw: [PATCH] Remove powerpc specific parts of 3c509 driver

2006-09-19 Thread Benjamin Herrenschmidt
However, I presume someone added the __powerpc__ define here because they picked up a 3c509 at a garage sale, stuck it in a powerpc, found out it didn't work due to a byte-swapping bug, and then patched it as above. I'm disturbed that somehow outsl_ns() became identical to outsl() at some

Re: Fw: [PATCH] Remove powerpc specific parts of 3c509 driver

2006-09-19 Thread Benjamin Herrenschmidt
On Tue, 2006-09-19 at 20:52 +0200, Matt Sealey wrote: Some northbridges and PCI bridges have clever byteswapping in hardware, maybe this is just an effect of that. In theory depending on the host bridge, you should pass in big endian data and have it swap or not swap, not pick that way in

Re: [PATCH] Remove powerpc specific parts of 3c509 driver

2006-09-19 Thread Benjamin Herrenschmidt
On Wed, 2006-09-20 at 02:21 +0200, Segher Boessenkool wrote: Nah. We have the basic rule that readl/writel are little endian. PowerPC additionally provides arch specific low level in_{be,le}32 type accessors with explicit endianness. Or you can also use cpu_to_le32/le32_to_cpu kind of

bcm43xx driver unstable behaviour (and linux wireless is junk btw)

2006-09-23 Thread Benjamin Herrenschmidt
Hi folks ! So this is 2.6.18 + Larry fix (though I've seen this problem before, it seems using WPA just make it happen more often). This is also a 4318, so the link is pretty weak due to the Tx Power problem and I suspects it makes the driver problems more visible... So basically, I lose the

Re: bcm43xx driver unstable behaviour (and linux wireless is junk btw)

2006-09-24 Thread Benjamin Herrenschmidt
prism54 fullmac, right? Yes. Try using -Dwext; the prism54 wpa_supplicant driver is a dead-end and I added WE-19 commands to it a bit ago anyway. Oddly enough, I couldn't seem to get the driver to work reliably for me using straight WEP either, let alone WPA. It's pretty unmaintained at

Re: bcm43xx driver unstable behaviour (and linux wireless is junk btw)

2006-09-24 Thread Benjamin Herrenschmidt
On Sat, 2006-09-23 at 23:45 -0400, Daniel Drake wrote: Benjamin Herrenschmidt wrote: Oh and I don't care about it works in dscape stack sort of crap I regulary get. I want something that works with upstream kernels. That isn't that much to ask... or is it ? wpa_supplicant triggers races

Re: bcm43xx driver unstable behaviour (and linux wireless is junk btw)

2006-09-24 Thread Benjamin Herrenschmidt
So what are the chances of getting this dscape stack merged, let's say... for 2.6.19 ? Or we'll get yet another full release with barely working wireless ? I don't think it's possible to happen for 2.6.19. Ealiest 2.6.20 but likely one or two releases later (me thinks). Which means

Re: bcm43xx driver unstable behaviour (and linux wireless is junk btw)

2006-09-24 Thread Benjamin Herrenschmidt
On Sun, 2006-09-24 at 10:43 +0200, Michael Buesch wrote: On Sunday 24 September 2006 10:12, Benjamin Herrenschmidt wrote: So what are the chances of getting this dscape stack merged, let's say... for 2.6.19 ? Or we'll get yet another full release with barely working wireless

Re: bcm43xx driver unstable behaviour (and linux wireless is junk btw)

2006-09-25 Thread Benjamin Herrenschmidt
yes. Many locking issues in d80211 to still sort out. Basically, there are next to no useful locks in it and most data structures are not protected at all. Doh ! Scary... locking is hard ... if the stuff was written without locking in mind in the first place, it might end up being a

Re: [PATCH 2.6.19-rc1] ehea firmware interface based on Anton Blanchard's new hvcall interface

2006-09-25 Thread Benjamin Herrenschmidt
On Mon, 2006-09-25 at 20:07 -0400, Jeff Garzik wrote: patch does not apply. also, it would seem like varargs would be appropriate here. Not really... these are hypervisor calls, their calling convention is not varargs, thus we would need some conversion layer if using them, with possible

Re: [PATCH] softmac: Fix WX and association related races

2006-09-27 Thread Benjamin Herrenschmidt
On Wed, 2006-09-27 at 17:26 +0200, Michael Buesch wrote: This fixes some race conditions in the WirelessExtension handling and association handling code. Unlike the previous patch, this one doesn't apply on top of 2.6.18 (which I'm using as a basis for testing, along with Larry big bcm43xx

Re: [PATCH] softmac: Fix WX and association related races

2006-09-27 Thread Benjamin Herrenschmidt
On Wed, 2006-09-27 at 19:50 +0200, Michael Buesch wrote: On Wednesday 27 September 2006 18:18, Larry Finger wrote: Michael Buesch wrote: This fixes some race conditions in the WirelessExtension handling and association handling code. Signed-off-by: Michael Buesch [EMAIL PROTECTED]

Re: [PATCH] softmac: Fix WX and association related races

2006-09-27 Thread Benjamin Herrenschmidt
On Wed, 2006-09-27 at 19:43 -0500, Larry Finger wrote: Benjamin Herrenschmidt wrote: I won't try some random other git tree to test things, it's simply not feasible for me and we need something we can give to distros to backport so they have something remotely stable (I'm thinking

Re: [PATCH 21/21]: powerpc/cell spidernet DMA coalescing

2006-10-11 Thread Benjamin Herrenschmidt
On Tue, 2006-10-10 at 18:20 -0500, jschopp wrote: Linas Vepstas wrote: The current driver code performs 512 DMA mappns of a bunch of 32-byte structures. This is silly, as they are all in contiguous memory. Ths patch changes the code to DMA map the entie area with just one call.

Re: [PATCH 21/21]: powerpc/cell spidernet DMA coalescing

2006-10-11 Thread Benjamin Herrenschmidt
I started writingthe patch thinking it will have some huge effect on performance, based on a false assumption on how i/o was done on this machine *If* this were another pSeries system, then each call to pci_map_single() chews up an actual hardware translation control entry (TCE) that

Re: [PATCH 1/5] remove TxStartThresh and RxEarlyThresh

2006-10-15 Thread Benjamin Herrenschmidt
On Sat, 2006-10-14 at 15:55 -0400, Jesse Huang wrote: From: Jesse Huang [EMAIL PROTECTED] Change Logs: For patent issue need to remove TxStartThresh and RxEarlyThresh. This patent is cut-through patent. If use this function, Tx will start to transmit after few data be move in to Tx FIFO.

[PATCH] add init_dummy_netdev() for napi only dummy intefaces

2006-12-11 Thread Benjamin Herrenschmidt
(if we want them at all). Signed-off-by: Benjamin Herrenschmidt [EMAIL PROTECTED] --- I'm shit at inventing function names so feel free to come up with something nicer ! Index: linux-cell/drivers/net/ibm_emac/ibm_emac_mal.c === --- linux

Re: [patch sungem] improved locking

2006-12-11 Thread Benjamin Herrenschmidt
On Tue, 2006-12-12 at 06:33 +0100, Eric Lemoine wrote: On 12/12/06, David Miller [EMAIL PROTECTED] wrote: [...] Anyways, Eric your changes look fine as far as I can tell, can you give them a really good testing on some SMP boxes? Unfortunately I can't, I don't have the hardware (only an

Re: [patch sungem] improved locking

2006-12-12 Thread Benjamin Herrenschmidt
On Wed, 2006-12-13 at 14:12 +1100, Benjamin Herrenschmidt wrote: Been hitting a raw throughput in both directions plus a few other things on a dual G5 and the driver didn't crash :-) I'm seeing a problem though but I'm not sure it's related to your patch, I'll have to test without

Re: [PATCH] drivers/net: spidernet driver on Celleb

2006-12-12 Thread Benjamin Herrenschmidt
On Tue, 2006-12-12 at 19:14 -0600, Linas Vepstas wrote: On Tue, Dec 12, 2006 at 02:25:50PM +0900, Ishizaki Kou wrote: Following are the changes. -This patch enables auto-negotiation. -Loading firmware is done when spidernet_open() is called. -And this patch adds other several small

Re: [patch sungem] improved locking

2006-12-12 Thread Benjamin Herrenschmidt
Been hitting a raw throughput in both directions plus a few other things on a dual G5 and the driver didn't crash :-) I'm seeing a problem though but I'm not sure it's related to your patch, I'll have to test without it. Basically, if I use a slightly modified versio of tridge's socklib (raw

Re: [patch sungem] improved locking

2006-12-12 Thread Benjamin Herrenschmidt
On Tue, 2006-12-12 at 20:03 -0800, David Miller wrote: From: Benjamin Herrenschmidt [EMAIL PROTECTED] Date: Wed, 13 Dec 2006 14:12:13 +1100 David, could that be the pause stuff not working properly ? It could be, but if the tg3 says flow control is up in the kernel logs things ought

Re: [PATCH] add init_dummy_netdev() for napi only dummy intefaces

2006-12-13 Thread Benjamin Herrenschmidt
On Wed, 2006-12-13 at 11:35 -0800, Stephen Hemminger wrote: Could we split off the NAPI context part of network_device instead? I'll work up something for 2.6.21. That would do the trick too... though I prefer not putting my hands in network_device too much myself :-) Ben - To unsubscribe

Re: [patch sungem] improved locking

2006-12-14 Thread Benjamin Herrenschmidt
On Tue, 2006-12-12 at 06:49 +0100, Eric Lemoine wrote: On 12/12/06, Benjamin Herrenschmidt [EMAIL PROTECTED] wrote: On Tue, 2006-12-12 at 06:33 +0100, Eric Lemoine wrote: On 12/12/06, David Miller [EMAIL PROTECTED] wrote: [...] Anyways, Eric your changes look fine as far as I can

Re: [RFC] split NAPI from network device.

2006-12-14 Thread Benjamin Herrenschmidt
On Wed, 2006-12-13 at 15:46 -0800, Stephen Hemminger wrote: Split off NAPI part from network device, this patch is build tested only! It breaks kernel API for network devices, and only three examples are fixed (skge, sky2, and tg3). 1. Decomposition allows different NAPI - network device

Re: [patch sungem] improved locking

2006-12-17 Thread Benjamin Herrenschmidt
Thanks for testing this stuff. I'll take a look at the pause-enabling issue in the sungem drive then work on integrating Eric's patch. Ok, thanks. Probably we'll need to put this in post-2.6.20 as the merge window is closed. Yup, no hurry there. Ben. - To unsubscribe from this list:

netif_poll_enable() barrier

2006-12-19 Thread Benjamin Herrenschmidt
Hi ! I stumbled accross what might be a bug on out of order architecture: netif_poll_enable() only does a clear_bit(). However, netif_poll_disable/enable pairs are often used as simili-spinlocks. (netif_poll_enable() has pretty much spin_lock semantics except that it schedules instead of

Generic PHY lib vs. locking

2006-12-21 Thread Benjamin Herrenschmidt
Hi Andy ! I've been looking at porting various drivers (EMAC, sungem, spider_net, ...) to the generic PHY stuff. However, I have one significant problem here. One of the things I've been trying to do lately with EMAC and that I plan to do with others, is to have the PHY polling entirely operate

Re: Generic PHY lib vs. locking

2006-12-22 Thread Benjamin Herrenschmidt
On Fri, 2006-12-22 at 10:24 -0500, David Hollis wrote: On Fri, 2006-12-22 at 15:07 +1100, Benjamin Herrenschmidt wrote: Hi Andy ! I've been looking at porting various drivers (EMAC, sungem, spider_net, ...) to the generic PHY stuff. However, I have one significant problem here

Re: Generic PHY lib vs. locking

2006-12-28 Thread Benjamin Herrenschmidt
Great! At last glance, only gianfar, fs_enet, and au1000_eth. There are one or two others that haven't gone in, yet. My hope is that your changes will not require any changes to the drivers, but I'll leave that to your discretion. Unfortunately, it will probably have an impact on

Re: netif_poll_enable() barrier

2006-12-28 Thread Benjamin Herrenschmidt
On Thu, 2006-12-28 at 21:09 -0800, David Miller wrote: From: Benjamin Herrenschmidt [EMAIL PROTECTED] Date: Wed, 20 Dec 2006 14:44:12 +1100 I stumbled accross what might be a bug on out of order architecture: netif_poll_enable() only does a clear_bit(). However, netif_poll_disable

Re: [patch sungem] improved locking

2006-12-29 Thread Benjamin Herrenschmidt
On Thu, 2006-12-28 at 21:05 -0800, David Miller wrote: From: Benjamin Herrenschmidt [EMAIL PROTECTED] Date: Wed, 13 Dec 2006 15:07:24 +1100 tg3 says tg3: eth0: Link is up at 1000 Mbps, full duplex. tg3: eth0: Flow control is on for TX and on for RX. but sungem says eth0

[PATCH] sungem: PHY updates pause fixes

2007-01-02 Thread Benjamin Herrenschmidt
, it shouldn't be very hard to add in a subsequent patch. Signed-off-by: Benjamin Herrenschmidt [EMAIL PROTECTED] --- (Applies on top of Eric's locking patch) Index: linux-work/drivers/net/sungem_phy.c === --- linux-work.orig/drivers/net

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

[PATCH] sungem: PHY updates pause fixes (#2)

2007-01-02 Thread Benjamin Herrenschmidt
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. Signed-off-by: Benjamin Herrenschmidt [EMAIL PROTECTED] --- (Applies on top of Eric's locking patch) This version advertise pause

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

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

Re: [PATCH 0/4] spidernet: add support for Celleb

2007-01-17 Thread Benjamin Herrenschmidt
On Wed, 2007-01-17 at 19:00 +0900, Ishizaki Kou wrote: Dear everyone, This is a revised version of the patch set for spider_net driver that works on Toshiba Cell Refererence Set (aka Celleb). This patch set is based on netdev-2.6.git#upstream. Jens, can you give that a go on our blades

Re: [PATCH 18/59] sysctl: ipmi remove unnecessary insert_at_head flag

2007-01-16 Thread Benjamin Herrenschmidt
On Tue, 2007-01-16 at 09:39 -0700, Eric W. Biederman wrote: From: Eric W. Biederman [EMAIL PROTECTED] - unquoted With unique sysctl binary numbers setting insert_at_head is pointless. Signed-off-by: Eric W. Biederman [EMAIL PROTECTED] Acked-by: Benjamin Herrenschmidt [EMAIL PROTECTED

Re: [PATCH 36/59] sysctl: C99 convert ctl_tables entries in arch/ppc/kernel/ppc_htab.c

2007-01-16 Thread Benjamin Herrenschmidt
On Tue, 2007-01-16 at 09:39 -0700, Eric W. Biederman wrote: From: Eric W. Biederman [EMAIL PROTECTED] - unquoted And make the mode of the kernel directory 0555 no one is allowed to write to sysctl directories. Signed-off-by: Eric W. Biederman [EMAIL PROTECTED] Acked-by: Benjamin

Re: [PATCH 35/59] sysctl: C99 convert ctl_tables in arch/powerpc/kernel/idle.c

2007-01-16 Thread Benjamin Herrenschmidt
On Tue, 2007-01-16 at 09:39 -0700, Eric W. Biederman wrote: From: Eric W. Biederman [EMAIL PROTECTED] - unquoted This was partially done already and there was no ABI breakage what a relief. Signed-off-by: Eric W. Biederman [EMAIL PROTECTED] Acked-by: Benjamin Herrenschmidt [EMAIL

Re: spidernet: dynamic phy setup code

2007-01-26 Thread Benjamin Herrenschmidt
On Fri, 2007-01-26 at 14:09 +0100, Jens Osterkamp wrote: This patch modifies the patch submitted by Kou Ishizaki to make it work on the blade (http://marc.theaimsgroup.com/?l=linux-netdevm=116593424505539w=2). Unfortunately I dont have access to a Celleb so I cannot test it there. The basic

Re: spidernet: add improved phy support in sungem_phy.c

2007-01-26 Thread Benjamin Herrenschmidt
On Fri, 2007-01-26 at 14:07 +0100, Jens Osterkamp wrote: This patch adds improved version of enable_fiber for both the 5421 and the 5461 phy. It is now possible to specify with these wether you want autonegotiation or not. This is needed for bladecenter switches where some expect

Re: No Subject

2007-02-03 Thread Benjamin Herrenschmidt
We need to use different auto-neg initial settings between for 10/100Mbps ethernet switches and for Gbps ethernet switches. That is strange ! What PHY chip are you using ? Are you sure it's not just you not properly configuring the PHY ? Is the datasheet for the PHY available somewhere ?

Re: [Cbe-oss-dev] spidernet: dynamic phy setup code

2007-02-04 Thread Benjamin Herrenschmidt
On Thu, 2007-02-01 at 12:04 +0100, Jens Osterkamp wrote: Ishizaki-san, This patch partially works on celleb but remains following several problems. 1. It doesn't recover once an ethernet cable which is connected to a spider_net card is unpluged. My understanding is that you are

Re: spidernet: dynamic phy setup code

2007-02-04 Thread Benjamin Herrenschmidt
We use bcm5461. There is a possibility that we don't know the appropriate setting which is applicable for both type of switches. Have you tested the existing 54xx code in sungem_phy.c ? We use that with 5462 at least in K2 and all sorts of 54xx chips and it works fine... Just setup the right

Re: [PATCH 3/4] myri10ge - Driver core

2006-05-25 Thread Benjamin Herrenschmidt
On Wed, 2006-05-24 at 01:39 +1000, Anton Blanchard wrote: +#ifdef CONFIG_MTRR + mgp-mtrr = mtrr_add(mgp-iomem_base, mgp-board_span, +MTRR_TYPE_WRCOMB, 1); +#endif ... + mgp-sram = ioremap(mgp-iomem_base, mgp-board_span); Not sure how we are meant to

Re: [PATCH 3/4] myri10ge - Driver core

2006-05-25 Thread Benjamin Herrenschmidt
On Wed, 2006-05-24 at 10:04 +0200, Brice Goglin wrote: I am not sure what you mean. The only ppc64 with PCI-E that we have seen so far (a G5) couldn't do write combining according to Apple. That is not 100% true I don't know what apple had in mind. It also depends in what slot you are.

Re: [PATCH 3/4] myri10ge - Driver core

2006-05-26 Thread Benjamin Herrenschmidt
No proper interface exposed, he'll have to do an #ifdef powerpc here or such and use __ioremap with explicit page attributes. I have a hack to do that automatically for memory covered by prefetchable PCI BARs when mmap'ing from userland but not for kernel ioremap. Stupid question:

Re: [PATCH 3/4] myri10ge - Driver core

2006-05-26 Thread Benjamin Herrenschmidt
On Fri, 2006-05-26 at 06:30 -0400, Jeff Garzik wrote: Benjamin Herrenschmidt wrote: No proper interface exposed, he'll have to do an #ifdef powerpc here or such and use __ioremap with explicit page attributes. I have a hack to do that automatically for memory covered by prefetchable PCI

Re: [PATCH] ieee80211: enable hw wep where host has to build IV

2005-12-30 Thread Benjamin Herrenschmidt
On Fri, 2005-12-30 at 04:22 +0100, Johannes Berg wrote: This patch fixes some of the ieee80211 crypto related code so that instead of having the host fully do crypto operations, the host_build_iv flag works properly (for WEP in this patch) which, if turned on, requires the hardware to do all

Re: [ANNOUNCE] RT2x00 ieee80211 stack switch

2006-01-03 Thread Benjamin Herrenschmidt
On Tue, 2006-01-03 at 04:20 -0500, Michael Wu wrote: On Monday 02 January 2006 09:22, Ivo van Doorn wrote: Hi rt2x00-devel netdev lists, First I would like to wish everybody a happy new year! Secondly I would like to make the announcement that the rt2x00 project has decided to switch

Re: sungem PHY changes break sparc64

2006-01-31 Thread Benjamin Herrenschmidt
. Signed-off-by: Benjamin Herrenschmidt [EMAIL PROTECTED]b Signed-off-by: David S. Miller [EMAIL PROTECTED] For example, clearing all of those extra bits in gem_init_phy() and forcing MIF_CFG_MDI0, PCS_DMODE_MGM in PCS_DMODE and MAC_XIFCFG_OE in MAC_XIFCFG have lots of non-trivial

Re: [patch 09/11] sungem: Make PM of PHYs more reliable (#2)

2006-02-01 Thread Benjamin Herrenschmidt
On Wed, 2006-02-01 at 00:54 -0800, [EMAIL PROTECTED] wrote: From: Benjamin Herrenschmidt [EMAIL PROTECTED] Andrew, please drop it for now. It has issues on sparc64 that I need to have a look at. Ben. On my latest laptop, I've had occasional PHY dead on wakeup from sleep... the PHY would

Re: [PATCH] bcm43xx: Drain TX status before starting IRQs

2006-10-19 Thread Benjamin Herrenschmidt
On Thu, 2006-10-19 at 17:29 +0200, Michael Buesch wrote: Drain the Microcode TX-status-FIFO before we enable IRQs. This is required, because the FIFO may still have entries left from a previous run. Those would immediately fire after enabling IRQs and would lead to an oops in the DMA TXstatus

Re: [sungem] proposal for a new locking strategy

2006-11-05 Thread Benjamin Herrenschmidt
On Sun, 2006-11-05 at 14:00 +0100, Eric Lemoine wrote: Hi! Some (long) time ago benh wrote a blaming comment in sungem.c about that driver's locking strategy. That comment basically says that we probably don't need two spinlocks. Yeah :) Note that I mostly blamed myself there ... Just never

[PATCH] s2io ppc64 fix for readq/writeq

2006-11-05 Thread Benjamin Herrenschmidt
accessors which will break that test. This fixes it. I don't have anything less ugly at hand unfortunately. Signed-off-by: Benjamin Herrenschmidt [EMAIL PROTECTED] --- The patch changing ppc64 own definition is scheduled to go in 2.6.20 when the merge window opens, so it would be nice if this patch

Re: [PATCH] s2io ppc64 fix for readq/writeq

2006-11-06 Thread Benjamin Herrenschmidt
This seems a bit ugly. Could you add #define readq readq to your platform instead? That's ugly too imho but I suppose I can do it :-) I generally think it's a bug in the kernel-wide API, if use of said API requires arch-specific ifdefs. Yes. I agree. In that specific case, I

Re: [PATCH] s2io ppc64 fix for readq/writeq

2006-11-06 Thread Benjamin Herrenschmidt
This is why I said good enough for drivers. This is _key_. I have run into several [PCI] devices with 64-bit registers, and __none__ of them had requirements such that the Linux platform code -must- provide an atomic readq/writeq. Probably because everybody wants to support 32-bit

Re: [PATCH] s2io ppc64 fix for readq/writeq

2006-11-06 Thread Benjamin Herrenschmidt
On Mon, 2006-11-06 at 01:37 -0800, Linus Torvalds wrote: On Mon, 6 Nov 2006, Jeff Garzik wrote: This seems a bit ugly. Could you add #define readq readq to your platform instead? Heartily agreed. MUCH better than adding unrelated #if defined() stuff, whether arch-related

Re: [PATCH] s2io ppc64 fix for readq/writeq

2006-11-06 Thread Benjamin Herrenschmidt
On Mon, 2006-11-06 at 01:50 -0800, Linus Torvalds wrote: On Mon, 6 Nov 2006, Benjamin Herrenschmidt wrote: Anyway, what do you think of Jeff proposal to just implement them as two 32 bits operations ? My arch guy side screams at the idea, but if, indeed, drivers generally cope fine

Re: [PATCH] s2io ppc64 fix for readq/writeq

2006-11-06 Thread Benjamin Herrenschmidt
On Mon, 2006-11-06 at 04:55 -0500, Jeff Garzik wrote: Benjamin Herrenschmidt wrote: On Mon, 2006-11-06 at 01:50 -0800, Linus Torvalds wrote: On Mon, 6 Nov 2006, Benjamin Herrenschmidt wrote: Anyway, what do you think of Jeff proposal to just implement them as two 32 bits operations ? My

Re: [PATCH] s2io ppc64 fix for readq/writeq

2006-11-06 Thread Benjamin Herrenschmidt
Generally the kernel code should write the two 32-bit chunks to the memory-mapped region in order (low dword first), and let things take care of themselves from there. That's pretty much the implementation that -every- driver copies, when they need readq/writeq to work on a 32-bit

Re: [patch sungem] improved locking

2006-11-10 Thread Benjamin Herrenschmidt
Yes, the bit 4 isn't used, but I assumed clearing it shouldn't be prolem. Always leave reserved bits alone ... I agree it's very unlikely in this case that it could cause a problem but I've seen stranger things Ben. - To unsubscribe from this list: send the line unsubscribe netdev in the

Re: [PATCH]: bcm43xx-d80211: fix hwcrypto issues (mcast)

2006-11-16 Thread Benjamin Herrenschmidt
On Thu, 2006-11-16 at 15:07 +0100, Michael Buesch wrote: This fixes various bcm43xx-d80211 hwcrypto issues, which mainly prevented mcast frames from being decrypted properly. This is mostly a rewrite of the key managing code. Note that after this patch v3 firmware is no longer supported. So

Re: [PATCH]: bcm43xx-d80211: fix hwcrypto issues (mcast)

2006-11-17 Thread Benjamin Herrenschmidt
On Fri, 2006-11-17 at 08:53 +0100, Johannes Berg wrote: On Fri, 2006-11-17 at 18:46 +1100, Benjamin Herrenschmidt wrote: So what is the solution for Apple machines owner who only get a v3 firmware from Apple ? I remember you telling me the answer on irc but I wanted to make it public

Re: [patch sungem] improved locking

2006-11-28 Thread Benjamin Herrenschmidt
On Tue, 2006-11-28 at 15:43 -0800, David Miller wrote: At least in theory the atomic + any necessary memory barriers would be cheaper than the extra PIO read we need otherwise. Yes, IO reads are generally the worst case scenarios even on machines with fairly slow locks. Ben. - To

Re: [PATCH] Add Broadcom PHY support

2006-12-04 Thread Benjamin Herrenschmidt
On Fri, 2006-09-15 at 16:15 -0400, Amy Fong wrote: [PATCH] Add Broadcom PHY support This patch adds a driver to support the bcm5421s and bcm5461s PHY Kernel version: linux-2.6.18-rc6 Signed-off-by: Amy Fong Some 5421's need special initialisation (see drivers/net/sungem_phy.c), might

Re: [PATCH] Add Broadcom PHY support

2006-12-04 Thread Benjamin Herrenschmidt
I believe that this fiber enabling can be done by defining config_init in the phy_driver struct. struct phy_driver { snip /* Called to initialize the PHY, * including after a reset */ int (*config_init)(struct phy_device *phydev); snip }; Well... I don't know for

NAPI and shared interrupt control

2006-12-06 Thread Benjamin Herrenschmidt
Hi Dave ! I'd like your advice on something we need to deal with in the EMAC ethernet driver (an IBM part). The driver is maintainedby Eugene (CC'd), I'm mostly adding support for some new hardware at this point, which involves making it SMP safe among other things ;-) So the problem this driver

Re: NAPI and shared interrupt control

2006-12-06 Thread Benjamin Herrenschmidt
What Eugene does currently, which seems to me like it's actually the only proper solution, is to create a separate net_device structure for the DMA engine and thus have a single NAPI poll weighting for all the EMACs sharing a given MAL (MAL is the name of that DMA engine). This means that

Re: NAPI and shared interrupt control

2006-12-07 Thread Benjamin Herrenschmidt
On Thu, 2006-12-07 at 02:22 -0800, Eugene Surovegin wrote: On Thu, Dec 07, 2006 at 02:20:10AM -0800, David Miller wrote: It also just occured to me that even if you use the dummy device approach, it's the dummy device's quota that will be used by the generic -poll() downcall into the

Re: [PATCH 3/16] Spidernet RX Locking

2006-12-08 Thread Benjamin Herrenschmidt
A spinlock is expensive in the fast path, which is why Jeff says it's invasive. spider_net_decode_one_descr() is called from spider_net_poll() (which is the netdev-poll callback) and also from spider_net_handle_rxram_full(). The rxramfull routine is called from a tasklet that is fired off

  1   2   3   4   5   >