On Wed, 30 Apr 2025 at 20:16, Quentin Perret qperret@google.com wrote:
Not my area of expertise, but by a quick eyeball at the code it seems that there is already per-device logic to skip the set_memory_decrypted() calls and such. Specifically, force_dma_unencrypted(dev) does that, although it seems to only be plumbed with CC-A specific logic. Could that be extended for this use-case?
Right, I also saw that yesterday and it can be the perfect place to add the check. It only checks for realm-world right now IIRC, we can also check if DMA ops are registered for a device, and skip DMA encryption/decryption in that case.
I just wasn't sure if that's a hack or the right way to solve this :)
-- Viresh