i.MX:Fix Coding style for UART emulator.
Signed-off-by: Jean-Christophe Dubois <jcd@tribudubois.net> Reviewed-by: Peter Crosthwaite <crosthwaite.peter@gmail.com> Message-id: 23ab872b7cd30b1399384fb26a2ebb75e9761d7b.1437080501.git.jcd@tribudubois.net Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
This commit is contained in:
parent
f6c64000f9
commit
fa2650a37e
|
@ -26,7 +26,7 @@
|
||||||
//#define DEBUG_SERIAL 1
|
//#define DEBUG_SERIAL 1
|
||||||
#ifdef DEBUG_SERIAL
|
#ifdef DEBUG_SERIAL
|
||||||
#define DPRINTF(fmt, args...) \
|
#define DPRINTF(fmt, args...) \
|
||||||
do { printf("imx_serial: " fmt , ##args); } while (0)
|
do { printf("%s: " fmt , TYPE_IMX_SERIAL, ##args); } while (0)
|
||||||
#else
|
#else
|
||||||
#define DPRINTF(fmt, args...) do {} while (0)
|
#define DPRINTF(fmt, args...) do {} while (0)
|
||||||
#endif
|
#endif
|
||||||
|
@ -38,13 +38,13 @@ do { printf("imx_serial: " fmt , ##args); } while (0)
|
||||||
//#define DEBUG_IMPLEMENTATION 1
|
//#define DEBUG_IMPLEMENTATION 1
|
||||||
#ifdef DEBUG_IMPLEMENTATION
|
#ifdef DEBUG_IMPLEMENTATION
|
||||||
# define IPRINTF(fmt, args...) \
|
# define IPRINTF(fmt, args...) \
|
||||||
do { fprintf(stderr, "imx_serial: " fmt, ##args); } while (0)
|
do { fprintf(stderr, "%s: " fmt, TYPE_IMX_SERIAL, ##args); } while (0)
|
||||||
#else
|
#else
|
||||||
# define IPRINTF(fmt, args...) do {} while (0)
|
# define IPRINTF(fmt, args...) do {} while (0)
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
static const VMStateDescription vmstate_imx_serial = {
|
static const VMStateDescription vmstate_imx_serial = {
|
||||||
.name = "imx-serial",
|
.name = TYPE_IMX_SERIAL,
|
||||||
.version_id = 1,
|
.version_id = 1,
|
||||||
.minimum_version_id = 1,
|
.minimum_version_id = 1,
|
||||||
.fields = (VMStateField[]) {
|
.fields = (VMStateField[]) {
|
||||||
|
@ -164,7 +164,7 @@ static uint64_t imx_serial_read(void *opaque, hwaddr offset,
|
||||||
return 0x0; /* TODO */
|
return 0x0; /* TODO */
|
||||||
|
|
||||||
default:
|
default:
|
||||||
IPRINTF("imx_serial_read: bad offset: 0x%x\n", (int)offset);
|
IPRINTF("%s: bad offset: 0x%x\n", __func__, (int)offset);
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -266,7 +266,7 @@ static void imx_serial_write(void *opaque, hwaddr offset,
|
||||||
break;
|
break;
|
||||||
|
|
||||||
default:
|
default:
|
||||||
IPRINTF("imx_serial_write: Bad offset 0x%x\n", (int)offset);
|
IPRINTF("%s: Bad offset 0x%x\n", __func__, (int)offset);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue