diff mbox series

[15/15] sun4u: switch from EBUS_DPRINTF() macro to trace-events

Message ID 1510926167-23326-16-git-send-email-mark.cave-ayland@ilande.co.uk
State New
Headers show
Series sun4u: tidy-up CPU, APB and ebus | expand

Commit Message

Mark Cave-Ayland Nov. 17, 2017, 1:42 p.m. UTC
Signed-off-by: Mark Cave-Ayland <mark.cave-ayland@ilande.co.uk>
---
 hw/sparc64/sun4u.c      |   12 ++----------
 hw/sparc64/trace-events |    3 +++
 2 files changed, 5 insertions(+), 10 deletions(-)

Comments

Philippe Mathieu-Daudé Nov. 17, 2017, 7:10 p.m. UTC | #1
On 11/17/2017 10:42 AM, Mark Cave-Ayland wrote:
> Signed-off-by: Mark Cave-Ayland <mark.cave-ayland@ilande.co.uk>

Reviewed-by: Philippe Mathieu-Daudé <f4bug@amsat.org>

> ---
>  hw/sparc64/sun4u.c      |   12 ++----------
>  hw/sparc64/trace-events |    3 +++
>  2 files changed, 5 insertions(+), 10 deletions(-)
> 
> diff --git a/hw/sparc64/sun4u.c b/hw/sparc64/sun4u.c
> index da386d3..50ccf75 100644
> --- a/hw/sparc64/sun4u.c
> +++ b/hw/sparc64/sun4u.c
> @@ -47,17 +47,9 @@
>  #include "hw/ide/pci.h"
>  #include "hw/loader.h"
>  #include "elf.h"
> +#include "trace.h"
>  #include "qemu/cutils.h"
>  
> -//#define DEBUG_EBUS
> -
> -#ifdef DEBUG_EBUS
> -#define EBUS_DPRINTF(fmt, ...)                                  \
> -    do { printf("EBUS: " fmt , ## __VA_ARGS__); } while (0)
> -#else
> -#define EBUS_DPRINTF(fmt, ...)
> -#endif
> -
>  #define KERNEL_LOAD_ADDR     0x00404000
>  #define CMDLINE_ADDR         0x003ff000
>  #define PROM_SIZE_MAX        (4 * 1024 * 1024)
> @@ -218,7 +210,7 @@ static void ebus_isa_irq_handler(void *opaque, int n, int level)
>      qemu_irq irq = s->isa_bus_irqs[n];
>  
>      /* Pass ISA bus IRQs onto their gpio equivalent */
> -    EBUS_DPRINTF("Set ISA IRQ %d level %d\n", n, level);
> +    trace_ebus_isa_irq_handler(n, level);
>      if (irq) {
>          qemu_set_irq(irq, level);
>      }
> diff --git a/hw/sparc64/trace-events b/hw/sparc64/trace-events
> index 9284b1f..04d80b7 100644
> --- a/hw/sparc64/trace-events
> +++ b/hw/sparc64/trace-events
> @@ -1 +1,4 @@
>  # See docs/devel/tracing.txt for syntax documentation.
> +
> +# hw/sparc64/sun4u.c
> +ebus_isa_irq_handler(int n, int level) "Set ISA IRQ %d level %d"
>
diff mbox series

Patch

diff --git a/hw/sparc64/sun4u.c b/hw/sparc64/sun4u.c
index da386d3..50ccf75 100644
--- a/hw/sparc64/sun4u.c
+++ b/hw/sparc64/sun4u.c
@@ -47,17 +47,9 @@ 
 #include "hw/ide/pci.h"
 #include "hw/loader.h"
 #include "elf.h"
+#include "trace.h"
 #include "qemu/cutils.h"
 
-//#define DEBUG_EBUS
-
-#ifdef DEBUG_EBUS
-#define EBUS_DPRINTF(fmt, ...)                                  \
-    do { printf("EBUS: " fmt , ## __VA_ARGS__); } while (0)
-#else
-#define EBUS_DPRINTF(fmt, ...)
-#endif
-
 #define KERNEL_LOAD_ADDR     0x00404000
 #define CMDLINE_ADDR         0x003ff000
 #define PROM_SIZE_MAX        (4 * 1024 * 1024)
@@ -218,7 +210,7 @@  static void ebus_isa_irq_handler(void *opaque, int n, int level)
     qemu_irq irq = s->isa_bus_irqs[n];
 
     /* Pass ISA bus IRQs onto their gpio equivalent */
-    EBUS_DPRINTF("Set ISA IRQ %d level %d\n", n, level);
+    trace_ebus_isa_irq_handler(n, level);
     if (irq) {
         qemu_set_irq(irq, level);
     }
diff --git a/hw/sparc64/trace-events b/hw/sparc64/trace-events
index 9284b1f..04d80b7 100644
--- a/hw/sparc64/trace-events
+++ b/hw/sparc64/trace-events
@@ -1 +1,4 @@ 
 # See docs/devel/tracing.txt for syntax documentation.
+
+# hw/sparc64/sun4u.c
+ebus_isa_irq_handler(int n, int level) "Set ISA IRQ %d level %d"