From 788121397c48ab3e5e5b7c8ceec3f401876d8e1e Mon Sep 17 00:00:00 2001 From: Eirik Nygaard Date: Fri, 15 Jul 2005 17:54:48 +0000 Subject: [PATCH] Tie SCTP into the kernel, this includes adding a new syscall (sctp_peeloff). Obtained from: KAME --- sys/conf/files | 15 +++++- sys/conf/options | 15 +++++- sys/kern/init_sysent.c | 4 +- sys/kern/syscalls.c | 4 +- sys/kern/syscalls.master | 7 ++- sys/kern/uipc_socket.c | 60 ++++++++++++++++++++---- sys/kern/uipc_syscalls.c | 99 +++++++++++++++++++++++++++++++++++++++- sys/net/rtsock.c | 21 ++++++++- sys/netinet/in.h | 3 +- sys/netinet/in_proto.c | 37 ++++++++++++++- sys/sys/mbuf.h | 3 +- sys/sys/protosw.h | 5 +- sys/sys/socket.h | 3 +- sys/sys/syscall-args | 3 +- sys/sys/syscall-hide.h | 3 +- sys/sys/syscall.h | 3 +- sys/sys/syscall.mk | 3 +- sys/sys/sysproto.h | 11 ++++- sys/sys/sysunion.h | 3 +- 19 files changed, 269 insertions(+), 33 deletions(-) diff --git a/sys/conf/files b/sys/conf/files index f0bd857011..e158149889 100644 --- a/sys/conf/files +++ b/sys/conf/files @@ -1,5 +1,5 @@ # $FreeBSD: src/sys/conf/files,v 1.340.2.137 2003/06/04 17:10:30 sam Exp $ -# $DragonFly: src/sys/conf/files,v 1.97 2005/07/13 17:31:05 joerg Exp $ +# $DragonFly: src/sys/conf/files,v 1.98 2005/07/15 17:54:47 eirikn Exp $ # # The long compile-with and dependency lines are required because of # limitations in config: backslash-newline doesn't work in strings, and @@ -1020,6 +1020,19 @@ netinet6/in6.c optional inet6 netinet6/in6_cksum.c optional inet6 netinet6/in6_gif.c optional gif inet6 netinet6/ip6_forward.c optional inet6 +netinet/sctp_asconf.c optional inet sctp +netinet/sctp_crc32.c optional inet sctp +netinet/sctp_hashdriver.c optional inet sctp +netinet/sctp_indata.c optional inet sctp +netinet/sctp_input.c optional inet sctp +netinet/sctp_output.c optional inet sctp +netinet/sctp_pcb.c optional inet sctp +netinet/sctp_peeloff.c optional inet sctp +netinet/sctp_sha1.c optional inet sctp +netinet/sctp_timer.c optional inet sctp +netinet/sctp_usrreq.c optional inet sctp +netinet/sctputil.c optional inet sctp +netinet6/sctp6_usrreq.c optional inet6 sctp net/ip6fw/ip6_fw.c optional inet6 ipv6firewall netinet6/in6_ifattach.c optional inet6 netinet6/ip6_input.c optional inet6 diff --git a/sys/conf/options b/sys/conf/options index df50382d24..8176748e22 100644 --- a/sys/conf/options +++ b/sys/conf/options @@ -1,5 +1,5 @@ # $FreeBSD: src/sys/conf/options,v 1.191.2.53 2003/06/04 17:56:58 sam Exp $ -# $DragonFly: src/sys/conf/options,v 1.33 2005/06/20 17:59:31 dillon Exp $ +# $DragonFly: src/sys/conf/options,v 1.34 2005/07/15 17:54:47 eirikn Exp $ # # On the handling of kernel options # @@ -546,3 +546,16 @@ DCONS_FORCE_GDB opt_dcons.h # depricated drivers and options I_WANT_DEPRECATED_STUFF opt_deprecated.h + +# SCTP +SCTP opt_sctp.h +SCTP_DEBUG opt_sctp.h +SCTP_TCP_MODEL_SUPPORT opt_sctp.h +SCTP_USE_ADLER32 opt_sctp.h +SCTP_HIGH_SPEED opt_sctp.h +SCTP_STAT_LOGGIN opt_sctp.h +SCTP_CWND_LOGGING opt_sctp.h +SCTP_BLK_LOGGING opt_sctp.h +SCTP_STR_LOGGING opt_sctp.h +SCTP_FR_LOGGING opt_sctp.h +SCTP_MAP_LOGGING opt_sctp.h diff --git a/sys/kern/init_sysent.c b/sys/kern/init_sysent.c index 23cc33e463..9ae0edfc93 100644 --- a/sys/kern/init_sysent.c +++ b/sys/kern/init_sysent.c @@ -2,7 +2,7 @@ * System call switch table. * * DO NOT EDIT-- this file is automatically generated. - * $DragonFly: src/sys/kern/init_sysent.c,v 1.28 2005/04/08 08:31:45 joerg Exp $ + * $DragonFly: src/sys/kern/init_sysent.c,v 1.29 2005/07/15 17:54:47 eirikn Exp $ * created from DragonFly: src/sys/kern/syscalls.master,v 1.22 2005/04/08 08:31:06 joerg Exp */ @@ -386,7 +386,7 @@ struct sysent sysent[] = { { AS(getresgid_args), (sy_call_t *)getresgid }, /* 361 = getresgid */ { 0, (sy_call_t *)kqueue }, /* 362 = kqueue */ { AS(kevent_args), (sy_call_t *)kevent }, /* 363 = kevent */ - { 0, (sy_call_t *)nosys }, /* 364 = nosys */ + { AS(sctp_peeloff_args), (sy_call_t *)sctp_peeloff }, /* 364 = sctp_peeloff */ { 0, (sy_call_t *)nosys }, /* 365 = nosys */ { 0, (sy_call_t *)nosys }, /* 366 = nosys */ { 0, (sy_call_t *)nosys }, /* 367 = nosys */ diff --git a/sys/kern/syscalls.c b/sys/kern/syscalls.c index 70c2c41c48..bd79ed1cce 100644 --- a/sys/kern/syscalls.c +++ b/sys/kern/syscalls.c @@ -2,7 +2,7 @@ * System call names. * * DO NOT EDIT-- this file is automatically generated. - * $DragonFly: src/sys/kern/syscalls.c,v 1.27 2005/04/08 08:31:45 joerg Exp $ + * $DragonFly: src/sys/kern/syscalls.c,v 1.28 2005/07/15 17:54:47 eirikn Exp $ * created from DragonFly: src/sys/kern/syscalls.master,v 1.22 2005/04/08 08:31:06 joerg Exp */ @@ -371,7 +371,7 @@ char *syscallnames[] = { "getresgid", /* 361 = getresgid */ "kqueue", /* 362 = kqueue */ "kevent", /* 363 = kevent */ - "#364", /* 364 = nosys */ + "sctp_peeloff", /* 364 = sctp_peeloff */ "#365", /* 365 = nosys */ "#366", /* 366 = nosys */ "#367", /* 367 = nosys */ diff --git a/sys/kern/syscalls.master b/sys/kern/syscalls.master index 877c322d33..ed370faa58 100644 --- a/sys/kern/syscalls.master +++ b/sys/kern/syscalls.master @@ -1,4 +1,4 @@ - $DragonFly: src/sys/kern/syscalls.master,v 1.22 2005/04/08 08:31:06 joerg Exp $ + $DragonFly: src/sys/kern/syscalls.master,v 1.23 2005/07/15 17:54:47 eirikn Exp $ ; @(#)syscalls.master 8.2 (Berkeley) 1/13/94 ; $FreeBSD: src/sys/kern/syscalls.master,v 1.72.2.10 2002/07/12 08:22:46 alfred Exp $ @@ -522,9 +522,8 @@ const struct kevent *changelist, int nchanges, \ struct kevent *eventlist, int nevents, \ const struct timespec *timeout); } - -; 364-392 used by FreeBSD-current -364 UNIMPL NOHIDE nosys +364 STD BSD { int sctp_peeloff(int sd, caddr_t name ); } +; 365-392 used by FreeBSD-current 365 UNIMPL NOHIDE nosys 366 UNIMPL NOHIDE nosys 367 UNIMPL NOHIDE nosys diff --git a/sys/kern/uipc_socket.c b/sys/kern/uipc_socket.c index c0134608d3..6bc2363507 100644 --- a/sys/kern/uipc_socket.c +++ b/sys/kern/uipc_socket.c @@ -82,10 +82,11 @@ * * @(#)uipc_socket.c 8.3 (Berkeley) 4/15/94 * $FreeBSD: src/sys/kern/uipc_socket.c,v 1.68.2.24 2003/11/11 17:18:18 silby Exp $ - * $DragonFly: src/sys/kern/uipc_socket.c,v 1.34 2005/06/07 19:08:55 hsu Exp $ + * $DragonFly: src/sys/kern/uipc_socket.c,v 1.35 2005/07/15 17:54:47 eirikn Exp $ */ #include "opt_inet.h" +#include "opt_sctp.h" #include #include @@ -259,23 +260,40 @@ int solisten(struct socket *so, int backlog, struct thread *td) { int error; +#ifdef SCTP + short oldopt, oldqlimit; +#endif /* SCTP */ crit_enter(); - if (so->so_state & (SS_ISCONNECTED | SS_ISCONNECTING)) { + if (so->so_state & (SS_ISCONNECTED | SS_ISCONNECTING)) { crit_exit(); - return (EINVAL); - } - - error = so_pru_listen(so, td); - if (error) { - crit_exit(); - return (error); + return (EINVAL); } + +#ifdef SCTP + oldopt = so->so_options; + oldqlimit = so->so_qlimit; +#endif /* SCTP */ + if (TAILQ_EMPTY(&so->so_comp)) so->so_options |= SO_ACCEPTCONN; if (backlog < 0 || backlog > somaxconn) backlog = somaxconn; so->so_qlimit = backlog; + /* SCTP needs to look at tweak both the inbound backlog parameter AND + * the so_options (UDP model both connect's and gets inbound + * connections .. implicitly). + */ + error = so_pru_listen(so, td); + if (error) { +#ifdef SCTP + /* Restore the params */ + so->so_options = oldopt; + so->so_qlimit = oldqlimit; +#endif /* SCTP */ + crit_exit(); + return (error); + } crit_exit(); return (0); } @@ -891,6 +909,26 @@ dontblock: m = so->so_rcv.sb_mb; } } +#ifdef SCTP + if (pr->pr_flags & PR_ADDR_OPT) { + /* + * For SCTP we may be getting a + * whole message OR a partial delivery. + */ + if (m->m_type == MT_SONAME) { + orig_resid = 0; + if (psa) + *psa = dup_sockaddr(mtod(m, struct sockaddr *)); + if (flags & MSG_PEEK) { + m = m->m_next; + } else { + sbfree(&so->so_rcv, m); + so->so_rcv.sb_mb = m_free(m); + m = so->so_rcv.sb_mb; + } + } + } +#endif /* SCTP */ while (m && m->m_type == MT_CONTROL && error == 0) { if (flags & MSG_PEEK) { if (controlp) @@ -961,6 +999,10 @@ dontblock: if (len == m->m_len - moff) { if (m->m_flags & M_EOR) flags |= MSG_EOR; +#ifdef SCTP + if (m->m_flags & M_NOTIFICATION) + flags |= MSG_NOTIFICATION; +#endif /* SCTP */ if (flags & MSG_PEEK) { m = m->m_next; moff = 0; diff --git a/sys/kern/uipc_syscalls.c b/sys/kern/uipc_syscalls.c index a7164bc94a..23ecac1b17 100644 --- a/sys/kern/uipc_syscalls.c +++ b/sys/kern/uipc_syscalls.c @@ -35,10 +35,11 @@ * * @(#)uipc_syscalls.c 8.4 (Berkeley) 2/21/94 * $FreeBSD: src/sys/kern/uipc_syscalls.c,v 1.65.2.17 2003/04/04 17:11:16 tegge Exp $ - * $DragonFly: src/sys/kern/uipc_syscalls.c,v 1.56 2005/07/13 01:38:50 dillon Exp $ + * $DragonFly: src/sys/kern/uipc_syscalls.c,v 1.57 2005/07/15 17:54:47 eirikn Exp $ */ #include "opt_ktrace.h" +#include "opt_sctp.h" #include #include @@ -77,6 +78,10 @@ #include #include +#ifdef SCTP +#include +#endif /* SCTP */ + struct sfbuf_mref { struct sf_buf *sf; int mref_count; @@ -1673,3 +1678,95 @@ done0: m_freem(mheader); return (error); } + +int +sctp_peeloff(struct sctp_peeloff_args *uap) +{ +#ifdef SCTP + struct thread *td = curthread; + struct proc *p = td->td_proc; + struct filedesc *fdp = p->p_fd; + struct file *lfp = NULL; + struct file *nfp = NULL; + int error; + struct socket *head, *so; + caddr_t assoc_id; + int fd; + short fflag; /* type must match fp->f_flag */ + + assoc_id = uap->name; + error = holdsock(fdp, uap->sd, &lfp); + if (error) { + return (error); + } + crit_enter(); + head = (struct socket *)lfp->f_data; + error = sctp_can_peel_off(head, assoc_id); + if (error) { + crit_exit(); + goto done; + } + /* + * At this point we know we do have a assoc to pull + * we proceed to get the fd setup. This may block + * but that is ok. + */ + + fflag = lfp->f_flag; + error = falloc(p, &nfp, &fd); + if (error) { + /* + * Probably ran out of file descriptors. Put the + * unaccepted connection back onto the queue and + * do another wakeup so some other process might + * have a chance at it. + */ + crit_exit(); + goto done; + } + fhold(nfp); + uap->sysmsg_result = fd; + + so = sctp_get_peeloff(head, assoc_id, &error); + if (so == NULL) { + /* + * Either someone else peeled it off OR + * we can't get a socket. + */ + goto noconnection; + } + so->so_state &= ~SS_COMP; + so->so_state &= ~SS_NOFDREF; + so->so_head = NULL; + if (head->so_sigio != NULL) + fsetown(fgetown(head->so_sigio), &so->so_sigio); + + nfp->f_data = (caddr_t)so; + nfp->f_flag = fflag; + nfp->f_ops = &socketops; + nfp->f_type = DTYPE_SOCKET; + +noconnection: + /* + * close the new descriptor, assuming someone hasn't ripped it + * out from under us. + */ + if (error) { + if (fdp->fd_files[fd].fp == nfp) { + funsetfd(fdp, fd); + fdrop(nfp, td); + } + } + crit_exit(); + /* + * Release explicitly held references before returning. + */ +done: + if (nfp != NULL) + fdrop(nfp, td); + fdrop(lfp, td); + return (error); +#else /* SCTP */ + return(EOPNOTSUPP); +#endif /* SCTP */ +} diff --git a/sys/net/rtsock.c b/sys/net/rtsock.c index d2c703db66..83433794f9 100644 --- a/sys/net/rtsock.c +++ b/sys/net/rtsock.c @@ -82,9 +82,11 @@ * * @(#)rtsock.c 8.7 (Berkeley) 10/12/95 * $FreeBSD: src/sys/net/rtsock.c,v 1.44.2.11 2002/12/04 14:05:41 ru Exp $ - * $DragonFly: src/sys/net/rtsock.c,v 1.28 2005/06/14 19:47:30 joerg Exp $ + * $DragonFly: src/sys/net/rtsock.c,v 1.29 2005/07/15 17:54:47 eirikn Exp $ */ +#include "opt_sctp.h" + #include #include #include @@ -102,6 +104,11 @@ #include #include +#ifdef SCTP +extern void sctp_add_ip_address(struct ifaddr *ifa); +extern void sctp_delete_ip_address(struct ifaddr *ifa); +#endif /* SCTP */ + MALLOC_DEFINE(M_RTABLE, "routetbl", "routing tables"); static struct route_cb { @@ -936,6 +943,18 @@ rt_rtmsg(int cmd, struct rtentry *rt, struct ifnet *ifp, int error) void rt_newaddrmsg(int cmd, struct ifaddr *ifa, int error, struct rtentry *rt) { +#ifdef SCTP + /* + * notify the SCTP stack + * this will only get called when an address is added/deleted + * XXX pass the ifaddr struct instead if ifa->ifa_addr... + */ + if (cmd == RTM_ADD) + sctp_add_ip_address(ifa); + else if (cmd == RTM_DELETE) + sctp_delete_ip_address(ifa); +#endif /* SCTP */ + if (route_cb.any_count == 0) return; diff --git a/sys/netinet/in.h b/sys/netinet/in.h index 2ebaec9633..a029255c9d 100644 --- a/sys/netinet/in.h +++ b/sys/netinet/in.h @@ -32,7 +32,7 @@ * * @(#)in.h 8.3 (Berkeley) 1/3/94 * $FreeBSD: src/sys/netinet/in.h,v 1.48.2.10 2003/08/24 08:24:38 hsu Exp $ - * $DragonFly: src/sys/netinet/in.h,v 1.12 2005/07/13 14:11:42 joerg Exp $ + * $DragonFly: src/sys/netinet/in.h,v 1.13 2005/07/15 17:54:47 eirikn Exp $ */ #ifndef _NETINET_IN_H_ @@ -170,6 +170,7 @@ /* 101-254: Partly Unassigned */ #define IPPROTO_PIM 103 /* Protocol Independent Mcast */ #define IPPROTO_PGM 113 /* PGM */ +#define IPPROTO_SCTP 132 /* SCTP */ #define IPPROTO_PFSYNC 240 /* PFSYNC */ /* 255: Reserved */ /* BSD Private, local use, namespace incursion */ diff --git a/sys/netinet/in_proto.c b/sys/netinet/in_proto.c index d1dcc230ee..ab5bfcaa61 100644 --- a/sys/netinet/in_proto.c +++ b/sys/netinet/in_proto.c @@ -32,7 +32,7 @@ * * @(#)in_proto.c 8.2 (Berkeley) 2/9/95 * $FreeBSD: src/sys/netinet/in_proto.c,v 1.53.2.7 2003/08/24 08:24:38 hsu Exp $ - * $DragonFly: src/sys/netinet/in_proto.c,v 1.12 2005/03/04 02:21:48 hsu Exp $ + * $DragonFly: src/sys/netinet/in_proto.c,v 1.13 2005/07/15 17:54:47 eirikn Exp $ */ #include "opt_ipdivert.h" @@ -40,6 +40,7 @@ #include "opt_mrouting.h" #include "opt_ipsec.h" #include "opt_inet6.h" +#include "opt_sctp.h" #include #include @@ -95,6 +96,13 @@ #include #endif +#ifdef SCTP +#include +#include +#include +#include +#endif /* SCTP */ + #include /* for cpu0_soport */ extern struct domain inetdomain; @@ -120,6 +128,33 @@ struct protosw inetsw[] = { tcp_init, 0, tcp_slowtimo, tcp_drain, &tcp_usrreqs }, +#ifdef SCTP +/* + * Order is very important here, we add the good one in + * in this postion so it maps to the right ip_protox[] + * postion for SCTP. Don't move the one above below + * this one or IPv6/4 compatability will break + */ +{ SOCK_DGRAM, &inetdomain, IPPROTO_SCTP, PR_ADDR_OPT|PR_WANTRCVD, + sctp_input, 0, sctp_ctlinput, sctp_ctloutput, + cpu0_soport, + sctp_init, 0, 0, sctp_drain, + &sctp_usrreqs +}, +{ SOCK_SEQPACKET,&inetdomain, IPPROTO_SCTP, PR_ADDR_OPT|PR_WANTRCVD, + sctp_input, 0, sctp_ctlinput, sctp_ctloutput, + cpu0_soport, + 0, 0, 0, sctp_drain, + &sctp_usrreqs +}, + +{ SOCK_STREAM, &inetdomain, IPPROTO_SCTP, PR_CONNREQUIRED|PR_ADDR_OPT|PR_WANTRCVD, + sctp_input, 0, sctp_ctlinput, sctp_ctloutput, + cpu0_soport, + 0, 0, 0, sctp_drain, + &sctp_usrreqs +}, +#endif /* SCTP */ { SOCK_RAW, &inetdomain, IPPROTO_RAW, PR_ATOMIC|PR_ADDR, rip_input, 0, rip_ctlinput, rip_ctloutput, cpu0_soport, diff --git a/sys/sys/mbuf.h b/sys/sys/mbuf.h index d917a5e907..dfca6cab72 100644 --- a/sys/sys/mbuf.h +++ b/sys/sys/mbuf.h @@ -34,7 +34,7 @@ * * @(#)mbuf.h 8.5 (Berkeley) 2/19/95 * $FreeBSD: src/sys/sys/mbuf.h,v 1.44.2.17 2003/04/15 06:15:02 silby Exp $ - * $DragonFly: src/sys/sys/mbuf.h,v 1.31 2005/06/17 19:12:18 dillon Exp $ + * $DragonFly: src/sys/sys/mbuf.h,v 1.32 2005/07/15 17:54:48 eirikn Exp $ */ #ifndef _SYS_MBUF_H_ @@ -184,6 +184,7 @@ struct mbuf { #define M_CLCACHE 0x2000 /* mbuf allocated from the cluster cache */ #define M_EXT_CLUSTER 0x4000 /* standard cluster else special */ #define M_PHCACHE 0x8000 /* mbuf allocated from the pkt header cache */ +#define M_NOTIFICATION 0x10000 /* notification event */ /* * Flags copied when copying m_pkthdr. diff --git a/sys/sys/protosw.h b/sys/sys/protosw.h index d889b63827..32596f9080 100644 --- a/sys/sys/protosw.h +++ b/sys/sys/protosw.h @@ -32,7 +32,7 @@ * * @(#)protosw.h 8.1 (Berkeley) 6/2/93 * $FreeBSD: src/sys/sys/protosw.h,v 1.28.2.2 2001/07/03 11:02:01 ume Exp $ - * $DragonFly: src/sys/sys/protosw.h,v 1.14 2005/03/04 02:21:49 hsu Exp $ + * $DragonFly: src/sys/sys/protosw.h,v 1.15 2005/07/15 17:54:48 eirikn Exp $ */ #ifndef _SYS_PROTOSW_H_ @@ -117,8 +117,9 @@ struct protosw { #define PR_CONNREQUIRED 0x04 /* connection required by protocol */ #define PR_WANTRCVD 0x08 /* want PRU_RCVD calls */ #define PR_RIGHTS 0x10 /* passes capabilities */ -#define PR_IMPLOPCL 0x20 /* implied open/close */ +#define PR_IMPLOPCL 0x20 /* implied open/close */ #define PR_LASTHDR 0x40 /* enforce ipsec policy; last header */ +#define PR_ADDR_OPT 0x80 /* allow addresses during delivery */ /* * The arguments to usrreq are: diff --git a/sys/sys/socket.h b/sys/sys/socket.h index c437499b61..35f3b30e23 100644 --- a/sys/sys/socket.h +++ b/sys/sys/socket.h @@ -32,7 +32,7 @@ * * @(#)socket.h 8.4 (Berkeley) 2/21/94 * $FreeBSD: src/sys/sys/socket.h,v 1.39.2.7 2001/07/03 11:02:01 ume Exp $ - * $DragonFly: src/sys/sys/socket.h,v 1.10 2005/01/26 23:09:58 hsu Exp $ + * $DragonFly: src/sys/sys/socket.h,v 1.11 2005/07/15 17:54:48 eirikn Exp $ */ #ifndef _SYS_SOCKET_H_ @@ -342,6 +342,7 @@ struct msghdr { #define MSG_WAITALL 0x40 /* wait for full request or error */ #define MSG_DONTWAIT 0x80 /* this message should be nonblocking */ #define MSG_EOF 0x100 /* data completes connection */ +#define MSG_NOTIFICATION 0x200 /* notification message */ /* * Header for ancillary data objects in msg_control buffer. diff --git a/sys/sys/syscall-args b/sys/sys/syscall-args index 326858ed11..f50aa41932 100644 --- a/sys/sys/syscall-args +++ b/sys/sys/syscall-args @@ -1,6 +1,6 @@ # System call argument table. # DO NOT EDIT-- this file is automatically generated. -# $DragonFly: src/sys/sys/Attic/syscall-args,v 1.12 2005/04/08 08:31:45 joerg Exp $ +# $DragonFly: src/sys/sys/Attic/syscall-args,v 1.13 2005/07/15 17:54:48 eirikn Exp $ # Created from DragonFly: src/sys/kern/syscalls.master,v 1.22 2005/04/08 08:31:06 joerg Exp @@ -238,6 +238,7 @@ int getresuid getresuid getresuid_args uid_t * ruid uid_t * euid uid_t * suid int getresgid getresgid getresgid_args gid_t * rgid gid_t * egid gid_t * sgid int kqueue kqueue kqueue_args int kevent kevent kevent_args int fd const struct kevent * changelist int nchanges struct kevent * eventlist int nevents const struct timespec * timeout +int sctp_peeloff sctp_peeloff sctp_peeloff_args int sd caddr_t name int sendfile sendfile sendfile_args int fd int s off_t offset size_t nbytes struct sf_hdtr * hdtr off_t * sbytes int flags int varsym_set varsym_set varsym_set_args int level const char * name const char * data int varsym_get varsym_get varsym_get_args int mask const char * wild char * buf int bufsize diff --git a/sys/sys/syscall-hide.h b/sys/sys/syscall-hide.h index ddcdd88843..e9b8d6752f 100644 --- a/sys/sys/syscall-hide.h +++ b/sys/sys/syscall-hide.h @@ -2,7 +2,7 @@ * System call hiders. * * DO NOT EDIT-- this file is automatically generated. - * $DragonFly: src/sys/sys/syscall-hide.h,v 1.29 2005/04/08 08:31:45 joerg Exp $ + * $DragonFly: src/sys/sys/syscall-hide.h,v 1.30 2005/07/15 17:54:48 eirikn Exp $ * created from DragonFly: src/sys/kern/syscalls.master,v 1.22 2005/04/08 08:31:06 joerg Exp */ @@ -276,6 +276,7 @@ HIDE_BSD(getresuid) HIDE_BSD(getresgid) HIDE_BSD(kqueue) HIDE_BSD(kevent) +HIDE_BSD(sctp_peeloff) HIDE_BSD(sendfile) HIDE_BSD(varsym_set) HIDE_BSD(varsym_get) diff --git a/sys/sys/syscall.h b/sys/sys/syscall.h index b4f9873ab9..37851781b6 100644 --- a/sys/sys/syscall.h +++ b/sys/sys/syscall.h @@ -2,7 +2,7 @@ * System call numbers. * * DO NOT EDIT-- this file is automatically generated. - * $DragonFly: src/sys/sys/syscall.h,v 1.29 2005/04/08 08:31:45 joerg Exp $ + * $DragonFly: src/sys/sys/syscall.h,v 1.30 2005/07/15 17:54:48 eirikn Exp $ * created from DragonFly: src/sys/kern/syscalls.master,v 1.22 2005/04/08 08:31:06 joerg Exp */ @@ -287,6 +287,7 @@ #define SYS_getresgid 361 #define SYS_kqueue 362 #define SYS_kevent 363 +#define SYS_sctp_peeloff 364 #define SYS_sendfile 393 #define SYS_varsym_set 450 #define SYS_varsym_get 451 diff --git a/sys/sys/syscall.mk b/sys/sys/syscall.mk index a2d317c4c9..a61e8b0934 100644 --- a/sys/sys/syscall.mk +++ b/sys/sys/syscall.mk @@ -1,6 +1,6 @@ # DragonFly system call names. # DO NOT EDIT-- this file is automatically generated. -# $DragonFly: src/sys/sys/syscall.mk,v 1.29 2005/04/08 08:31:45 joerg Exp $ +# $DragonFly: src/sys/sys/syscall.mk,v 1.30 2005/07/15 17:54:48 eirikn Exp $ # created from DragonFly: src/sys/kern/syscalls.master,v 1.22 2005/04/08 08:31:06 joerg Exp MIASM = \ syscall.o \ @@ -237,6 +237,7 @@ MIASM = \ getresgid.o \ kqueue.o \ kevent.o \ + sctp_peeloff.o \ sendfile.o \ varsym_set.o \ varsym_get.o \ diff --git a/sys/sys/sysproto.h b/sys/sys/sysproto.h index 3c05b65176..71be9f113d 100644 --- a/sys/sys/sysproto.h +++ b/sys/sys/sysproto.h @@ -2,7 +2,7 @@ * System call prototypes. * * DO NOT EDIT-- this file is automatically generated. - * $DragonFly: src/sys/sys/sysproto.h,v 1.29 2005/04/08 08:31:45 joerg Exp $ + * $DragonFly: src/sys/sys/sysproto.h,v 1.30 2005/07/15 17:54:48 eirikn Exp $ * created from DragonFly: src/sys/kern/syscalls.master,v 1.22 2005/04/08 08:31:06 joerg Exp */ @@ -1960,6 +1960,14 @@ struct kevent_args { int nevents; char nevents_[PAD_(int)]; const struct timespec * timeout; char timeout_[PAD_(const struct timespec *)]; }; +struct sctp_peeloff_args { +#ifdef _KERNEL + struct sysmsg sysmsg; +#endif + union usrmsg usrmsg; + int sd; char sd_[PAD_(int)]; + caddr_t name; char name_[PAD_(caddr_t)]; +}; struct sendfile_args { #ifdef _KERNEL struct sysmsg sysmsg; @@ -2436,6 +2444,7 @@ int getresuid (struct getresuid_args *); int getresgid (struct getresgid_args *); int kqueue (struct kqueue_args *); int kevent (struct kevent_args *); +int sctp_peeloff (struct sctp_peeloff_args *); int sendfile (struct sendfile_args *); int varsym_set (struct varsym_set_args *); int varsym_get (struct varsym_get_args *); diff --git a/sys/sys/sysunion.h b/sys/sys/sysunion.h index 3fd245327c..c17d36eee9 100644 --- a/sys/sys/sysunion.h +++ b/sys/sys/sysunion.h @@ -2,7 +2,7 @@ * Union of syscall args for messaging. * * DO NOT EDIT-- this file is automatically generated. - * $DragonFly: src/sys/sys/sysunion.h,v 1.26 2005/04/08 08:31:45 joerg Exp $ + * $DragonFly: src/sys/sys/sysunion.h,v 1.27 2005/07/15 17:54:48 eirikn Exp $ * created from DragonFly: src/sys/kern/syscalls.master,v 1.22 2005/04/08 08:31:06 joerg Exp */ @@ -321,6 +321,7 @@ union sysunion { struct getresgid_args getresgid; struct kqueue_args kqueue; struct kevent_args kevent; + struct sctp_peeloff_args sctp_peeloff; struct sendfile_args sendfile; struct varsym_set_args varsym_set; struct varsym_get_args varsym_get; -- 2.41.0