Received: by 2002:a05:6358:d09b:b0:dc:cd0c:909e with SMTP id jc27csp2817990rwb; Fri, 9 Dec 2022 06:43:48 -0800 (PST) X-Google-Smtp-Source: AA0mqf43fID0i/ftCHvmygYhoKe7v4CXrNTWhLGKxJEzaAupSoZS9kvo9gHwwH+UdCeEtn2u1bae X-Received: by 2002:a17:90a:fc85:b0:21a:b64:3488 with SMTP id ci5-20020a17090afc8500b0021a0b643488mr5784329pjb.44.1670597028155; Fri, 09 Dec 2022 06:43:48 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1670597028; cv=none; d=google.com; s=arc-20160816; b=ZqJYTL+c3StvVDyQPj9q1CcY2ljcNnSp4rto+YXE6tT2krfFKvyF9aZ6sMnE6J4d5R oS08Ymv2oSkPjHAWpfXkMPHvog9RbHF6eXw9DclMhe2ScubJJtJf1GUouzpQsfbUfoFZ nUUjG0OgVii22Gwm0j291xNyunPVDZH9/TraSewL1YpDKmfg/SG9b8AjV6bP6hu8TgGo nuv4CIv+OodiodYByQUVIGZM7gJ/7DlZ8td1uxEw5Z7scDW+yarea5X3RanStR9HcLvs LrMSBnPTQcw6BSHvXgl6G6dbLRw/+hlPjrHj6mAuF8qPMdzOD53DXnqGV7DFCI5u5OXR Y6ig== 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=DWeG1268g6v4b8wuSax0W2FlWgBUonuvP/aVevr+xC0=; b=U2vs0B8DfBUPEf3j3uB0lpN9Xu0drkRzO96OdWCvsqzvk9kvK661E+Cl5AeOe7mqqY UfgcKVLCThcXxTGCEfJ2+J1/ViuOvg7S+QE91w+s5NM6t25/5d5m1U/XZWLDaes2Xw+x mXPtXgZC5IKToq09k6b3rjcTNH7qC/q/aaC5MCbxmZ5WQHO4T1aYEykjvEnELkpETIGd pYLFaSUgl0RuX+UAvN5/RPPPF7ZIUH59t6pPuT5W40ILs3NBpU3RfGavQ1WTHA0aJIlr LehvdDOaMQuO6qMS6c0oGFHHgxSNpPqAHeGPCkBV6+43VWQSfNKPAlySe4LK0H+2GeqC fCMg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=Ek8MZqQK; 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 ne24-20020a17090b375800b002180c61f557si1752733pjb.99.2022.12.09.06.43.37; Fri, 09 Dec 2022 06:43:48 -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=Ek8MZqQK; 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 S230018AbiLIOGZ (ORCPT + 75 others); Fri, 9 Dec 2022 09:06:25 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:33844 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229957AbiLIOFV (ORCPT ); Fri, 9 Dec 2022 09:05:21 -0500 Received: from sin.source.kernel.org (sin.source.kernel.org [145.40.73.55]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 2FA967720A; Fri, 9 Dec 2022 06:05:18 -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 sin.source.kernel.org (Postfix) with ESMTPS id 7090ACE289D; Fri, 9 Dec 2022 14:05:16 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 025F3C43332; Fri, 9 Dec 2022 14:05:13 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1670594714; bh=6gyDnOh8vPJma4ZvWV3odrUEiz4K7dnpkJYUU+2k8Ko=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=Ek8MZqQKLsJ2LM5eTC6LlMFwRDP9T77FoT9Unw5x0i8TZozYTJDlgE5dX9OYlJHLc fBVnwf6BIAwxVgSKs3qB/zWQdbukgQ/7haodw9cswsTecqC3DzFYWhW7tLKLKmnx9X eswae/iOsywzrd85JzubZr0kZ2YR0QLa86l8DW2Fgr3oKPcaT0cGd+5ySQy+4cPl8V o5tUk3iMxqfJtiQRguut9wsTvQ7ELUH1Nrw57f+xm8cUaNkekwQy+iHBJ22/vGAcaX +Hd1y9+od+wFDSIvXyPVRJHyaAESxqMRuf8lViOsI6sWcSWVTr/V1cqaedM+7FkvKv DfQIUSAXNMN0A== Received: from johan by xi.lan with local (Exim 4.94.2) (envelope-from ) id 1p3e0J-0000Rv-8T; Fri, 09 Dec 2022 15:05:31 +0100 From: Johan Hovold To: Marc Zyngier Cc: Thomas Gleixner , 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 Subject: [PATCH v3 12/19] x86/apic: Use irq_domain_create_hierarchy() Date: Fri, 9 Dec 2022 15:01:43 +0100 Message-Id: <20221209140150.1453-13-johan+linaro@kernel.org> X-Mailer: git-send-email 2.37.4 In-Reply-To: <20221209140150.1453-1-johan+linaro@kernel.org> References: <20221209140150.1453-1-johan+linaro@kernel.org> MIME-Version: 1.0 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. Signed-off-by: Johan Hovold --- arch/x86/platform/uv/uv_irq.c | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/arch/x86/platform/uv/uv_irq.c b/arch/x86/platform/uv/uv_irq.c index 1a536a187d74..ee21d6a36a80 100644 --- a/arch/x86/platform/uv/uv_irq.c +++ b/arch/x86/platform/uv/uv_irq.c @@ -166,10 +166,9 @@ static struct irq_domain *uv_get_irq_domain(void) if (!fn) goto out; - uv_domain = irq_domain_create_tree(fn, &uv_domain_ops, NULL); - if (uv_domain) - uv_domain->parent = x86_vector_domain; - else + uv_domain = irq_domain_create_hierarchy(x86_vector_domain, 0, 0, fn, + &uv_domain_ops, NULL); + if (!uv_domain) irq_domain_free_fwnode(fn); out: mutex_unlock(&uv_lock); -- 2.37.4