From: Paolo Bonzini Date: Tue, 1 Feb 2022 19:09:41 +0000 (+0100) Subject: target/i386: the sgx_epc_get_section stub is reachable X-Git-Tag: v7.2.10~1 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=0ee0f9d8227ee6467807c4e9e549c0e166164dcb;p=thirdparty%2Fqemu.git target/i386: the sgx_epc_get_section stub is reachable The sgx_epc_get_section stub is reachable from cpu_x86_cpuid. It should not assert, instead it should just return true just like the "real" sgx_epc_get_section does when SGX is disabled. Reported-by: Vladimír Beneš Cc: qemu-stable@nongnu.org Signed-off-by: Paolo Bonzini Message-ID: <20220201190941.106001-1-pbonzini@redhat.com> Signed-off-by: Paolo Bonzini (cherry picked from commit 219615740425d9683588207b40a365e6741691a6) Signed-off-by: Michael Tokarev --- diff --git a/hw/i386/sgx-stub.c b/hw/i386/sgx-stub.c index 26833eb233c..16b1dfd90bb 100644 --- a/hw/i386/sgx-stub.c +++ b/hw/i386/sgx-stub.c @@ -34,5 +34,5 @@ void pc_machine_init_sgx_epc(PCMachineState *pcms) bool sgx_epc_get_section(int section_nr, uint64_t *addr, uint64_t *size) { - g_assert_not_reached(); + return true; }