tech-net archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

Re: PR/39203 CVS commit: src/sys/net



On Fri, Jul 25, 2008 at 09:01:29PM +0200, Martin Husemann wrote:
> On Fri, Jul 25, 2008 at 07:23:23PM +0200, Quentin Garnier wrote:
> > The NIC might have simply truncated it.  I'm pretty sure I've seen it
> > happen in that context, without specific notification to the driver.
> [..]
> > My initial implementation was smarter because it let the NIC driver
> > confirm it is able and willing to receive such frames.
> 
> Wouldn't it bet better to have the driver detect this (if possible) and
> not pass the frame to ether_input at all? If the hardware does not tell
> the driver, it should still know the maximum size and do this check
> better.

How can the driver tell if a frame was truncated or not, if the hardware
doesn't indicate it?  I'm pretty sure I saw it with sip(4), but it might
have been another.

> I don't see how the ethertype relates to this check - if at all the vlan
> or jumbo frame capabilities of the NIC should count.

It relates because the check is about whether or not the system *should*
have received such a packet, not whether or not it was able to (rather
obviously it was able to receive it).

That said, I'm all in favour of dropping the check completely.

-- 
Quentin Garnier - cube%cubidou.net@localhost - cube%NetBSD.org@localhost
"See the look on my face from staying too long in one place
[...] every time the morning breaks I know I'm closer to falling"
KT Tunstall, Saving My Face, Drastic Fantastic, 2007.

Attachment: pgpf1LoecHDfo.pgp
Description: PGP signature



Home | Main Index | Thread Index | Old Index