From: Tomasz Jeznach Date: Wed, 16 Oct 2024 20:40:25 +0000 (-0300) Subject: exec/memtxattr: add process identifier to the transaction attributes X-Git-Tag: v9.2.0-rc0~28^2~14 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=c6f3443af1bb61f25126861f33ede06b56c0ee85;p=thirdparty%2Fqemu.git exec/memtxattr: add process identifier to the transaction attributes Extend memory transaction attributes with process identifier to allow per-request address translation logic to use requester_id / process_id to identify memory mapping (e.g. enabling IOMMU w/ PASID translations). Signed-off-by: Tomasz Jeznach Reviewed-by: Frank Chang Reviewed-by: Jason Chien Reviewed-by: Alistair Francis Signed-off-by: Daniel Henrique Barboza Message-ID: <20241016204038.649340-2-dbarboza@ventanamicro.com> Signed-off-by: Alistair Francis --- diff --git a/include/exec/memattrs.h b/include/exec/memattrs.h index 14cdd8d5824..e27c18f3dc3 100644 --- a/include/exec/memattrs.h +++ b/include/exec/memattrs.h @@ -52,6 +52,11 @@ typedef struct MemTxAttrs { unsigned int memory:1; /* Requester ID (for MSI for example) */ unsigned int requester_id:16; + + /* + * PID (PCI PASID) support: Limited to 8 bits process identifier. + */ + unsigned int pid:8; } MemTxAttrs; /* Bus masters which don't specify any attributes will get this,