Home | History | Annotate | Download | only in netinet6
History log of /src/sys/netinet6/in6_cksum.c
RevisionDateAuthorComments
 1.28  25-Apr-2011  yamt fix assertions
 1.27  10-Mar-2008  yamt branches: 1.27.26; 1.27.32;
in6_cksum: use IN6_IS_SCOPE_EMBEDDABLE.
 1.26  10-Mar-2008  yamt in6_cksum: avoid using -> operator and use (char *) arithmetics instead.
reviewed by Joerg Sonnenberger. he pointed out that the original code
was written that way so that the compiler will explicitly not assume that
the alignment of the data is correct. although i don't know if it really
matters or not, being safer is not a problem.
 1.25  09-Mar-2008  yamt in6_cksum: constify
 1.24  12-Feb-2008  joerg branches: 1.24.2; 1.24.6;
Explicitly predict panic conditions as false.
 1.23  12-Feb-2008  joerg Provide a simplified inplace version of in6_cksum.
Tested by is@ on amd64.
 1.22  25-Jan-2008  joerg Refactor in_cksum/in4_cksum/in6_cksum implementations:
- All three functions are included in the kernel by default.
They call a backend function cpu_in_cksum after possibly
computing the checksum of the pseudo header.
- cpu_in_cksum is the core to implement the one-complement sum.
The default implementation is moderate fast on most platforms
and provides a 32bit accumulator with 16bit addends for L32 platforms
and a 64bit accumulator with 32bit addends for L64 platforms.
It handles edge cases like very large mbuf chains (could happen with
native IPv6 in the future) and provides a good base for new native
implementations.
- Modify i386 and amd64 assembly to use the new interface.

This disables the MD implementations on !x86 until the conversion is
done. For Alpha, the portable version is faster.
 1.21  25-Dec-2007  perry Convert many of the uses of __attribute__ to equivalent
__packed, __unused and __dead macros from cdefs.h
 1.20  23-May-2007  christos branches: 1.20.8; 1.20.14; 1.20.16; 1.20.20;
Ansify + add a few comments, from Karl Sjödahl
 1.19  27-Jan-2006  rpaulo branches: 1.19.28; 1.19.30;
PR 32653: mrt@notwork.org: remove 'sum += w[0]' left in previous revision.
 1.18  21-Jan-2006  rpaulo Better support of IPv6 scoped addresses.

- most of the kernel code will not care about the actual encoding of
scope zone IDs and won't touch "s6_addr16[1]" directly.
- similarly, most of the kernel code will not care about link-local
scoped addresses as a special case.
- scope boundary check will be stricter. For example, the current
*BSD code allows a packet with src=::1 and dst=(some global IPv6
address) to be sent outside of the node, if the application do:
s = socket(AF_INET6);
bind(s, "::1");
sendto(s, some_global_IPv6_addr);
This is clearly wrong, since ::1 is only meaningful within a single
node, but the current implementation of the *BSD kernel cannot
reject this attempt.
- and, while there, don't try to remove the ff02::/32 interface route
entry in in6_ifdetach() as it's already gone.

This also includes some level of support for the standard source
address selection algorithm defined in RFC3484, which will be
completed on in the future.

From the KAME project via JINMEI Tatuya.
Approved by core@.
 1.17  11-Dec-2005  christos branches: 1.17.2;
merge ktrace-lwp.
 1.16  07-Aug-2003  agc branches: 1.16.16;
Move UCB-licensed code from 4-clause to 3-clause licence.

Patches provided by Joel Baker in PR 22364, verified by myself.
 1.15  18-Jul-2003  itojun remove #if 0 portion
 1.14  27-Sep-2002  provos branches: 1.14.6;
remove trailing \n in panic(). approved perry.
 1.13  09-Jun-2002  itojun whitespace cleanup
 1.12  13-Nov-2001  lukem branches: 1.12.8;
add RCSIDs
 1.11  30-May-2001  thorpej branches: 1.11.2;
Skip the pseudo-header if nxt == 0. This is already documented
in in6_cksum(9) and is also the behavior of the i386 optimized
version.
 1.10  10-Feb-2001  itojun branches: 1.10.2;
to sync with kame better, (1) remove register declaration for variables,
(2) sync whitespaces, (3) update comments. (4) bring in some of portability
and logging enhancements. no functional changes here.
 1.9  09-Sep-2000  itojun move file static variable into auto variable, for better thread safety.
(not really required for big lock MP). sync with kame
 1.8  09-Sep-2000  itojun add attribute(packed).
From: Alfred Perlstein <bright@wintelcom.net>
 1.7  06-Feb-2000  itojun fix include pathname for better rfc2292 compliance.
 1.6  13-Dec-1999  itojun sync IPv6 part with latest KAME tree. IPsec part is left unmodified
due to massive changes in KAME side.
- IPv6 output goes through nd6_output
- faith can capture IPv4 packets as well - you can run IPv4-to-IPv6 translator
using heavily modified DNS servers
- per-interface statistics (required for IPv6 MIB)
- interface autoconfig is revisited
- udp input handling has a big change for mapped address support.
- introduce in4_cksum() for non-overwriting checksumming
- introduce m_pulldown()
- neighbor discovery cleanups/improvements
- netinet/in.h strictly conforms to RFC2553 (no extra defs visible to userland)
- IFA_STATS is fixed a bit (not tested)
- and more more more.

