Hi Konstantin, On 02/18/2015 11:47 AM, Ananyev, Konstantin wrote: >>> How was this managed before, since refcnt field seems to be necessary in >>> order >>> to effectively manage indirect mbufs? Is this just the case that this is >>> something >>> that never worked and that needs to be solved, or is it something that was >>> working that this patch will now break? >> >> This is something that never worked before: refcounts are not compatible >> with reserving private data in mbufs. This patch does not change the >> issue, it is still there. >> >> Before the patch, an application that wanted to reserve a private >> data could disable refcounts at compile-time. >> After the patch, the solution is just to avoid using refcounts. > > I'd say avoid using mbuf_attach/detach. > refcnt itself has nothing to do with that. > I finally understood what you are talking about ... > About private data - I suppose it is a matter of another patch. > I still think it would be better to reserve private data space before mbuf, > not after > (at mbuf pool initialisation time). > Then *BADDR* macros could be unaffected.
Indeed that could be a good idea. Regards, Olivier