Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S964987Ab2JCQBZ (ORCPT ); Wed, 3 Oct 2012 12:01:25 -0400 Received: from iolanthe.rowland.org ([192.131.102.54]:51427 "HELO iolanthe.rowland.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with SMTP id S932607Ab2JCQBX (ORCPT ); Wed, 3 Oct 2012 12:01:23 -0400 Date: Wed, 3 Oct 2012 12:01:22 -0400 (EDT) From: Alan Stern X-X-Sender: stern@iolanthe.rowland.org To: Florian Fainelli cc: linux-usb@vger.kernel.org, Ralf Baechle , Greg Kroah-Hartman , Gabor Juhos , Hauke Mehrtens , Kelvin Cheung , Jayachandran C , Dan Carpenter , Geert Uytterhoeven , , Subject: Re: [PATCH 06/25] USB: ehci: allow need_io_watchdog to be passed to ehci-platform driver In-Reply-To: <1349276601-8371-7-git-send-email-florian@openwrt.org> Message-ID: MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 2409 Lines: 58 On Wed, 3 Oct 2012, Florian Fainelli wrote: > And convert all the existing users of ehci-platform to specify a correct > need_io_watchdog value. IMO (and I realize that not everybody agrees), the patch description should not be considered an extension of the patch title, as though the title were the first sentence and the description the remainder of the same paragraph. Descriptions should stand on their own and be comprehensible even to somebody who hasn't read the title. > Signed-off-by: Florian Fainelli > --- > arch/mips/ath79/dev-usb.c | 2 ++ > arch/mips/loongson1/common/platform.c | 1 + > arch/mips/netlogic/xlr/platform.c | 1 + > drivers/usb/host/bcma-hcd.c | 1 + > drivers/usb/host/ehci-platform.c | 1 + > drivers/usb/host/ssb-hcd.c | 1 + > include/linux/usb/ehci_pdriver.h | 3 +++ > 7 files changed, 10 insertions(+) More importantly... Nearly every driver will have need_io_watchdog set. Only a few of them explicitly turn it off. The approach you're using puts an extra burden on most of the drivers. > diff --git a/drivers/usb/host/ehci-platform.c b/drivers/usb/host/ehci-platform.c > index 764e010..08d5dec 100644 > --- a/drivers/usb/host/ehci-platform.c > +++ b/drivers/usb/host/ehci-platform.c > @@ -32,6 +32,7 @@ static int ehci_platform_reset(struct usb_hcd *hcd) > ehci->has_synopsys_hc_bug = pdata->has_synopsys_hc_bug; > ehci->big_endian_desc = pdata->big_endian_desc; > ehci->big_endian_mmio = pdata->big_endian_mmio; > + ehci->need_io_watchdog = pdata->need_io_watchdog; > --- a/include/linux/usb/ehci_pdriver.h > +++ b/include/linux/usb/ehci_pdriver.h > @@ -29,6 +29,8 @@ > * initialization. > * @port_power_off: set to 1 if the controller needs to be powered down > * after initialization. > + * @need_io_watchdog: set to 1 if the controller needs the I/O watchdog to > + * run. Instead, how about adding a no_io_watchdog flag? Then after ehci-platform.c calls ehci_setup(), it can see whether to turn off ehci->need_io_watchdog. This way, most of this patch would become unnecessary. Alan Stern -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/