qemu/hw/sparc
Philippe Mathieu-Daudé 1284119991 hw/sparc: Allow building without the leon3 machine
When building without the leon3 machine, we get this link failure:

  /usr/bin/ld: target_sparc_int32_helper.c.o: in function `leon3_irq_manager':
  target/sparc/int32_helper.c:172: undefined reference to `leon3_irq_ack'

This is because the leon3_irq_ack() is declared in hw/sparc/leon3.c,
which is only build when CONFIG_LEON3 is selected.

Fix by moving the leon3_cache_control_int() / leon3_irq_manager()
(which are specific to the leon3 machine) to hw/sparc/leon3.c.
Move the trace events along (but don't rename them).

leon3_irq_ack() is now locally used, declare it static to reduce
its scope.

Reviewed-by: Richard Henderson <richard.henderson@linaro.org>
Reviewed-by: KONRAD Frederic <frederic.konrad@adacore.com>
Tested-by: KONRAD Frederic <frederic.konrad@adacore.com>
Signed-off-by: Philippe Mathieu-Daudé <f4bug@amsat.org>
Reviewed-by: Mark Cave-Ayland <mark.cave-ayland@ilande.co.uk>
Message-Id: <20210428141655.387430-2-f4bug@amsat.org>
Signed-off-by: Mark Cave-Ayland <mark.cave-ayland@ilande.co.uk>
2021-05-04 22:45:53 +01:00
..
Kconfig sun4m: don't connect two qemu_irqs directly to the same input 2021-01-06 11:41:37 +00:00
leon3.c hw/sparc: Allow building without the leon3 machine 2021-05-04 22:45:53 +01:00
meson.build meson: convert hw/arch* 2020-08-21 06:30:33 -04:00
sun4m_iommu.c qdev: set properties with device_class_set_props() 2020-01-24 20:59:15 +01:00
sun4m.c hw/sparc/sun4m: Move each sun4m_hwdef definition in its class_init 2021-05-04 22:45:28 +01:00
trace-events hw/sparc: Allow building without the leon3 machine 2021-05-04 22:45:53 +01:00
trace.h trace: switch position of headers to what Meson requires 2020-08-21 06:18:24 -04:00