diff mbox series

[2/7] at76c50x-usb: fix endpoint debug message

Message ID 20191210114426.4713-3-johan@kernel.org (mailing list archive)
State Mainlined
Commit af615abd15966387393471649185d15954e9cecd
Headers show
Series wireless: fix USB altsetting bugs | expand

Commit Message

Johan Hovold Dec. 10, 2019, 11:44 a.m. UTC
Make sure to use the current alternate setting, which may not be the
same as the first alternate setting, also when printing the number of
endpoints at probe.

Signed-off-by: Johan Hovold <johan@kernel.org>
---
 drivers/net/wireless/atmel/at76c50x-usb.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

Comments

Kalle Valo Dec. 18, 2019, 7:06 p.m. UTC | #1
Johan Hovold <johan@kernel.org> wrote:

> Make sure to use the current alternate setting, which may not be the
> same as the first alternate setting, also when printing the number of
> endpoints at probe.
> 
> Signed-off-by: Johan Hovold <johan@kernel.org>

6 patches applied to wireless-drivers-next.git, thanks.

af615abd1596 at76c50x-usb: fix endpoint debug message
3428fbcd6e6c brcmfmac: fix interface sanity check
b73e05aa543c orinoco_usb: fix interface sanity check
39a4281c312f rtl8xxxu: fix interface sanity check
3139b180906a rsi_91x_usb: fix interface sanity check
2d68bb2687ab zd1211rw: fix storage endpoint lookup
diff mbox series

Patch

diff --git a/drivers/net/wireless/atmel/at76c50x-usb.c b/drivers/net/wireless/atmel/at76c50x-usb.c
index db2c3b8d491e..3b2680772f03 100644
--- a/drivers/net/wireless/atmel/at76c50x-usb.c
+++ b/drivers/net/wireless/atmel/at76c50x-usb.c
@@ -2236,7 +2236,7 @@  static int at76_alloc_urbs(struct at76_priv *priv,
 	at76_dbg(DBG_PROC_ENTRY, "%s: ENTER", __func__);
 
 	at76_dbg(DBG_URB, "%s: NumEndpoints %d ", __func__,
-		 interface->altsetting[0].desc.bNumEndpoints);
+		 interface->cur_altsetting->desc.bNumEndpoints);
 
 	ep_in = NULL;
 	ep_out = NULL;