-
- Downloads
accel/amdxdna: Add hardware context
The hardware can be shared among multiple user applications. The hardware resources are allocated/freed based on the request from user application via driver IOCTLs. DRM_IOCTL_AMDXDNA_CREATE_HWCTX Allocate tile columns and create a hardware context structure to track the usage and status of the resources. A hardware context ID is returned for XDNA command execution. DRM_IOCTL_AMDXDNA_DESTROY_HWCTX Release hardware context based on its ID. The tile columns belong to this hardware context will be reclaimed. DRM_IOCTL_AMDXDNA_CONFIG_HWCTX Config hardware context. Bind the hardware context to the required resources. Co-developed-by:Min Ma <min.ma@amd.com> Signed-off-by:
Min Ma <min.ma@amd.com> Reviewed-by:
Jeffrey Hugo <quic_jhugo@quicinc.com> Signed-off-by:
Lizhi Hou <lizhi.hou@amd.com> Signed-off-by:
Jeffrey Hugo <quic_jhugo@quicinc.com> Link: https://patchwork.freedesktop.org/patch/msgid/20241118172942.2014541-6-lizhi.hou@amd.com
Showing
- drivers/accel/amdxdna/Makefile 2 additions, 0 deletionsdrivers/accel/amdxdna/Makefile
- drivers/accel/amdxdna/aie2_ctx.c 186 additions, 0 deletionsdrivers/accel/amdxdna/aie2_ctx.c
- drivers/accel/amdxdna/aie2_message.c 90 additions, 0 deletionsdrivers/accel/amdxdna/aie2_message.c
- drivers/accel/amdxdna/aie2_pci.c 43 additions, 0 deletionsdrivers/accel/amdxdna/aie2_pci.c
- drivers/accel/amdxdna/aie2_pci.h 13 additions, 0 deletionsdrivers/accel/amdxdna/aie2_pci.h
- drivers/accel/amdxdna/amdxdna_ctx.c 219 additions, 0 deletionsdrivers/accel/amdxdna/amdxdna_ctx.c
- drivers/accel/amdxdna/amdxdna_ctx.h 39 additions, 0 deletionsdrivers/accel/amdxdna/amdxdna_ctx.h
- drivers/accel/amdxdna/amdxdna_pci_drv.c 124 additions, 1 deletiondrivers/accel/amdxdna/amdxdna_pci_drv.c
- drivers/accel/amdxdna/amdxdna_pci_drv.h 20 additions, 0 deletionsdrivers/accel/amdxdna/amdxdna_pci_drv.h
- include/uapi/drm/amdxdna_accel.h 131 additions, 0 deletionsinclude/uapi/drm/amdxdna_accel.h
Loading