[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <Z7T7r9VtuN78qhL6@mini-arch>
Date: Tue, 18 Feb 2025 13:29:19 -0800
From: Stanislav Fomichev <stfomichev@...il.com>
To: Jakub Kicinski <kuba@...nel.org>
Cc: davem@...emloft.net, netdev@...r.kernel.org, edumazet@...gle.com,
pabeni@...hat.com, andrew+netdev@...n.ch, horms@...nel.org,
shuah@...nel.org, hawk@...nel.org, petrm@...dia.com,
jdamato@...tly.com, willemdebruijn.kernel@...il.com
Subject: Re: [PATCH net-next 2/4] selftests: drv-net: add a way to wait for a
local process
On 02/18, Jakub Kicinski wrote:
> On Tue, 18 Feb 2025 13:10:14 -0800 Stanislav Fomichev wrote:
> > > + env_str = getenv("KSFT_READY_FD");
> > > + if (!env_str)
> > > + return;
> > > +
> > > + fd = atoi(env_str);
> > > + if (!fd)
> > > + return;
> >
> > optional nit: should these fail with error() instead of silent return?
> > Should guarantee that the caller is doing everything correctly.
> > (passing wait_init vs waiting for a port)
>
> My thinking was that you may want to run the helper manually during
> development and then the env variable won't be set.
>
> Given that we currently don't expose the stdout/stderr if wait fails
> adding a print seemed a little performative.. We need to go back
> and provide better support for debug (/verbose output) at some stage.
Good point. In this case, we can fail only on the first case (!env_str);
should still catch the wrong invocation and let you do KSFT_READY_FD= ./helper
manual run. But agreed, that not worth the respin..
Powered by blists - more mailing lists