Calling m_pullup in ether_input
Gleb Smirnoff
glebius at freebsd.org
Fri Oct 8 13:34:37 PDT 2004
On Fri, Oct 08, 2004 at 06:15:15PM +0300, Giorgos Keramidas wrote:
G> In ether_input() we unconditionaly discard the mbufs whose m_len is less than
G> ETHER_HDR_LEN. A bit higher M_PKTHDR has been checked but the check made
G> before discarding the frame doesn't pay attention to the m->m_pkthdr.len (the
G> total packet length).
In my humble opinion, all Ethernet device drivers are intentionally written
in such a way that they always pass an mbuf with contigous Ethernet header
to ether_input().
Why did you write this patch? Do you really have packet loss?
G> I am trying to find out how often this happens, by using the attached patch to
G> count the number of small frames received in ether_input() and the number of
G> failed m_pullup() attempts that result from that.
And what results do you have?
G> Does this change seem reasonable as an instrumentation of the particular
G> problem or am I unknowingly breaking something in the way ether_input() is
G> supposed to work?
AFAIK, this patch does not break anything but just adds more processing.
--
Totus tuus, Glebius.
GLEBIUS-RIPN GLEB-RIPE
More information about the freebsd-net
mailing list