[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [PATCH 05/29] vl: split various early command line options to a sepa
|
From: |
Igor Mammedov |
|
Subject: |
Re: [PATCH 05/29] vl: split various early command line options to a separate function |
|
Date: |
Mon, 2 Nov 2020 16:30:22 +0100 |
On Tue, 27 Oct 2020 14:21:20 -0400
Paolo Bonzini <pbonzini@redhat.com> wrote:
> Various options affect the global state of QEMU including the rest of
> qemu_init, and they need to be called very early. Group them together
> in a function that is called at the beginning.
>
> Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
> ---
> softmmu/vl.c | 202 ++++++++++++++++++++++++++++-----------------------
> 1 file changed, 113 insertions(+), 89 deletions(-)
>
> diff --git a/softmmu/vl.c b/softmmu/vl.c
[...]
> +
> +static void qemu_maybe_daemonize(const char *pid_file)
why it's _maybe_ ?
It looks to me as just deamonize (or die which could be omitted)
> +{
> + Error *err;
> +
> + os_daemonize();
> + rcu_disable_atfork();
> +
> + if (pid_file && !qemu_write_pidfile(pid_file, &err)) {
> + error_reportf_err(err, "cannot create PID file: ");
> + exit(1);
> + }
> +
> + qemu_unlink_pidfile_notifier.notify = qemu_unlink_pidfile;
> + qemu_add_exit_notifier(&qemu_unlink_pidfile_notifier);
> +}
[...]
- Re: [PATCH 05/29] vl: split various early command line options to a separate function,
Igor Mammedov <=