[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20211126223824.914161382@linutronix.de>
Date: Sat, 27 Nov 2021 02:18:56 +0100 (CET)
From: Thomas Gleixner <tglx@...utronix.de>
To: LKML <linux-kernel@...r.kernel.org>
Cc: Bjorn Helgaas <helgaas@...nel.org>, Marc Zygnier <maz@...nel.org>,
Alex Williamson <alex.williamson@...hat.com>,
Kevin Tian <kevin.tian@...el.com>,
Jason Gunthorpe <jgg@...dia.com>,
Megha Dey <megha.dey@...el.com>,
Ashok Raj <ashok.raj@...el.com>, linux-pci@...r.kernel.org,
Michael Ellerman <mpe@...erman.id.au>,
Paul Mackerras <paulus@...ba.org>,
Benjamin Herrenschmidt <benh@...nel.crashing.org>,
linuxppc-dev@...ts.ozlabs.org,
Thomas Bogendoerfer <tsbogend@...ha.franken.de>,
linux-mips@...r.kernel.org,
Greg Kroah-Hartman <gregkh@...uxfoundation.org>,
sparclinux@...r.kernel.org, x86@...nel.org,
xen-devel@...ts.xenproject.org, ath11k@...ts.infradead.org,
Wei Liu <wei.liu@...nel.org>, linux-hyperv@...r.kernel.org,
Juergen Gross <jgross@...e.com>,
Christian Borntraeger <borntraeger@...ibm.com>,
Heiko Carstens <hca@...ux.ibm.com>
Subject: [patch 14/22] PCI/MSI: Make msix_update_entries() smarter
No need to walk the descriptors and check for each one whether the entries
pointer function argument is NULL. Do it once.
Signed-off-by: Thomas Gleixner <tglx@...utronix.de>
---
drivers/pci/msi.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
--- a/drivers/pci/msi.c
+++ b/drivers/pci/msi.c
@@ -642,8 +642,8 @@ static void msix_update_entries(struct p
{
struct msi_desc *entry;
- for_each_pci_msi_entry(entry, dev) {
- if (entries) {
+ if (entries) {
+ for_each_pci_msi_entry(entry, dev) {
entries->vector = entry->irq;
entries++;
}
Powered by blists - more mailing lists