From: Gavin Shan Date: Mon, 1 Dec 2025 14:18:00 +0000 (+1000) Subject: acpi/ghes: Abort in acpi_ghes_memory_errors() if necessary X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=27814d0e63f911432f493de2d74c4d030010afc0;p=thirdparty%2Fqemu.git acpi/ghes: Abort in acpi_ghes_memory_errors() if necessary The function hw/acpi/ghes-stub.c::acpi_ghes_memory_errors() shouldn't be called by any one. Take g_assert_not_reached() as a clearer indication. Suggested-by: Markus Armbruster Signed-off-by: Gavin Shan Reviewed-by: Igor Mammedov Reviewed-by: Mauro Carvalho Chehab Reviewed-by: Michael S. Tsirkin Signed-off-by: Michael S. Tsirkin Message-Id: <20251201141803.2386129-3-gshan@redhat.com> --- diff --git a/hw/acpi/ghes-stub.c b/hw/acpi/ghes-stub.c index 40f660c246..b54f1b093c 100644 --- a/hw/acpi/ghes-stub.c +++ b/hw/acpi/ghes-stub.c @@ -14,7 +14,7 @@ int acpi_ghes_memory_errors(AcpiGhesState *ags, uint16_t source_id, uint64_t physical_address) { - return -1; + g_assert_not_reached(); } AcpiGhesState *acpi_ghes_get_state(void)