Re: [PATCH 07/22] perf daemon: Add daemon command

From: Namhyung Kim
Date: Wed Jan 20 2021 - 23:58:07 EST


On Wed, Jan 20, 2021 at 3:31 AM Jiri Olsa <jolsa@xxxxxxxxxx> wrote:
>
> On Tue, Jan 19, 2021 at 01:08:17PM +0900, Namhyung Kim wrote:
> > > + /* Reconfig session. */
> > > + pr_debug2("reconfig: session '%s' start\n", session->name);
> > > + if (session->pid > 0) {
> > > + session__kill(session);
> > > + pr_info("reconfig: session '%s' killed\n", session->name);
> > > + }
> > > + if (session__run(session, daemon))
> >
> > Does it call a config function? Or is it called already?
>
> daemon__reconfig kills and starts sessions based
> on the config data read by setup_server_config
>
> >
> > > + return -1;
> > > + pr_debug2("reconfig: session '%s' done\n", session->name);
> > > + session->state = SESSION_STATE__OK;
> >
> > I think RUNNING is a better name.
>
> I'll check, I'll put the state graph in comment,
> so we can discuss the changes

Yeah, that would be helpful.

Thanks,
Namhyung