[prev in list] [next in list] [prev in thread] [next in thread] 

List:       netbsd-users
Subject:    Re: UDP Lite Support on NetBSD 6.0
From:       dave jones <s.dave.jones () gmail ! com>
Date:       2013-01-17 2:39:25
Message-ID: CANf5e8Y5aQc9RwPCXWaej0PZ5E46EBna0-xbAzDVdo3M2Hp4Og () mail ! gmail ! com
[Download RAW message or body]

On Tue, Jan 15, 2013 at 12:11 AM, Matt Thomas wrote:
> 
> On Jan 14, 2013, at 5:45 AM, Greg Troxel wrote:
> 
> > 
> > dave jones <s.dave.jones@gmail.com> writes:
> > 
> > > I'd work on it and learn NetBSD network internals, but it seems
> > > like there is a lot of duplicated code in order to implement UDP-Lite.
> > > For example, in udp_output(), to fill in mbuf with extended UDP-Lite header,
> > > I'd add the following code:
> > > 
> > > #ifdef UDPLITE
> > > ui->ui_pr = IPPROTO_UDPLITE;
> > > #else
> > > ui->ui_pr = IPPROTO_UDP;
> > > #endif
> > > 
> > > Is it a good idea? or any some suggestions? Thank you.
> > 
> > Adding support for UDP-Lite should not involve removing support for
> > UDP.
> 
> Indeed.  I have untested diffs for UDP-lite \
> (http://www.netbsd.org/~matt/udplite-diffs.txt) but realized that without \
> corresponding changes to all the network drivers, what's the point? 
> For UDPlite to be useful, the network drivers would need to stop discarding packets \
> with CRC errors and instead pass them up the stack.  We'd need a M_BADCRC flag to \
> tag packets with bad CRCs.  We also need code to identify packets as UDPlite.  Then \
> each common if_xxxsubr needs to test that flag and if set check for udplite, and if \
> not discard. 
> I thought about it and realized the additional overhead and complexity just wasn't \
> worth it so I stopped working on it.

Awesome! I tried to compile kernel with your diff. I got an error
while running a testing program:

udpliteclient: setsockopt(UDPLITE_SEND_CSCOV): Protocol option not available

Should I need to recompile libc as well or did I miss something? Thank you.

Regards,
Dave.


[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic