Message ID | 20230313182918.1312597-21-gregkh@linuxfoundation.org |
---|---|
State | New |
Headers |
Return-Path: <linux-kernel-owner@vger.kernel.org> Delivered-To: ouuuleilei@gmail.com Received: by 2002:a5d:5915:0:0:0:0:0 with SMTP id v21csp1342749wrd; Mon, 13 Mar 2023 11:36:08 -0700 (PDT) X-Google-Smtp-Source: AK7set8CS1u8PEOrbhWGRYS4U1ge6Ws/GKR72HUftqkZqmBF7IXjzqg+kU95wbOcpROFw6bq/yms X-Received: by 2002:a17:902:6b49:b0:19a:7f4b:3ef6 with SMTP id g9-20020a1709026b4900b0019a7f4b3ef6mr29636228plt.3.1678732567806; Mon, 13 Mar 2023 11:36:07 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1678732567; cv=none; d=google.com; s=arc-20160816; b=pvBrK81dwxUtj9OeZVKgI/5PTxkr2NiJE4NP5b6r+4KR7J7xDyNstQmfeo3asfYQNu 8zMCYYPS88zTYUV6hehddHQfstHFDiBq2vl+J9BNwB0Jyse9L5bFCqz3a5ByCIy1Qkp7 FAOBf0SGbeQfhd8x0/SIl01IPilZ8NYRrZdqkyrEVtKqv1nOopOBuoDgN9LmUNubtHp3 Gyo2gQxZB8T6vqLsyZ+WlCAVia+ZFZTM27A9dHEOR5U99dR+7mTZ5LQHpaVZBRC51kkO cE5ROtzcjIO6TTBqeq1CFo2PaIDieg7jUlQ6PVeoOGr6oNmbvuYp9FKvuyPPH8EmrgzG +jwg== 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=UJKjuOGDbrLYTiV56o66S1UkwPSIMpf/FooeUy6u4pc=; b=V6r6eSkxsGMWy1IOhJ3Px+hJMPGmlWxWeTusvaCgNW052mUMFCI/oxtAUXiM3+Hv2c ySHmLivwaJ3eDF5E+6XK06oB4QA2HN/O+b4mTQA+XohjLzXQW2dmntSubebOXi/tQXEx 0kuYlow0wVFWwqchj7qjKozt+1gXiUQqH5RB7XdN6I9eMhf2zKhqQfOPv8NJqV+REU5G 4Iz2gSqY7QALodqtJN8j9PAPPq6DPj3oVnzPO7E7wzayqZ8hLu0NXIAXSFIS0O9Y+r7b hK80obeOZqYm9Q6v1927tdqlHdSqB+hW1n2jfw0SszZiTjVuTnz1pW7cf3COfq4CLCAl SudQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b="MLMA0/W4"; 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=linuxfoundation.org Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id kk3-20020a170903070300b0019e665b24e0si399841plb.1.2023.03.13.11.35.52; Mon, 13 Mar 2023 11:36:07 -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=@linuxfoundation.org header.s=korg header.b="MLMA0/W4"; 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=linuxfoundation.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229662AbjCMSbU (ORCPT <rfc822;realc9580@gmail.com> + 99 others); Mon, 13 Mar 2023 14:31:20 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:34238 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S230515AbjCMSas (ORCPT <rfc822;linux-kernel@vger.kernel.org>); Mon, 13 Mar 2023 14:30:48 -0400 Received: from ams.source.kernel.org (ams.source.kernel.org [IPv6:2604:1380:4601:e00::1]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id E2A901499A for <linux-kernel@vger.kernel.org>; Mon, 13 Mar 2023 11:30:22 -0700 (PDT) Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ams.source.kernel.org (Postfix) with ESMTPS id 78B98B811E7 for <linux-kernel@vger.kernel.org>; Mon, 13 Mar 2023 18:30:00 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id E690CC433D2; Mon, 13 Mar 2023 18:29:58 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1678732199; bh=NvUcPCqXclVT0vDCEaH778GVQZ2rqILZ8eRefC/g5TQ=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=MLMA0/W4RIYMRSO1RYJk3EvULfF9X82t6F0IpxQCpIqQu/2t2VdHyACPpsqR/KTg1 rH9wAim3CUuFFGIspkL/zcHN4Z+Bg/Xul2JQRfXjS/DaL54wFjZ8No+Gchk7x4mQNs h3oP3oexGZZzUBUd1yEwNczLF//yo90Wc/2CjaZo= From: Greg Kroah-Hartman <gregkh@linuxfoundation.org> To: linux-kernel@vger.kernel.org Cc: rafael@kernel.org, Greg Kroah-Hartman <gregkh@linuxfoundation.org>, Thomas Gleixner <tglx@linutronix.de>, Marc Zyngier <maz@kernel.org> Subject: [PATCH 21/36] irqchip/mbigen: move to use bus_get_dev_root() Date: Mon, 13 Mar 2023 19:29:03 +0100 Message-Id: <20230313182918.1312597-21-gregkh@linuxfoundation.org> X-Mailer: git-send-email 2.39.2 In-Reply-To: <20230313182918.1312597-1-gregkh@linuxfoundation.org> References: <20230313182918.1312597-1-gregkh@linuxfoundation.org> MIME-Version: 1.0 X-Developer-Signature: v=1; a=openpgp-sha256; l=1593; i=gregkh@linuxfoundation.org; h=from:subject; bh=NvUcPCqXclVT0vDCEaH778GVQZ2rqILZ8eRefC/g5TQ=; b=owGbwMvMwCRo6H6F97bub03G02pJDCn82ZXX5P+xTk86lSulc/TLbwa3X8tdmtXbS/Nvz1MLN VojlcHfEcvCIMjEICumyPJlG8/R/RWHFL0MbU/DzGFlAhnCwMUpABMxYmNYMG15zvGHYWdeOFS7 iXy4OsPSYt4pLoYFcyQtW4v6TC5ebAl6HaN8KX8d7+o3AA== X-Developer-Key: i=gregkh@linuxfoundation.org; a=openpgp; fpr=F4B60CC5BF78C2214A313DCB3147D40DDB2DFB29 Content-Transfer-Encoding: 8bit X-Spam-Status: No, score=-4.4 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_MED, 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: <linux-kernel.vger.kernel.org> X-Mailing-List: linux-kernel@vger.kernel.org X-getmail-retrieved-from-mailbox: =?utf-8?q?INBOX?= X-GMAIL-THRID: =?utf-8?q?1760278681230563360?= X-GMAIL-MSGID: =?utf-8?q?1760278681230563360?= |
Series |
[01/36] EDAC/sysfs: move to use bus_get_dev_root()
|
|
Commit Message
Greg KH
March 13, 2023, 6:29 p.m. UTC
Direct access to the struct bus_type dev_root pointer is going away soon
so replace that with a call to bus_get_dev_root() instead, which is what
it is there for.
Cc: Thomas Gleixner <tglx@linutronix.de>
Cc: Marc Zyngier <maz@kernel.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
---
Note, this is a patch that is a prepatory cleanup as part of a larger
series of patches that is working on resolving some old driver core
design mistakes. It will build and apply cleanly on top of 6.3-rc2 on
its own, but I'd prefer if I could take it through my driver-core tree
so that the driver core changes can be taken through there for 6.4-rc1.
drivers/irqchip/irq-mbigen.c | 13 ++++++++-----
1 file changed, 8 insertions(+), 5 deletions(-)
diff --git a/drivers/irqchip/irq-mbigen.c b/drivers/irqchip/irq-mbigen.c index f3faf5c99770..30ca1bf7fc8b 100644 --- a/drivers/irqchip/irq-mbigen.c +++ b/drivers/irqchip/irq-mbigen.c @@ -245,11 +245,14 @@ static int mbigen_of_create_domain(struct platform_device *pdev, if (!of_property_read_bool(np, "interrupt-controller")) continue; - parent = platform_bus_type.dev_root; - child = of_platform_device_create(np, NULL, parent); - if (!child) { - of_node_put(np); - return -ENOMEM; + parent = bus_get_dev_root(&platform_bus_type); + if (parent) { + child = of_platform_device_create(np, NULL, parent); + put_device(parent); + if (!child) { + of_node_put(np); + return -ENOMEM; + } } if (of_property_read_u32(child->dev.of_node, "num-pins",