target/ppc: Fix the order of kvm_enable judgment about kvmppc_set_interrupt()
commit76d93e146768dde7e38b6e5e43c27e478ccb580e
authorjianchunfu <chunfu.jian@shingroup.cn>
Fri, 21 Jul 2023 07:37:34 +0000 (21 15:37 +0800)
committerCédric Le Goater <clg@kaod.org>
Wed, 6 Sep 2023 09:19:33 +0000 (6 11:19 +0200)
tree63c4ace577fa527e9845af19facf782eb37a294f
parent6ec65b69ba17c954414fa23a397fb8a3fcfb4a43
target/ppc: Fix the order of kvm_enable judgment about kvmppc_set_interrupt()

It's unnecessary for non-KVM accelerators(TCG, for example),
to call this function, so change the order of kvm_enable() judgment.

The static inline function that returns -1 directly does not work
 in TCG's situation.

Signed-off-by: jianchunfu <chunfu.jian@shingroup.cn>
Tested-by: Gautam Menghani <gautam@linux.ibm.com>
Signed-off-by: Cédric Le Goater <clg@kaod.org>
hw/ppc/ppc.c
target/ppc/kvm.c