On 8/23/21 2:27 PM, Yanan Wang wrote: > Currently the only difference between smp_parse and pc_smp_parse > is the support of dies parameter and the related error reporting. > With some arch compat variables like "bool dies_supported", we can > make smp_parse generic enough for all arches and the PC specific > one can be removed.
Ah, this is the opposite argument to my reply to your patch #5. > Making smp_parse() generic enough can reduce code duplication and > ease the code maintenance, and also allows extending the topology > with more arch specific members (e.g., clusters) in the future. > > Suggested-by: Andrew Jones <drjo...@redhat.com> > Signed-off-by: Yanan Wang <wangyana...@huawei.com> > Reviewed-by: Andrew Jones <drjo...@redhat.com> > --- > hw/core/machine.c | 110 ++++++++++++++++++++++++++++++++++++-------- > hw/i386/pc.c | 84 +-------------------------------- > include/hw/boards.h | 9 ++++ > 3 files changed, 100 insertions(+), 103 deletions(-)