Received: by 2002:a05:6358:1087:b0:cb:c9d3:cd90 with SMTP id j7csp3236074rwi; Fri, 28 Oct 2022 18:20:36 -0700 (PDT) X-Google-Smtp-Source: AMsMyM6S42JGxokwjbD3sjGuDccvM6JoSLEoo4HSdtGo3RDM/jOI6sbCtF1ZnMcGVP+wF84pjlMb X-Received: by 2002:aa7:df94:0:b0:461:aff8:d3e1 with SMTP id b20-20020aa7df94000000b00461aff8d3e1mr2166552edy.10.1667006436268; Fri, 28 Oct 2022 18:20:36 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1667006436; cv=none; d=google.com; s=arc-20160816; b=Ayi7UNdRzQxQMhN9P51AXbxxzzhBkdBuRDDg3aKw+HmQBL+1e1Hj6/SL//Uq7bcG6i M3xRA1w6lAG/4NLY3yptQM2jRrHGCBg7hPwjfwQsKbeLVvDyvFnuNJvHXrYL7CXoD/6W NzqwelIsev+KNswTScJKjfQORCFZSfJLtqaNpNzkIlmGyqzO9bEj3IIRdiHf9/UA5LPH y/e6NaTFgmo9MH+q23M34/owRK1Hf3rO6K/D9hay6qrCRf0AyJATebNTosMO84sATIso JUThLXB+DLPpiYwxWE/mjF61aBoeXhmvUxxKyerkEE8BCAvpXuqykE0gBgomo395QpT1 E+zQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:in-reply-to:content-disposition:mime-version :references:message-id:subject:cc:to:from:date; bh=7NDSNmSrmnAj73iEmQGLM1UqgO6C3xJ2gx8C61Q2fJM=; b=HY7kYBEwmeIGsf0cbF1mb/4kodoXfoWp3bDH9xEkWnLUnWlP54L26ZZv3wL0NWXbIC GzlMl4h2oEkzm/Fu/j/JvBqhRfFVFze+pLCAzg/UmKtekZfw0bDeN0yZ53THJ2jLy2SK Re1r1kaSoadMjwfKp1tU59upffA68DNK1/KqMay7UP0pXA/UcI/9q8rEGc9AIEbl8y5K 3uxmMnvfhlGYZDAsXtO/owIT6ooceMOutMUCPd0HLYycdt2/cL447ebYySlrFiYd8Gte ngpRXix5JeHuP8kLEsWB9zty0obgDlCdRQVWC2DzmMBqHzeQeBmCxB93XReb1oUH0H8S ARkg== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id hd43-20020a17090796ab00b0078bcc872a6esi272497ejc.360.2022.10.28.18.20.11; Fri, 28 Oct 2022 18:20:36 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229692AbiJ2BNS (ORCPT + 99 others); Fri, 28 Oct 2022 21:13:18 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:35752 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229678AbiJ2BNR (ORCPT ); Fri, 28 Oct 2022 21:13:17 -0400 Received: from netrider.rowland.org (netrider.rowland.org [192.131.102.5]) by lindbergh.monkeyblade.net (Postfix) with SMTP id CEC781D4406 for ; Fri, 28 Oct 2022 18:13:15 -0700 (PDT) Received: (qmail 100580 invoked by uid 1000); 28 Oct 2022 21:13:14 -0400 Date: Fri, 28 Oct 2022 21:13:14 -0400 From: Alan Stern To: Brian Norris Cc: Greg Kroah-Hartman , Mathias Nyman , linux-kernel@vger.kernel.org, linux-usb@vger.kernel.org Subject: Re: [PATCH 1/2] usb: ehci-pci: Set PROBE_PREFER_ASYNCHRONOUS Message-ID: References: <20221028141821.1.I9a5353f81d1509f85f3a04f0cdc9099f6fe60811@changeid> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20221028141821.1.I9a5353f81d1509f85f3a04f0cdc9099f6fe60811@changeid> X-Spam-Status: No, score=-1.7 required=5.0 tests=BAYES_00, HEADER_FROM_DIFFERENT_DOMAINS,SPF_HELO_PASS,SPF_PASS autolearn=no autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Fri, Oct 28, 2022 at 02:19:07PM -0700, Brian Norris wrote: > This driver often takes on the order of 8ms to start, but every little > bit counts. It shouldn't have many cross-device dependencies to > race with, nor racy access to shared state with other drivers, so this > should be a relatively low risk change. > > This driver was pinpointed as part of a survey of top slowest initcalls > (i.e., are built in, and probing synchronously) on a lab of ChromeOS > systems. > > Signed-off-by: Brian Norris > --- Acked-by: Alan Stern However, I'm curious to know why this patch makes ehci-pci use PROBE_PREFER_ASYNCHRONOUS even when CONFIG_PM isn't set, whereas the 2/2 patch makes xhci-pci use PROBE_PREFER_ASYNCHRONOUS only when CONFIG_PM is set. Alan Stern > drivers/usb/host/ehci-pci.c | 7 ++++--- > 1 file changed, 4 insertions(+), 3 deletions(-) > > diff --git a/drivers/usb/host/ehci-pci.c b/drivers/usb/host/ehci-pci.c > index 17f8b6ea0c35..4b148fe5e43b 100644 > --- a/drivers/usb/host/ehci-pci.c > +++ b/drivers/usb/host/ehci-pci.c > @@ -411,11 +411,12 @@ static struct pci_driver ehci_pci_driver = { > .remove = ehci_pci_remove, > .shutdown = usb_hcd_pci_shutdown, > > -#ifdef CONFIG_PM > .driver = { > - .pm = &usb_hcd_pci_pm_ops > - }, > +#ifdef CONFIG_PM > + .pm = &usb_hcd_pci_pm_ops, > #endif > + .probe_type = PROBE_PREFER_ASYNCHRONOUS, > + }, > }; > > static int __init ehci_pci_init(void) > -- > 2.38.1.273.g43a17bfeac-goog >