NetBSD/sys/netinet
dyoung 5493f188c7 KNF: de-__P, bzero -> memset, bcmp -> memcmp. Remove extraneous
parentheses in return statements.

Cosmetic: don't open-code TAILQ_FOREACH().

Cosmetic: change types of variables to avoid oodles of casts: in
   in6_src.c, avoid casts by changing several route_in6 pointers
   to struct route pointers.  Remove unnecessary casts to caddr_t
   elsewhere.

Pave the way for eliminating address family-specific route caches:
   soon, struct route will not embed a sockaddr, but it will hold
   a reference to an external sockaddr, instead.  We will set the
   destination sockaddr using rtcache_setdst().  (I created a stub
   for it, but it isn't used anywhere, yet.)  rtcache_free() will
   free the sockaddr.  I have extracted from rtcache_free() a helper
   subroutine, rtcache_clear().  rtcache_clear() will "forget" a
   cached route, but it will not forget the destination by releasing
   the sockaddr.  I use rtcache_clear() instead of rtcache_free()
   in rtcache_update(), because rtcache_update() is not supposed
   to forget the destination.

Constify:

   1 Introduce const accessor for route->ro_dst, rtcache_getdst().

   2 Constify the 'dst' argument to ifnet->if_output().  This
     led me to constify a lot of code called by output routines.

   3 Constify the sockaddr argument to protosw->pr_ctlinput.  This
     led me to constify a lot of code called by ctlinput routines.

   4 Introduce const macros for converting from a generic sockaddr
     to family-specific sockaddrs, e.g., sockaddr_in: satocsin6,
     satocsin, et cetera.
2007-02-17 22:34:07 +00:00
..
Makefile Here are various changes designed to protect against bad IPv4 2006-12-09 05:33:04 +00:00
files.ipfilter defflag IPFILTER_LOOKUP. 2006-09-17 13:43:15 +00:00
files.netinet Here are various changes designed to protect against bad IPv4 2006-12-09 05:33:04 +00:00
icmp6.h 'advertisment' -> 'advertisement', from leonardo chiquitto filho 2006-03-07 18:15:28 +00:00
icmp_var.h Multiple inclusion protection, as suggested by christos@ on tech-kern@ 2005-12-10 23:31:41 +00:00
if_arp.c KNF: de-__P, bzero -> memset, bcmp -> memcmp. Remove extraneous 2007-02-17 22:34:07 +00:00
if_atm.c KNF: de-__P, bzero -> memset, bcmp -> memcmp. Remove extraneous 2007-02-17 22:34:07 +00:00
if_atm.h KNF: de-__P, bzero -> memset, bcmp -> memcmp. Remove extraneous 2007-02-17 22:34:07 +00:00
if_ether.h typo. 2006-09-25 12:24:47 +00:00
if_inarp.h KNF: de-__P, bzero -> memset, bcmp -> memcmp. Remove extraneous 2007-02-17 22:34:07 +00:00
igmp.c Protect calls to pool_put/pool_get that may occur in interrupt context 2006-10-05 17:35:19 +00:00
igmp.h Multiple inclusion protection, as suggested by christos@ on tech-kern@ 2005-12-10 23:31:41 +00:00
igmp_var.h Multiple inclusion protection, as suggested by christos@ on tech-kern@ 2005-12-10 23:31:41 +00:00
in.c __unused removal on arguments; approved by core. 2006-11-16 01:32:37 +00:00
in.h KNF: de-__P, bzero -> memset, bcmp -> memcmp. Remove extraneous 2007-02-17 22:34:07 +00:00
in4_cksum.c merge ktrace-lwp. 2005-12-11 12:16:03 +00:00
in_cksum.c merge ktrace-lwp. 2005-12-11 12:16:03 +00:00
in_gif.c bzero -> memset 2007-02-17 05:31:39 +00:00
in_gif.h New EtherIP driver based on tap(4) and gif(4) by Hans Rosenfeld. 2006-11-23 04:07:07 +00:00
in_ifattach.h Add a source-address selection policy mechanism to the kernel. 2006-11-13 05:13:38 +00:00
in_offload.c move tso-by-software code to their own files. no functional changes. 2006-11-25 18:41:36 +00:00
in_offload.h move tso-by-software code to their own files. no functional changes. 2006-11-25 18:41:36 +00:00
in_pcb.c KNF: de-__P, bzero -> memset, bcmp -> memcmp. Remove extraneous 2007-02-17 22:34:07 +00:00
in_pcb.h Use the LWP cached credentials where sane. 2006-07-23 22:06:03 +00:00
in_pcb_hdr.h Multiple inclusion protection, as suggested by christos@ on tech-kern@ 2005-12-10 23:31:41 +00:00
in_proto.c Here are various changes designed to protect against bad IPv4 2006-12-09 05:33:04 +00:00
in_proto.h Multiple inclusion protection, as suggested by christos@ on tech-kern@ 2005-12-10 23:31:41 +00:00
in_route.c KNF: de-__P, bzero -> memset, bcmp -> memcmp. Remove extraneous 2007-02-17 22:34:07 +00:00
in_route.h Here are various changes designed to protect against bad IPv4 2006-12-09 05:33:04 +00:00
in_selsrc.c __unused removal on arguments; approved by core. 2006-11-16 01:32:37 +00:00
in_selsrc.h Add a source-address selection policy mechanism to the kernel. 2006-11-13 05:13:38 +00:00
in_systm.h Multiple inclusion protection, as suggested by christos@ on tech-kern@ 2005-12-10 23:31:41 +00:00
in_var.h Use the LWP cached credentials where sane. 2006-07-23 22:06:03 +00:00
ip.h According to ANSI c the only portably defined bitfields are unsigned int ones. 2006-12-17 20:07:36 +00:00
ip6.h Add support for RFC 3542 Adv. Socket API for IPv6 (which obsoletes 2292). 2006-05-05 00:03:21 +00:00
ip_carp.c KNF: de-__P, bzero -> memset, bcmp -> memcmp. Remove extraneous 2007-02-17 22:34:07 +00:00
ip_carp.h KNF: de-__P, bzero -> memset, bcmp -> memcmp. Remove extraneous 2007-02-17 22:34:07 +00:00
ip_ecn.c Import of TCP ECN algorithm for congestion control. 2006-09-05 00:29:35 +00:00
ip_ecn.h Multiple inclusion protection, as suggested by christos@ on tech-kern@ 2005-12-10 23:31:41 +00:00
ip_encap.c KNF: de-__P, bzero -> memset, bcmp -> memcmp. Remove extraneous 2007-02-17 22:34:07 +00:00
ip_encap.h KNF: de-__P, bzero -> memset, bcmp -> memcmp. Remove extraneous 2007-02-17 22:34:07 +00:00
ip_etherip.c KNF: de-__P, bzero -> memset, bcmp -> memcmp. Remove extraneous 2007-02-17 22:34:07 +00:00
ip_etherip.h New EtherIP driver based on tap(4) and gif(4) by Hans Rosenfeld. 2006-11-23 04:07:07 +00:00
ip_flow.c KNF: de-__P, bzero -> memset, bcmp -> memcmp. Remove extraneous 2007-02-17 22:34:07 +00:00
ip_gre.c Use LIST_FOREACH(). 2006-11-16 22:54:14 +00:00
ip_gre.h Multiple inclusion protection, as suggested by christos@ on tech-kern@ 2005-12-10 23:31:41 +00:00
ip_icmp.c KNF: de-__P, bzero -> memset, bcmp -> memcmp. Remove extraneous 2007-02-17 22:34:07 +00:00
ip_icmp.h Comment out attribute packed. Gcc4 warns us that the field is too narrow 2006-05-14 02:34:41 +00:00
ip_id.c static comes first 2006-08-30 18:54:19 +00:00
ip_input.c KNF: de-__P, bzero -> memset, bcmp -> memcmp. Remove extraneous 2007-02-17 22:34:07 +00:00
ip_mroute.c __unused removal on arguments; approved by core. 2006-11-16 01:32:37 +00:00
ip_mroute.h Multiple inclusion protection, as suggested by christos@ on tech-kern@ 2005-12-10 23:31:41 +00:00
ip_output.c KNF: de-__P, bzero -> memset, bcmp -> memcmp. Remove extraneous 2007-02-17 22:34:07 +00:00
ip_var.h KNF: de-__P, bzero -> memset, bcmp -> memcmp. Remove extraneous 2007-02-17 22:34:07 +00:00
pim.h Multiple inclusion protection, as suggested by christos@ on tech-kern@ 2005-12-10 23:31:41 +00:00
pim_var.h Multiple inclusion protection, as suggested by christos@ on tech-kern@ 2005-12-10 23:31:41 +00:00
raw_ip.c KNF: de-__P, bzero -> memset, bcmp -> memcmp. Remove extraneous 2007-02-17 22:34:07 +00:00
tcp.h Modular (I tried ;-) TCP congestion control API. Whenever certain conditions 2006-10-09 16:27:07 +00:00
tcp_congctl.c __unused removal on arguments; approved by core. 2006-11-16 01:32:37 +00:00
tcp_congctl.h constify. 2006-10-21 10:24:47 +00:00
tcp_debug.c merge ktrace-lwp. 2005-12-11 12:16:03 +00:00
tcp_debug.h Multiple inclusion protection, as suggested by christos@ on tech-kern@ 2005-12-10 23:31:41 +00:00
tcp_fsm.h Multiple inclusion protection, as suggested by christos@ on tech-kern@ 2005-12-10 23:31:41 +00:00
tcp_input.c Commit my SoC work 2007-02-10 09:43:05 +00:00
tcp_output.c Commit my SoC work 2007-02-10 09:43:05 +00:00
tcp_sack.c add sack_dump(), a function to dump sack holes, if defined(DDB). 2006-10-21 10:26:21 +00:00
tcp_seq.h Multiple inclusion protection, as suggested by christos@ on tech-kern@ 2005-12-10 23:31:41 +00:00
tcp_subr.c KNF: de-__P, bzero -> memset, bcmp -> memcmp. Remove extraneous 2007-02-17 22:34:07 +00:00
tcp_timer.c Modular (I tried ;-) TCP congestion control API. Whenever certain conditions 2006-10-09 16:27:07 +00:00
tcp_timer.h Fixed a bug in the timeout range constraint macro that can cause a timeout 2006-09-26 06:39:22 +00:00
tcp_usrreq.c add some more tcp mowners. 2006-12-06 09:10:45 +00:00
tcp_var.h KNF: de-__P, bzero -> memset, bcmp -> memcmp. Remove extraneous 2007-02-17 22:34:07 +00:00
tcpip.h Multiple inclusion protection, as suggested by christos@ on tech-kern@ 2005-12-10 23:31:41 +00:00
udp.h Multiple inclusion protection, as suggested by christos@ on tech-kern@ 2005-12-10 23:31:41 +00:00
udp_usrreq.c KNF: de-__P, bzero -> memset, bcmp -> memcmp. Remove extraneous 2007-02-17 22:34:07 +00:00
udp_var.h KNF: de-__P, bzero -> memset, bcmp -> memcmp. Remove extraneous 2007-02-17 22:34:07 +00:00