[PATCH] drm/amd/display: Fix error handling on waiting for completion

Michel Dänzer michel at daenzer.net
Tue Oct 26 16:11:24 UTC 2021


On 2021-10-26 18:08, Simon Ser wrote:
> On Tuesday, October 26th, 2021 at 18:03, Kazlauskas, Nicholas <nicholas.kazlauskas at amd.com> wrote:
> 
>> If it's just an error in the log without a functional issue then maybe
>> we should downgrade it to a debug statement in the case where it returns
>> -ERESTARTSYS.
>>
>> If this is a functional issue (DRM not automatically retrying the
>> commit?) then maybe we should take a deeper look into the IOCTL itself.
> 
> libdrm handles EINTR but not ERESTARTSYS. So, if the kernel returns ERESTARTSYS
> then Mutter will error out.
> 
> Should the kernel be fixed to return EINTR instead of ERESTARTSYS, or should
> libdrm be fixed to handle ERESTARTSYS?

The kernel is supposed to convert ERESTARTSYS to EINTR when returning to user space (when the kernel can't restart the system call itself), so user space doesn't need to handle the former.


-- 
Earthling Michel Dänzer            |                  https://redhat.com
Libre software enthusiast          |         Mesa and Xwayland developer


More information about the amd-gfx mailing list