Re: [PATCHv2 02/16] iommu/omap: omap_iommu_attach() should return ENODEV, not NULL

2014-02-26 Thread Suman Anna
Hi Laurent, On Tuesday 25 February 2014 16:32:03 Suman Anna wrote: On 02/25/2014 03:13 PM, Laurent Pinchart wrote: On Thursday 13 February 2014 12:15:33 Suman Anna wrote: From: Florian Vaussard florian.vauss...@epfl.ch omap_iommu_attach() returns NULL or ERR_PTR in case of error, but

Re: [PATCHv2 02/16] iommu/omap: omap_iommu_attach() should return ENODEV, not NULL

2014-02-25 Thread Laurent Pinchart
Hi Suman, Thank you for the patch. On Thursday 13 February 2014 12:15:33 Suman Anna wrote: From: Florian Vaussard florian.vauss...@epfl.ch omap_iommu_attach() returns NULL or ERR_PTR in case of error, but omap_iommu_attach_dev() only checks for IS_ERR. Thus a NULL return value (in case

Re: [PATCHv2 02/16] iommu/omap: omap_iommu_attach() should return ENODEV, not NULL

2014-02-25 Thread Suman Anna
Hi Laurent, On 02/25/2014 03:13 PM, Laurent Pinchart wrote: Hi Suman, Thank you for the patch. On Thursday 13 February 2014 12:15:33 Suman Anna wrote: From: Florian Vaussard florian.vauss...@epfl.ch omap_iommu_attach() returns NULL or ERR_PTR in case of error, but omap_iommu_attach_dev()

Re: [PATCHv2 02/16] iommu/omap: omap_iommu_attach() should return ENODEV, not NULL

2014-02-25 Thread Laurent Pinchart
Hi Suman, On Tuesday 25 February 2014 16:32:03 Suman Anna wrote: On 02/25/2014 03:13 PM, Laurent Pinchart wrote: On Thursday 13 February 2014 12:15:33 Suman Anna wrote: From: Florian Vaussard florian.vauss...@epfl.ch omap_iommu_attach() returns NULL or ERR_PTR in case of error, but

[PATCHv2 02/16] iommu/omap: omap_iommu_attach() should return ENODEV, not NULL

2014-02-13 Thread Suman Anna
From: Florian Vaussard florian.vauss...@epfl.ch omap_iommu_attach() returns NULL or ERR_PTR in case of error, but omap_iommu_attach_dev() only checks for IS_ERR. Thus a NULL return value (in case driver_find_device fails) will cause the kernel to panic when omap_iommu_attach_dev() dereferences