glamor: Don't initialize on softpipe

There are systems where softpipe is the default renderer,
e.g. when llvmpipe is not is not available. Using glamor
on such systems is never a good idea.

This mirrors what commit 0a9415cf79
did for llvmpipe.

Closes: #1417

Signed-off-by: Ivan A. Melnikov <iv@altlinux.org>
This commit is contained in:
Ivan A. Melnikov 2022-12-21 18:29:21 +04:00 committed by Olivier Fourdan
parent 5c18e25e12
commit 711d491729
2 changed files with 9 additions and 0 deletions

View File

@ -1080,6 +1080,11 @@ glamor_egl_init(ScrnInfoPtr scrn, int fd)
"glGetString() returned NULL, your GL is broken\n");
goto error;
}
if (strstr((const char *)renderer, "softpipe")) {
xf86DrvMsg(scrn->scrnIndex, X_INFO,
"Refusing to try glamor on softpipe\n");
goto error;
}
if (!strncmp("llvmpipe", (const char *)renderer, strlen("llvmpipe"))) {
if (scrn->confScreen->num_gpu_devices)
xf86DrvMsg(scrn->scrnIndex, X_INFO,

View File

@ -1030,6 +1030,10 @@ xwl_glamor_gbm_init_egl(struct xwl_screen *xwl_screen)
ErrorF("glGetString() returned NULL, your GL is broken\n");
goto error;
}
if (strstr((const char *)renderer, "softpipe")) {
ErrorF("Refusing to try glamor on softpipe\n");
goto error;
}
if (!strncmp("llvmpipe", (const char *)renderer, strlen("llvmpipe"))) {
ErrorF("Refusing to try glamor on llvmpipe\n");
goto error;