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

Unified Diff: ui/ozone/platform/drm/gpu/gbm_buffer.cc

Issue 2090343005: ui: Fix faulty drm/gbm DCHECKs. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Address posciak's comment. Created 4 years, 6 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/gl/gl_image_ozone_native_pixmap_drm_unittest.cc ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ui/ozone/platform/drm/gpu/gbm_buffer.cc
diff --git a/ui/ozone/platform/drm/gpu/gbm_buffer.cc b/ui/ozone/platform/drm/gpu/gbm_buffer.cc
index 952721bad5e25ccf23c080c75f9ae0329d4083c1..9f62cb673907b3ca906bba942ba46152df0fd219 100644
--- a/ui/ozone/platform/drm/gpu/gbm_buffer.cc
+++ b/ui/ozone/platform/drm/gpu/gbm_buffer.cc
@@ -142,8 +142,8 @@ scoped_refptr<GbmBuffer> GbmBuffer::CreateBufferFromFds(
const std::vector<int>& offsets) {
TRACE_EVENT2("drm", "GbmBuffer::CreateBufferFromFD", "device",
gbm->device_path().value(), "size", size.ToString());
- DCHECK_EQ(fds.size(), strides.size());
- DCHECK_EQ(fds.size(), 1u);
+ DCHECK_LE(fds.size(), strides.size());
+ DCHECK_EQ(strides.size(), offsets.size());
DCHECK_EQ(offsets[0], 0);
uint32_t fourcc_format = GetFourCCFormatFromBufferFormat(format);
« no previous file with comments | « ui/gl/gl_image_ozone_native_pixmap_drm_unittest.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698