Re: [PATCH 2/2] iommu/amd: Force identity mode for selected GPUs only

Vasant Hegde <[email protected]> Wed, 5 Aug 2026 20:07:50 +0530
Newsgroups dev.linux.lists.iommu,org.kernel.vger.linux-pci
Message-ID <[email protected]>
Jason,


On 8/5/2026 6:37 AM, Jason Gunthorpe wrote:
> On Thu, Jul 30, 2026 at 04:56:37PM +0530, Vasant Hegde wrote:
> 
>> Based on discussion so far in this thread and the link Mario shared earlier [1]:
>>   - We still need identity mapping for APUs. I will fine tune the patch based on
>> the discussion in this thread.
> 
> IMHO if certain HW has broken support for PAGING (eg because it can't
> handle the isochronous needs) then it should be quirked and blocked
> properly.
> 
> I thought the issue here was the PASID check forcing identity and
> accidently capturing these raven chips too? It should just be moved
> out to a normal quirk..
> 
>>   - Its fine to drop SNP check
>>   - I am still not sure its safe to drop SME check (CC_ATTR_MEM_ENCRYPT)
>>     Because here were are putting all APUs in identity mode.
>>     Commit ea68573d408f explicitly error out for RAVEN and some of the older APU
>> platform didn't support SME. But not sure about newer ones.
> 
> That's quite a hacky check to make in that commit..
> 
>> So I am inclined to keep SME check for now. Once this patch stabilized we can
>> revisit the SME check?
> 
> The SME check makes no sense either, but if you want to stage things
> I'm OK with it.

Right. Eventually it should remove SME as well. But I am concerned about any
regression. Also I don't have all these devices to test it. Hence for now I will
limit to APUs, keep SME check and drop SNP check. Once it settle, we can go with
next step.

I will respin the patch later this week.

-Vasant