OSDN Git Service

rocker: Tweak stubbed out monitor commands' error messages
authorMarkus Armbruster <armbru@redhat.com>
Tue, 7 Feb 2023 07:51:15 +0000 (08:51 +0100)
committerMarkus Armbruster <armbru@redhat.com>
Thu, 23 Feb 2023 13:10:17 +0000 (14:10 +0100)
commit1178710247017ee4f570b16a186ee48c250a18d1
treeab5a5ccba45d9327a19864ab80cb630e2cf93caf
parent43aef7e632c98573d907e7d86bbf3a1d6cc68f88
rocker: Tweak stubbed out monitor commands' error messages

The QERR_ macros are leftovers from the days of "rich" error objects.
We've been trying to reduce their remaining use.

The stubbed out Rocker monitor commands are the last remaining users
of QERR_FEATURE_DISABLED.  They fail like this:

    (qemu) info rocker mumble
    Error: The feature 'rocker' is not enabled

The real rocker commands fail like this when the named object doesn't
exist:

    Error: rocker mumble not found

If that's good enough when Rocker is enabled, then it's good enough
when it's disabled, so replace QERR_FEATURE_DISABLED with that, and
drop the macro.

Signed-off-by: Markus Armbruster <armbru@redhat.com>
Message-Id: <20230207075115.1525-13-armbru@redhat.com>
Reviewed-by: Philippe Mathieu-Daudé <philmd@linaro.org>
Reviewed-by: Juan Quintela <quintela@redhat.com>
hw/net/rocker/qmp-norocker.c
include/qapi/qmp/qerror.h