mirror of
https://gitlab.freedesktop.org/emersion/libliftoff.git
synced 2024-12-24 21:59:08 +01:00
hack: poor man's DRM debugging
This commit is contained in:
parent
bc0d0617ac
commit
d706fc64f3
1 changed files with 5 additions and 0 deletions
5
device.c
5
device.c
|
@ -95,6 +95,8 @@ device_test_commit(struct liftoff_device *device, drmModeAtomicReq *req,
|
|||
{
|
||||
int ret;
|
||||
|
||||
system("sudo dmesg -C");
|
||||
|
||||
flags &= ~DRM_MODE_PAGE_FLIP_EVENT;
|
||||
do {
|
||||
ret = drmModeAtomicCommit(device->drm_fd, req,
|
||||
|
@ -106,6 +108,9 @@ device_test_commit(struct liftoff_device *device, drmModeAtomicReq *req,
|
|||
liftoff_log(LIFTOFF_ERROR, "drmModeAtomicCommit: %s",
|
||||
strerror(-ret));
|
||||
}
|
||||
if (ret == -EINVAL || ret == -ERANGE) {
|
||||
system("sudo dmesg");
|
||||
}
|
||||
|
||||
return ret;
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue