Patchwork [01/13] sd: Send debug printfery to stderr not stdout

login
register
mail settings
Submitter Stefan Hajnoczi
Date Dec. 7, 2012, 11:39 a.m.
Message ID <1354880352-9597-2-git-send-email-stefanha@redhat.com>
Download mbox | patch
Permalink /patch/204473/
State New
Headers show

Comments

Stefan Hajnoczi - Dec. 7, 2012, 11:39 a.m.
From: Peter Crosthwaite <peter.crosthwaite@xilinx.com>

Some debug printfs for SD are coming up in stdout. Redirected them to stderr
instead.

Signed-off-by: Peter Crosthwaite <peter.crosthwaite@xilinx.com>
Reviewed-by: Peter Maydell <peter.maydell@linaro.org>
Signed-off-by: Stefan Hajnoczi <stefanha@redhat.com>
---
 hw/sd.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

Patch

diff --git a/hw/sd.c b/hw/sd.c
index 3c34d43..607edba 100644
--- a/hw/sd.c
+++ b/hw/sd.c
@@ -1439,8 +1439,8 @@  send_response:
         int i;
         DPRINTF("Response:");
         for (i = 0; i < rsplen; i++)
-            printf(" %02x", response[i]);
-        printf(" state %d\n", sd->state);
+            fprintf(stderr, " %02x", response[i]);
+        fprintf(stderr, " state %d\n", sd->state);
     } else {
         DPRINTF("No response %d\n", sd->state);
     }