Received: by 2002:a6b:500f:0:0:0:0:0 with SMTP id e15csp1031485iob; Fri, 13 May 2022 20:20:23 -0700 (PDT) X-Google-Smtp-Source: ABdhPJzsabG3GsriTVoXp8DdayaGWvekNpqIybUTjtAc5VGBJjEguTp4g2ev2aJ3ZWbecsQlM1lQ X-Received: by 2002:a05:600c:5104:b0:394:7d22:aad8 with SMTP id o4-20020a05600c510400b003947d22aad8mr7140699wms.68.1652498423486; Fri, 13 May 2022 20:20:23 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1652498423; cv=none; d=google.com; s=arc-20160816; b=om5JpHNZoYcJuFxhXH4KLMcWKeL5g1Xm/tYdKGEhyXWQf7k2Psm/mb32AomdI1jG2M 9rNdEo5IpuUkLipCMfKqwTfaWoK4T3TAZSFeXd+P3GxpuDRMZen/AEVEqrFmpmnrq30o HsI+JBh2KvYMx+njSHCCZhDJpLnQjBEQ0fgt5UEkkwzJt+cLnV7raYrvbhlFpFatd3XQ 1FhKDAFMTZxN8amUnlDnoTQ7c3ogkk1NH3nf8aEFulQumSXBzGaY4ycS5Fw8oxC8omEJ M15OUO6UriDgsORmrVbN/3mrTVmXwHCB8/UzRHCU8A9xapSnjHfr72HP9U8yP2S4d9l7 iGkw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:cc:to:subject:message-id:date:from:in-reply-to :references:mime-version:dkim-signature; bh=yncJ85+SIlrUyfibchlOo3nGcBtZSYvrpkr6At33oFM=; b=p3ek40yiag7i6gABxF5aiR8xbtKSOkVy+ZLefgK++OpHzuwdSYan9h6c2/KjZcoSQz KbGQ8gzqL+0DGpJPeUGGD/epsLp0CeiocEgrh8qBh2B4OffsgBl4fXsxdNrow/DIXLl3 OdKyxKXvFbmJ2YDOCeUckVChyuvvjcvFRxD2gGT/g3LNq4sLA0kMbxvqexjPbB7BP/wE F1Z85o0AxV4pR5ZCrjqFFwYgTXGl/J9CvVBCqHlGsYeIHCkS+MiyaDpiAtorDTA+Ws3K P4x/aP9dsvXbKiwhW/PX0VHDU1+7Ktz/UBJpdGf3QeMXTSf6k1ykhMHj6/p3hJ+c3u4B RjsA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@google.com header.s=20210112 header.b=tELgWSqP; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=REJECT sp=REJECT dis=NONE) header.from=google.com Return-Path: Received: from lindbergh.monkeyblade.net (lindbergh.monkeyblade.net. [2620:137:e000::1:18]) by mx.google.com with ESMTPS id y4-20020a056000168400b0020ade3118e6si2664431wrd.234.2022.05.13.20.20.23 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 13 May 2022 20:20:23 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:18 as permitted sender) client-ip=2620:137:e000::1:18; Authentication-Results: mx.google.com; dkim=pass header.i=@google.com header.s=20210112 header.b=tELgWSqP; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=REJECT sp=REJECT dis=NONE) header.from=google.com Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by lindbergh.monkeyblade.net (Postfix) with ESMTP id B378B3F6C85; Fri, 13 May 2022 16:58:25 -0700 (PDT) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1383063AbiEMR0o (ORCPT + 99 others); Fri, 13 May 2022 13:26:44 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:40994 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1382999AbiEMR0b (ORCPT ); Fri, 13 May 2022 13:26:31 -0400 Received: from mail-yw1-x112b.google.com (mail-yw1-x112b.google.com [IPv6:2607:f8b0:4864:20::112b]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 5F79270907 for ; Fri, 13 May 2022 10:26:29 -0700 (PDT) Received: by mail-yw1-x112b.google.com with SMTP id 00721157ae682-2f7d7e3b5bfso97337657b3.5 for ; Fri, 13 May 2022 10:26:29 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20210112; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=yncJ85+SIlrUyfibchlOo3nGcBtZSYvrpkr6At33oFM=; b=tELgWSqPJ2XeK5KWJc0j3Izxo5P0JYNJpS1LDlgAuPlebbh9e6WMDgeVVLegGeIaAG VVkPFzkgs9492PO60P9XWePlc06wmWZFRlwvZJOZcx5xgrMhBpFW0sOXiKbdsVgYAIRK zjP+gEQNqrUKj69da/qFLQkvCuZ4GjCjn29S2q5SXBtTpeqs0++CM4HRgIxA5FD6F1rD PV/soEr2Mv4iexAm30OrWfc/UQepJQ0ZaQQ+CqJ76d1FTyEX4rQxfaOahQA70NByLksO DRAsanWwPBz8CdNJ7IaHIeXq66XPKKcVg1BFmGAU10mdurV7Lixpw2rYJxRhb1PbLjk0 QcmA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=yncJ85+SIlrUyfibchlOo3nGcBtZSYvrpkr6At33oFM=; b=lvGOfySkaCJKUsp6tGknRfQM1NNqP7rvaYr6cw6YEeVFkKUyrQASsiRZ1JeLenFJx/ KQkX//i2LYByxhU4c6xDjOehfNJ5yxh64yE04jQbnYiC+4GlG0bayHUeyNnNwjV5yzyc buhZI9cRX10hp+Mg0GK/wviVQ/Pi36qqcWuLqlJyy9PNKKwVffza6gstjIW6uy8w1Bci w1BT3l4gfy7+1qe2rNaSZKfP6f7jjLw3+g6E/AKwIvhp9gVdUxy7FxtIoLJnEzJWD224 C5ahWjda8vAsJWuNQnS4ig7kwwl4btdMHU97hVw29J8dc3BOjOx64l9Lmr+yWzSZbqUk QJsw== X-Gm-Message-State: AOAM531hN1DcdBrKNM0eFYzyQ+CIa5s9+97nEQWOGY9lhYwUcYEb+xUX OlXH52tDs0/8mu2KBzprfifrScs0MKMrtEOfQCEYrg== X-Received: by 2002:a81:1e09:0:b0:2fe:c53c:a0aa with SMTP id e9-20020a811e09000000b002fec53ca0aamr2051320ywe.455.1652462788378; Fri, 13 May 2022 10:26:28 -0700 (PDT) MIME-Version: 1.0 References: <20220429220933.1350374-1-saravanak@google.com> In-Reply-To: From: Saravana Kannan Date: Fri, 13 May 2022 10:25:52 -0700 Message-ID: Subject: Re: [PATCH v1] driver core: Extend deferred probe timeout on driver registration To: Rob Herring Cc: Jonathan Corbet , Greg Kroah-Hartman , "Rafael J. Wysocki" , "Rafael J. Wysocki" , Linus Walleij , Will Deacon , Ulf Hansson , Kevin Hilman , Thierry Reding , Mark Brown , Pavel Machek , Geert Uytterhoeven , Yoshihiro Shimoda , Paul Kocialkowski , "open list:GPIO SUBSYSTEM" , "open list:THERMAL" , Linux IOMMU , Android Kernel Team , Linux Doc Mailing List , linux-kernel@vger.kernel.org Content-Type: text/plain; charset="UTF-8" X-Spam-Status: No, score=-9.5 required=5.0 tests=BAYES_00,DKIMWL_WL_MED, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,HEADER_FROM_DIFFERENT_DOMAINS, MAILING_LIST_MULTI,RDNS_NONE,SPF_HELO_NONE,T_SCC_BODY_TEXT_LINE, USER_IN_DEF_DKIM_WL 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, May 13, 2022 at 6:58 AM Rob Herring wrote: > > On Fri, Apr 29, 2022 at 5:09 PM Saravana Kannan wrote: > > > > The deferred probe timer that's used for this currently starts at > > late_initcall and runs for driver_deferred_probe_timeout seconds. The > > assumption being that all available drivers would be loaded and > > registered before the timer expires. This means, the > > driver_deferred_probe_timeout has to be pretty large for it to cover the > > worst case. But if we set the default value for it to cover the worst > > case, it would significantly slow down the average case. For this > > reason, the default value is set to 0. > > > > Also, with CONFIG_MODULES=y and the current default values of > > driver_deferred_probe_timeout=0 and fw_devlink=on, devices with missing > > drivers will cause their consumer devices to always defer their probes. > > This is because device links created by fw_devlink defer the probe even > > before the consumer driver's probe() is called. > > > > Instead of a fixed timeout, if we extend an unexpired deferred probe > > timer on every successful driver registration, with the expectation more > > modules would be loaded in the near future, then the default value of > > driver_deferred_probe_timeout only needs to be as long as the worst case > > time difference between two consecutive module loads. > > > > So let's implement that and set the default value to 10 seconds when > > CONFIG_MODULES=y. > > We had to revert a non-zero timeout before (issue with NFS root IIRC). > Does fw_devlink=on somehow fix that? If it's the one where ip autoconfig was timing out, then John Stultz fixed it by fixing wait_for_device_probe(). https://lore.kernel.org/all/20200422203245.83244-4-john.stultz@linaro.org/ If you are referring to some other issue, then I'd need more details. -Saravana