Skip site navigation (1)Skip section navigation (2)
Date:      Thu, 16 Sep 2004 04:10:00 -0000
From:      Pyun YongHyeon <yongari@kt-is.co.kr>
To:        Max Laier <max@love2party.net>
Cc:        pf4freebsd@freelists.org
Subject:   [pf4freebsd] Re: Strange problem/Need help
Message-ID:  <20040726035005.GB677@kt-is.co.kr>
In-Reply-To: <200407260137.46024.max@love2party.net>
References:  <200407230602.34822.max@love2party.net> <20040723083119.GA3240@kt-is.co.kr> <200407260137.46024.max@love2party.net>

next in thread | previous in thread | raw e-mail | index | archive | help
On Mon, Jul 26, 2004 at 01:37:39AM +0200, Max Laier wrote:
...
 > > How about this? Instead of using hand-optimized code, it would be
 > > better to use system supplied one. This will work on icc too.
 > > I have to go out now. Please review the patch and let me know your
 > > opinions.(It wasn't tested at all.) This one can be used for a while.
 > > Personally, I really want to import NetBSD's approach.
 > 
 > I like it. I can recall that we talked about using in_cksum_skip when we frist 
 > did in4_cksum, but for some reason it wasn't useable then (iirc). Can your 
 > remember the complete story?
 > 

Well, I guess we talked on the possibility of NetBSD's in[46]_cksum
import. NetBSD has highly-optimized version of in[46]_cksum for
major architecures(i386, sparc64, arm etc).
ATM, FreeBSD don't have in4_cksum() and uses in_cksum() and its
variants. In addition, these functions on sparc64 are pure-C code and
IPv6 checksum computations are pure-C for all supported architectures.

However, this import will have substantial impact on many parts of
kernel networking codes and it needs rewriting of checksum validation
codes in tcp/udp. It's not easy and needs assembly language gurus
for each architectures. But if network gurus in FreeBSD agree with
this import, I guess at least we don't have problems on i386.
(Bruce Evans?)

 > Anyway, I ran this on my gateway for two days and it seems okay. I'd like to 
 > have a little more feedback before commiting, though. Please copy attached 
 > in4_cksum.c into src/sys/contrib/pf/netinet, build and run with it. If you 
 > have any shake out, please let me know.
 > 

Great. I never thought it would work well due to lack of compilation
chance.

 > Pyun, I assert the original OpenBSD in4_cksum.c copyright on this one. Are you 
 > okay with this solution?
 > 

Yes. We SHOULD include original copyright messages here.

Regards,
Pyun YongHyeon
-- 
Pyun YongHyeon <http://www.kr.freebsd.org/~yongari>;




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20040726035005.GB677>