Re: [RFC net-next 01/15] psp: add documentation

Jakub Kicinski
2024-06-28T23:41:54Z

On Fri, 28 Jun 2024 15:33:28 -0400 Lance Richardson wrote:
> > Interesting. Hm. But SADB drivers would then have to implement some
> > complex logic to make sure all rings have cycled, or take references.
> > I'd rather have an opt-in for core to delay reaping old keys until
> > all sockets which used them went empty at least once (in wmem sense).
>
> Right, ensuring that the old entry is no longer referenced by packets in the
> transmit pipeline before removing is definitely a concern. One simple
> approach is to simply keep the old entry around for long enough (e.g. a
> minute or two) to ensure that any packets referencing it have been transmitted.

Sounds good, we can opportunistically remove immediately if socket is
idle, otherwise use a timeout. I'll try to have the patches on GH
before I post v1, it won't all fit in one reviewable series.