diff options
author | Paolo Bonzini <pbonzini@redhat.com> | 2022-09-10 13:44:47 +0200 |
---|---|---|
committer | Paolo Bonzini <pbonzini@redhat.com> | 2022-09-29 11:40:28 +0200 |
commit | 5433af7697ba97531d97e16e721cfe8a90722198 (patch) | |
tree | c0249d5dd7c856e3b07cb80b064ffa7f729b77fd /hw/watchdog/watchdog.c | |
parent | 7089977a24133b3b1dd0864f4138efe3b906af4b (diff) | |
download | qemu-5433af7697ba97531d97e16e721cfe8a90722198.zip qemu-5433af7697ba97531d97e16e721cfe8a90722198.tar.gz qemu-5433af7697ba97531d97e16e721cfe8a90722198.tar.bz2 |
watchdog: remove -watchdog option
This was deprecated in 6.2 and is ready to go. It removes quite a bit
of code that handled the registration of watchdog models.
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
Diffstat (limited to 'hw/watchdog/watchdog.c')
-rw-r--r-- | hw/watchdog/watchdog.c | 43 |
1 files changed, 0 insertions, 43 deletions
diff --git a/hw/watchdog/watchdog.c b/hw/watchdog/watchdog.c index 1437e6c..6c082a3 100644 --- a/hw/watchdog/watchdog.c +++ b/hw/watchdog/watchdog.c @@ -32,49 +32,6 @@ #include "qemu/help_option.h" static WatchdogAction watchdog_action = WATCHDOG_ACTION_RESET; -static QLIST_HEAD(, WatchdogTimerModel) watchdog_list; - -void watchdog_add_model(WatchdogTimerModel *model) -{ - QLIST_INSERT_HEAD(&watchdog_list, model, entry); -} - -/* Returns: - * 0 = continue - * 1 = exit program with error - * 2 = exit program without error - */ -int select_watchdog(const char *p) -{ - WatchdogTimerModel *model; - QemuOpts *opts; - - /* -watchdog ? lists available devices and exits cleanly. */ - if (is_help_option(p)) { - QLIST_FOREACH(model, &watchdog_list, entry) { - fprintf(stderr, "\t%s\t%s\n", - model->wdt_name, model->wdt_description); - } - return 2; - } - - QLIST_FOREACH(model, &watchdog_list, entry) { - if (strcasecmp(model->wdt_name, p) == 0) { - /* add the device */ - opts = qemu_opts_create(qemu_find_opts("device"), NULL, 0, - &error_abort); - qemu_opt_set(opts, "driver", p, &error_abort); - return 0; - } - } - - fprintf(stderr, "Unknown -watchdog device. Supported devices are:\n"); - QLIST_FOREACH(model, &watchdog_list, entry) { - fprintf(stderr, "\t%s\t%s\n", - model->wdt_name, model->wdt_description); - } - return 1; -} WatchdogAction get_watchdog_action(void) { |