diff --git a/sb600spi.c b/sb600spi.c
index 66943ba..9172eac 100644
--- a/sb600spi.c
+++ b/sb600spi.c
@@ -24,17 +24,6 @@
 #include "flash.h"
 #include "spi.h"
 
-/* Change this to #define if you want lowlevel debugging of commands
- * sent to the SB600/SB700 SPI controller.
- */
-#undef COMM_DEBUG
-
-#ifdef COMM_DEBUG
-#define msg_comm_debug printf_debug
-#else
-#define msg_comm_debug(...) do {} while (0)
-#endif
-
 /* This struct is unused, but helps visualize the SB600 SPI BAR layout.
  *struct sb600_spi_controller {
  *	unsigned int spi_cntrl0;	/ * 00h * /
@@ -65,28 +54,28 @@
 
 	spi_disable_blockprotect();
 	/* Erase first */
-	printf("Erasing flash before programming... ");
+	msg_pinfo("Erasing flash before programming... ");
 	if (erase_flash(flash)) {
-		fprintf(stderr, "ERASE FAILED!\n");
+		msg_perr("ERASE FAILED!\n");
 		return -1;
 	}
-	printf("done.\n");
+	msg_pinfo("done.\n");
 
-	printf("Programming flash");
+	msg_pinfo("Programming flash");
 	for (i = 0; i < total_size; i++, buf++) {
 		result = spi_nbyte_program(i, buf, 1);
 		if (result) {
-			fprintf(stderr, "Write error!\n");
+			msg_perr("Write error!\n");
 			return result;
 		}
 
 		/* wait program complete. */
 		if (i % 0x8000 == 0)
-			printf(".");
+			msg_pspew(".");
 		while (spi_read_status_register() & JEDEC_RDSR_BIT_WIP)
 			;
 	}
-	printf(" done.\n");
+	msg_pinfo(" done.\n");
 	return result;
 }
 
@@ -95,7 +84,7 @@
 	mmio_writeb(mmio_readb(sb600_spibar + 2) | 0x10, sb600_spibar + 2);
 
 	while (mmio_readb(sb600_spibar + 0xD) & 0x7)
-		printf("reset\n");
+		msg_pspew("reset\n");
 }
 
 static void execute_command(void)
@@ -116,17 +105,17 @@
 
 	writecnt--;
 
-	msg_comm_debug("%s, cmd=%x, writecnt=%x, readcnt=%x\n",
-		     __func__, cmd, writecnt, readcnt);
+	msg_pspew("%s, cmd=%x, writecnt=%x, readcnt=%x\n",
+		  __func__, cmd, writecnt, readcnt);
 
 	if (readcnt > 8) {
-		printf("%s, SB600 SPI controller can not receive %d bytes, "
+		msg_pinfo("%s, SB600 SPI controller can not receive %d bytes, "
 		       "it is limited to 8 bytes\n", __func__, readcnt);
 		return SPI_INVALID_LENGTH;
 	}
 
 	if (writecnt > 8) {
-		printf("%s, SB600 SPI controller can not send %d bytes, "
+		msg_pinfo("%s, SB600 SPI controller can not send %d bytes, "
 		       "it is limited to 8 bytes\n", __func__, writecnt);
 		return SPI_INVALID_LENGTH;
 	}
@@ -146,10 +135,10 @@
 
 	/* Send the write byte to FIFO. */
 	for (count = 0; count < writecnt; count++, writearr++) {
-		msg_comm_debug(" [%x]", *writearr);
+		msg_pspew(" [%x]", *writearr);
 		mmio_writeb(*writearr, sb600_spibar + 0xC);
 	}
-	msg_comm_debug("\n");
+	msg_pspew("\n");
 
 	/*
 	 * We should send the data by sequence, which means we need to reset
@@ -175,16 +164,16 @@
 	/* Skip the bytes we sent. */
 	for (count = 0; count < writecnt; count++) {
 		cmd = mmio_readb(sb600_spibar + 0xC);
-		msg_comm_debug("[ %2x]", cmd);
+		msg_pspew("[ %2x]", cmd);
 	}
 
-	msg_comm_debug("The FIFO pointer after skipping is %d.\n",
-		     mmio_readb(sb600_spibar + 0xd) & 0x07);
+	msg_pspew("The FIFO pointer after skipping is %d.\n",
+		  mmio_readb(sb600_spibar + 0xd) & 0x07);
 	for (count = 0; count < readcnt; count++, readarr++) {
 		*readarr = mmio_readb(sb600_spibar + 0xC);
-		msg_comm_debug("[%02x]", *readarr);
+		msg_pspew("[%02x]", *readarr);
 	}
-	msg_comm_debug("\n");
+	msg_pspew("\n");
 
 	return 0;
 }
