From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-1.0 required=3.0 tests=HEADER_FROM_DIFFERENT_DOMAINS, MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS,URIBL_BLOCKED autolearn=unavailable autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id A1E8AC2BCA1 for ; Fri, 7 Jun 2019 14:01:36 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id 8572B208E3 for ; Fri, 7 Jun 2019 14:01:36 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1729273AbfFGOBb (ORCPT ); Fri, 7 Jun 2019 10:01:31 -0400 Received: from iolanthe.rowland.org ([192.131.102.54]:34720 "HELO iolanthe.rowland.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with SMTP id S1729237AbfFGOBb (ORCPT ); Fri, 7 Jun 2019 10:01:31 -0400 Received: (qmail 1660 invoked by uid 2102); 7 Jun 2019 10:01:30 -0400 Received: from localhost (sendmail-bs@127.0.0.1) by localhost with SMTP; 7 Jun 2019 10:01:30 -0400 Date: Fri, 7 Jun 2019 10:01:30 -0400 (EDT) From: Alan Stern X-X-Sender: stern@iolanthe.rowland.org To: Felipe Balbi cc: Greg Kroah-Hartman , David Howells , , , , , , , , , Subject: Re: [PATCH 09/10] usb: Add USB subsystem notifications [ver #3] In-Reply-To: <87imthdhjb.fsf@linux.intel.com> Message-ID: MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII Sender: linux-fsdevel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-fsdevel@vger.kernel.org On Fri, 7 Jun 2019, Felipe Balbi wrote: > Hi, > > Greg Kroah-Hartman writes: > > On Thu, Jun 06, 2019 at 10:55:24AM -0400, Alan Stern wrote: > >> On Thu, 6 Jun 2019, Greg Kroah-Hartman wrote: > >> > >> > On Thu, Jun 06, 2019 at 10:24:18AM -0400, Alan Stern wrote: > >> > > On Thu, 6 Jun 2019, David Howells wrote: > >> > > > >> > > > Add a USB subsystem notification mechanism whereby notifications about > >> > > > hardware events such as device connection, disconnection, reset and I/O > >> > > > errors, can be reported to a monitoring process asynchronously. > >> > > > >> > > USB I/O errors covers an awfully large and vague field. Do we really > >> > > want to include them? I'm doubtful. > >> > > >> > See the other patch on the linux-usb list that wanted to start adding > >> > KOBJ_CHANGE notifications about USB "i/o errors". > >> > >> That patch wanted to add notifications only for enumeration failures > >> (assuming you're talking about the patch from Eugeniu Rosca), not I/O > >> errors in general. > > > > Yes, sorry, I was thinking that as a "I/O failed in enumeration" :) > > > >> > So for "severe" issues, yes, we should do this, but perhaps not for all > >> > of the "normal" things we see when a device is yanked out of the system > >> > and the like. > >> > >> Then what counts as a "severe" issue? Anything besides enumeration > >> failure? > > > > Not that I can think of at the moment, other than the other recently > > added KOBJ_CHANGE issue. I'm sure we have other "hard failure" issues > > in the USB stack that people will want exposed over time. > > From an XHCI standpoint, Transaction Errors might be one thing. They > happen rarely and are a strong indication that the bus itself is > bad. Either bad cable, misbehaving PHYs, improper power management, etc. Don't you also get transaction errors if the user unplugs a device in the middle of a transfer? That's not the sort of thing we want to sent notifications about. Alan Stern