Hi,

On 19/1/26 16:17, Thomas Zimmermann wrote:
> Hi,
> 
> thanks for the patch.

Thanks for taking a look. I did forget about this oops and the
smatch failure was a good reminder!

> 
> Am 18.01.26 um 13:50 schrieb Shenghao Yang:
>> Commit dc2d5ddb193e ("drm/gud: fix NULL fb and crtc dereferences
>> on USB disconnect") [1] only fixed the initial NULL crtc dereference
>> in gud_plane_atomic_update().
>>
>> However, planes can also be disabled in non-hotplug paths (e.g.
>> display disables via the DE). The drm_dev_enter() call would not
> 
> 'DE' ?

Ah - the desktop environment. I was scratching my head for why the
box kept oops-ing on boot even after the hotplug fix. It turned out
kscreen was applying the saved "disable display" setting.

> It seems to me that all these calls to GUD_REQ_SET_CONTROLLER_ENABLE(^1) and 
> GUD_REQ_SET_DISPLAY_ENABLEshould rather go to the CRTC's 
> atomic_enable/atomic_disable functions. Those currently seem missing from 
> [1]. The atomic_update helper would then be reduced to damage handling. Best 
> regards Thomas [1] 
> https://elixir.bootlin.com/linux/v6.18.6/source/drivers/gpu/drm/gud/gud_drv.c#L341
> ^1: SET_CONTROLLER_ENABLE sounds like it could even be part of device probing 
> and runtime PM management, but that is a more invasive change.

That feels like it'd be much cleaner. I'll respin with that in v2.

Shenghao

Reply via email to