renderonly: don't complain when GPU import fails

There are a number of drivers which do a trial-and-error import
of buffers into the KMS side via renderonly. Some of those imports
are expected to fail, so we should not print a error message in
this case. All callers do proper error handling themselves.

Cc: mesa-stable
Signed-off-by: Lucas Stach <l.stach@pengutronix.de>
Reviewed-by: Simon Ser <contact@emersion.fr>
Reviewed-by: Christian Gmeiner <christian.gmeiner@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/12018>
This commit is contained in:
Lucas Stach 2020-10-28 19:53:43 +01:00
parent 353e632393
commit 1bc22a2eab

View File

@ -134,10 +134,8 @@ renderonly_create_gpu_import_for_resource(struct pipe_resource *rsc,
err = drmPrimeFDToHandle(ro->kms_fd, fd, &scanout->handle);
close(fd);
if (err < 0) {
fprintf(stderr, "drmPrimeFDToHandle() failed: %s\n", strerror(errno));
if (err < 0)
goto free_scanout;
}
return scanout;