Received: by 2002:a25:683:0:0:0:0:0 with SMTP id 125csp1141095ybg; Tue, 2 Jun 2020 02:22:34 -0700 (PDT) X-Google-Smtp-Source: ABdhPJwE4oQKEZYVBrcdD0gPCXPb5HodlLM1UoAuDAiSzi576kBu8/BK08ooiIyCtgyE2JcXJiK7 X-Received: by 2002:a05:6402:8d1:: with SMTP id d17mr24618697edz.38.1591089754001; Tue, 02 Jun 2020 02:22:34 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1591089753; cv=none; d=google.com; s=arc-20160816; b=mPTNiqBjv6ceBQ8GcoAmczrqqiwYls0XVJrnBFMDatMMt863/FOnlpJestXAFsHh8y yVnWGZZn8XqnqiIIeb7VFOws2QPEZ+/lhjKifzXDDv8NJtIonpppLtcaerok+0m9cwIL wVjdwB8dReEsw9ovI+42rJkAbjQe/sbasVSWYqB7JMaLNOXDxE3CliMvH561Qll4uvMH /u/Yb/Hy7cwPO5Ez7EhzcKcVOrCS7B4jm55cBO2r2lCC1zAgxJhlqK15kaWWKOvT2dIg qt088MX2aJKRb2bfkhrHaOu9m+SYlS4rYZMD29M6NDknqepk31BItRZCuTflqDr2WH06 VwOA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:message-id:date:subject:cc:to:from :ironport-sdr:ironport-sdr; bh=pxeu9DttRbx5d38joxuR/Ooo3n01DBvkzEd290L33vc=; b=ejYChiqfcWpTugyIDomf3javIhqQN3H+MAjxBMKvw1DiBlZd/8XoqVB0wa/Rl9sUDm VO63CO8LP7GYDvllInqHKJdVnuSnII2diLmCtikDIWMVtyrmmLhjR8tBTyXmwCfTHGZx xvLVsw1+/RxReoWBwbcWJy06vM/pKOF5pPILeOvlWw0Zy3uKu1wN9CuVYgB9a/0Q3OU1 4M6ZthMt6GdSFYUth2Uqn0cQ8XB+gyAy554Z3NUl/hdg0fiZFMBUT7CYARwJPrx3D4m1 xrvJl8RBUgBEVGzkzRNdiYuvXAPq/Wm7w+WTNdQRRzIHO7W/d47LbXWyafdrIS0cyCAl XxhQ== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=intel.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id bq22si1129256ejb.685.2020.06.02.02.22.10; Tue, 02 Jun 2020 02:22:33 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=intel.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726894AbgFBJUP (ORCPT + 99 others); Tue, 2 Jun 2020 05:20:15 -0400 Received: from mga07.intel.com ([134.134.136.100]:59541 "EHLO mga07.intel.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726160AbgFBJUO (ORCPT ); Tue, 2 Jun 2020 05:20:14 -0400 IronPort-SDR: cw3gNLpb9D/O+pySl16xQ73cT9qMrPOVGzVA49sesGC6P01849v2tHs0rUQClDBujBF+5BAwf4 Gdq86j2IcjVA== X-Amp-Result: SKIPPED(no attachment in message) X-Amp-File-Uploaded: False Received: from orsmga005.jf.intel.com ([10.7.209.41]) by orsmga105.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 02 Jun 2020 02:20:13 -0700 IronPort-SDR: +cEGgRuOAVk6LQEdohGj4ySKkGpeHf2YtOTtWXaONxCBeJcXpx6a+OIsG7/ikgMAGrlIty66iD SFpNLQE7Rjng== X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.73,463,1583222400"; d="scan'208";a="444621223" Received: from gklab-125-110.igk.intel.com ([10.91.125.110]) by orsmga005.jf.intel.com with ESMTP; 02 Jun 2020 02:20:10 -0700 From: Piotr Stankiewicz To: Bjorn Helgaas , Kurt Schwemmer , Logan Gunthorpe Cc: linux-pci@vger.kernel.org, linux-kernel@vger.kernel.org, Piotr Stankiewicz Subject: [PATCH 03/15] PCI: use PCI_IRQ_MSI_TYPES where appropriate Date: Tue, 2 Jun 2020 11:20:02 +0200 Message-Id: <20200602092002.31787-1-piotr.stankiewicz@intel.com> X-Mailer: git-send-email 2.17.2 Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Seeing as there is shorthand available to use when asking for any type of interrupt, or any type of message signalled interrupt, leverage it. Signed-off-by: Piotr Stankiewicz Reviewed-by: Andy Shevchenko --- drivers/pci/pcie/portdrv_core.c | 4 ++-- drivers/pci/switch/switchtec.c | 3 +-- 2 files changed, 3 insertions(+), 4 deletions(-) diff --git a/drivers/pci/pcie/portdrv_core.c b/drivers/pci/pcie/portdrv_core.c index 50a9522ab07d..2a38a918ba12 100644 --- a/drivers/pci/pcie/portdrv_core.c +++ b/drivers/pci/pcie/portdrv_core.c @@ -105,7 +105,7 @@ static int pcie_port_enable_irq_vec(struct pci_dev *dev, int *irqs, int mask) /* Allocate the maximum possible number of MSI/MSI-X vectors */ nr_entries = pci_alloc_irq_vectors(dev, 1, PCIE_PORT_MAX_MSI_ENTRIES, - PCI_IRQ_MSIX | PCI_IRQ_MSI); + PCI_IRQ_MSI_TYPES); if (nr_entries < 0) return nr_entries; @@ -131,7 +131,7 @@ static int pcie_port_enable_irq_vec(struct pci_dev *dev, int *irqs, int mask) pci_free_irq_vectors(dev); nr_entries = pci_alloc_irq_vectors(dev, nvec, nvec, - PCI_IRQ_MSIX | PCI_IRQ_MSI); + PCI_IRQ_MSI_TYPES); if (nr_entries < 0) return nr_entries; } diff --git a/drivers/pci/switch/switchtec.c b/drivers/pci/switch/switchtec.c index e69cac84b605..11fbe9c6b201 100644 --- a/drivers/pci/switch/switchtec.c +++ b/drivers/pci/switch/switchtec.c @@ -1442,8 +1442,7 @@ static int switchtec_init_isr(struct switchtec_dev *stdev) nirqs = 4; nvecs = pci_alloc_irq_vectors(stdev->pdev, 1, nirqs, - PCI_IRQ_MSIX | PCI_IRQ_MSI | - PCI_IRQ_VIRTUAL); + PCI_IRQ_MSI_TYPES | PCI_IRQ_VIRTUAL); if (nvecs < 0) return nvecs; -- 2.17.2