OpenCloudOS-Kernel/drivers/accel
Jacek Lawrynowicz 647371a660 accel/ivpu: Add GEM buffer object management
Adds four types of GEM-based BOs for the VPU:
  - shmem
  - internal
  - prime

All types are implemented as struct ivpu_bo, based on
struct drm_gem_object. VPU address is allocated when buffer is created
except for imported prime buffers that allocate it in BO_INFO IOCTL due
to missing file_priv arg in gem_prime_import callback.
Internal buffers are pinned on creation, the rest of buffers types
can be pinned on demand (in SUBMIT IOCTL).
Buffer VPU address, allocated pages and mappings are released when the
buffer is destroyed.
Eviction mechanism is planned for future versions.

Add two new IOCTLs: BO_CREATE, BO_INFO

Signed-off-by: Jacek Lawrynowicz <jacek.lawrynowicz@linux.intel.com>
Reviewed-by: Oded Gabbay <ogabbay@kernel.org>
Reviewed-by: Jeffrey Hugo <quic_jhugo@quicinc.com>
Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
Link: https://patchwork.freedesktop.org/patch/msgid/20230117092723.60441-4-jacek.lawrynowicz@linux.intel.com
2023-01-19 11:11:34 +01:00
..
ivpu accel/ivpu: Add GEM buffer object management 2023-01-19 11:11:34 +01:00
Kconfig accel/ivpu: Introduce a new DRM driver for Intel VPU 2023-01-19 11:07:01 +01:00
Makefile accel/ivpu: Introduce a new DRM driver for Intel VPU 2023-01-19 11:07:01 +01:00
drm_accel.c Fix mismerge due to devnode now taking a 'const *' device 2022-12-16 13:04:15 -06:00