From mboxrd@z Thu Jan 1 00:00:00 1970 From: Jean-Philippe Brucker Subject: Re: [PATCH] iommu: Check for iommu_ops == NULL in iommu_probe_device() Date: Wed, 16 Jan 2019 16:33:51 +0000 Message-ID: <270d1c47-0752-68c7-e5ca-d19dcd170bbc@arm.com> References: <20181220090833.6643-1-joro@8bytes.org> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Return-path: In-Reply-To: Content-Language: en-US List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: iommu-bounces-cunTk1MwBs9QetFLy7KEm3xJsTq8ys+cHZ5vskTnxNA@public.gmane.org Errors-To: iommu-bounces-cunTk1MwBs9QetFLy7KEm3xJsTq8ys+cHZ5vskTnxNA@public.gmane.org To: Auger Eric , Joerg Roedel , iommu-cunTk1MwBs9QetFLy7KEm3xJsTq8ys+cHZ5vskTnxNA@public.gmane.org Cc: Joerg Roedel List-Id: iommu@lists.linux-foundation.org On 16/01/2019 15:27, Auger Eric wrote: > Hi Joerg, > > On 12/20/18 10:08 AM, Joerg Roedel wrote: >> From: Joerg Roedel >> >> This check needs to be there and got lost at some point >> during development. Add it again. >> >> Fixes: 641fb0efbff0 ('iommu/of: Don't call iommu_ops->add_device directly') > I experience a regression with those 2 patches. I have virtio-pci device > protected by virtual smmuv3 and in that case I get err = -EPROBE_DEFER > after pci_for_each_dma_alias() in of_iommu_configure(). When > iommu_probe_device is called, ops = NULL so it returns -EINVAL and err > is overwritten. So there is no deferred probing while it happened before. There is a fix on the list: https://www.spinics.net/lists/arm-kernel/msg698371.html Thanks, Jean