[Lima] [PATCH] drm: Return error codes from struct drm_driver.gem_create_object
Maxime Ripard
maxime at cerno.tech
Wed Dec 1 15:04:43 UTC 2021
On Tue, Nov 30, 2021 at 10:52:55AM +0100, Thomas Zimmermann wrote:
> GEM helper libraries use struct drm_driver.gem_create_object to let
> drivers override GEM object allocation. On failure, the call returns
> NULL.
>
> Change the semantics to make the calls return a pointer-encoded error.
> This aligns the callback with its callers. Fixes the ingenic driver,
> which already returns an error pointer.
>
> Also update the callers to handle the involved types more strictly.
>
> Signed-off-by: Thomas Zimmermann <tzimmermann at suse.de>
> ---
> There is an alternative patch at [1] that updates the value returned
> by ingenics' gem_create_object to NULL. Fixing the interface to return
> an errno code is more consistent with the rest of the GEM functions.
>
> [1] https://lore.kernel.org/dri-devel/20211118111522.GD1147@kili/
Acked-by: Maxime Ripard <maxime at cerno.tech>
Maxime
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 228 bytes
Desc: not available
URL: <https://lists.freedesktop.org/archives/lima/attachments/20211201/2c5be04e/attachment.sig>
More information about the lima
mailing list