Quoting Michel Thierry (2017-11-20 21:52:06) > On 11/20/2017 1:19 PM, Chris Wilson wrote: > > Silence sparse over > > > > drivers/gpu/drm/i915/selftests/intel_guc.c:135 igt_guc_init_doorbell_hw() > > error: we previously assumed 'guc->execbuf_client' could be null (see line > > 123) > > drivers/gpu/drm/i915/selftests/intel_guc.c:142 igt_guc_init_doorbell_hw() > > error: we previously assumed 'guc->preempt_client' could be null (see line > > 123) > > > > by asserting that we did succeed in creating the pair of clients for > > testing. > > > > Sparse isn't smart enough to see what guc_clients_destroy/_create do.
Oops, not sparse but smatch. Yeah, it doesn't inline as aggressively as gcc (if that's the right explanation). I'm also not sure if the pattern it enforces is a great pattern; but it certainly helps curb the antipatterns so keeping it clean does help with code quality. (So overall quite a useful little static analyser.) -Chris _______________________________________________ Intel-gfx mailing list Intel-gfx@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/intel-gfx