Re: [PATCH 06/17] vfio/pci: Remove interrupt index interpretation from wrappers

From: Reinette Chatre
Date: Tue Feb 06 2024 - 16:45:15 EST


Hi Alex,

On 2/5/2024 2:35 PM, Alex Williamson wrote:
> On Thu, 1 Feb 2024 20:57:00 -0800
> Reinette Chatre <reinette.chatre@xxxxxxxxx> wrote:

>> @@ -413,8 +415,10 @@ static int vfio_msi_alloc_irq(struct vfio_pci_core_device *vdev,
>> }
>>
>> static int vfio_msi_set_vector_signal(struct vfio_pci_core_device *vdev,
>> - unsigned int vector, int fd, bool msix)
>> + unsigned int vector, int fd,
>> + unsigned int index)
>> {
>> + bool msix = (index == VFIO_PCI_MSIX_IRQ_INDEX) ? true : false;
>
> Cleanup the unnecessary ternary while here, this can just be:
>
> bool msix = (index == VFIO_PCI_MSIX_IRQ_INDEX);
>

Will do. Thank you.

Reinette