aboutsummaryrefslogtreecommitdiffstats
path: root/target/linux/brcm2708/patches-4.4/0528-pisound-Fix-a-warning-in-DEBUG-builds.patch
blob: ce757f5182192166393a42bbad6fcdb20398da23 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
From a87861c387cf8d0d6691c17be865495674852953 Mon Sep 17 00:00:00 2001
From: Giedrius Trainavicius <giedrius@blokas.io>
Date: Tue, 25 Oct 2016 01:47:20 +0300
Subject: [PATCH] pisound: Fix a warning in DEBUG builds

Also change a macro that enables debug level printing from DEBUG to
PISOUND_DEBUG.
---
 sound/soc/bcm/pisound.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

--- a/sound/soc/bcm/pisound.c
+++ b/sound/soc/bcm/pisound.c
@@ -55,7 +55,7 @@ static void pisnd_midi_uninit(void);
 
 #define PISOUND_LOG_PREFIX "pisound: "
 
-#ifdef DEBUG
+#ifdef PISOUND_DEBUG
 #	define printd(...) pr_alert(PISOUND_LOG_PREFIX __VA_ARGS__)
 #else
 #	define printd(...) do {} while (0)
@@ -119,7 +119,7 @@ static void pisnd_midi_recv_callback(voi
 	while ((n = pisnd_spi_recv(data, sizeof(data)))) {
 		int res = snd_rawmidi_receive(substream, data, n);
 		(void)res;
-		printd("midi recv 0x%02x, res = %d\n", data, res);
+		printd("midi recv %u bytes, res = %d\n", n, res);
 	}
 }