]> git.sur5r.net Git - u-boot/blobdiff - common/xyzModem.c
Fix Ymodem build when DEBUG and CONFIG_USE_TINY_PRINTF are selected
[u-boot] / common / xyzModem.c
index 6ded958e8907663a28709ac850091ad2ff7110cc..519e414a6c10f4073e9d7421750e95d92b304d08 100644 (file)
@@ -1,3 +1,4 @@
+// SPDX-License-Identifier: eCos-2.0
 /*
  *==========================================================================
  *
@@ -6,8 +7,6 @@
  *      RedBoot stream handler for xyzModem protocol
  *
  *==========================================================================
- * SPDX-License-Identifier:    eCos-2.0
- *==========================================================================
  *#####DESCRIPTIONBEGIN####
  *
  * Author(s):    gthomas
@@ -172,20 +171,14 @@ parse_num (char *s, unsigned long *val, char **es, char *delim)
 }
 
 
-#ifdef DEBUG
+#if defined(DEBUG) && !defined(CONFIG_USE_TINY_PRINTF)
 /*
  * Note: this debug setup works by storing the strings in a fixed buffer
  */
-#define FINAL
-#ifdef FINAL
-static char *zm_out = (char *) 0x00380000;
-static char *zm_out_start = (char *) 0x00380000;
-#else
-static char zm_buf[8192];
-static char *zm_out = zm_buf;
-static char *zm_out_start = zm_buf;
+static char zm_debug_buf[8192];
+static char *zm_out = zm_debug_buf;
+static char *zm_out_start = zm_debug_buf;
 
-#endif
 static int
 zm_dprintf (char *fmt, ...)
 {