| OLD | NEW |
| 1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 #include "ui/ozone/platform/dri/dri_wrapper.h" | 5 #include "ui/ozone/platform/dri/dri_wrapper.h" |
| 6 | 6 |
| 7 #include <fcntl.h> | 7 #include <fcntl.h> |
| 8 #include <sys/mman.h> | 8 #include <sys/mman.h> |
| 9 #include <unistd.h> | 9 #include <unistd.h> |
| 10 #include <xf86drm.h> | 10 #include <xf86drm.h> |
| 11 #include <xf86drmMode.h> | 11 #include <xf86drmMode.h> |
| 12 | 12 |
| 13 #include "base/debug/trace_event.h" | |
| 14 #include "base/logging.h" | 13 #include "base/logging.h" |
| 15 #include "base/message_loop/message_loop.h" | 14 #include "base/message_loop/message_loop.h" |
| 16 #include "base/stl_util.h" | 15 #include "base/stl_util.h" |
| 17 #include "base/task_runner.h" | 16 #include "base/task_runner.h" |
| 18 #include "base/thread_task_runner_handle.h" | 17 #include "base/thread_task_runner_handle.h" |
| 18 #include "base/trace_event/trace_event.h" |
| 19 #include "third_party/skia/include/core/SkImageInfo.h" | 19 #include "third_party/skia/include/core/SkImageInfo.h" |
| 20 #include "ui/ozone/platform/dri/dri_util.h" | 20 #include "ui/ozone/platform/dri/dri_util.h" |
| 21 #include "ui/ozone/platform/dri/hardware_display_plane_manager_legacy.h" | 21 #include "ui/ozone/platform/dri/hardware_display_plane_manager_legacy.h" |
| 22 | 22 |
| 23 namespace ui { | 23 namespace ui { |
| 24 | 24 |
| 25 namespace { | 25 namespace { |
| 26 | 26 |
| 27 struct PageFlipPayload { | 27 struct PageFlipPayload { |
| 28 PageFlipPayload(const scoped_refptr<base::TaskRunner>& task_runner, | 28 PageFlipPayload(const scoped_refptr<base::TaskRunner>& task_runner, |
| (...skipping 379 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 408 DCHECK(fd_ >= 0); | 408 DCHECK(fd_ >= 0); |
| 409 return (drmSetMaster(fd_) == 0); | 409 return (drmSetMaster(fd_) == 0); |
| 410 } | 410 } |
| 411 | 411 |
| 412 bool DriWrapper::DropMaster() { | 412 bool DriWrapper::DropMaster() { |
| 413 DCHECK(fd_ >= 0); | 413 DCHECK(fd_ >= 0); |
| 414 return (drmDropMaster(fd_) == 0); | 414 return (drmDropMaster(fd_) == 0); |
| 415 } | 415 } |
| 416 | 416 |
| 417 } // namespace ui | 417 } // namespace ui |
| OLD | NEW |