Received: by 2002:a05:6358:4e97:b0:b3:742d:4702 with SMTP id ce23csp32719rwb; Fri, 19 Aug 2022 16:14:16 -0700 (PDT) X-Google-Smtp-Source: AA6agR6T1EMbxMDLtDwa2YsAfHyVQJqdbkMQbooXHRuzaC7LStShjxbCs/j7QqUafhafNvCGJS4Z X-Received: by 2002:a05:6402:5ca:b0:445:c80a:3c2 with SMTP id n10-20020a05640205ca00b00445c80a03c2mr7636807edx.247.1660950856720; Fri, 19 Aug 2022 16:14:16 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1660950856; cv=none; d=google.com; s=arc-20160816; b=bRaVlIgYBZaQxQwR9nLib8MAAobom5B/ohkBbg4pBay9uf1H11iho2JRRMqFukXjaf wGd1Z1f03ILRVZXvlZKTuRFPO9lr4tDCXJWwWyVIFgKUUGNeiAP18uqGyNvgS2Pja/qg pAb30gV78CPAZ8G9rBOk0pgYA+J/mefK5uIDq9TBm5zdhqbgL5xFWYvFKRzd4Y7kQ4NS X3h04GYYO3k+Pa9dPayfV0J+6nK1FhD4iAjyuTbpxHjBV5F30dqR7Euc86n8iGGwHsgb 2jF2VKCYW5B8+44TaVwF23ZwklL1lkRDl8v8gtJ4/A/uRzZQYp4EBGRy92VJW4+IkP1F oczw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:cc:to:from:subject:references:mime-version :message-id:in-reply-to:date:dkim-signature; bh=23aDVj4LlbfPkoiXqxbD0E4C7v4CoYUgh/84jy41NX0=; b=wV/tGE2Tyc20krgNl0hRQp14gpysl7Ut6JXDxrIe56SK2uwKB91ofoTjp5k7ntHYhQ gpjBhHMJScGwOP1HCBsakhNNoX2oOj4yagvkVEcD6nf218DMlsLhpDWYq3rfuXAdYUsf Wh9QZftEsF7qukRTShTPwT1CqoxEoth9FXEsYdlwzK3e9Em2ywOyFfSVP/qrcZb4mzIF BqwOBW9uBeuTSVWrr17n9msv/rqJclbz7W7x6TJxpBkBbnhCBfag/STPcfRdSlk0+gxi FY2bA1kFCxNN6LvlMdkRa8bO/xo8TOlz/VP3d4AZb/gdqvRjMQa9OP47bXJq7xn0BYEv t0Eg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@google.com header.s=20210112 header.b=RfDBUV4E; 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=REJECT sp=REJECT dis=NONE) header.from=google.com Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id hu8-20020a170907a08800b007321eb06896si3707042ejc.153.2022.08.19.16.13.33; Fri, 19 Aug 2022 16:14:16 -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=@google.com header.s=20210112 header.b=RfDBUV4E; 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=REJECT sp=REJECT dis=NONE) header.from=google.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S238949AbiHSWQo (ORCPT + 99 others); Fri, 19 Aug 2022 18:16:44 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:35248 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S239924AbiHSWQe (ORCPT ); Fri, 19 Aug 2022 18:16:34 -0400 Received: from mail-yw1-x1149.google.com (mail-yw1-x1149.google.com [IPv6:2607:f8b0:4864:20::1149]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 2681CD34D3 for ; Fri, 19 Aug 2022 15:16:28 -0700 (PDT) Received: by mail-yw1-x1149.google.com with SMTP id 00721157ae682-3339532b6a8so97240477b3.1 for ; Fri, 19 Aug 2022 15:16:28 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20210112; h=cc:to:from:subject:references:mime-version:message-id:in-reply-to :date:from:to:cc; bh=23aDVj4LlbfPkoiXqxbD0E4C7v4CoYUgh/84jy41NX0=; b=RfDBUV4Eoi6hUFddi87J/g/A5JBzLloY2dSMy9AH8SPOKlZLXQ//QBrA4oxiIqSu4a SIOdoHuaxKNOVbAJ7rfbvgzZsRd+lMbYJfODtYvKx4yHXzvVcTpentmBP17iRir2X+Q8 FlckrSbhp4QISwdxhNXl36Ack8Ob/HkJo70k1gEcoGu4PVUev58lHdvwI4FChXgTC+y5 LTE5zMaLdxyeGDcqGVqt2VvayphFlXKnYAmdOu8lbSbVtxx9pUAZ8nNJz8tK4YyOkHI/ BohL+A06pQKGtVKh3c7R1TalLS7V2CuJgo894FA5LRde++POf9XldtYkSnPPXVrKJnl3 5KPw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=cc:to:from:subject:references:mime-version:message-id:in-reply-to :date:x-gm-message-state:from:to:cc; bh=23aDVj4LlbfPkoiXqxbD0E4C7v4CoYUgh/84jy41NX0=; b=1mLYG/XBueGVAuEBhpwybRfgxcJH0mertrz+MOFCTjaflggEZgWZHoYjkIPU77fkM8 3Cd3ibkpLvf6/OuzBJtLyMnqzXIbx7wyI8IXdqHlAdGgBs2LgfHNjsrqlGsH3G/gygVE fDM6MTcwBHQgcQfCm43G0pAF5bRxllfPUgP7TAcKaH48aTG0ttchRSMXAKYbG56/vUoP pNelIHM3VHLk+fxn1srBoL/Uv7rDRt6lIXk9pKpYBdUrnK1WcjblxlMvJBqysHZfKprA amylYJP9+swlUUVPD4IP9rhOMF66yLZUGBsS5Tvm58N8Y303rH8CTh0ZxlABos23nAvE sjWw== X-Gm-Message-State: ACgBeo0y/anfpn6i9+9T5euCsCjD9Ol1BrN2HNIJV0TLOsgGOlEGWgHy cOUpyT30PkI5Jl8d3o2uLqO+DU4ulKTTJ+4= X-Received: from saravanak.san.corp.google.com ([2620:15c:2d:3:f93e:7b61:ce3d:5b06]) (user=saravanak job=sendgmr) by 2002:a25:bc52:0:b0:67e:e3c:1453 with SMTP id d18-20020a25bc52000000b0067e0e3c1453mr9778933ybk.121.1660947388574; Fri, 19 Aug 2022 15:16:28 -0700 (PDT) Date: Fri, 19 Aug 2022 15:16:13 -0700 In-Reply-To: <20220819221616.2107893-1-saravanak@google.com> Message-Id: <20220819221616.2107893-4-saravanak@google.com> Mime-Version: 1.0 References: <20220819221616.2107893-1-saravanak@google.com> X-Mailer: git-send-email 2.37.1.595.g718a3a8f04-goog Subject: [PATCH v2 3/4] Revert "PM: domains: Delete usage of driver_deferred_probe_check_state()" From: Saravana Kannan To: Greg Kroah-Hartman , "Rafael J. Wysocki" , Kevin Hilman , Ulf Hansson , Pavel Machek , Len Brown , Joerg Roedel , Will Deacon , Robin Murphy , Andrew Lunn , Heiner Kallweit , Russell King , "David S. Miller" , Eric Dumazet , Jakub Kicinski , Paolo Abeni , Saravana Kannan Cc: Peng Fan , Luca Weiss , Doug Anderson , Colin Foster , Tony Lindgren , Alexander Stein , Naresh Kamboju , Geert Uytterhoeven , Jean-Philippe Brucker , kernel-team@android.com, linux-kernel@vger.kernel.org, linux-pm@vger.kernel.org, iommu@lists.linux.dev, netdev@vger.kernel.org Content-Type: text/plain; charset="UTF-8" X-Spam-Status: No, score=-9.6 required=5.0 tests=BAYES_00,DKIMWL_WL_MED, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_NONE, SPF_HELO_NONE,SPF_PASS,T_SCC_BODY_TEXT_LINE,USER_IN_DEF_DKIM_WL 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 reverts commit 5a46079a96451cfb15e4f5f01f73f7ba24ef851a. Quite a few issues have been reported [1][2][3][4][5][6] on the original commit. While about half of them have been fixed, I'll need to fix the rest before driver_deferred_probe_check_state() can be deleted. So, revert the deletion for now. [1] - https://lore.kernel.org/all/DU0PR04MB941735271F45C716342D0410886B9@DU0PR04MB9417.eurprd04.prod.outlook.com/ [2] - https://lore.kernel.org/all/CM6REZS9Z8AC.2KCR9N3EFLNQR@otso/ [3] - https://lore.kernel.org/all/CAD=FV=XYVwaXZxqUKAuM5c7NiVjFz5C6m6gAHSJ7rBXBF94_Tg@mail.gmail.com/ [4] - https://lore.kernel.org/all/Yvpd2pwUJGp7R+YE@euler/ [5] - https://lore.kernel.org/lkml/20220601070707.3946847-2-saravanak@google.com/ [6] - https://lore.kernel.org/all/CA+G9fYt_cc5SiNv1Vbse=HYY_+uc+9OYPZuJ-x59bROSaLN6fw@mail.gmail.com/ Fixes: 5a46079a9645 ("PM: domains: Delete usage of driver_deferred_probe_check_state()") Reported-by: Peng Fan Reported-by: Luca Weiss Reported-by: Doug Anderson Reported-by: Colin Foster Reported-by: Tony Lindgren Reported-by: Alexander Stein Reported-by: Naresh Kamboju Reviewed-by: Tony Lindgren Tested-by: Tony Lindgren Signed-off-by: Saravana Kannan --- drivers/base/power/domain.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/base/power/domain.c b/drivers/base/power/domain.c index 5a2e0232862e..55a10e6d4e2a 100644 --- a/drivers/base/power/domain.c +++ b/drivers/base/power/domain.c @@ -2733,7 +2733,7 @@ static int __genpd_dev_pm_attach(struct device *dev, struct device *base_dev, mutex_unlock(&gpd_list_lock); dev_dbg(dev, "%s() failed to find PM domain: %ld\n", __func__, PTR_ERR(pd)); - return -ENODEV; + return driver_deferred_probe_check_state(base_dev); } dev_dbg(dev, "adding to PM domain %s\n", pd->name); -- 2.37.1.595.g718a3a8f04-goog