mirror of
https://github.com/Motorhead1991/qemu.git
synced 2025-07-27 04:13:53 -06:00
pci: Reject pcie_aer_inject_error -c with symbolic error status
When argument @error_status is symbolic, flag -c is ignored. Reject it instead. Signed-off-by: Markus Armbruster <armbru@redhat.com> Message-Id: <20221201121133.3813857-14-armbru@redhat.com>
This commit is contained in:
parent
ba235d33e8
commit
e221cfac59
1 changed files with 5 additions and 0 deletions
|
@ -189,6 +189,11 @@ void hmp_pcie_aer_inject_error(Monitor *mon, const QDict *qdict)
|
|||
}
|
||||
error_status = num;
|
||||
correctable = qdict_get_try_bool(qdict, "correctable", false);
|
||||
} else {
|
||||
if (qdict_haskey(qdict, "correctable")) {
|
||||
error_setg(&err, "-c is only valid with numeric error status");
|
||||
goto out;
|
||||
}
|
||||
}
|
||||
aer_err.status = error_status;
|
||||
aer_err.source_id = pci_requester_id(dev);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue