Commit cb3d1085 authored by Alex Deucher's avatar Alex Deucher
Browse files

drm/amdgpu/ring: add no_scheduler flag



This allows IPs to flag whether a specific ring requires
a GPU scheduler or not.  E.g., sometimes instances of an
IP are asymmetric and have different capabilities.

Reviewed-by: default avatarChristian König <christian.koenig@amd.com>
Reviewed-by: default avatarHawking Zhang <Hawking.Zhang@amd.com>
Signed-off-by: default avatarAlex Deucher <alexander.deucher@amd.com>
parent e8663832
Loading
Loading
Loading
Loading
+2 −1
Original line number Diff line number Diff line
@@ -261,7 +261,8 @@ int amdgpu_ring_init(struct amdgpu_device *adev, struct amdgpu_ring *ring,
	mutex_init(&ring->priority_mutex);

	if (ring->funcs->type >= AMDGPU_RING_TYPE_GFX &&
	    ring->funcs->type <= AMDGPU_RING_TYPE_VCN_JPEG) {
	    ring->funcs->type <= AMDGPU_RING_TYPE_VCN_JPEG &&
	    !ring->no_scheduler) {
		hw_ip = ring->funcs->type;
		num_sched = &adev->gpu_sched[hw_ip][hw_prio].num_scheds;
		adev->gpu_sched[hw_ip][hw_prio].sched[(*num_sched)++] =
+1 −0
Original line number Diff line number Diff line
@@ -223,6 +223,7 @@ struct amdgpu_ring {
	unsigned		vm_inv_eng;
	struct dma_fence	*vmid_wait;
	bool			has_compute_vm_bug;
	bool			no_scheduler;

	atomic_t		num_jobs[DRM_SCHED_PRIORITY_MAX];
	struct mutex		priority_mutex;