Received: by 2002:ac0:e350:0:0:0:0:0 with SMTP id g16csp314382imn; Thu, 4 Aug 2022 07:03:50 -0700 (PDT) X-Google-Smtp-Source: AA6agR4RfrUeEX0qfWJ7RnkLorlbKNCluNkOoFzB8FzgaULY7qOFFg9F68E8Cp/Uh34c0Hs8WIza X-Received: by 2002:a17:907:7209:b0:72b:924b:60a8 with SMTP id dr9-20020a170907720900b0072b924b60a8mr1590012ejc.442.1659621830297; Thu, 04 Aug 2022 07:03:50 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1659621830; cv=none; d=google.com; s=arc-20160816; b=m7QCxdGz2XvIy9oEtitY7WUIHEVL2SZYDA+9dc2O6fzDYNtkCne2wHiAvgGt8U6I/i MOeGc3FY3op+VK4cpwDalHUcr4ypNfyI1cgOIKf1Hec5+F+hieKTnPT446huUTE/0gmP /kS1k6tHLSxgTg72hLlcuE5fU1S0Gydwr4TJYvMfXohFTLrfF0LyDkXbjHcDAgZZHgdo NYrXcogStdQXPbTrxZ9XyRZlB8WzZ3IJI6PQPHVXnWyTS5SqmcAKCryppvcEUltufxGr xRsjOOQo5YylhTQWRK8O5SY8se6Ldsjsht0ZqbOD0vMeheVB41pjLouebGEe6wy3udJI 8VQA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:robot-unsubscribe :robot-id:message-id:mime-version:references:in-reply-to:cc:subject :to:reply-to:sender:from:dkim-signature:dkim-signature:date; bh=cFHLBCO5SHBgy6/VPCSR/0dLlOdvs5/InwJBhBRvG+M=; b=iLv9q76yv5VegrFxtXzbLQdvKAVSKzP1XmFBkUtxQinYfpzO9EqzZYxsVqyuvi8HQG 583xEV+peq6yFX6iJ+NusEvECYZNFIvgJ1CyklOUS5OGXAUZAhCyHx16S1biWyHVroeY JTfXC2K+1tHrUU29JkOioX99l7Q8rD8XmWoQI1CxjyybTYfRuL2rPxO6pnu0OhAjh8sB Rg2cJnmUbSqVX0dQipmqbigcDbDoscYq/MDGCukb+d+1EGlM+VOMkJJ0o7iASsmi4sM0 FfESqSqpGdGa+XbBkjpt7Gl5zyniWC3wz7LZZftox+KoRUVJqX/HxmrvktRmPNJsqN0e 7aMQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linutronix.de header.s=2020 header.b=sdDSQk7u; dkim=neutral (no key) header.i=@linutronix.de header.b=fMuUpipG; 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=QUARANTINE dis=NONE) header.from=linutronix.de Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id ho10-20020a1709070e8a00b007308bc0ecaesi776220ejc.429.2022.08.04.07.03.23; Thu, 04 Aug 2022 07:03:50 -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=@linutronix.de header.s=2020 header.b=sdDSQk7u; dkim=neutral (no key) header.i=@linutronix.de header.b=fMuUpipG; 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=QUARANTINE dis=NONE) header.from=linutronix.de Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S239761AbiHDN0S (ORCPT + 99 others); Thu, 4 Aug 2022 09:26:18 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:59750 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S239162AbiHDN0K (ORCPT ); Thu, 4 Aug 2022 09:26:10 -0400 Received: from galois.linutronix.de (Galois.linutronix.de [193.142.43.55]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id D14C0BF4C for ; Thu, 4 Aug 2022 06:26:07 -0700 (PDT) Date: Thu, 04 Aug 2022 13:26:04 -0000 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linutronix.de; s=2020; t=1659619566; h=from:from:sender:sender:reply-to:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:cc:mime-version:mime-version: content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=cFHLBCO5SHBgy6/VPCSR/0dLlOdvs5/InwJBhBRvG+M=; b=sdDSQk7ujJckDHFtwb9v+FZrVwIh+u6Jz9fXMZthKcv4mQBJN101iot+otIfR4KrSlVEfG ZRjkONRx3t8T1tq7LuVXYuOkmhdlpEU+m1dRI3+1nsJn9h75b1I8G7SRFbYaHM3keMAOHo uaVEuHoP8mdFb4OK6B77Gc4yEviW8S8YywSlJz3+AYHm2OWG7s+VfNkNpiMUrZwl9Y2/Hx LqYc9Uiwo3sAaA5C7IRPx3uu3n1BLW92sPUeLePuNGI3KZe5hHy0LUB/T1/IihTaOKdFLj 4DrTB8rVpDCosDg1D/nbpaB5i8l6vb/P6voFgi+o9OD0ZLpURHj/6wnEgvpeog== DKIM-Signature: v=1; a=ed25519-sha256; c=relaxed/relaxed; d=linutronix.de; s=2020e; t=1659619566; h=from:from:sender:sender:reply-to:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:cc:mime-version:mime-version: content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=cFHLBCO5SHBgy6/VPCSR/0dLlOdvs5/InwJBhBRvG+M=; b=fMuUpipGtXVPWpy00NFrMyAqRtA6M/FIuxlcupvKeLlpdIdxJBQeA+G3HiplRjy8r3b15x vk/PWVWRwdvj5FBg== From: "irqchip-bot for Michael Kelley" Sender: tip-bot2@linutronix.de Reply-to: linux-kernel@vger.kernel.org To: linux-kernel@vger.kernel.org Subject: [irqchip: irq/irqchip-fixes] iommu/hyper-v: Use helper instead of directly accessing affinity Cc: Michael Kelley , Randy Dunlap , Joerg Roedel , Marc Zyngier , tglx@linutronix.de In-Reply-To: <1658796820-2261-1-git-send-email-mikelley@microsoft.com> References: <1658796820-2261-1-git-send-email-mikelley@microsoft.com> MIME-Version: 1.0 Message-ID: <165961956454.15455.6170338476537736674.tip-bot2@tip-bot2> Robot-ID: Robot-Unsubscribe: Contact to get blacklisted from these emails Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: 7bit X-Spam-Status: No, score=-4.4 required=5.0 tests=BAYES_00,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: X-Mailing-List: linux-kernel@vger.kernel.org The following commit has been merged into the irq/irqchip-fixes branch of irqchip: Commit-ID: b0a4ab7ca4ce993d1cc51cbc85e9f341c729a3d4 Gitweb: https://git.kernel.org/pub/scm/linux/kernel/git/maz/arm-platforms/b0a4ab7ca4ce993d1cc51cbc85e9f341c729a3d4 Author: Michael Kelley AuthorDate: Mon, 25 Jul 2022 17:53:40 -07:00 Committer: Marc Zyngier CommitterDate: Thu, 04 Aug 2022 10:02:09 +01:00 iommu/hyper-v: Use helper instead of directly accessing affinity Recent changes to solve inconsistencies in handling IRQ masks #ifdef out the affinity field in irq_common_data for non-SMP configurations. The current code in hyperv_irq_remapping_alloc() gets a compiler error in that case. Fix this by using the new irq_data_update_affinity() helper, which handles the non-SMP case correctly. Signed-off-by: Michael Kelley Reported-by: Randy Dunlap Tested-by: Randy Dunlap Acked-by: Randy Dunlap Acked-by: Joerg Roedel Signed-off-by: Marc Zyngier Fixes: aa0813581b8d ("genirq: Provide an IRQ affinity mask in non-SMP configs") Link: https://lore.kernel.org/r/1658796820-2261-1-git-send-email-mikelley@microsoft.com --- drivers/iommu/hyperv-iommu.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/drivers/iommu/hyperv-iommu.c b/drivers/iommu/hyperv-iommu.c index 51bd66a..e190bb8 100644 --- a/drivers/iommu/hyperv-iommu.c +++ b/drivers/iommu/hyperv-iommu.c @@ -68,7 +68,6 @@ static int hyperv_irq_remapping_alloc(struct irq_domain *domain, { struct irq_alloc_info *info = arg; struct irq_data *irq_data; - struct irq_desc *desc; int ret = 0; if (!info || info->type != X86_IRQ_ALLOC_TYPE_IOAPIC || nr_irqs > 1) @@ -90,8 +89,7 @@ static int hyperv_irq_remapping_alloc(struct irq_domain *domain, * Hypver-V IO APIC irq affinity should be in the scope of * ioapic_max_cpumask because no irq remapping support. */ - desc = irq_data_to_desc(irq_data); - cpumask_copy(desc->irq_common_data.affinity, &ioapic_max_cpumask); + irq_data_update_affinity(irq_data, &ioapic_max_cpumask); return 0; }