The NetBSD Project

CVS log for src/sys/netinet/igmp.c

[BACK] Up to [cvs.NetBSD.org] / src / sys / netinet

Request diff between arbitrary revisions


Default branch: MAIN


Revision 1.64.6.3 / (download) - annotate - [select for diffs], Mon May 25 17:48:16 2020 UTC (3 years, 10 months ago) by martin
Branch: netbsd-8
Changes since 1.64.6.2: +3 -2 lines
Diff to previous 1.64.6.2 (colored) to branchpoint 1.64 (colored) next main 1.65 (colored) to selected 1.64 (colored)

Pull up following revision(s) (requested by christos in ticket #1549):

	sys/netinet/igmp.c: revision 1.70
	sys/kern/kern_time.c: revision 1.204

igmp_sendpkt() expects ip_output() to set 'imo.imo_multicast_ttl' into
'ip->ip_ttl'; but ip_output() won't if the target is not a multicast
address, meaning that the uninitialized 'ip->ip_ttl' byte gets sent to
the network. This leaks one byte of kernel heap.

Fix this by filling 'ip->ip_ttl' with a TTL of one.
Found by KMSAN.

 -

Fix uninitialized memory access. Found by KMSAN.

Revision 1.69.4.1 / (download) - annotate - [select for diffs], Mon May 18 18:59:39 2020 UTC (3 years, 10 months ago) by martin
Branch: netbsd-9
CVS Tags: netbsd-9-3-RELEASE, netbsd-9-2-RELEASE, netbsd-9-1-RELEASE
Changes since 1.69: +3 -2 lines
Diff to previous 1.69 (colored) next main 1.70 (colored) to selected 1.64 (colored)

Pull up following revision(s) (requested by maxv in ticket #915):

	sys/netinet/igmp.c: revision 1.70

igmp_sendpkt() expects ip_output() to set 'imo.imo_multicast_ttl' into
'ip->ip_ttl'; but ip_output() won't if the target is not a multicast
address, meaning that the uninitialized 'ip->ip_ttl' byte gets sent to
the network. This leaks one byte of kernel heap.

Fix this by filling 'ip->ip_ttl' with a TTL of one.

Found by KMSAN.

Revision 1.70 / (download) - annotate - [select for diffs], Fri May 15 06:34:34 2020 UTC (3 years, 10 months ago) by maxv
Branch: MAIN
CVS Tags: thorpej-ifq-base, thorpej-ifq, thorpej-i2c-spi-conf2-base, thorpej-i2c-spi-conf2, thorpej-i2c-spi-conf-base, thorpej-i2c-spi-conf, thorpej-futex2-base, thorpej-futex2, thorpej-futex-base, thorpej-futex, thorpej-cfargs2-base, thorpej-cfargs2, thorpej-cfargs-base, thorpej-cfargs, thorpej-altq-separation-base, thorpej-altq-separation, netbsd-10-base, netbsd-10-0-RELEASE, netbsd-10-0-RC6, netbsd-10-0-RC5, netbsd-10-0-RC4, netbsd-10-0-RC3, netbsd-10-0-RC2, netbsd-10-0-RC1, netbsd-10, cjep_sun2x-base1, cjep_sun2x-base, cjep_sun2x, cjep_staticlib_x-base1, cjep_staticlib_x-base, cjep_staticlib_x, bouyer-sunxi-drm-base, bouyer-sunxi-drm, HEAD
Changes since 1.69: +3 -2 lines
Diff to previous 1.69 (colored) to selected 1.64 (colored)

igmp_sendpkt() expects ip_output() to set 'imo.imo_multicast_ttl' into
'ip->ip_ttl'; but ip_output() won't if the target is not a multicast
address, meaning that the uninitialized 'ip->ip_ttl' byte gets sent to
the network. This leaks one byte of kernel heap.

Fix this by filling 'ip->ip_ttl' with a TTL of one.

Found by KMSAN.

Reported-by: syzbot+e49f7b8a8fec5a477c9a@syzkaller.appspotmail.com

Revision 1.68.2.1 / (download) - annotate - [select for diffs], Mon Jun 10 22:09:47 2019 UTC (4 years, 9 months ago) by christos
Branch: phil-wifi
Changes since 1.68: +5 -9 lines
Diff to previous 1.68 (colored) next main 1.69 (colored) to selected 1.64 (colored)

Sync with HEAD

Revision 1.66.2.3 / (download) - annotate - [select for diffs], Sun Sep 30 01:45:56 2018 UTC (5 years, 5 months ago) by pgoyette
Branch: pgoyette-compat
CVS Tags: pgoyette-compat-merge-20190127
Changes since 1.66.2.2: +5 -9 lines
Diff to previous 1.66.2.2 (colored) to branchpoint 1.66 (colored) next main 1.67 (colored) to selected 1.64 (colored)

Ssync with HEAD

Revision 1.69 / (download) - annotate - [select for diffs], Fri Sep 14 05:09:51 2018 UTC (5 years, 6 months ago) by maxv
Branch: MAIN
CVS Tags: phil-wifi-20200421, phil-wifi-20200411, phil-wifi-20200406, phil-wifi-20191119, phil-wifi-20190609, pgoyette-compat-20190127, pgoyette-compat-20190118, pgoyette-compat-1226, pgoyette-compat-1126, pgoyette-compat-1020, pgoyette-compat-0930, netbsd-9-base, netbsd-9-0-RELEASE, netbsd-9-0-RC2, netbsd-9-0-RC1, isaki-audio2-base, isaki-audio2, is-mlppp-base, is-mlppp, bouyer-xenpvh-base2, bouyer-xenpvh-base1, bouyer-xenpvh-base, bouyer-xenpvh, ad-namecache-base3, ad-namecache-base2, ad-namecache-base1, ad-namecache-base, ad-namecache
Branch point for: netbsd-9
Changes since 1.68: +5 -9 lines
Diff to previous 1.68 (colored) to selected 1.64 (colored)

Use non-variadic function pointer in protosw::pr_input.

Revision 1.64.6.2 / (download) - annotate - [select for diffs], Fri Jul 13 14:26:47 2018 UTC (5 years, 8 months ago) by martin
Branch: netbsd-8
CVS Tags: netbsd-8-2-RELEASE, netbsd-8-1-RELEASE, netbsd-8-1-RC1, netbsd-8-0-RELEASE
Changes since 1.64.6.1: +7 -2 lines
Diff to previous 1.64.6.1 (colored) to branchpoint 1.64 (colored) to selected 1.64 (colored)

Pull up following revision(s) via patch (requested by knakahara in ticket #905):

	sys/netinet/ip_mroute.c: revision 1.160
	sys/netinet6/in6_l2tp.c: revision 1.16
	sys/net/if.h: revision 1.263
	sys/netinet/in_l2tp.c: revision 1.15
	sys/netinet/ip_icmp.c: revision 1.172
	sys/netinet/igmp.c: revision 1.68
	sys/netinet/ip_encap.c: revision 1.69
	sys/netinet6/ip6_mroute.c: revision 1.129

sbappendaddr() is required any lock. Currently, softnet_lock is appropriate.

When rip_input() is called as inetsw[].pr_input, rip_iput() is always called
with holding softnet_lock, that is, in case of !defined(NET_MPSAFE) it is
acquired in ipintr(), otherwise(defined(NET_MPSAFE)) it is acquire in
PR_WRAP_INPUT macro.

However, some function calls rip_input() directly without holding softnet_lock.
That causes assertion failure in sbappendaddr().
rip6_input() and icmp6_rip6_input() are also required softnet_lock for the same
reason.

Revision 1.66.2.2 / (download) - annotate - [select for diffs], Mon Jun 25 07:26:06 2018 UTC (5 years, 9 months ago) by pgoyette
Branch: pgoyette-compat
Changes since 1.66.2.1: +7 -2 lines
Diff to previous 1.66.2.1 (colored) to branchpoint 1.66 (colored) to selected 1.64 (colored)

Sync with HEAD

Revision 1.68 / (download) - annotate - [select for diffs], Thu Jun 21 10:37:50 2018 UTC (5 years, 9 months ago) by knakahara
Branch: MAIN
CVS Tags: phil-wifi-base, pgoyette-compat-0906, pgoyette-compat-0728, pgoyette-compat-0625
Branch point for: phil-wifi
Changes since 1.67: +7 -2 lines
Diff to previous 1.67 (colored) to selected 1.64 (colored)

sbappendaddr() is required any lock. Currently, softnet_lock is appropriate.

When rip_input() is called as inetsw[].pr_input, rip_iput() is always called
with holding softnet_lock, that is, in case of !defined(NET_MPSAFE) it is
acquired in ipintr(), otherwise(defined(NET_MPSAFE)) it is acquire in
PR_WRAP_INPUT macro.
However, some function calls rip_input() directly without holding softnet_lock.
That causes assertion failure in sbappendaddr().
rip6_input() and icmp6_rip6_input() are also required softnet_lock for the same
reason.

Revision 1.66.2.1 / (download) - annotate - [select for diffs], Mon Apr 16 02:00:08 2018 UTC (5 years, 11 months ago) by pgoyette
Branch: pgoyette-compat
Changes since 1.66: +3 -6 lines
Diff to previous 1.66 (colored) to selected 1.64 (colored)

Sync with HEAD, resolve some conflicts

Revision 1.67 / (download) - annotate - [select for diffs], Tue Apr 10 08:22:35 2018 UTC (5 years, 11 months ago) by maxv
Branch: MAIN
CVS Tags: pgoyette-compat-0521, pgoyette-compat-0502, pgoyette-compat-0422, pgoyette-compat-0415
Changes since 1.66: +3 -6 lines
Diff to previous 1.66 (colored) to selected 1.64 (colored)

Replace comment by KASSERT.

Revision 1.66 / (download) - annotate - [select for diffs], Wed Feb 7 11:42:58 2018 UTC (6 years, 1 month ago) by maxv
Branch: MAIN
CVS Tags: pgoyette-compat-base, pgoyette-compat-0407, pgoyette-compat-0330, pgoyette-compat-0322, pgoyette-compat-0315
Branch point for: pgoyette-compat
Changes since 1.65: +3 -5 lines
Diff to previous 1.65 (colored) to selected 1.64 (colored)

Remove RSVP_ISI, that's mostly dead code. FreeBSD and OpenBSD too removed
it; FreeBSD kept some pieces but they are mostly no-opts.

Sent on tech-net@, no comment.

Revision 1.64.6.1 / (download) - annotate - [select for diffs], Tue Jan 2 10:20:34 2018 UTC (6 years, 2 months ago) by snj
Branch: netbsd-8
CVS Tags: netbsd-8-0-RC2, netbsd-8-0-RC1
Changes since 1.64: +4 -8 lines
Diff to previous 1.64 (colored)

Pull up following revision(s) (requested by ozaki-r in ticket #456):
	sys/arch/arm/sunxi/sunxi_emac.c: 1.9
	sys/dev/ic/dwc_gmac.c: 1.43-1.44
	sys/dev/pci/if_iwm.c: 1.75
	sys/dev/pci/if_wm.c: 1.543
	sys/dev/pci/ixgbe/ixgbe.c: 1.112
	sys/dev/pci/ixgbe/ixv.c: 1.74
	sys/kern/sys_socket.c: 1.75
	sys/net/agr/if_agr.c: 1.43
	sys/net/bpf.c: 1.219
	sys/net/if.c: 1.397, 1.399, 1.401-1.403, 1.406-1.410, 1.412-1.416
	sys/net/if.h: 1.242-1.247, 1.250, 1.252-1.257
	sys/net/if_bridge.c: 1.140 via patch, 1.142-1.146
	sys/net/if_etherip.c: 1.40
	sys/net/if_ethersubr.c: 1.243, 1.246
	sys/net/if_faith.c: 1.57
	sys/net/if_gif.c: 1.132
	sys/net/if_l2tp.c: 1.15, 1.17
	sys/net/if_loop.c: 1.98-1.101
	sys/net/if_media.c: 1.35
	sys/net/if_pppoe.c: 1.131-1.132
	sys/net/if_spppsubr.c: 1.176-1.177
	sys/net/if_tun.c: 1.142
	sys/net/if_vlan.c: 1.107, 1.109, 1.114-1.121
	sys/net/npf/npf_ifaddr.c: 1.3
	sys/net/npf/npf_os.c: 1.8-1.9
	sys/net/rtsock.c: 1.230
	sys/netcan/if_canloop.c: 1.3-1.5
	sys/netinet/if_arp.c: 1.255
	sys/netinet/igmp.c: 1.65
	sys/netinet/in.c: 1.210-1.211
	sys/netinet/in_pcb.c: 1.180
	sys/netinet/ip_carp.c: 1.92, 1.94
	sys/netinet/ip_flow.c: 1.81
	sys/netinet/ip_input.c: 1.362
	sys/netinet/ip_mroute.c: 1.147
	sys/netinet/ip_output.c: 1.283, 1.285, 1.287
	sys/netinet6/frag6.c: 1.61
	sys/netinet6/in6.c: 1.251, 1.255
	sys/netinet6/in6_pcb.c: 1.162
	sys/netinet6/ip6_flow.c: 1.35
	sys/netinet6/ip6_input.c: 1.183
	sys/netinet6/ip6_output.c: 1.196
	sys/netinet6/mld6.c: 1.90
	sys/netinet6/nd6.c: 1.239-1.240
	sys/netinet6/nd6_nbr.c: 1.139
	sys/netinet6/nd6_rtr.c: 1.136
	sys/netipsec/ipsec_output.c: 1.65
	sys/rump/net/lib/libnetinet/netinet_component.c: 1.9-1.10
kmem_intr_free kmem_intr_[z]alloced memory
the underlying pools are the same but api-wise those should match
Unify IFEF_*_MPSAFE into IFEF_MPSAFE
There are already two flags for if_output and if_start, however, it seems such
MPSAFE flags are eventually needed for all if_XXX operations. Having discrete
flags for each operation is wasteful of if_extflags bits. So let's unify
the flags into one: IFEF_MPSAFE.
Fortunately IFEF_*_MPSAFE flags have never been included in any releases, so
we can change them without breaking backward compatibility of the releases
(though the kernel version of -current should be bumped).
Note that if an interface have both MP-safe and non-MP-safe operations at a
time, we have to set the IFEF_MPSAFE flag and let callees of non-MP-safe
opeartions take the kernel lock.
Proposed on tech-kern@ and tech-net@
Provide macros for softnet_lock and KERNEL_LOCK hiding NET_MPSAFE switch
It reduces C&P codes such as "#ifndef NET_MPSAFE KERNEL_LOCK(1, NULL); ..."
scattered all over the source code and makes it easy to identify remaining
KERNEL_LOCK and/or softnet_lock that are held even if NET_MPSAFE.
No functional change
Hold KERNEL_LOCK on if_ioctl selectively based on IFEF_MPSAFE
If IFEF_MPSAFE is set, hold the lock and otherwise don't hold.
This change requires additions of KERNEL_LOCK to subsequence functions from
if_ioctl such as ifmedia_ioctl and ifioctl_common to protect non-MP-safe
components.
Proposed on tech-kern@ and tech-net@
Ensure to hold if_ioctl_lock when calling if_flags_set
Fix locking against myself on ifpromisc
vlan_unconfig_locked could be called with holding if_ioctl_lock.
Ensure to not turn on IFF_RUNNING of an interface until its initialization completes
And ensure to turn off it before destruction as per IFF_RUNNING's description
"resource allocated". (The description is a bit doubtful though, I believe the
change is still proper.)
Ensure to hold if_ioctl_lock on if_up and if_down
One exception for if_down is if_detach; in the case the lock isn't needed
because it's guaranteed that no other one can access ifp at that point.
Make if_link_queue MP-safe if IFEF_MPSAFE
if_link_queue is a queue to store events of link state changes, which is
used to pass events from (typically) an interrupt handler to
if_link_state_change softint. The queue was protected by KERNEL_LOCK so far,
but if IFEF_MPSAFE is enabled, it becomes unsafe because (perhaps) an interrupt
handler of an interface with IFEF_MPSAFE doesn't take KERNEL_LOCK. Protect it
by a spin mutex.
Additionally with this change KERNEL_LOCK of if_link_state_change softint is
omitted if NET_MPSAFE is enabled.
Note that the spin mutex is now ifp->if_snd.ifq_lock as well as the case of
if_timer (see the comment).
Use IFADDR_WRITER_FOREACH instead of IFADDR_READER_FOREACH
At that point no other one modifies the list so IFADDR_READER_FOREACH
is unnecessary. Use of IFADDR_READER_FOREACH is harmless in general though,
if we try to detect contract violations of pserialize, using it violates
the contract. So avoid using it makes life easy.
Ensure to call if_addr_init with holding if_ioctl_lock
Get rid of outdated comments
Fix build of kernels without ether
By throwing out if_enable_vlan_mtu and if_disable_vlan_mtu that
created a unnecessary dependency from if.c to if_ethersubr.c.
PR kern/52790
Rename IFNET_LOCK to IFNET_GLOBAL_LOCK
IFNET_LOCK will be used in another lock, if_ioctl_lock (might be renamed then).
Wrap if_ioctl_lock with IFNET_* macros (NFC)
Also if_ioctl_lock perhaps needs to be renamed to something because it's now
not just for ioctl...
Reorder some destruction routines in if_detach
- Destroy if_ioctl_lock at the end of the if_detach because it's used in various
  destruction routines
- Move psref_target_destroy after pr_purgeif because we want to use psref in
  pr_purgeif (otherwise destruction procedures can be tricky)
Ensure to call if_mcast_op with holding IFNET_LOCK
Note that CARP doesn't deal with IFNET_LOCK yet.
Remove IFNET_GLOBAL_LOCK where it's unnecessary because IFNET_LOCK is held
Describe which lock is used to protect each member variable of struct ifnet
Requested by skrll@
Write a guideline for converting an interface to IFEF_MPSAFE
Requested by skrll@
Note that IFNET_LOCK must not be held in softint
Don't set IFEF_MPSAFE unless NET_MPSAFE at this point
Because recent investigations show that interfaces with IFEF_MPSAFE need to
follow additional restrictions to work with the flag safely. We should enable it
on an interface by default only if the interface surely satisfies the
restrictions, which are described in if.h.
Note that enabling IFEF_MPSAFE solely gains a few benefit on performance because
the network stack is still serialized by the big kernel locks by default.

Revision 1.53.6.2 / (download) - annotate - [select for diffs], Sun Dec 3 11:39:03 2017 UTC (6 years, 3 months ago) by jdolecek
Branch: tls-maxphys
Changes since 1.53.6.1: +40 -21 lines
Diff to previous 1.53.6.1 (colored) to branchpoint 1.53 (colored) next main 1.54 (colored) to selected 1.64 (colored)

update from HEAD

Revision 1.65 / (download) - annotate - [select for diffs], Fri Nov 17 07:37:12 2017 UTC (6 years, 4 months ago) by ozaki-r
Branch: MAIN
CVS Tags: tls-maxphys-base-20171202
Changes since 1.64: +4 -8 lines
Diff to previous 1.64 (colored)

Provide macros for softnet_lock and KERNEL_LOCK hiding NET_MPSAFE switch

It reduces C&P codes such as "#ifndef NET_MPSAFE KERNEL_LOCK(1, NULL); ..."
scattered all over the source code and makes it easy to identify remaining
KERNEL_LOCK and/or softnet_lock that are held even if NET_MPSAFE.

No functional change

Revision 1.63.2.1 / (download) - annotate - [select for diffs], Fri Apr 21 16:54:05 2017 UTC (6 years, 11 months ago) by bouyer
Branch: bouyer-socketcan
Changes since 1.63: +9 -2 lines
Diff to previous 1.63 (colored) next main 1.64 (colored)

Sync with HEAD

Revision 1.61.2.2 / (download) - annotate - [select for diffs], Mon Mar 20 06:57:50 2017 UTC (7 years ago) by pgoyette
Branch: pgoyette-localcount
Changes since 1.61.2.1: +9 -3 lines
Diff to previous 1.61.2.1 (colored) to branchpoint 1.61 (colored) next main 1.62 (colored) to selected 1.64 (colored)

Sync with HEAD

Revision 1.55.4.5 / (download) - annotate - [select for diffs], Sun Feb 5 13:40:59 2017 UTC (7 years, 1 month ago) by skrll
Branch: nick-nhusb
Changes since 1.55.4.4: +9 -3 lines
Diff to previous 1.55.4.4 (colored) to branchpoint 1.55 (colored) next main 1.56 (colored) to selected 1.64 (colored)

Sync with HEAD

Revision 1.64 / (download) - annotate - [selected], Tue Jan 24 07:09:24 2017 UTC (7 years, 2 months ago) by ozaki-r
Branch: MAIN
CVS Tags: prg-localcount2-base3, prg-localcount2-base2, prg-localcount2-base1, prg-localcount2-base, prg-localcount2, pgoyette-localcount-20170426, pgoyette-localcount-20170320, perseant-stdc-iso10646-base, perseant-stdc-iso10646, nick-nhusb-base-20170825, nick-nhusb-base-20170204, netbsd-8-base, matt-nb8-mediatek-base, matt-nb8-mediatek, jdolecek-ncq-base, jdolecek-ncq, bouyer-socketcan-base1
Branch point for: netbsd-8
Changes since 1.63: +9 -2 lines
Diff to previous 1.63 (colored)

Tweak softnet_lock and NET_MPSAFE

- Don't hold softnet_lock in some functions if NET_MPSAFE
- Add softnet_lock to sysctl_net_inet_icmp_redirtimeout
- Add softnet_lock to expire_upcalls of ip_mroute.c
- Restore softnet_lock for in{,6}_pcbpurgeif{,0} if NET_MPSAFE
- Mark some softnet_lock for future work

Revision 1.63 / (download) - annotate - [select for diffs], Wed Jan 11 13:08:29 2017 UTC (7 years, 2 months ago) by ozaki-r
Branch: MAIN
CVS Tags: bouyer-socketcan-base
Branch point for: bouyer-socketcan
Changes since 1.62: +2 -3 lines
Diff to previous 1.62 (colored) to selected 1.64 (colored)

Get rid of unnecessary header inclusions

Revision 1.55.4.4 / (download) - annotate - [select for diffs], Wed Oct 5 20:56:09 2016 UTC (7 years, 5 months ago) by skrll
Branch: nick-nhusb
Changes since 1.55.4.3: +18 -9 lines
Diff to previous 1.55.4.3 (colored) to branchpoint 1.55 (colored) to selected 1.64 (colored)

Sync with HEAD

Revision 1.61.2.1 / (download) - annotate - [select for diffs], Sat Aug 6 00:19:10 2016 UTC (7 years, 7 months ago) by pgoyette
Branch: pgoyette-localcount
Changes since 1.61: +18 -9 lines
Diff to previous 1.61 (colored) to selected 1.64 (colored)

Sync with HEAD

Revision 1.62 / (download) - annotate - [select for diffs], Mon Aug 1 03:15:30 2016 UTC (7 years, 7 months ago) by ozaki-r
Branch: MAIN
CVS Tags: pgoyette-localcount-20170107, pgoyette-localcount-20161104, pgoyette-localcount-20160806, nick-nhusb-base-20161204, nick-nhusb-base-20161004, localcount-20160914
Changes since 1.61: +18 -9 lines
Diff to previous 1.61 (colored) to selected 1.64 (colored)

Apply pserialize and psref to struct ifaddr and its variants

This change makes struct ifaddr and its variants (in_ifaddr and in6_ifaddr)
MP-safe by using pserialize and psref. At this moment, pserialize_perform
and psref_target_destroy are disabled because (1) we don't need them
because of softnet_lock (2) they cause a deadlock because of softnet_lock.
So we'll enable them when we remove softnet_lock in the future.

Revision 1.55.4.3 / (download) - annotate - [select for diffs], Sat Jul 9 20:25:22 2016 UTC (7 years, 8 months ago) by skrll
Branch: nick-nhusb
Changes since 1.55.4.2: +22 -15 lines
Diff to previous 1.55.4.2 (colored) to branchpoint 1.55 (colored) to selected 1.64 (colored)

Sync with HEAD

Revision 1.61 / (download) - annotate - [select for diffs], Fri Jul 8 04:33:30 2016 UTC (7 years, 8 months ago) by ozaki-r
Branch: MAIN
CVS Tags: pgoyette-localcount-base, pgoyette-localcount-20160726, nick-nhusb-base-20160907
Branch point for: pgoyette-localcount
Changes since 1.60: +5 -5 lines
Diff to previous 1.60 (colored) to selected 1.64 (colored)

Replace macros to get an IP address with proper inline functions

The inline functions are more friendly for applying psz/psref;
they consist of only simple interations.

Revision 1.60 / (download) - annotate - [select for diffs], Tue Jun 28 02:02:56 2016 UTC (7 years, 9 months ago) by ozaki-r
Branch: MAIN
Changes since 1.59: +5 -2 lines
Diff to previous 1.59 (colored) to selected 1.64 (colored)

Add missing NULL checks for m_get_rcvif_psref

Revision 1.59 / (download) - annotate - [select for diffs], Tue Jun 21 03:28:27 2016 UTC (7 years, 9 months ago) by ozaki-r
Branch: MAIN
Changes since 1.58: +3 -3 lines
Diff to previous 1.58 (colored) to selected 1.64 (colored)

Replace ifp of ip_moptions and ip6_moptions with if_index

The motivation is the same as the mbuf's rcvif case; avoid having a pointer
of an ifnet object in ip_moptions and ip6_moptions, which is not MP-safe.

ip_moptions and ip6_moptions can be stored in a PCB for inet or inet6
that's life time is different from ifnet one and so an ifnet object can be
disappeared anytime we get it via them. Thus we need to look up an ifnet
object by if_index every time for safe.

Revision 1.58 / (download) - annotate - [select for diffs], Fri Jun 10 13:31:44 2016 UTC (7 years, 9 months ago) by ozaki-r
Branch: MAIN
Changes since 1.57: +15 -11 lines
Diff to previous 1.57 (colored) to selected 1.64 (colored)

Avoid storing a pointer of an interface in a mbuf

Having a pointer of an interface in a mbuf isn't safe if we remove big
kernel locks; an interface object (ifnet) can be destroyed anytime in any
packet processing and accessing such object via a pointer is racy. Instead
we have to get an object from the interface collection (ifindex2ifnet) via
an interface index (if_index) that is stored to a mbuf instead of an
pointer.

The change provides two APIs: m_{get,put}_rcvif_psref that use psref(9)
for sleep-able critical sections and m_{get,put}_rcvif that use
pserialize(9) for other critical sections. The change also adds another
API called m_get_rcvif_NOMPSAFE, that is NOT MP-safe and for transition
moratorium, i.e., it is intended to be used for places where are not
planned to be MP-ified soon.

The change adds some overhead due to psref to performance sensitive paths,
however the overhead is not serious, 2% down at worst.

Proposed on tech-kern and tech-net.

Revision 1.55.4.2 / (download) - annotate - [select for diffs], Sun May 29 08:44:38 2016 UTC (7 years, 10 months ago) by skrll
Branch: nick-nhusb
Changes since 1.55.4.1: +2 -3 lines
Diff to previous 1.55.4.1 (colored) to branchpoint 1.55 (colored) to selected 1.64 (colored)

Sync with HEAD

Revision 1.57 / (download) - annotate - [select for diffs], Tue Apr 26 08:44:44 2016 UTC (7 years, 11 months ago) by ozaki-r
Branch: MAIN
CVS Tags: nick-nhusb-base-20160529
Changes since 1.56: +2 -3 lines
Diff to previous 1.56 (colored) to selected 1.64 (colored)

Sweep unnecessary route.h inclusions

Revision 1.55.4.1 / (download) - annotate - [select for diffs], Tue Sep 22 12:06:11 2015 UTC (8 years, 6 months ago) by skrll
Branch: nick-nhusb
Changes since 1.55: +4 -2 lines
Diff to previous 1.55 (colored) to selected 1.64 (colored)

Sync with HEAD

Revision 1.56 / (download) - annotate - [select for diffs], Mon Aug 24 22:21:26 2015 UTC (8 years, 7 months ago) by pooka
Branch: MAIN
CVS Tags: nick-nhusb-base-20160422, nick-nhusb-base-20160319, nick-nhusb-base-20151226, nick-nhusb-base-20150921
Changes since 1.55: +4 -2 lines
Diff to previous 1.55 (colored) to selected 1.64 (colored)

sprinkle _KERNEL_OPT

Revision 1.53.6.1 / (download) - annotate - [select for diffs], Wed Aug 20 00:04:35 2014 UTC (9 years, 7 months ago) by tls
Branch: tls-maxphys
Changes since 1.53: +136 -100 lines
Diff to previous 1.53 (colored) to selected 1.64 (colored)

Rebase to HEAD as of a few days ago.

Revision 1.54.2.1 / (download) - annotate - [select for diffs], Sun Aug 10 06:56:25 2014 UTC (9 years, 7 months ago) by tls
Branch: tls-earlyentropy
Changes since 1.54: +136 -95 lines
Diff to previous 1.54 (colored) next main 1.55 (colored) to selected 1.64 (colored)

Rebase.

Revision 1.55 / (download) - annotate - [select for diffs], Thu May 29 23:02:48 2014 UTC (9 years, 10 months ago) by rmind
Branch: MAIN
CVS Tags: tls-maxphys-base, tls-earlyentropy-base, nick-nhusb-base-20150606, nick-nhusb-base-20150406, nick-nhusb-base, netbsd-7-nhusb-base-20170116, netbsd-7-nhusb-base, netbsd-7-nhusb, netbsd-7-base, netbsd-7-2-RELEASE, netbsd-7-1-RELEASE, netbsd-7-1-RC2, netbsd-7-1-RC1, netbsd-7-1-2-RELEASE, netbsd-7-1-1-RELEASE, netbsd-7-1, netbsd-7-0-RELEASE, netbsd-7-0-RC3, netbsd-7-0-RC2, netbsd-7-0-RC1, netbsd-7-0-2-RELEASE, netbsd-7-0-1-RELEASE, netbsd-7-0, netbsd-7
Branch point for: nick-nhusb
Changes since 1.54: +136 -95 lines
Diff to previous 1.54 (colored) to selected 1.64 (colored)

Make IGMP and multicast group management code MP-safe.  Use a read-write
lock to protect the hash table of multicast address records; also, make it
private and eliminate some macros.  In the long term, the lookup path ought
to be optimised.

Revision 1.52.2.2 / (download) - annotate - [select for diffs], Thu May 22 11:41:09 2014 UTC (9 years, 10 months ago) by yamt
Branch: yamt-pagecache
Changes since 1.52.2.1: +2 -7 lines
Diff to previous 1.52.2.1 (colored) to branchpoint 1.52 (colored) next main 1.53 (colored) to selected 1.64 (colored)

sync with head.

for a reference, the tree before this commit was tagged
as yamt-pagecache-tag8.

this commit was splitted into small chunks to avoid
a limitation of cvs.  ("Protocol error: too many arguments")

Revision 1.53.10.1 / (download) - annotate - [select for diffs], Sun May 18 17:46:13 2014 UTC (9 years, 10 months ago) by rmind
Branch: rmind-smpnet
Changes since 1.53: +2 -7 lines
Diff to previous 1.53 (colored) next main 1.54 (colored) to selected 1.64 (colored)

sync with head

Revision 1.54 / (download) - annotate - [select for diffs], Tue Feb 25 18:30:12 2014 UTC (10 years, 1 month ago) by pooka
Branch: MAIN
CVS Tags: yamt-pagecache-base9, rmind-smpnet-nbase, rmind-smpnet-base, riastradh-xf86-video-intel-2-7-1-pre-2-21-15, riastradh-drm2-base3
Branch point for: tls-earlyentropy
Changes since 1.53: +2 -7 lines
Diff to previous 1.53 (colored) to selected 1.64 (colored)

Ensure that the top level sysctl nodes (kern, vfs, net, ...) exist before
the sysctl link sets are processed, and remove redundancy.

Shaves >13kB off of an amd64 GENERIC, not to mention >1k duplicate
lines of code.

Revision 1.52.2.1 / (download) - annotate - [select for diffs], Tue Apr 17 00:08:40 2012 UTC (11 years, 11 months ago) by yamt
Branch: yamt-pagecache
CVS Tags: yamt-pagecache-tag8
Changes since 1.52: +3 -3 lines
Diff to previous 1.52 (colored) to selected 1.64 (colored)

sync with head

Revision 1.52.6.1 / (download) - annotate - [select for diffs], Sat Feb 18 07:35:39 2012 UTC (12 years, 1 month ago) by mrg
Branch: jmcneill-usbmp
Changes since 1.52: +3 -3 lines
Diff to previous 1.52 (colored) next main 1.53 (colored) to selected 1.64 (colored)

merge to -current.

Revision 1.53 / (download) - annotate - [select for diffs], Mon Jan 9 14:31:21 2012 UTC (12 years, 2 months ago) by liamjfoy
Branch: MAIN
CVS Tags: yamt-pagecache-base8, yamt-pagecache-base7, yamt-pagecache-base6, yamt-pagecache-base5, yamt-pagecache-base4, riastradh-drm2-base2, riastradh-drm2-base1, riastradh-drm2-base, riastradh-drm2, netbsd-6-base, netbsd-6-1-RELEASE, netbsd-6-1-RC4, netbsd-6-1-RC3, netbsd-6-1-RC2, netbsd-6-1-RC1, netbsd-6-1-5-RELEASE, netbsd-6-1-4-RELEASE, netbsd-6-1-3-RELEASE, netbsd-6-1-2-RELEASE, netbsd-6-1-1-RELEASE, netbsd-6-1, netbsd-6-0-RELEASE, netbsd-6-0-RC2, netbsd-6-0-RC1, netbsd-6-0-6-RELEASE, netbsd-6-0-5-RELEASE, netbsd-6-0-4-RELEASE, netbsd-6-0-3-RELEASE, netbsd-6-0-2-RELEASE, netbsd-6-0-1-RELEASE, netbsd-6-0, netbsd-6, matt-nb6-plus-nbase, matt-nb6-plus-base, matt-nb6-plus, khorben-n900, jmcneill-usbmp-base9, jmcneill-usbmp-base8, jmcneill-usbmp-base7, jmcneill-usbmp-base6, jmcneill-usbmp-base5, jmcneill-usbmp-base4, jmcneill-usbmp-base3, jmcneill-usbmp-base2, jmcneill-usbmp-base10, agc-symver-base, agc-symver
Branch point for: tls-maxphys, rmind-smpnet
Changes since 1.52: +3 -3 lines
Diff to previous 1.52 (colored) to selected 1.64 (colored)

check against NULL

Revision 1.52 / (download) - annotate - [select for diffs], Sun Jul 17 20:54:53 2011 UTC (12 years, 8 months ago) by joerg
Branch: MAIN
CVS Tags: yamt-pagecache-base3, yamt-pagecache-base2, yamt-pagecache-base, jmcneill-usbmp-pre-base2, jmcneill-usbmp-base, jmcneill-audiomp3-base, jmcneill-audiomp3
Branch point for: yamt-pagecache, jmcneill-usbmp
Changes since 1.51: +2 -4 lines
Diff to previous 1.51 (colored) to selected 1.64 (colored)

Retire varargs.h support. Move machine/stdarg.h logic into MI
sys/stdarg.h and expect compiler to provide proper builtins, defaulting
to the GCC interface. lint still has a special fallback.
Reduce abuse of _BSD_VA_LIST_ by defining __va_list by default and
derive va_list as required by standards.

Revision 1.48.2.3 / (download) - annotate - [select for diffs], Thu Mar 11 15:04:28 2010 UTC (14 years ago) by yamt
Branch: yamt-nfs-mp
Changes since 1.48.2.2: +7 -3 lines
Diff to previous 1.48.2.2 (colored) to branchpoint 1.48 (colored) next main 1.49 (colored) to selected 1.64 (colored)

sync with head

Revision 1.51 / (download) - annotate - [select for diffs], Wed Sep 16 15:23:04 2009 UTC (14 years, 6 months ago) by pooka
Branch: MAIN
CVS Tags: yamt-nfs-mp-base9, yamt-nfs-mp-base11, yamt-nfs-mp-base10, uebayasi-xip-base4, uebayasi-xip-base3, uebayasi-xip-base2, uebayasi-xip-base1, uebayasi-xip-base, uebayasi-xip, rmind-uvmplock-nbase, rmind-uvmplock-base, rmind-uvmplock, matt-premerge-20091211, matt-mips64-premerge-20101231, jym-xensuspend-nbase, jruoho-x86intr-base, jruoho-x86intr, cherry-xenmp-base, cherry-xenmp, bouyer-quota2-nbase, bouyer-quota2-base, bouyer-quota2
Changes since 1.50: +7 -3 lines
Diff to previous 1.50 (colored) to selected 1.64 (colored)

Replace a large number of link set based sysctl node creations with
calls from subsystem constructors.  Benefits both future kernel
modules and rump.

no change to sysctl nodes on i386/MONOLITHIC & build tested i386/ALL

Revision 1.48.2.2 / (download) - annotate - [select for diffs], Wed Sep 16 13:38:02 2009 UTC (14 years, 6 months ago) by yamt
Branch: yamt-nfs-mp
Changes since 1.48.2.1: +5 -4 lines
Diff to previous 1.48.2.1 (colored) to branchpoint 1.48 (colored) to selected 1.64 (colored)

sync with head

Revision 1.50 / (download) - annotate - [select for diffs], Sun Sep 13 18:45:11 2009 UTC (14 years, 6 months ago) by pooka
Branch: MAIN
CVS Tags: yamt-nfs-mp-base8
Changes since 1.49: +5 -4 lines
Diff to previous 1.49 (colored) to selected 1.64 (colored)

Wipe out the last vestiges of POOL_INIT with one swift stroke.  In
most cases, use a proper constructor.  For proplib, give a local
equivalent of POOL_INIT for the kernel object implementation.  This
way the code structure can be preserved, and a local link set is
not hazardous anyway (unless proplib is split to several modules,
but that'll be the day).

tested by booting a kernel in qemu and compile-testing i386/ALL

Revision 1.45.28.1 / (download) - annotate - [select for diffs], Mon Jun 2 13:24:24 2008 UTC (15 years, 9 months ago) by mjf
Branch: mjf-devfs2
Changes since 1.45: +76 -23 lines
Diff to previous 1.45 (colored) next main 1.46 (colored) to selected 1.64 (colored)

Sync with HEAD.

Revision 1.46.2.1 / (download) - annotate - [select for diffs], Sun May 18 12:35:28 2008 UTC (15 years, 10 months ago) by yamt
Branch: yamt-pf42
Changes since 1.46: +16 -41 lines
Diff to previous 1.46 (colored) next main 1.47 (colored) to selected 1.64 (colored)

sync with head.

Revision 1.48.2.1 / (download) - annotate - [select for diffs], Fri May 16 02:25:41 2008 UTC (15 years, 10 months ago) by yamt
Branch: yamt-nfs-mp
Changes since 1.48: +3 -8 lines
Diff to previous 1.48 (colored) to selected 1.64 (colored)

sync with head.

Revision 1.49 / (download) - annotate - [select for diffs], Sun May 4 07:22:14 2008 UTC (15 years, 10 months ago) by thorpej
Branch: MAIN
CVS Tags: yamt-pf42-base4, yamt-pf42-base3, yamt-pf42-base2, yamt-nfs-mp-base7, yamt-nfs-mp-base6, yamt-nfs-mp-base5, yamt-nfs-mp-base4, yamt-nfs-mp-base3, yamt-nfs-mp-base2, wrstuden-revivesa-base-4, wrstuden-revivesa-base-3, wrstuden-revivesa-base-2, wrstuden-revivesa-base-1, wrstuden-revivesa-base, wrstuden-revivesa, simonb-wapbl-nbase, simonb-wapbl-base, simonb-wapbl, nick-hppapmap-base4, nick-hppapmap-base3, nick-hppapmap-base2, nick-hppapmap-base, nick-hppapmap, netbsd-5-base, netbsd-5-2-RELEASE, netbsd-5-2-RC1, netbsd-5-2-3-RELEASE, netbsd-5-2-2-RELEASE, netbsd-5-2-1-RELEASE, netbsd-5-2, netbsd-5-1-RELEASE, netbsd-5-1-RC4, netbsd-5-1-RC3, netbsd-5-1-RC2, netbsd-5-1-RC1, netbsd-5-1-5-RELEASE, netbsd-5-1-4-RELEASE, netbsd-5-1-3-RELEASE, netbsd-5-1-2-RELEASE, netbsd-5-1-1-RELEASE, netbsd-5-1, netbsd-5-0-RELEASE, netbsd-5-0-RC4, netbsd-5-0-RC3, netbsd-5-0-RC2, netbsd-5-0-RC1, netbsd-5-0-2-RELEASE, netbsd-5-0-1-RELEASE, netbsd-5-0, netbsd-5, mjf-devfs2-base, matt-nb5-pq3-base, matt-nb5-pq3, matt-nb5-mips64-u2-k2-k4-k7-k8-k9, matt-nb5-mips64-u1-k1-k5, matt-nb5-mips64-premerge-20101231, matt-nb5-mips64-premerge-20091211, matt-nb5-mips64-k15, matt-nb5-mips64, matt-nb4-mips64-k7-u2a-k9b, matt-mips64-base2, jymxensuspend-base, jym-xensuspend-base, jym-xensuspend, hpcarm-cleanup-nbase, haad-nbase2, haad-dm-base2, haad-dm-base1, haad-dm-base, haad-dm, ad-audiomp2-base, ad-audiomp2
Changes since 1.48: +3 -8 lines
Diff to previous 1.48 (colored) to selected 1.64 (colored)

Simplify the interface to netstat_sysctl() and allocate space for
the collated counters using kmem_alloc().

PR kern/38577

Revision 1.48 / (download) - annotate - [select for diffs], Thu Apr 24 11:38:37 2008 UTC (15 years, 11 months ago) by ad
Branch: MAIN
CVS Tags: yamt-nfs-mp-base
Branch point for: yamt-nfs-mp
Changes since 1.47: +13 -8 lines
Diff to previous 1.47 (colored) to selected 1.64 (colored)

Merge the socket locking patch:

- Socket layer becomes MP safe.
- Unix protocols become MP safe.
- Allows protocol processing interrupts to safely block on locks.
- Fixes a number of race conditions.

With much feedback from matt@ and plunky@.

Revision 1.47 / (download) - annotate - [select for diffs], Wed Apr 23 05:26:50 2008 UTC (15 years, 11 months ago) by thorpej
Branch: MAIN
Changes since 1.46: +9 -34 lines
Diff to previous 1.46 (colored) to selected 1.64 (colored)

Use <net/net_stats.h> / netstat_sysctl().

Revision 1.46 / (download) - annotate - [select for diffs], Tue Apr 15 16:02:03 2008 UTC (15 years, 11 months ago) by thorpej
Branch: MAIN
CVS Tags: yamt-pf42-baseX, yamt-pf42-base
Branch point for: yamt-pf42
Changes since 1.45: +95 -17 lines
Diff to previous 1.45 (colored) to selected 1.64 (colored)

Make IGMP stats per-cpu.

Revision 1.41.6.2 / (download) - annotate - [select for diffs], Mon Sep 3 14:42:46 2007 UTC (16 years, 6 months ago) by yamt
Branch: yamt-lazymbuf
Changes since 1.41.6.1: +5 -5 lines
Diff to previous 1.41.6.1 (colored) to branchpoint 1.41 (colored) next main 1.42 (colored) to selected 1.64 (colored)

sync with head.

Revision 1.44.2.1 / (download) - annotate - [select for diffs], Wed Jul 11 20:11:17 2007 UTC (16 years, 8 months ago) by mjf
Branch: mjf-ufs-trans
Changes since 1.44: +3 -4 lines
Diff to previous 1.44 (colored) next main 1.45 (colored) to selected 1.64 (colored)

Sync with head.

Revision 1.43.8.2 / (download) - annotate - [select for diffs], Fri Jun 8 14:17:43 2007 UTC (16 years, 9 months ago) by ad
Branch: vmlocking
Changes since 1.43.8.1: +3 -4 lines
Diff to previous 1.43.8.1 (colored) to branchpoint 1.43 (colored) next main 1.44 (colored) to selected 1.64 (colored)

Sync with head.

Revision 1.43.4.2 / (download) - annotate - [select for diffs], Mon May 7 10:55:57 2007 UTC (16 years, 10 months ago) by yamt
Branch: yamt-idlelwp
Changes since 1.43.4.1: +3 -4 lines
Diff to previous 1.43.4.1 (colored) to branchpoint 1.43 (colored) next main 1.44 (colored) to selected 1.64 (colored)

sync with head.

Revision 1.45 / (download) - annotate - [select for diffs], Wed Apr 25 00:11:18 2007 UTC (16 years, 11 months ago) by dyoung
Branch: MAIN
CVS Tags: yamt-x86pmap-base4, yamt-x86pmap-base3, yamt-x86pmap-base2, yamt-x86pmap-base, yamt-x86pmap, yamt-lazymbuf-base15, yamt-lazymbuf-base14, yamt-kmem-base3, yamt-kmem-base2, yamt-kmem-base, yamt-kmem, yamt-idlelwp-base8, vmlocking2-base3, vmlocking2-base2, vmlocking2-base1, vmlocking2, vmlocking-nbase, vmlocking-base, reinoud-bufcleanup-nbase, reinoud-bufcleanup-base, nick-net80211-sync-base, nick-net80211-sync, nick-csl-alignment-base5, nick-csl-alignment-base, nick-csl-alignment, mjf-ufs-trans-base, mjf-devfs-base, mjf-devfs, matt-mips64-base, matt-mips64, matt-armv6-prevmlocking, matt-armv6-nbase, matt-armv6-base, matt-armv6, keiichi-mipv6-nbase, keiichi-mipv6-base, keiichi-mipv6, jmcneill-pm-base, jmcneill-pm, jmcneill-base, hpcarm-cleanup-base, hpcarm-cleanup, cube-autoconf-base, cube-autoconf, bouyer-xeni386-nbase, bouyer-xeni386-merge1, bouyer-xeni386-base, bouyer-xeni386, bouyer-xenamd64-base2, bouyer-xenamd64-base, bouyer-xenamd64, ad-socklock-base1
Branch point for: mjf-devfs2
Changes since 1.44: +3 -4 lines
Diff to previous 1.44 (colored) to selected 1.64 (colored)

Get rid of some gratuitous casts and join some lines.

Revision 1.43.4.1 / (download) - annotate - [select for diffs], Sat Mar 24 14:56:10 2007 UTC (17 years ago) by yamt
Branch: yamt-idlelwp
Changes since 1.43: +4 -3 lines
Diff to previous 1.43 (colored) to selected 1.64 (colored)

sync with head.

Revision 1.43.8.1 / (download) - annotate - [select for diffs], Tue Mar 13 16:52:01 2007 UTC (17 years ago) by ad
Branch: vmlocking
Changes since 1.43: +4 -3 lines
Diff to previous 1.43 (colored) to selected 1.64 (colored)

Sync with head.

Revision 1.44 / (download) - annotate - [select for diffs], Mon Mar 12 18:18:35 2007 UTC (17 years ago) by ad
Branch: MAIN
CVS Tags: thorpej-atomic-base, thorpej-atomic, reinoud-bufcleanup
Branch point for: mjf-ufs-trans
Changes since 1.43: +4 -3 lines
Diff to previous 1.43 (colored) to selected 1.64 (colored)

Pass an ipl argument to pool_init/POOL_INIT to be used when initializing
the pool's lock.

Revision 1.41.6.1 / (download) - annotate - [select for diffs], Sat Dec 30 20:50:33 2006 UTC (17 years, 3 months ago) by yamt
Branch: yamt-lazymbuf
Changes since 1.41: +11 -7 lines
Diff to previous 1.41 (colored) to selected 1.64 (colored)

sync with head.

Revision 1.42.20.1 / (download) - annotate - [select for diffs], Sat Nov 18 21:39:36 2006 UTC (17 years, 4 months ago) by ad
Branch: newlock2
Changes since 1.42: +11 -7 lines
Diff to previous 1.42 (colored) next main 1.43 (colored) to selected 1.64 (colored)

Sync with head.

Revision 1.42.22.1 / (download) - annotate - [select for diffs], Sun Oct 22 06:07:28 2006 UTC (17 years, 5 months ago) by yamt
Branch: yamt-splraiseipl
Changes since 1.42: +11 -7 lines
Diff to previous 1.42 (colored) next main 1.43 (colored) to selected 1.64 (colored)

sync with head

Revision 1.43 / (download) - annotate - [select for diffs], Thu Oct 5 17:35:19 2006 UTC (17 years, 5 months ago) by tls
Branch: MAIN
CVS Tags: yamt-splraiseipl-base5, yamt-splraiseipl-base4, yamt-splraiseipl-base3, yamt-splraiseipl-base2, wrstuden-fixsa-newbase, wrstuden-fixsa-base-1, wrstuden-fixsa-base, wrstuden-fixsa, post-newlock2-merge, newlock2-nbase, newlock2-base, netbsd-4-base, netbsd-4-0-RELEASE, netbsd-4-0-RC5, netbsd-4-0-RC4, netbsd-4-0-RC3, netbsd-4-0-RC2, netbsd-4-0-RC1, netbsd-4-0-1-RELEASE, netbsd-4-0, netbsd-4, matt-nb4-arm-base, matt-nb4-arm, ad-audiomp-base, ad-audiomp
Branch point for: yamt-idlelwp, vmlocking
Changes since 1.42: +11 -7 lines
Diff to previous 1.42 (colored) to selected 1.64 (colored)

Protect calls to pool_put/pool_get that may occur in interrupt context
with spl used to protect other allocations and frees, or datastructure
element insertion and removal, in adjacent code.

It is almost unquestionably the case that some of the spl()/splx() calls
added here are superfluous, but it really seems wrong to see:

	s=splfoo();
	/* frob data structure */
	splx(s);
	pool_put(x);

and if we think we need to protect the first operation, then it is hard
to see why we should not think we need to protect the next.  "Better
safe than sorry".

It is also almost unquestionably the case that I missed some pool
gets/puts from interrupt context with my strategy for finding these
calls; use of PR_NOWAIT is a strong hint that a pool may be used from
interrupt context but many callers in the kernel pass a "can wait/can't
wait" flag down such that my searches might not have found them.  One
notable area that needs to be looked at is pf.

See also:

http://mail-index.netbsd.org/tech-kern/2006/07/19/0003.html
http://mail-index.netbsd.org/tech-kern/2006/07/19/0009.html

Revision 1.42 / (download) - annotate - [select for diffs], Sun Dec 11 12:24:57 2005 UTC (18 years, 3 months ago) by christos
Branch: MAIN
CVS Tags: yamt-uio_vmspace-base5, yamt-uio_vmspace, yamt-splraiseipl-base, yamt-pdpolicy-base9, yamt-pdpolicy-base8, yamt-pdpolicy-base7, yamt-pdpolicy-base6, yamt-pdpolicy-base5, yamt-pdpolicy-base4, yamt-pdpolicy-base3, yamt-pdpolicy-base2, yamt-pdpolicy-base, yamt-pdpolicy, simonb-timecounters-base, simonb-timecounters, simonb-timcounters-final, rpaulo-netinet-merge-pcb-base, rpaulo-netinet-merge-pcb, peter-altq-base, peter-altq, gdamore-uart-base, gdamore-uart, elad-kernelauth-base, elad-kernelauth, chap-midi-nbase, chap-midi-base, chap-midi, abandoned-netbsd-4-base, abandoned-netbsd-4
Branch point for: yamt-splraiseipl, newlock2
Changes since 1.41: +2 -2 lines
Diff to previous 1.41 (colored) to selected 1.64 (colored)

merge ktrace-lwp.

Revision 1.39.4.1 / (download) - annotate - [select for diffs], Fri Apr 29 11:29:33 2005 UTC (18 years, 11 months ago) by kent
Branch: kent-audio2
Changes since 1.39: +14 -22 lines
Diff to previous 1.39 (colored) next main 1.40 (colored) to selected 1.64 (colored)

sync with -current

Revision 1.39.6.1 / (download) - annotate - [select for diffs], Sat Feb 12 18:17:53 2005 UTC (19 years, 1 month ago) by yamt
Branch: yamt-km
Changes since 1.39: +14 -22 lines
Diff to previous 1.39 (colored) next main 1.40 (colored) to selected 1.64 (colored)

sync with head.

Revision 1.34.2.5 / (download) - annotate - [select for diffs], Fri Feb 4 11:47:45 2005 UTC (19 years, 1 month ago) by skrll
Branch: ktrace-lwp
Changes since 1.34.2.4: +14 -22 lines
Diff to previous 1.34.2.4 (colored) next main 1.35 (colored) to selected 1.64 (colored)

Sync with HEAD.

Revision 1.41 / (download) - annotate - [select for diffs], Thu Feb 3 03:49:01 2005 UTC (19 years, 1 month ago) by perry
Branch: MAIN
CVS Tags: yamt-vop-base3, yamt-vop-base2, yamt-vop-base, yamt-vop, yamt-readahead-pervnode, yamt-readahead-perfile, yamt-readahead-base3, yamt-readahead-base2, yamt-readahead-base, yamt-readahead, yamt-km-base4, yamt-km-base3, yamt-km-base2, thorpej-vnode-attr-base, thorpej-vnode-attr, netbsd-3-base, netbsd-3-1-RELEASE, netbsd-3-1-RC4, netbsd-3-1-RC3, netbsd-3-1-RC2, netbsd-3-1-RC1, netbsd-3-1-1-RELEASE, netbsd-3-1, netbsd-3-0-RELEASE, netbsd-3-0-RC6, netbsd-3-0-RC5, netbsd-3-0-RC4, netbsd-3-0-RC3, netbsd-3-0-RC2, netbsd-3-0-RC1, netbsd-3-0-3-RELEASE, netbsd-3-0-2-RELEASE, netbsd-3-0-1-RELEASE, netbsd-3-0, netbsd-3, ktrace-lwp-base, kent-audio2-base
Branch point for: yamt-lazymbuf
Changes since 1.40: +11 -19 lines
Diff to previous 1.40 (colored) to selected 1.64 (colored)

ANSIfy function prototypes. (Still have about 3/5ths of the C files in
netinet to go...)

Revision 1.40 / (download) - annotate - [select for diffs], Wed Feb 2 21:41:55 2005 UTC (19 years, 1 month ago) by perry
Branch: MAIN
Changes since 1.39: +5 -5 lines
Diff to previous 1.39 (colored) to selected 1.64 (colored)

de-__P -- will ANSIfy .c files later.

Revision 1.34.2.4 / (download) - annotate - [select for diffs], Mon Nov 29 07:25:04 2004 UTC (19 years, 4 months ago) by skrll
Branch: ktrace-lwp
Changes since 1.34.2.3: +5 -3 lines
Diff to previous 1.34.2.3 (colored) to selected 1.64 (colored)

Sync with HEAD.

Revision 1.39 / (download) - annotate - [select for diffs], Sat Nov 13 19:17:50 2004 UTC (19 years, 4 months ago) by christos
Branch: MAIN
CVS Tags: yamt-km-base, kent-audio1-beforemerge, kent-audio1-base, kent-audio1
Branch point for: yamt-km, kent-audio2
Changes since 1.38: +5 -3 lines
Diff to previous 1.38 (colored) to selected 1.64 (colored)

PR/25749: Peter Postma: missing splx() in kernel.

Revision 1.34.2.3 / (download) - annotate - [select for diffs], Tue Sep 21 13:37:11 2004 UTC (19 years, 6 months ago) by skrll
Branch: ktrace-lwp
Changes since 1.34.2.2: +2 -2 lines
Diff to previous 1.34.2.2 (colored) to selected 1.64 (colored)

Fix the sync with head I botched.

Revision 1.34.2.2 / (download) - annotate - [select for diffs], Sat Sep 18 14:54:53 2004 UTC (19 years, 6 months ago) by skrll
Branch: ktrace-lwp
Changes since 1.34.2.1: +0 -0 lines
Diff to previous 1.34.2.1 (colored) to selected 1.64 (colored)

Sync with HEAD.

Revision 1.34.2.1 / (download) - annotate - [select for diffs], Tue Aug 3 10:54:36 2004 UTC (19 years, 7 months ago) by skrll
Branch: ktrace-lwp
Changes since 1.34: +5 -19 lines
Diff to previous 1.34 (colored) to selected 1.64 (colored)

Sync with HEAD

Revision 1.38 / (download) - annotate - [select for diffs], Mon Apr 26 01:31:56 2004 UTC (19 years, 11 months ago) by matt
Branch: MAIN
CVS Tags: BEFORE-IPF413
Changes since 1.37: +2 -8 lines
Diff to previous 1.37 (colored) to selected 1.64 (colored)

Remove #else clause of __STDC__

Revision 1.37 / (download) - annotate - [select for diffs], Sun Apr 25 16:42:42 2004 UTC (19 years, 11 months ago) by simonb
Branch: MAIN
Changes since 1.36: +3 -11 lines
Diff to previous 1.36 (colored) to selected 1.64 (colored)

Initialise (most) pools from a link set instead of explicit calls
to pool_init.  Untouched pools are ones that either in arch-specific
code, or aren't initialiased during initial system startup.

 Convert struct session, ucred and lockf to pools.

Revision 1.36 / (download) - annotate - [select for diffs], Fri Aug 22 21:53:02 2003 UTC (20 years, 7 months ago) by itojun
Branch: MAIN
CVS Tags: netbsd-2-base, netbsd-2-1-RELEASE, netbsd-2-1-RC6, netbsd-2-1-RC5, netbsd-2-1-RC4, netbsd-2-1-RC3, netbsd-2-1-RC2, netbsd-2-1-RC1, netbsd-2-1, netbsd-2-0-base, netbsd-2-0-RELEASE, netbsd-2-0-RC5, netbsd-2-0-RC4, netbsd-2-0-RC3, netbsd-2-0-RC2, netbsd-2-0-RC1, netbsd-2-0-3-RELEASE, netbsd-2-0-2-RELEASE, netbsd-2-0-1-RELEASE, netbsd-2-0, netbsd-2, BEFORE-IPF411
Changes since 1.35: +4 -4 lines
Diff to previous 1.35 (colored) to selected 1.64 (colored)

change the additional arg to be passed to ip{,6}_output to struct socket *.

this fixes KAME policy lookup which was broken by the previous commit.

Revision 1.35 / (download) - annotate - [select for diffs], Fri Aug 15 03:42:01 2003 UTC (20 years, 7 months ago) by jonathan
Branch: MAIN
Changes since 1.34: +3 -3 lines
Diff to previous 1.34 (colored) to selected 1.64 (colored)

(fast-ipsec): Add hooks to pass IPv4 IPsec traffic into fast-ipsec, if
configured with ``options FAST_IPSEC''.  Kernels with KAME IPsec or
with no IPsec should work as before.

All calls to ip_output() now always pass an additional compulsory
argument: the inpcb associated with the packet being sent,
or 0 if no inpcb is available.

Fast-ipsec tested with ICMP or UDP over ESP. TCP doesn't work, yet.

Revision 1.25.2.1 / (download) - annotate - [select for diffs], Mon Aug 4 19:08:11 2003 UTC (20 years, 7 months ago) by msaitoh
Branch: netbsd-1-5
Changes since 1.25: +29 -2 lines
Diff to previous 1.25 (colored) next main 1.26 (colored) to selected 1.64 (colored)

Pull up revision 1.34 (requested by itojun in ticket #50):
	purge rti structure (in igmp.c) for removed ifp on if_detach().

Revision 1.28.4.2 / (download) - annotate - [select for diffs], Wed Jul 2 14:02:43 2003 UTC (20 years, 9 months ago) by tron
Branch: netbsd-1-6
CVS Tags: netbsd-1-6-PATCH002-RELEASE, netbsd-1-6-PATCH002-RC4, netbsd-1-6-PATCH002-RC3, netbsd-1-6-PATCH002-RC2, netbsd-1-6-PATCH002-RC1, netbsd-1-6-PATCH002
Changes since 1.28.4.1: +10 -7 lines
Diff to previous 1.28.4.1 (colored) to branchpoint 1.28 (colored) next main 1.29 (colored) to selected 1.64 (colored)

Apply patch (requested by itojun in ticket #1360):
Make it compilable.

Revision 1.28.4.1 / (download) - annotate - [select for diffs], Mon Jun 30 02:16:24 2003 UTC (20 years, 9 months ago) by grant
Branch: netbsd-1-6
Changes since 1.28: +27 -3 lines
Diff to previous 1.28 (colored) to selected 1.64 (colored)

Pull up revision 1.34 (requested by itojun in ticket #1341):

purge rti structure (in igmp.c) for removed ifp on if_detach().

Revision 1.34 / (download) - annotate - [select for diffs], Thu Jun 26 03:11:08 2003 UTC (20 years, 9 months ago) by itojun
Branch: MAIN
Branch point for: ktrace-lwp
Changes since 1.33: +27 -3 lines
Diff to previous 1.33 (colored) to selected 1.64 (colored)

purge rti structure (in igmp.c) for removed ifp on if_detach().

Revision 1.33 / (download) - annotate - [select for diffs], Sun Jun 15 02:49:32 2003 UTC (20 years, 9 months ago) by matt
Branch: MAIN
Changes since 1.32: +26 -18 lines
Diff to previous 1.32 (colored) to selected 1.64 (colored)

Change the way multicasts are kept.  They now use a hash table in the same
manner as the ifaddr hash table.  By doing this, the mkludge code can go
away.  At the same time, keep track of what pcbs are using what ifaddr and
when an address is deleted from an interface, notify/abort all sockets
that have that address as a source.  Switch IGMP and multicasts to use pools
for allocation.  Fix a number of potential problems in the igmp code where
allocation failures could cause a trap/panic.

Revision 1.25.4.6 / (download) - annotate - [select for diffs], Mon Nov 11 22:15:13 2002 UTC (21 years, 4 months ago) by nathanw
Branch: nathanw_sa
CVS Tags: nathanw_sa_end
Changes since 1.25.4.5: +2 -2 lines
Diff to previous 1.25.4.5 (colored) to branchpoint 1.25 (colored) next main 1.26 (colored) to selected 1.64 (colored)

Catch up to -current

Revision 1.32 / (download) - annotate - [select for diffs], Thu Nov 7 07:15:19 2002 UTC (21 years, 4 months ago) by thorpej
Branch: MAIN
CVS Tags: nathanw_sa_before_merge, nathanw_sa_base, gmcgarry_ucred_base, gmcgarry_ucred, gmcgarry_ctxsw_base, gmcgarry_ctxsw, fvdl_fs64_base
Changes since 1.31: +4 -4 lines
Diff to previous 1.31 (colored) to selected 1.64 (colored)

Fix signed/unsigned comparison warnings.

Revision 1.25.6.4 / (download) - annotate - [select for diffs], Fri Sep 6 08:49:09 2002 UTC (21 years, 6 months ago) by jdolecek
Branch: kqueue
Changes since 1.25.6.3: +9 -6 lines
Diff to previous 1.25.6.3 (colored) to branchpoint 1.25 (colored) next main 1.26 (colored) to selected 1.64 (colored)

sync kqueue branch with HEAD

Revision 1.28.2.3 / (download) - annotate - [select for diffs], Thu Aug 29 00:56:45 2002 UTC (21 years, 7 months ago) by gehenna
Branch: gehenna-devsw
Changes since 1.28.2.2: +8 -6 lines
Diff to previous 1.28.2.2 (colored) to branchpoint 1.28 (colored) next main 1.29 (colored) to selected 1.64 (colored)

catch up with -current.

Revision 1.25.4.5 / (download) - annotate - [select for diffs], Tue Aug 27 23:47:57 2002 UTC (21 years, 7 months ago) by nathanw
Branch: nathanw_sa
Changes since 1.25.4.4: +6 -4 lines
Diff to previous 1.25.4.4 (colored) to branchpoint 1.25 (colored) to selected 1.64 (colored)

Catch up to -current.

Revision 1.31 / (download) - annotate - [select for diffs], Wed Aug 14 00:23:29 2002 UTC (21 years, 7 months ago) by itojun
Branch: MAIN
CVS Tags: kqueue-beforemerge, kqueue-base, kqueue-aftermerge, gehenna-devsw-base
Changes since 1.30: +8 -6 lines
Diff to previous 1.30 (colored) to selected 1.64 (colored)

avoid swapping endian of ip_len and ip_off on mbuf, to meet with M_LEADINGSPACE
optimization made last year.  should solve PR 17867 and 10195.

IP_HDRINCL behavior of raw ip socket is kept unchanged.  we may want to
provide IP_HDRINCL variant that does not swap endian.

Revision 1.25.4.4 / (download) - annotate - [select for diffs], Thu Aug 1 02:46:46 2002 UTC (21 years, 8 months ago) by nathanw
Branch: nathanw_sa
Changes since 1.25.4.3: +3 -2 lines
Diff to previous 1.25.4.3 (colored) to branchpoint 1.25 (colored) to selected 1.64 (colored)

Catch up to -current.

Revision 1.28.2.2 / (download) - annotate - [select for diffs], Mon Jul 15 10:36:55 2002 UTC (21 years, 8 months ago) by gehenna
Branch: gehenna-devsw
Changes since 1.28.2.1: +3 -2 lines
Diff to previous 1.28.2.1 (colored) to branchpoint 1.28 (colored) to selected 1.64 (colored)

catch up with -current.

Revision 1.30 / (download) - annotate - [select for diffs], Sun Jun 30 22:40:33 2002 UTC (21 years, 9 months ago) by thorpej
Branch: MAIN
Changes since 1.29: +3 -2 lines
Diff to previous 1.29 (colored) to selected 1.64 (colored)

Changes to allow the IPv4 and IPv6 layers to align headers themseves,
as necessary:
* Implement a new mbuf utility routine, m_copyup(), is is like
  m_pullup(), except that it always prepends and copies, rather
  than only doing so if the desired length is larger than m->m_len.
  m_copyup() also allows an offset into the destination mbuf, which
  allows space for packet headers, in the forwarding case.
* Add *_HDR_ALIGNED_P() macros for IP, IPv6, ICMP, and IGMP.  These
  macros expand to 1 if __NO_STRICT_ALIGNMENT is defined, so that
  architectures which do not have strict alignment constraints don't
  pay for the test or visit the new align-if-needed path.
* Use the new macros to check if a header needs to be aligned, or to
  assert that it already is, as appropriate.

Note: This code is still somewhat experimental.  However, the new
code path won't be visited if individual device drivers continue
to guarantee that packets are delivered to layer 3 already properly
aligned (which are rules that are already in use).

Revision 1.25.6.3 / (download) - annotate - [select for diffs], Sun Jun 23 17:50:41 2002 UTC (21 years, 9 months ago) by jdolecek
Branch: kqueue
Changes since 1.25.6.2: +5 -4 lines
Diff to previous 1.25.6.2 (colored) to branchpoint 1.25 (colored) to selected 1.64 (colored)

catch up with -current on kqueue branch

Revision 1.28.2.1 / (download) - annotate - [select for diffs], Thu Jun 20 15:52:13 2002 UTC (21 years, 9 months ago) by gehenna
Branch: gehenna-devsw
Changes since 1.28: +4 -4 lines
Diff to previous 1.28 (colored) to selected 1.64 (colored)

catch up with -current.

Revision 1.25.4.3 / (download) - annotate - [select for diffs], Thu Jun 20 03:48:31 2002 UTC (21 years, 9 months ago) by nathanw
Branch: nathanw_sa
Changes since 1.25.4.2: +5 -4 lines
Diff to previous 1.25.4.2 (colored) to branchpoint 1.25 (colored) to selected 1.64 (colored)

Catch up to -current.

Revision 1.29 / (download) - annotate - [select for diffs], Sun Jun 9 16:33:37 2002 UTC (21 years, 9 months ago) by itojun
Branch: MAIN
Changes since 1.28: +4 -4 lines
Diff to previous 1.28 (colored) to selected 1.64 (colored)

whitespace

Revision 1.28 / (download) - annotate - [select for diffs], Sun May 12 20:33:50 2002 UTC (21 years, 10 months ago) by matt
Branch: MAIN
CVS Tags: netbsd-1-6-base, netbsd-1-6-RELEASE, netbsd-1-6-RC3, netbsd-1-6-RC2, netbsd-1-6-RC1, netbsd-1-6-PATCH001-RELEASE, netbsd-1-6-PATCH001-RC3, netbsd-1-6-PATCH001-RC2, netbsd-1-6-PATCH001-RC1, netbsd-1-6-PATCH001
Branch point for: netbsd-1-6, gehenna-devsw
Changes since 1.27: +3 -2 lines
Diff to previous 1.27 (colored) to selected 1.64 (colored)

Eliminate commons.

Revision 1.25.6.2 / (download) - annotate - [select for diffs], Thu Jan 10 20:02:39 2002 UTC (22 years, 2 months ago) by thorpej
Branch: kqueue
Changes since 1.25.6.1: +4 -1 lines
Diff to previous 1.25.6.1 (colored) to branchpoint 1.25 (colored) to selected 1.64 (colored)

Sync kqueue branch with -current.

Revision 1.25.4.2 / (download) - annotate - [select for diffs], Wed Nov 14 19:17:42 2001 UTC (22 years, 4 months ago) by nathanw
Branch: nathanw_sa
Changes since 1.25.4.1: +4 -1 lines
Diff to previous 1.25.4.1 (colored) to branchpoint 1.25 (colored) to selected 1.64 (colored)

Catch up to -current.

Revision 1.27 / (download) - annotate - [select for diffs], Tue Nov 13 00:32:35 2001 UTC (22 years, 4 months ago) by lukem
Branch: MAIN
CVS Tags: newlock-base, newlock, ifpoll-base, eeh-devprop-base, eeh-devprop
Changes since 1.26: +4 -1 lines
Diff to previous 1.26 (colored) to selected 1.64 (colored)

add RCSIDs

Revision 1.25.4.1 / (download) - annotate - [select for diffs], Fri Aug 24 00:12:23 2001 UTC (22 years, 7 months ago) by nathanw
Branch: nathanw_sa
Changes since 1.25: +1 -4 lines
Diff to previous 1.25 (colored) to selected 1.64 (colored)

Catch up with -current.

Revision 1.25.6.1 / (download) - annotate - [select for diffs], Fri Aug 3 04:13:53 2001 UTC (22 years, 8 months ago) by lukem
Branch: kqueue
Changes since 1.25: +1 -4 lines
Diff to previous 1.25 (colored) to selected 1.64 (colored)

update to -current

Revision 1.26 / (download) - annotate - [select for diffs], Wed Jul 25 00:13:16 2001 UTC (22 years, 8 months ago) by enami
Branch: MAIN
CVS Tags: thorpej-mips-cache-base, thorpej-mips-cache, thorpej-devvp-base3, thorpej-devvp-base2, thorpej-devvp-base, thorpej-devvp, pre-chs-ubcperf, post-chs-ubcperf
Changes since 1.25: +1 -4 lines
Diff to previous 1.25 (colored) to selected 1.64 (colored)

Remove an obsolete comment.

Revision 1.22.2.1 / (download) - annotate - [select for diffs], Mon Nov 20 18:10:21 2000 UTC (23 years, 4 months ago) by bouyer
Branch: thorpej_scsipi
Changes since 1.22: +19 -21 lines
Diff to previous 1.22 (colored) next main 1.23 (colored) to selected 1.64 (colored)

Update thorpej_scsipi to -current as of a month ago

Revision 1.24.2.1 / (download) - annotate - [select for diffs], Thu Jun 22 17:09:45 2000 UTC (23 years, 9 months ago) by minoura
Branch: minoura-xpg4dl
Changes since 1.24: +9 -7 lines
Diff to previous 1.24 (colored) next main 1.25 (colored) to selected 1.64 (colored)

Sync w/ netbsd-1-5-base.

Revision 1.25 / (download) - annotate - [select for diffs], Fri Jun 16 20:21:26 2000 UTC (23 years, 9 months ago) by matt
Branch: MAIN
CVS Tags: thorpej_scsipi_nbase, thorpej_scsipi_beforemerge, thorpej_scsipi_base, netbsd-1-5-base, netbsd-1-5-RELEASE, netbsd-1-5-PATCH003, netbsd-1-5-PATCH002, netbsd-1-5-PATCH001, netbsd-1-5-BETA2, netbsd-1-5-BETA, netbsd-1-5-ALPHA2
Branch point for: netbsd-1-5, nathanw_sa, kqueue
Changes since 1.24: +9 -7 lines
Diff to previous 1.24 (colored) to selected 1.64 (colored)

Don't copy M_EXT mbufs unless in "dhcp" mode.  Do a mtod after the pullup
to make sure the ip pointer is still valid.

Revision 1.24 / (download) - annotate - [select for diffs], Thu Mar 30 13:24:54 2000 UTC (24 years ago) by augustss
Branch: MAIN
CVS Tags: minoura-xpg4dl-base
Branch point for: minoura-xpg4dl
Changes since 1.23: +11 -11 lines
Diff to previous 1.23 (colored) to selected 1.64 (colored)

Remove register declarations.

Revision 1.23 / (download) - annotate - [select for diffs], Wed Mar 1 12:49:30 2000 UTC (24 years, 1 month ago) by itojun
Branch: MAIN
Changes since 1.22: +1 -5 lines
Diff to previous 1.22 (colored) to selected 1.64 (colored)

introduce m->m_pkthdr.aux to hold random data which needs to be passed
between protocol handlers.

ipsec socket pointers, ipsec decryption/auth information, tunnel
decapsulation information are in my mind - there can be several other usage.
at this moment, we use this for ipsec socket pointer passing.  this will
avoid reuse of m->m_pkthdr.rcvif in ipsec code.

due to the change, MHLEN will be decreased by sizeof(void *) - for example,
for i386, MHLEN was 100 bytes, but is now 96 bytes.
we may want to increase MSIZE from 128 to 256 for some of our architectures.

take caution if you use it for keeping some data item for long period
of time - use extra caution on M_PREPEND() or m_adj(), as they may result
in loss of m->m_pkthdr.aux pointer (and mbuf leak).

this will bump kernel version.

(as discussed in tech-net, tested in kame tree)

Revision 1.19.2.1.4.2 / (download) - annotate - [select for diffs], Tue Nov 30 13:35:22 1999 UTC (24 years, 4 months ago) by itojun
Branch: kame
CVS Tags: kame_141_19991130
Changes since 1.19.2.1.4.1: +1 -0 lines
Diff to previous 1.19.2.1.4.1 (colored) to branchpoint 1.19.2.1 (colored) next main 1.20 (colored) to selected 1.64 (colored)

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.

Revision 1.19.2.1.2.3 / (download) - annotate - [select for diffs], Mon Aug 2 22:34:57 1999 UTC (24 years, 8 months ago) by thorpej
Branch: chs-ubc2
Changes since 1.19.2.1.2.2: +2 -1 lines
Diff to previous 1.19.2.1.2.2 (colored) to branchpoint 1.19.2.1 (colored) next main 1.20 (colored) to selected 1.64 (colored)

Update from trunk.

Revision 1.22 / (download) - annotate - [select for diffs], Fri Jul 9 22:57:16 1999 UTC (24 years, 8 months ago) by thorpej
Branch: MAIN
CVS Tags: wrstuden-devbsize-base, wrstuden-devbsize-19991221, wrstuden-devbsize, fvdl-softdep-base, fvdl-softdep, comdex-fall-1999-base, comdex-fall-1999, chs-ubc2-newbase, chs-ubc2-base
Branch point for: thorpej_scsipi
Changes since 1.21: +2 -1 lines
Diff to previous 1.21 (colored) to selected 1.64 (colored)

defopt IPSEC and IPSEC_ESP (both into opt_ipsec.h).

Revision 1.19.2.1.2.2 / (download) - annotate - [select for diffs], Thu Jul 1 23:47:00 1999 UTC (24 years, 9 months ago) by thorpej
Branch: chs-ubc2
Changes since 1.19.2.1.2.1: +37 -2 lines
Diff to previous 1.19.2.1.2.1 (colored) to branchpoint 1.19.2.1 (colored) to selected 1.64 (colored)

Sync w/ -current.

Revision 1.21 / (download) - annotate - [select for diffs], Thu Jul 1 08:12:49 1999 UTC (24 years, 9 months ago) by itojun
Branch: MAIN
Changes since 1.20: +37 -2 lines
Diff to previous 1.20 (colored) to selected 1.64 (colored)

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.

Revision 1.19.2.1.4.1 / (download) - annotate - [select for diffs], Mon Jun 28 06:36:58 1999 UTC (24 years, 9 months ago) by itojun
Branch: kame
CVS Tags: kame_14_19990705, kame_14_19990628
Changes since 1.19.2.1: +37 -2 lines
Diff to previous 1.19.2.1 (colored) to selected 1.64 (colored)

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.

Revision 1.19.2.1.2.1 / (download) - annotate - [select for diffs], Mon Jun 21 01:27:48 1999 UTC (24 years, 9 months ago) by thorpej
Branch: chs-ubc2
Changes since 1.19.2.1: +0 -0 lines
Diff to previous 1.19.2.1 (colored) to selected 1.64 (colored)

Sync w/ -current.

Revision 1.19.2.1 / (download) - annotate - [select for diffs], Mon Apr 26 15:45:02 1999 UTC (24 years, 11 months ago) by perry
Branch: netbsd-1-4
CVS Tags: netbsd-1-4-RELEASE, netbsd-1-4-PATCH003, netbsd-1-4-PATCH002, netbsd-1-4-PATCH001
Branch point for: kame, chs-ubc2
Changes since 1.19: +3 -1 lines
Diff to previous 1.19 (colored) next main 1.20 (colored) to selected 1.64 (colored)

pullup 1.19->1.20 (Heiko Rupp): fix handling of packets with 0 timer values.

Revision 1.20 / (download) - annotate - [select for diffs], Sun Apr 25 10:26:29 1999 UTC (24 years, 11 months ago) by hwr
Branch: MAIN
Changes since 1.19: +3 -1 lines
Diff to previous 1.19 (colored) to selected 1.64 (colored)

If the incoming code value is 0, timer gets 0, which would mean
a divide by zero afterwards.
This is also, what Bill Fenner seems to have done in the FreeBSD igmp
code.
This should fix kern/6541.

Revision 1.19 / (download) - annotate - [select for diffs], Tue Jan 19 23:03:20 1999 UTC (25 years, 2 months ago) by mycroft
Branch: MAIN
CVS Tags: netbsd-1-4-base
Branch point for: netbsd-1-4
Changes since 1.18: +4 -7 lines
Diff to previous 1.18 (colored) to selected 1.64 (colored)

Don't screw with ip_len; just subtract from it where we actually use the
value.

Revision 1.18.6.1 / (download) - annotate - [select for diffs], Fri Dec 11 04:53:08 1998 UTC (25 years, 3 months ago) by kenh
Branch: kenh-if-detach
Changes since 1.18: +44 -5 lines
Diff to previous 1.18 (colored) next main 1.19 (colored) to selected 1.64 (colored)

The beginnings of interface detach support.  Still some bugs, but mostly
works for me.

This work was originally by Bill Studenmund, and cleaned up by me.

Revision 1.16.14.1 / (download) - annotate - [select for diffs], Thu Oct 1 17:56:28 1998 UTC (25 years, 6 months ago) by cgd
Branch: netbsd-1-3
CVS Tags: netbsd-1-3-PATCH003-CANDIDATE2, netbsd-1-3-PATCH003-CANDIDATE1, netbsd-1-3-PATCH003-CANDIDATE0, netbsd-1-3-PATCH003
Changes since 1.16: +4 -4 lines
Diff to previous 1.16 (colored) next main 1.17 (colored) to selected 1.64 (colored)

pull up revision 1.18 from trunk. (tls)

Revision 1.18 / (download) - annotate - [select for diffs], Fri Feb 13 18:21:40 1998 UTC (26 years, 1 month ago) by tls
Branch: MAIN
CVS Tags: kenh-if-detach-base, eeh-paddr_t-base, eeh-paddr_t, chs-ubc-base, chs-ubc
Branch point for: kenh-if-detach
Changes since 1.17: +4 -4 lines
Diff to previous 1.17 (colored) to selected 1.64 (colored)

Change list of interface IP addresses to a hash.  Improves performance on hosts with a large number of IP addresses significantly.

Revision 1.17 / (download) - annotate - [select for diffs], Mon Jan 12 03:02:48 1998 UTC (26 years, 2 months ago) by scottr
Branch: MAIN
Changes since 1.16: +3 -1 lines
Diff to previous 1.16 (colored) to selected 1.64 (colored)

Use option header file for MROUTING

Revision 1.1.1.2 / (download) - annotate - [select for diffs] (vendor branch), Mon Jan 5 09:55:55 1998 UTC (26 years, 2 months ago) by thorpej
Branch: netbsd, CSRG
CVS Tags: lite-2
Changes since 1.1.1.1: +6 -2 lines
Diff to previous 1.1.1.1 (colored) to selected 1.64 (colored)

Import sys/netinet from 4.4BSD-Lite2 for reference purposes.

Revision 1.1.1.1 / (download) - annotate - [select for diffs] (vendor branch), Mon Jan 5 09:53:59 1998 UTC (26 years, 2 months ago) by thorpej
Branch: netbsd, CSRG
CVS Tags: lite-1, date-03-may-96
Changes since 1.1: +9 -16 lines
Diff to previous 1.1 (colored) to selected 1.64 (colored)

Import sys/netinet from 4.4BSD-Lite for reference purposes.

Revision 1.16 / (download) - annotate - [select for diffs], Mon Sep 9 14:51:08 1996 UTC (27 years, 6 months ago) by mycroft
Branch: MAIN
CVS Tags: thorpej-signal-base, thorpej-signal, thorpej-setroot, netbsd-1-3-base, netbsd-1-3-RELEASE, netbsd-1-3-PATCH002, netbsd-1-3-PATCH001, netbsd-1-3-BETA, mrg-vm-swap, marc-pcmcia-bp, marc-pcmcia-base, marc-pcmcia, is-newarp-before-merge, is-newarp-base, is-newarp, bouyer-scsipi
Branch point for: netbsd-1-3
Changes since 1.15: +6 -6 lines
Diff to previous 1.15 (colored) to selected 1.64 (colored)

Add in_nullhost() and in_hosteq() macros, to hide some protocol
details.  Also, fix a bug in TCP wrt SYN+URG packets.

Revision 1.15 / (download) - annotate - [select for diffs], Tue Feb 13 23:41:25 1996 UTC (28 years, 1 month ago) by christos
Branch: MAIN
CVS Tags: netbsd-1-2-base, netbsd-1-2-RELEASE, netbsd-1-2-PATCH001, netbsd-1-2-BETA, netbsd-1-2
Changes since 1.14: +19 -4 lines
Diff to previous 1.14 (colored) to selected 1.64 (colored)

netinet prototypes

Revision 1.14 / (download) - annotate - [select for diffs], Sat Aug 12 23:59:31 1995 UTC (28 years, 7 months ago) by mycroft
Branch: MAIN
CVS Tags: netbsd-1-1-base, netbsd-1-1-RELEASE, netbsd-1-1-PATCH001, netbsd-1-1
Changes since 1.13: +4 -4 lines
Diff to previous 1.13 (colored) to selected 1.64 (colored)

splnet --> splsoftnet

Revision 1.13 / (download) - annotate - [select for diffs], Sun Jun 4 05:58:20 1995 UTC (28 years, 10 months ago) by mycroft
Branch: MAIN
Changes since 1.12: +2 -2 lines
Diff to previous 1.12 (colored) to selected 1.64 (colored)

Don't cast things unnecessarily.

Revision 1.12 / (download) - annotate - [select for diffs], Thu Jun 1 21:35:34 1995 UTC (28 years, 10 months ago) by mycroft
Branch: MAIN
Changes since 1.11: +10 -18 lines
Diff to previous 1.11 (colored) to selected 1.64 (colored)

Avoid byte-swapping IP addresses at run time.

Revision 1.11 / (download) - annotate - [select for diffs], Thu Jun 1 15:59:04 1995 UTC (28 years, 10 months ago) by mycroft
Branch: MAIN
Changes since 1.10: +2 -2 lines
Diff to previous 1.10 (colored) to selected 1.64 (colored)

Add missing ntohl() in multicast test.

Revision 1.10 / (download) - annotate - [select for diffs], Wed May 31 06:08:17 1995 UTC (28 years, 10 months ago) by mycroft
Branch: MAIN
Changes since 1.9: +299 -95 lines
Diff to previous 1.9 (colored) to selected 1.64 (colored)

Implement IGMP v2.  Based on the Multicast 3.5 distribution.

Revision 1.9 / (download) - annotate - [select for diffs], Thu Apr 13 06:26:19 1995 UTC (28 years, 11 months ago) by cgd
Branch: MAIN
Changes since 1.8: +2 -2 lines
Diff to previous 1.8 (colored) to selected 1.64 (colored)

be a bit more careful and explicit with types.  (basically a large no-op.)

Revision 1.8 / (download) - annotate - [select for diffs], Wed Jun 29 06:37:56 1994 UTC (29 years, 9 months ago) by cgd
Branch: MAIN
CVS Tags: netbsd-1-0-base, netbsd-1-0-RELEASE, netbsd-1-0-PATCH1, netbsd-1-0-PATCH06, netbsd-1-0-PATCH05, netbsd-1-0-PATCH04, netbsd-1-0-PATCH03, netbsd-1-0-PATCH02, netbsd-1-0-PATCH0, netbsd-1-0
Changes since 1.7: +3 -2 lines
Diff to previous 1.7 (colored) to selected 1.64 (colored)

New RCS ID's, take two.  they're more aesthecially pleasant, and use 'NetBSD'

Revision 1.7 / (download) - annotate - [select for diffs], Thu Jun 9 15:59:47 1994 UTC (29 years, 9 months ago) by brezak
Branch: MAIN
Changes since 1.6: +6 -2 lines
Diff to previous 1.6 (colored) to selected 1.64 (colored)

Patch to fix ip cksum errors. From mccanne@ee.lbl.gov (Steven McCanne).

Revision 1.6 / (download) - annotate - [select for diffs], Sat Jun 4 08:13:23 1994 UTC (29 years, 10 months ago) by mycroft
Branch: MAIN
Changes since 1.5: +4 -6 lines
Diff to previous 1.5 (colored) to selected 1.64 (colored)

Modify the loopback checks to deal with multiple interfaces.

Revision 1.5 / (download) - annotate - [select for diffs], Fri May 13 06:05:58 1994 UTC (29 years, 10 months ago) by mycroft
Branch: MAIN
Changes since 1.4: +8 -12 lines
Diff to previous 1.4 (colored) to selected 1.64 (colored)

Update to 4.4-Lite networking code, with a few local changes.

Revision 1.4 / (download) - annotate - [select for diffs], Wed Feb 2 05:58:56 1994 UTC (30 years, 2 months ago) by hpeyerl
Branch: MAIN
Changes since 1.3: +0 -2 lines
Diff to previous 1.3 (colored) to selected 1.64 (colored)

Multicast is no longer optional.

Revision 1.3 / (download) - annotate - [select for diffs], Mon Jan 10 20:14:14 1994 UTC (30 years, 2 months ago) by mycroft
Branch: MAIN
Changes since 1.2: +1 -1 lines
Diff to previous 1.2 (colored) to selected 1.64 (colored)

Should compile now with or without `options MULTICAST'.

Revision 1.2 / (download) - annotate - [select for diffs], Sat Jan 8 21:21:32 1994 UTC (30 years, 2 months ago) by mycroft
Branch: MAIN
Changes since 1.1: +1 -1 lines
Diff to previous 1.1 (colored) to selected 1.64 (colored)

Fix some inconsistent spacing; spaces at the end of lines, etc.

Revision 1.1 / (download) - annotate - [select for diffs], Mon Dec 6 05:03:26 1993 UTC (30 years, 3 months ago) by hpeyerl
Branch: MAIN
Diff to selected 1.64 (colored)

multicast support.
>From Chris Maeda, cmaeda@cs.washington.edu
These patches are derived from the IP Multicast patches for BSDI.

This form allows you to request diff's between any two revisions of a file. You may select a symbolic revision name using the selection box or you may type in a numeric name using the type-in text box.




CVSweb <webmaster@jp.NetBSD.org>