The NetBSD Project

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

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

Request diff between arbitrary revisions


Default branch: MAIN


Revision 1.114.2.3 / (download) - annotate - [select for diffs], Wed Aug 20 00:04:35 2014 UTC (2 months, 1 week ago) by tls
Branch: tls-maxphys
Changes since 1.114.2.2: +372 -173 lines
Diff to previous 1.114.2.2 (colored) to branchpoint 1.114 (colored) next main 1.115 (colored) to selected 1.23 (colored)

Rebase to HEAD as of a few days ago.

Revision 1.118.2.1 / (download) - annotate - [select for diffs], Sun Aug 10 06:56:25 2014 UTC (2 months, 3 weeks ago) by tls
Branch: tls-earlyentropy
Changes since 1.118: +370 -164 lines
Diff to previous 1.118 (colored) next main 1.119 (colored) to selected 1.23 (colored)

Rebase.

Revision 1.145 / (download) - annotate - [select for diffs], Sat Aug 9 05:33:01 2014 UTC (2 months, 3 weeks ago) by rtr
Branch: MAIN
CVS Tags: tls-maxphys-base, tls-earlyentropy-base, netbsd-7-base, netbsd-7, HEAD
Changes since 1.144: +35 -32 lines
Diff to previous 1.144 (colored) to selected 1.23 (colored)

split PRU_CONNECT2 & PRU_PURGEIF function out of pr_generic() usrreq
switches and put into separate functions

  - always KASSERT(solocked(so)) even if not implemented
    (for PRU_CONNECT2 only)

  - replace calls to pr_generic() with req = PRU_CONNECT2 with calls to
    pr_connect2()

  - replace calls to pr_generic() with req = PRU_PURGEIF with calls to
    pr_purgeif()

