Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1130)

Unified Diff: ui/ozone/platform/drm/host/drm_display_host_manager.cc

Issue 1262043002: Implement DRM Native Pixmap using prime buffer (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@new-master
Patch Set: remove drm header Created 4 years, 9 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « ui/ozone/platform/drm/host/drm_display_host_manager.h ('k') | ui/ozone/platform/drm/ozone_platform_gbm.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ui/ozone/platform/drm/host/drm_display_host_manager.cc
diff --git a/ui/ozone/platform/drm/host/drm_display_host_manager.cc b/ui/ozone/platform/drm/host/drm_display_host_manager.cc
index 85b94e93fc93d92657000dd84ea872fe41a5191c..458c247ed2b509fe5cb6a0faed3833627e9596b8 100644
--- a/ui/ozone/platform/drm/host/drm_display_host_manager.cc
+++ b/ui/ozone/platform/drm/host/drm_display_host_manager.cc
@@ -9,7 +9,6 @@
#include <xf86drm.h>
#include <utility>
-#include "base/files/file_enumerator.h"
#include "base/files/file_path.h"
#include "base/files/file_util.h"
#include "base/strings/stringprintf.h"
@@ -36,8 +35,6 @@ typedef base::Callback<void(const base::FilePath&,
OnOpenDeviceReplyCallback;
const char kDefaultGraphicsCardPattern[] = "/dev/dri/card%d";
-const char kVgemDevDriCardPath[] = "/dev/dri/";
-const char kVgemSysCardPath[] = "/sys/bus/platform/devices/vgem/drm/";
const char* kDisplayActionString[] = {
"ADD", "REMOVE", "CHANGE",
@@ -95,22 +92,6 @@ base::FilePath GetPrimaryDisplayCardPath() {
return base::FilePath(); // Not reached.
}
-base::FilePath GetVgemCardPath() {
- base::FileEnumerator file_iter(base::FilePath(kVgemSysCardPath), false,
- base::FileEnumerator::DIRECTORIES,
- FILE_PATH_LITERAL("card*"));
-
- while (!file_iter.Next().empty()) {
- // Inspect the card%d directories in the directory and extract the filename.
- std::string vgem_card_path =
- kVgemDevDriCardPath + file_iter.GetInfo().GetName().BaseName().value();
- DVLOG(1) << "VGEM card path is " << vgem_card_path;
- return base::FilePath(vgem_card_path);
- }
- DVLOG(1) << "Don't support VGEM";
- return base::FilePath();
-}
-
class FindDrmDisplayHostById {
public:
explicit FindDrmDisplayHostById(int64_t display_id)
@@ -152,8 +133,6 @@ DrmDisplayHostManager::DrmDisplayHostManager(
}
drm_devices_[primary_graphics_card_path_] =
primary_graphics_card_path_sysfs;
-
- vgem_card_path_ = GetVgemCardPath();
}
device_manager_->AddObserver(this);
@@ -264,8 +243,6 @@ void DrmDisplayHostManager::ProcessEvent() {
<< " for " << event.path.value();
switch (event.action_type) {
case DeviceEvent::ADD:
- if (event.path == vgem_card_path_)
- continue;
if (drm_devices_.find(event.path) == drm_devices_.end()) {
task_pending_ = base::WorkerPool::PostTask(
FROM_HERE,
@@ -285,7 +262,6 @@ void DrmDisplayHostManager::ProcessEvent() {
case DeviceEvent::REMOVE:
DCHECK(event.path != primary_graphics_card_path_)
<< "Removing primary graphics card";
- DCHECK(event.path != vgem_card_path_) << "Removing VGEM device";
auto it = drm_devices_.find(event.path);
if (it != drm_devices_.end()) {
task_pending_ = base::ThreadTaskRunnerHandle::Get()->PostTask(
« no previous file with comments | « ui/ozone/platform/drm/host/drm_display_host_manager.h ('k') | ui/ozone/platform/drm/ozone_platform_gbm.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698