drm/i915: use effective_size for ringbuffer calculations
Subsystems (2)
PATCH v2 1/1 drm/i915: use effective_size for ringbuffer calculations
When calculating the available space in a ringbuffer, we should use the effective_size rather than the true size of the ring.
v2: rebase to latest drm-intel-nightly
Signed-off-by Dave Gordon <[email protected]>
--- drivers/gpu/drm/i915/intel_lrc.c | 2 +- drivers/gpu/drm/i915/intel_ringbuffer.c | 5 +++-- 2 files changed, 4 insertions(+), 3 deletions(-)
drivers/gpu/drm/i915/intel_lrc.c +1 -1
@@ -941,7 +941,7 @@ static int logical_ring_wait_request(struct intel_ringbuffer *ringbuf,/* Would completion of this request free enough space? */ if (__intel_ring_space (request->tail, ringbuf->tail, - ringbuf->size) >= bytes) { + ringbuf->effective_size) >= bytes) {break ; } }
drivers/gpu/drm/i915/intel_ringbuffer.c +3 -2
@@ -66,7 +66,8 @@ void intel_ring_update_space(struct intel_ringbuffer *ringbuf) } ringbuf->space =__intel_ring_space (ringbuf->head &HEAD_ADDR , - ringbuf->tail, ringbuf->size); + ringbuf->tail, + ringbuf->effective_size); }int intel_ring_space (struct intel_ringbuffer *ringbuf)
@@ -1932,7 +1933,7 @@ static int intel_ring_wait_request(struct intel_engine_cs *ring, int n)list_for_each_entry (request, &ring->request_list, list) {if (__intel_ring_space (request->tail, ringbuf->tail, - ringbuf->size) >= n) { + ringbuf->effective_size) >= n) {break ; } }
Signature · 6 lines
1.7.9.5 _______________________________________________ Intel-gfx mailing list [email protected] http://lists.freedesktop.org/mailman/listinfo/intel-gfx
-------------------------------------Summary-------------------------------------
Platform Delta drm-intel-nightly Series Applied
PNV -1 364/364 363/364
ILK +1-1 364/366 364/366
SNB -1 448/450 447/450 IVB -1 497/498 496/498 BYT -1 289/289 288/289 HSW -1 563/564 562/564 BDW -1 416/417 415/417 -------------------------------------Detailed------------------------------------- Platform Test drm-intel-nightly Series Applied PNV igt_gem_exec_blt NRUN(6, M23M7M25)PASS(1, M25) NRUN(1, M7) ILK igt_gem_exec_blt NRUN(7, M37M26)PASS(1, M26) NRUN(1, M37) ILK igt_kms_flip_bcs-flip-vs-modeset-interruptible DMESG_WARN(1, M26)PASS(10, M37M26) PASS(1, M37) SNB igt_gem_exec_blt NRUN(7, M35M22)PASS(1, M35) NRUN(1, M22) IVB igt_gem_exec_blt NRUN(7, M34M21M4)PASS(1, M34) NRUN(1, M34) BYT igt_gem_exec_blt NRUN(7, M48M49M50M51)PASS(1, M48) NRUN(1, M50) HSW igt_gem_exec_blt NRUN(7, M40M20M19)PASS(1, M40) NRUN(1, M19) BDW igt_gem_exec_blt NRUN(7, M30M28)PASS(1, M28) NRUN(1, M28)
Note: You need to pay more attention to line start with '*'
_______________________________________________
Intel-gfx mailing list [email protected]
http://lists.freedesktop.org/mailman/listinfo/intel-gfx