All of lore.kernel.org
 help / color / mirror / Atom feed
From: John W. Linville <linville@tuxdriver.com>
To: "Rafał Miłecki" <zajec5@gmail.com>
Cc: linux-wireless@vger.kernel.org, b43-dev@lists.infradead.org
Subject: [PATCH V2] b43: disable parity check on BCMA devices
Date: Thu, 21 Jul 2011 15:06:48 -0400	[thread overview]
Message-ID: <20110721190648.GC2468@tuxdriver.com> (raw)
In-Reply-To: <1311184027-3497-1-git-send-email-zajec5@gmail.com>

On Wed, Jul 20, 2011 at 07:47:07PM +0200, Rafa? Mi?ecki wrote:
> Analyze of MMIO dumps from BCM43224, BCM43225, BCM4313 and BCM4331 has
> shown that wl disables parity check for all that cards. This is required
> for receiving any packets from the hardware.
> 
> Signed-off-by: Rafa? Mi?ecki <zajec5@gmail.com>
> ---
> V2: drop dependency on other patches, can be applied right away

> @@ -1069,6 +1078,11 @@ int b43_dma_init(struct b43_wldev *dev)
>  #endif
>  	}
>  
> +	dma->parity = true;
> +	/* TODO: find out which SSB devices need disabling parity */
> +	if (dev->dev->bus_type == B43_BUS_BCMA)
> +		dma->parity = false;
> +
>  	err = -ENOMEM;
>  	/* setup TX DMA channels. */
>  	dma->tx_ring_AC_BK = b43_setup_dmaring(dev, 0, 1, type);

drivers/net/wireless/b43/dma.c: In function ?b43_dma_init?:
drivers/net/wireless/b43/dma.c:1083:28: error: ?B43_BUS_BCMA? undeclared (first use in this function)
drivers/net/wireless/b43/dma.c:1083:28: note: each undeclared identifier is reported only once for each function it appears in
make[2]: *** [drivers/net/wireless/b43/dma.o] Error 1
make[1]: *** [drivers/net/wireless/b43] Error 2
make: *** [drivers/net/wireless/] Error 2

I fixed it up with a change like this:

diff --git a/drivers/net/wireless/b43/dma.c b/drivers/net/wireless/b43/dma.c
index 2e072f6..0953ce1 100644
--- a/drivers/net/wireless/b43/dma.c
+++ b/drivers/net/wireless/b43/dma.c
@@ -1079,9 +1079,11 @@ int b43_dma_init(struct b43_wldev *dev)
 	}
 
 	dma->parity = true;
+#ifdef CONFIG_B43_BCMA
 	/* TODO: find out which SSB devices need disabling parity */
 	if (dev->dev->bus_type == B43_BUS_BCMA)
 		dma->parity = false;
+#endif
 
 	err = -ENOMEM;
 	/* setup TX DMA channels. */

Please do be careful...

John
-- 
John W. Linville		Someday the world will need a hero, and you
linville at tuxdriver.com			might be all we have.  Be ready.

WARNING: multiple messages have this Message-ID (diff)
From: "John W. Linville" <linville@tuxdriver.com>
To: "Rafał Miłecki" <zajec5@gmail.com>
Cc: linux-wireless@vger.kernel.org, b43-dev@lists.infradead.org
Subject: Re: [PATCH V2] b43: disable parity check on BCMA devices
Date: Thu, 21 Jul 2011 15:06:48 -0400	[thread overview]
Message-ID: <20110721190648.GC2468@tuxdriver.com> (raw)
In-Reply-To: <1311184027-3497-1-git-send-email-zajec5@gmail.com>

On Wed, Jul 20, 2011 at 07:47:07PM +0200, Rafał Miłecki wrote:
> Analyze of MMIO dumps from BCM43224, BCM43225, BCM4313 and BCM4331 has
> shown that wl disables parity check for all that cards. This is required
> for receiving any packets from the hardware.
> 
> Signed-off-by: Rafał Miłecki <zajec5@gmail.com>
> ---
> V2: drop dependency on other patches, can be applied right away

> @@ -1069,6 +1078,11 @@ int b43_dma_init(struct b43_wldev *dev)
>  #endif
>  	}
>  
> +	dma->parity = true;
> +	/* TODO: find out which SSB devices need disabling parity */
> +	if (dev->dev->bus_type == B43_BUS_BCMA)
> +		dma->parity = false;
> +
>  	err = -ENOMEM;
>  	/* setup TX DMA channels. */
>  	dma->tx_ring_AC_BK = b43_setup_dmaring(dev, 0, 1, type);

drivers/net/wireless/b43/dma.c: In function ‘b43_dma_init’:
drivers/net/wireless/b43/dma.c:1083:28: error: ‘B43_BUS_BCMA’ undeclared (first use in this function)
drivers/net/wireless/b43/dma.c:1083:28: note: each undeclared identifier is reported only once for each function it appears in
make[2]: *** [drivers/net/wireless/b43/dma.o] Error 1
make[1]: *** [drivers/net/wireless/b43] Error 2
make: *** [drivers/net/wireless/] Error 2

I fixed it up with a change like this:

diff --git a/drivers/net/wireless/b43/dma.c b/drivers/net/wireless/b43/dma.c
index 2e072f6..0953ce1 100644
--- a/drivers/net/wireless/b43/dma.c
+++ b/drivers/net/wireless/b43/dma.c
@@ -1079,9 +1079,11 @@ int b43_dma_init(struct b43_wldev *dev)
 	}
 
 	dma->parity = true;
+#ifdef CONFIG_B43_BCMA
 	/* TODO: find out which SSB devices need disabling parity */
 	if (dev->dev->bus_type == B43_BUS_BCMA)
 		dma->parity = false;
+#endif
 
 	err = -ENOMEM;
 	/* setup TX DMA channels. */

Please do be careful...

John
-- 
John W. Linville		Someday the world will need a hero, and you
linville@tuxdriver.com			might be all we have.  Be ready.

  reply	other threads:[~2011-07-21 19:06 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-07-20 17:47 [PATCH V2] b43: disable parity check on BCMA devices Rafał Miłecki
2011-07-20 17:47 ` Rafał Miłecki
2011-07-21 19:06 ` John W. Linville [this message]
2011-07-21 19:06   ` John W. Linville

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20110721190648.GC2468@tuxdriver.com \
    --to=linville@tuxdriver.com \
    --cc=b43-dev@lists.infradead.org \
    --cc=linux-wireless@vger.kernel.org \
    --cc=zajec5@gmail.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.