From: Jason Gunthorpe <jgg@nvidia.com>
To: "H. Nikolaus Schaller" <hns@goldelico.com>
Cc: Robin Murphy <robin.murphy@arm.com>,
Laurent Pinchart <laurent.pinchart@ideasonboard.com>,
"Rafael J. Wysocki" <rafael.j.wysocki@intel.com>,
Christoph Hellwig <hch@lst.de>,
Greg Kroah-Hartman <gregkh@linuxfoundation.org>,
Lu Baolu <baolu.lu@linux.intel.com>,
Jerry Snitselaar <jsnitsel@redhat.com>,
Joerg Roedel <jroedel@suse.de>, tony Lindgren <tony@atomide.com>,
Andreas Kemnade <andreas@kemnade.info>,
Linux-OMAP <linux-omap@vger.kernel.org>,
Linux Kernel Mailing List <linux-kernel@vger.kernel.org>,
linux-media@vger.kernel.org
Subject: Re: BUG: "iommu: Retire bus ops" breaks omap-iommu and omap3isp
Date: Mon, 7 Oct 2024 09:15:43 -0300 [thread overview]
Message-ID: <20241007121543.GM1365916@nvidia.com> (raw)
In-Reply-To: <A7C284A9-33A5-4E21-9B57-9C4C213CC13F@goldelico.com>
On Sun, Oct 06, 2024 at 09:40:00AM +0200, H. Nikolaus Schaller wrote:
> Hi,
>
> I found that the camera on our OMAP3 based system (GTA04) stopped working with v6.8-rc1.
> There was no bug in the camera driver but the OMAP3 ISP (image signal processor) emits
>
> [ 14.963684] omap3isp 480bc000.isp: failed to create ARM IOMMU mapping
> [ 15.010192] omap3isp 480bc000.isp: unable to attach to IOMMU
> [ 15.023376] omap3isp 480bc000.isp: isp_xclk_set_rate: cam_xclka set to 24685714 Hz (div 7)
> [ 15.065399] omap3isp: probe of 480bc000.isp failed with error -12
>
> Deeper analyses lead to this patch breaking operation. It is not fixed up to v6.12-rc1.
>
> What seems to happen (in 6.8-rc1 code):
>
> - omap_iommu_probe() passes &omap_iommu_ops to iommu_device_register()
> - iommu_device_register() stores the ops in iommu->ops (only)
> - __iommu_probe_device tries to read the ops from some fw_spec but not iommu->ops
Maybe like this?
@@ -1233,6 +1233,12 @@ static int omap_iommu_probe(struct platform_device *pdev)
err = iommu_device_register(&obj->iommu, &omap_iommu_ops, &pdev->dev);
if (err)
goto out_sysfs;
+ /*
+ * omap has a DT reprensetation but can't use the common DT
+ * code. Setting fwnode to NULL causes probe to be called for
+ * every device.
+ */
+ obj->iommu.fwnode = NULL;
obj->has_iommu_driver = true;
}
Jason
next prev parent reply other threads:[~2024-10-07 12:15 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-10-06 7:40 BUG: "iommu: Retire bus ops" breaks omap-iommu and omap3isp H. Nikolaus Schaller
2024-10-07 12:15 ` Jason Gunthorpe [this message]
2024-10-07 12:30 ` H. Nikolaus Schaller
2024-10-07 14:01 ` Andreas Kemnade
2024-10-07 14:48 ` Jason Gunthorpe
2024-10-07 16:31 ` Andreas Kemnade
2024-10-08 8:08 ` H. Nikolaus Schaller
2024-10-08 12:12 ` Jason Gunthorpe
2024-10-08 12:11 ` Robin Murphy
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20241007121543.GM1365916@nvidia.com \
--to=jgg@nvidia.com \
--cc=andreas@kemnade.info \
--cc=baolu.lu@linux.intel.com \
--cc=gregkh@linuxfoundation.org \
--cc=hch@lst.de \
--cc=hns@goldelico.com \
--cc=jroedel@suse.de \
--cc=jsnitsel@redhat.com \
--cc=laurent.pinchart@ideasonboard.com \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-media@vger.kernel.org \
--cc=linux-omap@vger.kernel.org \
--cc=rafael.j.wysocki@intel.com \
--cc=robin.murphy@arm.com \
--cc=tony@atomide.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.