Commit be0638fe authored by Tom Anderson's avatar Tom Anderson Committed by Commit Bot

Avoid loading DRI via GBM when GpuMemoryBuffers are disabled

We haven't yet whitelisted the necessary dri files in the GPU sandbox,
which is leading to issues like 1077609 and 1077626.  Since GMBs are
not yet supported, avoid loading GBM unless
--enable-native-gpu-memory-buffers is passed.

Bug: 1077609, 1077626, 1031269
Change-Id: Ic052d2e89330c6558da86a91b77637229808102f
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2211120
Auto-Submit: Thomas Anderson <thomasanderson@chromium.org>
Reviewed-by: default avatarKenneth Russell <kbr@chromium.org>
Commit-Queue: Thomas Anderson <thomasanderson@chromium.org>
Cr-Commit-Position: refs/heads/master@{#770878}
parent b32316e8
......@@ -364,11 +364,13 @@ int GpuMain(const MainFunctionParams& parameters) {
#if defined(USE_X11)
// ui::GbmDevice() takes >50ms with amdgpu, so kick off
// GpuMemoryBufferSupportX11 creation on another thread now.
base::PostTask(
FROM_HERE, base::BindOnce([]() {
SCOPED_UMA_HISTOGRAM_TIMER("Linux.X11.GbmSupportX11CreationTime");
ui::GpuMemoryBufferSupportX11::GetInstance();
}));
if (gpu_preferences.enable_native_gpu_memory_buffers) {
base::PostTask(
FROM_HERE, base::BindOnce([]() {
SCOPED_UMA_HISTOGRAM_TIMER("Linux.X11.GbmSupportX11CreationTime");
ui::GpuMemoryBufferSupportX11::GetInstance();
}));
}
#endif
auto* client = GetContentClient()->gpu();
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment