Browse Source
In ghes_record_cper_errors(), get_ghes_source_offsets() can return a error initialized by error_setg(). Without bailing on this error, it can call into the second error_setg() due to the unexpected value returned from the read acknowledgement register. The second error_setg() can trigger assert(*errp == NULL) in its callee error_setv(), which isn't expected. Bail early in ghes_record_cper_errors() when error is received from get_ghes_source_offsets() to avoid the unexpected behavior. Signed-off-by: Gavin Shan <gshan@redhat.com> Reviewed-by: Jonathan Cameron <jonathan.cameron@huawei.com> Reviewed-by: Markus Armbruster <armbru@redhat.com> Reviewed-by: Igor Mammedov <imammedo@redhat.com> Reviewed-by: Mauro Carvalho Chehab <mchehab+huawei@kernel.org> Reviewed-by: Michael S. Tsirkin <mst@redhat.com> Signed-off-by: Michael S. Tsirkin <mst@redhat.com> Message-Id: <20251201141803.2386129-5-gshan@redhat.com>pull/319/head
committed by
Michael S. Tsirkin
1 changed files with 9 additions and 6 deletions
Loading…
Reference in new issue