put common code from unp_connect2() (used by unp_connect() into
unp_connect1() and call out to it when needed

patch only briefly reviewed by rmind@

Revision 1.144 / (download) - annotate - [select for diffs], Fri Aug 8 03:05:45 2014 UTC (2 months, 3 weeks ago) by rtr
Branch: MAIN
Changes since 1.143: +13 -6 lines
Diff to previous 1.143 (colored) to selected 1.23 (colored)

split PRU_RCVD function out of pr_generic() usrreq switches and put into
separate functions

  - always KASSERT(solocked(so)) even if not implemented

  - replace calls to pr_generic() with req = PRU_RCVD with calls to
    pr_rcvd()

Revision 1.143 / (download) - annotate - [select for diffs], Tue Aug 5 07:55:32 2014 UTC (2 months, 3 weeks ago) by rtr
Branch: MAIN
Changes since 1.142: +55 -38 lines
Diff to previous 1.142 (colored) to selected 1.23 (colored)

split PRU_SEND function out of pr_generic() usrreq switches and put into
separate functions

   xxx_send(struct socket *, struct mbuf *, struct mbuf *,
       struct mbuf *, struct lwp *)

  - always KASSERT(solocked(so)) even if not implemented

  - replace calls to pr_generic() with req = PRU_SEND with calls to
    pr_send()

rename existing functions that operate on PCB for consistency (and to
free up their names for xxx_send() PRUs

  - l2cap_send() -> l2cap_send_pcb()
  - sco_send() -> sco_send_pcb()
  - rfcomm_send() -> rfcomm_send_pcb()

patch reviewed by rmind

Revision 1.142 / (download) - annotate - [select for diffs], Tue Aug 5 05:24:26 2014 UTC (2 months, 3 weeks ago) by rtr
Branch: MAIN
Changes since 1.141: +5 -5 lines
Diff to previous 1.141 (colored) to selected 1.23 (colored)

revert the removal of struct lwp * parameter from bind, listen and connect
user requests.

this should resolve the issue relating to nfs client hangs presented
recently by wiz on current-users@

Revision 1.141 / (download) - annotate - [select for diffs], Sun Aug 3 11:44:52 2014 UTC (2 months, 4 weeks ago) by rtr
Branch: MAIN
Changes since 1.140: +3 -3 lines
Diff to previous 1.140 (colored) to selected 1.23 (colored)

req cannot be PRU_SENDOOB here as per KASSERT() earlier in the
rip_usrreq() function.

-       KASSERT(!control || (req == PRU_SEND || req == PRU_SENDOOB));
+       KASSERT(!control || (req == PRU_SEND));

Revision 1.140 / (download) - annotate - [select for diffs], Sat Aug 2 03:55:26 2014 UTC (2 months, 4 weeks ago) by rtr
Branch: MAIN
Changes since 1.139: +22 -3 lines
Diff to previous 1.139 (colored) to selected 1.23 (colored)

restore splsoftnet() in various usrreqs that were removed during the PRU
splits.  we will properly review removal after the PRU split work is
complete.

Revision 1.139 / (download) - annotate - [select for diffs], Thu Jul 31 03:39:35 2014 UTC (3 months ago) by rtr
Branch: MAIN
Changes since 1.138: +49 -18 lines
Diff to previous 1.138 (colored) to selected 1.23 (colored)

split PRU_DISCONNECT, PRU_SHUTDOWN and PRU_ABORT function out of
pr_generic() usrreq switches and put into separate functions

   xxx_disconnect(struct socket *)
   xxx_shutdown(struct socket *)
   xxx_abort(struct socket *)

   - always KASSERT(solocked(so)) even if not implemented
   - replace calls to pr_generic() with req =
PRU_{DISCONNECT,SHUTDOWN,ABORT}
     with calls to pr_{disconnect,shutdown,abort}() respectively

rename existing internal functions used to implement above functionality
to permit use of the names for xxx_{disconnect,shutdown,abort}().

   - {l2cap,sco,rfcomm}_disconnect() ->
{l2cap,sco,rfcomm}_disconnect_pcb()
   - {unp,rip,tcp}_disconnect() -> {unp,rip,tcp}_disconnect1()
   - unp_shutdown() -> unp_shutdown1()

patch reviewed by rmind

Revision 1.138 / (download) - annotate - [select for diffs], Thu Jul 31 02:21:51 2014 UTC (3 months ago) by ozaki-r
Branch: MAIN
Changes since 1.137: +4 -4 lines
Diff to previous 1.137 (colored) to selected 1.23 (colored)

Define IFNET_EMPTY() and replace !IFNET_FIRST() with it

No functional change.

Revision 1.137 / (download) - annotate - [select for diffs], Wed Jul 30 10:04:26 2014 UTC (3 months ago) by rtr
Branch: MAIN
Changes since 1.136: +29 -12 lines
Diff to previous 1.136 (colored) to selected 1.23 (colored)

split PRU_CONNECT function out of pr_generic() usrreq switches and put
into seaparate functions

  xxx_listen(struct socket *, struct mbuf *)

  - always KASSERT(solocked(so)) and KASSERT(nam != NULL)
  - replace calls to pr_generic() with req = PRU_CONNECT with
    pr_connect()
  - rename existin {l2cap,sco,rfcomm}_connect() to
    {l2cap,sco,rfcomm}_connect_pcb() respectively to permit
    naming consistency with other protocols functions.
  - drop struct lwp * parameter from unp_connect() and at_pcbconnect()
    and use curlwp instead where appropriate.

patch reviewed by rmind

Revision 1.136 / (download) - annotate - [select for diffs], Thu Jul 24 15:12:03 2014 UTC (3 months, 1 week ago) by rtr
Branch: MAIN
Changes since 1.135: +55 -30 lines
Diff to previous 1.135 (colored) to selected 1.23 (colored)

split PRU_BIND and PRU_LISTEN function out of pr_generic() usrreq
switches and put into separate functions
  xxx_bind(struct socket *, struct mbuf *)
  xxx_listen(struct socket *)

  - always KASSERT(solocked(so)) even if not implemented

  - replace calls to pr_generic() with req = PRU_BIND with call to
    pr_bind()

  - replace calls to pr_generic() with req = PRU_LISTEN with call to
    pr_listen()

  - drop struct lwp * parameter from at_pcbsetaddr(), in_pcbbind() and
    unp_bind() and always use curlwp.

rename existing functions that operate on PCB for consistency (and to
free up their names for xxx_{bind,listen}() PRUs

  - l2cap_{bind,listen}() -> l2cap_{bind,listen}_pcb()
  - sco_{bind,listen}() -> sco_{bind,listen}_pcb()
  - rfcomm_{bind,listen}() -> rfcomm_{bind,listen}_pcb()

patch reviewed by rmind

welcome to netbsd 6.99.48

Revision 1.135 / (download) - annotate - [select for diffs], Wed Jul 23 13:17:18 2014 UTC (3 months, 1 week ago) by rtr
Branch: MAIN
Changes since 1.134: +27 -12 lines
Diff to previous 1.134 (colored) to selected 1.23 (colored)

split PRU_SENDOOB and PRU_RCVOOB function out of pr_generic() usrreq
switches and put into separate functions
  xxx_sendoob(struct socket *, struct mbuf *, struct mbuf *)
  xxx_recvoob(struct socket *, struct mbuf *, int)

  - always KASSERT(solocked(so)) even if request is not implemented

  - replace calls to pr_generic() with req = PRU_{SEND,RCV}OOB with
    calls to pr_{send,recv}oob() respectively.

there is still some tweaking of m_freem(m) and m_freem(control) to come
for consistency.  not performed with this commit for clarity.

reviewed by rmind

Revision 1.134 / (download) - annotate - [select for diffs], Mon Jul 14 13:39:18 2014 UTC (3 months, 2 weeks ago) by rtr
Branch: MAIN
Changes since 1.133: +4 -4 lines
Diff to previous 1.133 (colored) to selected 1.23 (colored)

fix fat fingered KASSERT(solocked(0)) -> KASSERT(solocked(so)) mistake.

spotted by Takahiro HAYASHI

Revision 1.133 / (download) - annotate - [select for diffs], Wed Jul 9 14:41:42 2014 UTC (3 months, 3 weeks ago) by rtr
Branch: MAIN
Changes since 1.132: +15 -2 lines
Diff to previous 1.132 (colored) to selected 1.23 (colored)

* split PRU_ACCEPT function out of pr_generic() usrreq switches and put
  into a separate function xxx_accept(struct socket *, struct mbuf *)

note: future cleanup will take place to remove struct mbuf parameter
type and replace it with a more appropriate type.

patch reviewed by rmind

Revision 1.132 / (download) - annotate - [select for diffs], Wed Jul 9 04:54:04 2014 UTC (3 months, 3 weeks ago) by rtr
Branch: MAIN
Changes since 1.131: +30 -10 lines
Diff to previous 1.131 (colored) to selected 1.23 (colored)

* split PRU_PEERADDR and PRU_SOCKADDR function out of pr_generic()
  usrreq switches and put into separate functions
  xxx_{peer,sock}addr(struct socket *, struct mbuf *).

    - KASSERT(solocked(so)) always in new functions even if request
      is not implemented

    - KASSERT(pcb != NULL) and KASSERT(nam) if the request is
      implemented and not for tcp.

* for tcp roll #ifdef KPROF and #ifdef DEBUG code from tcp_usrreq() into
  easier to cut & paste functions tcp_debug_capture() and
tcp_debug_trace()

    - functions provided by rmind
    - remaining use of PRU_{PEER,SOCK}ADDR #define to be removed in a
      future commit.

* rename netbt functions to permit consistency of pru function names
  (as has been done with other requests already split out).

    - l2cap_{peer,sock}addr()  -> l2cap_{peer,sock}_addr_pcb()
    - rfcomm_{peer,sock}addr() -> rfcomm_{peer,sock}_addr_pcb()
    - sco_{peer,sock}addr()    -> sco_{peer,sock}_addr_pcb()

* split/refactor do_sys_getsockname(lwp, fd, which, nam) into
  two functions do_sys_get{peer,sock}name(fd, nam).

    - move PRU_PEERADDR handling into do_sys_getpeername() from
      do_sys_getsockname()
    - have svr4_stream directly call do_sys_get{sock,peer}name()
      respectively instead of providing `which' & fix a DPRINTF string
      that incorrectly wrote "getpeername" when it meant "getsockname"
    - fix sys_getpeername() and sys_getsockname() to call
      do_sys_get{sock,peer}name() without `which' and `lwp' & adjust
      comments
    - bump kernel version for removal of lwp & which parameters from
      do_sys_getsockname()

note: future cleanup to remove struct mbuf * abuse in
xxx_{peer,sock}name()
still to come, not done in this commit since it is easier to do post
split.

patch reviewed by rmind

welcome to 6.99.47

Revision 1.131 / (download) - annotate - [select for diffs], Mon Jul 7 17:13:56 2014 UTC (3 months, 3 weeks ago) by rtr
Branch: MAIN
Changes since 1.130: +4 -2 lines
Diff to previous 1.130 (colored) to selected 1.23 (colored)

* sprinkle KASSERT(solocked(so)); in all pr_stat() functions.
* fix remaining inconsistent struct socket parameter names.

Revision 1.130 / (download) - annotate - [select for diffs], Mon Jul 7 15:13:21 2014 UTC (3 months, 3 weeks ago) by rtr
Branch: MAIN
Changes since 1.129: +4 -3 lines
Diff to previous 1.129 (colored) to selected 1.23 (colored)

backout change that made pr_stat return EOPNOTSUPP for protocols that
were not filling in struct stat.

decision made after further discussion with rmind and investigation of
how other operating systems behave.  soo_stat() is doing just enough to
be able to call what gets returned valid and thus justifys a return of
success.

additional review will be done to determine of the pr_stat functions
that were already returning EOPNOTSUPP can be considered successful with
what soo_stat() is doing.

Revision 1.129 / (download) - annotate - [select for diffs], Mon Jul 7 07:09:58 2014 UTC (3 months, 3 weeks ago) by rtr
Branch: MAIN
Changes since 1.128: +3 -10 lines
Diff to previous 1.128 (colored) to selected 1.23 (colored)

* have pr_stat return EOPNOTSUPP consistently for all protocols that do
  not fill in struct stat instead of returning success.

* in pr_stat remove all checks for non-NULL so->so_pcb except where the
  pcb is actually used (i.e. cases where we don't return EOPNOTSUPP).

proposed on tech-net@

Revision 1.128 / (download) - annotate - [select for diffs], Sun Jul 6 03:33:33 2014 UTC (3 months, 3 weeks ago) by rtr
Branch: MAIN
Changes since 1.127: +18 -9 lines
Diff to previous 1.127 (colored) to selected 1.23 (colored)

* split PRU_SENSE functionality out of xxx_usrreq() switches and place into
  separate xxx_stat(struct socket *, struct stat *) functions.
* replace calls using pr_generic with req == PRU_SENSE with pr_stat().

further change will follow that cleans up the pattern used to extract the
pcb and test for its presence.

reviewed by rmind

Revision 1.127 / (download) - annotate - [select for diffs], Tue Jul 1 05:49:18 2014 UTC (4 months ago) by rtr
Branch: MAIN
Changes since 1.126: +4 -5 lines
Diff to previous 1.126 (colored) to selected 1.23 (colored)

fix parameter types in pr_ioctl, called xx_control() functions and remove
abuse of pointer to struct mbuf type.

param2 changed to u_long type and uses parameter name 'cmd' (ioctl command)
param3 changed to void * type and uses parameter name 'data'
param4 changed to struct ifnet * and uses parameter name 'ifp'
param5 has been removed (formerly struct lwp *) and uses of 'l' have been
       replaced with curlwp from curproc(9).

callers have had (now unnecessary) casts to struct mbuf * removed, called
code has had (now unnecessary) casts to u_long, void * and struct ifnet *
respectively removed.

reviewed by rmind@

Revision 1.126 / (download) - annotate - [select for diffs], Mon Jun 23 17:18:45 2014 UTC (4 months, 1 week ago) by rtr
Branch: MAIN
Changes since 1.125: +4 -4 lines
Diff to previous 1.125 (colored) to selected 1.23 (colored)

where appropriate rename xxx_ioctl() struct mbuf * parameters from
`control' to `ifp' after split from xxx_usrreq().

sys_socket.c
    fix wrapping of arguments to be consistent with other function calls
    in the file after replacing pr_usrreq() call with pr_ioctl() which
    required one less argument.

link_proto.c
    fix indentation of parameters in link_ioctl() prototype to be
    consistent with the rest of the file.

discussed with rmind@

Revision 1.125 / (download) - annotate - [select for diffs], Sun Jun 22 08:10:18 2014 UTC (4 months, 1 week ago) by rtr
Branch: MAIN
Changes since 1.124: +12 -5 lines
Diff to previous 1.124 (colored) to selected 1.23 (colored)

* split PRU_CONTROL functionality out of xxx_userreq() switches and place
  into separate xxx_ioctl() functions.
* place KASSERT(req != PRU_CONTROL) inside xxx_userreq() as it is now
  inappropriate for req = PRU_CONTROL in xxx_userreq().
* replace calls to pr_generic() with req = PRU_CONTROL with pr_ioctl().
* remove & fixup references to PRU_CONTROL xxx_userreq() function comments.
* fix various comments references for xxx_userreq() that mentioned
  PRU_CONTROL as xxx_userreq() no longer handles the request.

a further change will follow to fix parameter and naming inconsistencies
retained from original code.

Reviewed by rmind@

Revision 1.124 / (download) - annotate - [select for diffs], Fri May 30 01:39:03 2014 UTC (5 months ago) by christos
Branch: MAIN
Changes since 1.123: +6 -4 lines
Diff to previous 1.123 (colored) to selected 1.23 (colored)

Introduce 2 new variables: ipsec_enabled and ipsec_used.
Ipsec enabled is controlled by sysctl and determines if is allowed.
ipsec_used is set automatically based on ipsec being enabled, and
rules existing.

Revision 1.123 / (download) - annotate - [select for diffs], Thu May 22 23:42:53 2014 UTC (5 months, 1 week ago) by rmind
Branch: MAIN
Changes since 1.122: +9 -4 lines
Diff to previous 1.122 (colored) to selected 1.23 (colored)

- Make ip_setmoptions(), ip_getmoptions() and ip_pcbopts() static.
- ip_output: eliminate 7th variadic argument; IP_RETURNMTU is flag
  always used to store MTU size into struct inpcb::inp_errormtu.
- Clean up these routines: reduce #ifdefs, variable scopes, etc.

Revision 1.112.2.2 / (download) - annotate - [select for diffs], Thu May 22 11:41:10 2014 UTC (5 months, 1 week ago) by yamt
Branch: yamt-pagecache
Changes since 1.112.2.1: +12 -21 lines
Diff to previous 1.112.2.1 (colored) to branchpoint 1.112 (colored) next main 1.113 (colored) to selected 1.23 (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.122 / (download) - annotate - [select for diffs], Tue May 20 19:04:00 2014 UTC (5 months, 1 week ago) by rmind
Branch: MAIN
Changes since 1.121: +5 -4 lines
Diff to previous 1.121 (colored) to selected 1.23 (colored)

Adjust PR_WRAP_USRREQS() to include the attach/detach functions.
We still need the kernel-lock for some corner cases.

Revision 1.121 / (download) - annotate - [select for diffs], Mon May 19 02:51:25 2014 UTC (5 months, 1 week ago) by rmind
Branch: MAIN
Changes since 1.120: +70 -58 lines
Diff to previous 1.120 (colored) to selected 1.23 (colored)

- Split off PRU_ATTACH and PRU_DETACH logic into separate functions.
- Replace malloc with kmem and eliminate M_PCB while here.
- Sprinkle more asserts.

Revision 1.116.2.4 / (download) - annotate - [select for diffs], Sun May 18 17:46:13 2014 UTC (5 months, 1 week ago) by rmind
Branch: rmind-smpnet
Changes since 1.116.2.3: +6 -11 lines
Diff to previous 1.116.2.3 (colored) to branchpoint 1.116 (colored) next main 1.117 (colored) to selected 1.23 (colored)

sync with head

Revision 1.120 / (download) - annotate - [select for diffs], Sun May 18 14:46:16 2014 UTC (5 months, 1 week ago) by rmind
Branch: MAIN
CVS Tags: rmind-smpnet-nbase, rmind-smpnet-base
Changes since 1.119: +10 -2 lines
Diff to previous 1.119 (colored) to selected 1.23 (colored)

Add struct pr_usrreqs with a pr_generic function and prepare for the
dismantling of pr_usrreq in the protocols; no functional change intended.
PRU_ATTACH/PRU_DETACH changes will follow soon.

Bump for struct protosw.  Welcome to 6.99.62!

Revision 1.119 / (download) - annotate - [select for diffs], Sun May 18 00:10:11 2014 UTC (5 months, 2 weeks ago) by rmind
Branch: MAIN
Changes since 1.118: +4 -4 lines
Diff to previous 1.118 (colored) to selected 1.23 (colored)

Use IFNET_FIRST() rather than open coding ifnet access.

Revision 1.118 / (download) - annotate - [select for diffs], Tue Feb 25 18:30:12 2014 UTC (8 months ago) by pooka
Branch: MAIN
CVS Tags: yamt-pagecache-base9, riastradh-xf86-video-intel-2-7-1-pre-2-21-15, riastradh-drm2-base3
Branch point for: tls-earlyentropy
Changes since 1.117: +2 -7 lines
Diff to previous 1.117 (colored) to selected 1.23 (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.117 / (download) - annotate - [select for diffs], Sat Nov 23 14:20:21 2013 UTC (11 months, 1 week ago) by christos
Branch: MAIN
Changes since 1.116: +6 -8 lines
Diff to previous 1.116 (colored) to selected 1.23 (colored)

convert from CIRCLEQ to TAILQ.

Revision 1.116.2.3 / (download) - annotate - [select for diffs], Mon Sep 23 00:57:53 2013 UTC (13 months, 1 week ago) by rmind
Branch: rmind-smpnet
Changes since 1.116.2.2: +3 -2 lines
Diff to previous 1.116.2.2 (colored) to branchpoint 1.116 (colored) to selected 1.23 (colored)

- Add some initial locking to the IPv4 PCB.
- Rename inpcb_lookup_*() routines to be more accurate and add comments.
- Add some comments about connection life-cycle WRT socket layer.

Revision 1.116.2.2 / (download) - annotate - [select for diffs], Wed Aug 28 15:21:48 2013 UTC (14 months ago) by rmind
Branch: rmind-smpnet
Changes since 1.116.2.1: +65 -38 lines
Diff to previous 1.116.2.1 (colored) to branchpoint 1.116 (colored) to selected 1.23 (colored)

Checkpoint work in progress:
- Initial split of the protocol user-request method into the following
  methods: pr_attach, pr_detach and pr_generic for old the pr_usrreq.
- Adjust socreate(9) and sonewconn(9) to call pr_attach without the
  socket lock held (as a preparation for the locking scheme adjustment).
- Adjust all pr_attach routines to assert that PCB is not set.
- Sprinkle various comments, document some routines and their locking.
- Remove M_PCB, replace with kmem(9).
- Fix few bugs spotted on the way.

Revision 1.116.2.1 / (download) - annotate - [select for diffs], Wed Jul 17 03:16:31 2013 UTC (15 months, 2 weeks ago) by rmind
Branch: rmind-smpnet
Changes since 1.116: +265 -257 lines
Diff to previous 1.116 (colored) to selected 1.23 (colored)

Checkpoint work in progress:
- Move PCB structures under __INPCB_PRIVATE, adjust most of the callers
  and thus make IPv4 PCB structures mostly opaque.  Any volunteers for
  merging in6pcb with inpcb (see rpaulo-netinet-merge-pcb branch)?
- Move various global vars to the modules where they belong, make them static.
- Some preliminary work for IPv4 PCB locking scheme.
- Make raw IP code mostly MP-safe.  Simplify some of it.
- Rework "fast" IP forwarding (ipflow) code to be mostly MP-safe.  It should
  run from a software interrupt, rather than hard.
- Rework tun(4) pseudo interface to be MP-safe.
- Work towards making some other interfaces more strict.

Revision 1.114.2.2 / (download) - annotate - [select for diffs], Sun Jun 23 06:20:25 2013 UTC (16 months, 1 week ago) by tls
Branch: tls-maxphys
Changes since 1.114.2.1: +6 -6 lines
Diff to previous 1.114.2.1 (colored) to branchpoint 1.114 (colored) to selected 1.23 (colored)

resync from head

Revision 1.116 / (download) - annotate - [select for diffs], Wed Jun 5 19:01:26 2013 UTC (16 months, 3 weeks ago) by christos
Branch: MAIN
CVS Tags: riastradh-drm2-base2, riastradh-drm2-base1, riastradh-drm2-base, riastradh-drm2
Branch point for: rmind-smpnet
Changes since 1.115: +6 -6 lines
Diff to previous 1.115 (colored) to selected 1.23 (colored)

IPSEC has not come in two speeds for a long time now (IPSEC == kame,
FAST_IPSEC). Make everything refer to IPSEC to avoid confusion.

Revision 1.114.2.1 / (download) - annotate - [select for diffs], Mon Feb 25 00:30:05 2013 UTC (20 months ago) by tls
Branch: tls-maxphys
Changes since 1.114: +4 -6 lines
Diff to previous 1.114 (colored) to selected 1.23 (colored)

resync with head

Revision 1.115 / (download) - annotate - [select for diffs], Tue Feb 5 17:30:02 2013 UTC (20 months, 3 weeks ago) by joerg
Branch: MAIN
CVS Tags: khorben-n900, agc-symver-base, agc-symver
Changes since 1.114: +4 -6 lines
Diff to previous 1.114 (colored) to selected 1.23 (colored)

Remove remnants of AF_IMPLINK.

Revision 1.112.2.1 / (download) - annotate - [select for diffs], Tue Apr 17 00:08:41 2012 UTC (2 years, 6 months ago) by yamt
Branch: yamt-pagecache
CVS Tags: yamt-pagecache-tag8
Changes since 1.112: +4 -9 lines
Diff to previous 1.112 (colored) to selected 1.23 (colored)

sync with head

Revision 1.112.6.2 / (download) - annotate - [select for diffs], Thu Apr 5 21:33:44 2012 UTC (2 years, 6 months ago) by mrg
Branch: jmcneill-usbmp
Changes since 1.112.6.1: +4 -9 lines
Diff to previous 1.112.6.1 (colored) to branchpoint 1.112 (colored) next main 1.113 (colored) to selected 1.23 (colored)

sync to latest -current.

Revision 1.114 / (download) - annotate - [select for diffs], Thu Mar 22 20:34:39 2012 UTC (2 years, 7 months ago) by drochner
Branch: MAIN
CVS Tags: yamt-pagecache-base8, yamt-pagecache-base7, yamt-pagecache-base6, yamt-pagecache-base5, yamt-pagecache-base4, jmcneill-usbmp-base9, jmcneill-usbmp-base8, jmcneill-usbmp-base10
Branch point for: tls-maxphys
Changes since 1.113: +4 -9 lines
Diff to previous 1.113 (colored) to selected 1.23 (colored)

remove KAME IPSEC, replaced by FAST_IPSEC

Revision 1.112.6.1 / (download) - annotate - [select for diffs], Sat Feb 18 07:35:39 2012 UTC (2 years, 8 months ago) by mrg
Branch: jmcneill-usbmp
Changes since 1.112: +6 -6 lines
Diff to previous 1.112 (colored) to selected 1.23 (colored)

merge to -current.

Revision 1.113 / (download) - annotate - [select for diffs], Mon Dec 19 11:59:57 2011 UTC (2 years, 10 months ago) by drochner
Branch: MAIN
CVS Tags: 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, jmcneill-usbmp-base7, jmcneill-usbmp-base6, jmcneill-usbmp-base5, jmcneill-usbmp-base4, jmcneill-usbmp-base3, jmcneill-usbmp-base2
Changes since 1.112: +6 -6 lines
Diff to previous 1.112 (colored) to selected 1.23 (colored)

rename the IPSEC in-kernel CPP variable and config(8) option to
KAME_IPSEC, and make IPSEC define it so that existing kernel
config files work as before
Now the default can be easily be changed to FAST_IPSEC just by
setting the IPSEC alias to FAST_IPSEC.

Revision 1.112 / (download) - annotate - [select for diffs], Sun Jul 17 20:54:53 2011 UTC (3 years, 3 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.111: +2 -4 lines
Diff to previous 1.111 (colored) to selected 1.23 (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.107.2.2 / (download) - annotate - [select for diffs], Thu Mar 11 15:04:28 2010 UTC (4 years, 7 months ago) by yamt
Branch: yamt-nfs-mp
Changes since 1.107.2.1: +9 -6 lines
Diff to previous 1.107.2.1 (colored) to branchpoint 1.107 (colored) next main 1.108 (colored) to selected 1.23 (colored)

sync with head

Revision 1.111 / (download) - annotate - [select for diffs], Wed Dec 9 00:45:25 2009 UTC (4 years, 10 months ago) by dyoung
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, jruoho-x86intr-base, jruoho-x86intr, cherry-xenmp-base, cherry-xenmp, bouyer-quota2-nbase, bouyer-quota2-base, bouyer-quota2
Changes since 1.110: +4 -5 lines
Diff to previous 1.110 (colored) to selected 1.23 (colored)

Remove superfluous cast of a pointer to void *.

Compare a pointer with NULL, not 0.

No functional change intended.

Revision 1.110 / (download) - annotate - [select for diffs], Wed Sep 16 15:23:05 2009 UTC (5 years, 1 month ago) by pooka
Branch: MAIN
CVS Tags: jym-xensuspend-nbase
Changes since 1.109: +7 -3 lines
Diff to previous 1.109 (colored) to selected 1.23 (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.107.2.1 / (download) - annotate - [select for diffs], Mon May 4 08:14:17 2009 UTC (5 years, 5 months ago) by yamt
Branch: yamt-nfs-mp
Changes since 1.107: +44 -35 lines
Diff to previous 1.107 (colored) to selected 1.23 (colored)

sync with head.

Revision 1.108.2.1 / (download) - annotate - [select for diffs], Mon Jan 19 13:20:13 2009 UTC (5 years, 9 months ago) by skrll
Branch: nick-hppapmap
Changes since 1.108: +12 -4 lines
Diff to previous 1.108 (colored) next main 1.109 (colored) to selected 1.23 (colored)

Sync with HEAD.

Revision 1.109 / (download) - annotate - [select for diffs], Mon Jan 19 02:27:57 2009 UTC (5 years, 9 months ago) by christos
Branch: MAIN
CVS Tags: yamt-nfs-mp-base8, yamt-nfs-mp-base7, yamt-nfs-mp-base6, yamt-nfs-mp-base5, yamt-nfs-mp-base4, yamt-nfs-mp-base3, nick-hppapmap-base4, nick-hppapmap-base3, nick-hppapmap-base2, nick-hppapmap-base, jymxensuspend-base, jym-xensuspend-base, jym-xensuspend
Changes since 1.108: +12 -4 lines
Diff to previous 1.108 (colored) to selected 1.23 (colored)

Provide compatibility to the old timeval SCM_TIMESTAMP messages.

Revision 1.107.8.1 / (download) - annotate - [select for diffs], Sun Oct 19 22:17:46 2008 UTC (6 years ago) by haad
Branch: haad-dm
Changes since 1.107: +34 -33 lines
Diff to previous 1.107 (colored) next main 1.108 (colored) to selected 1.23 (colored)

Sync with HEAD.

Revision 1.103.6.2 / (download) - annotate - [select for diffs], Sun Sep 28 10:40:58 2008 UTC (6 years, 1 month ago) by mjf
Branch: mjf-devfs2
Changes since 1.103.6.1: +32 -31 lines
Diff to previous 1.103.6.1 (colored) to branchpoint 1.103 (colored) next main 1.104 (colored) to selected 1.23 (colored)

Sync with HEAD.

Revision 1.107.4.1 / (download) - annotate - [select for diffs], Thu Sep 18 04:37:01 2008 UTC (6 years, 1 month ago) by wrstuden
Branch: wrstuden-revivesa
Changes since 1.107: +34 -33 lines
Diff to previous 1.107 (colored) next main 1.108 (colored) to selected 1.23 (colored)

Sync with wrstuden-revivesa-base-2.

Revision 1.108 / (download) - annotate - [select for diffs], Wed Aug 6 15:01:23 2008 UTC (6 years, 2 months ago) by plunky
Branch: MAIN
CVS Tags: wrstuden-revivesa-base-4, wrstuden-revivesa-base-3, wrstuden-revivesa-base-2, netbsd-5-base, netbsd-5-2-RELEASE, netbsd-5-2-RC1, 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-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, haad-nbase2, haad-dm-base2, haad-dm-base1, haad-dm-base, ad-audiomp2-base, ad-audiomp2
Branch point for: nick-hppapmap
Changes since 1.107: +34 -33 lines
Diff to previous 1.107 (colored) to selected 1.23 (colored)

Convert socket options code to use a sockopt structure
instead of laying everything into an mbuf.

approved by core

Revision 1.103.6.1 / (download) - annotate - [select for diffs], Mon Jun 2 13:24:24 2008 UTC (6 years, 4 months ago) by mjf
Branch: mjf-devfs2
Changes since 1.103: +21 -11 lines
Diff to previous 1.103 (colored) to selected 1.23 (colored)

Sync with HEAD.

Revision 1.105.2.1 / (download) - annotate - [select for diffs], Sun May 18 12:35:29 2008 UTC (6 years, 5 months ago) by yamt
Branch: yamt-pf42
Changes since 1.105: +12 -7 lines
Diff to previous 1.105 (colored) next main 1.106 (colored) to selected 1.23 (colored)

sync with head.

Revision 1.107 / (download) - annotate - [select for diffs], Thu Apr 24 11:38:38 2008 UTC (6 years, 6 months ago) by ad
Branch: MAIN
CVS Tags: yamt-pf42-base4, yamt-pf42-base3, yamt-pf42-base2, yamt-nfs-mp-base2, yamt-nfs-mp-base, wrstuden-revivesa-base-1, wrstuden-revivesa-base, simonb-wapbl-nbase, simonb-wapbl-base, simonb-wapbl, hpcarm-cleanup-nbase
Branch point for: yamt-nfs-mp, wrstuden-revivesa, haad-dm
Changes since 1.106: +5 -2 lines
Diff to previous 1.106 (colored) to selected 1.23 (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.106 / (download) - annotate - [select for diffs], Wed Apr 23 06:09:04 2008 UTC (6 years, 6 months ago) by thorpej
Branch: MAIN
Changes since 1.105: +9 -7 lines
Diff to previous 1.105 (colored) to selected 1.23 (colored)

Make IPSEC and FAST_IPSEC stats per-cpu.  Use <net/net_stats.h> and
netstat_sysctl().

Revision 1.105 / (download) - annotate - [select for diffs], Sat Apr 12 05:58:22 2008 UTC (6 years, 6 months ago) by thorpej
Branch: MAIN
CVS Tags: yamt-pf42-baseX, yamt-pf42-base
Branch point for: yamt-pf42
Changes since 1.104: +11 -6 lines
Diff to previous 1.104 (colored) to selected 1.23 (colored)

Make IP, TCP, UDP, and ICMP statistics per-CPU.  The stats are collated
when the user requests them via sysctl.

Revision 1.104 / (download) - annotate - [select for diffs], Mon Apr 7 06:31:28 2008 UTC (6 years, 6 months ago) by thorpej
Branch: MAIN
Changes since 1.103: +6 -6 lines
Diff to previous 1.103 (colored) to selected 1.23 (colored)

Change IP stats from a structure to an array of uint64_t's.

Note: This is ABI-compatible with the old ipstat structure; old netstat
binaries will continue to work properly.

Revision 1.97.8.3 / (download) - annotate - [select for diffs], Sun Mar 23 02:05:06 2008 UTC (6 years, 7 months ago) by matt
Branch: matt-armv6
Changes since 1.97.8.2: +4 -4 lines
Diff to previous 1.97.8.2 (colored) to branchpoint 1.97 (colored) next main 1.98 (colored) to selected 1.23 (colored)

sync with HEAD

Revision 1.100.6.3 / (download) - annotate - [select for diffs], Mon Feb 18 21:07:08 2008 UTC (6 years, 8 months ago) by mjf
Branch: mjf-devfs
Changes since 1.100.6.2: +4 -4 lines
Diff to previous 1.100.6.2 (colored) to branchpoint 1.100 (colored) next main 1.101 (colored) to selected 1.23 (colored)

Sync with HEAD.

Revision 1.87.2.8 / (download) - annotate - [select for diffs], Mon Feb 11 15:00:05 2008 UTC (6 years, 8 months ago) by yamt
Branch: yamt-lazymbuf
Changes since 1.87.2.7: +4 -4 lines
Diff to previous 1.87.2.7 (colored) to branchpoint 1.87 (colored) next main 1.88 (colored) to selected 1.23 (colored)

sync with head.

Revision 1.103 / (download) - annotate - [select for diffs], Wed Feb 6 03:20:52 2008 UTC (6 years, 8 months ago) by matt
Branch: MAIN
CVS Tags: yamt-lazymbuf-base15, yamt-lazymbuf-base14, nick-net80211-sync-base, nick-net80211-sync, mjf-devfs-base, matt-armv6-nbase, keiichi-mipv6-nbase, keiichi-mipv6-base, keiichi-mipv6, hpcarm-cleanup-base, ad-socklock-base1
Branch point for: mjf-devfs2
Changes since 1.102: +4 -4 lines
Diff to previous 1.102 (colored) to selected 1.23 (colored)

Add a new ip_id generation scheme based on a Fisher-Yates shuffle over a
sliding window.  XXX replace use of arc4random RSN.

Revision 1.87.2.7 / (download) - annotate - [select for diffs], Mon Jan 21 09:47:17 2008 UTC (6 years, 9 months ago) by yamt
Branch: yamt-lazymbuf
Changes since 1.87.2.6: +3 -3 lines
Diff to previous 1.87.2.6 (colored) to branchpoint 1.87 (colored) to selected 1.23 (colored)

sync with head

Revision 1.97.8.2 / (download) - annotate - [select for diffs], Wed Jan 9 01:57:29 2008 UTC (6 years, 9 months ago) by matt
Branch: matt-armv6
Changes since 1.97.8.1: +5 -5 lines
Diff to previous 1.97.8.1 (colored) to branchpoint 1.97 (colored) to selected 1.23 (colored)

sync with HEAD

Revision 1.101.6.1 / (download) - annotate - [select for diffs], Wed Jan 2 21:57:23 2008 UTC (6 years, 9 months ago) by bouyer
Branch: bouyer-xeni386
CVS Tags: bouyer-xeni386-merge1
Changes since 1.101: +3 -3 lines
Diff to previous 1.101 (colored) next main 1.102 (colored) to selected 1.23 (colored)

Sync with HEAD

Revision 1.100.6.2 / (download) - annotate - [select for diffs], Thu Dec 27 00:46:31 2007 UTC (6 years, 10 months ago) by mjf
Branch: mjf-devfs
Changes since 1.100.6.1: +3 -3 lines
Diff to previous 1.100.6.1 (colored) to branchpoint 1.100 (colored) to selected 1.23 (colored)

Sync with HEAD.

Revision 1.101.2.1 / (download) - annotate - [select for diffs], Wed Dec 26 19:57:41 2007 UTC (6 years, 10 months ago) by ad
Branch: vmlocking2
Changes since 1.101: +3 -3 lines
Diff to previous 1.101 (colored) next main 1.102 (colored) to selected 1.23 (colored)

Sync with head.

Revision 1.102 / (download) - annotate - [select for diffs], Fri Dec 21 02:07:55 2007 UTC (6 years, 10 months ago) by matt
Branch: MAIN
CVS Tags: vmlocking2-base3, matt-armv6-base, bouyer-xeni386-nbase, bouyer-xeni386-base
Changes since 1.101: +3 -3 lines
Diff to previous 1.101 (colored) to selected 1.23 (colored)

Add fix for ip_id information leakage.  Since the leakage information is
primarily used with TCP SYN and RST packets and such packets are less than
the smallest sized packet that an IP stack is allowed to fragment, we simply
set ip_id to 0 for all packets 68 bytes or less.

Revision 1.100.6.1 / (download) - annotate - [select for diffs], Sat Dec 8 18:21:14 2007 UTC (6 years, 10 months ago) by mjf
Branch: mjf-devfs
Changes since 1.100: +4 -4 lines
Diff to previous 1.100 (colored) to selected 1.23 (colored)

Sync with HEAD.

Revision 1.87.2.6 / (download) - annotate - [select for diffs], Fri Dec 7 17:34:32 2007 UTC (6 years, 10 months ago) by yamt
Branch: yamt-lazymbuf
Changes since 1.87.2.5: +4 -4 lines
Diff to previous 1.87.2.5 (colored) to branchpoint 1.87 (colored) to selected 1.23 (colored)

sync with head

Revision 1.97.6.3 / (download) - annotate - [select for diffs], Mon Dec 3 16:15:10 2007 UTC (6 years, 10 months ago) by joerg
Branch: jmcneill-pm
Changes since 1.97.6.2: +4 -4 lines
Diff to previous 1.97.6.2 (colored) to branchpoint 1.97 (colored) next main 1.98 (colored) to selected 1.23 (colored)

Sync with HEAD.

Revision 1.101 / (download) - annotate - [select for diffs], Tue Nov 27 22:45:29 2007 UTC (6 years, 11 months ago) by christos
Branch: MAIN
CVS Tags: yamt-kmem-base3, yamt-kmem-base2, yamt-kmem-base, yamt-kmem, vmlocking2-base2, vmlocking2-base1, vmlocking-nbase, reinoud-bufcleanup-nbase, reinoud-bufcleanup-base, jmcneill-pm-base, cube-autoconf-base, cube-autoconf
Branch point for: vmlocking2, bouyer-xeni386
Changes since 1.100: +4 -4 lines
Diff to previous 1.100 (colored) to selected 1.23 (colored)

require that the options argument is the right size, not that it is greater
or equal to the requested size. Suggested by Matt Thomas.

Revision 1.97.8.1 / (download) - annotate - [select for diffs], Tue Nov 6 23:33:51 2007 UTC (6 years, 11 months ago) by matt
Branch: matt-armv6
CVS Tags: matt-armv6-prevmlocking
Changes since 1.97: +58 -48 lines
Diff to previous 1.97 (colored) to selected 1.23 (colored)

sync with HEAD

Revision 1.87.2.5 / (download) - annotate - [select for diffs], Sat Oct 27 11:36:09 2007 UTC (7 years ago) by yamt
Branch: yamt-lazymbuf
Changes since 1.87.2.4: +57 -47 lines
Diff to previous 1.87.2.4 (colored) to branchpoint 1.87 (colored) to selected 1.23 (colored)

sync with head.

Revision 1.96.2.2 / (download) - annotate - [select for diffs], Tue Oct 9 13:44:51 2007 UTC (7 years ago) by ad
Branch: vmlocking
Changes since 1.96.2.1: +58 -48 lines
Diff to previous 1.96.2.1 (colored) to branchpoint 1.96 (colored) next main 1.97 (colored) to selected 1.23 (colored)

Sync with head.

Revision 1.97.6.2 / (download) - annotate - [select for diffs], Tue Oct 2 18:29:20 2007 UTC (7 years, 1 month ago) by joerg
Branch: jmcneill-pm
Changes since 1.97.6.1: +57 -47 lines
Diff to previous 1.97.6.1 (colored) to branchpoint 1.97 (colored) to selected 1.23 (colored)

Sync with HEAD.

Revision 1.100 / (download) - annotate - [select for diffs], Wed Sep 19 04:33:43 2007 UTC (7 years, 1 month ago) by dyoung
Branch: MAIN
CVS Tags: yamt-x86pmap-base4, yamt-x86pmap-base3, yamt-x86pmap-base2, yamt-x86pmap-base, yamt-x86pmap, vmlocking-base, jmcneill-base, bouyer-xenamd64-base2, bouyer-xenamd64-base, bouyer-xenamd64
Branch point for: mjf-devfs
Changes since 1.99: +57 -47 lines
Diff to previous 1.99 (colored) to selected 1.23 (colored)

1) Introduce a new socket option, (SOL_SOCKET, SO_NOHEADER), that
   tells a socket that it should both add a protocol header to tx'd
   datagrams and remove the header from rx'd datagrams:

        int onoff = 1, s = socket(...);
        setsockopt(s, SOL_SOCKET, SO_NOHEADER, &onoff);

2) Add an implementation of (SOL_SOCKET, SO_NOHEADER) for raw IPv4
   sockets.

3) Reorganize the protocols' pr_ctloutput implementations a bit.
   Consistently return ENOPROTOOPT when an option is unsupported,
   and EINVAL if a supported option's arguments are incorrect.
   Reorganize the flow of code so that it's more clear how/when
   options are passed down the stack until they are handled.

   Shorten some pr_ctloutput staircases for readability.

4) Extract common mbuf code into subroutines, add new sockaddr
   methods, and introduce a new subroutine, fsocreate(), for reuse
   later; use it first in sys_socket():

struct mbuf *m_getsombuf(struct socket *so)

        Create an mbuf and make its owner the socket `so'.

struct mbuf *m_intopt(struct socket *so, int val)

        Create an mbuf, make its owner the socket `so', put the
        int `val' into it, and set its length to sizeof(int).


int fsocreate(..., int *fd)

        Create a socket, a la socreate(9), put the socket into the
        given LWP's descriptor table, return the descriptor at `fd'
        on success.

void *sockaddr_addr(struct sockaddr *sa, socklen_t *slenp)
const void *sockaddr_const_addr(const struct sockaddr *sa, socklen_t *slenp)

        Extract a pointer to the address part of a sockaddr.  Write
        the length of the address  part at `slenp', if `slenp' is
        not NULL.

socklen_t sockaddr_getlen(const struct sockaddr *sa)

        Return the length of a sockaddr.  This just evaluates to
        sa->sa_len.  I only add this for consistency with code that
        appears in a portable userland library that I am going to
        import.

const struct sockaddr *sockaddr_any(const struct sockaddr *sa)

        Return the "don't care" sockaddr in the same family as
        `sa'.  This is the address a client should sobind(9) if it
        does not care the source address and, if applicable, the
        port et cetera that it uses.

const void *sockaddr_anyaddr(const struct sockaddr *sa, socklen_t *slenp)

        Return the "don't care" sockaddr in the same family as
        `sa'.  This is the address a client should sobind(9) if it
        does not care the source address and, if applicable, the
        port et cetera that it uses.

Revision 1.97.6.1 / (download) - annotate - [select for diffs], Mon Sep 3 16:49:06 2007 UTC (7 years, 1 month ago) by jmcneill
Branch: jmcneill-pm
Changes since 1.97: +3 -3 lines
Diff to previous 1.97 (colored) to selected 1.23 (colored)

Sync with HEAD.

Revision 1.87.2.4 / (download) - annotate - [select for diffs], Mon Sep 3 14:43:00 2007 UTC (7 years, 1 month ago) by yamt
Branch: yamt-lazymbuf
Changes since 1.87.2.3: +35 -43 lines
Diff to previous 1.87.2.3 (colored) to branchpoint 1.87 (colored) to selected 1.23 (colored)

sync with head.

Revision 1.97.2.1 / (download) - annotate - [select for diffs], Mon Sep 3 10:23:46 2007 UTC (7 years, 1 month ago) by skrll
Branch: nick-csl-alignment
Changes since 1.97: +3 -3 lines
Diff to previous 1.97 (colored) next main 1.98 (colored) to selected 1.23 (colored)

Sync with HEAD.

Revision 1.99 / (download) - annotate - [select for diffs], Sun Sep 2 07:18:55 2007 UTC (7 years, 2 months ago) by dyoung
Branch: MAIN
CVS Tags: nick-csl-alignment-base5
Changes since 1.98: +3 -3 lines
Diff to previous 1.98 (colored) to selected 1.23 (colored)

m_copym(..., 0, M_COPYALL, ...) -> m_copypacket(..., ...).

Revision 1.98 / (download) - annotate - [select for diffs], Sun Sep 2 03:12:23 2007 UTC (7 years, 2 months ago) by dyoung
Branch: MAIN
Changes since 1.97: +3 -3 lines
Diff to previous 1.97 (colored) to selected 1.23 (colored)

m_copy() was deprecated, apparently, long ago.  m_copy(...) ->
m_copym(..., M_DONTWAIT).

Revision 1.96.4.1 / (download) - annotate - [select for diffs], Wed Jul 11 20:11:26 2007 UTC (7 years, 3 months ago) by mjf
Branch: mjf-ufs-trans
Changes since 1.96: +34 -42 lines
Diff to previous 1.96 (colored) next main 1.97 (colored) to selected 1.23 (colored)

Sync with head.

Revision 1.96.2.1 / (download) - annotate - [select for diffs], Fri Jun 8 14:17:47 2007 UTC (7 years, 4 months ago) by ad
Branch: vmlocking
Changes since 1.96: +34 -42 lines
Diff to previous 1.96 (colored) to selected 1.23 (colored)

Sync with head.

Revision 1.94.4.3 / (download) - annotate - [select for diffs], Thu May 17 13:41:50 2007 UTC (7 years, 5 months ago) by yamt
Branch: yamt-idlelwp
Changes since 1.94.4.2: +34 -42 lines
Diff to previous 1.94.4.2 (colored) to branchpoint 1.94 (colored) next main 1.95 (colored) to selected 1.23 (colored)

sync with head.

Revision 1.97 / (download) - annotate - [select for diffs], Sat May 12 02:10:25 2007 UTC (7 years, 5 months ago) by dyoung
Branch: MAIN
CVS Tags: yamt-idlelwp-base8, nick-csl-alignment-base, mjf-ufs-trans-base, matt-mips64-base, matt-mips64, hpcarm-cleanup
Branch point for: nick-csl-alignment, matt-armv6, jmcneill-pm
Changes since 1.96: +34 -42 lines
Diff to previous 1.96 (colored) to selected 1.23 (colored)

KNF.  Use sockaddr_in_init().  Shorten staircases.  No functional
changes intended.

Revision 1.94.4.2 / (download) - annotate - [select for diffs], Mon Mar 12 05:59:38 2007 UTC (7 years, 7 months ago) by rmind
Branch: yamt-idlelwp
Changes since 1.94.4.1: +4 -4 lines
Diff to previous 1.94.4.1 (colored) to branchpoint 1.94 (colored) to selected 1.23 (colored)

Sync with HEAD.

Revision 1.96 / (download) - annotate - [select for diffs], Sun Mar 4 06:03:21 2007 UTC (7 years, 7 months ago) by christos
Branch: MAIN
CVS Tags: thorpej-atomic-base, thorpej-atomic, reinoud-bufcleanup
Branch point for: vmlocking, mjf-ufs-trans
Changes since 1.95: +4 -4 lines
Diff to previous 1.95 (colored) to selected 1.23 (colored)

Kill caddr_t; there will be some MI fallout, but it will be fixed shortly.

Revision 1.94.4.1 / (download) - annotate - [select for diffs], Tue Feb 27 16:54:56 2007 UTC (7 years, 8 months ago) by yamt
Branch: yamt-idlelwp
Changes since 1.94: +5 -5 lines
Diff to previous 1.94 (colored) to selected 1.23 (colored)

- sync with head.
- move sched_changepri back to kern_synch.c as it doesn't know PPQ anymore.

Revision 1.87.2.3 / (download) - annotate - [select for diffs], Mon Feb 26 09:11:45 2007 UTC (7 years, 8 months ago) by yamt
Branch: yamt-lazymbuf
Changes since 1.87.2.2: +5 -5 lines
Diff to previous 1.87.2.2 (colored) to branchpoint 1.87 (colored) to selected 1.23 (colored)

sync with head.

Revision 1.95 / (download) - annotate - [select for diffs], Sat Feb 17 22:34:12 2007 UTC (7 years, 8 months ago) by dyoung
Branch: MAIN
CVS Tags: ad-audiomp-base, ad-audiomp
Changes since 1.94: +5 -5 lines
Diff to previous 1.94 (colored) to selected 1.23 (colored)

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.

Revision 1.87.2.2 / (download) - annotate - [select for diffs], Sat Dec 30 20:50:33 2006 UTC (7 years, 10 months ago) by yamt
Branch: yamt-lazymbuf
Changes since 1.87.2.1: +11 -8 lines
Diff to previous 1.87.2.1 (colored) to branchpoint 1.87 (colored) to selected 1.23 (colored)

sync with head.

Revision 1.91.2.2 / (download) - annotate - [select for diffs], Sun Dec 10 07:19:11 2006 UTC (7 years, 10 months ago) by yamt
Branch: yamt-splraiseipl
Changes since 1.91.2.1: +7 -6 lines
Diff to previous 1.91.2.1 (colored) to branchpoint 1.91 (colored) next main 1.92 (colored) to selected 1.23 (colored)

sync with head.

Revision 1.90.4.1 / (download) - annotate - [select for diffs], Sat Nov 18 21:39:36 2006 UTC (7 years, 11 months ago) by ad
Branch: newlock2
Changes since 1.90: +10 -5 lines
Diff to previous 1.90 (colored) next main 1.91 (colored) to selected 1.23 (colored)

Sync with head.

Revision 1.94 / (download) - annotate - [select for diffs], Wed Oct 25 22:49:23 2006 UTC (8 years ago) by elad
Branch: MAIN
CVS Tags: yamt-splraiseipl-base5, yamt-splraiseipl-base4, yamt-splraiseipl-base3, 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
Branch point for: yamt-idlelwp
Changes since 1.93: +7 -6 lines
Diff to previous 1.93 (colored) to selected 1.23 (colored)

Introduce KAUTH_REQ_NETWORK_SOCKET_OPEN, to check if opening a socket is
allowed. It takes three int * arguments indicating domain, type, and
protocol. Replace previous KAUTH_REQ_NETWORK_SOCKET_RAWSOCK with it (but
keep it still).

Places that used to explicitly check for privileged context now don't
need it anymore, so I replaced these with XXX comment indiacting it for
future reference.

Documented and updated examples as well.

Revision 1.91.2.1 / (download) - annotate - [select for diffs], Sun Oct 22 06:07:28 2006 UTC (8 years ago) by yamt
Branch: yamt-splraiseipl
Changes since 1.91: +6 -4 lines
Diff to previous 1.91 (colored) to selected 1.23 (colored)

sync with head

Revision 1.93 / (download) - annotate - [select for diffs], Thu Oct 5 17:35:19 2006 UTC (8 years ago) by tls
Branch: MAIN
CVS Tags: yamt-splraiseipl-base2
Changes since 1.92: +5 -3 lines
Diff to previous 1.92 (colored) to selected 1.23 (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.92 / (download) - annotate - [select for diffs], Tue Sep 19 21:42:30 2006 UTC (8 years, 1 month ago) by elad
Branch: MAIN
Changes since 1.91: +3 -3 lines
Diff to previous 1.91 (colored) to selected 1.23 (colored)

Remove ugly (void *) casts from network scope authorization wrapper and
calls to it.

While here, adapt code for system scope listeners to avoid some more
casts (forgotten in previous run).

Update documentation.

Revision 1.88.8.3 / (download) - annotate - [select for diffs], Thu Sep 14 12:31:55 2006 UTC (8 years, 1 month ago) by yamt
Branch: yamt-pdpolicy
Changes since 1.88.8.2: +6 -4 lines
Diff to previous 1.88.8.2 (colored) to branchpoint 1.88 (colored) next main 1.89 (colored) to selected 1.23 (colored)

sync with head.

Revision 1.88.4.2 / (download) - annotate - [select for diffs], Sat Sep 9 02:58:47 2006 UTC (8 years, 1 month ago) by rpaulo
Branch: rpaulo-netinet-merge-pcb
Changes since 1.88.4.1: +6 -6 lines
Diff to previous 1.88.4.1 (colored) to branchpoint 1.88 (colored) next main 1.89 (colored) to selected 1.23 (colored)

sync with head

Revision 1.91 / (download) - annotate - [select for diffs], Fri Sep 8 20:58:58 2006 UTC (8 years, 1 month ago) by elad
Branch: MAIN
CVS Tags: yamt-splraiseipl-base, yamt-pdpolicy-base9
Branch point for: yamt-splraiseipl
Changes since 1.90: +6 -4 lines
Diff to previous 1.90 (colored) to selected 1.23 (colored)

First take at security model abstraction.

- Add a few scopes to the kernel: system, network, and machdep.

- Add a few more actions/sub-actions (requests), and start using them as
  opposed to the KAUTH_GENERIC_ISSUSER place-holders.

- Introduce a basic set of listeners that implement our "traditional"
  security model, called "bsd44". This is the default (and only) model we
  have at the moment.

- Update all relevant documentation.

- Add some code and docs to help folks who want to actually use this stuff:

  * There's a sample overlay model, sitting on-top of "bsd44", for
    fast experimenting with tweaking just a subset of an existing model.

    This is pretty cool because it's *really* straightforward to do stuff
    you had to use ugly hacks for until now...

  * And of course, documentation describing how to do the above for quick
    reference, including code samples.

All of these changes were tested for regressions using a Python-based
testsuite that will be (I hope) available soon via pkgsrc. Information
about the tests, and how to write new ones, can be found on:

	http://kauth.linbsd.org/kauthwiki

NOTE FOR DEVELOPERS: *PLEASE* don't add any code that does any of the
following:

  - Uses a KAUTH_GENERIC_ISSUSER kauth(9) request,
  - Checks 'securelevel' directly,
  - Checks a uid/gid directly.

(or if you feel you have to, contact me first)

This is still work in progress; It's far from being done, but now it'll
be a lot easier.

Relevant mailing list threads:

http://mail-index.netbsd.org/tech-security/2006/01/25/0011.html
http://mail-index.netbsd.org/tech-security/2006/03/24/0001.html
http://mail-index.netbsd.org/tech-security/2006/04/18/0000.html
http://mail-index.netbsd.org/tech-security/2006/05/15/0000.html
http://mail-index.netbsd.org/tech-security/2006/08/01/0000.html
http://mail-index.netbsd.org/tech-security/2006/08/25/0000.html

Many thanks to YAMAMOTO Takashi, Matt Thomas, and Christos Zoulas for help
stablizing kauth(9).

Full credit for the regression tests, making sure these changes didn't break
anything, goes to Matt Fleming and Jaime Fournier.

Happy birthday Randi! :)

Revision 1.88.8.2 / (download) - annotate - [select for diffs], Fri Aug 11 15:46:33 2006 UTC (8 years, 2 months ago) by yamt
Branch: yamt-pdpolicy
Changes since 1.88.8.1: +5 -7 lines
Diff to previous 1.88.8.1 (colored) to branchpoint 1.88 (colored) to selected 1.23 (colored)

sync with head

Revision 1.90 / (download) - annotate - [select for diffs], Sun Jul 23 22:06:13 2006 UTC (8 years, 3 months ago) by ad
Branch: MAIN
CVS Tags: yamt-pdpolicy-base8, yamt-pdpolicy-base7, rpaulo-netinet-merge-pcb-base, abandoned-netbsd-4-base, abandoned-netbsd-4
Branch point for: newlock2
Changes since 1.89: +5 -7 lines
Diff to previous 1.89 (colored) to selected 1.23 (colored)

Use the LWP cached credentials where sane.

Revision 1.87.2.1 / (download) - annotate - [select for diffs], Wed Jun 21 15:11:01 2006 UTC (8 years, 4 months ago) by yamt
Branch: yamt-lazymbuf
Changes since 1.87: +8 -4 lines
Diff to previous 1.87 (colored) to selected 1.23 (colored)

sync with head.

Revision 1.88.6.1 / (download) - annotate - [select for diffs], Thu Jun 1 22:38:47 2006 UTC (8 years, 5 months ago) by kardel
Branch: simonb-timecounters
CVS Tags: simonb-timcounters-final
Changes since 1.88: +5 -3 lines
Diff to previous 1.88 (colored) next main 1.89 (colored) to selected 1.23 (colored)

Sync with head.

Revision 1.88.12.1 / (download) - annotate - [select for diffs], Wed May 24 15:50:45 2006 UTC (8 years, 5 months ago) by tron
Branch: peter-altq
Changes since 1.88: +5 -3 lines
Diff to previous 1.88 (colored) next main 1.89 (colored) to selected 1.23 (colored)

Merge 2006-05-24 NetBSD-current into the "peter-altq" branch.

Revision 1.88.8.1 / (download) - annotate - [select for diffs], Wed May 24 10:59:03 2006 UTC (8 years, 5 months ago) by yamt
Branch: yamt-pdpolicy
Changes since 1.88: +5 -3 lines
Diff to previous 1.88 (colored) to selected 1.23 (colored)

sync with head.

Revision 1.89 / (download) - annotate - [select for diffs], Sun May 14 21:19:34 2006 UTC (8 years, 5 months ago) by elad
Branch: MAIN
CVS Tags: yamt-pdpolicy-base6, yamt-pdpolicy-base5, simonb-timecounters-base, gdamore-uart-base, gdamore-uart, chap-midi-nbase, chap-midi-base, chap-midi
Changes since 1.88: +5 -3 lines
Diff to previous 1.88 (colored) to selected 1.23 (colored)

integrate kauth.

Revision 1.88.10.3 / (download) - annotate - [select for diffs], Sat May 6 23:32:11 2006 UTC (8 years, 5 months ago) by christos
Branch: elad-kernelauth
Changes since 1.88.10.2: +3 -2 lines
Diff to previous 1.88.10.2 (colored) to branchpoint 1.88 (colored) next main 1.89 (colored) to selected 1.23 (colored)

- Move kauth_cred_t declaration to <sys/types.h>
- Cleanup struct ucred; forward declarations that are unused.
- Don't include <sys/kauth.h> in any header, but include it in the c files
  that need it.

Approved by core.

Revision 1.88.10.2 / (download) - annotate - [select for diffs], Fri Mar 10 15:20:54 2006 UTC (8 years, 7 months ago) by elad
Branch: elad-kernelauth
Changes since 1.88.10.1: +3 -3 lines
Diff to previous 1.88.10.1 (colored) to branchpoint 1.88 (colored) to selected 1.23 (colored)

generic_authorize() -> kauth_authorize_generic().

Revision 1.88.10.1 / (download) - annotate - [select for diffs], Wed Mar 8 01:19:40 2006 UTC (8 years, 7 months ago) by elad
Branch: elad-kernelauth
Changes since 1.88: +4 -3 lines
Diff to previous 1.88 (colored) to selected 1.23 (colored)

Adapt to kernel authorization KPI.

Revision 1.88.4.1 / (download) - annotate - [select for diffs], Sun Feb 5 03:03:09 2006 UTC (8 years, 8 months ago) by rpaulo
Branch: rpaulo-netinet-merge-pcb
Changes since 1.88: +3 -5 lines
Diff to previous 1.88 (colored) to selected 1.23 (colored)

inpcb_hdr is gone.

Revision 1.88 / (download) - annotate - [select for diffs], Sun Dec 11 12:24:57 2005 UTC (8 years, 10 months ago) by christos
Branch: MAIN
CVS Tags: yamt-uio_vmspace-base5, yamt-uio_vmspace, yamt-pdpolicy-base4, yamt-pdpolicy-base3, yamt-pdpolicy-base2, yamt-pdpolicy-base, peter-altq-base, elad-kernelauth-base
Branch point for: yamt-pdpolicy, simonb-timecounters, rpaulo-netinet-merge-pcb, peter-altq, elad-kernelauth
Changes since 1.87: +5 -3 lines
Diff to previous 1.87 (colored) to selected 1.23 (colored)

merge ktrace-lwp.

Revision 1.70.2.7 / (download) - annotate - [select for diffs], Thu Nov 10 14:11:07 2005 UTC (8 years, 11 months ago) by skrll
Branch: ktrace-lwp
Changes since 1.70.2.6: +3 -2 lines
Diff to previous 1.70.2.6 (colored) next main 1.71 (colored) to selected 1.23 (colored)

Sync with HEAD. Here we go again...

Revision 1.81.4.1 / (download) - annotate - [select for diffs], Fri Apr 29 11:29:33 2005 UTC (9 years, 6 months ago) by kent
Branch: kent-audio2
Changes since 1.81: +51 -37 lines
Diff to previous 1.81 (colored) next main 1.82 (colored) to selected 1.23 (colored)

sync with -current

Revision 1.87 / (download) - annotate - [select for diffs], Fri Apr 29 10:39:09 2005 UTC (9 years, 6 months ago) by yamt
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, thorpej-vnode-attr-base, thorpej-vnode-attr, ktrace-lwp-base, kent-audio2-base
Branch point for: yamt-lazymbuf
Changes since 1.86: +3 -2 lines
Diff to previous 1.86 (colored) to selected 1.23 (colored)

move decl of inetsw to its own header to avoid array of incomplete type.
found by gcc4.  reported by Adam Ciarcinski.

Revision 1.70.2.6 / (download) - annotate - [select for diffs], Fri Apr 1 14:31:50 2005 UTC (9 years, 7 months ago) by skrll
Branch: ktrace-lwp
Changes since 1.70.2.5: +32 -2 lines
Diff to previous 1.70.2.5 (colored) to selected 1.23 (colored)

Sync with HEAD.

Revision 1.81.6.2 / (download) - annotate - [select for diffs], Sat Mar 19 08:36:38 2005 UTC (9 years, 7 months ago) by yamt
Branch: yamt-km
Changes since 1.81.6.1: +32 -2 lines
Diff to previous 1.81.6.1 (colored) to branchpoint 1.81 (colored) next main 1.82 (colored) to selected 1.23 (colored)

sync with head.  xen and whitespace.  xen part is not finished.

Revision 1.86 / (download) - annotate - [select for diffs], Fri Mar 11 06:16:16 2005 UTC (9 years, 7 months ago) by atatat
Branch: MAIN
CVS Tags: yamt-km-base4, yamt-km-base3, 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
Changes since 1.85: +3 -3 lines
Diff to previous 1.85 (colored) to selected 1.23 (colored)

Revert the change that made kern.file2 and net.*.*.pcblist into nodes
instead of structs.  It had other deleterious side-effects that are
rather nasty.  Another solution must be found.

Revision 1.85 / (download) - annotate - [select for diffs], Thu Mar 10 05:43:25 2005 UTC (9 years, 7 months ago) by atatat
Branch: MAIN
Changes since 1.84: +3 -3 lines
Diff to previous 1.84 (colored) to selected 1.23 (colored)

Change types of kern.file2 and net.*.*.pcblist to NODE

Revision 1.84 / (download) - annotate - [select for diffs], Wed Mar 9 05:07:19 2005 UTC (9 years, 7 months ago) by atatat
Branch: MAIN
Changes since 1.83: +32 -2 lines
Diff to previous 1.83 (colored) to selected 1.23 (colored)

Add the following nodes to the sysctl tree:

	net.local.stream.pcblist
	net.local.dgram.pcblist
	net.inet.tcp.pcblist
	net.inet.udp.pcblist
	net.inet.raw.pcblist
	net.inet6.tcp6.pcblist
	net.inet6.udp6.pcblist
	net.inet6.raw6.pcblist

which allow retrieval of the pcbs in use for those protocols.  The
struct involved is 32/64 bit clean and incorporates parts of struct
inpcb, struct unpcb, a bit of struct tcpcb, and two socket addresses.

Revision 1.81.6.1 / (download) - annotate - [select for diffs], Sat Feb 12 18:17:54 2005 UTC (9 years, 8 months ago) by yamt
Branch: yamt-km
Changes since 1.81: +20 -37 lines
Diff to previous 1.81 (colored) to selected 1.23 (colored)

sync with head.

Revision 1.70.2.5 / (download) - annotate - [select for diffs], Fri Feb 4 11:47:48 2005 UTC (9 years, 8 months ago) by skrll
Branch: ktrace-lwp
Changes since 1.70.2.4: +20 -37 lines
Diff to previous 1.70.2.4 (colored) to selected 1.23 (colored)

Sync with HEAD.

Revision 1.83 / (download) - annotate - [select for diffs], Thu Feb 3 23:16:40 2005 UTC (9 years, 8 months ago) by perry
Branch: MAIN
CVS Tags: yamt-km-base2, matt-timespec
Changes since 1.82: +14 -31 lines
Diff to previous 1.82 (colored) to selected 1.23 (colored)

ANSIfy function declarations

Revision 1.82 / (download) - annotate - [select for diffs], Wed Feb 2 21:41:55 2005 UTC (9 years, 8 months ago) by perry
Branch: MAIN
Changes since 1.81: +9 -9 lines
Diff to previous 1.81 (colored) to selected 1.23 (colored)

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

Revision 1.70.2.4 / (download) - annotate - [select for diffs], Tue Sep 21 13:37:12 2004 UTC (10 years, 1 month ago) by skrll
Branch: ktrace-lwp
Changes since 1.70.2.3: +6 -4 lines
Diff to previous 1.70.2.3 (colored) to selected 1.23 (colored)

Fix the sync with head I botched.

Revision 1.70.2.3 / (download) - annotate - [select for diffs], Sat Sep 18 14:54:54 2004 UTC (10 years, 1 month ago) by skrll
Branch: ktrace-lwp
Changes since 1.70.2.2: +9 -6 lines
Diff to previous 1.70.2.2 (colored) to selected 1.23 (colored)

Sync with HEAD.

Revision 1.81 / (download) - annotate - [select for diffs], Sat Sep 4 23:30:07 2004 UTC (10 years, 1 month ago) by manu
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.80: +7 -2 lines
Diff to previous 1.80 (colored) to selected 1.23 (colored)

IPv4 PIM support, based on a submission from Pavlin Radoslavov posted on
tech-net@

Revision 1.70.2.2 / (download) - annotate - [select for diffs], Tue Aug 3 10:54:43 2004 UTC (10 years, 2 months ago) by skrll
Branch: ktrace-lwp
Changes since 1.70.2.1: +22 -32 lines
Diff to previous 1.70.2.1 (colored) to selected 1.23 (colored)

Sync with HEAD

Revision 1.78.2.1 / (download) - annotate - [select for diffs], Mon May 10 15:00:12 2004 UTC (10 years, 5 months ago) by tron
Branch: netbsd-2-0
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-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
Changes since 1.78: +3 -2 lines
Diff to previous 1.78 (colored) next main 1.79 (colored) to selected 1.23 (colored)

Pull up revision 1.80 (requested by jonathan in ticket #280):
Redo net.inet.* sysctl subtree for fast-ipsec from scratch.
Attach FAST-IPSEC statistics with 64-bit counters to new sysctl MIB.
Rework netstat to show FAST_IPSEC statistics, via sysctl,  for
netstat -p ipsec.
New kernel files:
	sys/netipsec/Makefile		(new file; install *_var.h includes)
	sys/netipsec/ipsec_var.h	(new 64-bit mib counter struct)
Changed kernel files:
	sys/Makefile			(recurse into sys/netipsec/)
	sys/netinet/in.h		(fake IP_PROTO name for fast_ipsec
					sysctl subtree.)
	sys/netipsec/ipsec.h		(minimal userspace inclusion)
	sys/netipsec/ipsec_osdep.h	(minimal userspace inclusion)
	sys/netipsec/ipsec_netbsd.c	(redo sysctl subtree from scratch)
	sys/netipsec/key*.c		(fix broken net.key subtree)
	sys/netipsec/ah_var.h		(increase all counters to 64 bits)
	sys/netipsec/esp_var.h		(increase all counters to 64 bits)
	sys/netipsec/ipip_var.h		(increase all counters to 64 bits)
	sys/netipsec/ipcomp_var.h	(increase all counters to 64 bits)
	sys/netipsec/ipsec.c		(add #include netipsec/ipsec_var.h)
	sys/netipsec/ipsec_mbuf.c	(add #include netipsec/ipsec_var.h)
	sys/netipsec/ipsec_output.c	(add #include netipsec/ipsec_var.h)
	sys/netinet/raw_ip.c		(add #include netipsec/ipsec_var.h)
	sys/netinet/tcp_input.c		(add #include netipsec/ipsec_var.h)
	sys/netinet/udp_usrreq.c	(add #include netipsec/ipsec_var.h)
Changes to usr.bin/netstat to print the new fast-ipsec sysctl tree
for "netstat -s -p ipsec":
New file:
	usr.bin/netstat/fast_ipsec.c	(print fast-ipsec counters)
Changed files:
	usr.bin/netstat/Makefile	(add fast_ipsec.c)
	usr.bin/netstat/netstat.h	(declarations for fast_ipsec.c)
	usr.bin/netstat/main.c		(call KAME-vs-fast-ipsec dispatcher)

Revision 1.80 / (download) - annotate - [select for diffs], Fri May 7 00:55:15 2004 UTC (10 years, 5 months ago) by jonathan
Branch: MAIN
CVS Tags: BEFORE-IPF413
Changes since 1.79: +3 -2 lines
Diff to previous 1.79 (colored) to selected 1.23 (colored)

Redo net.inet.* sysctl subtree for fast-ipsec from scratch.
Attach FAST-IPSEC statistics with 64-bit counters to new sysctl MIB.
Rework netstat to show FAST_IPSEC statistics, via sysctl,  for
netstat -p ipsec.

New kernel files:
	sys/netipsec/Makefile		(new file; install *_var.h includes)
	sys/netipsec/ipsec_var.h	(new 64-bit mib counter struct)

Changed kernel files:
	sys/Makefile			(recurse into sys/netipsec/)
	sys/netinet/in.h		(fake IP_PROTO name for fast_ipsec
					sysctl subtree.)
	sys/netipsec/ipsec.h		(minimal userspace inclusion)
	sys/netipsec/ipsec_osdep.h	(minimal userspace inclusion)
	sys/netipsec/ipsec_netbsd.c	(redo sysctl subtree from scratch)
	sys/netipsec/key*.c		(fix broken net.key subtree)

	sys/netipsec/ah_var.h		(increase all counters to 64 bits)
	sys/netipsec/esp_var.h		(increase all counters to 64 bits)
	sys/netipsec/ipip_var.h		(increase all counters to 64 bits)
	sys/netipsec/ipcomp_var.h	(increase all counters to 64 bits)

	sys/netipsec/ipsec.c		(add #include netipsec/ipsec_var.h)
	sys/netipsec/ipsec_mbuf.c	(add #include netipsec/ipsec_var.h)
	sys/netipsec/ipsec_output.c	(add #include netipsec/ipsec_var.h)

	sys/netinet/raw_ip.c		(add #include netipsec/ipsec_var.h)
	sys/netinet/tcp_input.c		(add #include netipsec/ipsec_var.h)
	sys/netinet/udp_usrreq.c	(add #include netipsec/ipsec_var.h)

Changes to usr.bin/netstat to print the new fast-ipsec sysctl tree
for "netstat -s -p ipsec":

New file:
	usr.bin/netstat/fast_ipsec.c	(print fast-ipsec counters)

Changed files:
	usr.bin/netstat/Makefile	(add fast_ipsec.c)
	usr.bin/netstat/netstat.h	(declarations for fast_ipsec.c)
	usr.bin/netstat/main.c		(call KAME-vs-fast-ipsec dispatcher)

Revision 1.79 / (download) - annotate - [select for diffs], Mon Apr 26 01:31:57 2004 UTC (10 years, 6 months ago) by matt
Branch: MAIN
Changes since 1.78: +2 -14 lines
Diff to previous 1.78 (colored) to selected 1.23 (colored)

Remove #else clause of __STDC__

Revision 1.78 / (download) - annotate - [select for diffs], Wed Nov 19 18:39:34 2003 UTC (10 years, 11 months ago) by jonathan
Branch: MAIN
CVS Tags: netbsd-2-0-base, BEFORE-IPF411
Branch point for: netbsd-2-0
Changes since 1.77: +3 -2 lines
Diff to previous 1.77 (colored) to selected 1.23 (colored)

Patch back support for (badly) randomized IP ids, by request:

* Include "opt_inet.h" everywhere IP-ids are generated with ip_newid(),
  so the RANDOM_IP_ID option is visible. Also in ip_id(), to ensure
  the prototype for ip_randomid() is made visible.

* Add new sysctl to enable randomized IP-ids, provided the kernel was
  configured with RANDOM_IP_ID. (The sysctl defaults to zero, and is
  a read-only zero if RANDOM_IP_ID is not configured).

Note that the implementation of randomized IP ids is still defective,
and should not be enabled at all (even if configured) without
very careful deliberation. Caveat emptor.

Revision 1.77 / (download) - annotate - [select for diffs], Mon Nov 17 21:34:27 2003 UTC (10 years, 11 months ago) by jonathan
Branch: MAIN
Changes since 1.76: +3 -3 lines
Diff to previous 1.76 (colored) to selected 1.23 (colored)

Revert the (default) ip_id algorithm to the pre-randomid algorithm,
due to demonstrated low-period repeated IDs from the randomized IP_id
code.  Consensus is that the low-period repetition (much less than
2^15) is not suitable for general-purpose use.

Allocators of new IPv4 IDs should now call the function ip_newid().
Randomized IP_ids is now a config-time option, "options RANDOM_IP_ID".
ip_newid() can use ip_random-id()_IP_ID if and only if configured
with RANDOM_IP_ID. A sysctl knob should be  provided.

This API may be reworked in the near future to support linear ip_id
counters per (src,dst) IP-address pair.

Revision 1.76 / (download) - annotate - [select for diffs], Sat Sep 6 03:36:31 2003 UTC (11 years, 1 month ago) by itojun
Branch: MAIN
Changes since 1.75: +3 -3 lines
Diff to previous 1.75 (colored) to selected 1.23 (colored)

randomize IPv4/v6 fragment ID and IPv6 flowlabel.  avoids predictability
of these fields.  ip_id.c is from openbsd.  ip6_id.c is adapted by kame.

Revision 1.75 / (download) - annotate - [select for diffs], Thu Sep 4 09:16:59 2003 UTC (11 years, 1 month ago) by itojun
Branch: MAIN
Changes since 1.74: +11 -5 lines
Diff to previous 1.74 (colored) to selected 1.23 (colored)

revamp inpcb/in6pcb so that they are more aligned with each other.
in6pcb lookup now uses hash(9).

Revision 1.74 / (download) - annotate - [select for diffs], Fri Aug 22 22:00:37 2003 UTC (11 years, 2 months ago) by itojun
Branch: MAIN
Changes since 1.73: +2 -8 lines
Diff to previous 1.73 (colored) to selected 1.23 (colored)

remove ipsec_set/getsocket.  now we explicitly pass socket * to ip{,6}_output.

Revision 1.73 / (download) - annotate - [select for diffs], Fri Aug 22 21:53:05 2003 UTC (11 years, 2 months ago) by itojun
Branch: MAIN
Changes since 1.72: +3 -3 lines
Diff to previous 1.72 (colored) to selected 1.23 (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.72 / (download) - annotate - [select for diffs], Fri Aug 15 03:42:03 2003 UTC (11 years, 2 months ago) by jonathan
Branch: MAIN
Changes since 1.71: +9 -5 lines
Diff to previous 1.71 (colored) to selected 1.23 (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.71 / (download) - annotate - [select for diffs], Thu Aug 7 16:33:14 2003 UTC (11 years, 2 months ago) by agc
Branch: MAIN
Changes since 1.70: +3 -7 lines
Diff to previous 1.70 (colored) to selected 1.23 (colored)

Move UCB-licensed code from 4-clause to 3-clause licence.

Patches provided by Joel Baker in PR 22364, verified by myself.

Revision 1.70.2.1 / (download) - annotate - [select for diffs], Wed Jul 2 15:27:00 2003 UTC (11 years, 4 months ago) by darrenr
Branch: ktrace-lwp
Changes since 1.70: +6 -4 lines
Diff to previous 1.70 (colored) to selected 1.23 (colored)

Apply the aborted ktrace-lwp changes to a specific branch.  This is just for
others to review, I'm concerned that patch fuziness may have resulted in some
errant code being generated but I'll look at that later by comparing the diff
from the base to the branch with the file I attempt to apply to it.  This will,
at the very least, put the changes in a better context for others to review
them and attempt to tinker with removing passing of 'struct lwp' through
the kernel.

Revision 1.70 / (download) - annotate - [select for diffs], Sun Jun 29 22:31:57 2003 UTC (11 years, 4 months ago) by fvdl
Branch: MAIN
Branch point for: ktrace-lwp
Changes since 1.69: +2 -4 lines
Diff to previous 1.69 (colored) to selected 1.23 (colored)

Back out the lwp/ktrace changes. They contained a lot of colateral damage,
and need to be examined and discussed more.

Revision 1.69 / (download) - annotate - [select for diffs], Sat Jun 28 14:22:09 2003 UTC (11 years, 4 months ago) by darrenr
Branch: MAIN
Changes since 1.68: +6 -4 lines
Diff to previous 1.68 (colored) to selected 1.23 (colored)

Pass lwp pointers throughtout the kernel, as required, so that the lwpid can
be inserted into ktrace records.  The general change has been to replace
"struct proc *" with "struct lwp *" in various function prototypes, pass
the lwp through and use l_proc to get the process pointer when needed.

Bump the kernel rev up to 1.6V

Revision 1.68 / (download) - annotate - [select for diffs], Tue May 27 22:36:38 2003 UTC (11 years, 5 months ago) by itojun
Branch: MAIN
Changes since 1.67: +5 -3 lines
Diff to previous 1.67 (colored) to selected 1.23 (colored)

can't use M_WAIT here, i believe.

Revision 1.67 / (download) - annotate - [select for diffs], Wed Feb 26 06:31:15 2003 UTC (11 years, 8 months ago) by matt
Branch: MAIN
Changes since 1.66: +3 -2 lines
Diff to previous 1.66 (colored) to selected 1.23 (colored)

Add MBUFTRACE kernel option.
Do a little mbuf rework while here.  Change all uses of MGET*(*, M_WAIT, *)
to m_get*(M_WAIT, *).  These are not performance critical and making them
call m_get saves considerable space.  Add m_clget analogue of MCLGET and
make corresponding change for M_WAIT uses.
Modify netinet, gem, fxp, tulip, nfs to support MBUFTRACE.
Begin to change netstat to use sysctl.

Revision 1.66 / (download) - annotate - [select for diffs], Thu Jan 30 23:43:33 2003 UTC (11 years, 9 months ago) by thorpej
Branch: MAIN
Changes since 1.65: +3 -3 lines
Diff to previous 1.65 (colored) to selected 1.23 (colored)

M_SOOPTS -> MT_SOOPTS

Revision 1.55.2.6 / (download) - annotate - [select for diffs], Thu Nov 7 17:58:51 2002 UTC (11 years, 11 months ago) by thorpej
Branch: nathanw_sa
CVS Tags: nathanw_sa_end
Changes since 1.55.2.5: +19 -6 lines
Diff to previous 1.55.2.5 (colored) to branchpoint 1.55 (colored) next main 1.56 (colored) to selected 1.23 (colored)

Sync with HEAD.

Revision 1.65 / (download) - annotate - [select for diffs], Thu Nov 7 17:49:08 2002 UTC (11 years, 11 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.64: +17 -2 lines
Diff to previous 1.64 (colored) to selected 1.23 (colored)

In the IP_HDRINCL case of rip_output(), if the mbuf is read-only
then copy the header into a new mbuf before modifying it.

Fixes PR 18809.  Thanks to Chuq Silvers for diagnosing it.

Revision 1.64 / (download) - annotate - [select for diffs], Tue Oct 22 02:44:34 2002 UTC (12 years ago) by simonb
Branch: MAIN
CVS Tags: kqueue-beforemerge, kqueue-aftermerge
Changes since 1.63: +3 -2 lines
Diff to previous 1.63 (colored) to selected 1.23 (colored)

Oops, still need the call to va_arg() to advance the args pointer.

Revision 1.63 / (download) - annotate - [select for diffs], Tue Oct 22 02:34:47 2002 UTC (12 years ago) by simonb
Branch: MAIN
Changes since 1.62: +3 -6 lines
Diff to previous 1.62 (colored) to selected 1.23 (colored)

"off" in rip_input() is set but not used, remove it.
static global "ripsrc" is never used, remove it.

Revision 1.56.2.4 / (download) - annotate - [select for diffs], Fri Sep 6 08:49:18 2002 UTC (12 years, 1 month ago) by jdolecek
Branch: kqueue
Changes since 1.56.2.3: +13 -7 lines
Diff to previous 1.56.2.3 (colored) next main 1.57 (colored) to selected 1.23 (colored)

sync kqueue branch with HEAD

Revision 1.60.8.2 / (download) - annotate - [select for diffs], Thu Aug 29 00:56:47 2002 UTC (12 years, 2 months ago) by gehenna
Branch: gehenna-devsw
Changes since 1.60.8.1: +13 -7 lines
Diff to previous 1.60.8.1 (colored) to branchpoint 1.60 (colored) next main 1.61 (colored) to selected 1.23 (colored)

catch up with -current.

Revision 1.55.2.5 / (download) - annotate - [select for diffs], Tue Aug 27 23:48:03 2002 UTC (12 years, 2 months ago) by nathanw
Branch: nathanw_sa
Changes since 1.55.2.4: +13 -7 lines
Diff to previous 1.55.2.4 (colored) to branchpoint 1.55 (colored) to selected 1.23 (colored)

Catch up to -current.

Revision 1.62 / (download) - annotate - [select for diffs], Wed Aug 14 00:23:33 2002 UTC (12 years, 2 months ago) by itojun
Branch: MAIN
CVS Tags: kqueue-base, gehenna-devsw-base
Changes since 1.61: +13 -7 lines
Diff to previous 1.61 (colored) to selected 1.23 (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.56.2.3 / (download) - annotate - [select for diffs], Sun Jun 23 17:50:58 2002 UTC (12 years, 4 months ago) by jdolecek
Branch: kqueue
Changes since 1.56.2.2: +4 -4 lines
Diff to previous 1.56.2.2 (colored) to selected 1.23 (colored)

catch up with -current on kqueue branch

Revision 1.60.8.1 / (download) - annotate - [select for diffs], Thu Jun 20 15:52:27 2002 UTC (12 years, 4 months ago) by gehenna
Branch: gehenna-devsw
Changes since 1.60: +4 -4 lines
Diff to previous 1.60 (colored) to selected 1.23 (colored)

catch up with -current.

Revision 1.55.2.4 / (download) - annotate - [select for diffs], Thu Jun 20 03:48:53 2002 UTC (12 years, 4 months ago) by nathanw
Branch: nathanw_sa
Changes since 1.55.2.3: +4 -4 lines
Diff to previous 1.55.2.3 (colored) to branchpoint 1.55 (colored) to selected 1.23 (colored)

Catch up to -current.

Revision 1.61 / (download) - annotate - [select for diffs], Sun Jun 9 16:33:43 2002 UTC (12 years, 4 months ago) by itojun
Branch: MAIN
Changes since 1.60: +4 -4 lines
Diff to previous 1.60 (colored) to selected 1.23 (colored)

whitespace

Revision 1.56.2.2 / (download) - annotate - [select for diffs], Thu Jan 10 20:02:57 2002 UTC (12 years, 9 months ago) by thorpej
Branch: kqueue
Changes since 1.56.2.1: +70 -6 lines
Diff to previous 1.56.2.1 (colored) to selected 1.23 (colored)

Sync kqueue branch with -current.

Revision 1.55.2.3 / (download) - annotate - [select for diffs], Tue Jan 8 00:34:11 2002 UTC (12 years, 9 months ago) by nathanw
Branch: nathanw_sa
Changes since 1.55.2.2: +65 -2 lines
Diff to previous 1.55.2.2 (colored) to branchpoint 1.55 (colored) to selected 1.23 (colored)

Catch up to -current.

Revision 1.60 / (download) - annotate - [select for diffs], Fri Dec 21 02:51:47 2001 UTC (12 years, 10 months ago) by itojun
Branch: MAIN
CVS Tags: newlock-base, newlock, netbsd-1-6-base, netbsd-1-6-RELEASE, netbsd-1-6-RC3, netbsd-1-6-RC2, netbsd-1-6-RC1, 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, netbsd-1-6-PATCH001-RELEASE, netbsd-1-6-PATCH001-RC3, netbsd-1-6-PATCH001-RC2, netbsd-1-6-PATCH001-RC1, netbsd-1-6-PATCH001, netbsd-1-6, ifpoll-base, ifpoll, eeh-devprop-base, eeh-devprop
Branch point for: gehenna-devsw
Changes since 1.59: +65 -2 lines
Diff to previous 1.59 (colored) to selected 1.23 (colored)

have rip_ctlinput to notify routing changes to raw sockets
(protosw change to be done).  sync with kame

Revision 1.55.2.2 / (download) - annotate - [select for diffs], Wed Nov 14 19:17:55 2001 UTC (12 years, 11 months ago) by nathanw
Branch: nathanw_sa
Changes since 1.55.2.1: +7 -6 lines
Diff to previous 1.55.2.1 (colored) to branchpoint 1.55 (colored) to selected 1.23 (colored)

Catch up to -current.

Revision 1.59 / (download) - annotate - [select for diffs], Tue Nov 13 00:32:40 2001 UTC (12 years, 11 months ago) by lukem
Branch: MAIN
Changes since 1.58: +4 -1 lines
Diff to previous 1.58 (colored) to selected 1.23 (colored)

add RCSIDs

Revision 1.57.4.1 / (download) - annotate - [select for diffs], Mon Nov 12 21:19:26 2001 UTC (12 years, 11 months ago) by thorpej
Branch: thorpej-mips-cache
Changes since 1.57: +4 -6 lines
Diff to previous 1.57 (colored) next main 1.58 (colored) to selected 1.23 (colored)

Sync the thorpej-mips-cache branch with -current.

Revision 1.58 / (download) - annotate - [select for diffs], Sun Nov 4 20:55:28 2001 UTC (12 years, 11 months ago) by matt
Branch: MAIN
CVS Tags: thorpej-mips-cache-base
Changes since 1.57: +4 -6 lines
Diff to previous 1.57 (colored) to selected 1.23 (colored)

Convert netinet to not use the internal <sys/queue.h> field names
but instead the access macros.  Use the FOREACH macros where appropriate.

Revision 1.55.2.1 / (download) - annotate - [select for diffs], Fri Aug 24 00:12:28 2001 UTC (13 years, 2 months ago) by nathanw
Branch: nathanw_sa
Changes since 1.55: +2 -8 lines
Diff to previous 1.55 (colored) to selected 1.23 (colored)

Catch up with -current.

Revision 1.56.2.1 / (download) - annotate - [select for diffs], Fri Aug 3 04:13:55 2001 UTC (13 years, 3 months ago) by lukem
Branch: kqueue
Changes since 1.56: +1 -8 lines
Diff to previous 1.56 (colored) to selected 1.23 (colored)

update to -current

Revision 1.57 / (download) - annotate - [select for diffs], Wed Jul 25 23:28:02 2001 UTC (13 years, 3 months ago) by itojun
Branch: MAIN
CVS Tags: thorpej-devvp-base3, thorpej-devvp-base2, thorpej-devvp-base, thorpej-devvp, pre-chs-ubcperf, post-chs-ubcperf
Branch point for: thorpej-mips-cache
Changes since 1.56: +1 -8 lines
Diff to previous 1.56 (colored) to selected 1.23 (colored)

allocate ipsec policy buffer attached to pcb in in*_pcballoc, before
giving anyone accesses to pcb (do not reveal an inconsistent ones).
sync with kame

Revision 1.56 / (download) - annotate - [select for diffs], Tue Jul 3 08:06:19 2001 UTC (13 years, 4 months ago) by itojun
Branch: MAIN
Branch point for: kqueue
Changes since 1.55: +2 -1 lines
Diff to previous 1.55 (colored) to selected 1.23 (colored)

call in{,6}_pcbpurgeif0() before in{,6}_purgeif().

Revision 1.53.4.2 / (download) - annotate - [select for diffs], Fri Apr 6 00:25:38 2001 UTC (13 years, 6 months ago) by he
Branch: netbsd-1-5
CVS Tags: netbsd-1-5-PATCH003, netbsd-1-5-PATCH002, netbsd-1-5-PATCH001
Changes since 1.53.4.1: +5 -2 lines
Diff to previous 1.53.4.1 (colored) to branchpoint 1.53 (colored) next main 1.54 (colored) to selected 1.23 (colored)

Pull up revision 1.54 (requested by itojun):
  Record IPsec packet history in m_aux structure.  Let ipfilter
  look at wire-format packet only (not the decapsulated ones), so
  that VPN setting can work with NAT/ipfilter settings.

Revision 1.46.2.3 / (download) - annotate - [select for diffs], Mon Mar 12 13:31:51 2001 UTC (13 years, 7 months ago) by bouyer
Branch: thorpej_scsipi
Changes since 1.46.2.2: +18 -1 lines
Diff to previous 1.46.2.2 (colored) to branchpoint 1.46 (colored) next main 1.47 (colored) to selected 1.23 (colored)

Sync with HEAD.

Revision 1.53.4.1 / (download) - annotate - [select for diffs], Mon Feb 26 22:43:55 2001 UTC (13 years, 8 months ago) by he
Branch: netbsd-1-5
Changes since 1.53: +18 -1 lines
Diff to previous 1.53 (colored) to selected 1.23 (colored)

Pull up revision 1.55 (requested by itojun):
  Make sure to validate packet against ipsec policy.

Revision 1.55 / (download) - annotate - [select for diffs], Mon Feb 26 07:20:44 2001 UTC (13 years, 8 months ago) by itojun
Branch: MAIN
CVS Tags: thorpej_scsipi_nbase, thorpej_scsipi_beforemerge, thorpej_scsipi_base
Branch point for: nathanw_sa
Changes since 1.54: +18 -1 lines
Diff to previous 1.54 (colored) to selected 1.23 (colored)

make sure to validate packet against ipsec policy.

Revision 1.46.2.2 / (download) - annotate - [select for diffs], Sun Feb 11 19:17:17 2001 UTC (13 years, 8 months ago) by bouyer
Branch: thorpej_scsipi
Changes since 1.46.2.1: +5 -2 lines
Diff to previous 1.46.2.1 (colored) to branchpoint 1.46 (colored) to selected 1.23 (colored)

Sync with HEAD.

Revision 1.54 / (download) - annotate - [select for diffs], Wed Jan 24 09:04:15 2001 UTC (13 years, 9 months ago) by itojun
Branch: MAIN
Changes since 1.53: +5 -2 lines
Diff to previous 1.53 (colored) to selected 1.23 (colored)

- record IPsec packet history into m_aux structure.
- let ipfilter look at wire-format packet only (not the decapsulated ones),
  so that VPN setting can work with NAT/ipfilter settings.
sync with kame.

TODO: use header history for stricter inbound validation

Revision 1.46.2.1 / (download) - annotate - [select for diffs], Mon Nov 20 18:10:34 2000 UTC (13 years, 11 months ago) by bouyer
Branch: thorpej_scsipi
Changes since 1.46: +22 -14 lines
Diff to previous 1.46 (colored) to selected 1.23 (colored)

Update thorpej_scsipi to -current as of a month ago

Revision 1.53 / (download) - annotate - [select for diffs], Thu Mar 30 13:25:04 2000 UTC (14 years, 7 months ago) by augustss
Branch: MAIN
CVS Tags: netbsd-1-5-base, netbsd-1-5-RELEASE, netbsd-1-5-BETA2, netbsd-1-5-BETA, netbsd-1-5-ALPHA2, minoura-xpg4dl-base, minoura-xpg4dl
Branch point for: netbsd-1-5
Changes since 1.52: +9 -9 lines
Diff to previous 1.52 (colored) to selected 1.23 (colored)

Remove register declarations.

Revision 1.52 / (download) - annotate - [select for diffs], Wed Mar 1 12:49:36 2000 UTC (14 years, 8 months ago) by itojun
Branch: MAIN
Changes since 1.51: +2 -2 lines
Diff to previous 1.51 (colored) to selected 1.23 (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.51 / (download) - annotate - [select for diffs], Thu Feb 17 10:59:36 2000 UTC (14 years, 8 months ago) by darrenr
Branch: MAIN
Changes since 1.50: +1 -3 lines
Diff to previous 1.50 (colored) to selected 1.23 (colored)

Change the use of pfil hooks.  There is no longer a single list of all
pfil information, instead, struct protosw now contains a structure
which caontains list heads, etc.  The per-protosw pfil struct is passed
to pfil_hook_get(), along with an in/out flag to get the head of the
relevant filter list.  This has been done for only IPv4 and IPv6, at
present, with these patches only enabling filtering for IPPROTO_IP and
IPPROTO_IPV6, although it is possible to have tcp/udp, etc, dedicated
filters now also.  The ipfilter code has been updated to only filter
IPv4 packets - next major release of ipfilter is required for ipv6.

Revision 1.50 / (download) - annotate - [select for diffs], Wed Feb 2 23:28:09 2000 UTC (14 years, 9 months ago) by thorpej
Branch: MAIN
CVS Tags: chs-ubc2-newbase
Changes since 1.49: +4 -3 lines
Diff to previous 1.49 (colored) to selected 1.23 (colored)

PRU_PURGEADDR -> PRU_PURGEIF, per a discussion w/ itojun.  In the IPv4
and IPv6 code, also use this to traverse PCB tables, looking for cached
routes referencing the dying ifnet, forcing them to be refreshed.

Revision 1.49 / (download) - annotate - [select for diffs], Tue Feb 1 22:52:08 2000 UTC (14 years, 9 months ago) by thorpej
Branch: MAIN
Changes since 1.48: +6 -1 lines
Diff to previous 1.48 (colored) to selected 1.23 (colored)

First-draft if_detach() implementation, originally from Bill Studnemund,
although this version has been changed somewhat:
- reference counting on ifaddrs isn't as complete as Bill's original
  work was.  This is hard to get right, and we should attack one
  protocol at a time.
- This doesn't do reference counting or dynamic allocation of ifnets yet.
- This version introduces a new PRU -- PRU_PURGEADDR, which is used to
  purge an ifaddr from a protocol.  The old method Bill used didn't work
  on all protocols, and it only worked on some because it was Very Lucky.

This mostly works ... i.e. works for my USB Ethernet, except for a dangling
ifaddr reference left by the IPv6 code; have not yet tracked this down.

Revision 1.48 / (download) - annotate - [select for diffs], Mon Jan 31 14:18:55 2000 UTC (14 years, 9 months ago) by itojun
Branch: MAIN
Changes since 1.47: +2 -2 lines
Diff to previous 1.47 (colored) to selected 1.23 (colored)

bring in latest KAME ipsec tree.
- interop issues in ipcomp is fixed
- padding type (after ESP) is configurable
- key database memory management (need more fixes)
- policy specification is revisited

XXX m->m_pkthdr.rcvif is still overloaded - hope to fix it soon

Revision 1.46.8.1 / (download) - annotate - [select for diffs], Mon Dec 27 18:36:19 1999 UTC (14 years, 10 months ago) by wrstuden
Branch: wrstuden-devbsize
Changes since 1.46: +7 -3 lines
Diff to previous 1.46 (colored) next main 1.47 (colored) to selected 1.23 (colored)

Pull up to last week's -current.

Revision 1.47 / (download) - annotate - [select for diffs], Mon Dec 13 15:17:20 1999 UTC (14 years, 10 months ago) by itojun
Branch: MAIN
CVS Tags: wrstuden-devbsize-base, wrstuden-devbsize-19991221
Changes since 1.46: +7 -3 lines
Diff to previous 1.46 (colored) to selected 1.23 (colored)

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...)

Revision 1.42.6.3 / (download) - annotate - [select for diffs], Tue Nov 30 13:35:34 1999 UTC (14 years, 11 months ago) by itojun
Branch: kame
CVS Tags: kame_141_19991130
Changes since 1.42.6.2: +7 -2 lines
Diff to previous 1.42.6.2 (colored) to branchpoint 1.42 (colored) next main 1.43 (colored) to selected 1.23 (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.46 / (download) - annotate - [select for diffs], Mon Sep 13 12:15:55 1999 UTC (15 years, 1 month ago) by itojun
Branch: MAIN
CVS Tags: fvdl-softdep-base, fvdl-softdep, comdex-fall-1999-base, comdex-fall-1999
Branch point for: wrstuden-devbsize, thorpej_scsipi
Changes since 1.45: +3 -2 lines
Diff to previous 1.45 (colored) to selected 1.23 (colored)

- Call in{,6}_pcbdetach if ipsec initialization is failed during PRU_ATTACH.
  This situation happens on severe memory shortage.  We may need more
  improvements here and there.
- Grab IEEE802 address from IFT_ETHER card, even if the card is
  inserted after bootup time.  Is there any other card that can be
  inserted afterwards?  pcmcia fddi card? :-P
- RFC2373 u bit handling suggests that we SHOULD NOT copy interface id from
  ethernet card to pseudo interface, when ethernet card has IEEE802/EUI64
  with u bit != 0 (this means that IEEE802/EUI64 is not universally unique).
  Do not use such address as, for example, interface id for gif interface.
  (I have such an ethernet card myself)
  This may change interface id for your gif interface.  be careful upgrading
  rc files.

(sync with recent KAME)

Revision 1.42.4.2 / (download) - annotate - [select for diffs], Mon Aug 2 22:34:59 1999 UTC (15 years, 3 months ago) by thorpej
Branch: chs-ubc2
Changes since 1.42.4.1: +11 -4 lines
Diff to previous 1.42.4.1 (colored) to branchpoint 1.42 (colored) next main 1.43 (colored) to selected 1.23 (colored)

Update from trunk.

Revision 1.45 / (download) - annotate - [select for diffs], Fri Jul 9 22:57:20 1999 UTC (15 years, 3 months ago) by thorpej
Branch: MAIN
CVS Tags: chs-ubc2-base
Changes since 1.44: +2 -1 lines
Diff to previous 1.44 (colored) to selected 1.23 (colored)

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

Revision 1.42.6.2 / (download) - annotate - [select for diffs], Tue Jul 6 11:02:47 1999 UTC (15 years, 3 months ago) by itojun
Branch: kame
CVS Tags: kame_14_19990705
Changes since 1.42.6.1: +30 -1 lines
Diff to previous 1.42.6.1 (colored) to branchpoint 1.42 (colored) to selected 1.23 (colored)

KAME/NetBSD 1.4, SNAP kit 1999/07/05.
NOTE: this branch is just for reference purposes (i.e. for taking cvs diff).
do not touch anything on the branch.  actual work must be done on HEAD branch.

Revision 1.44 / (download) - annotate - [select for diffs], Mon Jul 5 07:24:38 1999 UTC (15 years, 4 months ago) by darrenr
Branch: MAIN
Changes since 1.43: +10 -4 lines
Diff to previous 1.43 (colored) to selected 1.23 (colored)

Call icmp_error() at the bottom of rip_input IFF rip_input is the handler
for the protocol in the specified packet.
Fix statistic gathering to not make bogus increments of ips_delivered and
ips_noproto for cases where rip_input() is called by a protocol handler
(such as icmp_input or igmp_input) which has already processed the packet.

Revision 1.42.4.1 / (download) - annotate - [select for diffs], Thu Jul 1 23:47:02 1999 UTC (15 years, 4 months ago) by thorpej
Branch: chs-ubc2
Changes since 1.42: +51 -2 lines
Diff to previous 1.42 (colored) to selected 1.23 (colored)

Sync w/ -current.

Revision 1.43 / (download) - annotate - [select for diffs], Thu Jul 1 08:12:51 1999 UTC (15 years, 4 months ago) by itojun
Branch: MAIN
Changes since 1.42: +51 -2 lines
Diff to previous 1.42 (colored) to selected 1.23 (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.42.6.1 / (download) - annotate - [select for diffs], Mon Jun 28 06:37:01 1999 UTC (15 years, 4 months ago) by itojun
Branch: kame
CVS Tags: kame_14_19990628
Changes since 1.42: +22 -2 lines
Diff to previous 1.42 (colored) to selected 1.23 (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.42 / (download) - annotate - [select for diffs], Sat Jan 30 21:43:16 1999 UTC (15 years, 9 months ago) by thorpej
Branch: MAIN
CVS Tags: netbsd-1-4-base, netbsd-1-4-RELEASE, netbsd-1-4-PATCH003, netbsd-1-4-PATCH002, netbsd-1-4-PATCH001, netbsd-1-4
Branch point for: kame, chs-ubc2
Changes since 1.41: +7 -1 lines
Diff to previous 1.41 (colored) to selected 1.23 (colored)

Make programs that use raw IP work again; trim the header length from ip_len
before handing the packet off to the socket.

Revision 1.41.6.1 / (download) - annotate - [select for diffs], Fri Dec 11 04:53:09 1998 UTC (15 years, 10 months ago) by kenh
Branch: kenh-if-detach
Changes since 1.41: +5 -2 lines
Diff to previous 1.41 (colored) next main 1.42 (colored) to selected 1.23 (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.41 / (download) - annotate - [select for diffs], Fri Apr 3 07:49:16 1998 UTC (16 years, 7 months ago) by thorpej
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.40: +2 -1 lines
Diff to previous 1.40 (colored) to selected 1.23 (colored)

Fix a bug which would cause a panic in soreceive() if multiple raw
receivers ask for ancillary data.

Noted by Francis Dupont <Francis.Dupont@inria.fr> on tech-net.

Revision 1.40 / (download) - annotate - [select for diffs], Mon Jan 12 03:02:53 1998 UTC (16 years, 9 months ago) by scottr
Branch: MAIN
Changes since 1.39: +3 -1 lines
Diff to previous 1.39 (colored) to selected 1.23 (colored)

Use option header file for MROUTING

Revision 1.39 / (download) - annotate - [select for diffs], Mon Jan 5 10:32:01 1998 UTC (16 years, 9 months ago) by thorpej
Branch: MAIN
Changes since 1.38: +2 -2 lines
Diff to previous 1.38 (colored) to selected 1.23 (colored)

Finishing merging 4.4BSD-Lite2 netinet.  At this point, the only changes
left were SCCS IDs and Copyright dates.

Revision 1.1.1.3 / (download) - annotate - [select for diffs] (vendor branch), Mon Jan 5 09:56:02 1998 UTC (16 years, 9 months ago) by thorpej
Branch: WFJ-920714, CSRG
CVS Tags: lite-2
Changes since 1.1.1.2: +43 -21 lines
Diff to previous 1.1.1.2 (colored) to selected 1.23 (colored)

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

Revision 1.1.1.2 / (download) - annotate - [select for diffs] (vendor branch), Mon Jan 5 09:54:16 1998 UTC (16 years, 9 months ago) by thorpej
Branch: WFJ-920714, CSRG
CVS Tags: lite-1, date-03-may-96
Changes since 1.1.1.1: +258 -130 lines
Diff to previous 1.1.1.1 (colored) to selected 1.23 (colored)

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

Revision 1.37.2.1 / (download) - annotate - [select for diffs], Tue Nov 18 01:04:22 1997 UTC (16 years, 11 months ago) by mellon
Branch: netbsd-1-3
CVS Tags: netbsd-1-3-RELEASE, netbsd-1-3-PATCH003-CANDIDATE2, netbsd-1-3-PATCH003-CANDIDATE1, netbsd-1-3-PATCH003-CANDIDATE0, netbsd-1-3-PATCH003, netbsd-1-3-PATCH002, netbsd-1-3-PATCH001, netbsd-1-3-BETA
Changes since 1.37: +5 -1 lines
Diff to previous 1.37 (colored) next main 1.38 (colored) to selected 1.23 (colored)

Pull rev 1.38 up from trunk (mycroft)

Revision 1.38 / (download) - annotate - [select for diffs], Sun Nov 16 20:58:18 1997 UTC (16 years, 11 months ago) by mycroft
Branch: MAIN
Changes since 1.37: +5 -1 lines
Diff to previous 1.37 (colored) to selected 1.23 (colored)

On output, if the packet length doesn't match the length in the IP header,
drop the packet with EINVAL.

Revision 1.36.10.1 / (download) - annotate - [select for diffs], Tue Oct 14 10:29:34 1997 UTC (17 years ago) by thorpej
Branch: marc-pcmcia
Changes since 1.36: +4 -3 lines
Diff to previous 1.36 (colored) next main 1.37 (colored) to selected 1.23 (colored)

Update marc-pcmcia branch from trunk.

Revision 1.37 / (download) - annotate - [select for diffs], Tue Oct 14 00:52:54 1997 UTC (17 years ago) by matt
Branch: MAIN
CVS Tags: netbsd-1-3-base, marc-pcmcia-base
Branch point for: netbsd-1-3
Changes since 1.36: +4 -3 lines
Diff to previous 1.36 (colored) to selected 1.23 (colored)

Add support for returning maximum supported MTU when ip_output fails with
EMSGSIZE.

Revision 1.36 / (download) - annotate - [select for diffs], Sat Jan 11 05:21:13 1997 UTC (17 years, 9 months ago) by thorpej
Branch: MAIN
CVS Tags: thorpej-signal-base, thorpej-signal, thorpej-setroot, mrg-vm-swap, marc-pcmcia-bp, is-newarp-before-merge, is-newarp-base, is-newarp, bouyer-scsipi
Branch point for: marc-pcmcia
Changes since 1.35: +22 -12 lines
Diff to previous 1.35 (colored) to selected 1.23 (colored)

Implement the IP_RECVIF socket option: supply a datagram packet's incoming
interface using a sockaddr_dl in a control mbuf.

Implement SO_TIMESTAMP for IP datagrams.

Move packet information option processing into a generic function
so that they work with multicast UDP and raw IP as well as unicast UDP.

Contributed by Bill Fenner <fenner@parc.xerox.com>.

Revision 1.25.4.2 / (download) - annotate - [select for diffs], Wed Dec 11 04:01:08 1996 UTC (17 years, 10 months ago) by mycroft
Branch: netbsd-1-2
CVS Tags: netbsd-1-2-PATCH001
Changes since 1.25.4.1: +178 -127 lines
Diff to previous 1.25.4.1 (colored) to branchpoint 1.25 (colored) next main 1.26 (colored) to selected 1.23 (colored)

From trunk:
Eliminate SS_PRIV; instead, pass down a proc pointer to the usrreq methods
that need it.
Fix numerous memory leaks and bogus return values.

Revision 1.25.4.1 / (download) - annotate - [select for diffs], Sun Nov 10 21:57:53 1996 UTC (17 years, 11 months ago) by thorpej
Branch: netbsd-1-2
Changes since 1.25: +9 -1 lines
Diff to previous 1.25 (colored) to selected 1.23 (colored)

Update from trunk:
- Make ip_len and ip_off unsigned.
- Make sure we don't accept or transmit packets larger than the
  maximim IP packet size.
This fixes the so-called `death ping' bug.

Sum of work from Bill Fenner <fenner@parc.xerox.com>,
Kevin Lahey <kml@nas.nasa.gov>, and myself.

Thanks to Curt Sampson, Jukka Marin, and Kevin Lahey for testing
this under NetBSD 1.2

Revision 1.35 / (download) - annotate - [select for diffs], Fri Oct 25 06:33:36 1996 UTC (18 years ago) by thorpej
Branch: MAIN
Changes since 1.34: +9 -1 lines
Diff to previous 1.34 (colored) to selected 1.23 (colored)

In rip_output(), sanity check the length of the packet to be transmitted.
If it's larger than IP_MAXPACKET, return an error condition.
Based on a patch from Bill Fenner <fenner@parc.xerox.com>

Revision 1.34 / (download) - annotate - [select for diffs], Mon Sep 16 17:45:17 1996 UTC (18 years, 1 month ago) by mycroft
Branch: MAIN
Changes since 1.33: +3 -1 lines
Diff to previous 1.33 (colored) to selected 1.23 (colored)

Make sure the sin_zero fields are filled.

Revision 1.33 / (download) - annotate - [select for diffs], Sun Sep 15 18:11:08 1996 UTC (18 years, 1 month ago) by mycroft
Branch: MAIN
Changes since 1.32: +2 -2 lines
Diff to previous 1.32 (colored) to selected 1.23 (colored)

Hash unconnected PCBs.

Revision 1.32 / (download) - annotate - [select for diffs], Mon Sep 9 14:51:19 1996 UTC (18 years, 1 month ago) by mycroft
Branch: MAIN
Changes since 1.31: +11 -8 lines
Diff to previous 1.31 (colored) to selected 1.23 (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.31 / (download) - annotate - [select for diffs], Sun Jun 23 12:12:49 1996 UTC (18 years, 4 months ago) by mycroft
Branch: MAIN
Changes since 1.30: +48 -43 lines
Diff to previous 1.30 (colored) to selected 1.23 (colored)

Return ENOPROTOOPT rather than picking pseudo-random error values.
Don't allow SIOCGET{VIF,SG}CNT from sockets other than the multicast router.
Restructure rip_ctloutput() like ip_ctloutput(), and fix memory leaks.

Revision 1.30 / (download) - annotate - [select for diffs], Tue May 28 23:27:04 1996 UTC (18 years, 5 months ago) by pk
Branch: MAIN
Changes since 1.29: +5 -1 lines
Diff to previous 1.29 (colored) to selected 1.23 (colored)

Prototype new rip_*() functions.

Revision 1.29 / (download) - annotate - [select for diffs], Fri May 24 19:03:13 1996 UTC (18 years, 5 months ago) by mycroft
Branch: MAIN
Changes since 1.28: +23 -24 lines
Diff to previous 1.28 (colored) to selected 1.23 (colored)

Move some code into a separate rip_bind() function.

Revision 1.28 / (download) - annotate - [select for diffs], Thu May 23 17:03:27 1996 UTC (18 years, 5 months ago) by mycroft
Branch: MAIN
Changes since 1.27: +17 -14 lines
Diff to previous 1.27 (colored) to selected 1.23 (colored)

Make sure the control mbufs are freed in all cases.

Revision 1.27 / (download) - annotate - [select for diffs], Thu May 23 16:12:15 1996 UTC (18 years, 5 months ago) by mycroft
Branch: MAIN
Changes since 1.26: +104 -66 lines
Diff to previous 1.26 (colored) to selected 1.23 (colored)

Minor changes to make this more like other protocols.  Also, fix some return
values.

Revision 1.26 / (download) - annotate - [select for diffs], Wed May 22 13:55:31 1996 UTC (18 years, 5 months ago) by mycroft
Branch: MAIN
Changes since 1.25: +6 -4 lines
Diff to previous 1.25 (colored) to selected 1.23 (colored)

Pass a proc pointer down to the usrreq and pcbbind functions for PRU_ATTACH, PRU_BIND and
PRU_CONTROL.  The usrreq interface really needs to be split up, but this will have to wait.
Remove SS_PRIV completely.

Revision 1.25 / (download) - annotate - [select for diffs], Sun Feb 18 18:58:33 1996 UTC (18 years, 8 months ago) by christos
Branch: MAIN
CVS Tags: netbsd-1-2-base, netbsd-1-2-RELEASE, netbsd-1-2-BETA
Branch point for: netbsd-1-2
Changes since 1.24: +4 -1 lines
Diff to previous 1.24 (colored) to selected 1.23 (colored)

Fix PR/2095 options MROUTING did not compile.

Revision 1.24 / (download) - annotate - [select for diffs], Tue Feb 13 23:43:29 1996 UTC (18 years, 8 months ago) by christos
Branch: MAIN
Changes since 1.23: +30 -9 lines
Diff to previous 1.23 (colored)

netinet prototypes

Revision 1.21.2.1 / (download) - annotate - [select for diffs], Fri Feb 2 06:12:52 1996 UTC (18 years, 9 months ago) by mycroft
Branch: netbsd-1-1
Changes since 1.21: +2 -2 lines
Diff to previous 1.21 (colored) next main 1.22 (colored) to selected 1.23 (colored)

Bring in changes for mondo patch 2.

Revision 1.23 / (download) - annotate - [selected], Wed Jan 31 03:49:31 1996 UTC (18 years, 9 months ago) by mycroft
Branch: MAIN
Changes since 1.22: +2 -2 lines
Diff to previous 1.22 (colored)

Build a hash table of PCBs.  Hash function needs tweaking.

Revision 1.22 / (download) - annotate - [select for diffs], Thu Nov 30 16:42:18 1995 UTC (18 years, 11 months ago) by pk
Branch: MAIN
Changes since 1.21: +11 -1 lines
Diff to previous 1.21 (colored) to selected 1.23 (colored)

Handle PRU_CONTROL (David Maltz; PR#1664).

Revision 1.21 / (download) - annotate - [select for diffs], Sun Jun 18 20:01:15 1995 UTC (19 years, 4 months ago) by cgd
Branch: MAIN
CVS Tags: netbsd-1-1-base, netbsd-1-1-RELEASE, netbsd-1-1-PATCH001
Branch point for: netbsd-1-1
Changes since 1.20: +4 -3 lines
Diff to previous 1.20 (colored) to selected 1.23 (colored)

convert pcb lists to CIRCLEQs, so that the end can be looked at more
easily, and so that the original (insque/remque) logic can be effectively
mimiced.  (This fixes a bug in the previous set of list changes.)
also (since terminator is no longer null) reinstate uninitted list checks,
but mark them XXX.

Revision 1.20 / (download) - annotate - [select for diffs], Mon Jun 12 00:47:49 1995 UTC (19 years, 4 months ago) by mycroft
Branch: MAIN
Changes since 1.19: +8 -7 lines
Diff to previous 1.19 (colored) to selected 1.23 (colored)

Various cleanup, including:
* Convert several data structures to use queue.h.
* Split in_pcbnotify() into two parts; one for notifying a specific PCB, and
one for notifying all PCBs for a particular foreign address.

Revision 1.19 / (download) - annotate - [select for diffs], Sun Jun 4 05:07:11 1995 UTC (19 years, 5 months ago) by mycroft
Branch: MAIN
Changes since 1.18: +6 -6 lines
Diff to previous 1.18 (colored) to selected 1.23 (colored)

Clean up many more casts.

Revision 1.18 / (download) - annotate - [select for diffs], Wed May 31 21:50:44 1995 UTC (19 years, 5 months ago) by mycroft
Branch: MAIN
Changes since 1.17: +20 -15 lines
Diff to previous 1.17 (colored) to selected 1.23 (colored)

Integrate multicast 3.5 distribution, with several bugs fixed and general
cleanup.  This is a (working) snapshot of work in progress.

Revision 1.17 / (download) - annotate - [select for diffs], Thu Apr 13 06:36:21 1995 UTC (19 years, 6 months ago) by cgd
Branch: MAIN
Changes since 1.16: +3 -3 lines
Diff to previous 1.16 (colored) to selected 1.23 (colored)

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

Revision 1.16 / (download) - annotate - [select for diffs], Thu Mar 2 09:33:40 1995 UTC (19 years, 8 months ago) by glass
Branch: MAIN
Changes since 1.15: +3 -3 lines
Diff to previous 1.15 (colored) to selected 1.23 (colored)

Fix for two bad tests in the raw IP socket input code.  Only affected
raw sockets that were bound to a local address and/or connected to a
foreign address.   Fix from Dan McDonald <danmcd@itd.nrl.navy.mil>

Revision 1.15 / (download) - annotate - [select for diffs], Thu Jan 12 06:23:45 1995 UTC (19 years, 9 months ago) by mycroft
Branch: MAIN
Changes since 1.14: +5 -2 lines
Diff to previous 1.14 (colored) to selected 1.23 (colored)

Fix mbuf leak in rip_ctloutput().

Revision 1.14 / (download) - annotate - [select for diffs], Wed Jun 29 06:38:31 1994 UTC (20 years, 4 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.13: +3 -2 lines
Diff to previous 1.13 (colored) to selected 1.23 (colored)

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

Revision 1.13 / (download) - annotate - [select for diffs], Fri May 13 06:06:30 1994 UTC (20 years, 5 months ago) by mycroft
Branch: MAIN
Changes since 1.12: +233 -140 lines
Diff to previous 1.12 (colored) to selected 1.23 (colored)

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

Revision 1.12 / (download) - annotate - [select for diffs], Thu Feb 10 18:46:05 1994 UTC (20 years, 8 months ago) by mycroft
Branch: MAIN
Changes since 1.11: +4 -4 lines
Diff to previous 1.11 (colored) to selected 1.23 (colored)

Format police.

Revision 1.11 / (download) - annotate - [select for diffs], Wed Feb 2 05:59:08 1994 UTC (20 years, 9 months ago) by hpeyerl
Branch: MAIN
Changes since 1.10: +4 -19 lines
Diff to previous 1.10 (colored) to selected 1.23 (colored)

Multicast is no longer optional.

Revision 1.10 / (download) - annotate - [select for diffs], Mon Jan 10 20:14:28 1994 UTC (20 years, 9 months ago) by mycroft
Branch: MAIN
Changes since 1.9: +10 -7 lines
Diff to previous 1.9 (colored) to selected 1.23 (colored)

Should compile now with or without `options MULTICAST'.

Revision 1.9 / (download) - annotate - [select for diffs], Sun Jan 9 01:06:21 1994 UTC (20 years, 9 months ago) by mycroft
Branch: MAIN
Changes since 1.8: +7 -2 lines
Diff to previous 1.8 (colored) to selected 1.23 (colored)

Prototype the rest.

Revision 1.8 / (download) - annotate - [select for diffs], Sat Jan 8 21:21:55 1994 UTC (20 years, 9 months ago) by mycroft
Branch: MAIN
Changes since 1.7: +5 -5 lines
Diff to previous 1.7 (colored) to selected 1.23 (colored)

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

Revision 1.7 / (download) - annotate - [select for diffs], Sat Dec 18 00:42:00 1993 UTC (20 years, 10 months ago) by mycroft
Branch: MAIN
Changes since 1.6: +16 -16 lines
Diff to previous 1.6 (colored) to selected 1.23 (colored)

Canonicalize all #includes.

Revision 1.6 / (download) - annotate - [select for diffs], Mon Dec 6 04:59:44 1993 UTC (20 years, 10 months ago) by hpeyerl
Branch: MAIN
Changes since 1.5: +45 -5 lines
Diff to previous 1.5 (colored) to selected 1.23 (colored)

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

Revision 1.5 / (download) - annotate - [select for diffs], Sat May 22 11:42:37 1993 UTC (21 years, 5 months ago) by cgd
Branch: MAIN
CVS Tags: netbsd-0-9-patch-001, netbsd-0-9-base, netbsd-0-9-RELEASE, netbsd-0-9-BETA, netbsd-0-9-ALPHA2, netbsd-0-9-ALPHA, netbsd-0-9, magnum-base, magnum
Changes since 1.4: +1 -2 lines
Diff to previous 1.4 (colored) to selected 1.23 (colored)

add include of select.h if necessary for protos, or delete if extraneous

Revision 1.4 / (download) - annotate - [select for diffs], Fri May 21 05:27:15 1993 UTC (21 years, 5 months ago) by cgd
Branch: MAIN
Changes since 1.3: +6 -3 lines
Diff to previous 1.3 (colored) to selected 1.23 (colored)

add packet size check for raw IP provided by Paul Antonov <apg@apg.kiae.su>,
to fix the "traceroute foohost 2000 == panic" problem.

Revision 1.3 / (download) - annotate - [select for diffs], Tue May 18 18:20:12 1993 UTC (21 years, 5 months ago) by cgd
Branch: MAIN
Changes since 1.2: +3 -9 lines
Diff to previous 1.2 (colored) to selected 1.23 (colored)

make kernel select interface be one-stop shopping & clean it all up.

Revision 1.2 / (download) - annotate - [select for diffs], Sun Mar 21 18:04:42 1993 UTC (21 years, 7 months ago) by cgd
Branch: MAIN
CVS Tags: patchkit-0-2-2, netbsd-alpha-1, netbsd-0-8
Changes since 1.1: +10 -2 lines
Diff to previous 1.1 (colored) to selected 1.23 (colored)

after 0.2.2 "stable" patches applied

Revision 1.1.1.1 / (download) - annotate - [select for diffs] (vendor branch), Sun Mar 21 09:45:37 1993 UTC (21 years, 7 months ago) by cgd
Branch: WFJ-920714, CSRG
CVS Tags: WFJ-386bsd-01
Changes since 1.1: +0 -0 lines
Diff to previous 1.1 (colored) to selected 1.23 (colored)

initial import of 386bsd-0.1 sources

Revision 1.1 / (download) - annotate - [select for diffs], Sun Mar 21 09:45:37 1993 UTC (21 years, 7 months ago) by cgd
Branch: MAIN
Diff to selected 1.23 (colored)

Initial revision

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>