xwayland: skip drm authentication with render node
If using a render node, we can skip DRM authentication. Suggested-by: Emil Velikov <emil.velikov@collabora.com> Signed-off-by: Olivier Fourdan <ofourdan@redhat.com> Reviewed-by: Emil Velikov <emil.velikov@collabora.com>
This commit is contained in:
parent
b823b43dca
commit
de004eefc6
|
@ -837,11 +837,16 @@ error:
|
|||
static Bool
|
||||
xwl_glamor_gbm_init_screen(struct xwl_screen *xwl_screen)
|
||||
{
|
||||
struct xwl_gbm_private *xwl_gbm = xwl_gbm_get(xwl_screen);
|
||||
|
||||
if (!dri3_screen_init(xwl_screen->screen, &xwl_dri3_info)) {
|
||||
ErrorF("Failed to initialize dri3\n");
|
||||
goto error;
|
||||
}
|
||||
|
||||
if (xwl_gbm->fd_render_node)
|
||||
goto skip_drm_auth;
|
||||
|
||||
if (!dixRegisterPrivateKey(&xwl_auth_state_private_key, PRIVATE_CLIENT,
|
||||
0)) {
|
||||
ErrorF("Failed to register private key\n");
|
||||
|
@ -854,6 +859,7 @@ xwl_glamor_gbm_init_screen(struct xwl_screen *xwl_screen)
|
|||
goto error;
|
||||
}
|
||||
|
||||
skip_drm_auth:
|
||||
xwl_screen->screen->CreatePixmap = xwl_glamor_gbm_create_pixmap;
|
||||
xwl_screen->screen->DestroyPixmap = xwl_glamor_gbm_destroy_pixmap;
|
||||
|
||||
|
|
Loading…
Reference in New Issue
Block a user