commit 7f585a1
Michael Forney
·
2014-01-18 03:04:22 +0000 UTC
parent 118f63b
drm: Better debug messages
1 files changed,
+5,
-7
+5,
-7
1@@ -313,7 +313,7 @@ bool swc_drm_initialize(const char * seat_name)
2
3 if (!(drm_device = find_primary_drm_device(seat_name)))
4 {
5- printf("couldn't find drm device\n");
6+ ERROR("Could not find DRM device\n");
7 goto error0;
8 }
9
10@@ -323,7 +323,7 @@ bool swc_drm_initialize(const char * seat_name)
11
12 if (*end != '\0')
13 {
14- printf("couldn't get drm device sysnum\n");
15+ ERROR("Could not get DRM device sysnum\n");
16 udev_device_unref(drm_device);
17 goto error0;
18 }
19@@ -335,13 +335,13 @@ bool swc_drm_initialize(const char * seat_name)
20
21 if (swc.drm->fd == -1)
22 {
23- fprintf(stderr, "Could not open %s\n", drm.path);
24+ ERROR("Could not open DRM device at %s\n", drm.path);
25 goto error1;
26 }
27
28 if (!(swc.drm->context = wld_drm_create_context(swc.drm->fd)))
29 {
30- fprintf(stderr, "Could not create WLD DRM context\n");
31+ ERROR("Could not create WLD DRM context\n");
32 goto error2;
33 }
34
35@@ -410,12 +410,10 @@ bool swc_drm_create_screens(struct wl_list * screens)
36
37 if (!(resources = drmModeGetResources(swc.drm->fd)))
38 {
39- printf("couldn't get DRM resources\n");
40+ ERROR("Could not get DRM resources\n");
41 return false;
42 }
43
44- printf("crtc count: %u\n", resources->count_crtcs);
45-
46 /* XXX: crtcs */
47 for (index = 0; index < resources->count_crtcs; ++index)
48 {