diff options
author | Daniel Vetter <daniel.vetter@ffwll.ch> | 2014-08-26 15:13:06 +0200 |
---|---|---|
committer | Daniel Vetter <daniel.vetter@ffwll.ch> | 2014-08-26 15:16:01 +0200 |
commit | 71ac5de5a4473d20fb11cb454f62d8e5c90f020c (patch) | |
tree | d90ebcf85b8f7f674aeb0a2d2df81a430673de66 /lib/intel_iosf.c | |
parent | baa6f8b34f54b68c15fc86d86de77d954e458aac (diff) |
lib/intel_* Use igt checks and macros
Various stuff all over. Most done with the igt.cocci spatch, but
with a few fixups by hand. And add igt_core.h includes where needed.
Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
Diffstat (limited to 'lib/intel_iosf.c')
-rw-r--r-- | lib/intel_iosf.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/lib/intel_iosf.c b/lib/intel_iosf.c index 2f1ef90c..27134a07 100644 --- a/lib/intel_iosf.c +++ b/lib/intel_iosf.c @@ -3,8 +3,10 @@ #include <stdio.h> #include <err.h> #include <errno.h> + #include "intel_io.h" #include "intel_reg.h" +#include "igt_core.h" #define TIMEOUT_US 500000 @@ -33,8 +35,7 @@ static int vlv_sideband_rw(uint32_t port, uint8_t opcode, uint32_t addr, (bar << IOSF_BAR_SHIFT); if (intel_register_read(VLV_IOSF_DOORBELL_REQ) & IOSF_SB_BUSY) { - fprintf(stderr, "warning: pcode (%s) mailbox access failed\n", - is_read ? "read" : "write"); + igt_warn("warning: pcode (%s) mailbox access failed\n", is_read ? "read" : "write"); return -EAGAIN; } @@ -51,8 +52,7 @@ static int vlv_sideband_rw(uint32_t port, uint8_t opcode, uint32_t addr, timeout < TIMEOUT_US); if (timeout >= TIMEOUT_US) { - fprintf(stderr, "timeout waiting for pcode %s (%d) to finish\n", - is_read ? "read" : "write", addr); + igt_warn("timeout waiting for pcode %s (%d) to finish\n", is_read ? "read" : "write", addr); return -ETIMEDOUT; } |