Michael,
There is something a little funky with this routine. If the call to
__b43_get_and_map_ringmem() fails because the memory allocated is not within the
DMA region supported by the card, there is no way for execution to reach the
section that takes action to fix the problem. As you have probably seen, this is
likely the underlying cause of the regression reported in Bugzilla No. 14844.
Testing by the OP has not been done, but it fixed the same problem here.
Fixing this will likely be a two-step process. For 2.6.33, I am proposing the
following simple patch, which is essentially what is being tested:
Index: wireless-testing/drivers/net/wireless/b43/dma.c
===================================================================
--- wireless-testing.orig/drivers/net/wireless/b43/dma.c
+++ wireless-testing/drivers/net/wireless/b43/dma.c
@@ -439,9 +439,14 @@ static void * b43_get_and_map_ringmem(st
dma_addr_t *dmaaddr, size_t size)
{
void *base;
+ gfp_t flags = GFP_KERNEL;
+ if (unlikely(ring->type == B43_DMA_30BIT))
+ flags |= GFP_DMA;
+ else if (unlikely(ring->type == B43_DMA_32BIT))
+ flags |= GFP_DMA32;
base = __b43_get_and_map_ringmem(ring, dmaaddr, size,
- GFP_KERNEL);
+ flags);
if (!base) {
b43err(ring->dev->wl, "Failed to allocate or map pages "
"for DMA ringmemory\n");
Comments?
For 2.6.34, a more complete rework is probably needed.
Larry
_______________________________________________
Bcm43xx-dev mailing list
[email protected]
https://lists.berlios.de/mailman/listinfo/bcm43xx-dev