Re: [PATCH] serial: 8250_exar: Add missing call to pci_free_irq_vectors()

From: Andy Shevchenko
Date: Tue Aug 17 2021 - 13:39:03 EST


On Tue, Aug 17, 2021 at 10:30:57PM +0530, Utkarsh Verma wrote:
> Free the pci irq vectors if the call to pci_alloc_irq_vectors() fails
> or if the device is removed.

...

> rc = pci_alloc_irq_vectors(pcidev, 1, 1, PCI_IRQ_ALL_TYPES);
> - if (rc < 0)
> + if (rc < 0) {

> + pci_free_irq_vectors(pcidev);

Why?

--
With Best Regards,
Andy Shevchenko