X-Git-Url: http://git.ozlabs.org/?p=petitboot;a=blobdiff_plain;f=ui%2Ftwin%2Fmain-generic.c;h=517422e4da9285ded2c1dfb8ec5d1d593bfd149a;hp=7cf510a44c2ebefebf485e3a6fb5f9f25bd5f158;hb=c25601a71b0951225691aa2edc389826f7f3836c;hpb=09cc1ef3d7e2c1dab6648aceb24dd33e7897f998 diff --git a/ui/twin/main-generic.c b/ui/twin/main-generic.c index 7cf510a..517422e 100644 --- a/ui/twin/main-generic.c +++ b/ui/twin/main-generic.c @@ -199,7 +199,7 @@ fail_menu: return NULL; } -static int kexec_cb(__attribute__((unused)) struct pbt_client *client, struct pb_opt_data *opt_data) +static int boot_cb(struct pbt_client *client, struct pb_opt_data *opt_data) { int result; @@ -207,7 +207,7 @@ static int kexec_cb(__attribute__((unused)) struct pbt_client *client, struct pb pb_log("%s: %s\n", __func__, opt_data->name); - result = pb_run_kexec(opt_data->kd); + result = pb_boot(opt_data->bd, client->dry_run); return result; } @@ -215,7 +215,7 @@ static int kexec_cb(__attribute__((unused)) struct pbt_client *client, struct pb static int run(struct pbt_client *client) { while (1) { - int result = waiter_poll(); + int result = waiter_poll(client->waitset); if (result < 0 && errno != EINTR) { pb_log("%s: poll: %s\n", __func__, strerror(errno)); @@ -330,8 +330,8 @@ int main(int argc, char *argv[]) return EXIT_FAILURE; } - client = pbt_client_init(opts.backend, 900, 300, kexec_cb, - opts.start_daemon); + client = pbt_client_init(opts.backend, 1024, 640, boot_cb, + opts.start_daemon, opts.dry_run); if (!client) { ui_result = EXIT_FAILURE;