diff options
author | Dave Airlie <airlied@redhat.com> | 2017-07-21 00:00:40 -0400 |
---|---|---|
committer | Dave Airlie <airlied@redhat.com> | 2017-07-21 00:00:40 -0400 |
commit | 22a548d04853297b3855dcac2881d0cb52e3b99c (patch) | |
tree | 3e7d64542b720f1618b4cf2d125acfa3176b487e /drivers/gpu/drm/amd/amdgpu | |
parent | 5771a8c08880cdca3bfb4a3fc6d309d6bba20877 (diff) | |
parent | f835edf9aec13bc8abb3dd4836151773cc359f42 (diff) |
Merge tag 'drm-amdkfd-fixes-2017-07-18' of git://people.freedesktop.org/~gabbayo/linux into drm-fixes
This is a pull request for 4.13-rc2/3. The first patch addresses a bug that
appears when doing over-subscription of queues, due to a miscalculation of
the number of available compute queues. The other three patches remove
dead code that was created from the bugfix.
* tag 'drm-amdkfd-fixes-2017-07-18' of git://people.freedesktop.org/~gabbayo/linux:
drm/amdgpu: Remove unused field kgd2kfd_shared_resources.num_mec
drm/radeon: Remove initialization of shared_resources.num_mec
drm/amdkfd: Remove unused references to shared_resources.num_mec
drm/amdgpu: Fix KFD oversubscription by tracking queues correctly
Diffstat (limited to 'drivers/gpu/drm/amd/amdgpu')
-rw-r--r-- | drivers/gpu/drm/amd/amdgpu/amdgpu_amdkfd.c | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_amdkfd.c b/drivers/gpu/drm/amd/amdgpu/amdgpu_amdkfd.c index 5f8ada1d872b..37971d9402e3 100644 --- a/drivers/gpu/drm/amd/amdgpu/amdgpu_amdkfd.c +++ b/drivers/gpu/drm/amd/amdgpu/amdgpu_amdkfd.c | |||
@@ -101,7 +101,6 @@ void amdgpu_amdkfd_device_init(struct amdgpu_device *adev) | |||
101 | if (adev->kfd) { | 101 | if (adev->kfd) { |
102 | struct kgd2kfd_shared_resources gpu_resources = { | 102 | struct kgd2kfd_shared_resources gpu_resources = { |
103 | .compute_vmid_bitmap = 0xFF00, | 103 | .compute_vmid_bitmap = 0xFF00, |
104 | .num_mec = adev->gfx.mec.num_mec, | ||
105 | .num_pipe_per_mec = adev->gfx.mec.num_pipe_per_mec, | 104 | .num_pipe_per_mec = adev->gfx.mec.num_pipe_per_mec, |
106 | .num_queue_per_pipe = adev->gfx.mec.num_queue_per_pipe | 105 | .num_queue_per_pipe = adev->gfx.mec.num_queue_per_pipe |
107 | }; | 106 | }; |
@@ -122,7 +121,7 @@ void amdgpu_amdkfd_device_init(struct amdgpu_device *adev) | |||
122 | 121 | ||
123 | /* According to linux/bitmap.h we shouldn't use bitmap_clear if | 122 | /* According to linux/bitmap.h we shouldn't use bitmap_clear if |
124 | * nbits is not compile time constant */ | 123 | * nbits is not compile time constant */ |
125 | last_valid_bit = adev->gfx.mec.num_mec | 124 | last_valid_bit = 1 /* only first MEC can have compute queues */ |
126 | * adev->gfx.mec.num_pipe_per_mec | 125 | * adev->gfx.mec.num_pipe_per_mec |
127 | * adev->gfx.mec.num_queue_per_pipe; | 126 | * adev->gfx.mec.num_queue_per_pipe; |
128 | for (i = last_valid_bit; i < KGD_MAX_QUEUES; ++i) | 127 | for (i = last_valid_bit; i < KGD_MAX_QUEUES; ++i) |