diff mbox series

[v3,06/15] dmaengine: dw-edma: Use PCI_IRQ_MSI_TYPES where appropriate

Message ID 20200609091751.1065-1-piotr.stankiewicz@intel.com (mailing list archive)
State Superseded, archived
Headers show
Series [v3,01/15] PCI/MSI: Forward MSI-X vector enable error code in pci_alloc_irq_vectors_affinity() | expand

Commit Message

Piotr Stankiewicz June 9, 2020, 9:17 a.m. UTC
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 <piotr.stankiewicz@intel.com>
Reviewed-by: Andy Shevchenko <andriy.shevchenko@intel.com>
---
 drivers/dma/dw-edma/dw-edma-pcie.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

Comments

Andy Shevchenko June 9, 2020, 10:01 a.m. UTC | #1
On Tue, Jun 09, 2020 at 11:17:47AM +0200, Piotr Stankiewicz wrote:
> 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 <piotr.stankiewicz@intel.com>
> Reviewed-by: Andy Shevchenko <andriy.shevchenko@intel.com>

I think I saw somebody gave you tag here...
Am I mistaken?

...

>  	nr_irqs = pci_alloc_irq_vectors(pdev, 1, pdata->irqs,
> -					PCI_IRQ_MSI | PCI_IRQ_MSIX);
> +					PCI_IRQ_MSI_TYPES);

Now one line?
diff mbox series

Patch

diff --git a/drivers/dma/dw-edma/dw-edma-pcie.c b/drivers/dma/dw-edma/dw-edma-pcie.c
index dc85f55e1bb8..46defe30ac25 100644
--- a/drivers/dma/dw-edma/dw-edma-pcie.c
+++ b/drivers/dma/dw-edma/dw-edma-pcie.c
@@ -117,7 +117,7 @@  static int dw_edma_pcie_probe(struct pci_dev *pdev,
 
 	/* IRQs allocation */
 	nr_irqs = pci_alloc_irq_vectors(pdev, 1, pdata->irqs,
-					PCI_IRQ_MSI | PCI_IRQ_MSIX);
+					PCI_IRQ_MSI_TYPES);
 	if (nr_irqs < 1) {
 		pci_err(pdev, "fail to alloc IRQ vector (number of IRQs=%u)\n",
 			nr_irqs);