lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <ee24cb5f-d170-41d3-9928-5507b8ab22a7@nvidia.com>
Date: Fri, 12 Jul 2024 16:24:48 +0100
From: Jon Hunter <jonathanh@...dia.com>
To: Robin Murphy <robin.murphy@....com>, Will Deacon <will@...nel.org>,
 Joerg Roedel <joro@...tes.org>
Cc: linux-acpi@...r.kernel.org, linux-arm-kernel@...ts.infradead.org,
 linux-kernel@...r.kernel.org, iommu@...ts.linux.dev,
 devicetree@...r.kernel.org, Rob Herring <robh@...nel.org>,
 Saravana Kannan <saravanak@...gle.com>,
 Lorenzo Pieralisi <lpieralisi@...nel.org>, Hanjun Guo
 <guohanjun@...wei.com>, Sudeep Holla <sudeep.holla@....com>,
 "Rafael J. Wysocki" <rafael@...nel.org>, Len Brown <lenb@...nel.org>,
 Jean-Philippe Brucker <jean-philippe@...aro.org>,
 Andy Shevchenko <andy.shevchenko@...il.com>, Yong Wu <yong.wu@...iatek.com>,
 "linux-tegra@...r.kernel.org" <linux-tegra@...r.kernel.org>
Subject: Re: [PATCH v3 2/5] iommu: Resolve fwspec ops automatically


On 12/07/2024 12:48, Robin Murphy wrote:

...

>> I am seeing some failures on -next with some of our devices. Bisect is 
>> pointing to this commit. Looks like the host1x device is no longer 
>> probing successfully. I see the following ...
>>
>>   tegra-host1x 50000000.host1x: failed to initialize fwspec: -517
>>   nouveau 57000000.gpu: failed to initialize fwspec: -517
>>
>> The probe seems to be deferred forever. The above is seen on Tegra210 
>> but Tegra30 and Tegra194 are also having the same problem. 
>> Interestingly it is not all devices and so make me wonder if we are 
>> missing something on these devices? Let me know if you have any thoughts.
> 
> Ugh, tegra-smmu has been doing a complete nonsense this whole time - on 
> closer inspection, it's passing the fwnode of the *client device* where 
> it should be that of the IOMMU device :(
> 
> I *think* it should probably just be a case of:
> 
> -    err = iommu_fwspec_init(dev, of_fwnode_handle(dev->of_node));
> +    err = iommu_fwspec_init(dev, of_fwnode_handle(smmu->dev->of_node));
> 
> since smmu->dev appears to be the same one initially passed to 
> iommu_device_register(), so it at least ought to match and work, but the 
> SMMU device vs. MC device thing leaves me mildly wary of how correct it 
> might be overall.
> 
> (Also now I'm wondering why I didn't just use dev_fwnode() there...)


Yes making that change in the tegra-smmu driver does fix it.

Thanks!
Jon

-- 
nvpublic

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