netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH net-next] usbnet: use netif_tx_wake_queue instead of netif_start_queue
@ 2012-03-14 14:00 Alexey Orishko
       [not found] ` <1331733624-23266-1-git-send-email-alexey.orishko-0IS4wlFg1OjSUeElwK9/Pw@public.gmane.org>
  0 siblings, 1 reply; 3+ messages in thread
From: Alexey Orishko @ 2012-03-14 14:00 UTC (permalink / raw)
  To: netdev-u79uwXL29TY76Z2rM5mHXA, davem-fT/PcQaiUtIeIZ0/mPfg9Q,
	oliver-GvhC2dPhHPQdnm+yROfE0A
  Cc: linux-usb-u79uwXL29TY76Z2rM5mHXA, gregkh-l3A5Bk7waGM, Alexey Orishko

If host is going to autosuspend function with two interfaces and
if IP packet has arrived in-between of two usbnet_suspend() callbacks,
i.e usbnet_resume() is called in-between, tx data flow is stopped.
When autosuspend timer expires and device is put to autosuspend
again, tx queue is waked up and data can be sent again.
This behavior might be repeated several times in a row.

Tested on Intel/ARM.

Reviewed-by: Sjur Brændeland <sjur.brandeland-0IS4wlFg1OjSUeElwK9/Pw@public.gmane.org>
Tested-by: Dmitry Tarnyagin <dmitry.tarnyagin-0IS4wlFg1OjSUeElwK9/Pw@public.gmane.org>
Signed-off-by: Alexey Orishko <alexey.orishko-0IS4wlFg1OjSUeElwK9/Pw@public.gmane.org>
---
 drivers/net/usb/usbnet.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/drivers/net/usb/usbnet.c b/drivers/net/usb/usbnet.c
index 83dcc53..5394b4e 100644
--- a/drivers/net/usb/usbnet.c
+++ b/drivers/net/usb/usbnet.c
@@ -1535,7 +1535,7 @@ int usbnet_resume (struct usb_interface *intf)
 
 		if (test_bit(EVENT_DEV_OPEN, &dev->flags)) {
 			if (!(dev->txq.qlen >= TX_QLEN(dev)))
-				netif_start_queue(dev->net);
+				netif_tx_wake_all_queues(dev->net);
 			tasklet_schedule (&dev->bh);
 		}
 	}
-- 
1.7.4.1

--
To unsubscribe from this list: send the line "unsubscribe linux-usb" in
the body of a message to majordomo-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

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

* Re: [PATCH net-next] usbnet: use netif_tx_wake_queue instead of netif_start_queue
       [not found] ` <1331733624-23266-1-git-send-email-alexey.orishko-0IS4wlFg1OjSUeElwK9/Pw@public.gmane.org>
@ 2012-03-15 17:05   ` Oliver Neukum
  2012-03-17  5:50     ` David Miller
  0 siblings, 1 reply; 3+ messages in thread
From: Oliver Neukum @ 2012-03-15 17:05 UTC (permalink / raw)
  To: Alexey Orishko
  Cc: netdev-u79uwXL29TY76Z2rM5mHXA, davem-fT/PcQaiUtIeIZ0/mPfg9Q,
	linux-usb-u79uwXL29TY76Z2rM5mHXA, greg-U8xfFu+wG4EAvxtiuMwx3w,
	Alexey Orishko

Am Mittwoch, 14. März 2012, 15:00:24 schrieb Alexey Orishko:
> If host is going to autosuspend function with two interfaces and
> if IP packet has arrived in-between of two usbnet_suspend() callbacks,
> i.e usbnet_resume() is called in-between, tx data flow is stopped.
> When autosuspend timer expires and device is put to autosuspend
> again, tx queue is waked up and data can be sent again.
> This behavior might be repeated several times in a row.
> 
> Tested on Intel/ARM.
> 
> Reviewed-by: Sjur Brændeland <sjur.brandeland-0IS4wlFg1OjSUeElwK9/Pw@public.gmane.org>
> Tested-by: Dmitry Tarnyagin <dmitry.tarnyagin-0IS4wlFg1OjSUeElwK9/Pw@public.gmane.org>
> Signed-off-by: Alexey Orishko <alexey.orishko-0IS4wlFg1OjSUeElwK9/Pw@public.gmane.org>
Acked-by: Oliver Neukum <oneukum-l3A5Bk7waGM@public.gmane.org>
--
To unsubscribe from this list: send the line "unsubscribe linux-usb" in
the body of a message to majordomo-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

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

* Re: [PATCH net-next] usbnet: use netif_tx_wake_queue instead of netif_start_queue
  2012-03-15 17:05   ` Oliver Neukum
@ 2012-03-17  5:50     ` David Miller
  0 siblings, 0 replies; 3+ messages in thread
From: David Miller @ 2012-03-17  5:50 UTC (permalink / raw)
  To: oneukum; +Cc: alexey.orishko, netdev, linux-usb, greg, alexey.orishko

From: Oliver Neukum <oneukum@suse.de>
Date: Thu, 15 Mar 2012 18:05:09 +0100

> Am Mittwoch, 14. März 2012, 15:00:24 schrieb Alexey Orishko:
>> If host is going to autosuspend function with two interfaces and
>> if IP packet has arrived in-between of two usbnet_suspend() callbacks,
>> i.e usbnet_resume() is called in-between, tx data flow is stopped.
>> When autosuspend timer expires and device is put to autosuspend
>> again, tx queue is waked up and data can be sent again.
>> This behavior might be repeated several times in a row.
>> 
>> Tested on Intel/ARM.
>> 
>> Reviewed-by: Sjur Brændeland <sjur.brandeland@stericsson.com>
>> Tested-by: Dmitry Tarnyagin <dmitry.tarnyagin@stericsson.com>
>> Signed-off-by: Alexey Orishko <alexey.orishko@stericsson.com>
> Acked-by: Oliver Neukum <oneukum@suse.de>

Applied, thanks.

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

end of thread, other threads:[~2012-03-17  5:51 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2012-03-14 14:00 [PATCH net-next] usbnet: use netif_tx_wake_queue instead of netif_start_queue Alexey Orishko
     [not found] ` <1331733624-23266-1-git-send-email-alexey.orishko-0IS4wlFg1OjSUeElwK9/Pw@public.gmane.org>
2012-03-15 17:05   ` Oliver Neukum
2012-03-17  5:50     ` David Miller

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).