On 7/8/24 05:46, Richard Henderson wrote:
On 8/7/24 00:19, Philippe Mathieu-Daudé wrote:
qmp_query_gic_capabilities() is not specific to the ARM
architecture but to the GIC device which is modelled in
hw/intc/, so move the code there for clarity.
But the GIC is certainly arm architecture specific.
It's built into the CPU, and shares state.
Yes... but there are also SoC with ARM cores, GIC and non-ARM cores ;)
Example: ZynqMP with MicroBlaze cores.
The fact that it's modeled in hw/intc/ and not in target/arm/ has always
been a needle in the side, though it seems there are no good options.
@@ -39,6 +39,7 @@ if config_all_devices.has_key('CONFIG_APIC') or \
endif
specific_ss.add(when: 'CONFIG_APIC', if_true: files('apic.c',
'apic_common.c'))
+specific_ss.add(when: 'CONFIG_ARM', if_true: files('arm_gic_qmp.c'))
specific_ss.add(when: 'CONFIG_ARM_GIC', if_true:
files('arm_gicv3_cpuif_common.c'))
Is it more or less confusing that you're not using CONFIG_ARM_GIC, for
something that is GIC related?
(You figured in the next patch) this commit aims to be "no logical
change" to indeed use CONFIG_ARM_GIC in the next (simpler) patch.