All of lore.kernel.org
 help / color / mirror / Atom feed
From: Oliver Neukum <oneukum@suse.com>
To: Greg KH <gregKH@linuxfoundation.org>
Cc: linux-usb@vger.kernel.org, stable@vger.kernel.org
Subject: usb: uas: unconditionally bring back host after reset
Date: Thu, 11 Jan 2018 13:10:00 +0100	[thread overview]
Message-ID: <1515672600.5798.15.camel@suse.com> (raw)

Am Donnerstag, den 11.01.2018, 12:22 +0100 schrieb Greg KH:
> On Thu, Jan 11, 2018 at 11:59:54AM +0100, Oliver Neukum wrote:
> > 
> > Quoting Hans:
> > 
> > If we return 1 from our post_reset handler, then our disconnect handler
> > will be called immediately afterwards. Since pre_reset blocks all scsi
> > requests our disconnect handler will then hang in the scsi_remove_host
> > call.
> > 
> > This is esp. bad because our disconnect handler hanging for ever also
> > stops the USB subsys from enumerating any new USB devices, causes commands
> > like lsusb to hang, etc.
> > 
> > In practice this happens when unplugging some uas devices because the hub
> > code may see the device as needing a warm-reset and calls usb_reset_device
> > before seeing the disconnect. In this case uas_configure_endpoints fails
> > with -ENODEV. We do not want to print an error for this, so this commit
> > also silences the shost_printk for -ENODEV.
> > 
> > ENDQUOTE
> > 
> > However, if we do that we better drop any unconditional execution
> > and report to the SCSI subsystem that we have undergone a reset
> > but we are not operational now.
> > 
> > Signed-off-by: Oliver Neukum <oneukum@suse.com>
> > Reported-by: Hans de Goede <hdegoede@redhat.com>
> > CC: stable@vger.kernel.org
> > ---
> >  Makefile                  | 2 +-
> 
> I don't think you want me to patch this file :)

Hi,

sorry, yes, I do not want you to do that.

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

WARNING: multiple messages have this Message-ID (diff)
From: Oliver Neukum <oneukum@suse.com>
To: Greg KH <gregKH@linuxfoundation.org>
Cc: linux-usb@vger.kernel.org, stable@vger.kernel.org
Subject: Re: [PATCH] usb: uas: unconditionally bring back host after reset
Date: Thu, 11 Jan 2018 13:10:00 +0100	[thread overview]
Message-ID: <1515672600.5798.15.camel@suse.com> (raw)
In-Reply-To: <20180111112234.GA16268@kroah.com>

Am Donnerstag, den 11.01.2018, 12:22 +0100 schrieb Greg KH:
> On Thu, Jan 11, 2018 at 11:59:54AM +0100, Oliver Neukum wrote:
> > 
> > Quoting Hans:
> > 
> > If we return 1 from our post_reset handler, then our disconnect handler
> > will be called immediately afterwards. Since pre_reset blocks all scsi
> > requests our disconnect handler will then hang in the scsi_remove_host
> > call.
> > 
> > This is esp. bad because our disconnect handler hanging for ever also
> > stops the USB subsys from enumerating any new USB devices, causes commands
> > like lsusb to hang, etc.
> > 
> > In practice this happens when unplugging some uas devices because the hub
> > code may see the device as needing a warm-reset and calls usb_reset_device
> > before seeing the disconnect. In this case uas_configure_endpoints fails
> > with -ENODEV. We do not want to print an error for this, so this commit
> > also silences the shost_printk for -ENODEV.
> > 
> > ENDQUOTE
> > 
> > However, if we do that we better drop any unconditional execution
> > and report to the SCSI subsystem that we have undergone a reset
> > but we are not operational now.
> > 
> > Signed-off-by: Oliver Neukum <oneukum@suse.com>
> > Reported-by: Hans de Goede <hdegoede@redhat.com>
> > CC: stable@vger.kernel.org
> > ---
> >  Makefile                  | 2 +-
> 
> I don't think you want me to patch this file :)

Hi,

sorry, yes, I do not want you to do that.

	Sorry
		Oliver

             reply	other threads:[~2018-01-11 12:10 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-01-11 12:10 Oliver Neukum [this message]
2018-01-11 12:10 ` [PATCH] usb: uas: unconditionally bring back host after reset Oliver Neukum
  -- strict thread matches above, loose matches on Subject: below --
2018-01-11 12:10 Oliver Neukum
2018-01-11 11:22 Greg Kroah-Hartman
2018-01-11 11:22 ` [PATCH] " Greg KH
2018-01-11 10:59 Oliver Neukum
2018-01-11 10:59 ` [PATCH] " Oliver Neukum

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=1515672600.5798.15.camel@suse.com \
    --to=oneukum@suse.com \
    --cc=gregKH@linuxfoundation.org \
    --cc=linux-usb@vger.kernel.org \
    --cc=stable@vger.kernel.org \
    /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.