| Index: ui/ozone/platform/drm/gpu/drm_device.cc
|
| diff --git a/ui/ozone/platform/drm/gpu/drm_device.cc b/ui/ozone/platform/drm/gpu/drm_device.cc
|
| index 4d2bcbfe9894496e5c73d91c8282691f8d15d898..fe95a622ca04eb01255310bb612255d75a3a831e 100644
|
| --- a/ui/ozone/platform/drm/gpu/drm_device.cc
|
| +++ b/ui/ozone/platform/drm/gpu/drm_device.cc
|
| @@ -100,14 +100,6 @@ bool CanQueryForResources(int fd) {
|
| return !drmIoctl(fd, DRM_IOCTL_MODE_GETRESOURCES, &resources);
|
| }
|
|
|
| -bool Authenticate(int fd) {
|
| - drm_magic_t magic;
|
| - memset(&magic, 0, sizeof(magic));
|
| - // We need to make sure the DRM device has enough privilege. Use the DRM
|
| - // authentication logic to figure out if the device has enough permissions.
|
| - return !drmGetMagic(fd, &magic) && !drmAuthMagic(fd, magic);
|
| -}
|
| -
|
| } // namespace
|
|
|
| class DrmDevice::IOWatcher
|
| @@ -212,28 +204,6 @@ bool DrmDevice::Initialize() {
|
| return false;
|
| }
|
|
|
| - bool print_warning = true;
|
| - // TODO(dnicoara) Ugly hack to block until getting master. This is needed
|
| - // since DRM devices from an old GPU process may be getting deallocated while
|
| - // the new GPU process tries to take them.
|
| - // Move ownership of devices in the Browser process and just have the GPU
|
| - // processes authenticate.
|
| - while (!Authenticate(file_.GetPlatformFile())) {
|
| - PLOG_IF(WARNING, print_warning) << "Failed to take master on "
|
| - << device_path_.value();
|
| - print_warning = false;
|
| -
|
| - usleep(100000);
|
| - file_ =
|
| - base::File(device_path_, base::File::FLAG_OPEN | base::File::FLAG_READ |
|
| - base::File::FLAG_WRITE);
|
| - LOG_IF(FATAL, !file_.IsValid())
|
| - << "Failed to open '" << device_path_.value()
|
| - << "': " << base::File::ErrorToString(file_.error_details());
|
| - }
|
| -
|
| - VLOG(1) << "Succeeded in taking master on " << device_path_.value();
|
| -
|
| #if defined(USE_DRM_ATOMIC)
|
| plane_manager_.reset(new HardwareDisplayPlaneManagerAtomic());
|
| #else
|
|
|