From 1edc9979226ad1566ec1e4d28e86af1fdd787254 Mon Sep 17 00:00:00 2001 From: Gregory Nutt Date: Fri, 17 Jun 2016 11:00:43 -0600 Subject: [PATCH] LPC2378/LPC214x: Convert *err() to either *info() or add ERROR:, depending on if an error is reported --- arch/arm/src/lpc214x/lpc214x_serial.c | 2 +- arch/arm/src/lpc214x/lpc214x_usbdev.c | 14 +++++++------- arch/arm/src/lpc2378/lpc23xx_i2c.c | 2 +- arch/arm/src/lpc2378/lpc23xx_serial.c | 2 +- arch/arm/src/lpc2378/lpc23xx_spi.c | 6 +++--- 5 files changed, 13 insertions(+), 13 deletions(-) diff --git a/arch/arm/src/lpc214x/lpc214x_serial.c b/arch/arm/src/lpc214x/lpc214x_serial.c index 1f699f51295..e1b3511f9ca 100644 --- a/arch/arm/src/lpc214x/lpc214x_serial.c +++ b/arch/arm/src/lpc214x/lpc214x_serial.c @@ -549,7 +549,7 @@ static int up_interrupt(int irq, void *context) default: { - _err("Unexpected IIR: %02x\n", status); + _err("ERROR: Unexpected IIR: %02x\n", status); break; } } diff --git a/arch/arm/src/lpc214x/lpc214x_usbdev.c b/arch/arm/src/lpc214x/lpc214x_usbdev.c index e9ea74f088a..72398781482 100644 --- a/arch/arm/src/lpc214x/lpc214x_usbdev.c +++ b/arch/arm/src/lpc214x/lpc214x_usbdev.c @@ -382,7 +382,7 @@ struct lpc214x_usbdev_s /* Register operations ********************************************************/ -#if defined(CONFIG_LPC214X_USBDEV_REGDEBUG) && defined(CONFIG_DEBUG_FEATURES) +#ifdef CONFIG_LPC214X_USBDEV_REGDEBUG static uint32_t lpc214x_getreg(uint32_t addr); static void lpc214x_putreg(uint32_t val, uint32_t addr); #else @@ -518,7 +518,7 @@ static const struct usbdev_ops_s g_devops = * ****************************************************************************/ -#if defined(CONFIG_LPC214X_USBDEV_REGDEBUG) && defined(CONFIG_DEBUG_FEATURES) +#ifdef CONFIG_LPC214X_USBDEV_REGDEBUG static uint32_t lpc214x_getreg(uint32_t addr) { static uint32_t prevaddr = 0; @@ -539,7 +539,7 @@ static uint32_t lpc214x_getreg(uint32_t addr) { if (count == 4) { - _llerr("...\n"); + ullinfo("...\n"); } return val; @@ -556,7 +556,7 @@ static uint32_t lpc214x_getreg(uint32_t addr) { /* Yes.. then show how many times the value repeated */ - _llerr("[repeats %d more times]\n", count-3); + ullinfo("[repeats %d more times]\n", count-3); } /* Save the new address, value, and count */ @@ -568,7 +568,7 @@ static uint32_t lpc214x_getreg(uint32_t addr) /* Show the register value read */ - _llerr("%08x->%08x\n", addr, val); + ullinfo("%08x->%08x\n", addr, val); return val; } #endif @@ -581,12 +581,12 @@ static uint32_t lpc214x_getreg(uint32_t addr) * ****************************************************************************/ -#if defined(CONFIG_LPC214X_USBDEV_REGDEBUG) && defined(CONFIG_DEBUG_FEATURES) +#ifdef CONFIG_LPC214X_USBDEV_REGDEBUG static void lpc214x_putreg(uint32_t val, uint32_t addr) { /* Show the register value being written */ - _llerr("%08x<-%08x\n", addr, val); + ullinfo("%08x<-%08x\n", addr, val); /* Write the value */ diff --git a/arch/arm/src/lpc2378/lpc23xx_i2c.c b/arch/arm/src/lpc2378/lpc23xx_i2c.c index 6932e932102..1c281e88574 100644 --- a/arch/arm/src/lpc2378/lpc23xx_i2c.c +++ b/arch/arm/src/lpc2378/lpc23xx_i2c.c @@ -490,7 +490,7 @@ struct i2c_master_s *lpc2378_i2cbus_initialize(int port) if (port > 1) { - _err("lpc I2C Only support 0,1\n"); + l2cerr("ERROR: lpc I2C Only support 0,1\n"); return NULL; } diff --git a/arch/arm/src/lpc2378/lpc23xx_serial.c b/arch/arm/src/lpc2378/lpc23xx_serial.c index 50aaa662a6b..48e322ec15a 100644 --- a/arch/arm/src/lpc2378/lpc23xx_serial.c +++ b/arch/arm/src/lpc2378/lpc23xx_serial.c @@ -667,7 +667,7 @@ static int up_interrupt(int irq, void *context) default: { - _err("Unexpected IIR: %02x\n", status); + _err("ERROR: Unexpected IIR: %02x\n", status); break; } } diff --git a/arch/arm/src/lpc2378/lpc23xx_spi.c b/arch/arm/src/lpc2378/lpc23xx_spi.c index 95b0cdcd1d7..cf95f63a8bc 100644 --- a/arch/arm/src/lpc2378/lpc23xx_spi.c +++ b/arch/arm/src/lpc2378/lpc23xx_spi.c @@ -274,7 +274,7 @@ static uint32_t spi_setfrequency(FAR struct spi_dev_s *dev, uint32_t frequency) priv->frequency = frequency; priv->actual = actual; - spierr("Frequency %d->%d\n", frequency, actual); + spiinfo("Frequency %d->%d\n", frequency, actual); return actual; } @@ -438,7 +438,7 @@ static void spi_sndblock(FAR struct spi_dev_s *dev, FAR const void *buffer, size FAR uint8_t *ptr = (FAR uint8_t *)buffer; uint8_t data; - spierr("nwords: %d\n", nwords); + spiinfo("nwords: %d\n", nwords); while (nwords) { /* Write the data to transmitted to the SPI Data Register */ @@ -483,7 +483,7 @@ static void spi_recvblock(FAR struct spi_dev_s *dev, FAR void *buffer, size_t nw { FAR uint8_t *ptr = (FAR uint8_t *)buffer; - spierr("nwords: %d\n", nwords); + spiinfo("nwords: %d\n", nwords); while (nwords) { /* Write some dummy data to the SPI Data Register in order to clock the