summaryrefslogtreecommitdiff
path: root/include/uapi
diff options
context:
space:
mode:
authorBrett Creeley <brett.creeley@amd.com>2025-03-20 12:44:11 -0700
committerJason Gunthorpe <jgg@nvidia.com>2025-03-21 20:57:55 -0300
commit92c66ee829b99a860a90f62ef16df3e42f92edac (patch)
tree02533c676755cca77ede76eea9c613505ecfe9e3 /include/uapi
parent4d09dd11d7d0e7e7f535c0abc7de19b9da6612e9 (diff)
pds_fwctl: add rpc and query support
The pds_fwctl driver doesn't know what RPC operations are available in the firmware, so also doesn't know what scope they might have. The userland utility supplies the firmware "endpoint" and "operation" id values and this driver queries the firmware for endpoints and their available operations. The operation descriptions include the scope information which the driver uses for scope testing. Link: https://patch.msgid.link/r/20250320194412.67983-6-shannon.nelson@amd.com Reviewed-by: Leon Romanovsky <leonro@nvidia.com> Signed-off-by: Brett Creeley <brett.creeley@amd.com> Reviewed-by: Jonathan Cameron <Jonathan.Cameron@huawei.com> Signed-off-by: Shannon Nelson <shannon.nelson@amd.com> Signed-off-by: Jason Gunthorpe <jgg@nvidia.com>
Diffstat (limited to 'include/uapi')
-rw-r--r--include/uapi/fwctl/pds.h30
1 files changed, 30 insertions, 0 deletions
diff --git a/include/uapi/fwctl/pds.h b/include/uapi/fwctl/pds.h
index 749bfb652f4d..66be32411642 100644
--- a/include/uapi/fwctl/pds.h
+++ b/include/uapi/fwctl/pds.h
@@ -29,4 +29,34 @@ enum pds_fwctl_capabilities {
PDS_FWCTL_QUERY_CAP = 0,
PDS_FWCTL_SEND_CAP,
};
+
+/**
+ * struct fwctl_rpc_pds
+ * @in.op: requested operation code
+ * @in.ep: firmware endpoint to operate on
+ * @in.rsvd: reserved
+ * @in.len: length of payload data
+ * @in.payload: address of payload buffer
+ * @in: rpc in parameters
+ * @out.retval: operation result value
+ * @out.rsvd: reserved
+ * @out.len: length of result data buffer
+ * @out.payload: address of payload data buffer
+ * @out: rpc out parameters
+ */
+struct fwctl_rpc_pds {
+ struct {
+ __u32 op;
+ __u32 ep;
+ __u32 rsvd;
+ __u32 len;
+ __aligned_u64 payload;
+ } in;
+ struct {
+ __u32 retval;
+ __u32 rsvd[2];
+ __u32 len;
+ __aligned_u64 payload;
+ } out;
+};
#endif /* _UAPI_FWCTL_PDS_H_ */