[dpdk-dev] [PATCH v5 4/5] igb_uio: use msi mask functions from kernel, little corrections
Ferruh Yigit
ferruh.yigit at intel.com
Mon Sep 4 14:43:51 CEST 2017
On 8/31/2017 10:46 PM, Markus Theil wrote:
> This patch substitutes the custom MSI/MSI-X mask code and uses
> already existing kernel APIs. Feedback/small corrections to the previous
> patch of this series are also incorporated.
>
> Signed-off-by: Markus Theil <markus.theil at tu-ilmenau.de>
<...>
> + if (udev->mode == RTE_INTR_MODE_MSIX || udev->mode == RTE_INTR_MODE_MSI) {
> +#ifdef HAVE_PCI_MSI_MASK_IRQ
> + if (irq_state == 1)
> + pci_msi_unmask_irq(irq);
> + else
> + pci_msi_mask_irq(irq);
It is an option to keep using mask_msi_irq() without #ifdef, it seems in
newer version of the kernel mask_msi_irq() is already wrapper to the
pci_msi_mask_irq().
Although this may make the code simpler, it can break it if
mask_msi_irq() wrapper removed.
I would go with using mask_msi_irq() directly, but no strong opinion...
<...>
More information about the dev
mailing list