QError: Add QERR_KVM_MISSING_CAP New class for KVM unavailable features errors. Signed-off-by: Luiz Capitulino <lcapitulino@redhat.com> Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
diff --git a/qerror.c b/qerror.c index 0c0a510..d8b125e 100644 --- a/qerror.c +++ b/qerror.c
@@ -48,6 +48,10 @@ .error_fmt = QERR_DEVICE_NOT_ACTIVE, .desc = "The %(device) device has not been activated by the guest", }, + { + .error_fmt = QERR_KVM_MISSING_CAP, + .desc = "Using KVM without %(capability), %(feature) unavailable", + }, {} };
diff --git a/qerror.h b/qerror.h index c1be8b9..6c100af 100644 --- a/qerror.h +++ b/qerror.h
@@ -44,4 +44,7 @@ #define QERR_DEVICE_NOT_ACTIVE \ "{ 'class': 'DeviceNotActive', 'data': { 'device': %s } }" +#define QERR_KVM_MISSING_CAP \ + "{ 'class': 'KVMMissingCap', 'data': { 'capability': %s, 'feature': %s } }" + #endif /* QERROR_H */