On 9/28/21 05:57, Yanan Wang wrote: > Now we have a generic smp parser for all arches, and there will > not be any other arch specific ones, so let's remove the callback > from MachineClass and call the parser directly. > > Signed-off-by: Yanan Wang <wangyana...@huawei.com> > Reviewed-by: Andrew Jones <drjo...@redhat.com> > --- > hw/core/machine.c | 3 +-- > include/hw/boards.h | 5 ----- > 2 files changed, 1 insertion(+), 7 deletions(-) > > diff --git a/hw/core/machine.c b/hw/core/machine.c > index f5dadcbd78..23f77201eb 100644 > --- a/hw/core/machine.c > +++ b/hw/core/machine.c > @@ -918,7 +918,7 @@ static void machine_set_smp(Object *obj, Visitor *v, > const char *name, > "CPU topology parameters must be greater than zero"); > } > > - mc->smp_parse(ms, config, errp); > + smp_parse(ms, config, errp); > if (*errp) {
If smp_parse() were to return a boolean, this would become: if (!smp_parse(ms, config, errp)) { Regardless: Reviewed-by: Philippe Mathieu-Daudé <phi...@redhat.com> > goto out_free; > }