Re: [PATCH] firewire: fw-ohci: sync AT dma buffer before use

From: Stefan Richter
Date: Thu Mar 13 2008 - 04:52:17 EST


Jarod Wilson wrote:
On Wednesday 12 March 2008 07:16:43 pm Stefan Richter wrote:
Jarod Wilson wrote:
See http://bugzilla.kernel.org/show_bug.cgi?id=9617
Alas the panic from comment #10 is still there, i.e. instant crash when
plugging in an LSI based CD-RW (shortly after SCSI inquiry) --- but only
if CONFIG_DEBUG_PAGEALLOC=y.

Jarod, did your crashes happen with CONFIG_DEBUG_PAGEALLOC=n?

No, they're with it turned on (and still on w/this change where it doesn't panic). If I run with CONFIG_DEBUG_PAGEALLOC=n, no panic.

So then that's like "my" panic.

The other thing that I see here is that it only happens with my two LSI based devices (both CD-RWs), always quickly after SCSI inquiry.

I shall test with my Prolific based DVD-RW to find out whether it is about some requests that are sent to CD/DVD-RWs or about the split transactions that I get from the LSI bridges. (See bugzilla.)

So this patch shouldn't do anything, except that it inserts a call which happens to have barrier
characteristics on some platforms.

...and potentially delays execution.

...but got lucky in that it actually helps this particular setup (x86_64 kernel, dual quad-core opteron, 8G RAM, 3 FireWire controllers). Hrm.

Unless you or I spot the real solution earlier, you could also try replacing your dma_sync_ with mb() and with mdelay() respectively to see what aspect of the dma_sync_ is fixing your setup. Also move the mb() to other interesting places of the involved code.
--
Stefan Richter
-=====-==--- --== -==-=
http://arcgraph.de/sr/
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/