From owner-p4-projects Thu Aug 29 17:51:19 2002 Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id 22D1D37B401; Thu, 29 Aug 2002 17:49:40 -0700 (PDT) Delivered-To: perforce@freebsd.org Received: from mx1.FreeBSD.org (mx1.FreeBSD.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id AF3C737B400 for ; Thu, 29 Aug 2002 17:49:39 -0700 (PDT) Received: from freefall.freebsd.org (freefall.FreeBSD.org [216.136.204.21]) by mx1.FreeBSD.org (Postfix) with ESMTP id BFF1843E6E for ; Thu, 29 Aug 2002 17:49:38 -0700 (PDT) (envelope-from peter@freebsd.org) Received: from freefall.freebsd.org (perforce@localhost [127.0.0.1]) by freefall.freebsd.org (8.12.4/8.12.4) with ESMTP id g7U0ncJU007886 for ; Thu, 29 Aug 2002 17:49:38 -0700 (PDT) (envelope-from peter@freebsd.org) Received: (from perforce@localhost) by freefall.freebsd.org (8.12.4/8.12.4/Submit) id g7U0nbWG007883 for perforce@freebsd.org; Thu, 29 Aug 2002 17:49:37 -0700 (PDT) Date: Thu, 29 Aug 2002 17:49:37 -0700 (PDT) Message-Id: <200208300049.g7U0nbWG007883@freefall.freebsd.org> X-Authentication-Warning: freefall.freebsd.org: perforce set sender to peter@freebsd.org using -f From: Peter Wemm Subject: PERFORCE change 16779 for review To: Perforce Change Reviews Sender: owner-p4-projects@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG http://people.freebsd.org/~peter/p4db/chv.cgi?CH=16779 Change 16779 by peter@peter_daintree on 2002/08/29 17:49:03 IFC @16778 Affected files ... .. //depot/projects/ia64/bin/ls/print.c#7 integrate .. //depot/projects/ia64/bin/sh/eval.c#6 integrate .. //depot/projects/ia64/games/wargames/wargames.6#2 integrate .. //depot/projects/ia64/gnu/usr.bin/send-pr/doc/fields.texi#2 integrate .. //depot/projects/ia64/lib/libc_r/uthread/pthread_private.h#9 integrate .. //depot/projects/ia64/lib/libc_r/uthread/uthread_accept.c#2 integrate .. //depot/projects/ia64/lib/libc_r/uthread/uthread_close.c#2 integrate .. //depot/projects/ia64/lib/libc_r/uthread/uthread_connect.c#2 integrate .. //depot/projects/ia64/lib/libc_r/uthread/uthread_dup.c#2 integrate .. //depot/projects/ia64/lib/libc_r/uthread/uthread_dup2.c#4 integrate .. //depot/projects/ia64/lib/libc_r/uthread/uthread_execve.c#2 integrate .. //depot/projects/ia64/lib/libc_r/uthread/uthread_exit.c#5 integrate .. //depot/projects/ia64/lib/libc_r/uthread/uthread_fcntl.c#2 integrate .. //depot/projects/ia64/lib/libc_r/uthread/uthread_fd.c#2 integrate .. //depot/projects/ia64/lib/libc_r/uthread/uthread_ioctl.c#2 integrate .. //depot/projects/ia64/lib/libc_r/uthread/uthread_read.c#2 integrate .. //depot/projects/ia64/lib/libc_r/uthread/uthread_readv.c#3 integrate .. //depot/projects/ia64/lib/libc_r/uthread/uthread_recvfrom.c#2 integrate .. //depot/projects/ia64/lib/libc_r/uthread/uthread_recvmsg.c#2 integrate .. //depot/projects/ia64/lib/libc_r/uthread/uthread_select.c#4 integrate .. //depot/projects/ia64/lib/libc_r/uthread/uthread_sendfile.c#4 integrate .. //depot/projects/ia64/lib/libc_r/uthread/uthread_sendmsg.c#2 integrate .. //depot/projects/ia64/lib/libc_r/uthread/uthread_sendto.c#2 integrate .. //depot/projects/ia64/lib/libc_r/uthread/uthread_sig.c#5 integrate .. //depot/projects/ia64/lib/libc_r/uthread/uthread_write.c#2 integrate .. //depot/projects/ia64/lib/libc_r/uthread/uthread_writev.c#3 integrate .. //depot/projects/ia64/libexec/ftpd/ftpcmd.y#9 integrate .. //depot/projects/ia64/libexec/ftpd/ftpd.c#12 integrate .. //depot/projects/ia64/sbin/growfs/growfs.8#7 integrate .. //depot/projects/ia64/share/man/man7/tuning.7#13 integrate .. //depot/projects/ia64/sys/alpha/alpha/machdep.c#15 integrate .. //depot/projects/ia64/sys/alpha/include/reg.h#3 integrate .. //depot/projects/ia64/sys/boot/common/load_aout.c#2 delete .. //depot/projects/ia64/sys/boot/i386/libi386/aout_freebsd.c#2 delete .. //depot/projects/ia64/sys/boot/i386/loader/Makefile#7 integrate .. //depot/projects/ia64/sys/boot/i386/pxeldr/Makefile#2 integrate .. //depot/projects/ia64/sys/contrib/dev/acpica/acfreebsd.h#6 integrate .. //depot/projects/ia64/sys/dev/sound/pci/maestro3.c#6 integrate .. //depot/projects/ia64/sys/i386/i386/machdep.c#22 integrate .. //depot/projects/ia64/sys/i386/include/reg.h#3 integrate .. //depot/projects/ia64/sys/ia64/ia64/machdep.c#44 integrate .. //depot/projects/ia64/sys/ia64/ia64/mca.c#5 integrate .. //depot/projects/ia64/sys/ia64/ia64/sal.c#8 integrate .. //depot/projects/ia64/sys/ia64/ia64/trap.c#33 integrate .. //depot/projects/ia64/sys/ia64/include/reg.h#7 integrate .. //depot/projects/ia64/sys/kern/kern_exec.c#26 integrate .. //depot/projects/ia64/sys/kern/kern_switch.c#10 integrate .. //depot/projects/ia64/sys/kern/kern_synch.c#15 integrate .. //depot/projects/ia64/sys/kern/kern_thread.c#8 integrate .. //depot/projects/ia64/sys/kern/link_aout.c#6 delete .. //depot/projects/ia64/sys/kern/subr_rman.c#5 integrate .. //depot/projects/ia64/sys/netinet/ip_h323_pxy.c#2 delete .. //depot/projects/ia64/sys/netinet/ip_ipsec_pxy.c#2 delete .. //depot/projects/ia64/sys/netinet/ip_netbios_pxy.c#2 delete .. //depot/projects/ia64/sys/pc98/i386/machdep.c#20 integrate .. //depot/projects/ia64/sys/powerpc/include/reg.h#3 integrate .. //depot/projects/ia64/sys/powerpc/powerpc/machdep.c#14 integrate .. //depot/projects/ia64/sys/sparc64/include/reg.h#6 integrate .. //depot/projects/ia64/sys/sparc64/sparc64/machdep.c#19 integrate .. //depot/projects/ia64/sys/sys/imgact.h#7 integrate .. //depot/projects/ia64/sys/sys/param.h#16 integrate .. //depot/projects/ia64/sys/sys/proc.h#28 integrate .. //depot/projects/ia64/usr.sbin/gifconfig/gifconfig.c#2 integrate .. //depot/projects/ia64/usr.sbin/ppp/command.c#12 integrate .. //depot/projects/ia64/usr.sbin/ppp/iface.c#8 integrate .. //depot/projects/ia64/usr.sbin/ppp/ipv6cp.c#4 integrate .. //depot/projects/ia64/usr.sbin/ppp/ipv6cp.h#2 integrate .. //depot/projects/ia64/usr.sbin/ppp/ncpaddr.c#5 integrate .. //depot/projects/ia64/usr.sbin/ppp/ppp.8.m4#14 integrate Differences ... ==== //depot/projects/ia64/bin/ls/print.c#7 (text+ko) ==== @@ -40,7 +40,7 @@ #endif /* not lint */ #endif #include -__FBSDID("$FreeBSD: src/bin/ls/print.c,v 1.56 2002/06/30 05:13:54 obrien Exp $"); +__FBSDID("$FreeBSD: src/bin/ls/print.c,v 1.57 2002/08/29 14:29:09 keramida Exp $"); #include #include @@ -306,8 +306,7 @@ if (dp->list->fts_level != FTS_ROOTLEVEL && (f_longform || f_size)) (void)printf("total %lu\n", howmany(dp->btotal, blocksize)); - if (f_sortacross) - base = 0; + base = 0; for (row = 0; row < numrows; ++row) { endcol = colwidth; if (!f_sortacross) ==== //depot/projects/ia64/bin/sh/eval.c#6 (text+ko) ==== @@ -40,10 +40,11 @@ #endif #endif /* not lint */ #include -__FBSDID("$FreeBSD: src/bin/sh/eval.c,v 1.35 2002/07/25 10:47:38 tjr Exp $"); +__FBSDID("$FreeBSD: src/bin/sh/eval.c,v 1.36 2002/08/29 14:26:49 keramida Exp $"); #include #include +#include #include #include /* For WIFSIGNALED(status) */ #include ==== //depot/projects/ia64/games/wargames/wargames.6#2 (text+ko) ==== @@ -26,7 +26,7 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" -.\" $FreeBSD: src/games/wargames/wargames.6,v 1.4 2000/12/19 15:46:46 ru Exp $ +.\" $FreeBSD: src/games/wargames/wargames.6,v 1.5 2002/08/29 04:07:20 jmallett Exp $ .\" .Dd February 22, 1998 .Dt WARGAMES 6 @@ -46,6 +46,6 @@ resulting is much smaller.... .Sh SEE ALSO Wargames, -the movie (an MGM production, PGP 13, directed by John Badham, 1983). +the movie (an MGM production, PG-13, directed by John Badham, 1983). .Sh AUTHORS This manual page was written by Joey Hess . ==== //depot/projects/ia64/gnu/usr.bin/send-pr/doc/fields.texi#2 (text+ko) ==== @@ -1,4 +1,4 @@ -@c $FreeBSD: src/gnu/usr.bin/send-pr/doc/fields.texi,v 1.2 2000/10/29 22:05:52 steve Exp $ +@c $FreeBSD: src/gnu/usr.bin/send-pr/doc/fields.texi,v 1.3 2002/08/29 22:59:22 keramida Exp $ @node Fields @section Problem Report format @@ -250,7 +250,7 @@ for confidentiality, then if the value of this field is @samp{yes} the support organization treats the PR as confidential; any code samples provided are not made publicly available (e.g., in regression test -suites). The default value is @samp{yes}. +suites). The default value is @samp{no}. @cindex @code{Synopsis} field @cindex @code{>Synopsis:} ==== //depot/projects/ia64/lib/libc_r/uthread/pthread_private.h#9 (text+ko) ==== @@ -31,7 +31,7 @@ * * Private thread definitions for the uthread kernel. * - * $FreeBSD: src/lib/libc_r/uthread/pthread_private.h,v 1.72 2002/06/14 04:02:25 rwatson Exp $ + * $FreeBSD: src/lib/libc_r/uthread/pthread_private.h,v 1.73 2002/08/29 23:06:06 deischen Exp $ */ #ifndef _PTHREAD_PRIVATE_H @@ -1151,8 +1151,6 @@ void *_thread_stack_alloc(size_t, size_t); void _thread_stack_free(void *, size_t, size_t); int _thread_create(pthread_t *,const pthread_attr_t *,void *(*start_routine)(void *),void *,pthread_t); -int _thread_fd_lock(int, int, struct timespec *); -int _thread_fd_lock_debug(int, int, struct timespec *,char *fname,int lineno); int _mutex_cv_lock(pthread_mutex_t *); int _mutex_cv_unlock(pthread_mutex_t *); void _mutex_lock_backout(pthread_t); @@ -1188,6 +1186,11 @@ #endif void _thread_exit(char *, int, char *); void _thread_exit_cleanup(void); +int _thread_fd_getflags(int); +int _thread_fd_lock(int, int, struct timespec *); +int _thread_fd_lock_debug(int, int, struct timespec *,char *fname,int lineno); +void _thread_fd_setflags(int, int); +int _thread_fd_table_init(int fd); void _thread_fd_unlock(int, int); void _thread_fd_unlock_debug(int, int, char *, int); void _thread_fd_unlock_owned(pthread_t); @@ -1214,7 +1217,6 @@ struct pthread_signal_frame *psf); void _thread_start(void); void _thread_seterrno(pthread_t, int); -int _thread_fd_table_init(int fd); pthread_addr_t _thread_gc(pthread_addr_t); void _thread_enter_cancellation_point(void); void _thread_leave_cancellation_point(void); ==== //depot/projects/ia64/lib/libc_r/uthread/uthread_accept.c#2 (text+ko) ==== @@ -29,7 +29,7 @@ * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF * SUCH DAMAGE. * - * $FreeBSD: src/lib/libc_r/uthread/uthread_accept.c,v 1.15 2001/04/10 04:19:19 deischen Exp $ + * $FreeBSD: src/lib/libc_r/uthread/uthread_accept.c,v 1.16 2002/08/29 23:06:06 deischen Exp $ */ #include #include @@ -52,7 +52,8 @@ /* Enter a loop to wait for a connection request: */ while ((ret = __sys_accept(fd, name, namelen)) < 0) { /* Check if the socket is to block: */ - if ((_thread_fd_table[fd]->flags & O_NONBLOCK) == 0 && (errno == EWOULDBLOCK || errno == EAGAIN)) { + if ((_thread_fd_getflags(fd) & O_NONBLOCK) == 0 + && (errno == EWOULDBLOCK || errno == EAGAIN)) { /* Save the socket file descriptor: */ curthread->data.fd.fd = fd; curthread->data.fd.fname = __FILE__; @@ -99,9 +100,9 @@ * set the new socket flags to non-blocking, as that * will be the inherited state of the new socket. */ - if((ret > 0) && (_thread_fd_table[fd]->flags & O_NONBLOCK) == 0) - _thread_fd_table[ret]->flags &= ~O_NONBLOCK; - + if((ret > 0) && (_thread_fd_getflags(fd) & O_NONBLOCK) == 0) + _thread_fd_setflags(ret, + _thread_fd_getflags(ret) & ~O_NONBLOCK); /* Unlock the file descriptor: */ _FD_UNLOCK(fd, FD_RDWR); } ==== //depot/projects/ia64/lib/libc_r/uthread/uthread_close.c#2 (text+ko) ==== @@ -29,7 +29,7 @@ * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF * SUCH DAMAGE. * - * $FreeBSD: src/lib/libc_r/uthread/uthread_close.c,v 1.12 2001/04/10 04:19:19 deischen Exp $ + * $FreeBSD: src/lib/libc_r/uthread/uthread_close.c,v 1.13 2002/08/29 23:06:06 deischen Exp $ */ #include #include @@ -82,7 +82,8 @@ * using, which would then cause any reads to block * indefinitely. */ - if ((S_ISREG(sb.st_mode) || S_ISCHR(sb.st_mode)) && (_thread_fd_table[fd]->flags & O_NONBLOCK) == 0) { + if ((S_ISREG(sb.st_mode) || S_ISCHR(sb.st_mode)) + && (_thread_fd_getflags(fd) & O_NONBLOCK) == 0) { /* Get the current flags: */ flags = __sys_fcntl(fd, F_GETFL, NULL); /* Clear the nonblocking file descriptor flag: */ ==== //depot/projects/ia64/lib/libc_r/uthread/uthread_connect.c#2 (text+ko) ==== @@ -29,7 +29,7 @@ * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF * SUCH DAMAGE. * - * $FreeBSD: src/lib/libc_r/uthread/uthread_connect.c,v 1.12 2001/04/10 04:19:20 deischen Exp $ + * $FreeBSD: src/lib/libc_r/uthread/uthread_connect.c,v 1.13 2002/08/29 23:06:07 deischen Exp $ */ #include #include @@ -49,9 +49,9 @@ if ((ret = _FD_LOCK(fd, FD_RDWR, NULL)) == 0) { if ((ret = __sys_connect(fd, name, namelen)) < 0) { - if (!(_thread_fd_table[fd]->flags & O_NONBLOCK) && - ((errno == EWOULDBLOCK) || (errno == EINPROGRESS) || - (errno == EALREADY) || (errno == EAGAIN))) { + if ((_thread_fd_getflags(fd) & O_NONBLOCK) == 0 + && ((errno == EWOULDBLOCK) || (errno == EINPROGRESS) + || (errno == EALREADY) || (errno == EAGAIN))) { curthread->data.fd.fd = fd; /* Set the timeout: */ ==== //depot/projects/ia64/lib/libc_r/uthread/uthread_dup.c#2 (text+ko) ==== @@ -29,7 +29,7 @@ * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF * SUCH DAMAGE. * - * $FreeBSD: src/lib/libc_r/uthread/uthread_dup.c,v 1.10 2001/04/10 04:19:20 deischen Exp $ + * $FreeBSD: src/lib/libc_r/uthread/uthread_dup.c,v 1.11 2002/08/29 23:06:07 deischen Exp $ */ #include #include @@ -59,7 +59,7 @@ * Save the file open flags so that they can be * checked later: */ - _thread_fd_table[ret]->flags = _thread_fd_table[fd]->flags; + _thread_fd_setflags(ret, _thread_fd_getflags(fd)); } /* Unlock the file descriptor: */ ==== //depot/projects/ia64/lib/libc_r/uthread/uthread_dup2.c#4 (text+ko) ==== @@ -29,7 +29,7 @@ * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF * SUCH DAMAGE. * - * $FreeBSD: src/lib/libc_r/uthread/uthread_dup2.c,v 1.13 2002/06/23 20:41:30 robert Exp $ + * $FreeBSD: src/lib/libc_r/uthread/uthread_dup2.c,v 1.14 2002/08/29 23:06:07 deischen Exp $ */ #include #include @@ -81,8 +81,8 @@ * Save the file open flags so that * they can be checked later: */ - _thread_fd_table[ret]->flags = - _thread_fd_table[fd]->flags; + _thread_fd_setflags(ret, + _thread_fd_getflags(fd)); } } ==== //depot/projects/ia64/lib/libc_r/uthread/uthread_execve.c#2 (text+ko) ==== @@ -29,7 +29,7 @@ * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF * SUCH DAMAGE. * - * $FreeBSD: src/lib/libc_r/uthread/uthread_execve.c,v 1.14 2001/04/10 04:19:20 deischen Exp $ + * $FreeBSD: src/lib/libc_r/uthread/uthread_execve.c,v 1.15 2002/08/29 23:06:07 deischen Exp $ */ #include #include @@ -68,7 +68,7 @@ for (i = 0; i < _thread_dtablesize; i++) { /* Check if this file descriptor is in use: */ if (_thread_fd_table[i] != NULL && - !(_thread_fd_table[i]->flags & O_NONBLOCK)) { + (_thread_fd_getflags(i) & O_NONBLOCK) == 0) { /* Get the current flags: */ flags = __sys_fcntl(i, F_GETFL, NULL); /* Clear the nonblocking file descriptor flag: */ ==== //depot/projects/ia64/lib/libc_r/uthread/uthread_exit.c#5 (text+ko) ==== @@ -29,7 +29,7 @@ * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF * SUCH DAMAGE. * - * $FreeBSD: src/lib/libc_r/uthread/uthread_exit.c,v 1.26 2002/05/24 04:32:28 deischen Exp $ + * $FreeBSD: src/lib/libc_r/uthread/uthread_exit.c,v 1.27 2002/08/29 23:06:07 deischen Exp $ */ #include #include @@ -69,7 +69,7 @@ for (i = 0; i < _thread_dtablesize; i++) { /* Check if this file descriptor is in use: */ if (_thread_fd_table[i] != NULL && - !(_thread_fd_table[i]->flags & O_NONBLOCK)) { + (_thread_fd_getflags(i) & O_NONBLOCK) == 0) { /* Get the current flags: */ flags = __sys_fcntl(i, F_GETFL, NULL); /* Clear the nonblocking file descriptor flag: */ ==== //depot/projects/ia64/lib/libc_r/uthread/uthread_fcntl.c#2 (text+ko) ==== @@ -29,7 +29,7 @@ * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF * SUCH DAMAGE. * - * $FreeBSD: src/lib/libc_r/uthread/uthread_fcntl.c,v 1.14 2001/04/10 04:19:20 deischen Exp $ + * $FreeBSD: src/lib/libc_r/uthread/uthread_fcntl.c,v 1.15 2002/08/29 23:06:07 deischen Exp $ */ #include #include @@ -76,9 +76,10 @@ } else { /* * Save the file open flags so that they can - * be checked later: + * be checked later: */ - _thread_fd_table[ret]->flags = _thread_fd_table[fd]->flags; + _thread_fd_setflags(ret, + _thread_fd_getflags(fd)); } break; case F_SETFD: @@ -89,7 +90,7 @@ ret = __sys_fcntl(fd, cmd, 0); break; case F_GETFL: - ret = _thread_fd_table[fd]->flags; + ret = _thread_fd_getflags(fd); break; case F_SETFL: /* @@ -119,10 +120,10 @@ */ } else if (nonblock) /* A non-blocking descriptor: */ - _thread_fd_table[fd]->flags = flags | O_NONBLOCK; + _thread_fd_setflags(fd, flags | O_NONBLOCK); else /* Save the flags: */ - _thread_fd_table[fd]->flags = flags & ~O_NONBLOCK; + _thread_fd_setflags(fd, flags & ~O_NONBLOCK); break; default: /* Might want to make va_arg use a union */ ==== //depot/projects/ia64/lib/libc_r/uthread/uthread_fd.c#2 (text+ko) ==== @@ -29,7 +29,7 @@ * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF * SUCH DAMAGE. * - * $FreeBSD: src/lib/libc_r/uthread/uthread_fd.c,v 1.21 2001/10/21 18:23:50 deischen Exp $ + * $FreeBSD: src/lib/libc_r/uthread/uthread_fd.c,v 1.22 2002/08/29 23:06:07 deischen Exp $ * */ #include @@ -182,6 +182,22 @@ return (ret); } +int +_thread_fd_getflags(int fd) +{ + if (_thread_fd_table[fd] != NULL) + return (_thread_fd_table[fd]->flags); + else + return (0); +} + +void +_thread_fd_setflags(int fd, int flags) +{ + if (_thread_fd_table[fd] != NULL) + _thread_fd_table[fd]->flags = flags; +} + #ifdef _FDLOCKS_ENABLED void _thread_fd_unlock(int fd, int lock_type) ==== //depot/projects/ia64/lib/libc_r/uthread/uthread_ioctl.c#2 (text+ko) ==== @@ -29,7 +29,7 @@ * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF * SUCH DAMAGE. * - * $FreeBSD: src/lib/libc_r/uthread/uthread_ioctl.c,v 1.11 2001/04/10 04:19:20 deischen Exp $ + * $FreeBSD: src/lib/libc_r/uthread/uthread_ioctl.c,v 1.12 2002/08/29 23:06:07 deischen Exp $ */ #include #include @@ -43,6 +43,7 @@ _ioctl(int fd, unsigned long request,...) { int ret; + int flags; int *op; va_list ap; @@ -58,8 +59,12 @@ * twiddling the flag based on the request */ op = va_arg(ap, int *); - _thread_fd_table[fd]->flags &= ~O_NONBLOCK; - _thread_fd_table[fd]->flags |= ((*op) ? O_NONBLOCK : 0); + flags = _thread_fd_getflags(fd); + if (*op == 0) + flags &= ~O_NONBLOCK; + else + flags |= O_NONBLOCK; + _thread_fd_setflags(fd, flags); ret = 0; break; default: ==== //depot/projects/ia64/lib/libc_r/uthread/uthread_read.c#2 (text+ko) ==== @@ -29,7 +29,7 @@ * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF * SUCH DAMAGE. * - * $FreeBSD: src/lib/libc_r/uthread/uthread_read.c,v 1.13 2001/04/10 04:19:20 deischen Exp $ + * $FreeBSD: src/lib/libc_r/uthread/uthread_read.c,v 1.14 2002/08/29 23:06:07 deischen Exp $ * */ #include @@ -57,7 +57,7 @@ /* Lock the file descriptor for read: */ if ((ret = _FD_LOCK(fd, FD_READ, NULL)) == 0) { /* Get the read/write mode type: */ - type = _thread_fd_table[fd]->flags & O_ACCMODE; + type = _thread_fd_getflags(fd) & O_ACCMODE; /* Check if the file is not open for read: */ if (type != O_RDONLY && type != O_RDWR) { @@ -69,7 +69,7 @@ /* Perform a non-blocking read syscall: */ while ((ret = __sys_read(fd, buf, nbytes)) < 0) { - if ((_thread_fd_table[fd]->flags & O_NONBLOCK) == 0 && + if ((_thread_fd_getflags(fd) & O_NONBLOCK) == 0 && (errno == EWOULDBLOCK || errno == EAGAIN)) { curthread->data.fd.fd = fd; _thread_kern_set_timeout(NULL); ==== //depot/projects/ia64/lib/libc_r/uthread/uthread_readv.c#3 (text+ko) ==== @@ -29,7 +29,7 @@ * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF * SUCH DAMAGE. * - * $FreeBSD: src/lib/libc_r/uthread/uthread_readv.c,v 1.14 2002/05/02 19:58:43 archie Exp $ + * $FreeBSD: src/lib/libc_r/uthread/uthread_readv.c,v 1.15 2002/08/29 23:06:07 deischen Exp $ * */ #include @@ -52,7 +52,7 @@ /* Lock the file descriptor for read: */ if ((ret = _FD_LOCK(fd, FD_READ, NULL)) == 0) { /* Get the read/write mode type: */ - type = _thread_fd_table[fd]->flags & O_ACCMODE; + type = _thread_fd_getflags(fd) & O_ACCMODE; /* Check if the file is not open for read: */ if (type != O_RDONLY && type != O_RDWR) { @@ -64,7 +64,7 @@ /* Perform a non-blocking readv syscall: */ while ((ret = __sys_readv(fd, iov, iovcnt)) < 0) { - if ((_thread_fd_table[fd]->flags & O_NONBLOCK) == 0 && + if ((_thread_fd_getflags(fd) & O_NONBLOCK) == 0 && (errno == EWOULDBLOCK || errno == EAGAIN)) { curthread->data.fd.fd = fd; _thread_kern_set_timeout(NULL); ==== //depot/projects/ia64/lib/libc_r/uthread/uthread_recvfrom.c#2 (text+ko) ==== @@ -29,7 +29,7 @@ * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF * SUCH DAMAGE. * - * $FreeBSD: src/lib/libc_r/uthread/uthread_recvfrom.c,v 1.11 2001/04/10 04:19:20 deischen Exp $ + * $FreeBSD: src/lib/libc_r/uthread/uthread_recvfrom.c,v 1.12 2002/08/29 23:06:07 deischen Exp $ */ #include #include @@ -49,7 +49,8 @@ if ((ret = _FD_LOCK(fd, FD_READ, NULL)) == 0) { while ((ret = __sys_recvfrom(fd, buf, len, flags, from, from_len)) < 0) { - if (!(_thread_fd_table[fd]->flags & O_NONBLOCK) && ((errno == EWOULDBLOCK) || (errno == EAGAIN))) { + if (((_thread_fd_getflags(fd) & O_NONBLOCK) == 0) + && ((errno == EWOULDBLOCK) || (errno == EAGAIN))) { curthread->data.fd.fd = fd; /* Set the timeout: */ ==== //depot/projects/ia64/lib/libc_r/uthread/uthread_recvmsg.c#2 (text+ko) ==== @@ -29,7 +29,7 @@ * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF * SUCH DAMAGE. * - * $FreeBSD: src/lib/libc_r/uthread/uthread_recvmsg.c,v 1.9 2001/04/10 04:19:20 deischen Exp $ + * $FreeBSD: src/lib/libc_r/uthread/uthread_recvmsg.c,v 1.10 2002/08/29 23:06:07 deischen Exp $ */ #include #include @@ -48,7 +48,8 @@ if ((ret = _FD_LOCK(fd, FD_READ, NULL)) == 0) { while ((ret = __sys_recvmsg(fd, msg, flags)) < 0) { - if (!(_thread_fd_table[fd]->flags & O_NONBLOCK) && ((errno == EWOULDBLOCK) || (errno == EAGAIN))) { + if (((_thread_fd_getflags(fd) & O_NONBLOCK) == 0) + && ((errno == EWOULDBLOCK) || (errno == EAGAIN))) { curthread->data.fd.fd = fd; /* Set the timeout: */ ==== //depot/projects/ia64/lib/libc_r/uthread/uthread_select.c#4 (text+ko) ==== @@ -29,7 +29,7 @@ * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF * SUCH DAMAGE. * - * $FreeBSD: src/lib/libc_r/uthread/uthread_select.c,v 1.20 2002/05/02 19:58:43 archie Exp $ + * $FreeBSD: src/lib/libc_r/uthread/uthread_select.c,v 1.21 2002/08/29 21:39:19 archie Exp $ */ #include #include @@ -179,8 +179,9 @@ got_events = 0; if (readfds != NULL) { if (FD_ISSET(data.fds[i].fd, readfds)) { - if (data.fds[i].revents & (POLLIN | - POLLRDNORM)) + if ((data.fds[i].revents & (POLLIN + | POLLRDNORM | POLLERR + | POLLHUP | POLLNVAL)) != 0) got_events++; else FD_CLR(data.fds[i].fd, readfds); @@ -188,8 +189,9 @@ } if (writefds != NULL) { if (FD_ISSET(data.fds[i].fd, writefds)) { - if (data.fds[i].revents & (POLLOUT | - POLLWRNORM | POLLWRBAND)) + if ((data.fds[i].revents & (POLLOUT + | POLLWRNORM | POLLWRBAND | POLLERR + | POLLHUP | POLLNVAL)) != 0) got_events++; else FD_CLR(data.fds[i].fd, ==== //depot/projects/ia64/lib/libc_r/uthread/uthread_sendfile.c#4 (text+ko) ==== @@ -26,7 +26,7 @@ * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, * EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. * - * $FreeBSD: src/lib/libc_r/uthread/uthread_sendfile.c,v 1.9 2002/02/22 04:26:54 jb Exp $ + * $FreeBSD: src/lib/libc_r/uthread/uthread_sendfile.c,v 1.10 2002/08/29 23:06:07 deischen Exp $ */ #include @@ -83,14 +83,14 @@ } /* Check the descriptor access modes. */ - type = _thread_fd_table[fd]->flags & O_ACCMODE; + type = _thread_fd_getflags(fd) & O_ACCMODE; if (type != O_RDONLY && type != O_RDWR) { /* File is not open for read. */ ret = -1; errno = EBADF; goto ERROR_2; } - type = _thread_fd_table[s]->flags & O_ACCMODE; + type = _thread_fd_getflags(s) & O_ACCMODE; if (type != O_WRONLY && type != O_RDWR) { /* File is not open for write. */ ret = -1; @@ -99,7 +99,7 @@ } /* Check if file operations are to block */ - blocking = ((_thread_fd_table[s]->flags & O_NONBLOCK) == 0); + blocking = ((_thread_fd_getflags(s) & O_NONBLOCK) == 0); /* * Loop while no error occurs and until the expected number of bytes are ==== //depot/projects/ia64/lib/libc_r/uthread/uthread_sendmsg.c#2 (text+ko) ==== @@ -29,7 +29,7 @@ * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF * SUCH DAMAGE. * - * $FreeBSD: src/lib/libc_r/uthread/uthread_sendmsg.c,v 1.9 2001/04/10 04:19:20 deischen Exp $ + * $FreeBSD: src/lib/libc_r/uthread/uthread_sendmsg.c,v 1.10 2002/08/29 23:06:07 deischen Exp $ */ #include #include @@ -48,7 +48,8 @@ if ((ret = _FD_LOCK(fd, FD_WRITE, NULL)) == 0) { while ((ret = __sys_sendmsg(fd, msg, flags)) < 0) { - if (!(_thread_fd_table[fd]->flags & O_NONBLOCK) && ((errno == EWOULDBLOCK) || (errno == EAGAIN))) { + if (!(_thread_fd_getflags(fd) & O_NONBLOCK) + && ((errno == EWOULDBLOCK) || (errno == EAGAIN))) { curthread->data.fd.fd = fd; /* Set the timeout: */ ==== //depot/projects/ia64/lib/libc_r/uthread/uthread_sendto.c#2 (text+ko) ==== @@ -29,7 +29,7 @@ * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF * SUCH DAMAGE. * - * $FreeBSD: src/lib/libc_r/uthread/uthread_sendto.c,v 1.11 2001/04/10 04:19:20 deischen Exp $ + * $FreeBSD: src/lib/libc_r/uthread/uthread_sendto.c,v 1.12 2002/08/29 23:06:07 deischen Exp $ */ #include #include @@ -49,7 +49,8 @@ if ((ret = _FD_LOCK(fd, FD_WRITE, NULL)) == 0) { while ((ret = __sys_sendto(fd, msg, len, flags, to, to_len)) < 0) { - if (!(_thread_fd_table[fd]->flags & O_NONBLOCK) && ((errno == EWOULDBLOCK) || (errno == EAGAIN))) { + if (((_thread_fd_getflags(fd) & O_NONBLOCK) == 0) + && ((errno == EWOULDBLOCK) || (errno == EAGAIN))) { curthread->data.fd.fd = fd; /* Set the timeout: */ ==== //depot/projects/ia64/lib/libc_r/uthread/uthread_sig.c#5 (text+ko) ==== @@ -29,7 +29,7 @@ * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF * SUCH DAMAGE. * - * $FreeBSD: src/lib/libc_r/uthread/uthread_sig.c,v 1.41 2002/05/24 04:32:28 deischen Exp $ + * $FreeBSD: src/lib/libc_r/uthread/uthread_sig.c,v 1.42 2002/08/29 23:06:07 deischen Exp $ */ #include #include @@ -536,7 +536,7 @@ * Set the file descriptor to non-blocking: */ __sys_fcntl(i, F_SETFL, - _thread_fd_table[i]->flags | O_NONBLOCK); + _thread_fd_getflags(i) | O_NONBLOCK); } } /* ==== //depot/projects/ia64/lib/libc_r/uthread/uthread_write.c#2 (text+ko) ==== @@ -29,7 +29,7 @@ * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF * SUCH DAMAGE. * - * $FreeBSD: src/lib/libc_r/uthread/uthread_write.c,v 1.19 2001/04/10 04:19:20 deischen Exp $ + * $FreeBSD: src/lib/libc_r/uthread/uthread_write.c,v 1.20 2002/08/29 23:06:07 deischen Exp $ * */ #include @@ -59,7 +59,7 @@ /* Lock the file descriptor for write: */ if ((ret = _FD_LOCK(fd, FD_WRITE, NULL)) == 0) { /* Get the read/write mode type: */ - type = _thread_fd_table[fd]->flags & O_ACCMODE; + type = _thread_fd_getflags(fd) & O_ACCMODE; /* Check if the file is not open for write: */ if (type != O_WRONLY && type != O_RDWR) { @@ -70,7 +70,7 @@ } /* Check if file operations are to block */ - blocking = ((_thread_fd_table[fd]->flags & O_NONBLOCK) == 0); + blocking = ((_thread_fd_getflags(fd) & O_NONBLOCK) == 0); /* * Loop while no error occurs and until the expected number ==== //depot/projects/ia64/lib/libc_r/uthread/uthread_writev.c#3 (text+ko) ==== @@ -29,7 +29,7 @@ * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF * SUCH DAMAGE. * - * $FreeBSD: src/lib/libc_r/uthread/uthread_writev.c,v 1.19 2002/05/02 19:58:43 archie Exp $ + * $FreeBSD: src/lib/libc_r/uthread/uthread_writev.c,v 1.20 2002/08/29 23:06:07 deischen Exp $ * */ #include @@ -75,7 +75,7 @@ /* Lock the file descriptor for write: */ if ((ret = _FD_LOCK(fd, FD_WRITE, NULL)) == 0) { /* Get the read/write mode type: */ - type = _thread_fd_table[fd]->flags & O_ACCMODE; + type = _thread_fd_getflags(fd) & O_ACCMODE; /* Check if the file is not open for write: */ if (type != O_WRONLY && type != O_RDWR) { @@ -86,7 +86,7 @@ } /* Check if file operations are to block */ - blocking = ((_thread_fd_table[fd]->flags & O_NONBLOCK) == 0); + blocking = ((_thread_fd_getflags(fd) & O_NONBLOCK) == 0); /* * Loop while no error occurs and until the expected number ==== //depot/projects/ia64/libexec/ftpd/ftpcmd.y#9 (text+ko) ==== @@ -45,7 +45,7 @@ static char sccsid[] = "@(#)ftpcmd.y 8.3 (Berkeley) 4/6/94"; #endif static const char rcsid[] = - "$FreeBSD: src/libexec/ftpd/ftpcmd.y,v 1.41 2002/08/13 13:56:42 yar Exp $"; + "$FreeBSD: src/libexec/ftpd/ftpcmd.y,v 1.42 2002/08/29 09:23:08 yar Exp $"; #endif /* not lint */ #include @@ -136,7 +136,7 @@ UMASK IDLE CHMOD MDFIVE - LEXERR + LEXERR NOTIMPL %token STRING %token NUMBER @@ -145,7 +145,7 @@ %type check_login_ro check_login_epsv %type struct_code mode_code type_code form_code %type pathstring pathname password username -%type ALL +%type ALL NOTIMPL %start cmd_list @@ -752,11 +752,15 @@ reply(221, "Goodbye."); dologout(0); } + | NOTIMPL + { + nack($1); + } | error { yyclearin; /* discard lookahead data */ yyerrok; /* clear error condition */ - state = 0; /* reset lexer state */ + state = CMD; /* reset lexer state */ } ; rcmd @@ -1289,12 +1293,10 @@ p = lookup(cmdtab, cbuf); cbuf[cpos] = c; if (p != 0) { - if (p->implemented == 0) { - nack(p->name); - return (LEXERR); - } + yylval.s = p->name; + if (!p->implemented) + return (NOTIMPL); /* state remains CMD */ state = p->state; - yylval.s = p->name; return (p->token); } break; @@ -1313,13 +1315,12 @@ p = lookup(sitetab, cp); cbuf[cpos] = c; if (guest == 0 && p != 0) { - if (p->implemented == 0) { + yylval.s = p->name; + if (!p->implemented) { state = CMD; - nack(p->name); - return (LEXERR); + return (NOTIMPL); } state = p->state; - yylval.s = p->name; return (p->token); } state = CMD; ==== //depot/projects/ia64/libexec/ftpd/ftpd.c#12 (text+ko) ==== @@ -44,7 +44,7 @@ static char sccsid[] = "@(#)ftpd.c 8.4 (Berkeley) 4/16/94"; #endif static const char rcsid[] = - "$FreeBSD: src/libexec/ftpd/ftpd.c,v 1.127 2002/08/27 09:05:03 yar Exp $"; + "$FreeBSD: src/libexec/ftpd/ftpd.c,v 1.128 2002/08/29 09:53:51 yar Exp $"; #endif /* not lint */ /* @@ -1697,7 +1697,7 @@ data = -1; pdata = -1; done: - LOGBYTES(*mode == 'w' ? "put" : "append", name, byte_count); + LOGBYTES(*mode == 'a' ? "append" : "put", name, byte_count); (*closefunc)(fout); return; err: ==== //depot/projects/ia64/sbin/growfs/growfs.8#7 (text+ko) ==== @@ -35,7 +35,7 @@ .\" SUCH DAMAGE. .\" .\" $TSHeader: src/sbin/growfs/growfs.8,v 1.3 2000/12/12 19:31:00 tomsoft Exp $ -.\" $FreeBSD: src/sbin/growfs/growfs.8,v 1.15 2002/08/21 18:10:38 trhodes Exp $ +.\" $FreeBSD: src/sbin/growfs/growfs.8,v 1.16 2002/08/29 08:12:09 keramida Exp $ .\" .Dd September 8, 2000 .Dt GROWFS 8 @@ -58,6 +58,11 @@ .Nm the disk must be labeled to a bigger size using .Xr disklabel 8 . +If you wish to grow a filesystem beyound the boundary of +the slice it resides in, you must re-size the slice using +.Xr fdisk 8 +before running +.Nm . If you are using volumes you must enlarge them by using .Xr vinum 8 . The @@ -173,6 +178,7 @@ .Sh SEE ALSO .Xr disklabel 8 , .Xr dumpfs 8 , +.Xr fdisk 8 , .Xr ffsinfo 8 , .Xr fsck 8 , .Xr newfs 8 , ==== //depot/projects/ia64/share/man/man7/tuning.7#13 (text+ko) ==== @@ -2,7 +2,7 @@ .\" the BSD Copyright as specified in the file "/usr/src/COPYRIGHT" in .\" the source tree. .\" -.\" $FreeBSD: src/share/man/man7/tuning.7,v 1.52 2002/08/25 18:54:04 dillon Exp $ +.\" $FreeBSD: src/share/man/man7/tuning.7,v 1.53 2002/08/29 20:34:06 dillon Exp $ .\" .Dd June 25, 2002 .Dt TUNING 7 @@ -222,7 +222,7 @@ .Dq Li "newfs -f 1024 -b 8192 ..." . .Pp If a large partition is intended to be used to hold fewer, larger files, such -as a database files, you can increase the +as database files, you can increase the .Em bytes/i-node ratio which reduces the number of i-nodes (maximum number of files and directories that can be created) for that partition. @@ -273,7 +273,7 @@ determining whether to use it on a filesystem. First, softupdates guarantees filesystem consistency in the case of a crash but could very easily be several seconds (even a minute!) -behind updating the physical disk. +behind on pending write to the physical disk. If you crash you may lose more work than otherwise. Secondly, softupdates delays the freeing of filesystem @@ -291,7 +291,7 @@ options exist that can help you tune the system. The most obvious and most dangerous one is .Cm async . -Do not ever use it, it is far too dangerous. +Do not ever use it; it is far too dangerous. A less dangerous and more useful .Xr mount 8 @@ -455,7 +455,7 @@ .Va net.inet.tcp.recvspace sysctls are of particular interest if you are running network intensive applications. -This controls the amount of send and receive buffer space +They control the amount of send and receive buffer space allowed for any given TCP connection. The default sending buffer is 32K; the default receiving buffer is 64K. @@ -499,7 +499,7 @@ .Va net.inet.tcp.rfc1323 sysctl. These extensions should be enabled and the TCP buffer size should be set -to a value larger than 65536 in order to obtain good performance out of +to a value larger than 65536 in order to obtain good performance from certain types of network links; specifically, gigabit WAN links and high-latency satellite links. RFC1323 support is enabled by default. @@ -524,6 +524,29 @@ TCP session disconnections. .Pp The +.Va net.inet.tcp.delayed_ack +TCP feature is largly misunderstood. Historically speaking this feature +was designed to allow the acknowledgement to transmitted data to be returned +along with the response. For example, when you type over a remote shell +the acknowledgement to the character you send can be returned along with the +data representing the echo of the character. With delayed acks turned off +the acknowledgement may be sent in its own packet before the remote service +has a chance to echo the data it just received. This same concept also +applies to any interactive protocol (e.g. SMTP, WWW, POP3) and can cut the +number of tiny packets flowing across the network in half. The FreeBSD +delayed-ack implementation also follows the TCP protocol rule that +at least every other packet be acknowledged even if the standard 100ms +timeout has not yet passed. Normally the worst a delayed ack can do is +slightly delay the teardown of a connection, or slightly delay the ramp-up +of a slow-start TCP connection. While we aren't sure we believe that +the several FAQs related to packages such as SAMBA and SQUID which advise +turning off delayed acks may be refering to the slow-start issue. In FreeBSD +it would be more beneficial to increase the slow-start flightsize via +the +.Va net.inet.tcp.slowstart_flightsize +sysctl rather then disable delayed acks. +.Pp +The .Va net.inet.tcp.inflight_enable >>> TRUNCATED FOR MAIL (1000 lines) <<< To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe p4-projects" in the body of the message