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 vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id CA337C433EF for ; Thu, 16 Dec 2021 21:41:18 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S241934AbhLPVlQ (ORCPT ); Thu, 16 Dec 2021 16:41:16 -0500 Received: from Galois.linutronix.de ([193.142.43.55]:57042 "EHLO galois.linutronix.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S241726AbhLPVkd (ORCPT ); Thu, 16 Dec 2021 16:40:33 -0500 Date: Thu, 16 Dec 2021 21:40:31 -0000 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linutronix.de; s=2020; t=1639690832; 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=oiV5Am9Gtgo6ubA/1E1L8M6rup4KNwD60I7rIr5kJ3c=; b=Gt3M4BWEvnlKJCHfg0PMvujEYJkTcfZwN4eHdV/tZLy+9cJx0g/AqFnhnZ2QQndF8CGzNZ rEXTzw/HzLEnW5ZSLHn9b9L8wPju5sSI9wCtc2kg9vNPsP2U0qy09rKW333hDK1ki4a78e D38Ffn31A5NL1+OMtLf2zI65IlcvFKh2jD36/zNozU84W9bYNXaPac90ols/yG6fDemC35 hzLJaIlPvrlz7uxN7hO10S+6/EN19XO658jrXhf8cx1Vf1Egvej257gqT6YIONi17aAVeH pzAOvpqpHxD3TpBTlZAjd3O39/Mjj/pWcHAoCciFuTOFFFc+N7FzTAa/ztDLnw== DKIM-Signature: v=1; a=ed25519-sha256; c=relaxed/relaxed; d=linutronix.de; s=2020e; t=1639690832; 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=oiV5Am9Gtgo6ubA/1E1L8M6rup4KNwD60I7rIr5kJ3c=; b=wX8gJq5xv82QfXq2YNzv6wTODN0kuyBBBkNX47XEKanVRyJqCkAYEdqE7rqZ/VBZd/0mkG l1fVeDEem4N9qRAw== From: "tip-bot2 for Thomas Gleixner" Sender: tip-bot2@linutronix.de Reply-to: linux-kernel@vger.kernel.org To: linux-tip-commits@vger.kernel.org Subject: [tip: irq/msi] powerpc/pasemi/msi: Convert to msi_on_each_dec() Cc: Thomas Gleixner , Jason Gunthorpe , x86@kernel.org, linux-kernel@vger.kernel.org In-Reply-To: <20211206210748.468512783@linutronix.de> References: <20211206210748.468512783@linutronix.de> MIME-Version: 1.0 Message-ID: <163969083183.23020.13468707208989147673.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 Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org The following commit has been merged into the irq/msi branch of tip: Commit-ID: e22b0d1bbf5bd71ed2b2fb54a257b5cc38c351c3 Gitweb: https://git.kernel.org/tip/e22b0d1bbf5bd71ed2b2fb54a257b5cc38c351c3 Author: Thomas Gleixner AuthorDate: Mon, 06 Dec 2021 23:51:28 +01:00 Committer: Thomas Gleixner CommitterDate: Thu, 16 Dec 2021 22:22:18 +01:00 powerpc/pasemi/msi: Convert to msi_on_each_dec() Replace the about to vanish iterators and make use of the filtering. Signed-off-by: Thomas Gleixner Reviewed-by: Jason Gunthorpe Link: https://lore.kernel.org/r/20211206210748.468512783@linutronix.de --- arch/powerpc/platforms/pasemi/msi.c | 9 ++------- 1 file changed, 2 insertions(+), 7 deletions(-) diff --git a/arch/powerpc/platforms/pasemi/msi.c b/arch/powerpc/platforms/pasemi/msi.c index d38944a..e8af722 100644 --- a/arch/powerpc/platforms/pasemi/msi.c +++ b/arch/powerpc/platforms/pasemi/msi.c @@ -62,17 +62,12 @@ static void pasemi_msi_teardown_msi_irqs(struct pci_dev *pdev) pr_debug("pasemi_msi_teardown_msi_irqs, pdev %p\n", pdev); - for_each_pci_msi_entry(entry, pdev) { - if (!entry->irq) - continue; - + msi_for_each_desc(entry, &pdev->dev, MSI_DESC_ASSOCIATED) { hwirq = virq_to_hw(entry->irq); irq_set_msi_desc(entry->irq, NULL); irq_dispose_mapping(entry->irq); msi_bitmap_free_hwirqs(&msi_mpic->msi_bitmap, hwirq, ALLOC_CHUNK); } - - return; } static int pasemi_msi_setup_msi_irqs(struct pci_dev *pdev, int nvec, int type) @@ -90,7 +85,7 @@ static int pasemi_msi_setup_msi_irqs(struct pci_dev *pdev, int nvec, int type) msg.address_hi = 0; msg.address_lo = PASEMI_MSI_ADDR; - for_each_pci_msi_entry(entry, pdev) { + msi_for_each_desc(entry, &pdev->dev, MSI_DESC_NOTASSOCIATED) { /* Allocate 16 interrupts for now, since that's the grouping for * affinity. This can be changed later if it turns out 32 is too * few MSIs for someone, but restrictions will apply to how the