From patchwork Mon May 9 03:43:30 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Samuel Holland X-Patchwork-Id: 12843015 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 50832C433F5 for ; Mon, 9 May 2022 03:45:31 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender: Content-Transfer-Encoding:Content-Type:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:MIME-Version:References:In-Reply-To: Message-Id:Date:Subject:Cc:To:From:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=sEMkSJJIiKQdKuGgXgmIwPccHqQdCLWnR+qCDRH6dgU=; b=2al+aOp0oNyQMs 6qRGpwmvjlDeEpGnO+m27o5oCpLRV94tqKIVPlQvBLsu/6WNyCZ4P/KFeDZxc+uyXp7reqmiyMNSR EjFh8QxLSLFyRG98PX9vZfhtuY5+A2IY+dl6ZQw+4hDtYnnJABy0kP8BfJEgmo6xiZgZYHD1E32zC Mm1PG2YZJrKf4mg+y3UqxND3+TqfehKEBUrvHbasSr5Fkv+eex4g/vcoyDyUh7LyyX/O2Fn9btNei nALhTHgicferdSOgHsdVSSL4M7zL4x83vh09FoK1mav6T/12YuY6xAsEB99OxWX+D39cYyxetpI5U gHQ6ixFfcuH9xBkNhBeg==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.94.2 #2 (Red Hat Linux)) id 1nnuJi-00CDqH-QE; Mon, 09 May 2022 03:44:14 +0000 Received: from out5-smtp.messagingengine.com ([66.111.4.29]) by bombadil.infradead.org with esmtps (Exim 4.94.2 #2 (Red Hat Linux)) id 1nnuJC-00CDfh-4P; Mon, 09 May 2022 03:43:45 +0000 Received: from compute1.internal (compute1.nyi.internal [10.202.2.41]) by mailout.nyi.internal (Postfix) with ESMTP id 615945C010A; Sun, 8 May 2022 23:43:38 -0400 (EDT) Received: from mailfrontend1 ([10.202.2.162]) by compute1.internal (MEProxy); Sun, 08 May 2022 23:43:38 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=sholland.org; h= cc:cc:content-transfer-encoding:date:date:from:from:in-reply-to :in-reply-to:message-id:mime-version:references:reply-to:sender :subject:subject:to:to; s=fm2; t=1652067818; x=1652154218; bh=YD hDThkINI0HCk+Vr4rmFl8Cmx4jEjCcgwwCp9ZTzSs=; b=iMiu+odchUn6oLYO2i p4md3l7LvrWNBzLa67wJ/ymaQKyTnHIrhJsvOlCmX4QaSggQRdOGXcUyZeZiAy8V M94tBwQd1qtxEA0RY74zpwL1q3YbYMN+MgzOb4xM0+xJrdHi9ZIb92kIszoWsAeW GYaWvwvNzTPWQCHO0d8AqE9Z0sNwQQ9OqjpkoIrU+EZdEjoB7I0S/Gzgqwk5/tJT JY7xqUB90lvoac90cYpm5ZRLUTVX4g21IOxjTk02BFnC+4VnUwYkUCUUgcivbrd4 2qQdve8p2bx6TRqN2cSE/ti6zvKQR1ZANju3YfKVkMQfIAZWukmnVNrm/YVw/Htl hwzw== DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= messagingengine.com; h=cc:cc:content-transfer-encoding:date:date :from:from:in-reply-to:in-reply-to:message-id:mime-version :references:reply-to:sender:subject:subject:to:to:x-me-proxy :x-me-proxy:x-me-sender:x-me-sender:x-sasl-enc; s=fm1; t= 1652067818; x=1652154218; bh=YDhDThkINI0HCk+Vr4rmFl8Cmx4jEjCcgww Cp9ZTzSs=; b=RZESZKyw9aetxD11MazwPfIWAUyG+pSjRDiGArRDRPGmh7hJnmU fNL5pi9Qh2bAU0dt8KT1V9aN/FPfv6/LkGsDO13QJL6dD10BO0yu04OJVdVWFFdI l7x0JoroWjOTc/5+ixWvcytPu16m2TmZpKyjhEusZ0PFOt18GGnhYj1+/qNWJKOv Gh94b7Y52clMF0El3wVygHpD13SdBMftgm90qtfVuMIyr99PnZrL/o9juI7BBmQ/ wmdeHnfs5S9z2aMG2Xe53G7pHMGJaG9o5gAdBWNtK0R/hwuuOlrJdXhuty6tNWOh WkPXs3/YWGbT1I6WHxqfAmWxFThNn7LA5uA== X-ME-Sender: X-ME-Received: X-ME-Proxy-Cause: gggruggvucftvghtrhhoucdtuddrgedvfedrfeekgdejiecutefuodetggdotefrodftvf curfhrohhfihhlvgemucfhrghsthforghilhdpqfgfvfdpuffrtefokffrpgfnqfghnecu uegrihhlohhuthemuceftddtnecusecvtfgvtghiphhivghnthhsucdlqddutddtmdenuc fjughrpefhvfevufffkffojghfggfgsedtkeertdertddtnecuhfhrohhmpefurghmuhgv lhcujfholhhlrghnugcuoehsrghmuhgvlhesshhhohhllhgrnhgurdhorhhgqeenucggtf frrghtthgvrhhnpedukeetueduhedtleetvefguddvvdejhfefudelgfduveeggeehgfdu feeitdevteenucevlhhushhtvghrufhiiigvpedtnecurfgrrhgrmhepmhgrihhlfhhroh hmpehsrghmuhgvlhesshhhohhllhgrnhgurdhorhhg X-ME-Proxy: Received: by mail.messagingengine.com (Postfix) with ESMTPA; Sun, 8 May 2022 23:43:37 -0400 (EDT) From: Samuel Holland To: Thomas Gleixner , Marc Zyngier , Palmer Dabbelt , Paul Walmsley , Albert Ou Cc: Samuel Holland , Florian Fainelli , Guo Ren , Linus Walleij , Mark Rutland , Russell King , Wei Xu , linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org, linux-riscv@lists.infradead.org Subject: [PATCH 2/5] genirq: Refactor accessors to use irq_data_get_affinity_mask Date: Sun, 8 May 2022 22:43:30 -0500 Message-Id: <20220509034333.60017-3-samuel@sholland.org> X-Mailer: git-send-email 2.35.1 In-Reply-To: <20220509034333.60017-1-samuel@sholland.org> References: <20220509034333.60017-1-samuel@sholland.org> MIME-Version: 1.0 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20220508_204342_760549_F78C10FD X-CRM114-Status: GOOD ( 10.45 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org A couple of functions directly reference the affinity mask. Route them through irq_data_get_affinity_mask so they will pick up any refactoring done there. Signed-off-by: Samuel Holland --- include/linux/irq.h | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/include/linux/irq.h b/include/linux/irq.h index f92788ccdba2..48ac33ca3703 100644 --- a/include/linux/irq.h +++ b/include/linux/irq.h @@ -877,16 +877,16 @@ static inline int irq_data_get_node(struct irq_data *d) return irq_common_data_get_node(d->common); } -static inline struct cpumask *irq_get_affinity_mask(int irq) +static inline struct cpumask *irq_data_get_affinity_mask(struct irq_data *d) { - struct irq_data *d = irq_get_irq_data(irq); - - return d ? d->common->affinity : NULL; + return d->common->affinity; } -static inline struct cpumask *irq_data_get_affinity_mask(struct irq_data *d) +static inline struct cpumask *irq_get_affinity_mask(int irq) { - return d->common->affinity; + struct irq_data *d = irq_get_irq_data(irq); + + return d ? irq_data_get_affinity_mask(d) : NULL; } #ifdef CONFIG_GENERIC_IRQ_EFFECTIVE_AFF_MASK @@ -908,7 +908,7 @@ static inline void irq_data_update_effective_affinity(struct irq_data *d, static inline struct cpumask *irq_data_get_effective_affinity_mask(struct irq_data *d) { - return d->common->affinity; + return irq_data_get_affinity_mask(d); } #endif