Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.kernel > #1404283 > unrolled thread

[PATCH 1/1] usbip: don't call stub_device_reset() during stub_disconnect()

Started byAlexander Popov <alpopov@ptsecurity.com>
First post2016-05-20 11:40 +0200
Last post2016-05-27 18:20 +0200
Articles 3 — 2 participants

Back to article view | Back to linux.kernel


Contents

  [PATCH 1/1] usbip: don't call stub_device_reset() during stub_disconnect() Alexander Popov <alpopov@ptsecurity.com> - 2016-05-20 11:40 +0200
    Re: [PATCH 1/1] usbip: don't call stub_device_reset() during  stub_disconnect() Alexander Popov <alpopov@ptsecurity.com> - 2016-05-27 16:30 +0200
      Re: [PATCH 1/1] usbip: don't call stub_device_reset() during  stub_disconnect() Greg Kroah-Hartman <gregkh@linuxfoundation.org> - 2016-05-27 18:20 +0200

#1404283 — [PATCH 1/1] usbip: don't call stub_device_reset() during stub_disconnect()

FromAlexander Popov <alpopov@ptsecurity.com>
Date2016-05-20 11:40 +0200
Subject[PATCH 1/1] usbip: don't call stub_device_reset() during stub_disconnect()
Message-ID<rAP4t-3Mf-17@gated-at.bofh.it>
stub_disconnect() calls stub_device_reset() during usb_unbind_device() when
usb device is locked. So usb_lock_device_for_reset() in stub_device_reset()
in that case polls for one second and returns -EBUSY anyway.

Remove useless flag USBIP_EH_RESET from SDEV_EVENT_REMOVED.

Signed-off-by: Alexander Popov <alpopov@ptsecurity.com>
---
 drivers/usb/usbip/usbip_common.h | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/usb/usbip/usbip_common.h b/drivers/usb/usbip/usbip_common.h
index 86b0847..c4b4938 100644
--- a/drivers/usb/usbip/usbip_common.h
+++ b/drivers/usb/usbip/usbip_common.h
@@ -242,7 +242,7 @@ enum usbip_side {
 #define USBIP_EH_RESET		(1 << 2)
 #define USBIP_EH_UNUSABLE	(1 << 3)
 
-#define SDEV_EVENT_REMOVED   (USBIP_EH_SHUTDOWN | USBIP_EH_RESET | USBIP_EH_BYE)
+#define	SDEV_EVENT_REMOVED	(USBIP_EH_SHUTDOWN | USBIP_EH_BYE)
 #define	SDEV_EVENT_DOWN		(USBIP_EH_SHUTDOWN | USBIP_EH_RESET)
 #define	SDEV_EVENT_ERROR_TCP	(USBIP_EH_SHUTDOWN | USBIP_EH_RESET)
 #define	SDEV_EVENT_ERROR_SUBMIT	(USBIP_EH_SHUTDOWN | USBIP_EH_RESET)
-- 
1.9.1

[toc] | [next] | [standalone]


#1408112 — Re: [PATCH 1/1] usbip: don't call stub_device_reset() during stub_disconnect()

FromAlexander Popov <alpopov@ptsecurity.com>
Date2016-05-27 16:30 +0200
SubjectRe: [PATCH 1/1] usbip: don't call stub_device_reset() during stub_disconnect()
Message-ID<rDqW2-4AO-11@gated-at.bofh.it>
In reply to#1404283
Hello,

Excuse me for disturbing, could I have a feedback?

On 20.05.2016 12:37, Alexander Popov wrote:
> stub_disconnect() calls stub_device_reset() during usb_unbind_device() when
> usb device is locked. So usb_lock_device_for_reset() in stub_device_reset()
> in that case polls for one second and returns -EBUSY anyway.
> 
> Remove useless flag USBIP_EH_RESET from SDEV_EVENT_REMOVED.
> 
> Signed-off-by: Alexander Popov <alpopov@ptsecurity.com>
> ---
>  drivers/usb/usbip/usbip_common.h | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/drivers/usb/usbip/usbip_common.h b/drivers/usb/usbip/usbip_common.h
> index 86b0847..c4b4938 100644
> --- a/drivers/usb/usbip/usbip_common.h
> +++ b/drivers/usb/usbip/usbip_common.h
> @@ -242,7 +242,7 @@ enum usbip_side {
>  #define USBIP_EH_RESET		(1 << 2)
>  #define USBIP_EH_UNUSABLE	(1 << 3)
>  
> -#define SDEV_EVENT_REMOVED   (USBIP_EH_SHUTDOWN | USBIP_EH_RESET | USBIP_EH_BYE)
> +#define	SDEV_EVENT_REMOVED	(USBIP_EH_SHUTDOWN | USBIP_EH_BYE)
>  #define	SDEV_EVENT_DOWN		(USBIP_EH_SHUTDOWN | USBIP_EH_RESET)
>  #define	SDEV_EVENT_ERROR_TCP	(USBIP_EH_SHUTDOWN | USBIP_EH_RESET)
>  #define	SDEV_EVENT_ERROR_SUBMIT	(USBIP_EH_SHUTDOWN | USBIP_EH_RESET)
> 

[toc] | [prev] | [next] | [standalone]


#1408165 — Re: [PATCH 1/1] usbip: don't call stub_device_reset() during stub_disconnect()

FromGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Date2016-05-27 18:20 +0200
SubjectRe: [PATCH 1/1] usbip: don't call stub_device_reset() during stub_disconnect()
Message-ID<rDsEq-5Ht-19@gated-at.bofh.it>
In reply to#1408112
On Fri, May 27, 2016 at 05:20:45PM +0300, Alexander Popov wrote:
> Hello,
> 
> Excuse me for disturbing, could I have a feedback?

Nope, it's the middle of the merge window, I can't do anything with new
patches until after 4.7-rc1 comes out.  And even then, give me a week or
so to catch up...

thanks,

greg k-h

[toc] | [prev] | [standalone]


Back to top | Article view | linux.kernel


csiph-web