On Tue, 2026-06-09 at 14:39 +0100, Tvrtko Ursulin wrote:
> 
> On 03/06/2026 10:14, Tvrtko Ursulin wrote:
> > 
> > On 03/06/2026 09:37, Philipp Stanner wrote:
> > > On Tue, 2026-06-02 at 16:33 +0100, Tvrtko Ursulin wrote:
> > > > Commit
> > > > 28c5bf28763d ("drm/sched: Disallow initializing entities with no 
> > > > schedulers")
> > > > failed to notice clearing of entity->rq in drm_sched_entity_init() is 
> > > > now
> > > 
> > > By clearing you also mean the setting to NULL?
> > > 
> > > I'd just use "initialization" consistently, like in the commit title.
> > 
> > It is initialized properly a bit lower down so clearing is I think more 
> > accurate.
> > 
> > > > redundant and can be removed.
> > > > 
> > > > Given that entity->rq can now never be NULL, we also remove two
> > > > impossible
> > > > checks, from drm_sched_entity_kill() and drm_sched_entity_flush()
> > > > respectively.
> > > > 
> > > > Similarly, we can also remove the !entity->rq check in
> > > > drm_sched_job_init(). And for the better, given that the error 
> > > > message, if
> > > > it ever triggered, would have dereferenced the yet un-initialized job->
> > > > sched (only initialized later in drm_sched_job_arm()). This appears to
> > > > have been theoretically broken ever since commit
> > > > 56e449603f0a ("drm/sched: Convert the GPU scheduler to variable
> > > > number of run-queues")
> > > > .
> > > > 
> > > > Signed-off-by: Tvrtko Ursulin <[email protected]>
> > > > Cc: Christian König <[email protected]>
> > > > Cc: Danilo Krummrich <[email protected]>
> > > > Cc: Matthew Brost <[email protected]>
> > > > Cc: Philipp Stanner <[email protected]>
> > > > 
> 
> Gentle reminder - can we merge this as is or you want me to tweak what 
> specifically?

No, cool cleanup, shoved it into drm-misc-next

Sorry for forgetting, it drowned in all the dma_fence mails <.<


P.

Reply via email to