Received: by 2002:a05:6358:a55:b0:ec:fcf4:3ecf with SMTP id 21csp3331692rwb; Mon, 16 Jan 2023 06:45:40 -0800 (PST) X-Google-Smtp-Source: AMrXdXvfEMVPSxGPUgBK+WjjaIqmUjxMg+X+/Il/1pL0BxuK9GhQ06pblj6MYdAnRJWl0epy8bjU X-Received: by 2002:aa7:8b03:0:b0:58b:c688:6ac0 with SMTP id f3-20020aa78b03000000b0058bc6886ac0mr9553523pfd.10.1673880339864; Mon, 16 Jan 2023 06:45:39 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1673880339; cv=none; d=google.com; s=arc-20160816; b=BOBlot/016+oOwT+dezCl6u5UVWea5zJZg9yswOqRQ1/82hf/zMUuxfkFqBK6Sg2uT FxdHoRedvDy2AgCwwVnN7Cfp/09QGTFxPDaV9IvNUAz/LSwx2whneb6fG+HTtmzjQ/mz wngBj3MIz76fP5A2ANteEk4N++P8wPcX0sfTWqorT61FSqkwLDqWFa4RvJkd/vmRcoHS fxb0PNHW4ZmmK1ixE694jwpPdWmPXaZPsJhGgutcM4/MqrXDE3+cMA1Uk/OPAUENTLnZ RFxScyOGQte2XCPbJ+i1D/cdklhsjJBq6m1yWAGwdeinjbIUQgWHGEiRMn/+6PIaAEdc v2cQ== 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=L6yhiZ6LlUbPuFVSIXmDs2SsJmBCeaJlsD2pIr23l74=; b=lOP72KBmP0MpseynRv3q/s/numh/96c10McRHWld7L+OtiaOX+3vnvW/hKP2BCnvvr 86ktqqR/3mq5qFQSlKujHBV/u9x+vjVvX7drB17cFn7x2V5++mkItH+U9n8Hy96r1uCL JE8Wo8y6IECVMg7N0+M4mVmH2cc3f1CYqrV/3XuuntfU31OQ77KKGhqa6s/7AKNSjsPl MEBOe2hLdSxjeJisNF3LjVxsu1CmwqpyNqZgsShvMh6j221Q3R5tSpw0zqe3brqRtoPQ 2febMuycrD4S6IfrNtnt9toTTFPUDkL3YNHmkCxXbQcZDhUqN0+KzHd9l6AW0f6mqwy/ 2OpA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=Zc9+3pnm; 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=kernel.org Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id v6-20020a056a00148600b00582cddd784csi2272334pfu.264.2023.01.16.06.45.33; Mon, 16 Jan 2023 06:45:39 -0800 (PST) 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=@kernel.org header.s=k20201202 header.b=Zc9+3pnm; 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=kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S231521AbjAPNvd (ORCPT + 50 others); Mon, 16 Jan 2023 08:51:33 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:60674 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S231534AbjAPNuo (ORCPT ); Mon, 16 Jan 2023 08:50:44 -0500 Received: from dfw.source.kernel.org (dfw.source.kernel.org [IPv6:2604:1380:4641:c500::1]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 7708321963; Mon, 16 Jan 2023 05:50:43 -0800 (PST) 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 dfw.source.kernel.org (Postfix) with ESMTPS id 1E37D60FDE; Mon, 16 Jan 2023 13:50:42 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 47EE2C4339B; Mon, 16 Jan 2023 13:50:41 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1673877041; bh=xzaP0POiJTvdAArF5s+sRyCE4tI36PeyUYdNU4owoyY=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=Zc9+3pnmtbZ6o82DpGuYgW1tMjj2PtHMP9Upu1/umGP0gbfj8u/zRXpbpei3VP4k3 yh66TqL50QoPk7mXgdeNbBCpC13H6fm1Ls7zqggb3rogCRORryH9ZxK2eK3jLw4+GS nCroqQSwrzlbhN+4ZXOmYg61FG/wVxc0HOrPq5HR7Ty1JcuzJF+5atkBtuTnqx09Bj F1OtSt8LptZorWDyyh5Kw/BWMdQ5RifsiBQNdIytp6M67brGBBhO3jIXVhlFAjHi6q 0WnR5b2/IO2kGUl8OwiQXkItmlXHLJU4kpyoqqAG7zt3dMxFYAuM9geuRWMy/TgGoO TNC7j7/KEE6qA== Received: from johan by xi.lan with local (Exim 4.94.2) (envelope-from ) id 1pHPt6-0003vL-OK; Mon, 16 Jan 2023 14:51:00 +0100 From: Johan Hovold To: Marc Zyngier , Thomas Gleixner Cc: x86@kernel.org, platform-driver-x86@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-mips@vger.kernel.org, linux-kernel@vger.kernel.org, Johan Hovold , =?UTF-8?q?Philippe=20Mathieu-Daud=C3=A9?= , Hsin-Yi Wang , Mark-PK Tsai Subject: [PATCH v4 14/19] irqchip/gic-v2m: Use irq_domain_create_hierarchy() Date: Mon, 16 Jan 2023 14:50:39 +0100 Message-Id: <20230116135044.14998-15-johan+linaro@kernel.org> X-Mailer: git-send-email 2.38.2 In-Reply-To: <20230116135044.14998-1-johan+linaro@kernel.org> References: <20230116135044.14998-1-johan+linaro@kernel.org> MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-Spam-Status: No, score=-7.1 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_HI, 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 Use the irq_domain_create_hierarchy() helper to create the hierarchical domain, which both serves as documentation and avoids poking at irqdomain internals. Reviewed-by: Philippe Mathieu-Daudé Tested-by: Hsin-Yi Wang Tested-by: Mark-PK Tsai Signed-off-by: Johan Hovold --- drivers/irqchip/irq-gic-v2m.c | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/drivers/irqchip/irq-gic-v2m.c b/drivers/irqchip/irq-gic-v2m.c index f4d7eeb13951..f1e75b35a52a 100644 --- a/drivers/irqchip/irq-gic-v2m.c +++ b/drivers/irqchip/irq-gic-v2m.c @@ -287,15 +287,14 @@ static __init int gicv2m_allocate_domains(struct irq_domain *parent) if (!v2m) return 0; - inner_domain = irq_domain_create_tree(v2m->fwnode, - &gicv2m_domain_ops, v2m); + inner_domain = irq_domain_create_hierarchy(parent, 0, 0, v2m->fwnode, + &gicv2m_domain_ops, v2m); if (!inner_domain) { pr_err("Failed to create GICv2m domain\n"); return -ENOMEM; } irq_domain_update_bus_token(inner_domain, DOMAIN_BUS_NEXUS); - inner_domain->parent = parent; pci_domain = pci_msi_create_irq_domain(v2m->fwnode, &gicv2m_msi_domain_info, inner_domain); -- 2.38.2