[PATCH 0/3] spapr: Improve error reporting in spapr_caps.c

Greg Kurz posted 3 patches 3 years, 10 months ago
Test docker-mingw@fedora passed
Test checkpatch passed
Test asan passed
Test docker-quick@centos7 passed
Test FreeBSD passed
Patches applied successfully (tree, apply log)
git fetch https://github.com/patchew-project/qemu tags/patchew/159180935807.29090.16079635439548762534.stgit@bahia.lan
Maintainers: Michael Roth <mdroth@linux.vnet.ibm.com>, David Gibson <david@gibson.dropbear.id.au>, Markus Armbruster <armbru@redhat.com>
There is a newer version of this series
hw/ppc/spapr_caps.c  |  104 +++++++++++++++----------
include/qapi/error.h |  205 ++++++++++++++++++++++++++++++++++++++++++--------
2 files changed, 236 insertions(+), 73 deletions(-)
[PATCH 0/3] spapr: Improve error reporting in spapr_caps.c
Posted by Greg Kurz 3 years, 10 months ago
Spapr capabilities are checked at machine init. If a capability cannot
be used, an error message is printed and QEMU exits. In most places,
the error message also contains an hint for the user. But we should
use error_append_hint() for that, as explained in the "qapi/error.h"
header.

This is already the case for cap_fwnmi_apply() and we now want to add 
a similar check for nested KVM-HV. Unfortunately, spapr_caps_apply()
passes &error_fatal to all apply hooks and error_append_hint() is
never called. 

So this reuses previous work from Vladimir Sementsov-Ogievskiy to
address that.

---

Greg Kurz (2):
      spapr: Use error_append_hint() in spapr_caps.c
      spapr: Forbid nested KVM-HV in pre-power9 compat mode

Vladimir Sementsov-Ogievskiy (1):
      error: auto propagated local_err


 hw/ppc/spapr_caps.c  |  104 +++++++++++++++----------
 include/qapi/error.h |  205 ++++++++++++++++++++++++++++++++++++++++++--------
 2 files changed, 236 insertions(+), 73 deletions(-)

--
Greg