Quoting Mika Kuoppala (2017-09-12 09:36:18) > static void execlists_dequeue(struct intel_engine_cs *engine) > { > - struct drm_i915_gem_request *last; > struct intel_engine_execlist * const el = &engine->execlist; > - struct execlist_port *port = execlist_port_head(el); > - const struct execlist_port * const last_port = execlist_port_tail(el); > + struct execlist_port *port; > + struct drm_i915_gem_request *last; > struct rb_node *rb; > bool submit = false; > > - last = port_request(port); > - if (last) > + if (execlist_active_ports(el)) { > + port = execlist_port_tail(el); > + last = port_request(port); > + > /* WaIdleLiteRestore:bdw,skl > * Apply the wa NOOPs to prevent ring:HEAD == req:TAIL > * as we resubmit the request. See gen8_emit_breadcrumb() > @@ -414,6 +419,10 @@ static void execlists_dequeue(struct intel_engine_cs > *engine) > * request. > */ > last->tail = last->wa_tail; > + } else { > + port = NULL; > + last = NULL; > + } > > /* Hardware submission is through 2 ports. Conceptually each port > * has a (RING_START, RING_HEAD, RING_TAIL) tuple. RING_START is > @@ -443,6 +452,9 @@ static void execlists_dequeue(struct intel_engine_cs > *engine) > struct i915_priolist *p = rb_entry(rb, typeof(*p), node); > struct drm_i915_gem_request *rq, *rn; > > + if (!port) > + port = execlist_request_port(el); > + > list_for_each_entry_safe(rq, rn, &p->requests, priotree.link) > { > /* > * Can we combine this request with the current port? > @@ -461,7 +473,7 @@ static void execlists_dequeue(struct intel_engine_cs > *engine) > * combine this request with the last, then we > * are done. > */
The comment above is now confused, so /* * If we are on the last port and cannot combine * this request with the previous, then we are * done. */ -Chris _______________________________________________ Intel-gfx mailing list Intel-gfx@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/intel-gfx