From dcba65f824817596e817a43f83ef83bac9099e76 Mon Sep 17 00:00:00 2001 From: Kevin Wolf Date: Mon, 5 Oct 2020 17:58:42 +0200 Subject: monitor: Add Monitor parameter to monitor_set_cpu() Most callers actually don't have to rely on cur_mon, but already know for which monitor they call monitor_set_cpu(). Signed-off-by: Kevin Wolf Reviewed-by: Eric Blake Message-Id: <20201005155855.256490-2-kwolf@redhat.com> Reviewed-by: Markus Armbruster Reviewed-by: Stefan Hajnoczi Signed-off-by: Markus Armbruster --- monitor/hmp-cmds.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'monitor/hmp-cmds.c') diff --git a/monitor/hmp-cmds.c b/monitor/hmp-cmds.c index dc0de39219..0c0a03f824 100644 --- a/monitor/hmp-cmds.c +++ b/monitor/hmp-cmds.c @@ -998,7 +998,7 @@ void hmp_cpu(Monitor *mon, const QDict *qdict) /* XXX: drop the monitor_set_cpu() usage when all HMP commands that use it are converted to the QAPI */ cpu_index = qdict_get_int(qdict, "index"); - if (monitor_set_cpu(cpu_index) < 0) { + if (monitor_set_cpu(mon, cpu_index) < 0) { monitor_printf(mon, "invalid CPU index\n"); } } -- cgit 1.4.1