Re: [PATCH v5 1/4] PCI: Introduce pcim_alloc_irq_vectors()

2021-03-23 Thread Bjorn Helgaas
[+cc Christoph, Thomas, Alexander, in case you're interested] [+cc Jonathan, Kurt, Logan: vmd.c and switchtec.c use managed resources and pci_alloc_irq_vectors()] On Fri, Feb 26, 2021 at 11:50:53PM +0800, Dejin Zheng wrote: > Introduce pcim_alloc_irq_vectors(), a device-managed version of >

Re: [PATCH v5 1/4] PCI: Introduce pcim_alloc_irq_vectors()

2021-02-28 Thread Dejin Zheng
On Fri, Feb 26, 2021 at 06:23:02PM +0200, Andy Shevchenko wrote: > On Fri, Feb 26, 2021 at 11:50:53PM +0800, Dejin Zheng wrote: > > Introduce pcim_alloc_irq_vectors(), a device-managed version of > > pci_alloc_irq_vectors(). Introducing this function can simplify > > the error handling path in

Re: [PATCH v5 1/4] PCI: Introduce pcim_alloc_irq_vectors()

2021-02-26 Thread Andy Shevchenko
On Fri, Feb 26, 2021 at 11:50:53PM +0800, Dejin Zheng wrote: > Introduce pcim_alloc_irq_vectors(), a device-managed version of > pci_alloc_irq_vectors(). Introducing this function can simplify > the error handling path in many drivers. > > And use pci_free_irq_vectors() to replace some code in

[PATCH v5 1/4] PCI: Introduce pcim_alloc_irq_vectors()

2021-02-26 Thread Dejin Zheng
Introduce pcim_alloc_irq_vectors(), a device-managed version of pci_alloc_irq_vectors(). Introducing this function can simplify the error handling path in many drivers. And use pci_free_irq_vectors() to replace some code in pcim_release(), they are equivalent, and no functional change. It is more