From 43df70a9ddfc40961188bf1c6f67fed3b899b8da Mon Sep 17 00:00:00 2001 From: Marc-André Lureau Date: Wed, 12 Dec 2018 19:36:30 +0400 Subject: compat: replace PC_COMPAT_2_11 & HW_COMPAT_2_11 macros Use static arrays instead. Suggested-by: Eduardo Habkost Signed-off-by: Marc-André Lureau Reviewed-by: Igor Mammedov Reviewed-by: Cornelia Huck Acked-by: Eduardo Habkost --- include/hw/boards.h | 3 +++ include/hw/compat.h | 19 ------------------- include/hw/i386/pc.h | 13 ++----------- 3 files changed, 5 insertions(+), 30 deletions(-) (limited to 'include') diff --git a/include/hw/boards.h b/include/hw/boards.h index c6d828e73c..67202b5a2f 100644 --- a/include/hw/boards.h +++ b/include/hw/boards.h @@ -297,4 +297,7 @@ extern const size_t hw_compat_3_0_len; extern GlobalProperty hw_compat_2_12[]; extern const size_t hw_compat_2_12_len; +extern GlobalProperty hw_compat_2_11[]; +extern const size_t hw_compat_2_11_len; + #endif diff --git a/include/hw/compat.h b/include/hw/compat.h index 13242b831a..cf389b4e85 100644 --- a/include/hw/compat.h +++ b/include/hw/compat.h @@ -1,25 +1,6 @@ #ifndef HW_COMPAT_H #define HW_COMPAT_H -#define HW_COMPAT_2_11 \ - {\ - .driver = "hpet",\ - .property = "hpet-offset-saved",\ - .value = "false",\ - },{\ - .driver = "virtio-blk-pci",\ - .property = "vectors",\ - .value = "2",\ - },{\ - .driver = "vhost-user-blk-pci",\ - .property = "vectors",\ - .value = "2",\ - },{\ - .driver = "e1000",\ - .property = "migrate_tso_props",\ - .value = "off",\ - }, - #define HW_COMPAT_2_10 \ {\ .driver = "virtio-mouse-device",\ diff --git a/include/hw/i386/pc.h b/include/hw/i386/pc.h index 91cb3283f0..f0f7e76a3e 100644 --- a/include/hw/i386/pc.h +++ b/include/hw/i386/pc.h @@ -303,17 +303,8 @@ extern const size_t pc_compat_3_0_len; extern GlobalProperty pc_compat_2_12[]; extern const size_t pc_compat_2_12_len; -#define PC_COMPAT_2_11 \ - HW_COMPAT_2_11 \ - {\ - .driver = TYPE_X86_CPU,\ - .property = "x-migrate-smi-count",\ - .value = "off",\ - },{\ - .driver = "Skylake-Server" "-" TYPE_X86_CPU,\ - .property = "clflushopt",\ - .value = "off",\ - }, +extern GlobalProperty pc_compat_2_11[]; +extern const size_t pc_compat_2_11_len; #define PC_COMPAT_2_10 \ HW_COMPAT_2_10 \ -- cgit v1.2.3-55-g7522