[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Qemu-devel] [PATCH 0/8] i.MX: Standardize debug code
From: |
Peter Crosthwaite |
Subject: |
Re: [Qemu-devel] [PATCH 0/8] i.MX: Standardize debug code |
Date: |
Tue, 20 Oct 2015 16:10:16 -0700 |
On Tue, Oct 20, 2015 at 2:19 PM, Jean-Christophe Dubois
<address@hidden> wrote:
> We fix all i.MX driver files to use the same type of debug code.
>
> The goal is to have debug code always compiled during build.
>
It goes beyond that, it that the logs are now going to be way easier
to read with a consistent formatting of verbose messages. I think this
is a good idea, and with a lack of precedent (that I know of) you may
be setting a tree-wide standard here. CC Markus who is into logs and
errors. Patch 2 sums up nicely the proposed format:
if (DEBUG_IMX_GPIO) { \
- fprintf(stderr, "%s: " fmt , __func__, ##args); \
+ fprintf(stderr, "[%s]%s: " fmt , TYPE_IMX_GPIO, \
+ __func__, ##args); \
which is:
[QOM_TYPE_NAME]reporting_function: some printf type message
so general RFC on what other think of it. Are there any existing
in-tree standards to factor in? I am OK in principle.
Regards,
Peter
> Jean-Christophe Dubois (8):
> i.MX: Standardize i.MX serial debug.
> i.MX: Standardize i.MX GPIO debug
> i.MX: Standardize i.MX I2C debug
> i.MX: Standardize i.MX AVIC debug
> i.MX: Standardize i.MX CCM debug
> i.MX: Standardize i.MX FEC debug
> i.MX: Standardize i.MX EPIT debug
> i.MX: Standardize i.MX GPT debug
>
> hw/char/imx_serial.c | 39 +++++++++++++++++----------------------
> hw/gpio/imx_gpio.c | 3 ++-
> hw/i2c/imx_i2c.c | 25 +++++++++++++------------
> hw/intc/imx_avic.c | 40 ++++++++++++++++------------------------
> hw/misc/imx_ccm.c | 30 ++++++++++++++++++++----------
> hw/net/imx_fec.c | 38 ++++++++++++++++++--------------------
> hw/timer/imx_epit.c | 37 +++++++++++++++----------------------
> hw/timer/imx_gpt.c | 40 +++++++++++++++-------------------------
> 8 files changed, 116 insertions(+), 136 deletions(-)
>
> --
> 2.1.4
>
- [Qemu-devel] [PATCH 2/8] i.MX: Standardize i.MX GPIO debug, (continued)
- [Qemu-devel] [PATCH 2/8] i.MX: Standardize i.MX GPIO debug, Jean-Christophe Dubois, 2015/10/20
- [Qemu-devel] [PATCH 3/8] i.MX: Standardize i.MX I2C debug, Jean-Christophe Dubois, 2015/10/20
- [Qemu-devel] [PATCH 4/8] i.MX: Standardize i.MX AVIC debug, Jean-Christophe Dubois, 2015/10/20
- [Qemu-devel] [PATCH 5/8] i.MX: Standardize i.MX CCM debug, Jean-Christophe Dubois, 2015/10/20
- [Qemu-devel] [PATCH 7/8] i.MX: Standardize i.MX EPIT debug, Jean-Christophe Dubois, 2015/10/20
- [Qemu-devel] [PATCH 8/8] i.MX: Standardize i.MX GPT debug, Jean-Christophe Dubois, 2015/10/20
- [Qemu-devel] [PATCH 6/8] i.MX: Standardize i.MX FEC debug, Jean-Christophe Dubois, 2015/10/20
- Re: [Qemu-devel] [PATCH 0/8] i.MX: Standardize debug code,
Peter Crosthwaite <=