linux-wireless.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] setup correct int pipe type in ar9170_usb_exec_cmd
@ 2010-03-26 10:44 Valentin Longchamp
  2010-03-26 20:57 ` Pavel Roskin
  2010-03-27 12:22 ` Christian Lamparter
  0 siblings, 2 replies; 3+ messages in thread
From: Valentin Longchamp @ 2010-03-26 10:44 UTC (permalink / raw)
  To: chunkeey, linux-wireless; +Cc: Valentin Longchamp

An int urb is constructed but we fill it in with a bulk pipe type.

Commit f661c6f8c67bd55e93348f160d590ff9edf08904 implemented a pipe type
check when CONFIG_USB_DEBUG is enabled. The check failed for all the ar9170
usb transfers and the driver could not configure the wifi dongle.

This went unnoticed until now because most people don't have
CONFIG_USB_DEBUG enabled.

Signed-off-by: Valentin Longchamp <valentin.longchamp@epfl.ch>
---
 drivers/net/wireless/ath/ar9170/usb.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/drivers/net/wireless/ath/ar9170/usb.c b/drivers/net/wireless/ath/ar9170/usb.c
index 4e30197..dbde2de 100644
--- a/drivers/net/wireless/ath/ar9170/usb.c
+++ b/drivers/net/wireless/ath/ar9170/usb.c
@@ -416,7 +416,7 @@ static int ar9170_usb_exec_cmd(struct ar9170 *ar, enum ar9170_cmd cmd,
 	spin_unlock_irqrestore(&aru->common.cmdlock, flags);
 
 	usb_fill_int_urb(urb, aru->udev,
-			 usb_sndbulkpipe(aru->udev, AR9170_EP_CMD),
+			 usb_sndintpipe(aru->udev, AR9170_EP_CMD),
 			 aru->common.cmdbuf, plen + 4,
 			 ar9170_usb_tx_urb_complete, NULL, 1);
 
-- 
1.6.3.3


^ permalink raw reply related	[flat|nested] 3+ messages in thread

* Re: [PATCH] setup correct int pipe type in ar9170_usb_exec_cmd
  2010-03-26 10:44 [PATCH] setup correct int pipe type in ar9170_usb_exec_cmd Valentin Longchamp
@ 2010-03-26 20:57 ` Pavel Roskin
  2010-03-27 12:22 ` Christian Lamparter
  1 sibling, 0 replies; 3+ messages in thread
From: Pavel Roskin @ 2010-03-26 20:57 UTC (permalink / raw)
  To: Valentin Longchamp; +Cc: chunkeey, linux-wireless

On Fri, 2010-03-26 at 11:44 +0100, Valentin Longchamp wrote:
> An int urb is constructed but we fill it in with a bulk pipe type.
> 
> Commit f661c6f8c67bd55e93348f160d590ff9edf08904 implemented a pipe type
> check when CONFIG_USB_DEBUG is enabled. The check failed for all the ar9170
> usb transfers and the driver could not configure the wifi dongle.
> 
> This went unnoticed until now because most people don't have
> CONFIG_USB_DEBUG enabled.

Actually, if the code was broken and nobody noticed, do we need it at
all?  ar9170_usb_tx_urb_complete() is an empty function.

Suppose we need it, then maybe we could put some debug code there?  I
think that function has a poor name, it should be something with "cmd",
like ar9170_usb_tx_urb_complete_cmd().

By the way, I think such fixes belong to stable.
 
-- 
Regards,
Pavel Roskin

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: [PATCH] setup correct int pipe type in ar9170_usb_exec_cmd
  2010-03-26 10:44 [PATCH] setup correct int pipe type in ar9170_usb_exec_cmd Valentin Longchamp
  2010-03-26 20:57 ` Pavel Roskin
@ 2010-03-27 12:22 ` Christian Lamparter
  1 sibling, 0 replies; 3+ messages in thread
From: Christian Lamparter @ 2010-03-27 12:22 UTC (permalink / raw)
  To: Valentin Longchamp, linux-wireless

On Friday 26 March 2010 11:44:33 Valentin Longchamp wrote:
> An int urb is constructed but we fill it in with a bulk pipe type.
> 
> Commit f661c6f8c67bd55e93348f160d590ff9edf08904 implemented a pipe type
> check when CONFIG_USB_DEBUG is enabled. The check failed for all the ar9170
> usb transfers and the driver could not configure the wifi dongle.
> 
> This went unnoticed until now because most people don't have
> CONFIG_USB_DEBUG enabled.
> 
> Signed-off-by: Valentin Longchamp <valentin.longchamp@epfl.ch>
> ---
Cc: Stable <stable@kernel.org>
Acked-by: Christian Lamparter <chunkeey@googlemail.com>

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2010-03-27 12:22 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2010-03-26 10:44 [PATCH] setup correct int pipe type in ar9170_usb_exec_cmd Valentin Longchamp
2010-03-26 20:57 ` Pavel Roskin
2010-03-27 12:22 ` Christian Lamparter

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).