[PATCH RESEND xserver v3] xfree86: Immediately handle failure to set HW cursor
Alexandre Courbot
gnurou at gmail.com
Fri May 27 03:57:43 UTC 2016
Friendly ping, as it would be very nice to see this merged!
On Fri, May 13, 2016 at 7:36 PM, Alexandre Courbot <acourbot at nvidia.com> wrote:
> On 05/13/2016 01:04 AM, Adam Jackson wrote:
>>
>> On Thu, 2016-05-12 at 16:04 +0900, Alexandre Courbot wrote:
>>>
>>> There is currently no reliable way to report failure to set a HW
>>> cursor. Still such failures can happen if e.g. the MODE_CURSOR DRM
>>> ioctl fails (which currently happens at least with modesetting on Tegra
>>> for format incompatibility reasons).
>>>
>>> As failures are currently handled by setting the HW cursor size to
>>> (0,0), the fallback to SW cursor will not happen until the next time the
>>> cursor changes and xf86CursorSetCursor() is called again. In the
>>> meantime, the cursor will be invisible to the user.
>>>
>>> This patch addresses that by adding _xf86CrtcFuncs::set_cursor_check and
>>> _xf86CursorInfoRec::ShowCursorCheck hook variants that return booleans.
>>> This allows to propagate errors up to xf86CursorSetCursor(), which can
>>> then fall back to using the SW cursor immediately.
>>>
>>> Signed-off-by: Alexandre Courbot <acourbot at nvidia.com>
>>> Cc: Michael Thayer <michael.thayer at oracle.com>
>>> ---
>>> Hoping to see this patch go through - all issues in the previous versions
>>> have been addressed, and the logic it introduces seems saner than setting
>>> the cursor size to (0, 0).
>>
>>
>> How are external drivers to know whether .set_cursor_check is available
>> at compile time? ABI_VIDEODRV_VERSION > 21.0 ? (That's a fine answer,
>> just want to make sure it's explicit.)
>
>
> Yes, that's probably how it should be done - should I add a comment
> somewhere in the code to specify the minimum ABI version? I haven't found
> any such comment for other _check variants though.
More information about the xorg-devel
mailing list