Re: [PATCH] iommu: explicitly check for NULL in iommu_dma_get_resv_regions()

2022-02-11 Thread Aleksandr Fedorov
> On 2022-02-09 14:09, Aleksandr Fedorov wrote: >> iommu_dma_get_resv_regions() assumes that iommu_fwspec field for >> corresponding device is set which is not always true. Since >> iommu_dma_get_resv_regions() seems to be a future-proof generic API >> that can be used by any iommu driver, add an

Re: [PATCH] iommu: explicitly check for NULL in iommu_dma_get_resv_regions()

2022-02-10 Thread Robin Murphy
On 2022-02-09 14:09, Aleksandr Fedorov wrote: iommu_dma_get_resv_regions() assumes that iommu_fwspec field for corresponding device is set which is not always true. Since iommu_dma_get_resv_regions() seems to be a future-proof generic API that can be used by any iommu driver, add an explicit

[PATCH] iommu: explicitly check for NULL in iommu_dma_get_resv_regions()

2022-02-09 Thread Aleksandr Fedorov
iommu_dma_get_resv_regions() assumes that iommu_fwspec field for corresponding device is set which is not always true. Since iommu_dma_get_resv_regions() seems to be a future-proof generic API that can be used by any iommu driver, add an explicit check for NULL. Currently it can work by accident