From 12da30977813472b91f0ba1a69f9258bbe679b2e Mon Sep 17 00:00:00 2001 From: Gonglei Date: Tue, 7 Oct 2014 16:00:11 +0800 Subject: bootindex: add a setter/getter functions wrapper for bootindex property when we remove bootindex form qdev.property to qom.property, we can use those functions set/get bootindex property for all correlative devices. Meanwhile set the initial value of bootindex to -1. Signed-off-by: Gonglei Reviewed-by: Gerd Hoffmann Acked-by: Paolo Bonzini Signed-off-by: Gerd Hoffmann --- include/sysemu/sysemu.h | 3 +++ 1 file changed, 3 insertions(+) (limited to 'include') diff --git a/include/sysemu/sysemu.h b/include/sysemu/sysemu.h index b3489be..0037a69 100644 --- a/include/sysemu/sysemu.h +++ b/include/sysemu/sysemu.h @@ -215,6 +215,9 @@ char *get_boot_devices_list(size_t *size, bool ignore_suffixes); DeviceState *get_boot_device(uint32_t position); void check_boot_index(int32_t bootindex, Error **errp); void del_boot_device_path(DeviceState *dev, const char *suffix); +void device_add_bootindex_property(Object *obj, int32_t *bootindex, + const char *name, const char *suffix, + DeviceState *dev, Error **errp); QemuOpts *qemu_get_machine_opts(void); -- cgit v1.1