mirror of
https://github.com/AuxXxilium/linux_dsm_epyc7002.git
synced 2024-12-04 16:16:46 +07:00
drm fixes for 5.6-rc8/final
radeon/amdgpu/dma-buf: - sg list fixes scheduler: - oops fix -----BEGIN PGP SIGNATURE----- iQIcBAABAgAGBQJefaN4AAoJEAx081l5xIa+eakQAJYLuWSybs1/FwUybqnuv1BF c9EiMf1XPt78wTM5hVI/7xv/0ZUW++p3FkioSKUxYWejDcZCZ16gVUw2Byh/eBWl OIcVgjDZTO7z14/fgApqYjWrmmftwfg59LOvc44pZXNHyTIgJMCEbidTQy5dj7xW NqWXXOokhgZPYZI2fAlkk9PVkSc9QaJTJCiWh8lSR4smQRHjF5uiiwwvYY3h33Nk 5hpH95kgHU6npke1t0EXrGdJtq1tdwDeqUoGkWNwWxQ405mPyBan7zC4zzSKJjbH UKO+TaFJQQ2ycXTmgVx2KRpIOQa6g2vBYKVs98EylgO32P443D8nIUI4foDO7GY2 31rwK7GZfHTLWCOfFMNM4V+8dEwZJZYpbLOIc/4+zaufzBLwntLDZM/O9Dky9UU4 ZQKfFU4Q16Cy8ceVVdFmBn8fv+/Zn6wFewT4qXDtsuekjnD+HCCP7p5dxIGOBn89 SOoEH8b77TqnGEqJxf/XTeXIMvd2O3ZLeszMQyI4v/2YQzH+DkFY6OUchP6YwaCv 9/93T/e0sq7a6C18B9x70sTfAeGuza3R1BYd1RoCyDdn2H103i7Fm/E8Pu0JXOep 4GxU8GpGvaP2akZsB5WIcVz6ADaDPGtZvL/uooCans+LixgQMaGAAWgF97DWMjd7 B+g7bFio8qYqD+BIp6Sy =ukHW -----END PGP SIGNATURE----- Merge tag 'drm-fixes-2020-03-27' of git://anongit.freedesktop.org/drm/drm Pull drm fixes from Dave Airlie: "Pretty quiet: some minor sg mapping fixes for 3 drivers, and a single oops fix for the scheduler. I'm hoping nobody tries to send me a fixes pull today but I'll keep an eye out of the weekend. radeon/amdgpu/dma-buf: - sg list fixes scheduler: - oops fix" * tag 'drm-fixes-2020-03-27' of git://anongit.freedesktop.org/drm/drm: drm/scheduler: fix rare NULL ptr race drm/radeon: fix scatter-gather mapping with user pages drm/amdgpu: fix scatter-gather mapping with user pages drm/prime: use dma length macro when mapping sg
This commit is contained in:
commit
7bf8df68cb
@ -974,7 +974,7 @@ static int amdgpu_ttm_tt_pin_userptr(struct ttm_tt *ttm)
|
||||
/* Map SG to device */
|
||||
r = -ENOMEM;
|
||||
nents = dma_map_sg(adev->dev, ttm->sg->sgl, ttm->sg->nents, direction);
|
||||
if (nents != ttm->sg->nents)
|
||||
if (nents == 0)
|
||||
goto release_sg;
|
||||
|
||||
/* convert SG to linear array of pages and dma addresses */
|
||||
|
@ -967,7 +967,7 @@ int drm_prime_sg_to_page_addr_arrays(struct sg_table *sgt, struct page **pages,
|
||||
|
||||
index = 0;
|
||||
for_each_sg(sgt->sgl, sg, sgt->nents, count) {
|
||||
len = sg->length;
|
||||
len = sg_dma_len(sg);
|
||||
page = sg_page(sg);
|
||||
addr = sg_dma_address(sg);
|
||||
|
||||
|
@ -528,7 +528,7 @@ static int radeon_ttm_tt_pin_userptr(struct ttm_tt *ttm)
|
||||
|
||||
r = -ENOMEM;
|
||||
nents = dma_map_sg(rdev->dev, ttm->sg->sgl, ttm->sg->nents, direction);
|
||||
if (nents != ttm->sg->nents)
|
||||
if (nents == 0)
|
||||
goto release_sg;
|
||||
|
||||
drm_prime_sg_to_page_addr_arrays(ttm->sg, ttm->pages,
|
||||
|
@ -661,7 +661,9 @@ static void drm_sched_process_job(struct dma_fence *f, struct dma_fence_cb *cb)
|
||||
|
||||
trace_drm_sched_process_job(s_fence);
|
||||
|
||||
dma_fence_get(&s_fence->finished);
|
||||
drm_sched_fence_finished(s_fence);
|
||||
dma_fence_put(&s_fence->finished);
|
||||
wake_up_interruptible(&sched->wake_up_worker);
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user