Received: by 2002:a05:6358:1087:b0:cb:c9d3:cd90 with SMTP id j7csp3033798rwi; Fri, 28 Oct 2022 14:56:53 -0700 (PDT) X-Google-Smtp-Source: AMsMyM7GKch1cLYUsHF3FukML/jJHOMHFaPTfio/zpOopRf9Ux/0QOaxcuGLs3w8L7ggytGukN57 X-Received: by 2002:a17:902:ebce:b0:186:9905:11bf with SMTP id p14-20020a170902ebce00b00186990511bfmr1172885plg.110.1666994213429; Fri, 28 Oct 2022 14:56:53 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1666994213; cv=none; d=google.com; s=arc-20160816; b=LgZG2Zp816ls5+syA23D4UPVT+xV9tvtD5sc8omnuIQIN7aJzJA/U0QuBwXZuzEOXL tpz3VOkpUYQQ13JVgwwqMGRbyZSLxatGTIwZqqEJ5knxY7XP1r5zN6RVLQiD0iC/20OM sbHNEZ2hYefKdjTx4X5dZ1yhkXi2oarBO4EsGADrbVKkAis2dWLmrP0qFZjQvJjEN4HJ AAc11+817XBgsT0Os1gpsTbQXUwClrVzqD/UHFIOdbuOfgzAb60v2s1SJzuBegBFs13+ 05apaFOdB/gQVv6A0U/j9mqTt8WHqMRjrzZfM6VUEA0GIePSQ3W0c7Cf+dMa1NroyRHc 3Smg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :references:in-reply-to:message-id:date:subject:cc:to:from :dkim-signature; bh=ZPP9pF7fIvV/nLcvOx6oDjBVViuf9MAG5n+X6Tj0h3Y=; b=rsemwTIiVmrcPSE+A3E9TGq+zIf3Mm2m4O4rnJeItvxIYe89fpvK0nhboTRGRHk06u Bk7e2jcCJ+U9NMqiW8PsymXDVENpen4U5gl2WdF2/MBpDPVQLT71GoS8r/4cO2l7UgOb /3cmMzuOOTZh+3XZ8JzSDpEEqdZ64v2IC8ZCr6eD37Ep+aG1d7IMu3Mora2LdTXxlwL+ teYgKQssdbcEzOsC6jA5u1gX8PgJvBNQ4r2+SXv7bVWtCUYVFJeKl7rsDPChcf5Pdnup aGjXOapf9KVmLXuWkdx4qzhzcfyB0scj7JXdUgXwGuBccfEaO0sy0IjGF2WjHifrkggf 5o2A== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@chromium.org header.s=google header.b="ZW9XW/Gf"; 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; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=chromium.org Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id k7-20020a63ff07000000b0042b9117b723si6297932pgi.794.2022.10.28.14.56.41; Fri, 28 Oct 2022 14:56:53 -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; dkim=pass header.i=@chromium.org header.s=google header.b="ZW9XW/Gf"; 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; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=chromium.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229971AbiJ1VPP (ORCPT + 99 others); Fri, 28 Oct 2022 17:15:15 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:37700 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229720AbiJ1VPA (ORCPT ); Fri, 28 Oct 2022 17:15:00 -0400 Received: from mail-pf1-x42f.google.com (mail-pf1-x42f.google.com [IPv6:2607:f8b0:4864:20::42f]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id D5A4313F22 for ; Fri, 28 Oct 2022 14:14:59 -0700 (PDT) Received: by mail-pf1-x42f.google.com with SMTP id g62so5787012pfb.10 for ; Fri, 28 Oct 2022 14:14:59 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=chromium.org; s=google; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=ZPP9pF7fIvV/nLcvOx6oDjBVViuf9MAG5n+X6Tj0h3Y=; b=ZW9XW/GfmujrJzDszG++/tJuCMwJBY7sSL2UrozY9KqH2Q0vlWzgUTXD7vpYtObRm/ 61xOuFMG+ZzrULCo/W9z8JasQoFrm6Dg6gHxExJyQU1D1f4QjBpE7oLrC23Jqd63ycbX obYJUiuItCe8/7dqWy6i77dDUD6hvr7XAIWsQ= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=ZPP9pF7fIvV/nLcvOx6oDjBVViuf9MAG5n+X6Tj0h3Y=; b=YPEHVvdYGe/Z0i+QPmsIYp9thfrOQXkImjVIiYCDfqVl12TxkwkTcDW7+pIMWu9SJg PYSYylEf8o4QukVP4MLbHQaVdbGOS7o6f4aZQ7ERTfkGqP+EcajKnkr920ZHCFUWvKaL y8osxWLCuzIu0z0L6GMmGX08ngdaHMo5YAE1L2Nxiuqqt5hb6gbQ/2/TLPUyd2m9Vz0b ESnIbxW/Gse7ZpuA7klhUAo4KcyrnqLm/vZ5EeE4GzEu0APuk8Yte7Rpp2K9bUdrsdtm nf89Xzz2LJWxsVr6/wsV/uSa6tA5GyUxTb03GLfKMKZgngpwg1RYLD93o+LI68hV+D9+ Xj7g== X-Gm-Message-State: ACrzQf2xjOI2KZyty2KB0nLT2PjIUYsOPAiXqG86yRFn8WGeHjEpyu/3 auzSRzU4BcHi8syagT+X4DsIHg== X-Received: by 2002:a05:6a00:1749:b0:563:8346:12e9 with SMTP id j9-20020a056a00174900b00563834612e9mr1125101pfc.68.1666991699582; Fri, 28 Oct 2022 14:14:59 -0700 (PDT) Received: from localhost ([2620:15c:9d:2:65f9:c180:249c:190f]) by smtp.gmail.com with UTF8SMTPSA id jc19-20020a17090325d300b00186ae20e8dcsm3415829plb.271.2022.10.28.14.14.58 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Fri, 28 Oct 2022 14:14:59 -0700 (PDT) From: Brian Norris To: Benson Leung , Guenter Roeck Cc: chrome-platform@lists.linux.dev, linux-kernel@vger.kernel.org, Brian Norris Subject: [PATCH 4/5] platform/chrome: cros_ec_lightbar: Set PROBE_PREFER_ASYNCHRONOUS Date: Fri, 28 Oct 2022 14:14:48 -0700 Message-Id: <20221028141411.4.I565598102e0bfb03bdf8c090d3bfdf954d026bc5@changeid> X-Mailer: git-send-email 2.38.1.273.g43a17bfeac-goog In-Reply-To: <20221028141411.1.I0728421299079b104710c202d5d7095b2674fd8c@changeid> References: <20221028141411.1.I0728421299079b104710c202d5d7095b2674fd8c@changeid> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Spam-Status: No, score=-2.6 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_NONE, SPF_HELO_NONE,SPF_PASS autolearn=ham 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 This driver takes on the order of 15ms to start on some systems. Even on systems where there is no lightbar support, it can take a few milliseconds just to probe the EC for support. 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 --- drivers/platform/chrome/cros_ec_lightbar.c | 1 + 1 file changed, 1 insertion(+) diff --git a/drivers/platform/chrome/cros_ec_lightbar.c b/drivers/platform/chrome/cros_ec_lightbar.c index 469dfc7a4a03..ff4d619cf924 100644 --- a/drivers/platform/chrome/cros_ec_lightbar.c +++ b/drivers/platform/chrome/cros_ec_lightbar.c @@ -601,6 +601,7 @@ static struct platform_driver cros_ec_lightbar_driver = { .driver = { .name = DRV_NAME, .pm = &cros_ec_lightbar_pm_ops, + .probe_type = PROBE_PREFER_ASYNCHRONOUS, }, .probe = cros_ec_lightbar_probe, .remove = cros_ec_lightbar_remove, -- 2.38.1.273.g43a17bfeac-goog