TODO:
- cleanup os-independency #ifdef
- avoid rcvif dual use (for IPsec) to help ifdetach

(sorry for jumbo commit, I can't separate this any more...)
 1.5  11-Jul-1999  itojun branches: 1.5.2; 1.5.8;
fix compilation/runtime problem on alpha.

PR: 7952, 7953
From: Dave Huang <khym@bga.com>
 1.4  06-Jul-1999  itojun checked build on alpha and i386, with GENERIC.v6.
fixed several sizeof(void *) and sizeof(size_t) issues on alpha.

Thanks to: Dave Huang and Tim Rightnour
 1.3  03-Jul-1999  thorpej RCS ID police.
 1.2  01-Jul-1999  itojun branches: 1.2.2;
IPv6 kernel code, based on KAME/NetBSD 1.4, SNAP kit 19990628.
(Sorry for a big commit, I can't separate this into several pieces...)
Pls check sys/netinet6/TODO and sys/netinet6/IMPLEMENTATION for details.

- sys/kern: do not assume single mbuf, accept chained mbuf on passing
data from userland to kernel (or other way round).
- "midway" ATM card: ATM PVC pseudo device support, like those done in ALTQ
package (ftp://ftp.csl.sony.co.jp/pub/kjc/).
- sys/netinet/tcp*: IPv4/v6 dual stack tcp support.
- sys/netinet/{ip6,icmp6}.h, sys/net/pfkeyv2.h: IETF document assumes those
file to be there so we patch it up.
- sys/netinet: IPsec additions are here and there.
- sys/netinet6/*: most of IPv6 code sits here.
- sys/netkey: IPsec key management code
- dev/pci/pcidevs: regen

In my understanding no code here is subject to export control so it
should be safe.
 1.1  28-Jun-1999  itojun branches: 1.1.2;
file in6_cksum.c was initially added on branch kame.
 1.1.2.2  30-Nov-1999  itojun bring in latest KAME (as of 19991130, KAME/NetBSD141) into kame branch
just for reference purposes.
This commit includes 1.4 -> 1.4.1 sync for kame branch.

The branch does not compile at all (due to the lack of ALTQ and some other
source code). Please do not try to modify the branch, this is just for
referenre purposes.

synchronization to latest KAME will take place on HEAD branch soon.
 1.1.2.1  28-Jun-1999  itojun KAME/NetBSD 1.4 SNAP kit, dated 19990628.

NOTE: this branch (kame) is used just for refernce. this may not compile
due to multiple reasons.
 1.2.2.3  02-Aug-1999  thorpej Update from trunk.
 1.2.2.2  01-Jul-1999  thorpej Sync w/ -current.
 1.2.2.1  01-Jul-1999  thorpej file in6_cksum.c was added on branch chs-ubc2 on 1999-07-01 23:48:27 +0000
 1.5.8.1  27-Dec-1999  wrstuden Pull up to last week's -current.
 1.5.2.2  11-Feb-2001  bouyer Sync with HEAD.
 1.5.2.1  20-Nov-2000  bouyer Update thorpej_scsipi to -current as of a month ago
 1.10.2.4  18-Oct-2002  nathanw Catch up to -current.
 1.10.2.3  20-Jun-2002  nathanw Catch up to -current.
 1.10.2.2  14-Nov-2001  nathanw Catch up to -current.
 1.10.2.1  21-Jun-2001  nathanw Catch up to -current.
 1.11.2.3  10-Oct-2002  jdolecek sync kqueue with -current; this includes merge of gehenna-devsw branch,
merge of i386 MP branch, and part of autoconf rototil work
 1.11.2.2  23-Jun-2002  jdolecek catch up with -current on kqueue branch
 1.11.2.1  10-Jan-2002  thorpej Sync kqueue branch with -current.
 1.12.8.1  20-Jun-2002  gehenna catch up with -current.
 1.14.6.3  21-Sep-2004  skrll Fix the sync with head I botched.
 1.14.6.2  18-Sep-2004  skrll Sync with HEAD.
 1.14.6.1  03-Aug-2004  skrll Sync with HEAD
 1.16.16.6  17-Mar-2008  yamt sync with head.
 1.16.16.5  27-Feb-2008  yamt sync with head.
 1.16.16.4  04-Feb-2008  yamt sync with head.
 1.16.16.3  21-Jan-2008  yamt sync with head
 1.16.16.2  03-Sep-2007  yamt sync with head.
 1.16.16.1  21-Jun-2006  yamt sync with head.
 1.17.2.1  01-Feb-2006  yamt sync with head.
 1.19.30.1  11-Jul-2007  mjf Sync with head.
 1.19.28.1  08-Jun-2007  ad Sync with head.
 1.20.20.1  02-Jan-2008  bouyer Sync with HEAD
 1.20.16.1  26-Dec-2007  ad Sync with head.
 1.20.14.1  18-Feb-2008  mjf Sync with HEAD.
 1.20.8.2  23-Mar-2008  matt sync with HEAD
 1.20.8.1  09-Jan-2008  matt sync with HEAD
 1.24.6.1  03-Apr-2008  mjf Sync with HEAD.
 1.24.2.1  24-Mar-2008  keiichi sync with head.
 1.27.32.1  06-Jun-2011  jruoho Sync with HEAD.
 1.27.26.1  31-May-2011  rmind sync with head

RSS XML Feed