mirror of
https://github.com/qemu/qemu.git
synced 2025-10-28 06:54:53 +00:00
spapr_reallocate_hpt() has three users, two of which pass &error_fatal and the third one, htab_load(), passes &local_err, uses it to detect failures and simply propagates -EINVAL up to vmstate_load(), which will cause QEMU to exit. It is thus confusing that spapr_reallocate_hpt() doesn't return right away when an error is detected in some cases. Also, the comment suggesting that the caller is welcome to try to carry on seems like a remnant in this respect. This can be improved: - change spapr_reallocate_hpt() to always report a negative errno on failure, either as reported by KVM or -ENOSPC if the HPT is smaller than what was asked, - use that to detect failures in htab_load() which is preferred over checking &local_err, - propagate this negative errno to vmstate_load() because it is more accurate than propagating -EINVAL for all possible errors. [dwg: Fix compile error due to omitted prelim patch] Signed-off-by: Greg Kurz <groug@kaod.org> Message-Id: <160371605460.305923.5890143959901241157.stgit@bahia.lan> Signed-off-by: David Gibson <david@gibson.dropbear.id.au> |
||
|---|---|---|
| .. | ||
| fdt.h | ||
| mac_dbdma.h | ||
| openpic_kvm.h | ||
| openpic.h | ||
| pnv_core.h | ||
| pnv_homer.h | ||
| pnv_lpc.h | ||
| pnv_occ.h | ||
| pnv_pnor.h | ||
| pnv_psi.h | ||
| pnv_xive.h | ||
| pnv_xscom.h | ||
| pnv.h | ||
| ppc4xx.h | ||
| ppc_e500.h | ||
| ppc.h | ||
| spapr_cpu_core.h | ||
| spapr_drc.h | ||
| spapr_irq.h | ||
| spapr_numa.h | ||
| spapr_nvdimm.h | ||
| spapr_ovec.h | ||
| spapr_rtas.h | ||
| spapr_tpm_proxy.h | ||
| spapr_vio.h | ||
| spapr_xive.h | ||
| spapr.h | ||
| xics_spapr.h | ||
| xics.h | ||
| xive_regs.h | ||
| xive.h | ||