Date: Thu, 24 Feb 2005 10:44:18 +0000 (GMT) From: Robert Watson <rwatson@FreeBSD.org> To: Mike Silbersack <silby@FreeBSD.org> Cc: cvs-all@FreeBSD.org Subject: Re: cvs commit: src/sys/kern uipc_mbuf.c src/sys/sys mbuf.h Message-ID: <Pine.NEB.3.96L.1050224102854.95733H-100000@fledge.watson.org> In-Reply-To: <200303290548.h2T5ma5Q007596@repoman.freebsd.org>
next in thread | previous in thread | raw e-mail | index | archive | help
On Fri, 28 Mar 2003, Mike Silbersack wrote: > Add the m_defrag routine, as discussed on committers@. This > incarnation should address the concerns of all in the discussion, > and keeps statistics which show how much it is used. I just started tracking a bug report from Peter Holm in which if_rl free's an already free'd mbuf, and tracked it back to the following problem: when you went through and adapted various drivers to use m_defrag(), two bugs were introduced: (1) Callers of m_defrag() did not properly handle the case where m_defrag() would return a new mbuf cluster as the head. Specifically, on encapsulation failure, they might requeue the old head in the ifnet queue. (2) Callers of m_defrag() did not properly handle the case where m_defrag() would return NULL due to mbuf exhaustion. Specifically, on encapsulation failure in the case where m_defrag() fails, they might attempt to enqueue a NULL mbuf pointer or a free'd mbuf pointer into the ifnet queue. This may explain a number of problems seen with several device drivers when under very high load. It looks like if_vge, if_bfe, if_dc, if_re, if_rl, if_sis, if_vr, and if_xl may all be partially affected by these bugs. I may have missed other cases of breakage. It looks like you and jmg fixed a few at least partially, though. It would be really good if we could get this fixed for 5.4, and probably merged to the 5.3 patch branch! Robert N M Watson
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?Pine.NEB.3.96L.1050224102854.95733H-100000>