Hi Simon, On Fri, 30 Aug 2024 at 03:59, Simon Glass <s...@chromium.org> wrote: > > Hi Jerome, > > On Thu, 29 Aug 2024 at 10:21, Jerome Forissier > <jerome.foriss...@linaro.org> wrote: > > > > > > > > On 8/29/24 16:05, Simon Glass wrote: > > > Hi Jerome, > > > > > > On Fri, 23 Aug 2024 at 07:50, Jerome Forissier > > > <jerome.foriss...@linaro.org> wrote: > > >> > > >> Enable NET_LWIP by default for testing purposes. SANDBOX doesn't support > > >> NET_LWIP so default to NET in this case. > > > > > > Sandbox needs to support NET_LWIP. > > > > I agree in principle, but AFAICT it is not a trivial task. Does it have to > > be done in this series or can it be dealt with later? > > Does it build OK with sandbox? We use it for almost all of our feature > development and testing, so I cannot imagine bringing this in if it > doesn't work. How did you develop this feature?
sandbox is deeply rooted into the old network stack. It fakes ACK responses, handles the ping request/replies with the sandbox ethernet driver etc. I was looking on adding LWIP support for it, but it's not trivial and I don't want us to add another hacky 'glue layer'. Since LWIP is a big feature on its own -- and is working on real hardware and QEMU, we discussed adding it, so people can test and contribute fixes while we fix sandbox. > > > > > I would need to look into this more closely to give details, but if I > > remember correctly the sandbox tests expect a precise sequence of network > > packets. For example when doing a TFTP tests, it expects an ARP packet to > > go out first, but when lwIP is used the ARP might not go out because the IP > > may already be in the cache. So the sandbox is definitely not a black box > > in that respect which makes things a bit more difficult. > > The key thing is to have a way to reset the state. So long as you have > that, you should be able to put networking back to the initial state > before running a test. Thanks /Ilias > > Regards, > Simon