From owner-svn-src-stable@FreeBSD.ORG Sun Sep 16 00:32:26 2012 Return-Path: Delivered-To: svn-src-stable@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 39BED106566C; Sun, 16 Sep 2012 00:32:26 +0000 (UTC) (envelope-from pfg@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 2372A8FC15; Sun, 16 Sep 2012 00:32:26 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q8G0WPux067063; Sun, 16 Sep 2012 00:32:25 GMT (envelope-from pfg@svn.freebsd.org) Received: (from pfg@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q8G0WPLb067059; Sun, 16 Sep 2012 00:32:25 GMT (envelope-from pfg@svn.freebsd.org) Message-Id: <201209160032.q8G0WPLb067059@svn.freebsd.org> From: "Pedro F. Giffuni" Date: Sun, 16 Sep 2012 00:32:25 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r240542 - in stable/9: include/rpc sys/rpc X-BeenThere: svn-src-stable@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for all the -stable branches of the src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 16 Sep 2012 00:32:26 -0000 Author: pfg Date: Sun Sep 16 00:32:25 2012 New Revision: 240542 URL: http://svn.freebsd.org/changeset/base/240542 Log: MFC r240060, r240062: Rename __rpc_xdr with XDR. This fixes at least one C++ application and matches what upstream (Solaris) has done on their xdr.h header. PR: 137443 Modified: stable/9/include/rpc/xdr.h stable/9/sys/rpc/rpc_com.h stable/9/sys/rpc/xdr.h Modified: stable/9/include/rpc/xdr.h ============================================================================== --- stable/9/include/rpc/xdr.h Sat Sep 15 21:56:30 2012 (r240541) +++ stable/9/include/rpc/xdr.h Sun Sep 16 00:32:25 2012 (r240542) @@ -97,26 +97,26 @@ enum xdr_op { * an operations vector for the particular implementation (e.g. see xdr_mem.c), * and two private fields for the use of the particular implementation. */ -typedef struct __rpc_xdr { +typedef struct XDR { enum xdr_op x_op; /* operation; fast additional param */ const struct xdr_ops { /* get a long from underlying stream */ - bool_t (*x_getlong)(struct __rpc_xdr *, long *); + bool_t (*x_getlong)(struct XDR *, long *); /* put a long to " */ - bool_t (*x_putlong)(struct __rpc_xdr *, const long *); + bool_t (*x_putlong)(struct XDR *, const long *); /* get some bytes from " */ - bool_t (*x_getbytes)(struct __rpc_xdr *, char *, u_int); + bool_t (*x_getbytes)(struct XDR *, char *, u_int); /* put some bytes to " */ - bool_t (*x_putbytes)(struct __rpc_xdr *, const char *, u_int); + bool_t (*x_putbytes)(struct XDR *, const char *, u_int); /* returns bytes off from beginning */ - u_int (*x_getpostn)(struct __rpc_xdr *); + u_int (*x_getpostn)(struct XDR *); /* lets you reposition the stream */ - bool_t (*x_setpostn)(struct __rpc_xdr *, u_int); + bool_t (*x_setpostn)(struct XDR *, u_int); /* buf quick ptr to buffered data */ - int32_t *(*x_inline)(struct __rpc_xdr *, u_int); + int32_t *(*x_inline)(struct XDR *, u_int); /* free privates of this xdr_stream */ - void (*x_destroy)(struct __rpc_xdr *); - bool_t (*x_control)(struct __rpc_xdr *, int, void *); + void (*x_destroy)(struct XDR *); + bool_t (*x_control)(struct XDR *, int, void *); } *x_ops; char * x_public; /* users' data */ void * x_private; /* pointer to private data */ Modified: stable/9/sys/rpc/rpc_com.h ============================================================================== --- stable/9/sys/rpc/rpc_com.h Sat Sep 15 21:56:30 2012 (r240541) +++ stable/9/sys/rpc/rpc_com.h Sun Sep 16 00:32:25 2012 (r240542) @@ -114,8 +114,8 @@ extern int __rpc_sockisbound(struct sock extern int bindresvport(struct socket *so, struct sockaddr *sa); struct xucred; -struct __rpc_xdr; -bool_t xdr_authunix_parms(struct __rpc_xdr *xdrs, uint32_t *time, struct xucred *cred); +struct XDR; +bool_t xdr_authunix_parms(struct XDR *xdrs, uint32_t *time, struct xucred *cred); #endif __END_DECLS Modified: stable/9/sys/rpc/xdr.h ============================================================================== --- stable/9/sys/rpc/xdr.h Sat Sep 15 21:56:30 2012 (r240541) +++ stable/9/sys/rpc/xdr.h Sun Sep 16 00:32:25 2012 (r240542) @@ -97,26 +97,26 @@ enum xdr_op { * an operations vector for the particular implementation (e.g. see xdr_mem.c), * and two private fields for the use of the particular implementation. */ -typedef struct __rpc_xdr { +typedef struct XDR { enum xdr_op x_op; /* operation; fast additional param */ const struct xdr_ops { /* get a long from underlying stream */ - bool_t (*x_getlong)(struct __rpc_xdr *, long *); + bool_t (*x_getlong)(struct XDR *, long *); /* put a long to " */ - bool_t (*x_putlong)(struct __rpc_xdr *, const long *); + bool_t (*x_putlong)(struct XDR *, const long *); /* get some bytes from " */ - bool_t (*x_getbytes)(struct __rpc_xdr *, char *, u_int); + bool_t (*x_getbytes)(struct XDR *, char *, u_int); /* put some bytes to " */ - bool_t (*x_putbytes)(struct __rpc_xdr *, const char *, u_int); + bool_t (*x_putbytes)(struct XDR *, const char *, u_int); /* returns bytes off from beginning */ - u_int (*x_getpostn)(struct __rpc_xdr *); + u_int (*x_getpostn)(struct XDR *); /* lets you reposition the stream */ - bool_t (*x_setpostn)(struct __rpc_xdr *, u_int); + bool_t (*x_setpostn)(struct XDR *, u_int); /* buf quick ptr to buffered data */ - int32_t *(*x_inline)(struct __rpc_xdr *, u_int); + int32_t *(*x_inline)(struct XDR *, u_int); /* free privates of this xdr_stream */ - void (*x_destroy)(struct __rpc_xdr *); - bool_t (*x_control)(struct __rpc_xdr *, int, void *); + void (*x_destroy)(struct XDR *); + bool_t (*x_control)(struct XDR *, int, void *); } *x_ops; char * x_public; /* users' data */ void * x_private; /* pointer to private data */ From owner-svn-src-stable@FreeBSD.ORG Sun Sep 16 00:34:04 2012 Return-Path: Delivered-To: svn-src-stable@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id CBE4D1065670; Sun, 16 Sep 2012 00:34:04 +0000 (UTC) (envelope-from pfg@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id AD3C48FC0A; Sun, 16 Sep 2012 00:34:04 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q8G0Y4TH067323; Sun, 16 Sep 2012 00:34:04 GMT (envelope-from pfg@svn.freebsd.org) Received: (from pfg@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q8G0Y47w067318; Sun, 16 Sep 2012 00:34:04 GMT (envelope-from pfg@svn.freebsd.org) Message-Id: <201209160034.q8G0Y47w067318@svn.freebsd.org> From: "Pedro F. Giffuni" Date: Sun, 16 Sep 2012 00:34:04 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-8@freebsd.org X-SVN-Group: stable-8 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r240543 - in stable/8: include/rpc sys/rpc X-BeenThere: svn-src-stable@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for all the -stable branches of the src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 16 Sep 2012 00:34:04 -0000 Author: pfg Date: Sun Sep 16 00:34:04 2012 New Revision: 240543 URL: http://svn.freebsd.org/changeset/base/240543 Log: MFC r240060, r240062: Rename __rpc_xdr with XDR. This fixes at least one C++ application and matches what upstream (Solaris) has done on their xdr.h header. PR: 137443 Modified: stable/8/include/rpc/xdr.h stable/8/sys/rpc/rpc_com.h stable/8/sys/rpc/xdr.h Directory Properties: stable/8/include/rpc/ (props changed) stable/8/sys/rpc/ (props changed) Modified: stable/8/include/rpc/xdr.h ============================================================================== --- stable/8/include/rpc/xdr.h Sun Sep 16 00:32:25 2012 (r240542) +++ stable/8/include/rpc/xdr.h Sun Sep 16 00:34:04 2012 (r240543) @@ -97,26 +97,26 @@ enum xdr_op { * an operations vector for the particular implementation (e.g. see xdr_mem.c), * and two private fields for the use of the particular implementation. */ -typedef struct __rpc_xdr { +typedef struct XDR { enum xdr_op x_op; /* operation; fast additional param */ const struct xdr_ops { /* get a long from underlying stream */ - bool_t (*x_getlong)(struct __rpc_xdr *, long *); + bool_t (*x_getlong)(struct XDR *, long *); /* put a long to " */ - bool_t (*x_putlong)(struct __rpc_xdr *, const long *); + bool_t (*x_putlong)(struct XDR *, const long *); /* get some bytes from " */ - bool_t (*x_getbytes)(struct __rpc_xdr *, char *, u_int); + bool_t (*x_getbytes)(struct XDR *, char *, u_int); /* put some bytes to " */ - bool_t (*x_putbytes)(struct __rpc_xdr *, const char *, u_int); + bool_t (*x_putbytes)(struct XDR *, const char *, u_int); /* returns bytes off from beginning */ - u_int (*x_getpostn)(struct __rpc_xdr *); + u_int (*x_getpostn)(struct XDR *); /* lets you reposition the stream */ - bool_t (*x_setpostn)(struct __rpc_xdr *, u_int); + bool_t (*x_setpostn)(struct XDR *, u_int); /* buf quick ptr to buffered data */ - int32_t *(*x_inline)(struct __rpc_xdr *, u_int); + int32_t *(*x_inline)(struct XDR *, u_int); /* free privates of this xdr_stream */ - void (*x_destroy)(struct __rpc_xdr *); - bool_t (*x_control)(struct __rpc_xdr *, int, void *); + void (*x_destroy)(struct XDR *); + bool_t (*x_control)(struct XDR *, int, void *); } *x_ops; char * x_public; /* users' data */ void * x_private; /* pointer to private data */ Modified: stable/8/sys/rpc/rpc_com.h ============================================================================== --- stable/8/sys/rpc/rpc_com.h Sun Sep 16 00:32:25 2012 (r240542) +++ stable/8/sys/rpc/rpc_com.h Sun Sep 16 00:34:04 2012 (r240543) @@ -114,8 +114,8 @@ extern int __rpc_sockisbound(struct sock extern int bindresvport(struct socket *so, struct sockaddr *sa); struct xucred; -struct __rpc_xdr; -bool_t xdr_authunix_parms(struct __rpc_xdr *xdrs, uint32_t *time, struct xucred *cred); +struct XDR; +bool_t xdr_authunix_parms(struct XDR *xdrs, uint32_t *time, struct xucred *cred); #endif __END_DECLS Modified: stable/8/sys/rpc/xdr.h ============================================================================== --- stable/8/sys/rpc/xdr.h Sun Sep 16 00:32:25 2012 (r240542) +++ stable/8/sys/rpc/xdr.h Sun Sep 16 00:34:04 2012 (r240543) @@ -97,26 +97,26 @@ enum xdr_op { * an operations vector for the particular implementation (e.g. see xdr_mem.c), * and two private fields for the use of the particular implementation. */ -typedef struct __rpc_xdr { +typedef struct XDR { enum xdr_op x_op; /* operation; fast additional param */ const struct xdr_ops { /* get a long from underlying stream */ - bool_t (*x_getlong)(struct __rpc_xdr *, long *); + bool_t (*x_getlong)(struct XDR *, long *); /* put a long to " */ - bool_t (*x_putlong)(struct __rpc_xdr *, const long *); + bool_t (*x_putlong)(struct XDR *, const long *); /* get some bytes from " */ - bool_t (*x_getbytes)(struct __rpc_xdr *, char *, u_int); + bool_t (*x_getbytes)(struct XDR *, char *, u_int); /* put some bytes to " */ - bool_t (*x_putbytes)(struct __rpc_xdr *, const char *, u_int); + bool_t (*x_putbytes)(struct XDR *, const char *, u_int); /* returns bytes off from beginning */ - u_int (*x_getpostn)(struct __rpc_xdr *); + u_int (*x_getpostn)(struct XDR *); /* lets you reposition the stream */ - bool_t (*x_setpostn)(struct __rpc_xdr *, u_int); + bool_t (*x_setpostn)(struct XDR *, u_int); /* buf quick ptr to buffered data */ - int32_t *(*x_inline)(struct __rpc_xdr *, u_int); + int32_t *(*x_inline)(struct XDR *, u_int); /* free privates of this xdr_stream */ - void (*x_destroy)(struct __rpc_xdr *); - bool_t (*x_control)(struct __rpc_xdr *, int, void *); + void (*x_destroy)(struct XDR *); + bool_t (*x_control)(struct XDR *, int, void *); } *x_ops; char * x_public; /* users' data */ void * x_private; /* pointer to private data */ From owner-svn-src-stable@FreeBSD.ORG Sun Sep 16 00:35:10 2012 Return-Path: Delivered-To: svn-src-stable@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 08D95106566C; Sun, 16 Sep 2012 00:35:10 +0000 (UTC) (envelope-from eadler@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id C933B8FC0C; Sun, 16 Sep 2012 00:35:09 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q8G0Z9sC067521; Sun, 16 Sep 2012 00:35:09 GMT (envelope-from eadler@svn.freebsd.org) Received: (from eadler@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q8G0Z9iL067507; Sun, 16 Sep 2012 00:35:09 GMT (envelope-from eadler@svn.freebsd.org) Message-Id: <201209160035.q8G0Z9iL067507@svn.freebsd.org> From: Eitan Adler Date: Sun, 16 Sep 2012 00:35:09 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-8@freebsd.org X-SVN-Group: stable-8 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r240544 - in stable/8/share/examples: . cvsup X-BeenThere: svn-src-stable@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for all the -stable branches of the src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 16 Sep 2012 00:35:10 -0000 Author: eadler Date: Sun Sep 16 00:35:09 2012 New Revision: 240544 URL: http://svn.freebsd.org/changeset/base/240544 Log: MFC r240252,r240253: Remove documentation and www cvsup files as they are no longer useful with the switch to subversion. Specifically document that an incomplete ports tree is not supported. Remove useless comment about sendmail. Approved by: cperciva (implicit) Deleted: stable/8/share/examples/cvsup/doc-supfile stable/8/share/examples/cvsup/www-supfile Modified: stable/8/share/examples/Makefile stable/8/share/examples/cvsup/cvs-supfile stable/8/share/examples/cvsup/refuse stable/8/share/examples/cvsup/refuse.README stable/8/share/examples/cvsup/stable-supfile Directory Properties: stable/8/share/examples/ (props changed) stable/8/share/examples/cvsup/ (props changed) stable/8/share/man/man5/ (props changed) Modified: stable/8/share/examples/Makefile ============================================================================== --- stable/8/share/examples/Makefile Sun Sep 16 00:34:04 2012 (r240543) +++ stable/8/share/examples/Makefile Sun Sep 16 00:35:09 2012 (r240544) @@ -52,14 +52,12 @@ XFILES= BSD_daemon/FreeBSD.pfa \ csh/dot.cshrc \ cvsup/README \ cvsup/cvs-supfile \ - cvsup/doc-supfile \ cvsup/gnats-supfile \ cvsup/ports-supfile \ cvsup/refuse \ cvsup/refuse.README \ cvsup/stable-supfile \ cvsup/standard-supfile \ - cvsup/www-supfile \ diskless/ME \ diskless/README.BOOTP \ diskless/README.TEMPLATING \ Modified: stable/8/share/examples/cvsup/cvs-supfile ============================================================================== --- stable/8/share/examples/cvsup/cvs-supfile Sun Sep 16 00:34:04 2012 (r240543) +++ stable/8/share/examples/cvsup/cvs-supfile Sun Sep 16 00:35:09 2012 (r240544) @@ -169,19 +169,6 @@ ports-all #ports-x11-toolkits #ports-x11-wm -## Documentation -# -# The easiest way to get the doc tree is to use the "doc-all" -# mega-collection. It includes all of the individual "doc-*" -# collections, -doc-all - -## Website -# -# This collection retrieves the www tree of the FreeBSD -# repository -www - ## Projects # # This collection retrieves the projects tree of the FreeBSD @@ -200,4 +187,3 @@ cvsroot-all #cvsroot-common #cvsroot-src #cvsroot-ports -#cvsroot-doc Modified: stable/8/share/examples/cvsup/refuse ============================================================================== --- stable/8/share/examples/cvsup/refuse Sun Sep 16 00:34:04 2012 (r240543) +++ stable/8/share/examples/cvsup/refuse Sun Sep 16 00:35:09 2012 (r240544) @@ -1,23 +1,3 @@ -doc/bn_* -doc/da_* -doc/de_* -doc/el_* -doc/es_* -doc/fr_* -doc/hu_* -doc/id_* -doc/it_* -doc/ja_* -doc/mn_* -doc/nl_* -doc/no_* -doc/pl_* -doc/pt_* -doc/ro_* -doc/ru_* -doc/sr_* -doc/tr_* -doc/zh_* ports/arabic ports/chinese ports/french Modified: stable/8/share/examples/cvsup/refuse.README ============================================================================== --- stable/8/share/examples/cvsup/refuse.README Sun Sep 16 00:34:04 2012 (r240543) +++ stable/8/share/examples/cvsup/refuse.README Sun Sep 16 00:35:09 2012 (r240544) @@ -16,33 +16,9 @@ CVSup's base directory to "/var/db". Th directory; i.e., it is "/var/db/sup". If you have changed your base directory, your sup directory is /path/to/base/sup. -This file used to contain /usr/src/etc/sendmail/freebsd.mc in case -you modified that file. However, this was removed as it can break -buildworld. Modify /etc/mail/`hostname`.mc instead. - If you are an English speaker and don't wish to receive the -foreign-language documentation or ports, use the following patterns: +non-English ports, use the following patterns: - doc/bn_* - doc/da_* - doc/de_* - doc/el_* - doc/es_* - doc/fr_* - doc/hu_* - doc/id_* - doc/it_* - doc/ja_* - doc/mn_* - doc/nl_* - doc/no_* - doc/pl_* - doc/pt_* - doc/ro_* - doc/ru_* - doc/sr_* - doc/tr_* - doc/zh_* ports/arabic ports/chinese ports/french @@ -57,6 +33,9 @@ foreign-language documentation or ports, ports/ukrainian ports/vietnamese +Note that this is *not* a supported configuration and may result +in ports builds breaking. + Use refuse files with care. Some parts of the src distribution depend on files in completely different parts. Modified: stable/8/share/examples/cvsup/stable-supfile ============================================================================== --- stable/8/share/examples/cvsup/stable-supfile Sun Sep 16 00:34:04 2012 (r240543) +++ stable/8/share/examples/cvsup/stable-supfile Sun Sep 16 00:35:09 2012 (r240544) @@ -43,14 +43,13 @@ # # DANGER! WARNING! LOOK OUT! VORSICHT! # -# If you add any of the ports or doc collections to this file, be sure to +# If you add any of the ports collections to this file, be sure to # specify them with a "tag" value set to ".", like this: # # ports-all tag=. -# doc-all tag=. # # If you leave out the "tag=." portion, CVSup will delete all of -# the files in your ports or doc tree. That is because the ports and doc +# the files in your ports. That is because the ports # collections do not use the same tags as the main part of the FreeBSD # source tree. # From owner-svn-src-stable@FreeBSD.ORG Sun Sep 16 00:35:10 2012 Return-Path: Delivered-To: svn-src-stable@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 374DA1065670; Sun, 16 Sep 2012 00:35:10 +0000 (UTC) (envelope-from eadler@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 177818FC16; Sun, 16 Sep 2012 00:35:10 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q8G0Z91L067532; Sun, 16 Sep 2012 00:35:09 GMT (envelope-from eadler@svn.freebsd.org) Received: (from eadler@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q8G0Z9q6067523; Sun, 16 Sep 2012 00:35:09 GMT (envelope-from eadler@svn.freebsd.org) Message-Id: <201209160035.q8G0Z9q6067523@svn.freebsd.org> From: Eitan Adler Date: Sun, 16 Sep 2012 00:35:09 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r240545 - in stable/9/share/examples: . cvsup etc X-BeenThere: svn-src-stable@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for all the -stable branches of the src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 16 Sep 2012 00:35:10 -0000 Author: eadler Date: Sun Sep 16 00:35:09 2012 New Revision: 240545 URL: http://svn.freebsd.org/changeset/base/240545 Log: MFC r240252,r240253: Remove documentation and www cvsup files as they are no longer useful with the switch to subversion. Specifically document that an incomplete ports tree is not supported. Remove useless comment about sendmail. Approved by: cperciva (implicit) Deleted: stable/9/share/examples/cvsup/doc-supfile stable/9/share/examples/cvsup/www-supfile Modified: stable/9/share/examples/Makefile stable/9/share/examples/cvsup/cvs-supfile stable/9/share/examples/cvsup/refuse stable/9/share/examples/cvsup/refuse.README stable/9/share/examples/cvsup/stable-supfile stable/9/share/examples/etc/make.conf Directory Properties: stable/9/share/examples/ (props changed) stable/9/share/examples/cvsup/ (props changed) stable/9/share/examples/etc/ (props changed) stable/9/share/man/man5/ (props changed) Modified: stable/9/share/examples/Makefile ============================================================================== --- stable/9/share/examples/Makefile Sun Sep 16 00:35:09 2012 (r240544) +++ stable/9/share/examples/Makefile Sun Sep 16 00:35:09 2012 (r240545) @@ -53,14 +53,12 @@ XFILES= BSD_daemon/FreeBSD.pfa \ csh/dot.cshrc \ cvsup/README \ cvsup/cvs-supfile \ - cvsup/doc-supfile \ cvsup/gnats-supfile \ cvsup/ports-supfile \ cvsup/refuse \ cvsup/refuse.README \ cvsup/stable-supfile \ cvsup/standard-supfile \ - cvsup/www-supfile \ diskless/ME \ diskless/README.BOOTP \ diskless/README.TEMPLATING \ Modified: stable/9/share/examples/cvsup/cvs-supfile ============================================================================== --- stable/9/share/examples/cvsup/cvs-supfile Sun Sep 16 00:35:09 2012 (r240544) +++ stable/9/share/examples/cvsup/cvs-supfile Sun Sep 16 00:35:09 2012 (r240545) @@ -169,19 +169,6 @@ ports-all #ports-x11-toolkits #ports-x11-wm -## Documentation -# -# The easiest way to get the doc tree is to use the "doc-all" -# mega-collection. It includes all of the individual "doc-*" -# collections, -doc-all - -## Website -# -# This collection retrieves the www tree of the FreeBSD -# repository -www - ## Projects # # This collection retrieves the projects tree of the FreeBSD @@ -200,4 +187,3 @@ cvsroot-all #cvsroot-common #cvsroot-src #cvsroot-ports -#cvsroot-doc Modified: stable/9/share/examples/cvsup/refuse ============================================================================== --- stable/9/share/examples/cvsup/refuse Sun Sep 16 00:35:09 2012 (r240544) +++ stable/9/share/examples/cvsup/refuse Sun Sep 16 00:35:09 2012 (r240545) @@ -1,23 +1,3 @@ -doc/bn_* -doc/da_* -doc/de_* -doc/el_* -doc/es_* -doc/fr_* -doc/hu_* -doc/id_* -doc/it_* -doc/ja_* -doc/mn_* -doc/nl_* -doc/no_* -doc/pl_* -doc/pt_* -doc/ro_* -doc/ru_* -doc/sr_* -doc/tr_* -doc/zh_* ports/arabic ports/chinese ports/french Modified: stable/9/share/examples/cvsup/refuse.README ============================================================================== --- stable/9/share/examples/cvsup/refuse.README Sun Sep 16 00:35:09 2012 (r240544) +++ stable/9/share/examples/cvsup/refuse.README Sun Sep 16 00:35:09 2012 (r240545) @@ -16,33 +16,9 @@ CVSup's base directory to "/var/db". Th directory; i.e., it is "/var/db/sup". If you have changed your base directory, your sup directory is /path/to/base/sup. -This file used to contain /usr/src/etc/sendmail/freebsd.mc in case -you modified that file. However, this was removed as it can break -buildworld. Modify /etc/mail/`hostname`.mc instead. - If you are an English speaker and don't wish to receive the -foreign-language documentation or ports, use the following patterns: +non-English ports, use the following patterns: - doc/bn_* - doc/da_* - doc/de_* - doc/el_* - doc/es_* - doc/fr_* - doc/hu_* - doc/id_* - doc/it_* - doc/ja_* - doc/mn_* - doc/nl_* - doc/no_* - doc/pl_* - doc/pt_* - doc/ro_* - doc/ru_* - doc/sr_* - doc/tr_* - doc/zh_* ports/arabic ports/chinese ports/french @@ -57,6 +33,9 @@ foreign-language documentation or ports, ports/ukrainian ports/vietnamese +Note that this is *not* a supported configuration and may result +in ports builds breaking. + Use refuse files with care. Some parts of the src distribution depend on files in completely different parts. Modified: stable/9/share/examples/cvsup/stable-supfile ============================================================================== --- stable/9/share/examples/cvsup/stable-supfile Sun Sep 16 00:35:09 2012 (r240544) +++ stable/9/share/examples/cvsup/stable-supfile Sun Sep 16 00:35:09 2012 (r240545) @@ -43,14 +43,13 @@ # # DANGER! WARNING! LOOK OUT! VORSICHT! # -# If you add any of the ports or doc collections to this file, be sure to +# If you add any of the ports collections to this file, be sure to # specify them with a "tag" value set to ".", like this: # # ports-all tag=. -# doc-all tag=. # # If you leave out the "tag=." portion, CVSup will delete all of -# the files in your ports or doc tree. That is because the ports and doc +# the files in your ports. That is because the ports # collections do not use the same tags as the main part of the FreeBSD # source tree. # Modified: stable/9/share/examples/etc/make.conf ============================================================================== --- stable/9/share/examples/etc/make.conf Sun Sep 16 00:35:09 2012 (r240544) +++ stable/9/share/examples/etc/make.conf Sun Sep 16 00:35:09 2012 (r240545) @@ -187,8 +187,6 @@ #SUPHOST= cvsup.uk.FreeBSD.org #SUPFILE= /usr/share/examples/cvsup/standard-supfile #PORTSSUPFILE= /usr/share/examples/cvsup/ports-supfile -#DOCSUPFILE= /usr/share/examples/cvsup/doc-supfile -#WWWSUPFILE= /usr/share/examples/cvsup/www-supfile # # top(1) uses a hash table for the user names. The size of this hash # can be tuned to match the number of local users. The table size should From owner-svn-src-stable@FreeBSD.ORG Sun Sep 16 08:42:41 2012 Return-Path: Delivered-To: svn-src-stable@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 29E52106566B; Sun, 16 Sep 2012 08:42:41 +0000 (UTC) (envelope-from mav@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 0BABE8FC12; Sun, 16 Sep 2012 08:42:41 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q8G8ge5F043358; Sun, 16 Sep 2012 08:42:41 GMT (envelope-from mav@svn.freebsd.org) Received: (from mav@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q8G8gelW043344; Sun, 16 Sep 2012 08:42:40 GMT (envelope-from mav@svn.freebsd.org) Message-Id: <201209160842.q8G8gelW043344@svn.freebsd.org> From: Alexander Motin Date: Sun, 16 Sep 2012 08:42:40 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r240552 - stable/9/sys/geom/raid X-BeenThere: svn-src-stable@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for all the -stable branches of the src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 16 Sep 2012 08:42:41 -0000 Author: mav Date: Sun Sep 16 08:42:40 2012 New Revision: 240552 URL: http://svn.freebsd.org/changeset/base/240552 Log: MFC r240465: Add global and per-module sysctls/tunables to enable/disable metadata taste. That should help to handle some cases when disk has some RAID metadata that should be ignored, especially during boot. Modified: stable/9/sys/geom/raid/g_raid.c stable/9/sys/geom/raid/g_raid.h stable/9/sys/geom/raid/md_ddf.c stable/9/sys/geom/raid/md_intel.c stable/9/sys/geom/raid/md_jmicron.c stable/9/sys/geom/raid/md_nvidia.c stable/9/sys/geom/raid/md_promise.c stable/9/sys/geom/raid/md_sii.c stable/9/sys/geom/raid/tr_concat.c stable/9/sys/geom/raid/tr_raid0.c stable/9/sys/geom/raid/tr_raid1.c stable/9/sys/geom/raid/tr_raid1e.c stable/9/sys/geom/raid/tr_raid5.c Directory Properties: stable/9/share/man/man4/ (props changed) stable/9/sys/ (props changed) Modified: stable/9/sys/geom/raid/g_raid.c ============================================================================== --- stable/9/sys/geom/raid/g_raid.c Sun Sep 16 08:09:10 2012 (r240551) +++ stable/9/sys/geom/raid/g_raid.c Sun Sep 16 08:42:40 2012 (r240552) @@ -52,6 +52,10 @@ static MALLOC_DEFINE(M_RAID, "raid_data" SYSCTL_DECL(_kern_geom); SYSCTL_NODE(_kern_geom, OID_AUTO, raid, CTLFLAG_RW, 0, "GEOM_RAID stuff"); +int g_raid_enable = 1; +TUNABLE_INT("kern.geom.raid.enable", &g_raid_enable); +SYSCTL_INT(_kern_geom_raid, OID_AUTO, enable, CTLFLAG_RW, + &g_raid_enable, 0, "Enable on-disk metadata taste"); u_int g_raid_aggressive_spare = 0; TUNABLE_INT("kern.geom.raid.aggressive_spare", &g_raid_aggressive_spare); SYSCTL_UINT(_kern_geom_raid, OID_AUTO, aggressive_spare, CTLFLAG_RW, @@ -1920,6 +1924,8 @@ int g_raid_start_volume(struct g_raid_vo G_RAID_DEBUG1(2, vol->v_softc, "Starting volume %s.", vol->v_name); LIST_FOREACH(class, &g_raid_tr_classes, trc_list) { + if (!class->trc_enable) + continue; G_RAID_DEBUG1(2, vol->v_softc, "Tasting volume %s for %s transformation.", vol->v_name, class->name); @@ -2142,6 +2148,8 @@ g_raid_taste(struct g_class *mp, struct g_topology_assert(); g_trace(G_T_TOPOLOGY, "%s(%s, %s)", __func__, mp->name, pp->name); + if (!g_raid_enable) + return (NULL); G_RAID_DEBUG(2, "Tasting provider %s.", pp->name); gp = g_new_geomf(mp, "raid:taste"); @@ -2154,6 +2162,8 @@ g_raid_taste(struct g_class *mp, struct geom = NULL; LIST_FOREACH(class, &g_raid_md_classes, mdc_list) { + if (!class->mdc_enable) + continue; G_RAID_DEBUG(2, "Tasting provider %s for %s metadata.", pp->name, class->name); obj = (void *)kobj_create((kobj_class_t)class, M_RAID, Modified: stable/9/sys/geom/raid/g_raid.h ============================================================================== --- stable/9/sys/geom/raid/g_raid.h Sun Sep 16 08:09:10 2012 (r240551) +++ stable/9/sys/geom/raid/g_raid.h Sun Sep 16 08:42:40 2012 (r240552) @@ -33,6 +33,9 @@ #include #include #include +#ifdef _KERNEL +#include +#endif #define G_RAID_CLASS_NAME "RAID" @@ -51,6 +54,7 @@ struct g_raid_tr_object; #ifdef _KERNEL extern u_int g_raid_aggressive_spare; extern u_int g_raid_debug; +extern int g_raid_enable; extern int g_raid_read_err_thresh; extern u_int g_raid_start_timeout; extern struct g_class g_raid_class; @@ -322,11 +326,14 @@ struct g_raid_softc { }; #define sc_name sc_geom->name +SYSCTL_DECL(_kern_geom_raid); + /* * KOBJ parent class of metadata processing modules. */ struct g_raid_md_class { KOBJ_CLASS_FIELDS; + int mdc_enable; int mdc_priority; LIST_ENTRY(g_raid_md_class) mdc_list; }; @@ -342,20 +349,29 @@ struct g_raid_md_object { int g_raid_md_modevent(module_t, int, void *); -#define G_RAID_MD_DECLARE(name) \ - static moduledata_t name##_mod = { \ - #name, \ +#define G_RAID_MD_DECLARE(name, label) \ + static moduledata_t g_raid_md_##name##_mod = { \ + "g_raid_md_" __XSTRING(name), \ g_raid_md_modevent, \ - &name##_class \ + &g_raid_md_##name##_class \ }; \ - DECLARE_MODULE(name, name##_mod, SI_SUB_DRIVERS, SI_ORDER_SECOND); \ - MODULE_DEPEND(name, geom_raid, 0, 0, 0) + DECLARE_MODULE(g_raid_md_##name, g_raid_md_##name##_mod, \ + SI_SUB_DRIVERS, SI_ORDER_SECOND); \ + MODULE_DEPEND(g_raid_md_##name, geom_raid, 0, 0, 0); \ + SYSCTL_NODE(_kern_geom_raid, OID_AUTO, name, CTLFLAG_RD, \ + NULL, label " metadata module"); \ + SYSCTL_INT(_kern_geom_raid_##name, OID_AUTO, enable, \ + CTLFLAG_RW, &g_raid_md_##name##_class.mdc_enable, 0, \ + "Enable " label " metadata format taste"); \ + TUNABLE_INT("kern.geom.raid." __XSTRING(name) ".enable", \ + &g_raid_md_##name##_class.mdc_enable) /* * KOBJ parent class of data transformation modules. */ struct g_raid_tr_class { KOBJ_CLASS_FIELDS; + int trc_enable; int trc_priority; LIST_ENTRY(g_raid_tr_class) trc_list; }; @@ -371,14 +387,22 @@ struct g_raid_tr_object { int g_raid_tr_modevent(module_t, int, void *); -#define G_RAID_TR_DECLARE(name) \ - static moduledata_t name##_mod = { \ - #name, \ +#define G_RAID_TR_DECLARE(name, label) \ + static moduledata_t g_raid_tr_##name##_mod = { \ + "g_raid_tr_" __XSTRING(name), \ g_raid_tr_modevent, \ - &name##_class \ + &g_raid_tr_##name##_class \ }; \ - DECLARE_MODULE(name, name##_mod, SI_SUB_DRIVERS, SI_ORDER_FIRST); \ - MODULE_DEPEND(name, geom_raid, 0, 0, 0) + DECLARE_MODULE(g_raid_tr_##name, g_raid_tr_##name##_mod, \ + SI_SUB_DRIVERS, SI_ORDER_FIRST); \ + MODULE_DEPEND(g_raid_tr_##name, geom_raid, 0, 0, 0); \ + SYSCTL_NODE(_kern_geom_raid, OID_AUTO, name, CTLFLAG_RD, \ + NULL, label " transformation module"); \ + SYSCTL_INT(_kern_geom_raid_##name, OID_AUTO, enable, \ + CTLFLAG_RW, &g_raid_tr_##name##_class.trc_enable, 0, \ + "Enable " label " transformation module taste"); \ + TUNABLE_INT("kern.geom.raid." __XSTRING(name) ".enable", \ + &g_raid_tr_##name##_class.trc_enable) const char * g_raid_volume_level2str(int level, int qual); int g_raid_volume_str2level(const char *str, int *level, int *qual); Modified: stable/9/sys/geom/raid/md_ddf.c ============================================================================== --- stable/9/sys/geom/raid/md_ddf.c Sun Sep 16 08:09:10 2012 (r240551) +++ stable/9/sys/geom/raid/md_ddf.c Sun Sep 16 08:42:40 2012 (r240552) @@ -125,6 +125,7 @@ static struct g_raid_md_class g_raid_md_ "DDF", g_raid_md_ddf_methods, sizeof(struct g_raid_md_ddf_object), + .mdc_enable = 1, .mdc_priority = 100 }; @@ -3065,4 +3066,4 @@ g_raid_md_free_ddf(struct g_raid_md_obje return (0); } -G_RAID_MD_DECLARE(g_raid_md_ddf); +G_RAID_MD_DECLARE(ddf, "DDF"); Modified: stable/9/sys/geom/raid/md_intel.c ============================================================================== --- stable/9/sys/geom/raid/md_intel.c Sun Sep 16 08:09:10 2012 (r240551) +++ stable/9/sys/geom/raid/md_intel.c Sun Sep 16 08:42:40 2012 (r240552) @@ -224,6 +224,7 @@ static struct g_raid_md_class g_raid_md_ "Intel", g_raid_md_intel_methods, sizeof(struct g_raid_md_intel_object), + .mdc_enable = 1, .mdc_priority = 100 }; @@ -2432,4 +2433,4 @@ g_raid_md_free_intel(struct g_raid_md_ob return (0); } -G_RAID_MD_DECLARE(g_raid_md_intel); +G_RAID_MD_DECLARE(intel, "Intel"); Modified: stable/9/sys/geom/raid/md_jmicron.c ============================================================================== --- stable/9/sys/geom/raid/md_jmicron.c Sun Sep 16 08:09:10 2012 (r240551) +++ stable/9/sys/geom/raid/md_jmicron.c Sun Sep 16 08:42:40 2012 (r240552) @@ -132,6 +132,7 @@ static struct g_raid_md_class g_raid_md_ "JMicron", g_raid_md_jmicron_methods, sizeof(struct g_raid_md_jmicron_object), + .mdc_enable = 1, .mdc_priority = 100 }; @@ -1581,4 +1582,4 @@ g_raid_md_free_jmicron(struct g_raid_md_ return (0); } -G_RAID_MD_DECLARE(g_raid_md_jmicron); +G_RAID_MD_DECLARE(jmicron, "JMicron"); Modified: stable/9/sys/geom/raid/md_nvidia.c ============================================================================== --- stable/9/sys/geom/raid/md_nvidia.c Sun Sep 16 08:09:10 2012 (r240551) +++ stable/9/sys/geom/raid/md_nvidia.c Sun Sep 16 08:42:40 2012 (r240552) @@ -143,6 +143,7 @@ static struct g_raid_md_class g_raid_md_ "NVIDIA", g_raid_md_nvidia_methods, sizeof(struct g_raid_md_nvidia_object), + .mdc_enable = 1, .mdc_priority = 100 }; @@ -1600,4 +1601,4 @@ g_raid_md_free_nvidia(struct g_raid_md_o return (0); } -G_RAID_MD_DECLARE(g_raid_md_nvidia); +G_RAID_MD_DECLARE(nvidia, "NVIDIA"); Modified: stable/9/sys/geom/raid/md_promise.c ============================================================================== --- stable/9/sys/geom/raid/md_promise.c Sun Sep 16 08:09:10 2012 (r240551) +++ stable/9/sys/geom/raid/md_promise.c Sun Sep 16 08:42:40 2012 (r240552) @@ -171,6 +171,7 @@ static struct g_raid_md_class g_raid_md_ "Promise", g_raid_md_promise_methods, sizeof(struct g_raid_md_object), + .mdc_enable = 1, .mdc_priority = 100 }; @@ -1967,4 +1968,4 @@ g_raid_md_free_promise(struct g_raid_md_ return (0); } -G_RAID_MD_DECLARE(g_raid_md_promise); +G_RAID_MD_DECLARE(promise, "Promise"); Modified: stable/9/sys/geom/raid/md_sii.c ============================================================================== --- stable/9/sys/geom/raid/md_sii.c Sun Sep 16 08:09:10 2012 (r240551) +++ stable/9/sys/geom/raid/md_sii.c Sun Sep 16 08:42:40 2012 (r240552) @@ -140,6 +140,7 @@ static struct g_raid_md_class g_raid_md_ "SiI", g_raid_md_sii_methods, sizeof(struct g_raid_md_sii_object), + .mdc_enable = 1, .mdc_priority = 100 }; @@ -1688,4 +1689,4 @@ g_raid_md_free_sii(struct g_raid_md_obje return (0); } -G_RAID_MD_DECLARE(g_raid_md_sii); +G_RAID_MD_DECLARE(sii, "SiI"); Modified: stable/9/sys/geom/raid/tr_concat.c ============================================================================== --- stable/9/sys/geom/raid/tr_concat.c Sun Sep 16 08:09:10 2012 (r240551) +++ stable/9/sys/geom/raid/tr_concat.c Sun Sep 16 08:42:40 2012 (r240552) @@ -73,6 +73,7 @@ static struct g_raid_tr_class g_raid_tr_ "CONCAT", g_raid_tr_concat_methods, sizeof(struct g_raid_tr_concat_object), + .trc_enable = 1, .trc_priority = 50 }; @@ -340,4 +341,4 @@ g_raid_tr_free_concat(struct g_raid_tr_o return (0); } -G_RAID_TR_DECLARE(g_raid_tr_concat); +G_RAID_TR_DECLARE(concat, "CONCAT"); Modified: stable/9/sys/geom/raid/tr_raid0.c ============================================================================== --- stable/9/sys/geom/raid/tr_raid0.c Sun Sep 16 08:09:10 2012 (r240551) +++ stable/9/sys/geom/raid/tr_raid0.c Sun Sep 16 08:42:40 2012 (r240552) @@ -73,6 +73,7 @@ static struct g_raid_tr_class g_raid_tr_ "RAID0", g_raid_tr_raid0_methods, sizeof(struct g_raid_tr_raid0_object), + .trc_enable = 1, .trc_priority = 100 }; @@ -323,4 +324,4 @@ g_raid_tr_free_raid0(struct g_raid_tr_ob return (0); } -G_RAID_TR_DECLARE(g_raid_tr_raid0); +G_RAID_TR_DECLARE(raid0, "RAID0"); Modified: stable/9/sys/geom/raid/tr_raid1.c ============================================================================== --- stable/9/sys/geom/raid/tr_raid1.c Sun Sep 16 08:09:10 2012 (r240551) +++ stable/9/sys/geom/raid/tr_raid1.c Sun Sep 16 08:42:40 2012 (r240552) @@ -42,9 +42,7 @@ __FBSDID("$FreeBSD$"); #include "geom/raid/g_raid.h" #include "g_raid_tr_if.h" -SYSCTL_DECL(_kern_geom_raid); -SYSCTL_NODE(_kern_geom_raid, OID_AUTO, raid1, CTLFLAG_RW, 0, - "RAID1 parameters"); +SYSCTL_DECL(_kern_geom_raid_raid1); #define RAID1_REBUILD_SLAB (1 << 20) /* One transation in a rebuild */ static int g_raid1_rebuild_slab = RAID1_REBUILD_SLAB; @@ -131,6 +129,7 @@ static struct g_raid_tr_class g_raid_tr_ "RAID1", g_raid_tr_raid1_methods, sizeof(struct g_raid_tr_raid1_object), + .trc_enable = 1, .trc_priority = 100 }; @@ -996,4 +995,4 @@ g_raid_tr_free_raid1(struct g_raid_tr_ob return (0); } -G_RAID_TR_DECLARE(g_raid_tr_raid1); +G_RAID_TR_DECLARE(raid1, "RAID1"); Modified: stable/9/sys/geom/raid/tr_raid1e.c ============================================================================== --- stable/9/sys/geom/raid/tr_raid1e.c Sun Sep 16 08:09:10 2012 (r240551) +++ stable/9/sys/geom/raid/tr_raid1e.c Sun Sep 16 08:42:40 2012 (r240552) @@ -44,9 +44,7 @@ __FBSDID("$FreeBSD$"); #define N 2 -SYSCTL_DECL(_kern_geom_raid); -SYSCTL_NODE(_kern_geom_raid, OID_AUTO, raid1e, CTLFLAG_RW, 0, - "RAID1E parameters"); +SYSCTL_DECL(_kern_geom_raid_raid1e); #define RAID1E_REBUILD_SLAB (1 << 20) /* One transation in a rebuild */ static int g_raid1e_rebuild_slab = RAID1E_REBUILD_SLAB; @@ -135,6 +133,7 @@ static struct g_raid_tr_class g_raid_tr_ "RAID1E", g_raid_tr_raid1e_methods, sizeof(struct g_raid_tr_raid1e_object), + .trc_enable = 1, .trc_priority = 200 }; @@ -1236,4 +1235,4 @@ g_raid_tr_free_raid1e(struct g_raid_tr_o return (0); } -G_RAID_TR_DECLARE(g_raid_tr_raid1e); +G_RAID_TR_DECLARE(raid1e, "RAID1E"); Modified: stable/9/sys/geom/raid/tr_raid5.c ============================================================================== --- stable/9/sys/geom/raid/tr_raid5.c Sun Sep 16 08:09:10 2012 (r240551) +++ stable/9/sys/geom/raid/tr_raid5.c Sun Sep 16 08:42:40 2012 (r240552) @@ -42,8 +42,6 @@ __FBSDID("$FreeBSD$"); #include "geom/raid/g_raid.h" #include "g_raid_tr_if.h" -SYSCTL_DECL(_kern_geom_raid); - static MALLOC_DEFINE(M_TR_RAID5, "tr_raid5_data", "GEOM_RAID RAID5 data"); #define TR_RAID5_NONE 0 @@ -95,6 +93,7 @@ static struct g_raid_tr_class g_raid_tr_ "RAID5", g_raid_tr_raid5_methods, sizeof(struct g_raid_tr_raid5_object), + .trc_enable = 1, .trc_priority = 100 }; @@ -419,4 +418,4 @@ g_raid_tr_free_raid5(struct g_raid_tr_ob return (0); } -G_RAID_TR_DECLARE(g_raid_tr_raid5); +G_RAID_TR_DECLARE(raid5, "RAID5"); From owner-svn-src-stable@FreeBSD.ORG Sun Sep 16 08:44:56 2012 Return-Path: Delivered-To: svn-src-stable@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 1856D106566B; Sun, 16 Sep 2012 08:44:56 +0000 (UTC) (envelope-from mav@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id DDAC98FC08; Sun, 16 Sep 2012 08:44:55 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q8G8itMQ043781; Sun, 16 Sep 2012 08:44:55 GMT (envelope-from mav@svn.freebsd.org) Received: (from mav@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q8G8itGJ043780; Sun, 16 Sep 2012 08:44:55 GMT (envelope-from mav@svn.freebsd.org) Message-Id: <201209160844.q8G8itGJ043780@svn.freebsd.org> From: Alexander Motin Date: Sun, 16 Sep 2012 08:44:55 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-8@freebsd.org X-SVN-Group: stable-8 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r240553 - stable/8/share/man/man4 X-BeenThere: svn-src-stable@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for all the -stable branches of the src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 16 Sep 2012 08:44:56 -0000 Author: mav Date: Sun Sep 16 08:44:55 2012 New Revision: 240553 URL: http://svn.freebsd.org/changeset/base/240553 Log: MFC r240465: Add global and per-module sysctls/tunables to enable/disable metadata taste. That should help to handle some cases when disk has some RAID metadata that should be ignored, especially during boot. Modified: Directory Properties: stable/8/share/man/man4/ (props changed) From owner-svn-src-stable@FreeBSD.ORG Sun Sep 16 08:58:35 2012 Return-Path: Delivered-To: svn-src-stable@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 197B81065675; Sun, 16 Sep 2012 08:58:35 +0000 (UTC) (envelope-from mav@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id EED6F8FC16; Sun, 16 Sep 2012 08:58:34 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q8G8wYk2045858; Sun, 16 Sep 2012 08:58:34 GMT (envelope-from mav@svn.freebsd.org) Received: (from mav@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q8G8wYQT045844; Sun, 16 Sep 2012 08:58:34 GMT (envelope-from mav@svn.freebsd.org) Message-Id: <201209160858.q8G8wYQT045844@svn.freebsd.org> From: Alexander Motin Date: Sun, 16 Sep 2012 08:58:34 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-8@freebsd.org X-SVN-Group: stable-8 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r240554 - stable/8/sys/geom/raid X-BeenThere: svn-src-stable@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for all the -stable branches of the src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 16 Sep 2012 08:58:35 -0000 Author: mav Date: Sun Sep 16 08:58:34 2012 New Revision: 240554 URL: http://svn.freebsd.org/changeset/base/240554 Log: MFC r240465: Add global and per-module sysctls/tunables to enable/disable metadata taste. That should help to handle some cases when disk has some RAID metadata that should be ignored, especially during boot. pR: Modified: stable/8/sys/geom/raid/g_raid.c stable/8/sys/geom/raid/g_raid.h stable/8/sys/geom/raid/md_ddf.c stable/8/sys/geom/raid/md_intel.c stable/8/sys/geom/raid/md_jmicron.c stable/8/sys/geom/raid/md_nvidia.c stable/8/sys/geom/raid/md_promise.c stable/8/sys/geom/raid/md_sii.c stable/8/sys/geom/raid/tr_concat.c stable/8/sys/geom/raid/tr_raid0.c stable/8/sys/geom/raid/tr_raid1.c stable/8/sys/geom/raid/tr_raid1e.c stable/8/sys/geom/raid/tr_raid5.c Directory Properties: stable/8/sys/ (props changed) stable/8/sys/geom/ (props changed) Modified: stable/8/sys/geom/raid/g_raid.c ============================================================================== --- stable/8/sys/geom/raid/g_raid.c Sun Sep 16 08:44:55 2012 (r240553) +++ stable/8/sys/geom/raid/g_raid.c Sun Sep 16 08:58:34 2012 (r240554) @@ -51,6 +51,10 @@ static MALLOC_DEFINE(M_RAID, "raid_data" SYSCTL_DECL(_kern_geom); SYSCTL_NODE(_kern_geom, OID_AUTO, raid, CTLFLAG_RW, 0, "GEOM_RAID stuff"); +int g_raid_enable = 1; +TUNABLE_INT("kern.geom.raid.enable", &g_raid_enable); +SYSCTL_INT(_kern_geom_raid, OID_AUTO, enable, CTLFLAG_RW, + &g_raid_enable, 0, "Enable on-disk metadata taste"); u_int g_raid_aggressive_spare = 0; TUNABLE_INT("kern.geom.raid.aggressive_spare", &g_raid_aggressive_spare); SYSCTL_UINT(_kern_geom_raid, OID_AUTO, aggressive_spare, CTLFLAG_RW, @@ -1919,6 +1923,8 @@ int g_raid_start_volume(struct g_raid_vo G_RAID_DEBUG1(2, vol->v_softc, "Starting volume %s.", vol->v_name); LIST_FOREACH(class, &g_raid_tr_classes, trc_list) { + if (!class->trc_enable) + continue; G_RAID_DEBUG1(2, vol->v_softc, "Tasting volume %s for %s transformation.", vol->v_name, class->name); @@ -2141,6 +2147,8 @@ g_raid_taste(struct g_class *mp, struct g_topology_assert(); g_trace(G_T_TOPOLOGY, "%s(%s, %s)", __func__, mp->name, pp->name); + if (!g_raid_enable) + return (NULL); G_RAID_DEBUG(2, "Tasting provider %s.", pp->name); gp = g_new_geomf(mp, "raid:taste"); @@ -2153,6 +2161,8 @@ g_raid_taste(struct g_class *mp, struct geom = NULL; LIST_FOREACH(class, &g_raid_md_classes, mdc_list) { + if (!class->mdc_enable) + continue; G_RAID_DEBUG(2, "Tasting provider %s for %s metadata.", pp->name, class->name); obj = (void *)kobj_create((kobj_class_t)class, M_RAID, Modified: stable/8/sys/geom/raid/g_raid.h ============================================================================== --- stable/8/sys/geom/raid/g_raid.h Sun Sep 16 08:44:55 2012 (r240553) +++ stable/8/sys/geom/raid/g_raid.h Sun Sep 16 08:58:34 2012 (r240554) @@ -33,6 +33,9 @@ #include #include #include +#ifdef _KERNEL +#include +#endif #define G_RAID_CLASS_NAME "RAID" @@ -51,6 +54,7 @@ struct g_raid_tr_object; #ifdef _KERNEL extern u_int g_raid_aggressive_spare; extern u_int g_raid_debug; +extern int g_raid_enable; extern int g_raid_read_err_thresh; extern u_int g_raid_start_timeout; extern struct g_class g_raid_class; @@ -322,11 +326,14 @@ struct g_raid_softc { }; #define sc_name sc_geom->name +SYSCTL_DECL(_kern_geom_raid); + /* * KOBJ parent class of metadata processing modules. */ struct g_raid_md_class { KOBJ_CLASS_FIELDS; + int mdc_enable; int mdc_priority; LIST_ENTRY(g_raid_md_class) mdc_list; }; @@ -342,20 +349,29 @@ struct g_raid_md_object { int g_raid_md_modevent(module_t, int, void *); -#define G_RAID_MD_DECLARE(name) \ - static moduledata_t name##_mod = { \ - #name, \ +#define G_RAID_MD_DECLARE(name, label) \ + static moduledata_t g_raid_md_##name##_mod = { \ + "g_raid_md_" __XSTRING(name), \ g_raid_md_modevent, \ - &name##_class \ + &g_raid_md_##name##_class \ }; \ - DECLARE_MODULE(name, name##_mod, SI_SUB_DRIVERS, SI_ORDER_SECOND); \ - MODULE_DEPEND(name, geom_raid, 0, 0, 0) + DECLARE_MODULE(g_raid_md_##name, g_raid_md_##name##_mod, \ + SI_SUB_DRIVERS, SI_ORDER_SECOND); \ + MODULE_DEPEND(g_raid_md_##name, geom_raid, 0, 0, 0); \ + SYSCTL_NODE(_kern_geom_raid, OID_AUTO, name, CTLFLAG_RD, \ + NULL, label " metadata module"); \ + SYSCTL_INT(_kern_geom_raid_##name, OID_AUTO, enable, \ + CTLFLAG_RW, &g_raid_md_##name##_class.mdc_enable, 0, \ + "Enable " label " metadata format taste"); \ + TUNABLE_INT("kern.geom.raid." __XSTRING(name) ".enable", \ + &g_raid_md_##name##_class.mdc_enable) /* * KOBJ parent class of data transformation modules. */ struct g_raid_tr_class { KOBJ_CLASS_FIELDS; + int trc_enable; int trc_priority; LIST_ENTRY(g_raid_tr_class) trc_list; }; @@ -371,14 +387,22 @@ struct g_raid_tr_object { int g_raid_tr_modevent(module_t, int, void *); -#define G_RAID_TR_DECLARE(name) \ - static moduledata_t name##_mod = { \ - #name, \ +#define G_RAID_TR_DECLARE(name, label) \ + static moduledata_t g_raid_tr_##name##_mod = { \ + "g_raid_tr_" __XSTRING(name), \ g_raid_tr_modevent, \ - &name##_class \ + &g_raid_tr_##name##_class \ }; \ - DECLARE_MODULE(name, name##_mod, SI_SUB_DRIVERS, SI_ORDER_FIRST); \ - MODULE_DEPEND(name, geom_raid, 0, 0, 0) + DECLARE_MODULE(g_raid_tr_##name, g_raid_tr_##name##_mod, \ + SI_SUB_DRIVERS, SI_ORDER_FIRST); \ + MODULE_DEPEND(g_raid_tr_##name, geom_raid, 0, 0, 0); \ + SYSCTL_NODE(_kern_geom_raid, OID_AUTO, name, CTLFLAG_RD, \ + NULL, label " transformation module"); \ + SYSCTL_INT(_kern_geom_raid_##name, OID_AUTO, enable, \ + CTLFLAG_RW, &g_raid_tr_##name##_class.trc_enable, 0, \ + "Enable " label " transformation module taste"); \ + TUNABLE_INT("kern.geom.raid." __XSTRING(name) ".enable", \ + &g_raid_tr_##name##_class.trc_enable) const char * g_raid_volume_level2str(int level, int qual); int g_raid_volume_str2level(const char *str, int *level, int *qual); Modified: stable/8/sys/geom/raid/md_ddf.c ============================================================================== --- stable/8/sys/geom/raid/md_ddf.c Sun Sep 16 08:44:55 2012 (r240553) +++ stable/8/sys/geom/raid/md_ddf.c Sun Sep 16 08:58:34 2012 (r240554) @@ -125,6 +125,7 @@ static struct g_raid_md_class g_raid_md_ "DDF", g_raid_md_ddf_methods, sizeof(struct g_raid_md_ddf_object), + .mdc_enable = 1, .mdc_priority = 100 }; @@ -3065,4 +3066,4 @@ g_raid_md_free_ddf(struct g_raid_md_obje return (0); } -G_RAID_MD_DECLARE(g_raid_md_ddf); +G_RAID_MD_DECLARE(ddf, "DDF"); Modified: stable/8/sys/geom/raid/md_intel.c ============================================================================== --- stable/8/sys/geom/raid/md_intel.c Sun Sep 16 08:44:55 2012 (r240553) +++ stable/8/sys/geom/raid/md_intel.c Sun Sep 16 08:58:34 2012 (r240554) @@ -224,6 +224,7 @@ static struct g_raid_md_class g_raid_md_ "Intel", g_raid_md_intel_methods, sizeof(struct g_raid_md_intel_object), + .mdc_enable = 1, .mdc_priority = 100 }; @@ -2432,4 +2433,4 @@ g_raid_md_free_intel(struct g_raid_md_ob return (0); } -G_RAID_MD_DECLARE(g_raid_md_intel); +G_RAID_MD_DECLARE(intel, "Intel"); Modified: stable/8/sys/geom/raid/md_jmicron.c ============================================================================== --- stable/8/sys/geom/raid/md_jmicron.c Sun Sep 16 08:44:55 2012 (r240553) +++ stable/8/sys/geom/raid/md_jmicron.c Sun Sep 16 08:58:34 2012 (r240554) @@ -132,6 +132,7 @@ static struct g_raid_md_class g_raid_md_ "JMicron", g_raid_md_jmicron_methods, sizeof(struct g_raid_md_jmicron_object), + .mdc_enable = 1, .mdc_priority = 100 }; @@ -1581,4 +1582,4 @@ g_raid_md_free_jmicron(struct g_raid_md_ return (0); } -G_RAID_MD_DECLARE(g_raid_md_jmicron); +G_RAID_MD_DECLARE(jmicron, "JMicron"); Modified: stable/8/sys/geom/raid/md_nvidia.c ============================================================================== --- stable/8/sys/geom/raid/md_nvidia.c Sun Sep 16 08:44:55 2012 (r240553) +++ stable/8/sys/geom/raid/md_nvidia.c Sun Sep 16 08:58:34 2012 (r240554) @@ -143,6 +143,7 @@ static struct g_raid_md_class g_raid_md_ "NVIDIA", g_raid_md_nvidia_methods, sizeof(struct g_raid_md_nvidia_object), + .mdc_enable = 1, .mdc_priority = 100 }; @@ -1600,4 +1601,4 @@ g_raid_md_free_nvidia(struct g_raid_md_o return (0); } -G_RAID_MD_DECLARE(g_raid_md_nvidia); +G_RAID_MD_DECLARE(nvidia, "NVIDIA"); Modified: stable/8/sys/geom/raid/md_promise.c ============================================================================== --- stable/8/sys/geom/raid/md_promise.c Sun Sep 16 08:44:55 2012 (r240553) +++ stable/8/sys/geom/raid/md_promise.c Sun Sep 16 08:58:34 2012 (r240554) @@ -171,6 +171,7 @@ static struct g_raid_md_class g_raid_md_ "Promise", g_raid_md_promise_methods, sizeof(struct g_raid_md_object), + .mdc_enable = 1, .mdc_priority = 100 }; @@ -1967,4 +1968,4 @@ g_raid_md_free_promise(struct g_raid_md_ return (0); } -G_RAID_MD_DECLARE(g_raid_md_promise); +G_RAID_MD_DECLARE(promise, "Promise"); Modified: stable/8/sys/geom/raid/md_sii.c ============================================================================== --- stable/8/sys/geom/raid/md_sii.c Sun Sep 16 08:44:55 2012 (r240553) +++ stable/8/sys/geom/raid/md_sii.c Sun Sep 16 08:58:34 2012 (r240554) @@ -140,6 +140,7 @@ static struct g_raid_md_class g_raid_md_ "SiI", g_raid_md_sii_methods, sizeof(struct g_raid_md_sii_object), + .mdc_enable = 1, .mdc_priority = 100 }; @@ -1688,4 +1689,4 @@ g_raid_md_free_sii(struct g_raid_md_obje return (0); } -G_RAID_MD_DECLARE(g_raid_md_sii); +G_RAID_MD_DECLARE(sii, "SiI"); Modified: stable/8/sys/geom/raid/tr_concat.c ============================================================================== --- stable/8/sys/geom/raid/tr_concat.c Sun Sep 16 08:44:55 2012 (r240553) +++ stable/8/sys/geom/raid/tr_concat.c Sun Sep 16 08:58:34 2012 (r240554) @@ -73,6 +73,7 @@ static struct g_raid_tr_class g_raid_tr_ "CONCAT", g_raid_tr_concat_methods, sizeof(struct g_raid_tr_concat_object), + .trc_enable = 1, .trc_priority = 50 }; @@ -340,4 +341,4 @@ g_raid_tr_free_concat(struct g_raid_tr_o return (0); } -G_RAID_TR_DECLARE(g_raid_tr_concat); +G_RAID_TR_DECLARE(concat, "CONCAT"); Modified: stable/8/sys/geom/raid/tr_raid0.c ============================================================================== --- stable/8/sys/geom/raid/tr_raid0.c Sun Sep 16 08:44:55 2012 (r240553) +++ stable/8/sys/geom/raid/tr_raid0.c Sun Sep 16 08:58:34 2012 (r240554) @@ -73,6 +73,7 @@ static struct g_raid_tr_class g_raid_tr_ "RAID0", g_raid_tr_raid0_methods, sizeof(struct g_raid_tr_raid0_object), + .trc_enable = 1, .trc_priority = 100 }; @@ -323,4 +324,4 @@ g_raid_tr_free_raid0(struct g_raid_tr_ob return (0); } -G_RAID_TR_DECLARE(g_raid_tr_raid0); +G_RAID_TR_DECLARE(raid0, "RAID0"); Modified: stable/8/sys/geom/raid/tr_raid1.c ============================================================================== --- stable/8/sys/geom/raid/tr_raid1.c Sun Sep 16 08:44:55 2012 (r240553) +++ stable/8/sys/geom/raid/tr_raid1.c Sun Sep 16 08:58:34 2012 (r240554) @@ -42,9 +42,7 @@ __FBSDID("$FreeBSD$"); #include "geom/raid/g_raid.h" #include "g_raid_tr_if.h" -SYSCTL_DECL(_kern_geom_raid); -SYSCTL_NODE(_kern_geom_raid, OID_AUTO, raid1, CTLFLAG_RW, 0, - "RAID1 parameters"); +SYSCTL_DECL(_kern_geom_raid_raid1); #define RAID1_REBUILD_SLAB (1 << 20) /* One transation in a rebuild */ static int g_raid1_rebuild_slab = RAID1_REBUILD_SLAB; @@ -131,6 +129,7 @@ static struct g_raid_tr_class g_raid_tr_ "RAID1", g_raid_tr_raid1_methods, sizeof(struct g_raid_tr_raid1_object), + .trc_enable = 1, .trc_priority = 100 }; @@ -996,4 +995,4 @@ g_raid_tr_free_raid1(struct g_raid_tr_ob return (0); } -G_RAID_TR_DECLARE(g_raid_tr_raid1); +G_RAID_TR_DECLARE(raid1, "RAID1"); Modified: stable/8/sys/geom/raid/tr_raid1e.c ============================================================================== --- stable/8/sys/geom/raid/tr_raid1e.c Sun Sep 16 08:44:55 2012 (r240553) +++ stable/8/sys/geom/raid/tr_raid1e.c Sun Sep 16 08:58:34 2012 (r240554) @@ -44,9 +44,7 @@ __FBSDID("$FreeBSD$"); #define N 2 -SYSCTL_DECL(_kern_geom_raid); -SYSCTL_NODE(_kern_geom_raid, OID_AUTO, raid1e, CTLFLAG_RW, 0, - "RAID1E parameters"); +SYSCTL_DECL(_kern_geom_raid_raid1e); #define RAID1E_REBUILD_SLAB (1 << 20) /* One transation in a rebuild */ static int g_raid1e_rebuild_slab = RAID1E_REBUILD_SLAB; @@ -135,6 +133,7 @@ static struct g_raid_tr_class g_raid_tr_ "RAID1E", g_raid_tr_raid1e_methods, sizeof(struct g_raid_tr_raid1e_object), + .trc_enable = 1, .trc_priority = 200 }; @@ -1236,4 +1235,4 @@ g_raid_tr_free_raid1e(struct g_raid_tr_o return (0); } -G_RAID_TR_DECLARE(g_raid_tr_raid1e); +G_RAID_TR_DECLARE(raid1e, "RAID1E"); Modified: stable/8/sys/geom/raid/tr_raid5.c ============================================================================== --- stable/8/sys/geom/raid/tr_raid5.c Sun Sep 16 08:44:55 2012 (r240553) +++ stable/8/sys/geom/raid/tr_raid5.c Sun Sep 16 08:58:34 2012 (r240554) @@ -42,8 +42,6 @@ __FBSDID("$FreeBSD$"); #include "geom/raid/g_raid.h" #include "g_raid_tr_if.h" -SYSCTL_DECL(_kern_geom_raid); - static MALLOC_DEFINE(M_TR_RAID5, "tr_raid5_data", "GEOM_RAID RAID5 data"); #define TR_RAID5_NONE 0 @@ -95,6 +93,7 @@ static struct g_raid_tr_class g_raid_tr_ "RAID5", g_raid_tr_raid5_methods, sizeof(struct g_raid_tr_raid5_object), + .trc_enable = 1, .trc_priority = 100 }; @@ -419,4 +418,4 @@ g_raid_tr_free_raid5(struct g_raid_tr_ob return (0); } -G_RAID_TR_DECLARE(g_raid_tr_raid5); +G_RAID_TR_DECLARE(raid5, "RAID5"); From owner-svn-src-stable@FreeBSD.ORG Sun Sep 16 09:00:54 2012 Return-Path: Delivered-To: svn-src-stable@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 45341106566C; Sun, 16 Sep 2012 09:00:54 +0000 (UTC) (envelope-from mav@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 2FBEF8FC24; Sun, 16 Sep 2012 09:00:54 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q8G90sCr046274; Sun, 16 Sep 2012 09:00:54 GMT (envelope-from mav@svn.freebsd.org) Received: (from mav@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q8G90rfs046272; Sun, 16 Sep 2012 09:00:53 GMT (envelope-from mav@svn.freebsd.org) Message-Id: <201209160900.q8G90rfs046272@svn.freebsd.org> From: Alexander Motin Date: Sun, 16 Sep 2012 09:00:53 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r240555 - stable/9/sbin/geom/class/raid X-BeenThere: svn-src-stable@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for all the -stable branches of the src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 16 Sep 2012 09:00:54 -0000 Author: mav Date: Sun Sep 16 09:00:53 2012 New Revision: 240555 URL: http://svn.freebsd.org/changeset/base/240555 Log: MFC r240465: Add global and per-module sysctls/tunables to enable/disable metadata taste. That should help to handle some cases when disk has some RAID metadata that should be ignored, especially during boot. Modified: stable/9/sbin/geom/class/raid/graid.8 Directory Properties: stable/9/sbin/geom/class/raid/ (props changed) Modified: stable/9/sbin/geom/class/raid/graid.8 ============================================================================== --- stable/9/sbin/geom/class/raid/graid.8 Sun Sep 16 08:58:34 2012 (r240554) +++ stable/9/sbin/geom/class/raid/graid.8 Sun Sep 16 09:00:53 2012 (r240555) @@ -24,7 +24,7 @@ .\" .\" $FreeBSD$ .\" -.Dd May 6, 2012 +.Dd September 13, 2012 .Dt GRAID 8 .Os .Sh NAME @@ -293,6 +293,8 @@ Mark volume as clean when idle for the s Debug level of the .Nm RAID GEOM class. +.It Va kern.geom.raid.enable : No 1 +Enable on-disk metadata taste. .It Va kern.geom.raid.idle_threshold : No 1000000 Time in microseconds to consider a volume idle for rebuild purposes. .It Va kern.geom.raid.name_format : No 0 @@ -302,6 +304,8 @@ Number of read errors equated to disk fa Write errors are always considered as disk failures. .It Va kern.geom.raid.start_timeout : No 30 Time to wait for missing array components on startup. +.It Va kern.geom.raid. Ns Ar X Ns Va .enable : No 1 +Enable taste for specific metadata or transformation module. .El .Sh EXIT STATUS Exit status is 0 on success, and non-zero if the command fails. From owner-svn-src-stable@FreeBSD.ORG Sun Sep 16 09:01:40 2012 Return-Path: Delivered-To: svn-src-stable@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 8F5C51065705; Sun, 16 Sep 2012 09:01:40 +0000 (UTC) (envelope-from mav@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 7A2158FC08; Sun, 16 Sep 2012 09:01:40 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q8G91eIq046421; Sun, 16 Sep 2012 09:01:40 GMT (envelope-from mav@svn.freebsd.org) Received: (from mav@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q8G91ekr046419; Sun, 16 Sep 2012 09:01:40 GMT (envelope-from mav@svn.freebsd.org) Message-Id: <201209160901.q8G91ekr046419@svn.freebsd.org> From: Alexander Motin Date: Sun, 16 Sep 2012 09:01:40 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-8@freebsd.org X-SVN-Group: stable-8 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r240556 - stable/8/sbin/geom/class/raid X-BeenThere: svn-src-stable@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for all the -stable branches of the src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 16 Sep 2012 09:01:40 -0000 Author: mav Date: Sun Sep 16 09:01:40 2012 New Revision: 240556 URL: http://svn.freebsd.org/changeset/base/240556 Log: MFC r240465: Add global and per-module sysctls/tunables to enable/disable metadata taste. That should help to handle some cases when disk has some RAID metadata that should be ignored, especially during boot. Modified: stable/8/sbin/geom/class/raid/graid.8 Directory Properties: stable/8/sbin/geom/class/raid/ (props changed) Modified: stable/8/sbin/geom/class/raid/graid.8 ============================================================================== --- stable/8/sbin/geom/class/raid/graid.8 Sun Sep 16 09:00:53 2012 (r240555) +++ stable/8/sbin/geom/class/raid/graid.8 Sun Sep 16 09:01:40 2012 (r240556) @@ -24,7 +24,7 @@ .\" .\" $FreeBSD$ .\" -.Dd May 6, 2012 +.Dd September 13, 2012 .Dt GRAID 8 .Os .Sh NAME @@ -293,6 +293,8 @@ Mark volume as clean when idle for the s Debug level of the .Nm RAID GEOM class. +.It Va kern.geom.raid.enable : No 1 +Enable on-disk metadata taste. .It Va kern.geom.raid.idle_threshold : No 1000000 Time in microseconds to consider a volume idle for rebuild purposes. .It Va kern.geom.raid.name_format : No 0 @@ -302,6 +304,8 @@ Number of read errors equated to disk fa Write errors are always considered as disk failures. .It Va kern.geom.raid.start_timeout : No 30 Time to wait for missing array components on startup. +.It Va kern.geom.raid. Ns Ar X Ns Va .enable : No 1 +Enable taste for specific metadata or transformation module. .El .Sh EXIT STATUS Exit status is 0 on success, and non-zero if the command fails. From owner-svn-src-stable@FreeBSD.ORG Sun Sep 16 10:40:17 2012 Return-Path: Delivered-To: svn-src-stable@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id D17B4106566B; Sun, 16 Sep 2012 10:40:17 +0000 (UTC) (envelope-from issyl0@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id BB42D8FC0C; Sun, 16 Sep 2012 10:40:17 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q8GAeHKd063007; Sun, 16 Sep 2012 10:40:17 GMT (envelope-from issyl0@svn.freebsd.org) Received: (from issyl0@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q8GAeHUV063005; Sun, 16 Sep 2012 10:40:17 GMT (envelope-from issyl0@svn.freebsd.org) Message-Id: <201209161040.q8GAeHUV063005@svn.freebsd.org> From: Isabell Long Date: Sun, 16 Sep 2012 10:40:17 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r240557 - stable/9/share/man/man4 X-BeenThere: svn-src-stable@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for all the -stable branches of the src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 16 Sep 2012 10:40:17 -0000 Author: issyl0 (doc committer) Date: Sun Sep 16 10:40:17 2012 New Revision: 240557 URL: http://svn.freebsd.org/changeset/base/240557 Log: MFC r239840 from HEAD: - Fix a dead link in sk(4). PR: docs/146958 Approved by: gabor (mentor) Modified: stable/9/share/man/man4/sk.4 Directory Properties: stable/9/share/man/man4/ (props changed) Modified: stable/9/share/man/man4/sk.4 ============================================================================== --- stable/9/share/man/man4/sk.4 Sun Sep 16 09:01:40 2012 (r240556) +++ stable/9/share/man/man4/sk.4 Sun Sep 16 10:40:17 2012 (r240557) @@ -30,7 +30,7 @@ .\" .\" $FreeBSD$ .\" -.Dd November 23, 2010 +.Dd August 29, 2012 .Dt SK 4 .Os .Sh NAME @@ -223,7 +223,7 @@ the network connection (cable). .Xr ifconfig 8 .Rs .%T XaQti XMAC II datasheet -.%U http://www.xaqti.com +.%U http://people.freebsd.org/~wpaul/SysKonnect/xmacii_datasheet_rev_c_9-29.pdf .Re .Rs .%T SysKonnect GEnesis programming manual From owner-svn-src-stable@FreeBSD.ORG Sun Sep 16 12:06:46 2012 Return-Path: Delivered-To: svn-src-stable@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 2A422106566B; Sun, 16 Sep 2012 12:06:46 +0000 (UTC) (envelope-from mav@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 147D98FC08; Sun, 16 Sep 2012 12:06:46 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q8GC6jcF079798; Sun, 16 Sep 2012 12:06:45 GMT (envelope-from mav@svn.freebsd.org) Received: (from mav@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q8GC6jYN079796; Sun, 16 Sep 2012 12:06:45 GMT (envelope-from mav@svn.freebsd.org) Message-Id: <201209161206.q8GC6jYN079796@svn.freebsd.org> From: Alexander Motin Date: Sun, 16 Sep 2012 12:06:45 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r240559 - stable/9/sys/dev/sound/pci/hda X-BeenThere: svn-src-stable@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for all the -stable branches of the src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 16 Sep 2012 12:06:46 -0000 Author: mav Date: Sun Sep 16 12:06:45 2012 New Revision: 240559 URL: http://svn.freebsd.org/changeset/base/240559 Log: MFC r239326: Fix "speaker" volume control, broken at r230451. Modified: stable/9/sys/dev/sound/pci/hda/hdaa.c Directory Properties: stable/9/sys/ (props changed) stable/9/sys/dev/ (props changed) Modified: stable/9/sys/dev/sound/pci/hda/hdaa.c ============================================================================== --- stable/9/sys/dev/sound/pci/hda/hdaa.c Sun Sep 16 11:02:22 2012 (r240558) +++ stable/9/sys/dev/sound/pci/hda/hdaa.c Sun Sep 16 12:06:45 2012 (r240559) @@ -2127,11 +2127,14 @@ hdaa_audio_ctl_dev_volume(struct hdaa_pc w = hdaa_widget_get(devinfo, i); if (w == NULL || w->enable == 0) continue; - if (w->bindas < 0 && pdevinfo->index != 0) - continue; - if (w->bindas != pdevinfo->playas && - w->bindas != pdevinfo->recas) - continue; + if (w->bindas < 0) { + if (pdevinfo->index != 0) + continue; + } else { + if (w->bindas != pdevinfo->playas && + w->bindas != pdevinfo->recas) + continue; + } if (dev == SOUND_MIXER_RECLEV && w->type == HDA_PARAM_AUDIO_WIDGET_CAP_TYPE_AUDIO_INPUT) { hdaa_audio_ctl_dest_volume(pdevinfo, dev, From owner-svn-src-stable@FreeBSD.ORG Sun Sep 16 12:08:06 2012 Return-Path: Delivered-To: svn-src-stable@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 85F90106566C; Sun, 16 Sep 2012 12:08:06 +0000 (UTC) (envelope-from mav@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 70F008FC08; Sun, 16 Sep 2012 12:08:06 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q8GC86ul080091; Sun, 16 Sep 2012 12:08:06 GMT (envelope-from mav@svn.freebsd.org) Received: (from mav@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q8GC86JH080089; Sun, 16 Sep 2012 12:08:06 GMT (envelope-from mav@svn.freebsd.org) Message-Id: <201209161208.q8GC86JH080089@svn.freebsd.org> From: Alexander Motin Date: Sun, 16 Sep 2012 12:08:06 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-8@freebsd.org X-SVN-Group: stable-8 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r240560 - stable/8/sys/dev/sound/pci/hda X-BeenThere: svn-src-stable@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for all the -stable branches of the src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 16 Sep 2012 12:08:06 -0000 Author: mav Date: Sun Sep 16 12:08:06 2012 New Revision: 240560 URL: http://svn.freebsd.org/changeset/base/240560 Log: MFC r239326: Fix "speaker" volume control, broken at r230451. Modified: stable/8/sys/dev/sound/pci/hda/hdaa.c Directory Properties: stable/8/sys/ (props changed) stable/8/sys/dev/ (props changed) stable/8/sys/dev/sound/ (props changed) stable/8/sys/dev/sound/pci/ (props changed) Modified: stable/8/sys/dev/sound/pci/hda/hdaa.c ============================================================================== --- stable/8/sys/dev/sound/pci/hda/hdaa.c Sun Sep 16 12:06:45 2012 (r240559) +++ stable/8/sys/dev/sound/pci/hda/hdaa.c Sun Sep 16 12:08:06 2012 (r240560) @@ -2127,11 +2127,14 @@ hdaa_audio_ctl_dev_volume(struct hdaa_pc w = hdaa_widget_get(devinfo, i); if (w == NULL || w->enable == 0) continue; - if (w->bindas < 0 && pdevinfo->index != 0) - continue; - if (w->bindas != pdevinfo->playas && - w->bindas != pdevinfo->recas) - continue; + if (w->bindas < 0) { + if (pdevinfo->index != 0) + continue; + } else { + if (w->bindas != pdevinfo->playas && + w->bindas != pdevinfo->recas) + continue; + } if (dev == SOUND_MIXER_RECLEV && w->type == HDA_PARAM_AUDIO_WIDGET_CAP_TYPE_AUDIO_INPUT) { hdaa_audio_ctl_dest_volume(pdevinfo, dev, From owner-svn-src-stable@FreeBSD.ORG Sun Sep 16 18:17:39 2012 Return-Path: Delivered-To: svn-src-stable@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id E4C0A106566B; Sun, 16 Sep 2012 18:17:39 +0000 (UTC) (envelope-from gavin@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id CF15F8FC1F; Sun, 16 Sep 2012 18:17:39 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q8GIHduo049252; Sun, 16 Sep 2012 18:17:39 GMT (envelope-from gavin@svn.freebsd.org) Received: (from gavin@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q8GIHdAS049249; Sun, 16 Sep 2012 18:17:39 GMT (envelope-from gavin@svn.freebsd.org) Message-Id: <201209161817.q8GIHdAS049249@svn.freebsd.org> From: Gavin Atkinson Date: Sun, 16 Sep 2012 18:17:39 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r240567 - in stable/9/sys/dev/usb: . serial X-BeenThere: svn-src-stable@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for all the -stable branches of the src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 16 Sep 2012 18:17:40 -0000 Author: gavin Date: Sun Sep 16 18:17:39 2012 New Revision: 240567 URL: http://svn.freebsd.org/changeset/base/240567 Log: Merge r240118 from head: Support another uchcom(4) device. Modified: stable/9/sys/dev/usb/serial/uchcom.c stable/9/sys/dev/usb/usbdevs Directory Properties: stable/9/sys/ (props changed) stable/9/sys/dev/ (props changed) Modified: stable/9/sys/dev/usb/serial/uchcom.c ============================================================================== --- stable/9/sys/dev/usb/serial/uchcom.c Sun Sep 16 16:58:49 2012 (r240566) +++ stable/9/sys/dev/usb/serial/uchcom.c Sun Sep 16 18:17:39 2012 (r240567) @@ -207,6 +207,7 @@ static const struct uchcom_divider_recor static const STRUCT_USB_HOST_ID uchcom_devs[] = { {USB_VPI(USB_VENDOR_WCH, USB_PRODUCT_WCH_CH341SER, 0)}, {USB_VPI(USB_VENDOR_WCH2, USB_PRODUCT_WCH2_CH341SER, 0)}, + {USB_VPI(USB_VENDOR_WCH2, USB_PRODUCT_WCH2_CH341SER_2, 0)}, }; /* protypes */ Modified: stable/9/sys/dev/usb/usbdevs ============================================================================== --- stable/9/sys/dev/usb/usbdevs Sun Sep 16 16:58:49 2012 (r240566) +++ stable/9/sys/dev/usb/usbdevs Sun Sep 16 18:17:39 2012 (r240567) @@ -3456,6 +3456,7 @@ product WAVESENSE JAZZ 0xaaaa Jazz bloo /* WCH products */ product WCH CH341SER 0x5523 CH341/CH340 USB-Serial Bridge +product WCH2 CH341SER_2 0x5523 CH341/CH340 USB-Serial Bridge product WCH2 CH341SER 0x7523 CH341/CH340 USB-Serial Bridge /* Western Digital products */ From owner-svn-src-stable@FreeBSD.ORG Sun Sep 16 18:25:08 2012 Return-Path: Delivered-To: svn-src-stable@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id A07711065670; Sun, 16 Sep 2012 18:25:08 +0000 (UTC) (envelope-from gavin@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 8AF598FC12; Sun, 16 Sep 2012 18:25:08 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q8GIP8r8050631; Sun, 16 Sep 2012 18:25:08 GMT (envelope-from gavin@svn.freebsd.org) Received: (from gavin@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q8GIP8TN050629; Sun, 16 Sep 2012 18:25:08 GMT (envelope-from gavin@svn.freebsd.org) Message-Id: <201209161825.q8GIP8TN050629@svn.freebsd.org> From: Gavin Atkinson Date: Sun, 16 Sep 2012 18:25:08 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r240568 - stable/9/usr.sbin/pciconf X-BeenThere: svn-src-stable@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for all the -stable branches of the src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 16 Sep 2012 18:25:08 -0000 Author: gavin Date: Sun Sep 16 18:25:08 2012 New Revision: 240568 URL: http://svn.freebsd.org/changeset/base/240568 Log: Merge r240146 from head: - If the PCIe "SLOT" flag is set, include this in the capability output - Fix printing of PCIe interrupt number, the shift was incorrect. Modified: stable/9/usr.sbin/pciconf/cap.c Directory Properties: stable/9/usr.sbin/pciconf/ (props changed) Modified: stable/9/usr.sbin/pciconf/cap.c ============================================================================== --- stable/9/usr.sbin/pciconf/cap.c Sun Sep 16 18:17:39 2012 (r240567) +++ stable/9/usr.sbin/pciconf/cap.c Sun Sep 16 18:25:08 2012 (r240568) @@ -403,8 +403,10 @@ cap_express(int fd, struct pci_conf *p, printf("type %d", (flags & PCIM_EXP_FLAGS_TYPE) >> 4); break; } + if (flags & PCIM_EXP_FLAGS_SLOT) + printf(" slot"); if (flags & PCIM_EXP_FLAGS_IRQ) - printf(" IRQ %d", (flags & PCIM_EXP_FLAGS_IRQ) >> 8); + printf(" IRQ %d", (flags & PCIM_EXP_FLAGS_IRQ) >> 9); val = read_config(fd, &p->pc_sel, ptr + PCIR_EXPRESS_DEVICE_CAP, 4); flags = read_config(fd, &p->pc_sel, ptr + PCIR_EXPRESS_DEVICE_CTL, 2); printf(" max data %d(%d)", From owner-svn-src-stable@FreeBSD.ORG Sun Sep 16 18:26:33 2012 Return-Path: Delivered-To: svn-src-stable@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 6B2C8106566B; Sun, 16 Sep 2012 18:26:33 +0000 (UTC) (envelope-from gavin@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 54ED08FC0A; Sun, 16 Sep 2012 18:26:33 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q8GIQXWe050949; Sun, 16 Sep 2012 18:26:33 GMT (envelope-from gavin@svn.freebsd.org) Received: (from gavin@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q8GIQXNT050947; Sun, 16 Sep 2012 18:26:33 GMT (envelope-from gavin@svn.freebsd.org) Message-Id: <201209161826.q8GIQXNT050947@svn.freebsd.org> From: Gavin Atkinson Date: Sun, 16 Sep 2012 18:26:33 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-8@freebsd.org X-SVN-Group: stable-8 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r240569 - stable/8/usr.sbin/pciconf X-BeenThere: svn-src-stable@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for all the -stable branches of the src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 16 Sep 2012 18:26:33 -0000 Author: gavin Date: Sun Sep 16 18:26:32 2012 New Revision: 240569 URL: http://svn.freebsd.org/changeset/base/240569 Log: Merge r240146 from head: - If the PCIe "SLOT" flag is set, include this in the capability output - Fix printing of PCIe interrupt number, the shift was incorrect. Modified: stable/8/usr.sbin/pciconf/cap.c Directory Properties: stable/8/usr.sbin/pciconf/ (props changed) Modified: stable/8/usr.sbin/pciconf/cap.c ============================================================================== --- stable/8/usr.sbin/pciconf/cap.c Sun Sep 16 18:25:08 2012 (r240568) +++ stable/8/usr.sbin/pciconf/cap.c Sun Sep 16 18:26:32 2012 (r240569) @@ -403,8 +403,10 @@ cap_express(int fd, struct pci_conf *p, printf("type %d", (flags & PCIM_EXP_FLAGS_TYPE) >> 4); break; } + if (flags & PCIM_EXP_FLAGS_SLOT) + printf(" slot"); if (flags & PCIM_EXP_FLAGS_IRQ) - printf(" IRQ %d", (flags & PCIM_EXP_FLAGS_IRQ) >> 8); + printf(" IRQ %d", (flags & PCIM_EXP_FLAGS_IRQ) >> 9); val = read_config(fd, &p->pc_sel, ptr + PCIR_EXPRESS_DEVICE_CAP, 4); flags = read_config(fd, &p->pc_sel, ptr + PCIR_EXPRESS_DEVICE_CTL, 2); printf(" max data %d(%d)", From owner-svn-src-stable@FreeBSD.ORG Sun Sep 16 18:57:32 2012 Return-Path: Delivered-To: svn-src-stable@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id C077D1065670; Sun, 16 Sep 2012 18:57:32 +0000 (UTC) (envelope-from gavin@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id AB3D48FC1C; Sun, 16 Sep 2012 18:57:32 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q8GIvWel056637; Sun, 16 Sep 2012 18:57:32 GMT (envelope-from gavin@svn.freebsd.org) Received: (from gavin@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q8GIvWRU056634; Sun, 16 Sep 2012 18:57:32 GMT (envelope-from gavin@svn.freebsd.org) Message-Id: <201209161857.q8GIvWRU056634@svn.freebsd.org> From: Gavin Atkinson Date: Sun, 16 Sep 2012 18:57:32 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-8@freebsd.org X-SVN-Group: stable-8 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r240570 - in stable/8/sys/dev/usb: . serial X-BeenThere: svn-src-stable@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for all the -stable branches of the src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 16 Sep 2012 18:57:32 -0000 Author: gavin Date: Sun Sep 16 18:57:32 2012 New Revision: 240570 URL: http://svn.freebsd.org/changeset/base/240570 Log: Merge r240118 from head: Support another uchcom(4) device. Modified: stable/8/sys/dev/usb/serial/uchcom.c stable/8/sys/dev/usb/usbdevs Directory Properties: stable/8/sys/ (props changed) stable/8/sys/dev/ (props changed) stable/8/sys/dev/usb/ (props changed) Modified: stable/8/sys/dev/usb/serial/uchcom.c ============================================================================== --- stable/8/sys/dev/usb/serial/uchcom.c Sun Sep 16 18:26:32 2012 (r240569) +++ stable/8/sys/dev/usb/serial/uchcom.c Sun Sep 16 18:57:32 2012 (r240570) @@ -207,6 +207,7 @@ static const struct uchcom_divider_recor static const STRUCT_USB_HOST_ID uchcom_devs[] = { {USB_VPI(USB_VENDOR_WCH, USB_PRODUCT_WCH_CH341SER, 0)}, {USB_VPI(USB_VENDOR_WCH2, USB_PRODUCT_WCH2_CH341SER, 0)}, + {USB_VPI(USB_VENDOR_WCH2, USB_PRODUCT_WCH2_CH341SER_2, 0)}, }; /* protypes */ Modified: stable/8/sys/dev/usb/usbdevs ============================================================================== --- stable/8/sys/dev/usb/usbdevs Sun Sep 16 18:26:32 2012 (r240569) +++ stable/8/sys/dev/usb/usbdevs Sun Sep 16 18:57:32 2012 (r240570) @@ -3443,6 +3443,7 @@ product WAVESENSE JAZZ 0xaaaa Jazz bloo /* WCH products */ product WCH CH341SER 0x5523 CH341/CH340 USB-Serial Bridge +product WCH2 CH341SER_2 0x5523 CH341/CH340 USB-Serial Bridge product WCH2 CH341SER 0x7523 CH341/CH340 USB-Serial Bridge /* Western Digital products */ From owner-svn-src-stable@FreeBSD.ORG Mon Sep 17 00:32:36 2012 Return-Path: Delivered-To: svn-src-stable@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 29848106564A; Mon, 17 Sep 2012 00:32:36 +0000 (UTC) (envelope-from eadler@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 139938FC17; Mon, 17 Sep 2012 00:32:36 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q8H0WZkE014164; Mon, 17 Sep 2012 00:32:35 GMT (envelope-from eadler@svn.freebsd.org) Received: (from eadler@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q8H0WZR4014161; Mon, 17 Sep 2012 00:32:35 GMT (envelope-from eadler@svn.freebsd.org) Message-Id: <201209170032.q8H0WZR4014161@svn.freebsd.org> From: Eitan Adler Date: Mon, 17 Sep 2012 00:32:35 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-8@freebsd.org X-SVN-Group: stable-8 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r240576 - stable/8/sys/dev/isci/scil X-BeenThere: svn-src-stable@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for all the -stable branches of the src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 17 Sep 2012 00:32:36 -0000 Author: eadler Date: Mon Sep 17 00:32:35 2012 New Revision: 240576 URL: http://svn.freebsd.org/changeset/base/240576 Log: MFC r240521: s/ is is / is /g s/ a a / a /g Approved by: cperciva (implicit) Modified: stable/8/sys/dev/isci/scil/scic_sds_remote_device.h Directory Properties: stable/8/sys/ (props changed) stable/8/sys/cam/ (props changed) stable/8/sys/dev/ (props changed) stable/8/sys/dev/isci/ (props changed) stable/8/sys/dev/xen/ (props changed) stable/8/sys/libkern/ (props changed) stable/8/sys/net80211/ (props changed) Modified: stable/8/sys/dev/isci/scil/scic_sds_remote_device.h ============================================================================== --- stable/8/sys/dev/isci/scil/scic_sds_remote_device.h Sun Sep 16 23:25:13 2012 (r240575) +++ stable/8/sys/dev/isci/scil/scic_sds_remote_device.h Mon Sep 17 00:32:35 2012 (r240576) @@ -121,7 +121,7 @@ enum SCIC_SDS_STP_REMOTE_DEVICE_READY_SU { /** * This is the idle substate for the stp remote device. When there are no - * active IO for the device it is is in this state. + * active IO for the device it is in this state. */ SCIC_SDS_STP_REMOTE_DEVICE_READY_SUBSTATE_IDLE, From owner-svn-src-stable@FreeBSD.ORG Mon Sep 17 00:32:36 2012 Return-Path: Delivered-To: svn-src-stable@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 9E3E8106566B; Mon, 17 Sep 2012 00:32:36 +0000 (UTC) (envelope-from eadler@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 88B208FC19; Mon, 17 Sep 2012 00:32:36 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q8H0Watf014179; Mon, 17 Sep 2012 00:32:36 GMT (envelope-from eadler@svn.freebsd.org) Received: (from eadler@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q8H0Wa8f014177; Mon, 17 Sep 2012 00:32:36 GMT (envelope-from eadler@svn.freebsd.org) Message-Id: <201209170032.q8H0Wa8f014177@svn.freebsd.org> From: Eitan Adler Date: Mon, 17 Sep 2012 00:32:36 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r240577 - stable/9/sys/dev/isci/scil X-BeenThere: svn-src-stable@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for all the -stable branches of the src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 17 Sep 2012 00:32:36 -0000 Author: eadler Date: Mon Sep 17 00:32:36 2012 New Revision: 240577 URL: http://svn.freebsd.org/changeset/base/240577 Log: MFC r240521: s/ is is / is /g s/ a a / a /g Approved by: cperciva (implicit) Modified: stable/9/sys/dev/isci/scil/scic_sds_remote_device.h Directory Properties: stable/9/sys/ (props changed) stable/9/sys/dev/ (props changed) Modified: stable/9/sys/dev/isci/scil/scic_sds_remote_device.h ============================================================================== --- stable/9/sys/dev/isci/scil/scic_sds_remote_device.h Mon Sep 17 00:32:35 2012 (r240576) +++ stable/9/sys/dev/isci/scil/scic_sds_remote_device.h Mon Sep 17 00:32:36 2012 (r240577) @@ -121,7 +121,7 @@ enum SCIC_SDS_STP_REMOTE_DEVICE_READY_SU { /** * This is the idle substate for the stp remote device. When there are no - * active IO for the device it is is in this state. + * active IO for the device it is in this state. */ SCIC_SDS_STP_REMOTE_DEVICE_READY_SUBSTATE_IDLE, From owner-svn-src-stable@FreeBSD.ORG Mon Sep 17 00:44:12 2012 Return-Path: Delivered-To: svn-src-stable@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 70B031065670; Mon, 17 Sep 2012 00:44:12 +0000 (UTC) (envelope-from eadler@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 41E5D8FC19; Mon, 17 Sep 2012 00:44:12 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q8H0iCBw015853; Mon, 17 Sep 2012 00:44:12 GMT (envelope-from eadler@svn.freebsd.org) Received: (from eadler@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q8H0iCDJ015850; Mon, 17 Sep 2012 00:44:12 GMT (envelope-from eadler@svn.freebsd.org) Message-Id: <201209170044.q8H0iCDJ015850@svn.freebsd.org> From: Eitan Adler Date: Mon, 17 Sep 2012 00:44:12 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-8@freebsd.org X-SVN-Group: stable-8 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r240578 - in stable/8/sys: kern sparc64/sparc64 X-BeenThere: svn-src-stable@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for all the -stable branches of the src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 17 Sep 2012 00:44:12 -0000 Author: eadler Date: Mon Sep 17 00:44:11 2012 New Revision: 240578 URL: http://svn.freebsd.org/changeset/base/240578 Log: MFC r240518: Correct double "the the" Approved by: cperciva (implicit) Modified: stable/8/sys/kern/subr_unit.c stable/8/sys/sparc64/sparc64/ata_machdep.c Directory Properties: stable/8/sys/ (props changed) stable/8/sys/kern/ (props changed) stable/8/sys/sparc64/ (props changed) stable/8/sys/vm/ (props changed) stable/8/tools/kerneldoc/ (props changed) stable/8/tools/kerneldoc/subsys/ (props changed) stable/8/usr.bin/lex/ (props changed) stable/8/usr.sbin/tcpdump/ (props changed) Modified: stable/8/sys/kern/subr_unit.c ============================================================================== --- stable/8/sys/kern/subr_unit.c Mon Sep 17 00:32:36 2012 (r240577) +++ stable/8/sys/kern/subr_unit.c Mon Sep 17 00:44:11 2012 (r240578) @@ -63,7 +63,7 @@ * in the usermode test program included, the worst case usage * was 798 bytes on i386 for 5000 allocated and 5000 free units. * * The worst case is where every other unit number is allocated and - * the the rest are free. In that case 44 + N/4 bytes are used where + * the rest are free. In that case 44 + N/4 bytes are used where * N is the number of the highest unit allocated. */ Modified: stable/8/sys/sparc64/sparc64/ata_machdep.c ============================================================================== --- stable/8/sys/sparc64/sparc64/ata_machdep.c Mon Sep 17 00:32:36 2012 (r240577) +++ stable/8/sys/sparc64/sparc64/ata_machdep.c Mon Sep 17 00:44:11 2012 (r240578) @@ -40,7 +40,7 @@ sparc64_ata_disk_firmware_geom_adjust(st * and sectors so the geometry of large disks has to be adjusted. * If the disk is > 32GB at 16 heads and 63 sectors, adjust to 255 * sectors (this matches what the OpenSolaris dad(7D) driver does). - * If the the disk is even > 128GB, additionally adjust the heads to + * If the disk is even > 128GB, additionally adjust the heads to * 255. This allows disks up to the 2TB limit of the extended VTOC8. * XXX the OpenSolaris dad(7D) driver limits the mediasize to 128GB. */ From owner-svn-src-stable@FreeBSD.ORG Mon Sep 17 00:44:17 2012 Return-Path: Delivered-To: svn-src-stable@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 29489106564A; Mon, 17 Sep 2012 00:44:17 +0000 (UTC) (envelope-from eadler@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 109DA8FC12; Mon, 17 Sep 2012 00:44:17 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q8H0iHwF015918; Mon, 17 Sep 2012 00:44:17 GMT (envelope-from eadler@svn.freebsd.org) Received: (from eadler@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q8H0iGEh015896; Mon, 17 Sep 2012 00:44:16 GMT (envelope-from eadler@svn.freebsd.org) Message-Id: <201209170044.q8H0iGEh015896@svn.freebsd.org> From: Eitan Adler Date: Mon, 17 Sep 2012 00:44:16 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r240579 - in stable/9: sys/dev/buslogic sys/dev/e1000 sys/dev/isci/scil sys/dev/isp sys/dev/mps sys/kern sys/sparc64/sparc64 sys/vm usr.sbin/tcpdump/tcpdump X-BeenThere: svn-src-stable@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for all the -stable branches of the src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 17 Sep 2012 00:44:17 -0000 Author: eadler Date: Mon Sep 17 00:44:16 2012 New Revision: 240579 URL: http://svn.freebsd.org/changeset/base/240579 Log: MFC r240518: Correct double "the the" Approved by: cperciva (implicit) Modified: stable/9/sys/dev/buslogic/bt.c stable/9/sys/dev/e1000/e1000_82575.c stable/9/sys/dev/e1000/e1000_ich8lan.c stable/9/sys/dev/isci/scil/sati.c stable/9/sys/dev/isci/scil/sati_callbacks.h stable/9/sys/dev/isci/scil/sci_base_controller.h stable/9/sys/dev/isci/scil/sci_base_domain.h stable/9/sys/dev/isci/scil/sci_base_phy.h stable/9/sys/dev/isci/scil/sci_base_remote_device.h stable/9/sys/dev/isci/scil/scic_io_request.h stable/9/sys/dev/isci/scil/scic_sds_phy.c stable/9/sys/dev/isci/scil/scic_sds_port.h stable/9/sys/dev/isci/scil/scic_sds_remote_node_context.h stable/9/sys/dev/isci/scil/scic_sds_request.c stable/9/sys/dev/isci/scil/scu_bios_definitions.h stable/9/sys/dev/isp/isp_freebsd.c stable/9/sys/dev/mps/mps_sas.c stable/9/sys/kern/subr_unit.c stable/9/sys/sparc64/sparc64/ata_machdep.c stable/9/sys/vm/vm_pageout.c stable/9/usr.sbin/tcpdump/tcpdump/tcpdump.1 Directory Properties: stable/9/sys/ (props changed) stable/9/sys/dev/ (props changed) stable/9/sys/dev/e1000/ (props changed) stable/9/sys/dev/isp/ (props changed) stable/9/tools/kerneldoc/ (props changed) stable/9/usr.bin/lex/ (props changed) stable/9/usr.sbin/tcpdump/ (props changed) Modified: stable/9/sys/dev/buslogic/bt.c ============================================================================== --- stable/9/sys/dev/buslogic/bt.c Mon Sep 17 00:44:11 2012 (r240578) +++ stable/9/sys/dev/buslogic/bt.c Mon Sep 17 00:44:16 2012 (r240579) @@ -1945,7 +1945,7 @@ bt_cmd(struct bt_softc *bt, bt_op_t opco bt_outb(bt, COMMAND_REG, opcode); /* - * Wait for up to 1sec for each byte of the the + * Wait for up to 1sec for each byte of the * parameter list sent to be sent. */ timeout = 10000; Modified: stable/9/sys/dev/e1000/e1000_82575.c ============================================================================== --- stable/9/sys/dev/e1000/e1000_82575.c Mon Sep 17 00:44:11 2012 (r240578) +++ stable/9/sys/dev/e1000/e1000_82575.c Mon Sep 17 00:44:16 2012 (r240579) @@ -2280,7 +2280,7 @@ out: * e1000_reset_mdicnfg_82580 - Reset MDICNFG destination and com_mdio bits * @hw: pointer to the HW structure * - * This resets the the MDICNFG.Destination and MDICNFG.Com_MDIO bits based on + * This resets the MDICNFG.Destination and MDICNFG.Com_MDIO bits based on * the values found in the EEPROM. This addresses an issue in which these * bits are not restored from EEPROM after reset. **/ Modified: stable/9/sys/dev/e1000/e1000_ich8lan.c ============================================================================== --- stable/9/sys/dev/e1000/e1000_ich8lan.c Mon Sep 17 00:44:11 2012 (r240578) +++ stable/9/sys/dev/e1000/e1000_ich8lan.c Mon Sep 17 00:44:16 2012 (r240579) @@ -3228,7 +3228,7 @@ out: * @hw: pointer to the HW structure * * ICH8 use the PCI Express bus, but does not contain a PCI Express Capability - * register, so the the bus width is hard coded. + * register, so the bus width is hard coded. **/ static s32 e1000_get_bus_info_ich8lan(struct e1000_hw *hw) { Modified: stable/9/sys/dev/isci/scil/sati.c ============================================================================== --- stable/9/sys/dev/isci/scil/sati.c Mon Sep 17 00:44:11 2012 (r240578) +++ stable/9/sys/dev/isci/scil/sati.c Mon Sep 17 00:44:16 2012 (r240579) @@ -1236,7 +1236,7 @@ void sati_sequence_terminate( ) { // Decode the sequence type to determine how to handle the termination - // of the the translation method. + // of the translation method. switch (sequence->type) { case SATI_SEQUENCE_UNMAP: Modified: stable/9/sys/dev/isci/scil/sati_callbacks.h ============================================================================== --- stable/9/sys/dev/isci/scil/sati_callbacks.h Mon Sep 17 00:44:11 2012 (r240578) +++ stable/9/sys/dev/isci/scil/sati_callbacks.h Mon Sep 17 00:44:16 2012 (r240579) @@ -153,7 +153,7 @@ void sati_cb_get_data_byte( ); /** - * @brief This callback method gets the the task type for the SCSI task + * @brief This callback method gets the task type for the SCSI task * request. * * @param[in] scsi_task This parameter specifies the user's SCSI Task request. Modified: stable/9/sys/dev/isci/scil/sci_base_controller.h ============================================================================== --- stable/9/sys/dev/isci/scil/sci_base_controller.h Mon Sep 17 00:44:11 2012 (r240578) +++ stable/9/sys/dev/isci/scil/sci_base_controller.h Mon Sep 17 00:44:16 2012 (r240579) @@ -113,7 +113,7 @@ typedef enum _SCI_BASE_CONTROLLER_STATES SCI_BASE_CONTROLLER_STATE_INITIALIZED, /** - * This state indicates the the controller is in the process of becoming + * This state indicates the controller is in the process of becoming * ready (i.e. starting). In this state no new IO operations are permitted. * This state is entered from the INITIALIZED state. */ Modified: stable/9/sys/dev/isci/scil/sci_base_domain.h ============================================================================== --- stable/9/sys/dev/isci/scil/sci_base_domain.h Mon Sep 17 00:44:11 2012 (r240578) +++ stable/9/sys/dev/isci/scil/sci_base_domain.h Mon Sep 17 00:44:16 2012 (r240579) @@ -92,7 +92,7 @@ typedef enum _SCI_BASE_DOMAIN_STATES SCI_BASE_DOMAIN_STATE_STARTING, /** - * This state indicates the the domain is now ready. Thus, the user + * This state indicates the domain is now ready. Thus, the user * is able to perform IO operations to remote devices in this domain. * This state is entered from the STOPPED state. * This state is entered from the STOPPING state. Modified: stable/9/sys/dev/isci/scil/sci_base_phy.h ============================================================================== --- stable/9/sys/dev/isci/scil/sci_base_phy.h Mon Sep 17 00:44:11 2012 (r240578) +++ stable/9/sys/dev/isci/scil/sci_base_phy.h Mon Sep 17 00:44:16 2012 (r240579) @@ -102,7 +102,7 @@ typedef enum _SCI_BASE_PHY_STATES SCI_BASE_PHY_STATE_STARTING, /** - * This state indicates the the phy is now ready. Thus, the user + * This state indicates the phy is now ready. Thus, the user * is able to perform IO operations utilizing this phy as long as it * is currently part of a valid port. * This state is entered from the STARTING state. Modified: stable/9/sys/dev/isci/scil/sci_base_remote_device.h ============================================================================== --- stable/9/sys/dev/isci/scil/sci_base_remote_device.h Mon Sep 17 00:44:11 2012 (r240578) +++ stable/9/sys/dev/isci/scil/sci_base_remote_device.h Mon Sep 17 00:44:16 2012 (r240579) @@ -93,7 +93,7 @@ typedef enum _SCI_BASE_REMOTE_DEVICE_STA SCI_BASE_REMOTE_DEVICE_STATE_STOPPED, /** - * This state indicates the the remote device is in the process of + * This state indicates the remote device is in the process of * becoming ready (i.e. starting). In this state no new IO operations * are permitted. * This state is entered from the STOPPED state. Modified: stable/9/sys/dev/isci/scil/scic_io_request.h ============================================================================== --- stable/9/sys/dev/isci/scil/scic_io_request.h Mon Sep 17 00:44:11 2012 (r240578) +++ stable/9/sys/dev/isci/scil/scic_io_request.h Mon Sep 17 00:44:16 2012 (r240579) @@ -260,12 +260,12 @@ typedef struct SCIC_SMP_PASSTHRU_REQUEST */ U8 (* scic_cb_smp_passthru_get_frame_type) ( void *); /** - * Function pointer to get the function in the the smp request + * Function pointer to get the function in the smp request */ U8 (* scic_cb_smp_passthru_get_function) ( void * ); /** - * Function pointer to get the "allocated response length" in the the smp request + * Function pointer to get the "allocated response length" in the smp request */ U8 (* scic_cb_smp_passthru_get_allocated_response_length) ( void * ); Modified: stable/9/sys/dev/isci/scil/scic_sds_phy.c ============================================================================== --- stable/9/sys/dev/isci/scil/scic_sds_phy.c Mon Sep 17 00:44:11 2012 (r240578) +++ stable/9/sys/dev/isci/scil/scic_sds_phy.c Mon Sep 17 00:44:16 2012 (r240579) @@ -658,7 +658,7 @@ void scic_sds_phy_construct( // Clear out the error counter data memset(this_phy->error_counter, 0, sizeof(this_phy->error_counter)); - // Initialize the the substate machines + // Initialize the substate machines sci_base_state_machine_construct( &this_phy->starting_substate_machine, &this_phy->parent.parent, Modified: stable/9/sys/dev/isci/scil/scic_sds_port.h ============================================================================== --- stable/9/sys/dev/isci/scil/scic_sds_port.h Mon Sep 17 00:44:11 2012 (r240578) +++ stable/9/sys/dev/isci/scil/scic_sds_port.h Mon Sep 17 00:44:16 2012 (r240579) @@ -109,7 +109,7 @@ struct SCIC_SDS_REQUEST; /** * @struct SCIC_SDS_PORT * - * The core port object provides the the abstraction for an SCU port. + * The core port object provides the abstraction for an SCU port. */ typedef struct SCIC_SDS_PORT { Modified: stable/9/sys/dev/isci/scil/scic_sds_remote_node_context.h ============================================================================== --- stable/9/sys/dev/isci/scil/scic_sds_remote_node_context.h Mon Sep 17 00:44:11 2012 (r240578) +++ stable/9/sys/dev/isci/scil/scic_sds_remote_node_context.h Mon Sep 17 00:44:16 2012 (r240579) @@ -237,7 +237,7 @@ enum SCIC_SDS_REMOTE_NODE_CONTEXT_DESTIN * * @brief This structure contains the data associated with the remote * node context object. The remote node context (RNC) object models - * the the remote device information necessary to manage the + * the remote device information necessary to manage the * silicon RNC. */ typedef struct SCIC_SDS_REMOTE_NODE_CONTEXT Modified: stable/9/sys/dev/isci/scil/scic_sds_request.c ============================================================================== --- stable/9/sys/dev/isci/scil/scic_sds_request.c Mon Sep 17 00:44:11 2012 (r240578) +++ stable/9/sys/dev/isci/scil/scic_sds_request.c Mon Sep 17 00:44:16 2012 (r240579) @@ -2679,7 +2679,7 @@ void scic_sds_request_initial_state_ente /** * This method implements the actions taken when entering the * SCI_BASE_REQUEST_STATE_CONSTRUCTED state. - * The method sets the state handlers for the the constructed state. + * The method sets the state handlers for the constructed state. * * @param[in] object The io request object that is to enter the constructed * state. Modified: stable/9/sys/dev/isci/scil/scu_bios_definitions.h ============================================================================== --- stable/9/sys/dev/isci/scil/scu_bios_definitions.h Mon Sep 17 00:44:11 2012 (r240578) +++ stable/9/sys/dev/isci/scil/scu_bios_definitions.h Mon Sep 17 00:44:16 2012 (r240579) @@ -299,7 +299,7 @@ typedef struct SCI_BIOS_OEM_PARAM_ELEMEN } sas_address; /** - * These are the per PHY equalization settings associated with the the + * These are the per PHY equalization settings associated with the * AFE XCVR Tx Amplitude and Equalization Control Register Set * (0 thru 3). * @@ -496,7 +496,7 @@ typedef struct SCI_BIOS_OEM_PARAM_ELEMEN } sas_address; /** - * These are the per PHY equalization settings associated with the the + * These are the per PHY equalization settings associated with the * AFE XCVR Tx Amplitude and Equalization Control Register Set * (0 thru 3). * @@ -706,7 +706,7 @@ typedef struct SCI_BIOS_OEM_PARAM_ELEMEN } sas_address; /** - * These are the per PHY equalization settings associated with the the + * These are the per PHY equalization settings associated with the * AFE XCVR Tx Amplitude and Equalization Control Register Set * (0 thru 3). * @@ -927,7 +927,7 @@ typedef struct SCI_BIOS_OEM_PARAM_ELEMEN } sas_address; /** - * These are the per PHY equalization settings associated with the the + * These are the per PHY equalization settings associated with the * AFE XCVR Tx Amplitude and Equalization Control Register Set * (0 thru 3). * Modified: stable/9/sys/dev/isp/isp_freebsd.c ============================================================================== --- stable/9/sys/dev/isp/isp_freebsd.c Mon Sep 17 00:44:11 2012 (r240578) +++ stable/9/sys/dev/isp/isp_freebsd.c Mon Sep 17 00:44:16 2012 (r240579) @@ -1889,7 +1889,7 @@ isp_target_start_ctio(ispsoftc_t *isp, u * Mode 1, status, no data. Only possible when we are sending status, have * no data to transfer, and the sense length can fit in the ct7_entry. * - * Mode 2, status, no data. We have to use this in the case the the response + * Mode 2, status, no data. We have to use this in the case the response * length won't fit into a ct2_entry_t. * * We'll fill out this structure with information as if this were a Modified: stable/9/sys/dev/mps/mps_sas.c ============================================================================== --- stable/9/sys/dev/mps/mps_sas.c Mon Sep 17 00:44:11 2012 (r240578) +++ stable/9/sys/dev/mps/mps_sas.c Mon Sep 17 00:44:16 2012 (r240579) @@ -360,7 +360,7 @@ mpssas_remove_volume(struct mps_softc *s mps_printf(sc, "Reset aborted %u commands\n", reply->TerminationCount); mps_free_reply(sc, tm->cm_reply_data); - tm->cm_reply = NULL; /* Ensures the the reply won't get re-freed */ + tm->cm_reply = NULL; /* Ensures the reply won't get re-freed */ mps_printf(sc, "clearing target %u handle 0x%04x\n", targ->tid, handle); @@ -550,7 +550,7 @@ mpssas_remove_device(struct mps_softc *s mps_dprint(sc, MPS_INFO, "Reset aborted %u commands\n", le32toh(reply->TerminationCount)); mps_free_reply(sc, tm->cm_reply_data); - tm->cm_reply = NULL; /* Ensures the the reply won't get re-freed */ + tm->cm_reply = NULL; /* Ensures the reply won't get re-freed */ /* Reuse the existing command */ req = (MPI2_SAS_IOUNIT_CONTROL_REQUEST *)tm->cm_req; Modified: stable/9/sys/kern/subr_unit.c ============================================================================== --- stable/9/sys/kern/subr_unit.c Mon Sep 17 00:44:11 2012 (r240578) +++ stable/9/sys/kern/subr_unit.c Mon Sep 17 00:44:16 2012 (r240579) @@ -63,7 +63,7 @@ * in the usermode test program included, the worst case usage * was 798 bytes on i386 for 5000 allocated and 5000 free units. * * The worst case is where every other unit number is allocated and - * the the rest are free. In that case 44 + N/4 bytes are used where + * the rest are free. In that case 44 + N/4 bytes are used where * N is the number of the highest unit allocated. */ Modified: stable/9/sys/sparc64/sparc64/ata_machdep.c ============================================================================== --- stable/9/sys/sparc64/sparc64/ata_machdep.c Mon Sep 17 00:44:11 2012 (r240578) +++ stable/9/sys/sparc64/sparc64/ata_machdep.c Mon Sep 17 00:44:16 2012 (r240579) @@ -40,7 +40,7 @@ sparc64_ata_disk_firmware_geom_adjust(st * and sectors so the geometry of large disks has to be adjusted. * If the disk is > 32GB at 16 heads and 63 sectors, adjust to 255 * sectors (this matches what the OpenSolaris dad(7D) driver does). - * If the the disk is even > 128GB, additionally adjust the heads to + * If the disk is even > 128GB, additionally adjust the heads to * 255. This allows disks up to the 2TB limit of the extended VTOC8. * XXX the OpenSolaris dad(7D) driver limits the mediasize to 128GB. */ Modified: stable/9/sys/vm/vm_pageout.c ============================================================================== --- stable/9/sys/vm/vm_pageout.c Mon Sep 17 00:44:11 2012 (r240578) +++ stable/9/sys/vm/vm_pageout.c Mon Sep 17 00:44:16 2012 (r240579) @@ -755,7 +755,7 @@ vm_pageout_scan(int pass) uma_reclaim(); /* - * The addl_page_shortage is the the number of temporarily + * The addl_page_shortage is the number of temporarily * stuck pages in the inactive queue. In other words, the * number of pages from cnt.v_inactive_count that should be * discounted in setting the target for the active queue scan. Modified: stable/9/usr.sbin/tcpdump/tcpdump/tcpdump.1 ============================================================================== --- stable/9/usr.sbin/tcpdump/tcpdump/tcpdump.1 Mon Sep 17 00:44:11 2012 (r240578) +++ stable/9/usr.sbin/tcpdump/tcpdump/tcpdump.1 Mon Sep 17 00:44:16 2012 (r240579) @@ -1436,11 +1436,11 @@ not be useful to people who are not fami AFS and RX. .LP If the -v (verbose) flag is given twice, acknowledgement packets and -additional header information is printed, such as the the RX call ID, +additional header information is printed, such as the RX call ID, call number, sequence number, serial number, and the RX packet flags. .LP If the -v flag is given twice, additional information is printed, -such as the the RX call ID, serial number, and the RX packet flags. +such as the RX call ID, serial number, and the RX packet flags. The MTU negotiation information is also printed from RX ack packets. .LP If the -v flag is given three times, the security index and service id From owner-svn-src-stable@FreeBSD.ORG Mon Sep 17 00:47:37 2012 Return-Path: Delivered-To: svn-src-stable@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id EA6F3106564A; Mon, 17 Sep 2012 00:47:36 +0000 (UTC) (envelope-from eadler@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id CC44D8FC0A; Mon, 17 Sep 2012 00:47:36 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q8H0laQo016433; Mon, 17 Sep 2012 00:47:36 GMT (envelope-from eadler@svn.freebsd.org) Received: (from eadler@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q8H0laRW016421; Mon, 17 Sep 2012 00:47:36 GMT (envelope-from eadler@svn.freebsd.org) Message-Id: <201209170047.q8H0laRW016421@svn.freebsd.org> From: Eitan Adler Date: Mon, 17 Sep 2012 00:47:36 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r240580 - in stable/9/sys: dev/isci/scil dev/vxge/include i386/include/xen netinet X-BeenThere: svn-src-stable@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for all the -stable branches of the src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 17 Sep 2012 00:47:37 -0000 Author: eadler Date: Mon Sep 17 00:47:35 2012 New Revision: 240580 URL: http://svn.freebsd.org/changeset/base/240580 Log: MFC r240520: s/teh/the/g Approved by: cperciva (implicit) Modified: stable/9/sys/dev/isci/scil/scic_io_request.h stable/9/sys/dev/vxge/include/vxgehal-ll.h stable/9/sys/i386/include/xen/xen-os.h stable/9/sys/netinet/sctp_input.c Directory Properties: stable/9/sys/ (props changed) stable/9/sys/dev/ (props changed) Modified: stable/9/sys/dev/isci/scil/scic_io_request.h ============================================================================== --- stable/9/sys/dev/isci/scil/scic_io_request.h Mon Sep 17 00:44:16 2012 (r240579) +++ stable/9/sys/dev/isci/scil/scic_io_request.h Mon Sep 17 00:47:35 2012 (r240580) @@ -706,7 +706,7 @@ void * scic_stp_io_request_get_h2d_reg_a * @brief This method will return the address of the device to host register * fis region for the io request object. * - * @param[in] scic_io_request This parameter specifies teh handle to the io + * @param[in] scic_io_request This parameter specifies the handle to the io * request object from which to get the device to host register fis * buffer. * Modified: stable/9/sys/dev/vxge/include/vxgehal-ll.h ============================================================================== --- stable/9/sys/dev/vxge/include/vxgehal-ll.h Mon Sep 17 00:44:16 2012 (r240579) +++ stable/9/sys/dev/vxge/include/vxgehal-ll.h Mon Sep 17 00:47:35 2012 (r240580) @@ -3095,7 +3095,7 @@ typedef struct vxge_hal_device_pmd_info_ * @mac_addr_masks: Mac address masks for each vpath * * Returns the vpath mask that has the bits set for each vpath allocated - * for the driver and teh first mac addresse for each vpath + * for the driver and the first mac addresse for each vpath */ typedef struct vxge_hal_device_hw_info_t { u32 host_type; Modified: stable/9/sys/i386/include/xen/xen-os.h ============================================================================== --- stable/9/sys/i386/include/xen/xen-os.h Mon Sep 17 00:44:16 2012 (r240579) +++ stable/9/sys/i386/include/xen/xen-os.h Mon Sep 17 00:47:35 2012 (r240580) @@ -99,7 +99,7 @@ void trap_init(void); /* * STI/CLI equivalents. These basically set and clear the virtual - * event_enable flag in teh shared_info structure. Note that when + * event_enable flag in the shared_info structure. Note that when * the enable bit is set, there may be pending events to be handled. * We may therefore call into do_hypervisor_callback() directly. */ Modified: stable/9/sys/netinet/sctp_input.c ============================================================================== --- stable/9/sys/netinet/sctp_input.c Mon Sep 17 00:44:16 2012 (r240579) +++ stable/9/sys/netinet/sctp_input.c Mon Sep 17 00:47:35 2012 (r240580) @@ -3160,7 +3160,7 @@ sctp_handle_ecn_cwr(struct sctp_cwr_chun { /* * Here we get a CWR from the peer. We must look in the outqueue and - * make sure that we have a covered ECNE in teh control chunk part. + * make sure that we have a covered ECNE in the control chunk part. * If so remove it. */ struct sctp_tmit_chunk *chk; From owner-svn-src-stable@FreeBSD.ORG Mon Sep 17 00:47:38 2012 Return-Path: Delivered-To: svn-src-stable@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 02008106566C; Mon, 17 Sep 2012 00:47:38 +0000 (UTC) (envelope-from eadler@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id E0E0F8FC0C; Mon, 17 Sep 2012 00:47:37 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q8H0lb4T016458; Mon, 17 Sep 2012 00:47:37 GMT (envelope-from eadler@svn.freebsd.org) Received: (from eadler@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q8H0lboF016455; Mon, 17 Sep 2012 00:47:37 GMT (envelope-from eadler@svn.freebsd.org) Message-Id: <201209170047.q8H0lboF016455@svn.freebsd.org> From: Eitan Adler Date: Mon, 17 Sep 2012 00:47:37 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-8@freebsd.org X-SVN-Group: stable-8 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r240581 - in stable/8/sys: i386/include/xen netinet X-BeenThere: svn-src-stable@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for all the -stable branches of the src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 17 Sep 2012 00:47:38 -0000 Author: eadler Date: Mon Sep 17 00:47:37 2012 New Revision: 240581 URL: http://svn.freebsd.org/changeset/base/240581 Log: MFC r240520: s/teh/the/g Approved by: cperciva (implicit) Modified: stable/8/sys/i386/include/xen/xen-os.h stable/8/sys/netinet/sctp_input.c Directory Properties: stable/8/sys/ (props changed) stable/8/sys/i386/ (props changed) stable/8/sys/netinet/ (props changed) Modified: stable/8/sys/i386/include/xen/xen-os.h ============================================================================== --- stable/8/sys/i386/include/xen/xen-os.h Mon Sep 17 00:47:35 2012 (r240580) +++ stable/8/sys/i386/include/xen/xen-os.h Mon Sep 17 00:47:37 2012 (r240581) @@ -99,7 +99,7 @@ void trap_init(void); /* * STI/CLI equivalents. These basically set and clear the virtual - * event_enable flag in teh shared_info structure. Note that when + * event_enable flag in the shared_info structure. Note that when * the enable bit is set, there may be pending events to be handled. * We may therefore call into do_hypervisor_callback() directly. */ Modified: stable/8/sys/netinet/sctp_input.c ============================================================================== --- stable/8/sys/netinet/sctp_input.c Mon Sep 17 00:47:35 2012 (r240580) +++ stable/8/sys/netinet/sctp_input.c Mon Sep 17 00:47:37 2012 (r240581) @@ -3107,7 +3107,7 @@ sctp_handle_ecn_cwr(struct sctp_cwr_chun { /* * Here we get a CWR from the peer. We must look in the outqueue and - * make sure that we have a covered ECNE in teh control chunk part. + * make sure that we have a covered ECNE in the control chunk part. * If so remove it. */ struct sctp_tmit_chunk *chk; From owner-svn-src-stable@FreeBSD.ORG Mon Sep 17 00:56:11 2012 Return-Path: Delivered-To: svn-src-stable@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id C1901106564A; Mon, 17 Sep 2012 00:56:11 +0000 (UTC) (envelope-from eadler@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id A80658FC15; Mon, 17 Sep 2012 00:56:11 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q8H0uB1E017867; Mon, 17 Sep 2012 00:56:11 GMT (envelope-from eadler@svn.freebsd.org) Received: (from eadler@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q8H0uBSH017854; Mon, 17 Sep 2012 00:56:11 GMT (envelope-from eadler@svn.freebsd.org) Message-Id: <201209170056.q8H0uBSH017854@svn.freebsd.org> From: Eitan Adler Date: Mon, 17 Sep 2012 00:56:11 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r240582 - in stable/9: lib/libpam/modules/pam_lastlog libexec/comsat libexec/ftpd share/man/man7 usr.bin/finger usr.bin/last usr.bin/ncplist usr.bin/talk usr.bin/users usr.bin/w usr.sbi... X-BeenThere: svn-src-stable@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for all the -stable branches of the src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 17 Sep 2012 00:56:12 -0000 Author: eadler Date: Mon Sep 17 00:56:10 2012 New Revision: 240582 URL: http://svn.freebsd.org/changeset/base/240582 Log: MFC r240506: Bump date missed in r202756 PR: docs/171624 Approved by: cperciva (implicit) Modified: stable/9/lib/libpam/modules/pam_lastlog/pam_lastlog.8 stable/9/libexec/comsat/comsat.8 stable/9/libexec/ftpd/ftpd.8 stable/9/share/man/man7/hier.7 stable/9/usr.bin/finger/finger.1 stable/9/usr.bin/last/last.1 stable/9/usr.bin/ncplist/ncplist.1 stable/9/usr.bin/talk/talk.1 stable/9/usr.bin/users/users.1 stable/9/usr.bin/w/w.1 stable/9/usr.sbin/ac/ac.8 stable/9/usr.sbin/rwhod/rwhod.8 Directory Properties: stable/9/lib/libpam/ (props changed) stable/9/libexec/comsat/ (props changed) stable/9/libexec/ftpd/ (props changed) stable/9/share/man/man4/ (props changed) stable/9/share/man/man7/ (props changed) stable/9/usr.bin/finger/ (props changed) stable/9/usr.bin/last/ (props changed) stable/9/usr.bin/ncplist/ (props changed) stable/9/usr.bin/talk/ (props changed) stable/9/usr.bin/users/ (props changed) stable/9/usr.bin/w/ (props changed) stable/9/usr.sbin/ac/ (props changed) stable/9/usr.sbin/rwhod/ (props changed) Modified: stable/9/lib/libpam/modules/pam_lastlog/pam_lastlog.8 ============================================================================== --- stable/9/lib/libpam/modules/pam_lastlog/pam_lastlog.8 Mon Sep 17 00:47:37 2012 (r240581) +++ stable/9/lib/libpam/modules/pam_lastlog/pam_lastlog.8 Mon Sep 17 00:56:10 2012 (r240582) @@ -34,7 +34,7 @@ .\" .\" $FreeBSD$ .\" -.Dd January 24, 2002 +.Dd January 21, 2010 .Dt PAM_LASTLOG 8 .Os .Sh NAME Modified: stable/9/libexec/comsat/comsat.8 ============================================================================== --- stable/9/libexec/comsat/comsat.8 Mon Sep 17 00:47:37 2012 (r240581) +++ stable/9/libexec/comsat/comsat.8 Mon Sep 17 00:56:10 2012 (r240582) @@ -32,7 +32,7 @@ .\" @(#)comsat.8 8.1 (Berkeley) 6/4/93 .\" $FreeBSD$ .\" -.Dd July 9, 2002 +.Dd January 21, 2010 .Dt COMSAT 8 .Os .Sh NAME Modified: stable/9/libexec/ftpd/ftpd.8 ============================================================================== --- stable/9/libexec/ftpd/ftpd.8 Mon Sep 17 00:47:37 2012 (r240581) +++ stable/9/libexec/ftpd/ftpd.8 Mon Sep 17 00:56:10 2012 (r240582) @@ -32,7 +32,7 @@ .\" @(#)ftpd.8 8.2 (Berkeley) 4/19/94 .\" $FreeBSD$ .\" -.Dd April 20, 2007 +.Dd January 21, 2010 .Dt FTPD 8 .Os .Sh NAME Modified: stable/9/share/man/man7/hier.7 ============================================================================== --- stable/9/share/man/man7/hier.7 Mon Sep 17 00:47:37 2012 (r240581) +++ stable/9/share/man/man7/hier.7 Mon Sep 17 00:56:10 2012 (r240582) @@ -32,7 +32,7 @@ .\" @(#)hier.7 8.1 (Berkeley) 6/5/93 .\" $FreeBSD$ .\" -.Dd May 25, 2008 +.Dd January 21, 2010 .Dt HIER 7 .Os .Sh NAME Modified: stable/9/usr.bin/finger/finger.1 ============================================================================== --- stable/9/usr.bin/finger/finger.1 Mon Sep 17 00:47:37 2012 (r240581) +++ stable/9/usr.bin/finger/finger.1 Mon Sep 17 00:56:10 2012 (r240582) @@ -28,7 +28,7 @@ .\" @(#)finger.1 8.3 (Berkeley) 5/5/94 .\" $FreeBSD$ .\" -.Dd April 11, 2007 +.Dd January 21, 2010 .Dt FINGER 1 .Os .Sh NAME Modified: stable/9/usr.bin/last/last.1 ============================================================================== --- stable/9/usr.bin/last/last.1 Mon Sep 17 00:47:37 2012 (r240581) +++ stable/9/usr.bin/last/last.1 Mon Sep 17 00:56:10 2012 (r240582) @@ -28,7 +28,7 @@ .\" @(#)last.1 8.1 (Berkeley) 6/6/93 .\" $FreeBSD$ .\" -.Dd July 27, 2003 +.Dd January 21, 2010 .Dt LAST 1 .Os .Sh NAME Modified: stable/9/usr.bin/ncplist/ncplist.1 ============================================================================== --- stable/9/usr.bin/ncplist/ncplist.1 Mon Sep 17 00:47:37 2012 (r240581) +++ stable/9/usr.bin/ncplist/ncplist.1 Mon Sep 17 00:56:10 2012 (r240582) @@ -1,5 +1,5 @@ .\" $FreeBSD$ -.Dd June 24, 1999 +.Dd January 21, 2010 .Dt NCPLIST 1 .Os .Sh NAME Modified: stable/9/usr.bin/talk/talk.1 ============================================================================== --- stable/9/usr.bin/talk/talk.1 Mon Sep 17 00:47:37 2012 (r240581) +++ stable/9/usr.bin/talk/talk.1 Mon Sep 17 00:56:10 2012 (r240582) @@ -28,7 +28,7 @@ .\" @(#)talk.1 8.1 (Berkeley) 6/6/93 .\" $FreeBSD$ .\" -.Dd July 3, 2004 +.Dd January 21, 2010 .Dt TALK 1 .Os .Sh NAME Modified: stable/9/usr.bin/users/users.1 ============================================================================== --- stable/9/usr.bin/users/users.1 Mon Sep 17 00:47:37 2012 (r240581) +++ stable/9/usr.bin/users/users.1 Mon Sep 17 00:56:10 2012 (r240582) @@ -28,7 +28,7 @@ .\" @(#)users.1 8.1 (Berkeley) 6/6/93 .\" $FreeBSD$ .\" -.Dd June 6, 1993 +.Dd January 21, 2010 .Dt USERS 1 .Os .Sh NAME Modified: stable/9/usr.bin/w/w.1 ============================================================================== --- stable/9/usr.bin/w/w.1 Mon Sep 17 00:47:37 2012 (r240581) +++ stable/9/usr.bin/w/w.1 Mon Sep 17 00:56:10 2012 (r240582) @@ -28,7 +28,7 @@ .\" @(#)w.1 8.1 (Berkeley) 6/6/93 .\" $FreeBSD$ .\" -.Dd June 6, 1993 +.Dd January 21, 2010 .Dt W 1 .Os .Sh NAME Modified: stable/9/usr.sbin/ac/ac.8 ============================================================================== --- stable/9/usr.sbin/ac/ac.8 Mon Sep 17 00:47:37 2012 (r240581) +++ stable/9/usr.sbin/ac/ac.8 Mon Sep 17 00:56:10 2012 (r240582) @@ -30,7 +30,7 @@ .\" .\" $FreeBSD$ .\" -.Dd March 15, 1994 +.Dd January 21, 2010 .Dt AC 8 .Os .Sh NAME Modified: stable/9/usr.sbin/rwhod/rwhod.8 ============================================================================== --- stable/9/usr.sbin/rwhod/rwhod.8 Mon Sep 17 00:47:37 2012 (r240581) +++ stable/9/usr.sbin/rwhod/rwhod.8 Mon Sep 17 00:56:10 2012 (r240582) @@ -28,7 +28,7 @@ .\" @(#)rwhod.8 8.2 (Berkeley) 12/11/93 .\" $FreeBSD$ .\" -.Dd December 11, 1993 +.Dd January 21, 2010 .Dt RWHOD 8 .Os .Sh NAME From owner-svn-src-stable@FreeBSD.ORG Mon Sep 17 11:21:57 2012 Return-Path: Delivered-To: svn-src-stable@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 89EF1106564A; Mon, 17 Sep 2012 11:21:57 +0000 (UTC) (envelope-from trasz@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 7472C8FC12; Mon, 17 Sep 2012 11:21:57 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q8HBLvjC004139; Mon, 17 Sep 2012 11:21:57 GMT (envelope-from trasz@svn.freebsd.org) Received: (from trasz@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q8HBLviY004137; Mon, 17 Sep 2012 11:21:57 GMT (envelope-from trasz@svn.freebsd.org) Message-Id: <201209171121.q8HBLviY004137@svn.freebsd.org> From: Edward Tomasz Napierala Date: Mon, 17 Sep 2012 11:21:57 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r240598 - stable/9/bin/setfacl X-BeenThere: svn-src-stable@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for all the -stable branches of the src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 17 Sep 2012 11:21:57 -0000 Author: trasz Date: Mon Sep 17 11:21:57 2012 New Revision: 240598 URL: http://svn.freebsd.org/changeset/base/240598 Log: MFC r240076: Fix compact form of "synchronize" permission in setfacl(1) manual page - it should be "s", not "S". PR: docs/162380 Modified: stable/9/bin/setfacl/setfacl.1 Directory Properties: stable/9/bin/setfacl/ (props changed) Modified: stable/9/bin/setfacl/setfacl.1 ============================================================================== --- stable/9/bin/setfacl/setfacl.1 Mon Sep 17 09:32:11 2012 (r240597) +++ stable/9/bin/setfacl/setfacl.1 Mon Sep 17 11:21:57 2012 (r240598) @@ -26,7 +26,7 @@ .\" .\" $FreeBSD$ .\" -.Dd April 9, 2011 +.Dd September 2, 2012 .Dt SETFACL 1 .Os .Sh NAME @@ -337,7 +337,7 @@ read_acl write_acl .It o write_owner -.It S +.It s synchronize .El .Pp From owner-svn-src-stable@FreeBSD.ORG Mon Sep 17 11:27:56 2012 Return-Path: Delivered-To: svn-src-stable@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id AEC551065677; Mon, 17 Sep 2012 11:27:56 +0000 (UTC) (envelope-from trasz@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 994FC8FC1C; Mon, 17 Sep 2012 11:27:56 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q8HBRuFn004991; Mon, 17 Sep 2012 11:27:56 GMT (envelope-from trasz@svn.freebsd.org) Received: (from trasz@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q8HBRunu004989; Mon, 17 Sep 2012 11:27:56 GMT (envelope-from trasz@svn.freebsd.org) Message-Id: <201209171127.q8HBRunu004989@svn.freebsd.org> From: Edward Tomasz Napierala Date: Mon, 17 Sep 2012 11:27:56 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r240599 - stable/9/usr.bin/rctl X-BeenThere: svn-src-stable@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for all the -stable branches of the src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 17 Sep 2012 11:27:56 -0000 Author: trasz Date: Mon Sep 17 11:27:56 2012 New Revision: 240599 URL: http://svn.freebsd.org/changeset/base/240599 Log: MFC r232329: Use proper "maxproc" name, not "nproc". PR: docs/162172 Modified: stable/9/usr.bin/rctl/rctl.8 Directory Properties: stable/9/usr.bin/rctl/ (props changed) Modified: stable/9/usr.bin/rctl/rctl.8 ============================================================================== --- stable/9/usr.bin/rctl/rctl.8 Mon Sep 17 11:21:57 2012 (r240598) +++ stable/9/usr.bin/rctl/rctl.8 Mon Sep 17 11:27:56 2012 (r240599) @@ -25,7 +25,7 @@ .\" .\" $FreeBSD$ .\" -.Dd December 22, 2011 +.Dd March 1, 2012 .Dt RCTL 8 .Os .Sh NAME @@ -117,8 +117,8 @@ A filter is a rule for which one of more For example, a filter that matches every rule could be written as ":::=/", or, in short, ":". A filter that matches all the login classes would be "loginclass:". -A filter that matches all defined rules for nproc resource would be -"::nproc". +A filter that matches all defined rules for maxproc resource would be +"::maxproc". .Pp .Sh RESOURCES .Bl -column -offset 3n "pseudoterminals" From owner-svn-src-stable@FreeBSD.ORG Mon Sep 17 11:35:39 2012 Return-Path: Delivered-To: svn-src-stable@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 1BCCF1065670; Mon, 17 Sep 2012 11:35:39 +0000 (UTC) (envelope-from trasz@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 061408FC08; Mon, 17 Sep 2012 11:35:39 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q8HBZcRV006098; Mon, 17 Sep 2012 11:35:38 GMT (envelope-from trasz@svn.freebsd.org) Received: (from trasz@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q8HBZcp7006096; Mon, 17 Sep 2012 11:35:38 GMT (envelope-from trasz@svn.freebsd.org) Message-Id: <201209171135.q8HBZcp7006096@svn.freebsd.org> From: Edward Tomasz Napierala Date: Mon, 17 Sep 2012 11:35:38 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r240600 - stable/9/usr.bin/rctl X-BeenThere: svn-src-stable@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for all the -stable branches of the src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 17 Sep 2012 11:35:39 -0000 Author: trasz Date: Mon Sep 17 11:35:38 2012 New Revision: 240600 URL: http://svn.freebsd.org/changeset/base/240600 Log: MFC r233456 by joel@: Remove superfluous paragraph macro. MFC r233665 by joel@: mandoc complains loudly when s are misused in columnated lists. Fix this syntax violation and while I'm here also convert to Ta and adjust quotation marks in order to prevent this problem in the future. MFC r233667 by joel@: Remove superfluous paragraph macro. MFC r234568 by delphij@: The .Fx macro needs the version number be in its own word separated by a space. This change have no visible effect for rendering. Modified: stable/9/usr.bin/rctl/rctl.8 Directory Properties: stable/9/usr.bin/rctl/ (props changed) Modified: stable/9/usr.bin/rctl/rctl.8 ============================================================================== --- stable/9/usr.bin/rctl/rctl.8 Mon Sep 17 11:27:56 2012 (r240599) +++ stable/9/usr.bin/rctl/rctl.8 Mon Sep 17 11:35:38 2012 (r240600) @@ -119,36 +119,34 @@ or, in short, ":". A filter that matches all the login classes would be "loginclass:". A filter that matches all defined rules for maxproc resource would be "::maxproc". -.Pp .Sh RESOURCES .Bl -column -offset 3n "pseudoterminals" -.It "cputime CPU time, in seconds" -.It "datasize data size, in bytes" -.It "stacksize stack size, in bytes" -.It "coredumpsize core dump size, in bytes" -.It "memoryuse resident set size, in bytes" -.It "memorylocked locked memory, in bytes" -.It "maxproc number of processes" -.It "openfiles file descriptor table size" -.It "vmemoryuse address space limit, in bytes" -.It "pseudoterminals number of PTYs" -.It "swapuse swap usage, in bytes" -.It "nthr number of threads" -.It "msgqqueued number of queued SysV messages" -.It "msgqsize SysV message queue size, in bytes" -.It "nmsgq number of SysV message queues" -.It "nsem number of SysV semaphores" -.It "nsemop number of SysV semaphores modified in a single semop(2) call" -.It "nshm number of SysV shared memory segments" -.It "shmsize SysV shared memory size, in bytes" -.It "wallclock wallclock time, in seconds" +.It cputime Ta "CPU time, in seconds" +.It datasize Ta "data size, in bytes" +.It stacksize Ta "stack size, in bytes" +.It coredumpsize Ta "core dump size, in bytes" +.It memoryuse Ta "resident set size, in bytes" +.It memorylocked Ta "locked memory, in bytes" +.It maxproc Ta "number of processes" +.It openfiles Ta "file descriptor table size" +.It vmemoryuse Ta "address space limit, in bytes" +.It pseudoterminals Ta "number of PTYs" +.It swapuse Ta "swap usage, in bytes" +.It nthr Ta "number of threads" +.It msgqqueued Ta "number of queued SysV messages" +.It msgqsize Ta "SysV message queue size, in bytes" +.It nmsgq Ta "number of SysV message queues" +.It nsem Ta "number of SysV semaphores" +.It nsemop Ta "number of SysV semaphores modified in a single semop(2) call" +.It nshm Ta "number of SysV shared memory segments" +.It shmsize Ta "SysV shared memory size, in bytes" +.It wallclock Ta "wallclock time, in seconds" .El -.Pp .Sh ACTIONS .Bl -column -offset 3n "pseudoterminals" -.It "deny deny the allocation; not supported for cpu and wallclock" -.It "log log a warning to the console" -.It "devctl send notification to" +.It deny Ta "deny the allocation; not supported for cpu and wallclock" +.It log Ta "log a warning to the console" +.It devctl Ta "send notification to" .Xr devd 8 .It "sig* e.g. sigterm; send a signal to the offending process" .El @@ -162,7 +160,6 @@ Attempt to add rule with action not supp in error. .Pp Note that limiting RSS may kill the machine due to thrashing. -.Pp .Sh EXIT STATUS .Ex -std .Sh EXAMPLES @@ -189,7 +186,7 @@ Display all the rules applicable to proc The .Nm command appeared in -.Fx 9.0. +.Fx 9.0 . .Sh AUTHORS .An -nosplit The From owner-svn-src-stable@FreeBSD.ORG Mon Sep 17 11:39:28 2012 Return-Path: Delivered-To: svn-src-stable@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id A27321065702; Mon, 17 Sep 2012 11:39:28 +0000 (UTC) (envelope-from trasz@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 8CCEA8FC16; Mon, 17 Sep 2012 11:39:28 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q8HBdSVw006642; Mon, 17 Sep 2012 11:39:28 GMT (envelope-from trasz@svn.freebsd.org) Received: (from trasz@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q8HBdS4r006640; Mon, 17 Sep 2012 11:39:28 GMT (envelope-from trasz@svn.freebsd.org) Message-Id: <201209171139.q8HBdS4r006640@svn.freebsd.org> From: Edward Tomasz Napierala Date: Mon, 17 Sep 2012 11:39:28 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r240601 - stable/9/usr.bin/rctl X-BeenThere: svn-src-stable@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for all the -stable branches of the src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 17 Sep 2012 11:39:28 -0000 Author: trasz Date: Mon Sep 17 11:39:28 2012 New Revision: 240601 URL: http://svn.freebsd.org/changeset/base/240601 Log: MFC r239990: Improve description for "rctl -l". Modified: stable/9/usr.bin/rctl/rctl.8 Directory Properties: stable/9/usr.bin/rctl/ (props changed) Modified: stable/9/usr.bin/rctl/rctl.8 ============================================================================== --- stable/9/usr.bin/rctl/rctl.8 Mon Sep 17 11:35:38 2012 (r240600) +++ stable/9/usr.bin/rctl/rctl.8 Mon Sep 17 11:39:28 2012 (r240601) @@ -25,7 +25,7 @@ .\" .\" $FreeBSD$ .\" -.Dd March 1, 2012 +.Dd September 1, 2012 .Dt RCTL 8 .Os .Sh NAME @@ -68,6 +68,10 @@ to the RCTL database. .It Fl l Ar filter Display rules applicable to the process defined by .Ar filter . +Note that this is different from showing the rules when called without +any options, as it shows not just the rules with subject equal to that +of process, but also rules for the user, jail, and login class applicable +to the process. .It Fl r Ar filter Remove rules matching .Ar filter @@ -90,7 +94,8 @@ Subject defines the kind of entity the r It can be either process, user, login class, or jail. .Pp Subject ID identifies the subject. -It can be user name, numerical user ID, login class name, or jail name. +It can be a process ID, user name, numerical user ID, login class name, +or jail name. .Pp Resource identifies the resource the rule controls. .Pp From owner-svn-src-stable@FreeBSD.ORG Mon Sep 17 13:05:39 2012 Return-Path: Delivered-To: svn-src-stable@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id C87AF106564A; Mon, 17 Sep 2012 13:05:39 +0000 (UTC) (envelope-from glebius@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 951358FC0C; Mon, 17 Sep 2012 13:05:39 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q8HD5d5l020505; Mon, 17 Sep 2012 13:05:39 GMT (envelope-from glebius@svn.freebsd.org) Received: (from glebius@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q8HD5d9F020502; Mon, 17 Sep 2012 13:05:39 GMT (envelope-from glebius@svn.freebsd.org) Message-Id: <201209171305.q8HD5d9F020502@svn.freebsd.org> From: Gleb Smirnoff Date: Mon, 17 Sep 2012 13:05:39 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r240603 - stable/9/lib/libc/locale X-BeenThere: svn-src-stable@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for all the -stable branches of the src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 17 Sep 2012 13:05:39 -0000 Author: glebius Date: Mon Sep 17 13:05:39 2012 New Revision: 240603 URL: http://svn.freebsd.org/changeset/base/240603 Log: Merge r238182 by theraven@: Restore the __collate_load_error global that was accidentally removed in the xlocale refactoring. Modified: stable/9/lib/libc/locale/collate.c stable/9/lib/libc/locale/setrunelocale.c Directory Properties: stable/9/lib/libc/ (props changed) Modified: stable/9/lib/libc/locale/collate.c ============================================================================== --- stable/9/lib/libc/locale/collate.c Mon Sep 17 12:51:48 2012 (r240602) +++ stable/9/lib/libc/locale/collate.c Mon Sep 17 13:05:39 2012 (r240603) @@ -56,11 +56,11 @@ __FBSDID("$FreeBSD$"); * We also modify the collation table test functions to search the thread-local * table first and the global table second. */ -#define __collate_load_error (table->__collate_load_error) #define __collate_substitute_nontrivial (table->__collate_substitute_nontrivial) #define __collate_substitute_table_ptr (table->__collate_substitute_table_ptr) #define __collate_char_pri_table_ptr (table->__collate_char_pri_table_ptr) #define __collate_chain_pri_table (table->__collate_chain_pri_table) +int __collate_load_error; struct xlocale_collate __xlocale_global_collate = { @@ -109,7 +109,9 @@ __collate_load(const char *encoding, loc int __collate_load_tables(const char *encoding) { - return __collate_load_tables_l(encoding, &__xlocale_global_collate); + int ret = __collate_load_tables_l(encoding, &__xlocale_global_collate); + __collate_load_error = __xlocale_global_collate.__collate_load_error; + return ret; } int @@ -123,7 +125,7 @@ __collate_load_tables_l(const char *enco /* 'encoding' must be already checked. */ if (strcmp(encoding, "C") == 0 || strcmp(encoding, "POSIX") == 0) { - __collate_load_error = 1; + table->__collate_load_error = 1; return (_LDP_CACHE); } @@ -240,7 +242,7 @@ __collate_load_tables_l(const char *enco break; } } - __collate_load_error = 0; + table->__collate_load_error = 0; return (_LDP_LOADED); } Modified: stable/9/lib/libc/locale/setrunelocale.c ============================================================================== --- stable/9/lib/libc/locale/setrunelocale.c Mon Sep 17 12:51:48 2012 (r240602) +++ stable/9/lib/libc/locale/setrunelocale.c Mon Sep 17 13:05:39 2012 (r240603) @@ -67,7 +67,6 @@ extern _RuneLocale *_Read_RuneMagi(FILE static int __setrunelocale(struct xlocale_ctype *l, const char *); -#define __collate_load_error (table->__collate_load_error) #define __collate_substitute_nontrivial (table->__collate_substitute_nontrivial) #define __collate_substitute_table_ptr (table->__collate_substitute_table_ptr) #define __collate_char_pri_table_ptr (table->__collate_char_pri_table_ptr) From owner-svn-src-stable@FreeBSD.ORG Mon Sep 17 13:06:48 2012 Return-Path: Delivered-To: svn-src-stable@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id BE705106566C; Mon, 17 Sep 2012 13:06:48 +0000 (UTC) (envelope-from glebius@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 8FCEC8FC17; Mon, 17 Sep 2012 13:06:48 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q8HD6mPf020773; Mon, 17 Sep 2012 13:06:48 GMT (envelope-from glebius@svn.freebsd.org) Received: (from glebius@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q8HD6mJJ020770; Mon, 17 Sep 2012 13:06:48 GMT (envelope-from glebius@svn.freebsd.org) Message-Id: <201209171306.q8HD6mJJ020770@svn.freebsd.org> From: Gleb Smirnoff Date: Mon, 17 Sep 2012 13:06:48 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r240604 - in stable/9/sys/geom: mirror raid3 X-BeenThere: svn-src-stable@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for all the -stable branches of the src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 17 Sep 2012 13:06:48 -0000 Author: glebius Date: Mon Sep 17 13:06:47 2012 New Revision: 240604 URL: http://svn.freebsd.org/changeset/base/240604 Log: Merge r240371: When synchronizing, include in the config dump amount of bytes syncronized. The rationale behind this is the following: for large disks the percent synchronisation counter ticks too seldom, and monitoring software (as well as human operator) can't tell whether synchronisation goes on or one of disks got stuck. On an idle server one can look into gstat and see whether synchronisation goes on or not, but on a busy server that won't work. Also, new value monitored can be differentiated obtaining the synchronisation speed quite precisely. Submitted by: Konstantin Kukushkin Reviewed by: pjd Modified: stable/9/sys/geom/mirror/g_mirror.c stable/9/sys/geom/raid3/g_raid3.c Directory Properties: stable/9/sys/ (props changed) Modified: stable/9/sys/geom/mirror/g_mirror.c ============================================================================== --- stable/9/sys/geom/mirror/g_mirror.c Mon Sep 17 13:05:39 2012 (r240603) +++ stable/9/sys/geom/mirror/g_mirror.c Mon Sep 17 13:06:47 2012 (r240604) @@ -3143,6 +3143,11 @@ g_mirror_dumpconf(struct sbuf *sb, const sc->sc_provider->mediasize)); } sbuf_printf(sb, "\n"); + if (disk->d_sync.ds_offset > 0) { + sbuf_printf(sb, "%s%jd" + "\n", indent, + (intmax_t)disk->d_sync.ds_offset); + } } sbuf_printf(sb, "%s%u\n", indent, disk->d_sync.ds_syncid); Modified: stable/9/sys/geom/raid3/g_raid3.c ============================================================================== --- stable/9/sys/geom/raid3/g_raid3.c Mon Sep 17 13:05:39 2012 (r240603) +++ stable/9/sys/geom/raid3/g_raid3.c Mon Sep 17 13:06:47 2012 (r240604) @@ -3447,6 +3447,11 @@ g_raid3_dumpconf(struct sbuf *sb, const (sc->sc_mediasize / (sc->sc_ndisks - 1)))); } sbuf_printf(sb, "\n"); + if (disk->d_sync.ds_offset > 0) { + sbuf_printf(sb, "%s%jd" + "\n", indent, + (intmax_t)disk->d_sync.ds_offset); + } } sbuf_printf(sb, "%s%u\n", indent, disk->d_sync.ds_syncid); From owner-svn-src-stable@FreeBSD.ORG Mon Sep 17 14:53:34 2012 Return-Path: Delivered-To: svn-src-stable@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 1A0AE1065672; Mon, 17 Sep 2012 14:53:34 +0000 (UTC) (envelope-from trociny@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 0439C8FC0A; Mon, 17 Sep 2012 14:53:34 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q8HErXRv039191; Mon, 17 Sep 2012 14:53:33 GMT (envelope-from trociny@svn.freebsd.org) Received: (from trociny@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q8HErXIm039189; Mon, 17 Sep 2012 14:53:33 GMT (envelope-from trociny@svn.freebsd.org) Message-Id: <201209171453.q8HErXIm039189@svn.freebsd.org> From: Mikolaj Golub Date: Mon, 17 Sep 2012 14:53:33 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r240606 - stable/9/sys/kern X-BeenThere: svn-src-stable@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for all the -stable branches of the src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 17 Sep 2012 14:53:34 -0000 Author: trociny Date: Mon Sep 17 14:53:33 2012 New Revision: 240606 URL: http://svn.freebsd.org/changeset/base/240606 Log: MFC r240003, r240004: r240003: In soreceive_generic() when checking if the type of mbuf has changed check it for MT_CONTROL type too, otherwise the assertion "m->m_type == MT_DATA" below may be triggered by the following scenario: - the sender sends some data (MT_DATA) and then a file descriptor (MT_CONTROL); - the receiver calls recv(2) with a MSG_WAITALL asking for data larger than the receive buffer (uio_resid > hiwat). r240004: In soreceive_generic() remove the optimization for the case when MSG_WAITALL is set, and it is possible to do the entire receive operation at once if we block (resid <= hiwat). Actually it might make the recv(2) with MSG_WAITALL flag get stuck when there is enough space in the receiver buffer to satisfy the request but not enough to open the window closed previously due to the buffer being full. The issue can be reproduced using the following scenario: On the sender side do 2 send(2) requests: 1) data of size much smaller than SOBUF_SIZE (e.g. SOBUF_SIZE / 10); 2) data of size equal to SOBUF_SIZE. On the receiver side do 2 recv(2) requests with MSG_WAITALL flag set: 1) recv() data of SOBUF_SIZE / 10 size; 2) recv() data of SOBUF_SIZE size; We totally fill the receiver buffer with one SOBUF_SIZE/10 size request and partial SOBUF_SIZE request. When the first request is processed we get SOBUF_SIZE/10 free space. It is just enough to receive the rest of bytes for the second request, and soreceive_generic() blocks in the part that is a subject of this change waiting for the rest. But the window was closed when the buffer was filled and to avoid silly window syndrome it opens only when available space is larger than sb_hiwat/4 or maxseg. So it is stuck and pending data is only sent via TCP window probes. Discussed with: kib (long ago) Modified: stable/9/sys/kern/uipc_socket.c Directory Properties: stable/9/sys/ (props changed) Modified: stable/9/sys/kern/uipc_socket.c ============================================================================== --- stable/9/sys/kern/uipc_socket.c Mon Sep 17 13:36:47 2012 (r240605) +++ stable/9/sys/kern/uipc_socket.c Mon Sep 17 14:53:33 2012 (r240606) @@ -1496,17 +1496,11 @@ restart: * If we have less data than requested, block awaiting more (subject * to any timeout) if: * 1. the current count is less than the low water mark, or - * 2. MSG_WAITALL is set, and it is possible to do the entire - * receive operation at once if we block (resid <= hiwat). - * 3. MSG_DONTWAIT is not set - * If MSG_WAITALL is set but resid is larger than the receive buffer, - * we have to do the receive in sections, and thus risk returning a - * short count if a timeout or signal occurs after we start. + * 2. MSG_DONTWAIT is not set */ if (m == NULL || (((flags & MSG_DONTWAIT) == 0 && so->so_rcv.sb_cc < uio->uio_resid) && - (so->so_rcv.sb_cc < so->so_rcv.sb_lowat || - ((flags & MSG_WAITALL) && uio->uio_resid <= so->so_rcv.sb_hiwat)) && + so->so_rcv.sb_cc < so->so_rcv.sb_lowat && m->m_nextpkt == NULL && (pr->pr_flags & PR_ATOMIC) == 0)) { KASSERT(m != NULL || !so->so_rcv.sb_cc, ("receive: m == %p so->so_rcv.sb_cc == %u", @@ -1695,8 +1689,8 @@ dontblock: * examined ('type'), end the receive operation. */ SOCKBUF_LOCK_ASSERT(&so->so_rcv); - if (m->m_type == MT_OOBDATA) { - if (type != MT_OOBDATA) + if (m->m_type == MT_OOBDATA || m->m_type == MT_CONTROL) { + if (type != m->m_type) break; } else if (type == MT_OOBDATA) break; From owner-svn-src-stable@FreeBSD.ORG Mon Sep 17 14:54:59 2012 Return-Path: Delivered-To: svn-src-stable@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 63C571065677; Mon, 17 Sep 2012 14:54:59 +0000 (UTC) (envelope-from trociny@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 4F25A8FC14; Mon, 17 Sep 2012 14:54:59 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q8HEsxjp039406; Mon, 17 Sep 2012 14:54:59 GMT (envelope-from trociny@svn.freebsd.org) Received: (from trociny@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q8HEsxEJ039404; Mon, 17 Sep 2012 14:54:59 GMT (envelope-from trociny@svn.freebsd.org) Message-Id: <201209171454.q8HEsxEJ039404@svn.freebsd.org> From: Mikolaj Golub Date: Mon, 17 Sep 2012 14:54:59 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-8@freebsd.org X-SVN-Group: stable-8 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r240607 - stable/8/sys/kern X-BeenThere: svn-src-stable@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for all the -stable branches of the src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 17 Sep 2012 14:54:59 -0000 Author: trociny Date: Mon Sep 17 14:54:58 2012 New Revision: 240607 URL: http://svn.freebsd.org/changeset/base/240607 Log: MFC r240003, r240004: r240003: In soreceive_generic() when checking if the type of mbuf has changed check it for MT_CONTROL type too, otherwise the assertion "m->m_type == MT_DATA" below may be triggered by the following scenario: - the sender sends some data (MT_DATA) and then a file descriptor (MT_CONTROL); - the receiver calls recv(2) with a MSG_WAITALL asking for data larger than the receive buffer (uio_resid > hiwat). r240004: In soreceive_generic() remove the optimization for the case when MSG_WAITALL is set, and it is possible to do the entire receive operation at once if we block (resid <= hiwat). Actually it might make the recv(2) with MSG_WAITALL flag get stuck when there is enough space in the receiver buffer to satisfy the request but not enough to open the window closed previously due to the buffer being full. The issue can be reproduced using the following scenario: On the sender side do 2 send(2) requests: 1) data of size much smaller than SOBUF_SIZE (e.g. SOBUF_SIZE / 10); 2) data of size equal to SOBUF_SIZE. On the receiver side do 2 recv(2) requests with MSG_WAITALL flag set: 1) recv() data of SOBUF_SIZE / 10 size; 2) recv() data of SOBUF_SIZE size; We totally fill the receiver buffer with one SOBUF_SIZE/10 size request and partial SOBUF_SIZE request. When the first request is processed we get SOBUF_SIZE/10 free space. It is just enough to receive the rest of bytes for the second request, and soreceive_generic() blocks in the part that is a subject of this change waiting for the rest. But the window was closed when the buffer was filled and to avoid silly window syndrome it opens only when available space is larger than sb_hiwat/4 or maxseg. So it is stuck and pending data is only sent via TCP window probes. Discussed with: kib (long ago) Modified: stable/8/sys/kern/uipc_socket.c Directory Properties: stable/8/sys/ (props changed) stable/8/sys/kern/ (props changed) Modified: stable/8/sys/kern/uipc_socket.c ============================================================================== --- stable/8/sys/kern/uipc_socket.c Mon Sep 17 14:53:33 2012 (r240606) +++ stable/8/sys/kern/uipc_socket.c Mon Sep 17 14:54:58 2012 (r240607) @@ -1483,17 +1483,11 @@ restart: * If we have less data than requested, block awaiting more (subject * to any timeout) if: * 1. the current count is less than the low water mark, or - * 2. MSG_WAITALL is set, and it is possible to do the entire - * receive operation at once if we block (resid <= hiwat). - * 3. MSG_DONTWAIT is not set - * If MSG_WAITALL is set but resid is larger than the receive buffer, - * we have to do the receive in sections, and thus risk returning a - * short count if a timeout or signal occurs after we start. + * 2. MSG_DONTWAIT is not set */ if (m == NULL || (((flags & MSG_DONTWAIT) == 0 && so->so_rcv.sb_cc < uio->uio_resid) && - (so->so_rcv.sb_cc < so->so_rcv.sb_lowat || - ((flags & MSG_WAITALL) && uio->uio_resid <= so->so_rcv.sb_hiwat)) && + so->so_rcv.sb_cc < so->so_rcv.sb_lowat && m->m_nextpkt == NULL && (pr->pr_flags & PR_ATOMIC) == 0)) { KASSERT(m != NULL || !so->so_rcv.sb_cc, ("receive: m == %p so->so_rcv.sb_cc == %u", @@ -1682,8 +1676,8 @@ dontblock: * examined ('type'), end the receive operation. */ SOCKBUF_LOCK_ASSERT(&so->so_rcv); - if (m->m_type == MT_OOBDATA) { - if (type != MT_OOBDATA) + if (m->m_type == MT_OOBDATA || m->m_type == MT_CONTROL) { + if (type != m->m_type) break; } else if (type == MT_OOBDATA) break; From owner-svn-src-stable@FreeBSD.ORG Mon Sep 17 15:45:28 2012 Return-Path: Delivered-To: svn-src-stable@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 5E6D1106566C; Mon, 17 Sep 2012 15:45:28 +0000 (UTC) (envelope-from gjb@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 492EE8FC14; Mon, 17 Sep 2012 15:45:28 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q8HFjSZ3046170; Mon, 17 Sep 2012 15:45:28 GMT (envelope-from gjb@svn.freebsd.org) Received: (from gjb@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q8HFjSGb046167; Mon, 17 Sep 2012 15:45:28 GMT (envelope-from gjb@svn.freebsd.org) Message-Id: <201209171545.q8HFjSGb046167@svn.freebsd.org> From: Glen Barber Date: Mon, 17 Sep 2012 15:45:28 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r240610 - stable/9/release X-BeenThere: svn-src-stable@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for all the -stable branches of the src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 17 Sep 2012 15:45:28 -0000 Author: gjb (doc,ports committer) Date: Mon Sep 17 15:45:27 2012 New Revision: 240610 URL: http://svn.freebsd.org/changeset/base/240610 Log: MFC r232714 (nwhitehorn): Make sure not to tar up CVS directories if this ports tree is a CVS checkout. PR: bin/165868 Modified: stable/9/release/Makefile Directory Properties: stable/9/release/ (props changed) Modified: stable/9/release/Makefile ============================================================================== --- stable/9/release/Makefile Mon Sep 17 15:43:57 2012 (r240609) +++ stable/9/release/Makefile Mon Sep 17 15:45:27 2012 (r240610) @@ -87,6 +87,7 @@ ports.txz: -mkdir -p ${DISTDIR}/usr ln -fs ${PORTSDIR} ${DISTDIR}/usr/ports cd ${DISTDIR} && tar cLvJf ${.OBJDIR}/ports.txz \ + --exclude CVS --exclude .svn \ --exclude usr/ports/distfiles --exclude usr/ports/packages \ --exclude 'usr/ports/INDEX*' --exclude work usr/ports From owner-svn-src-stable@FreeBSD.ORG Mon Sep 17 15:48:43 2012 Return-Path: Delivered-To: svn-src-stable@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 505D91065670; Mon, 17 Sep 2012 15:48:43 +0000 (UTC) (envelope-from gjb@FreeBSD.org) Received: from onyx.glenbarber.us (onyx.glenbarber.us [IPv6:2607:fc50:1000:c200::face]) by mx1.freebsd.org (Postfix) with ESMTP id E17668FC18; Mon, 17 Sep 2012 15:48:42 +0000 (UTC) Received: from glenbarber.us (75-146-225-65-Philadelphia.hfc.comcastbusiness.net [75.146.225.65]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (No client certificate requested) (Authenticated sender: gjb) by onyx.glenbarber.us (Postfix) with ESMTPSA id 27E8323F6D9; Mon, 17 Sep 2012 11:48:42 -0400 (EDT) Date: Mon, 17 Sep 2012 11:48:40 -0400 From: Glen Barber To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org Message-ID: <20120917154840.GF1295@glenbarber.us> References: <201209171545.q8HFjSGb046167@svn.freebsd.org> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha256; protocol="application/pgp-signature"; boundary="wj9ZLJVQDRFjGSdK" Content-Disposition: inline In-Reply-To: <201209171545.q8HFjSGb046167@svn.freebsd.org> X-Operating-System: FreeBSD 10.0-CURRENT amd64 User-Agent: Mutt/1.5.21 (2010-09-15) Cc: Subject: Re: svn commit: r240610 - stable/9/release X-BeenThere: svn-src-stable@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for all the -stable branches of the src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 17 Sep 2012 15:48:43 -0000 --wj9ZLJVQDRFjGSdK Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Mon, Sep 17, 2012 at 03:45:28PM +0000, Glen Barber wrote: > Author: gjb (doc,ports committer) > Date: Mon Sep 17 15:45:27 2012 > New Revision: 240610 > URL: http://svn.freebsd.org/changeset/base/240610 >=20 > Log: > MFC r232714 (nwhitehorn): > =20 > Make sure not to tar up CVS directories if this ports tree is a CVS > checkout. > =20 > PR: bin/165868 >=20 Forgot to add: Approved by: nwhitehorn Glen --wj9ZLJVQDRFjGSdK Content-Type: application/pgp-signature -----BEGIN PGP SIGNATURE----- Version: GnuPG v2.0.19 (FreeBSD) iQEcBAEBCAAGBQJQV0ZYAAoJEFJPDDeguUajR5QH/1gaDYfigQk+7X9jLwfEG3hG +4p/i+pvL2v0w1Eysyk/AzqvT/o3ySW5pelLoi004Nmc4xPS2RqsiHDMkTSaUBwn h09C3UZRiEiWsr5XXvJ9/MHD9JfpwhKlYLPRFD1KkOoeHW7htYyz43irWZJbIWis Ash9XJGCQIQa+eJuUCBZFhgkIeYPLZbKBe1SZ2dsG7bHD6GJ7Xi2fC4UjFKZP52v lBVIag3deuD6JMePlcWc/DXo36s/j0DPe+SdTTaaPqefG+xagcess1lFyDTuZ49t Y+IQdD/4y+eBnhmaLcmcy+csOSOA7m2KJCoAkEik4mDztMl7Wxe3rR/Wk1C0GQk= =d2qj -----END PGP SIGNATURE----- --wj9ZLJVQDRFjGSdK-- From owner-svn-src-stable@FreeBSD.ORG Mon Sep 17 16:05:04 2012 Return-Path: Delivered-To: svn-src-stable@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id DC059106566C; Mon, 17 Sep 2012 16:05:03 +0000 (UTC) (envelope-from jimharris@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id C0A718FC0C; Mon, 17 Sep 2012 16:05:03 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q8HG53Wl048881; Mon, 17 Sep 2012 16:05:03 GMT (envelope-from jimharris@svn.freebsd.org) Received: (from jimharris@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q8HG53Hd048878; Mon, 17 Sep 2012 16:05:03 GMT (envelope-from jimharris@svn.freebsd.org) Message-Id: <201209171605.q8HG53Hd048878@svn.freebsd.org> From: Jim Harris Date: Mon, 17 Sep 2012 16:05:03 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r240611 - stable/9/sys/dev/isci/scil X-BeenThere: svn-src-stable@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for all the -stable branches of the src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 17 Sep 2012 16:05:04 -0000 Author: jimharris Date: Mon Sep 17 16:05:03 2012 New Revision: 240611 URL: http://svn.freebsd.org/changeset/base/240611 Log: MFC r240514: isci(4): Fix SCSI/ATA translation for SCSI_WRITE_BUFFER w/ mode==0x7 (download microcode with offsets, save, and activate). SATI translation layer was incorrectly using allocation length instead of blocks, and was constructing the ATA command incorrectly. Also change #define to specify that the 512 block size here is specific for DOWNLOAD_MICROCODE, and does not relate to the device's logical block size. Modified: stable/9/sys/dev/isci/scil/sati_util.c stable/9/sys/dev/isci/scil/sati_write_buffer.c Directory Properties: stable/9/sys/ (props changed) stable/9/sys/dev/ (props changed) Modified: stable/9/sys/dev/isci/scil/sati_util.c ============================================================================== --- stable/9/sys/dev/isci/scil/sati_util.c Mon Sep 17 15:45:27 2012 (r240610) +++ stable/9/sys/dev/isci/scil/sati_util.c Mon Sep 17 16:05:03 2012 (r240611) @@ -1976,6 +1976,8 @@ void sati_ata_download_microcode_constru ) { U8 * register_fis = sati_cb_get_h2d_register_fis_address(ata_io); + U32 allocation_blocks = allocation_length >> 9; + U32 buffer_blkoffset = buffer_offset >> 9; sati_set_ata_command(register_fis, ATA_DOWNLOAD_MICROCODE); sati_set_ata_features(register_fis, mode); @@ -1987,9 +1989,10 @@ void sati_ata_download_microcode_constru } else //mode == 0x03 { - sati_set_ata_sector_count(register_fis, (U8) (allocation_length >> 9)); - sati_set_ata_lba_low(register_fis, (U8) (allocation_length >> 17)); - sati_set_ata_lba_high(register_fis, (U8) (buffer_offset >> 9)); + sati_set_ata_sector_count(register_fis, (U8) (allocation_blocks & 0xff)); + sati_set_ata_lba_low(register_fis, (U8) ((allocation_blocks >> 8) & 0xff)); + sati_set_ata_lba_mid(register_fis, (U8) (buffer_blkoffset & 0xff)); + sati_set_ata_lba_high(register_fis, (U8) ((buffer_blkoffset >> 8) & 0xff)); } if((allocation_length == 0) && (buffer_offset == 0)) Modified: stable/9/sys/dev/isci/scil/sati_write_buffer.c ============================================================================== --- stable/9/sys/dev/isci/scil/sati_write_buffer.c Mon Sep 17 15:45:27 2012 (r240610) +++ stable/9/sys/dev/isci/scil/sati_write_buffer.c Mon Sep 17 16:05:03 2012 (r240611) @@ -66,7 +66,7 @@ __FBSDID("$FreeBSD$"); #define WRITE_BUFFER_WRITE_DATA 0x02 #define WRITE_BUFFER_DOWNLOAD_SAVE 0x05 #define WRITE_BUFFER_OFFSET_DOWNLOAD_SAVE 0x07 -#define BLOCK_SIZE 512 +#define DOWNLOAD_MICROCODE_BLOCK_SIZE 512 /** * @brief This method will translate the SCSI Write Buffer command @@ -89,6 +89,7 @@ SATI_STATUS sati_write_buffer_translate_ U8 * cdb = sati_cb_get_cdb_address(scsi_io); SATI_STATUS status = SATI_FAILURE; U32 allocation_length; + U32 allocation_blocks; U32 buffer_offset; allocation_length = ((sati_get_cdb_byte(cdb, 6) << 16) | @@ -100,11 +101,13 @@ SATI_STATUS sati_write_buffer_translate_ (sati_get_cdb_byte(cdb, 5))); sequence->allocation_length = allocation_length; + allocation_blocks = allocation_length / DOWNLOAD_MICROCODE_BLOCK_SIZE; switch(sati_get_cdb_byte(cdb, 1)) { case WRITE_BUFFER_WRITE_DATA: - if((allocation_length == BLOCK_SIZE) && (buffer_offset == 0) && + if((allocation_length == DOWNLOAD_MICROCODE_BLOCK_SIZE) && + (buffer_offset == 0) && (sati_get_cdb_byte(cdb, 2) == 0)) { sati_ata_write_buffer_construct(ata_io, sequence); @@ -146,8 +149,9 @@ SATI_STATUS sati_write_buffer_translate_ case WRITE_BUFFER_OFFSET_DOWNLOAD_SAVE: if(((allocation_length & 0x000001FF) == 0) && //Bits 08:00 need to be zero per SAT2v7 ((buffer_offset & 0x000001FF) == 0) && - (allocation_length <= sequence->device->max_blocks_per_microcode_command) && - (allocation_length >= sequence->device->min_blocks_per_microcode_command)) + (allocation_blocks <= sequence->device->max_blocks_per_microcode_command) && + ((allocation_blocks >= sequence->device->min_blocks_per_microcode_command) || + (allocation_length == 0))) { sati_ata_download_microcode_construct( ata_io, From owner-svn-src-stable@FreeBSD.ORG Mon Sep 17 16:11:23 2012 Return-Path: Delivered-To: svn-src-stable@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 058A11065670; Mon, 17 Sep 2012 16:11:23 +0000 (UTC) (envelope-from jimharris@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id E3D528FC0A; Mon, 17 Sep 2012 16:11:22 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q8HGBMaF049781; Mon, 17 Sep 2012 16:11:22 GMT (envelope-from jimharris@svn.freebsd.org) Received: (from jimharris@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q8HGBMlU049778; Mon, 17 Sep 2012 16:11:22 GMT (envelope-from jimharris@svn.freebsd.org) Message-Id: <201209171611.q8HGBMlU049778@svn.freebsd.org> From: Jim Harris Date: Mon, 17 Sep 2012 16:11:22 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-8@freebsd.org X-SVN-Group: stable-8 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r240612 - stable/8/sys/dev/isci/scil X-BeenThere: svn-src-stable@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for all the -stable branches of the src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 17 Sep 2012 16:11:23 -0000 Author: jimharris Date: Mon Sep 17 16:11:22 2012 New Revision: 240612 URL: http://svn.freebsd.org/changeset/base/240612 Log: MFC r240514: isci(4): Fix SCSI/ATA translation for SCSI_WRITE_BUFFER w/ mode==0x7 (download microcode with offsets, save, and activate). SATI translation layer was incorrectly using allocation length instead of blocks, and was constructing the ATA command incorrectly. Also change #define to specify that the 512 block size here is specific for DOWNLOAD_MICROCODE, and does not relate to the device's logical block size. Modified: stable/8/sys/dev/isci/scil/sati_util.c stable/8/sys/dev/isci/scil/sati_write_buffer.c Directory Properties: stable/8/sys/ (props changed) stable/8/sys/dev/ (props changed) stable/8/sys/dev/isci/ (props changed) Modified: stable/8/sys/dev/isci/scil/sati_util.c ============================================================================== --- stable/8/sys/dev/isci/scil/sati_util.c Mon Sep 17 16:05:03 2012 (r240611) +++ stable/8/sys/dev/isci/scil/sati_util.c Mon Sep 17 16:11:22 2012 (r240612) @@ -1976,6 +1976,8 @@ void sati_ata_download_microcode_constru ) { U8 * register_fis = sati_cb_get_h2d_register_fis_address(ata_io); + U32 allocation_blocks = allocation_length >> 9; + U32 buffer_blkoffset = buffer_offset >> 9; sati_set_ata_command(register_fis, ATA_DOWNLOAD_MICROCODE); sati_set_ata_features(register_fis, mode); @@ -1987,9 +1989,10 @@ void sati_ata_download_microcode_constru } else //mode == 0x03 { - sati_set_ata_sector_count(register_fis, (U8) (allocation_length >> 9)); - sati_set_ata_lba_low(register_fis, (U8) (allocation_length >> 17)); - sati_set_ata_lba_high(register_fis, (U8) (buffer_offset >> 9)); + sati_set_ata_sector_count(register_fis, (U8) (allocation_blocks & 0xff)); + sati_set_ata_lba_low(register_fis, (U8) ((allocation_blocks >> 8) & 0xff)); + sati_set_ata_lba_mid(register_fis, (U8) (buffer_blkoffset & 0xff)); + sati_set_ata_lba_high(register_fis, (U8) ((buffer_blkoffset >> 8) & 0xff)); } if((allocation_length == 0) && (buffer_offset == 0)) Modified: stable/8/sys/dev/isci/scil/sati_write_buffer.c ============================================================================== --- stable/8/sys/dev/isci/scil/sati_write_buffer.c Mon Sep 17 16:05:03 2012 (r240611) +++ stable/8/sys/dev/isci/scil/sati_write_buffer.c Mon Sep 17 16:11:22 2012 (r240612) @@ -66,7 +66,7 @@ __FBSDID("$FreeBSD$"); #define WRITE_BUFFER_WRITE_DATA 0x02 #define WRITE_BUFFER_DOWNLOAD_SAVE 0x05 #define WRITE_BUFFER_OFFSET_DOWNLOAD_SAVE 0x07 -#define BLOCK_SIZE 512 +#define DOWNLOAD_MICROCODE_BLOCK_SIZE 512 /** * @brief This method will translate the SCSI Write Buffer command @@ -89,6 +89,7 @@ SATI_STATUS sati_write_buffer_translate_ U8 * cdb = sati_cb_get_cdb_address(scsi_io); SATI_STATUS status = SATI_FAILURE; U32 allocation_length; + U32 allocation_blocks; U32 buffer_offset; allocation_length = ((sati_get_cdb_byte(cdb, 6) << 16) | @@ -100,11 +101,13 @@ SATI_STATUS sati_write_buffer_translate_ (sati_get_cdb_byte(cdb, 5))); sequence->allocation_length = allocation_length; + allocation_blocks = allocation_length / DOWNLOAD_MICROCODE_BLOCK_SIZE; switch(sati_get_cdb_byte(cdb, 1)) { case WRITE_BUFFER_WRITE_DATA: - if((allocation_length == BLOCK_SIZE) && (buffer_offset == 0) && + if((allocation_length == DOWNLOAD_MICROCODE_BLOCK_SIZE) && + (buffer_offset == 0) && (sati_get_cdb_byte(cdb, 2) == 0)) { sati_ata_write_buffer_construct(ata_io, sequence); @@ -146,8 +149,9 @@ SATI_STATUS sati_write_buffer_translate_ case WRITE_BUFFER_OFFSET_DOWNLOAD_SAVE: if(((allocation_length & 0x000001FF) == 0) && //Bits 08:00 need to be zero per SAT2v7 ((buffer_offset & 0x000001FF) == 0) && - (allocation_length <= sequence->device->max_blocks_per_microcode_command) && - (allocation_length >= sequence->device->min_blocks_per_microcode_command)) + (allocation_blocks <= sequence->device->max_blocks_per_microcode_command) && + ((allocation_blocks >= sequence->device->min_blocks_per_microcode_command) || + (allocation_length == 0))) { sati_ata_download_microcode_construct( ata_io, From owner-svn-src-stable@FreeBSD.ORG Mon Sep 17 16:12:54 2012 Return-Path: Delivered-To: svn-src-stable@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 56817106564A; Mon, 17 Sep 2012 16:12:54 +0000 (UTC) (envelope-from jimharris@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 412DC8FC20; Mon, 17 Sep 2012 16:12:54 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q8HGCssu050021; Mon, 17 Sep 2012 16:12:54 GMT (envelope-from jimharris@svn.freebsd.org) Received: (from jimharris@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q8HGCscS050018; Mon, 17 Sep 2012 16:12:54 GMT (envelope-from jimharris@svn.freebsd.org) Message-Id: <201209171612.q8HGCscS050018@svn.freebsd.org> From: Jim Harris Date: Mon, 17 Sep 2012 16:12:54 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-7@freebsd.org X-SVN-Group: stable-7 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r240613 - stable/7/sys/dev/isci/scil X-BeenThere: svn-src-stable@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for all the -stable branches of the src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 17 Sep 2012 16:12:54 -0000 Author: jimharris Date: Mon Sep 17 16:12:53 2012 New Revision: 240613 URL: http://svn.freebsd.org/changeset/base/240613 Log: MFC r240514: isci(4): Fix SCSI/ATA translation for SCSI_WRITE_BUFFER w/ mode==0x7 (download microcode with offsets, save, and activate). SATI translation layer was incorrectly using allocation length instead of blocks, and was constructing the ATA command incorrectly. Also change #define to specify that the 512 block size here is specific for DOWNLOAD_MICROCODE, and does not relate to the device's logical block size. Modified: stable/7/sys/dev/isci/scil/sati_util.c stable/7/sys/dev/isci/scil/sati_write_buffer.c Directory Properties: stable/7/sys/ (props changed) Modified: stable/7/sys/dev/isci/scil/sati_util.c ============================================================================== --- stable/7/sys/dev/isci/scil/sati_util.c Mon Sep 17 16:11:22 2012 (r240612) +++ stable/7/sys/dev/isci/scil/sati_util.c Mon Sep 17 16:12:53 2012 (r240613) @@ -1976,6 +1976,8 @@ void sati_ata_download_microcode_constru ) { U8 * register_fis = sati_cb_get_h2d_register_fis_address(ata_io); + U32 allocation_blocks = allocation_length >> 9; + U32 buffer_blkoffset = buffer_offset >> 9; sati_set_ata_command(register_fis, ATA_DOWNLOAD_MICROCODE); sati_set_ata_features(register_fis, mode); @@ -1987,9 +1989,10 @@ void sati_ata_download_microcode_constru } else //mode == 0x03 { - sati_set_ata_sector_count(register_fis, (U8) (allocation_length >> 9)); - sati_set_ata_lba_low(register_fis, (U8) (allocation_length >> 17)); - sati_set_ata_lba_high(register_fis, (U8) (buffer_offset >> 9)); + sati_set_ata_sector_count(register_fis, (U8) (allocation_blocks & 0xff)); + sati_set_ata_lba_low(register_fis, (U8) ((allocation_blocks >> 8) & 0xff)); + sati_set_ata_lba_mid(register_fis, (U8) (buffer_blkoffset & 0xff)); + sati_set_ata_lba_high(register_fis, (U8) ((buffer_blkoffset >> 8) & 0xff)); } if((allocation_length == 0) && (buffer_offset == 0)) Modified: stable/7/sys/dev/isci/scil/sati_write_buffer.c ============================================================================== --- stable/7/sys/dev/isci/scil/sati_write_buffer.c Mon Sep 17 16:11:22 2012 (r240612) +++ stable/7/sys/dev/isci/scil/sati_write_buffer.c Mon Sep 17 16:12:53 2012 (r240613) @@ -66,7 +66,7 @@ __FBSDID("$FreeBSD$"); #define WRITE_BUFFER_WRITE_DATA 0x02 #define WRITE_BUFFER_DOWNLOAD_SAVE 0x05 #define WRITE_BUFFER_OFFSET_DOWNLOAD_SAVE 0x07 -#define BLOCK_SIZE 512 +#define DOWNLOAD_MICROCODE_BLOCK_SIZE 512 /** * @brief This method will translate the SCSI Write Buffer command @@ -89,6 +89,7 @@ SATI_STATUS sati_write_buffer_translate_ U8 * cdb = sati_cb_get_cdb_address(scsi_io); SATI_STATUS status = SATI_FAILURE; U32 allocation_length; + U32 allocation_blocks; U32 buffer_offset; allocation_length = ((sati_get_cdb_byte(cdb, 6) << 16) | @@ -100,11 +101,13 @@ SATI_STATUS sati_write_buffer_translate_ (sati_get_cdb_byte(cdb, 5))); sequence->allocation_length = allocation_length; + allocation_blocks = allocation_length / DOWNLOAD_MICROCODE_BLOCK_SIZE; switch(sati_get_cdb_byte(cdb, 1)) { case WRITE_BUFFER_WRITE_DATA: - if((allocation_length == BLOCK_SIZE) && (buffer_offset == 0) && + if((allocation_length == DOWNLOAD_MICROCODE_BLOCK_SIZE) && + (buffer_offset == 0) && (sati_get_cdb_byte(cdb, 2) == 0)) { sati_ata_write_buffer_construct(ata_io, sequence); @@ -146,8 +149,9 @@ SATI_STATUS sati_write_buffer_translate_ case WRITE_BUFFER_OFFSET_DOWNLOAD_SAVE: if(((allocation_length & 0x000001FF) == 0) && //Bits 08:00 need to be zero per SAT2v7 ((buffer_offset & 0x000001FF) == 0) && - (allocation_length <= sequence->device->max_blocks_per_microcode_command) && - (allocation_length >= sequence->device->min_blocks_per_microcode_command)) + (allocation_blocks <= sequence->device->max_blocks_per_microcode_command) && + ((allocation_blocks >= sequence->device->min_blocks_per_microcode_command) || + (allocation_length == 0))) { sati_ata_download_microcode_construct( ata_io, From owner-svn-src-stable@FreeBSD.ORG Tue Sep 18 02:14:48 2012 Return-Path: Delivered-To: svn-src-stable@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 2C106106566C; Tue, 18 Sep 2012 02:14:48 +0000 (UTC) (envelope-from kevlo@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 16D938FC14; Tue, 18 Sep 2012 02:14:48 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q8I2ElYv020694; Tue, 18 Sep 2012 02:14:47 GMT (envelope-from kevlo@svn.freebsd.org) Received: (from kevlo@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q8I2El0h020692; Tue, 18 Sep 2012 02:14:47 GMT (envelope-from kevlo@svn.freebsd.org) Message-Id: <201209180214.q8I2El0h020692@svn.freebsd.org> From: Kevin Lo Date: Tue, 18 Sep 2012 02:14:47 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r240626 - stable/9/usr.sbin/timed/timed X-BeenThere: svn-src-stable@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for all the -stable branches of the src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 18 Sep 2012 02:14:48 -0000 Author: kevlo Date: Tue Sep 18 02:14:47 2012 New Revision: 240626 URL: http://svn.freebsd.org/changeset/base/240626 Log: MFC r240388: Add missing braces Obtained from: DragonFly Modified: stable/9/usr.sbin/timed/timed/timed.c Directory Properties: stable/9/usr.sbin/timed/timed/ (props changed) Modified: stable/9/usr.sbin/timed/timed/timed.c ============================================================================== --- stable/9/usr.sbin/timed/timed/timed.c Tue Sep 18 01:27:24 2012 (r240625) +++ stable/9/usr.sbin/timed/timed/timed.c Tue Sep 18 02:14:47 2012 (r240626) @@ -419,9 +419,10 @@ main(argc, argv) justquit = 1; } for (ntp = nettab; ntp != NULL; ntp = ntp->next) { - if (ntp->status == MASTER) + if (ntp->status == MASTER) { rmnetmachs(ntp); ntp->status = NOMASTER; + } } checkignorednets(); pickslavenet(0); From owner-svn-src-stable@FreeBSD.ORG Tue Sep 18 08:27:02 2012 Return-Path: Delivered-To: svn-src-stable@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 449EE1065676; Tue, 18 Sep 2012 08:27:02 +0000 (UTC) (envelope-from avg@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 2F5F18FC1D; Tue, 18 Sep 2012 08:27:02 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q8I8R21j056375; Tue, 18 Sep 2012 08:27:02 GMT (envelope-from avg@svn.freebsd.org) Received: (from avg@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q8I8R1eF056373; Tue, 18 Sep 2012 08:27:01 GMT (envelope-from avg@svn.freebsd.org) Message-Id: <201209180827.q8I8R1eF056373@svn.freebsd.org> From: Andriy Gapon Date: Tue, 18 Sep 2012 08:27:01 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r240635 - stable/9/share/man/man4 X-BeenThere: svn-src-stable@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for all the -stable branches of the src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 18 Sep 2012 08:27:02 -0000 Author: avg Date: Tue Sep 18 08:27:01 2012 New Revision: 240635 URL: http://svn.freebsd.org/changeset/base/240635 Log: MFC r240340: acpi.4: machdep.cpu_idle_hlt no longer exists Modified: stable/9/share/man/man4/acpi.4 Directory Properties: stable/9/share/man/man4/ (props changed) Modified: stable/9/share/man/man4/acpi.4 ============================================================================== --- stable/9/share/man/man4/acpi.4 Tue Sep 18 08:17:29 2012 (r240634) +++ stable/9/share/man/man4/acpi.4 Tue Sep 18 08:27:01 2012 (r240635) @@ -80,8 +80,12 @@ A scheduling algorithm will select state and this setting as system load dictates. To enable ACPI CPU idling control, -.Va machdep.cpu_idle_hlt -must be set to 1. +.Va machdep.idle +should be set to +.Li acpi +if it is listed in +.Va machdep.idle_available +. .It Va hw.acpi.cpu.cx_supported List of supported CPU idle states and their transition latency in microseconds. From owner-svn-src-stable@FreeBSD.ORG Tue Sep 18 08:28:09 2012 Return-Path: Delivered-To: svn-src-stable@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 5455E1065711; Tue, 18 Sep 2012 08:28:09 +0000 (UTC) (envelope-from avg@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 3FC978FC18; Tue, 18 Sep 2012 08:28:09 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q8I8S9YP056545; Tue, 18 Sep 2012 08:28:09 GMT (envelope-from avg@svn.freebsd.org) Received: (from avg@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q8I8S99Y056543; Tue, 18 Sep 2012 08:28:09 GMT (envelope-from avg@svn.freebsd.org) Message-Id: <201209180828.q8I8S99Y056543@svn.freebsd.org> From: Andriy Gapon Date: Tue, 18 Sep 2012 08:28:09 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-8@freebsd.org X-SVN-Group: stable-8 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r240636 - stable/8/share/man/man4 X-BeenThere: svn-src-stable@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for all the -stable branches of the src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 18 Sep 2012 08:28:09 -0000 Author: avg Date: Tue Sep 18 08:28:08 2012 New Revision: 240636 URL: http://svn.freebsd.org/changeset/base/240636 Log: MFC r240340: acpi.4: machdep.cpu_idle_hlt no longer exists Modified: stable/8/share/man/man4/acpi.4 Directory Properties: stable/8/share/man/man4/ (props changed) Modified: stable/8/share/man/man4/acpi.4 ============================================================================== --- stable/8/share/man/man4/acpi.4 Tue Sep 18 08:27:01 2012 (r240635) +++ stable/8/share/man/man4/acpi.4 Tue Sep 18 08:28:08 2012 (r240636) @@ -80,8 +80,12 @@ A scheduling algorithm will select state and this setting as system load dictates. To enable ACPI CPU idling control, -.Va machdep.cpu_idle_hlt -must be set to 1. +.Va machdep.idle +should be set to +.Li acpi +if it is listed in +.Va machdep.idle_available +. .It Va hw.acpi.cpu.cx_supported List of supported CPU idle states and their transition latency in microseconds. From owner-svn-src-stable@FreeBSD.ORG Tue Sep 18 11:25:05 2012 Return-Path: Delivered-To: svn-src-stable@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 64697106564A; Tue, 18 Sep 2012 11:25:05 +0000 (UTC) (envelope-from gjb@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 49B608FC0C; Tue, 18 Sep 2012 11:25:05 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q8IBP5TJ079867; Tue, 18 Sep 2012 11:25:05 GMT (envelope-from gjb@svn.freebsd.org) Received: (from gjb@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q8IBP57E079865; Tue, 18 Sep 2012 11:25:05 GMT (envelope-from gjb@svn.freebsd.org) Message-Id: <201209181125.q8IBP57E079865@svn.freebsd.org> From: Glen Barber Date: Tue, 18 Sep 2012 11:25:05 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r240643 - stable/9/release/doc/en_US.ISO8859-1/relnotes X-BeenThere: svn-src-stable@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for all the -stable branches of the src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 18 Sep 2012 11:25:05 -0000 Author: gjb (doc,ports committer) Date: Tue Sep 18 11:25:04 2012 New Revision: 240643 URL: http://svn.freebsd.org/changeset/base/240643 Log: Fix release notes build on 9-STABLE. This is a direct commit to stable/9. Modified: stable/9/release/doc/en_US.ISO8859-1/relnotes/article.sgml Modified: stable/9/release/doc/en_US.ISO8859-1/relnotes/article.sgml ============================================================================== --- stable/9/release/doc/en_US.ISO8859-1/relnotes/article.sgml Tue Sep 18 11:07:19 2012 (r240642) +++ stable/9/release/doc/en_US.ISO8859-1/relnotes/article.sgml Tue Sep 18 11:25:04 2012 (r240643) @@ -1264,7 +1264,7 @@ nfsuserd_enable="YES" when a login daemon crashes or fails to remove the entry during shutdown. - The &man.zpool.8: utility now supports a + The &man.zpool.8; utility now supports a zpool labelclear command. This allows to wipe the label data from a drive that is not active in a pool. From owner-svn-src-stable@FreeBSD.ORG Tue Sep 18 13:54:49 2012 Return-Path: Delivered-To: svn-src-stable@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 34169106566B; Tue, 18 Sep 2012 13:54:49 +0000 (UTC) (envelope-from gjb@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 1A07D8FC0A; Tue, 18 Sep 2012 13:54:49 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q8IDsm6P005133; Tue, 18 Sep 2012 13:54:48 GMT (envelope-from gjb@svn.freebsd.org) Received: (from gjb@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q8IDsmcG005106; Tue, 18 Sep 2012 13:54:48 GMT (envelope-from gjb@svn.freebsd.org) Message-Id: <201209181354.q8IDsmcG005106@svn.freebsd.org> From: Glen Barber Date: Tue, 18 Sep 2012 13:54:48 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r240651 - in stable/9/release/doc: de_DE.ISO8859-1/early-adopter de_DE.ISO8859-1/errata de_DE.ISO8859-1/hardware/alpha de_DE.ISO8859-1/hardware/i386 de_DE.ISO8859-1/hardware/ia64 de_DE.... X-BeenThere: svn-src-stable@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for all the -stable branches of the src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 18 Sep 2012 13:54:49 -0000 Author: gjb (doc,ports committer) Date: Tue Sep 18 13:54:48 2012 New Revision: 240651 URL: http://svn.freebsd.org/changeset/base/240651 Log: MFC r240508, r240516, r240519 (gabor): Update stable/9/release/doc files post-XML conversion. This commit fixes most of the 9-STABLE release build problems. Modified: stable/9/release/doc/de_DE.ISO8859-1/early-adopter/article.sgml stable/9/release/doc/de_DE.ISO8859-1/errata/article.sgml stable/9/release/doc/de_DE.ISO8859-1/hardware/alpha/article.sgml stable/9/release/doc/de_DE.ISO8859-1/hardware/i386/article.sgml stable/9/release/doc/de_DE.ISO8859-1/hardware/ia64/article.sgml stable/9/release/doc/de_DE.ISO8859-1/hardware/pc98/article.sgml stable/9/release/doc/de_DE.ISO8859-1/hardware/sparc64/article.sgml stable/9/release/doc/de_DE.ISO8859-1/installation/alpha/article.sgml stable/9/release/doc/de_DE.ISO8859-1/installation/common/install.sgml stable/9/release/doc/de_DE.ISO8859-1/installation/common/layout.sgml stable/9/release/doc/de_DE.ISO8859-1/installation/i386/article.sgml stable/9/release/doc/de_DE.ISO8859-1/installation/ia64/article.sgml stable/9/release/doc/de_DE.ISO8859-1/installation/pc98/article.sgml stable/9/release/doc/de_DE.ISO8859-1/installation/sparc64/article.sgml stable/9/release/doc/de_DE.ISO8859-1/readme/article.sgml stable/9/release/doc/de_DE.ISO8859-1/relnotes/alpha/article.sgml stable/9/release/doc/de_DE.ISO8859-1/relnotes/i386/article.sgml stable/9/release/doc/de_DE.ISO8859-1/relnotes/ia64/article.sgml stable/9/release/doc/de_DE.ISO8859-1/relnotes/pc98/article.sgml stable/9/release/doc/de_DE.ISO8859-1/relnotes/sparc64/article.sgml stable/9/release/doc/en_US.ISO8859-1/errata/article.sgml stable/9/release/doc/en_US.ISO8859-1/hardware/article.sgml stable/9/release/doc/en_US.ISO8859-1/readme/article.sgml stable/9/release/doc/en_US.ISO8859-1/relnotes/article.sgml stable/9/release/doc/fr_FR.ISO8859-1/early-adopter/article.sgml stable/9/release/doc/fr_FR.ISO8859-1/errata/article.sgml stable/9/release/doc/fr_FR.ISO8859-1/hardware/alpha/article.sgml stable/9/release/doc/fr_FR.ISO8859-1/hardware/common/dev.sgml stable/9/release/doc/fr_FR.ISO8859-1/hardware/i386/article.sgml stable/9/release/doc/fr_FR.ISO8859-1/hardware/ia64/article.sgml stable/9/release/doc/fr_FR.ISO8859-1/hardware/pc98/article.sgml stable/9/release/doc/fr_FR.ISO8859-1/hardware/sparc64/article.sgml stable/9/release/doc/fr_FR.ISO8859-1/installation/alpha/article.sgml stable/9/release/doc/fr_FR.ISO8859-1/installation/common/install.sgml stable/9/release/doc/fr_FR.ISO8859-1/installation/common/layout.sgml stable/9/release/doc/fr_FR.ISO8859-1/installation/common/trouble.sgml stable/9/release/doc/fr_FR.ISO8859-1/installation/common/upgrade.sgml stable/9/release/doc/fr_FR.ISO8859-1/installation/i386/article.sgml stable/9/release/doc/fr_FR.ISO8859-1/installation/pc98/article.sgml stable/9/release/doc/fr_FR.ISO8859-1/installation/sparc64/article.sgml stable/9/release/doc/fr_FR.ISO8859-1/installation/sparc64/install.sgml stable/9/release/doc/fr_FR.ISO8859-1/relnotes/alpha/article.sgml stable/9/release/doc/fr_FR.ISO8859-1/relnotes/common/new.sgml stable/9/release/doc/fr_FR.ISO8859-1/relnotes/i386/article.sgml Directory Properties: stable/9/release/ (props changed) stable/9/release/doc/en_US.ISO8859-1/hardware/ (props changed) Modified: stable/9/release/doc/de_DE.ISO8859-1/early-adopter/article.sgml ============================================================================== --- stable/9/release/doc/de_DE.ISO8859-1/early-adopter/article.sgml Tue Sep 18 13:33:39 2012 (r240650) +++ stable/9/release/doc/de_DE.ISO8859-1/early-adopter/article.sgml Tue Sep 18 13:54:48 2012 (r240651) @@ -1,3 +1,14 @@ + + +%entities; + +%release; + +X"> +X"> +]> + - -%man; - - -%freebsd; - - -%authors; - - -%teams; - - -%mailing-lists; - - -%release; - -X"> -X"> - -]> -
Hinweise für die ersten Anwender von &os; Modified: stable/9/release/doc/de_DE.ISO8859-1/errata/article.sgml ============================================================================== --- stable/9/release/doc/de_DE.ISO8859-1/errata/article.sgml Tue Sep 18 13:33:39 2012 (r240650) +++ stable/9/release/doc/de_DE.ISO8859-1/errata/article.sgml Tue Sep 18 13:54:48 2012 (r240651) @@ -1,3 +1,11 @@ +<?xml version="1.0" encoding="iso-8859-1" standalone="no"?> +<!DOCTYPE article PUBLIC "-//FreeBSD//DTD DocBook XML V4.2-Based Extension//EN" [ +<!ENTITY % entities PUBLIC "-//FreeBSD//ENTITIES DocBook FreeBSD Entity Set//DE"> +%entities; +<!ENTITY % release PUBLIC "-//FreeBSD//ENTITIES Release Specification//EN"> +%release; +]> + <!-- FreeBSD errata document. Unlike some of the other RELNOTESng files, this file should remain as a single SGML file, so that @@ -12,19 +20,6 @@ basiert auf: 1.38 --> -<!DOCTYPE ARTICLE PUBLIC "-//FreeBSD//DTD DocBook V4.1-Based Extension//EN" [ -<!ENTITY % man PUBLIC "-//FreeBSD//ENTITIES DocBook Manual Page Entities//EN"> -%man; -<!ENTITY % authors PUBLIC "-//FreeBSD//ENTITIES DocBook Author Entities//EN"> -%authors; -<!ENTITY % translators PUBLIC "-//FreeBSD//ENTITIES DocBook Translator Entities//DE"> -%translators; -<!ENTITY % mlists PUBLIC "-//FreeBSD//ENTITIES DocBook Mailing List Entities//DE"> -%mlists; -<!ENTITY % release PUBLIC "-//FreeBSD//ENTITIES Release Specification//EN"> -%release; -]> - <article lang="de"> <articleinfo> Modified: stable/9/release/doc/de_DE.ISO8859-1/hardware/alpha/article.sgml ============================================================================== --- stable/9/release/doc/de_DE.ISO8859-1/hardware/alpha/article.sgml Tue Sep 18 13:33:39 2012 (r240650) +++ stable/9/release/doc/de_DE.ISO8859-1/hardware/alpha/article.sgml Tue Sep 18 13:54:48 2012 (r240651) @@ -1,29 +1,23 @@ -<!-- - $FreeBSD$ - $FreeBSDde: de-docproj/relnotes/de_DE.ISO8859-1/hardware/alpha/article.sgml,v 1.5 2002/10/12 18:02:21 ue Exp $ - basiert auf: 1.4 ---> - -<!DOCTYPE article PUBLIC "-//FreeBSD//DTD DocBook V4.1-Based Extension//EN" [ -<!ENTITY % man PUBLIC "-//FreeBSD//ENTITIES DocBook Manual Page Entities//EN"> -%man; -<!ENTITY % authors PUBLIC "-//FreeBSD//ENTITIES DocBook Author Entities//EN"> -%authors; -<!ENTITY % translators PUBLIC "-//FreeBSD//ENTITIES DocBook Translator Entities//DE"> -%translators; -<!ENTITY % mlists PUBLIC "-//FreeBSD//ENTITIES DocBook Mailing List Entities//DE"> -%mlists; +<?xml version="1.0" encoding="iso-8859-1" standalone="no"?> +<!DOCTYPE article PUBLIC "-//FreeBSD//DTD DocBook XML V4.2-Based Extension//EN" [ +<!ENTITY % entities PUBLIC "-//FreeBSD//ENTITIES DocBook FreeBSD Entity Set//DE"> +%entities; <!ENTITY % release PUBLIC "-//FreeBSD//ENTITIES Release Specification//EN"> %release; -<!ENTITY % sections SYSTEM "../common/hw.ent"> %sections; +<!ENTITY % sections SYSTEM "../common/hw.ent"> %sections <!-- Architecture-specific customization --> <!ENTITY arch "alpha"> <!ENTITY arch.print "Alpha/AXP"> - ]> +<!-- + $FreeBSD$ + $FreeBSDde: de-docproj/relnotes/de_DE.ISO8859-1/hardware/alpha/article.sgml,v 1.5 2002/10/12 18:02:21 ue Exp $ + basiert auf: 1.4 +--> + <article lang="de"> &artheader; §.intro; Modified: stable/9/release/doc/de_DE.ISO8859-1/hardware/i386/article.sgml ============================================================================== --- stable/9/release/doc/de_DE.ISO8859-1/hardware/i386/article.sgml Tue Sep 18 13:33:39 2012 (r240650) +++ stable/9/release/doc/de_DE.ISO8859-1/hardware/i386/article.sgml Tue Sep 18 13:54:48 2012 (r240651) @@ -1,27 +1,23 @@ -<!-- - $FreeBSD$ - $FreeBSDde: de-docproj/relnotes/de_DE.ISO8859-1/hardware/i386/article.sgml,v 1.5 2002/12/07 21:09:09 ue Exp $ - basiert auf: 1.4 ---> - -<!DOCTYPE article PUBLIC "-//FreeBSD//DTD DocBook V4.1-Based Extension//EN" [ -<!ENTITY % man PUBLIC "-//FreeBSD//ENTITIES DocBook Manual Page Entities//EN"> -%man; -<!ENTITY % authors PUBLIC "-//FreeBSD//ENTITIES DocBook Author Entities//EN"> -%authors; -<!ENTITY % mlists PUBLIC "-//FreeBSD//ENTITIES DocBook Mailing List Entities//DE"> -%mlists; +<?xml version="1.0" encoding="iso-8859-1" standalone="no"?> +<!DOCTYPE article PUBLIC "-//FreeBSD//DTD DocBook XML V4.2-Based Extension//EN" [ +<!ENTITY % entities PUBLIC "-//FreeBSD//ENTITIES DocBook FreeBSD Entity Set//DE"> +%entities; <!ENTITY % release PUBLIC "-//FreeBSD//ENTITIES Release Specification//EN"> %release; -<!ENTITY % sections SYSTEM "../common/hw.ent"> %sections; +<!ENTITY % sections SYSTEM "../common/hw.ent"> %sections <!-- Architecture-specific customization --> <!ENTITY arch "i386"> <!ENTITY arch.print "i386"> - ]> +<!-- + $FreeBSD$ + $FreeBSDde: de-docproj/relnotes/de_DE.ISO8859-1/hardware/i386/article.sgml,v 1.5 2002/12/07 21:09:09 ue Exp $ + basiert auf: 1.4 +--> + <article lang="de"> &artheader; §.intro; Modified: stable/9/release/doc/de_DE.ISO8859-1/hardware/ia64/article.sgml ============================================================================== --- stable/9/release/doc/de_DE.ISO8859-1/hardware/ia64/article.sgml Tue Sep 18 13:33:39 2012 (r240650) +++ stable/9/release/doc/de_DE.ISO8859-1/hardware/ia64/article.sgml Tue Sep 18 13:54:48 2012 (r240651) @@ -1,27 +1,23 @@ -<!-- - $FreeBSD$ - $FreeBSDde: de-docproj/relnotes/de_DE.ISO8859-1/hardware/ia64/article.sgml,v 1.6 2003/05/24 21:52:46 ue Exp $ - basiert auf: 1.3 ---> - -<!DOCTYPE article PUBLIC "-//FreeBSD//DTD DocBook V4.1-Based Extension//EN" [ -<!ENTITY % man PUBLIC "-//FreeBSD//ENTITIES DocBook Manual Page Entities//EN"> -%man; -<!ENTITY % authors PUBLIC "-//FreeBSD//ENTITIES DocBook Author Entities//EN"> -%authors; -<!ENTITY % mlists PUBLIC "-//FreeBSD//ENTITIES DocBook Mailing List Entities//DE"> -%mlists; +<?xml version="1.0" encoding="iso-8859-1" standalone="no"?> +<!DOCTYPE article PUBLIC "-//FreeBSD//DTD DocBook XML V4.2-Based Extension//EN" [ +<!ENTITY % entities PUBLIC "-//FreeBSD//ENTITIES DocBook FreeBSD Entity Set//DE"> +%entities; <!ENTITY % release PUBLIC "-//FreeBSD//ENTITIES Release Specification//EN"> %release; -<!ENTITY % sections SYSTEM "../common/hw.ent"> %sections; +<!ENTITY % sections SYSTEM "../common/hw.ent"> %sections <!-- Architecture-specific customization --> <!ENTITY arch "ia64"> <!ENTITY arch.print "IA-64"> - ]> +<!-- + $FreeBSD$ + $FreeBSDde: de-docproj/relnotes/de_DE.ISO8859-1/hardware/ia64/article.sgml,v 1.6 2003/05/24 21:52:46 ue Exp $ + basiert auf: 1.3 +--> + <article lang="de"> &artheader; Modified: stable/9/release/doc/de_DE.ISO8859-1/hardware/pc98/article.sgml ============================================================================== --- stable/9/release/doc/de_DE.ISO8859-1/hardware/pc98/article.sgml Tue Sep 18 13:33:39 2012 (r240650) +++ stable/9/release/doc/de_DE.ISO8859-1/hardware/pc98/article.sgml Tue Sep 18 13:54:48 2012 (r240651) @@ -1,27 +1,23 @@ -<!-- - $FreeBSD$ - $FreeBSDde: de-docproj/relnotes/de_DE.ISO8859-1/hardware/pc98/article.sgml,v 1.2 2002/10/12 18:02:22 ue Exp $ - basiert auf: 1.1 ---> - -<!DOCTYPE article PUBLIC "-//FreeBSD//DTD DocBook V4.1-Based Extension//EN" [ -<!ENTITY % man PUBLIC "-//FreeBSD//ENTITIES DocBook Manual Page Entities//EN"> -%man; -<!ENTITY % authors PUBLIC "-//FreeBSD//ENTITIES DocBook Author Entities//EN"> -%authors; -<!ENTITY % mlists PUBLIC "-//FreeBSD//ENTITIES DocBook Mailing List Entities//DE"> -%mlists; +<?xml version="1.0" encoding="iso-8859-1" standalone="no"?> +<!DOCTYPE article PUBLIC "-//FreeBSD//DTD DocBook XML V4.2-Based Extension//EN" [ +<!ENTITY % entities PUBLIC "-//FreeBSD//ENTITIES DocBook FreeBSD Entity Set//DE"> +%entities; <!ENTITY % release PUBLIC "-//FreeBSD//ENTITIES Release Specification//EN"> %release; -<!ENTITY % sections SYSTEM "../common/hw.ent"> %sections; +<!ENTITY % sections SYSTEM "../common/hw.ent"> %sections <!-- Architecture-specific customization --> <!ENTITY arch "pc98"> <!ENTITY arch.print "NEC PC-98x1"> - ]> +<!-- + $FreeBSD$ + $FreeBSDde: de-docproj/relnotes/de_DE.ISO8859-1/hardware/pc98/article.sgml,v 1.2 2002/10/12 18:02:22 ue Exp $ + basiert auf: 1.1 +--> + <article lang="de"> &artheader; §.intro; Modified: stable/9/release/doc/de_DE.ISO8859-1/hardware/sparc64/article.sgml ============================================================================== --- stable/9/release/doc/de_DE.ISO8859-1/hardware/sparc64/article.sgml Tue Sep 18 13:33:39 2012 (r240650) +++ stable/9/release/doc/de_DE.ISO8859-1/hardware/sparc64/article.sgml Tue Sep 18 13:54:48 2012 (r240651) @@ -1,19 +1,10 @@ -<!-- - $FreeBSD$ - $FreeBSDde: de-docproj/relnotes/de_DE.ISO8859-1/hardware/sparc64/article.sgml,v 1.7 2003/01/09 12:46:28 ue Exp $ - basiert auf: 1.3 ---> - -<!DOCTYPE article PUBLIC "-//FreeBSD//DTD DocBook V4.1-Based Extension//EN" [ -<!ENTITY % man PUBLIC "-//FreeBSD//ENTITIES DocBook Manual Page Entities//EN"> -%man; -<!ENTITY % authors PUBLIC "-//FreeBSD//ENTITIES DocBook Author Entities//EN"> -%authors; -<!ENTITY % mlists PUBLIC "-//FreeBSD//ENTITIES DocBook Mailing List Entities//DE"> -%mlists; +<?xml version="1.0" encoding="iso-8859-1" standalone="no"?> +<!DOCTYPE article PUBLIC "-//FreeBSD//DTD DocBook XML V4.2-Based Extension//EN" [ +<!ENTITY % entities PUBLIC "-//FreeBSD//ENTITIES DocBook FreeBSD Entity Set//DE"> +%entities; <!ENTITY % release PUBLIC "-//FreeBSD//ENTITIES Release Specification//EN"> %release; -<!ENTITY % sections SYSTEM "../common/hw.ent"> %sections; +<!ENTITY % sections SYSTEM "../common/hw.ent"> %sections <!-- Architecture-specific customization --> @@ -21,6 +12,12 @@ <!ENTITY arch.print "UltraSPARC"> ]> +<!-- + $FreeBSD$ + $FreeBSDde: de-docproj/relnotes/de_DE.ISO8859-1/hardware/sparc64/article.sgml,v 1.7 2003/01/09 12:46:28 ue Exp $ + basiert auf: 1.3 +--> + <article lang="de"> &artheader; §.intro; Modified: stable/9/release/doc/de_DE.ISO8859-1/installation/alpha/article.sgml ============================================================================== --- stable/9/release/doc/de_DE.ISO8859-1/installation/alpha/article.sgml Tue Sep 18 13:33:39 2012 (r240650) +++ stable/9/release/doc/de_DE.ISO8859-1/installation/alpha/article.sgml Tue Sep 18 13:54:48 2012 (r240651) @@ -1,16 +1,7 @@ -<!-- - $FreeBSD$ - $FreeBSDde: de-docproj/relnotes/de_DE.ISO8859-1/installation/alpha/article.sgml,v 1.4 2002/10/12 18:02:23 ue Exp $ - basiert auf: 1.3 ---> - -<!DOCTYPE article PUBLIC "-//FreeBSD//DTD DocBook V4.1-Based Extension//EN" [ -<!ENTITY % man PUBLIC "-//FreeBSD//ENTITIES DocBook Manual Page Entities//EN"> -%man; -<!ENTITY % authors PUBLIC "-//FreeBSD//ENTITIES DocBook Author Entities//EN"> -%authors; -<!ENTITY % mlists PUBLIC "-//FreeBSD//ENTITIES DocBook Mailing List Entities//DE"> -%mlists; +<?xml version="1.0" encoding="iso-8859-1" standalone="no"?> +<!DOCTYPE article PUBLIC "-//FreeBSD//DTD DocBook XML V4.2-Based Extension//EN" [ +<!ENTITY % entities PUBLIC "-//FreeBSD//ENTITIES DocBook FreeBSD Entity Set//DE"> +%entities; <!ENTITY % release PUBLIC "-//FreeBSD//ENTITIES Release Specification//EN"> %release; <!ENTITY % sections SYSTEM "../common/install.ent"> %sections; @@ -21,6 +12,12 @@ <!ENTITY arch.print "Alpha/AXP"> ]> +<!-- + $FreeBSD$ + $FreeBSDde: de-docproj/relnotes/de_DE.ISO8859-1/installation/alpha/article.sgml,v 1.4 2002/10/12 18:02:23 ue Exp $ + basiert auf: 1.3 +--> + <article lang="de"> &artheader; &abstract; Modified: stable/9/release/doc/de_DE.ISO8859-1/installation/common/install.sgml ============================================================================== --- stable/9/release/doc/de_DE.ISO8859-1/installation/common/install.sgml Tue Sep 18 13:33:39 2012 (r240650) +++ stable/9/release/doc/de_DE.ISO8859-1/installation/common/install.sgml Tue Sep 18 13:54:48 2012 (r240651) @@ -26,7 +26,7 @@ from {alpha,i386}/INSTALL.TXT. ausführlichen, bebilderten Installationsleitung.</para> <para>Wenn Sie eine ältere Version von &os; aktualisieren - wollen, sollten Sie <xref linkend="upgrading">, Aktualisierung von + wollen, sollten Sie <xref linkend="upgrading"/>, Aktualisierung von FreeBSD, lesen.</para> <sect2 id="getting-started"> @@ -60,7 +60,7 @@ from {alpha,i386}/INSTALL.TXT. <para>Irgend etwas kann immer schiefgehen und wenn Ihnen das passiert, sollten Sie einen Blick in <xref - linkend="trouble"> werfen, wo Sie hilfreiche Informationen + linkend="trouble"/> werfen, wo Sie hilfreiche Informationen finden können. Sie sollten ebenfalls einen Blick auf die aktuelle Version von <filename>ERRATA.TXT</filename> werfen, bevor Sie mit der Installation beginnen, da Sie dort @@ -76,6 +76,7 @@ from {alpha,i386}/INSTALL.TXT. Backup haben, bevor Sie die Installation durchführen.</para> </important> + </sect2> <sect2> <title>Hardware-Anforderungen @@ -286,7 +287,7 @@ from {alpha,i386}/INSTALL.TXT. benutzen, können Sie das Script makeflp.bat verwenden. Weitere Informationen zu diesem Thema finden Sie im Kapitel . Danach müssen Sie nur noch von + linkend="floppies"/>. Danach müssen Sie nur noch von der ersten Diskette booten, um die &os;-Installation zu starten. @@ -306,7 +307,7 @@ from {alpha,i386}/INSTALL.TXT. benutzen, können Sie das Script makeflp.bat verwenden. Weitere Informationen zu diesem Thema finden Sie im Kapitel . Danach müssen Sie nur noch von + linkend="floppies"/>. Danach müssen Sie nur noch von der ersten Diskette booten, um die &os;-Installation zu starten. @@ -320,12 +321,12 @@ from {alpha,i386}/INSTALL.TXT. müssen Sie ebenfalls die beiden &os; Bootdisketten aus den Dateien floppies/kern.flp und floppies/mfsroot.flp erzeugen, wie in - beschrieben. Booten Sie Ihren + beschrieben. Booten Sie Ihren Rechner von der Diskette mit kern.flp; und legen Sie die Diskette mit mfsroot.flp ein, sobald Sie dazu aufgefordert werden. Weitere Informationen zu dieser Art der Installation finden Sie in . + linkend="ftpnfs"/>. Wenn Ihr Rechner kein CDROM Laufwerk hat, können Sie &os; auch direkt über das Internet @@ -334,12 +335,12 @@ from {alpha,i386}/INSTALL.TXT. Bootdisketten aus den Dateien floppies/kern.flp und floppies/mfsroot.flp erzeugen, wie in beschrieben. Booten Sie Ihren Rechner von + linkend="floppies"/> beschrieben. Booten Sie Ihren Rechner von der Diskette mit kern.flp; und legen Sie die Diskette mit mfsroot.flp ein, sobald Sie dazu aufgefordert werden. Weitere Informationen zu dieser Art der Installation finden Sie in . + linkend="ftpnfs"/>. @@ -358,7 +359,7 @@ from {alpha,i386}/INSTALL.TXT. Bootdisketten aus den Dateien floppies/kern.flp und floppies/mfsroot.flp erzeugen, wie in - beschrieben. Legen Sie die + beschrieben. Legen Sie die Diskette mit dem Inhalt von kern.flp ein und geben Sie an der Eingabeaufforderung des SRM (>>>) den folgenden Befehl ein, um @@ -400,8 +401,8 @@ Ethernet address 0:3:ba:b:92:d4, Host ID - - + + ok @@ -506,7 +507,7 @@ pqb0.0.1.4.0 PQB0 Wenn Sie von einem lokalen CDROM installieren wollen, sollten Sie nicht dieses Kapitel lesen, sondern - . Wenn in Ihrem System + . Wenn in Ihrem System kein CDROM vorhanden ist und Sie eine &os; CD benutzen wollen, die in einem CDROM Laufwerk eines anderen Systems liegt und Sie dieses System über ein Netzwerk erreichen @@ -580,10 +581,10 @@ pqb0.0.1.4.0 PQB0 Installation vorbereiten. Der erste Schritt ist die Erstellung der Bootdisketten, - wie in beschrieben. + wie in beschrieben. Der zweite Schritt ist, einen Blick in zu werfen. Das Kapitel Distribution + linkend="layout"/> zu werfen. Das Kapitel Distribution Format ist besonders wichtig, da Sie hier erfahren, welche Dateien Sie auf Diskette übertragen müssen und welche Sie ignorieren können. @@ -733,14 +734,14 @@ pqb0.0.1.4.0 PQB0 Der letzte Schritt ist die Erzeugung der Bootdisketten, - siehe . + siehe . Netzwerk-Installation mit FTP oder NFS Wenn Sie die Bootdisketten erzeugt haben, wie in beschrieben, können Sie die restliche + linkend="floppies"/> beschrieben, können Sie die restliche Installation über eine Netzwerk-Verbindung durchführen, wobei drei Arten von Netzwerkverbindungen unterstützt werden: seriell, parallel, oder @@ -981,7 +982,7 @@ pqb0.0.1.4.0 PQB0 Wenn Sie keine Meldungen auf Ihrer seriellen Konsole sehen, müssen Sie die Tastatur wieder einstecken und auf ein Tonsignal warten. Wenn Sie von CD booten, machen - Sie bei weiter, wenn Sie das + Sie bei weiter, wenn Sie das Tonsignal hören.. Modified: stable/9/release/doc/de_DE.ISO8859-1/installation/common/layout.sgml ============================================================================== --- stable/9/release/doc/de_DE.ISO8859-1/installation/common/layout.sgml Tue Sep 18 13:33:39 2012 (r240650) +++ stable/9/release/doc/de_DE.ISO8859-1/installation/common/layout.sgml Tue Sep 18 13:54:48 2012 (r240651) @@ -23,7 +23,7 @@ README.HTM cdrom.inf crypto Wenn Sie dieses Verzeichnis für eine CD-, FTP- oder NFS-Installation nutzen wollen, brauchen Sie nur die beiden 1.44 MByte großen Bootdisketten zu erstellen (wie das geht, ist - in beschrieben), von diesen zu booten, + in beschrieben), von diesen zu booten, und dann den Anweisungen zu folgen. Alle anderen Dateien, die für die Installation notwendig sind, werden auf der Grundlage Ihrer Angaben automatisch geholt. Wenn Sie &os; noch nie @@ -86,7 +86,7 @@ README.HTM cdrom.inf crypto Das Verzeichnis floppies/ enthält die Images der Bootdisketten. Informationen, wie man diese Images benutzt, finden Sie in . + linkend="floppies"/>. Modified: stable/9/release/doc/de_DE.ISO8859-1/installation/i386/article.sgml ============================================================================== --- stable/9/release/doc/de_DE.ISO8859-1/installation/i386/article.sgml Tue Sep 18 13:33:39 2012 (r240650) +++ stable/9/release/doc/de_DE.ISO8859-1/installation/i386/article.sgml Tue Sep 18 13:54:48 2012 (r240651) @@ -1,16 +1,7 @@ - - - -%man; - -%authors; - -%mlists; + + +%entities; %release; %sections; @@ -19,9 +10,14 @@ - ]> + +
&artheader; &abstract; Modified: stable/9/release/doc/de_DE.ISO8859-1/installation/ia64/article.sgml ============================================================================== --- stable/9/release/doc/de_DE.ISO8859-1/installation/ia64/article.sgml Tue Sep 18 13:33:39 2012 (r240650) +++ stable/9/release/doc/de_DE.ISO8859-1/installation/ia64/article.sgml Tue Sep 18 13:54:48 2012 (r240651) @@ -1,17 +1,7 @@ - - - - -%man; - -%authors; - -%mlists; + + +%entities; %release; %sections; @@ -20,9 +10,14 @@ - ]> + +
&artheader; &abstract; Modified: stable/9/release/doc/de_DE.ISO8859-1/installation/pc98/article.sgml ============================================================================== --- stable/9/release/doc/de_DE.ISO8859-1/installation/pc98/article.sgml Tue Sep 18 13:33:39 2012 (r240650) +++ stable/9/release/doc/de_DE.ISO8859-1/installation/pc98/article.sgml Tue Sep 18 13:54:48 2012 (r240651) @@ -1,16 +1,7 @@ - - - -%man; - -%authors; - -%mlists; + + +%entities; %release; %sections; @@ -19,9 +10,14 @@ - ]> + +
&artheader; &abstract; Modified: stable/9/release/doc/de_DE.ISO8859-1/installation/sparc64/article.sgml ============================================================================== --- stable/9/release/doc/de_DE.ISO8859-1/installation/sparc64/article.sgml Tue Sep 18 13:33:39 2012 (r240650) +++ stable/9/release/doc/de_DE.ISO8859-1/installation/sparc64/article.sgml Tue Sep 18 13:54:48 2012 (r240651) @@ -1,19 +1,8 @@ - - - + +%entities; - - -%man; - -%authors; - -%mlists; %release; %sections; @@ -24,6 +13,12 @@ ]> + +
&artheader; &abstract; Modified: stable/9/release/doc/de_DE.ISO8859-1/readme/article.sgml ============================================================================== --- stable/9/release/doc/de_DE.ISO8859-1/readme/article.sgml Tue Sep 18 13:33:39 2012 (r240650) +++ stable/9/release/doc/de_DE.ISO8859-1/readme/article.sgml Tue Sep 18 13:54:48 2012 (r240651) @@ -1,3 +1,11 @@ + + +%entities; + +%release; +]> + - -%man; - -%authors; - -%mlists; - -%release; - -%misc; -]> -
&os; &release.current; README @@ -229,7 +224,7 @@ wenn Sie an weiteren Informationen zu diesem Thema interessiert sind. Zusätzliche Informationen zu diesem Thema finden Sie im Artikel Mirroring + url="http://www.FreeBSD.org/doc/en_US.ISO8859-1/articles/hubs/">Mirroring FreeBSD. Sie finden die für den Start der Installation Modified: stable/9/release/doc/de_DE.ISO8859-1/relnotes/alpha/article.sgml ============================================================================== --- stable/9/release/doc/de_DE.ISO8859-1/relnotes/alpha/article.sgml Tue Sep 18 13:33:39 2012 (r240650) +++ stable/9/release/doc/de_DE.ISO8859-1/relnotes/alpha/article.sgml Tue Sep 18 13:54:48 2012 (r240651) @@ -1,16 +1,7 @@ - - - -%man; - -%authors; - -%mlists; + + +%entities; %release; %sections; @@ -19,9 +10,14 @@ - ]> + +
&art;
Modified: stable/9/release/doc/de_DE.ISO8859-1/relnotes/i386/article.sgml ============================================================================== --- stable/9/release/doc/de_DE.ISO8859-1/relnotes/i386/article.sgml Tue Sep 18 13:33:39 2012 (r240650) +++ stable/9/release/doc/de_DE.ISO8859-1/relnotes/i386/article.sgml Tue Sep 18 13:54:48 2012 (r240651) @@ -1,16 +1,7 @@ - - - -%man; - -%authors; - -%mlists; + + +%entities; %release; %sections; @@ -19,9 +10,15 @@ - ]> + + +
&art;
Modified: stable/9/release/doc/de_DE.ISO8859-1/relnotes/ia64/article.sgml ============================================================================== --- stable/9/release/doc/de_DE.ISO8859-1/relnotes/ia64/article.sgml Tue Sep 18 13:33:39 2012 (r240650) +++ stable/9/release/doc/de_DE.ISO8859-1/relnotes/ia64/article.sgml Tue Sep 18 13:54:48 2012 (r240651) @@ -1,16 +1,7 @@ - - - -%man; - -%authors; - -%mlists; + + +%entities; %release; %sections; @@ -19,8 +10,12 @@ - ]> +
&art; Modified: stable/9/release/doc/de_DE.ISO8859-1/relnotes/pc98/article.sgml ============================================================================== --- stable/9/release/doc/de_DE.ISO8859-1/relnotes/pc98/article.sgml Tue Sep 18 13:33:39 2012 (r240650) +++ stable/9/release/doc/de_DE.ISO8859-1/relnotes/pc98/article.sgml Tue Sep 18 13:54:48 2012 (r240651) @@ -1,16 +1,7 @@ - - - -%man; - -%authors; - -%mlists; + + +%entities; %release; %sections; @@ -19,9 +10,15 @@ - ]> + + +
&art;
Modified: stable/9/release/doc/de_DE.ISO8859-1/relnotes/sparc64/article.sgml ============================================================================== --- stable/9/release/doc/de_DE.ISO8859-1/relnotes/sparc64/article.sgml Tue Sep 18 13:33:39 2012 (r240650) +++ stable/9/release/doc/de_DE.ISO8859-1/relnotes/sparc64/article.sgml Tue Sep 18 13:54:48 2012 (r240651) @@ -1,19 +1,7 @@ - - - - - -%man; - -%authors; - -%mlists; + + +%entities; %release; %sections; @@ -22,9 +10,14 @@ - ]> + +
&art;
Modified: stable/9/release/doc/en_US.ISO8859-1/errata/article.sgml ============================================================================== --- stable/9/release/doc/en_US.ISO8859-1/errata/article.sgml Tue Sep 18 13:33:39 2012 (r240650) +++ stable/9/release/doc/en_US.ISO8859-1/errata/article.sgml Tue Sep 18 13:54:48 2012 (r240651) @@ -1,3 +1,22 @@ + + +%entities; + + +%release; + + +]]> + +]]> + +]]> +]> + - -%articles.ent; - - -%release; -]> -
- &os; -<![ %release.type.current [ - &release.current; -]]> -<![ %release.type.snapshot [ - &release.prev; -]]> -<![ %release.type.release [ - &release.current; -]]> - Errata + &os; &release; Errata The &os; Project Modified: stable/9/release/doc/en_US.ISO8859-1/hardware/article.sgml ============================================================================== --- stable/9/release/doc/en_US.ISO8859-1/hardware/article.sgml Tue Sep 18 13:33:39 2012 (r240650) +++ stable/9/release/doc/en_US.ISO8859-1/hardware/article.sgml Tue Sep 18 13:54:48 2012 (r240651) @@ -1,14 +1,12 @@ - -%articles.ent; + + +%entities; %release; %devauto; - - - ]>
Modified: stable/9/release/doc/en_US.ISO8859-1/readme/article.sgml ============================================================================== --- stable/9/release/doc/en_US.ISO8859-1/readme/article.sgml Tue Sep 18 13:33:39 2012 (r240650) +++ stable/9/release/doc/en_US.ISO8859-1/readme/article.sgml Tue Sep 18 13:54:48 2012 (r240651) @@ -1,6 +1,7 @@ - -%articles.ent; + + +%entities; %release; @@ -184,7 +185,7 @@ freebsd-admin@FreeBSD.org for more details on becoming an official mirror site. You can also find useful information for mirror sites at the Mirroring + url="&url.articles.hubs;/">Mirroring &os; article. Mirrors generally contain the ISO images generally used to Modified: stable/9/release/doc/en_US.ISO8859-1/relnotes/article.sgml ============================================================================== --- stable/9/release/doc/en_US.ISO8859-1/relnotes/article.sgml Tue Sep 18 13:33:39 2012 (r240650) +++ stable/9/release/doc/en_US.ISO8859-1/relnotes/article.sgml Tue Sep 18 13:54:48 2012 (r240651) @@ -1,6 +1,7 @@ - -%articles.ent; + + +%entities; %release; Modified: stable/9/release/doc/fr_FR.ISO8859-1/early-adopter/article.sgml ============================================================================== --- stable/9/release/doc/fr_FR.ISO8859-1/early-adopter/article.sgml Tue Sep 18 13:33:39 2012 (r240650) +++ stable/9/release/doc/fr_FR.ISO8859-1/early-adopter/article.sgml Tue Sep 18 13:54:48 2012 (r240651) @@ -1,3 +1,14 @@ + *** DIFF OUTPUT TRUNCATED AT 1000 LINES *** From owner-svn-src-stable@FreeBSD.ORG Tue Sep 18 14:05:36 2012 Return-Path: Delivered-To: svn-src-stable@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 165401065786; Tue, 18 Sep 2012 14:05:36 +0000 (UTC) (envelope-from gjb@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id DAC3C8FC1C; Tue, 18 Sep 2012 14:05:35 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q8IE5Zn8006867; Tue, 18 Sep 2012 14:05:35 GMT (envelope-from gjb@svn.freebsd.org) Received: (from gjb@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q8IE5Zcb006864; Tue, 18 Sep 2012 14:05:35 GMT (envelope-from gjb@svn.freebsd.org) Message-Id: <201209181405.q8IE5Zcb006864@svn.freebsd.org> From: Glen Barber Date: Tue, 18 Sep 2012 14:05:35 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r240653 - in stable/9/release/doc: en_US.ISO8859-1/errata en_US.ISO8859-1/relnotes ru_RU.KOI8-R/relnotes/common X-BeenThere: svn-src-stable@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for all the -stable branches of the src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 18 Sep 2012 14:05:36 -0000 Author: gjb (doc,ports committer) Date: Tue Sep 18 14:05:35 2012 New Revision: 240653 URL: http://svn.freebsd.org/changeset/base/240653 Log: Close colspec tags to conform to XML standards. This commit should fix more 9-STABLE release build problems. This is a direct commit to stable/9. Modified: stable/9/release/doc/en_US.ISO8859-1/errata/article.sgml stable/9/release/doc/en_US.ISO8859-1/relnotes/article.sgml stable/9/release/doc/ru_RU.KOI8-R/relnotes/common/new.sgml (contents, props changed) Modified: stable/9/release/doc/en_US.ISO8859-1/errata/article.sgml ============================================================================== --- stable/9/release/doc/en_US.ISO8859-1/errata/article.sgml Tue Sep 18 14:00:11 2012 (r240652) +++ stable/9/release/doc/en_US.ISO8859-1/errata/article.sgml Tue Sep 18 14:05:35 2012 (r240653) @@ -132,9 +132,9 @@ - - - + + + Modified: stable/9/release/doc/en_US.ISO8859-1/relnotes/article.sgml ============================================================================== --- stable/9/release/doc/en_US.ISO8859-1/relnotes/article.sgml Tue Sep 18 14:00:11 2012 (r240652) +++ stable/9/release/doc/en_US.ISO8859-1/relnotes/article.sgml Tue Sep 18 14:05:35 2012 (r240653) @@ -97,9 +97,9 @@ - - - + + + Advisory @@ -295,8 +295,8 @@ - - + + &man.sysctl.8; variable name Modified: stable/9/release/doc/ru_RU.KOI8-R/relnotes/common/new.sgml ============================================================================== Binary file (source and/or target). No diff available. From owner-svn-src-stable@FreeBSD.ORG Tue Sep 18 16:01:26 2012 Return-Path: Delivered-To: svn-src-stable@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 689FF10656F0; Tue, 18 Sep 2012 16:01:26 +0000 (UTC) (envelope-from hselasky@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 49ED48FC19; Tue, 18 Sep 2012 16:01:26 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q8IG1QeT021237; Tue, 18 Sep 2012 16:01:26 GMT (envelope-from hselasky@svn.freebsd.org) Received: (from hselasky@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q8IG1QLA021234; Tue, 18 Sep 2012 16:01:26 GMT (envelope-from hselasky@svn.freebsd.org) Message-Id: <201209181601.q8IG1QLA021234@svn.freebsd.org> From: Hans Petter Selasky Date: Tue, 18 Sep 2012 16:01:26 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r240657 - in stable/9/sys/dev/usb: . wlan X-BeenThere: svn-src-stable@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for all the -stable branches of the src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 18 Sep 2012 16:01:26 -0000 Author: hselasky Date: Tue Sep 18 16:01:25 2012 New Revision: 240657 URL: http://svn.freebsd.org/changeset/base/240657 Log: MFC r238274 and r239358 Add new USB device ID's. Modified: stable/9/sys/dev/usb/usbdevs stable/9/sys/dev/usb/wlan/if_run.c Directory Properties: stable/9/sys/ (props changed) stable/9/sys/dev/ (props changed) Modified: stable/9/sys/dev/usb/usbdevs ============================================================================== --- stable/9/sys/dev/usb/usbdevs Tue Sep 18 16:00:44 2012 (r240656) +++ stable/9/sys/dev/usb/usbdevs Tue Sep 18 16:01:25 2012 (r240657) @@ -1077,6 +1077,7 @@ product ASUS A730W 0x4202 ASUS MyPal A7 product ASUS P535 0x420f ASUS P535 PDA product ASUS GMSC 0x422f ASUS Generic Mass Storage product ASUS RT2570 0x1706 RT2500USB Wireless Adapter +product ASUS USB_N53 0x179d ASUS Black Diamond Dual Band USB-N53 /* ATen products */ product ATEN UC1284 0x2001 Parallel printer @@ -2147,6 +2148,7 @@ product LOGITEC RT2870_1 0x0162 RT2870 product LOGITEC RT2870_2 0x0163 RT2870 product LOGITEC RT2870_3 0x0164 RT2870 product LOGITEC LANW300NU2 0x0166 LAN-W300N/U2 +product LOGITEC LANW150NU2 0x0168 LAN-W150N/U2 /* Longcheer Holdings, Ltd. products */ product LONGCHEER WM66 0x6061 Longcheer WM66 HSDPA @@ -2211,7 +2213,8 @@ product MELCO RT2870_1 0x0148 RT2870 product MELCO RT2870_2 0x0150 RT2870 product MELCO WLIUCGN 0x015d WLI-UC-GN product MELCO WLIUCG301N 0x016f WLI-UC-G301N -product MELCO WLIUCGNM 0x01a2 WLI-UC-GNM +product MELCO WLIUCGNM 0x01a2 WLI-UC-GNM +product MELCO WLIUCGNM2 0x01ee WLI-UC-GNM2 /* Merlin products */ product MERLIN V620 0x1110 Merlin V620 @@ -2629,6 +2632,7 @@ product PLANEX2 GWUS54GD 0xed01 GW-US54G product PLANEX2 GWUSMM 0xed02 GW-USMM product PLANEX2 RT2870 0xed06 RT2870 product PLANEX2 GWUSMICRON 0xed14 GW-USMicroN +product PLANEX2 GWUSVALUEEZ 0xed17 GW-USValue-EZ product PLANEX3 GWUS54GZ 0xab10 GW-US54GZ product PLANEX3 GU1000T 0xab11 GU-1000T product PLANEX3 GWUS54MINI 0xab13 GW-US54Mini Modified: stable/9/sys/dev/usb/wlan/if_run.c ============================================================================== --- stable/9/sys/dev/usb/wlan/if_run.c Tue Sep 18 16:00:44 2012 (r240656) +++ stable/9/sys/dev/usb/wlan/if_run.c Tue Sep 18 16:01:25 2012 (r240657) @@ -136,6 +136,7 @@ static const STRUCT_USB_HOST_ID run_devs RUN_DEV(ASUS, RT2870_5), RUN_DEV(ASUS, USBN13), RUN_DEV(ASUS, RT3070_1), + RUN_DEV(ASUS, USB_N53), RUN_DEV(ASUS2, USBN11), RUN_DEV(AZUREWAVE, RT2870_1), RUN_DEV(AZUREWAVE, RT2870_2), @@ -209,6 +210,7 @@ static const STRUCT_USB_HOST_ID run_devs RUN_DEV(LOGITEC, RT2870_2), RUN_DEV(LOGITEC, RT2870_3), RUN_DEV(LOGITEC, LANW300NU2), + RUN_DEV(LOGITEC, LANW150NU2), RUN_DEV(MELCO, RT2870_1), RUN_DEV(MELCO, RT2870_2), RUN_DEV(MELCO, WLIUCAG300N), @@ -216,6 +218,7 @@ static const STRUCT_USB_HOST_ID run_devs RUN_DEV(MELCO, WLIUCG301N), RUN_DEV(MELCO, WLIUCGN), RUN_DEV(MELCO, WLIUCGNM), + RUN_DEV(MELCO, WLIUCGNM2), RUN_DEV(MOTOROLA4, RT2770), RUN_DEV(MOTOROLA4, RT3070), RUN_DEV(MSI, RT3070_1), From owner-svn-src-stable@FreeBSD.ORG Tue Sep 18 16:28:50 2012 Return-Path: Delivered-To: svn-src-stable@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id B7DB1106566C; Tue, 18 Sep 2012 16:28:50 +0000 (UTC) (envelope-from hselasky@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 9F6CC8FC16; Tue, 18 Sep 2012 16:28:50 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q8IGSoZF024644; Tue, 18 Sep 2012 16:28:50 GMT (envelope-from hselasky@svn.freebsd.org) Received: (from hselasky@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q8IGSoOF024628; Tue, 18 Sep 2012 16:28:50 GMT (envelope-from hselasky@svn.freebsd.org) Message-Id: <201209181628.q8IGSoOF024628@svn.freebsd.org> From: Hans Petter Selasky Date: Tue, 18 Sep 2012 16:28:50 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r240659 - in stable/9/sys: dev/usb/net dev/usb/serial kern sys X-BeenThere: svn-src-stable@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for all the -stable branches of the src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 18 Sep 2012 16:28:50 -0000 Author: hselasky Date: Tue Sep 18 16:28:49 2012 New Revision: 240659 URL: http://svn.freebsd.org/changeset/base/240659 Log: MFC r239178, r239179, r239180, r239181, r239182 and r239299: Fix detach of USB serial devices so that it doesn't block the USB explore thread forever. To accomplish this two new functions have been added to the kernel, to claim and free the newbus allocated softc. This change is backwards API compatible, but not binary compatible. The FreeBSD version has been bumped to force a recompile of all kernel modules. Discussed with: kib, ed, jhb Modified: stable/9/sys/dev/usb/net/if_usie.c stable/9/sys/dev/usb/net/uhso.c stable/9/sys/dev/usb/serial/u3g.c stable/9/sys/dev/usb/serial/uark.c stable/9/sys/dev/usb/serial/ubsa.c stable/9/sys/dev/usb/serial/ubser.c stable/9/sys/dev/usb/serial/uchcom.c stable/9/sys/dev/usb/serial/ucycom.c stable/9/sys/dev/usb/serial/ufoma.c stable/9/sys/dev/usb/serial/uftdi.c stable/9/sys/dev/usb/serial/ugensa.c stable/9/sys/dev/usb/serial/uipaq.c stable/9/sys/dev/usb/serial/ulpt.c stable/9/sys/dev/usb/serial/umcs.c stable/9/sys/dev/usb/serial/umct.c stable/9/sys/dev/usb/serial/umodem.c stable/9/sys/dev/usb/serial/umoscom.c stable/9/sys/dev/usb/serial/uplcom.c stable/9/sys/dev/usb/serial/usb_serial.c stable/9/sys/dev/usb/serial/usb_serial.h stable/9/sys/dev/usb/serial/uslcom.c stable/9/sys/dev/usb/serial/uvisor.c stable/9/sys/dev/usb/serial/uvscom.c stable/9/sys/kern/subr_bus.c stable/9/sys/sys/bus.h stable/9/sys/sys/param.h Directory Properties: stable/9/sys/ (props changed) stable/9/sys/dev/ (props changed) Modified: stable/9/sys/dev/usb/net/if_usie.c ============================================================================== --- stable/9/sys/dev/usb/net/if_usie.c Tue Sep 18 16:23:23 2012 (r240658) +++ stable/9/sys/dev/usb/net/if_usie.c Tue Sep 18 16:28:49 2012 (r240659) @@ -95,7 +95,9 @@ static const STRUCT_USB_HOST_ID usie_dev static device_probe_t usie_probe; static device_attach_t usie_attach; static device_detach_t usie_detach; +static void usie_free_softc(struct usie_softc *); +static void usie_free(struct ucom_softc *); static void usie_uc_update_line_state(struct ucom_softc *, uint8_t); static void usie_uc_cfg_get_status(struct ucom_softc *, uint8_t *, uint8_t *); static void usie_uc_cfg_set_dtr(struct ucom_softc *, uint8_t); @@ -189,7 +191,7 @@ static device_method_t usie_methods[] = DEVMETHOD(device_probe, usie_probe), DEVMETHOD(device_attach, usie_attach), DEVMETHOD(device_detach, usie_detach), - {0, 0} + DEVMETHOD_END }; static driver_t usie_driver = { @@ -216,6 +218,7 @@ static const struct ucom_callback usie_u .ucom_stop_read = &usie_uc_stop_read, .ucom_start_write = &usie_uc_start_write, .ucom_stop_write = &usie_uc_stop_write, + .ucom_free = &usie_free, }; static void @@ -298,6 +301,7 @@ usie_attach(device_t self) sc->sc_dev = self; mtx_init(&sc->sc_mtx, "usie", MTX_NETWORK_LOCK, MTX_DEF); + ucom_ref(&sc->sc_super_ucom); TASK_INIT(&sc->sc_if_status_task, 0, usie_if_status_cb, sc); TASK_INIT(&sc->sc_if_sync_task, 0, usie_if_sync_cb, sc); @@ -482,11 +486,31 @@ usie_detach(device_t self) for (x = 0; x != USIE_UCOM_MAX; x++) usbd_transfer_unsetup(sc->sc_uc_xfer[x], USIE_UC_N_XFER); - mtx_destroy(&sc->sc_mtx); + + device_claim_softc(self); + + usie_free_softc(sc); return (0); } +UCOM_UNLOAD_DRAIN(usie); + +static void +usie_free_softc(struct usie_softc *sc) +{ + if (ucom_unref(&sc->sc_super_ucom)) { + mtx_destroy(&sc->sc_mtx); + device_free_softc(sc); + } +} + +static void +usie_free(struct ucom_softc *ucom) +{ + usie_free_softc(ucom->sc_parent); +} + static void usie_uc_update_line_state(struct ucom_softc *ucom, uint8_t ls) { Modified: stable/9/sys/dev/usb/net/uhso.c ============================================================================== --- stable/9/sys/dev/usb/net/uhso.c Tue Sep 18 16:23:23 2012 (r240658) +++ stable/9/sys/dev/usb/net/uhso.c Tue Sep 18 16:28:49 2012 (r240659) @@ -455,6 +455,7 @@ static int uhso_driver_loaded(struct mo static int uhso_radio_sysctl(SYSCTL_HANDLER_ARGS); static int uhso_radio_ctrl(struct uhso_softc *, int); +static void uhso_free(struct ucom_softc *); static void uhso_ucom_start_read(struct ucom_softc *); static void uhso_ucom_stop_read(struct ucom_softc *); static void uhso_ucom_start_write(struct ucom_softc *); @@ -473,6 +474,7 @@ static void uhso_if_rxflush(void *); static device_probe_t uhso_probe; static device_attach_t uhso_attach; static device_detach_t uhso_detach; +static void uhso_free_softc(struct uhso_softc *); static device_method_t uhso_methods[] = { DEVMETHOD(device_probe, uhso_probe), @@ -500,7 +502,8 @@ static struct ucom_callback uhso_ucom_ca .ucom_start_read = uhso_ucom_start_read, .ucom_stop_read = uhso_ucom_stop_read, .ucom_start_write = uhso_ucom_start_write, - .ucom_stop_write = uhso_ucom_stop_write + .ucom_stop_write = uhso_ucom_stop_write, + .ucom_free = &uhso_free, }; static int @@ -552,6 +555,7 @@ uhso_attach(device_t self) sc->sc_dev = self; sc->sc_udev = uaa->device; mtx_init(&sc->sc_mtx, "uhso", NULL, MTX_DEF); + ucom_ref(&sc->sc_super_ucom); sc->sc_ucom = NULL; sc->sc_ttys = 0; @@ -692,10 +696,30 @@ uhso_detach(device_t self) usbd_transfer_unsetup(sc->sc_if_xfer, UHSO_IFNET_MAX); } - mtx_destroy(&sc->sc_mtx); + device_claim_softc(self); + + uhso_free_softc(sc); + return (0); } +UCOM_UNLOAD_DRAIN(uhso); + +static void +uhso_free_softc(struct uhso_softc *sc) +{ + if (ucom_unref(&sc->sc_super_ucom)) { + mtx_destroy(&sc->sc_mtx); + device_free_softc(sc); + } +} + +static void +uhso_free(struct ucom_softc *ucom) +{ + uhso_free_softc(ucom->sc_parent); +} + static void uhso_test_autoinst(void *arg, struct usb_device *udev, struct usb_attach_arg *uaa) Modified: stable/9/sys/dev/usb/serial/u3g.c ============================================================================== --- stable/9/sys/dev/usb/serial/u3g.c Tue Sep 18 16:23:23 2012 (r240658) +++ stable/9/sys/dev/usb/serial/u3g.c Tue Sep 18 16:28:49 2012 (r240659) @@ -118,10 +118,12 @@ struct u3g_softc { static device_probe_t u3g_probe; static device_attach_t u3g_attach; static device_detach_t u3g_detach; +static void u3g_free_softc(struct u3g_softc *); static usb_callback_t u3g_write_callback; static usb_callback_t u3g_read_callback; +static void u3g_free(struct ucom_softc *ucom); static void u3g_start_read(struct ucom_softc *ucom); static void u3g_stop_read(struct ucom_softc *ucom); static void u3g_start_write(struct ucom_softc *ucom); @@ -160,13 +162,14 @@ static const struct ucom_callback u3g_ca .ucom_stop_read = &u3g_stop_read, .ucom_start_write = &u3g_start_write, .ucom_stop_write = &u3g_stop_write, + .ucom_free = &u3g_free, }; static device_method_t u3g_methods[] = { DEVMETHOD(device_probe, u3g_probe), DEVMETHOD(device_attach, u3g_attach), DEVMETHOD(device_detach, u3g_detach), - {0, 0} + DEVMETHOD_END }; static devclass_t u3g_devclass; @@ -799,6 +802,7 @@ u3g_attach(device_t dev) device_set_usb_desc(dev); mtx_init(&sc->sc_mtx, "u3g", NULL, MTX_DEF); + ucom_ref(&sc->sc_super_ucom); sc->sc_udev = uaa->device; @@ -886,11 +890,31 @@ u3g_detach(device_t dev) for (subunit = 0; subunit != U3G_MAXPORTS; subunit++) usbd_transfer_unsetup(sc->sc_xfer[subunit], U3G_N_TRANSFER); - mtx_destroy(&sc->sc_mtx); + + device_claim_softc(dev); + + u3g_free_softc(sc); return (0); } +UCOM_UNLOAD_DRAIN(u3g); + +static void +u3g_free_softc(struct u3g_softc *sc) +{ + if (ucom_unref(&sc->sc_super_ucom)) { + mtx_destroy(&sc->sc_mtx); + device_free_softc(sc); + } +} + +static void +u3g_free(struct ucom_softc *ucom) +{ + u3g_free_softc(ucom->sc_parent); +} + static void u3g_start_read(struct ucom_softc *ucom) { @@ -898,7 +922,6 @@ u3g_start_read(struct ucom_softc *ucom) /* start read endpoint */ usbd_transfer_start(sc->sc_xfer[ucom->sc_subunit][U3G_BULK_RD]); - return; } static void @@ -908,7 +931,6 @@ u3g_stop_read(struct ucom_softc *ucom) /* stop read endpoint */ usbd_transfer_stop(sc->sc_xfer[ucom->sc_subunit][U3G_BULK_RD]); - return; } static void @@ -917,7 +939,6 @@ u3g_start_write(struct ucom_softc *ucom) struct u3g_softc *sc = ucom->sc_parent; usbd_transfer_start(sc->sc_xfer[ucom->sc_subunit][U3G_BULK_WR]); - return; } static void @@ -926,7 +947,6 @@ u3g_stop_write(struct ucom_softc *ucom) struct u3g_softc *sc = ucom->sc_parent; usbd_transfer_stop(sc->sc_xfer[ucom->sc_subunit][U3G_BULK_WR]); - return; } static void @@ -955,7 +975,6 @@ tr_setup: } break; } - return; } static void @@ -986,5 +1005,4 @@ tr_setup: } break; } - return; } Modified: stable/9/sys/dev/usb/serial/uark.c ============================================================================== --- stable/9/sys/dev/usb/serial/uark.c Tue Sep 18 16:23:23 2012 (r240658) +++ stable/9/sys/dev/usb/serial/uark.c Tue Sep 18 16:28:49 2012 (r240659) @@ -99,10 +99,12 @@ struct uark_softc { static device_probe_t uark_probe; static device_attach_t uark_attach; static device_detach_t uark_detach; +static void uark_free_softc(struct uark_softc *); static usb_callback_t uark_bulk_write_callback; static usb_callback_t uark_bulk_read_callback; +static void uark_free(struct ucom_softc *); static void uark_start_read(struct ucom_softc *); static void uark_stop_read(struct ucom_softc *); static void uark_start_write(struct ucom_softc *); @@ -147,6 +149,7 @@ static const struct ucom_callback uark_c .ucom_start_write = &uark_start_write, .ucom_stop_write = &uark_stop_write, .ucom_poll = &uark_poll, + .ucom_free = &uark_free, }; static device_method_t uark_methods[] = { @@ -154,7 +157,7 @@ static device_method_t uark_methods[] = DEVMETHOD(device_probe, uark_probe), DEVMETHOD(device_attach, uark_attach), DEVMETHOD(device_detach, uark_detach), - {0, 0} + DEVMETHOD_END }; static devclass_t uark_devclass; @@ -201,6 +204,7 @@ uark_attach(device_t dev) device_set_usb_desc(dev); mtx_init(&sc->sc_mtx, "uark", NULL, MTX_DEF); + ucom_ref(&sc->sc_super_ucom); sc->sc_udev = uaa->device; @@ -242,11 +246,31 @@ uark_detach(device_t dev) ucom_detach(&sc->sc_super_ucom, &sc->sc_ucom); usbd_transfer_unsetup(sc->sc_xfer, UARK_N_TRANSFER); - mtx_destroy(&sc->sc_mtx); + + device_claim_softc(dev); + + uark_free_softc(sc); return (0); } +UCOM_UNLOAD_DRAIN(uark); + +static void +uark_free_softc(struct uark_softc *sc) +{ + if (ucom_unref(&sc->sc_super_ucom)) { + mtx_destroy(&sc->sc_mtx); + device_free_softc(sc); + } +} + +static void +uark_free(struct ucom_softc *ucom) +{ + uark_free_softc(ucom->sc_parent); +} + static void uark_bulk_write_callback(struct usb_xfer *xfer, usb_error_t error) { Modified: stable/9/sys/dev/usb/serial/ubsa.c ============================================================================== --- stable/9/sys/dev/usb/serial/ubsa.c Tue Sep 18 16:23:23 2012 (r240658) +++ stable/9/sys/dev/usb/serial/ubsa.c Tue Sep 18 16:28:49 2012 (r240659) @@ -176,12 +176,14 @@ struct ubsa_softc { static device_probe_t ubsa_probe; static device_attach_t ubsa_attach; static device_detach_t ubsa_detach; +static void ubsa_free_softc(struct ubsa_softc *); static usb_callback_t ubsa_write_callback; static usb_callback_t ubsa_read_callback; static usb_callback_t ubsa_intr_callback; static void ubsa_cfg_request(struct ubsa_softc *, uint8_t, uint16_t); +static void ubsa_free(struct ucom_softc *); static void ubsa_cfg_set_dtr(struct ucom_softc *, uint8_t); static void ubsa_cfg_set_rts(struct ucom_softc *, uint8_t); static void ubsa_cfg_set_break(struct ucom_softc *, uint8_t); @@ -237,6 +239,7 @@ static const struct ucom_callback ubsa_c .ucom_start_write = &ubsa_start_write, .ucom_stop_write = &ubsa_stop_write, .ucom_poll = &ubsa_poll, + .ucom_free = &ubsa_free, }; static const STRUCT_USB_HOST_ID ubsa_devs[] = { @@ -262,7 +265,7 @@ static device_method_t ubsa_methods[] = DEVMETHOD(device_probe, ubsa_probe), DEVMETHOD(device_attach, ubsa_attach), DEVMETHOD(device_detach, ubsa_detach), - {0, 0} + DEVMETHOD_END }; static devclass_t ubsa_devclass; @@ -306,6 +309,7 @@ ubsa_attach(device_t dev) device_set_usb_desc(dev); mtx_init(&sc->sc_mtx, "ubsa", NULL, MTX_DEF); + ucom_ref(&sc->sc_super_ucom); sc->sc_udev = uaa->device; sc->sc_iface_no = uaa->info.bIfaceNum; @@ -348,11 +352,31 @@ ubsa_detach(device_t dev) ucom_detach(&sc->sc_super_ucom, &sc->sc_ucom); usbd_transfer_unsetup(sc->sc_xfer, UBSA_N_TRANSFER); - mtx_destroy(&sc->sc_mtx); + + device_claim_softc(dev); + + ubsa_free_softc(sc); return (0); } +UCOM_UNLOAD_DRAIN(ubsa); + +static void +ubsa_free_softc(struct ubsa_softc *sc) +{ + if (ucom_unref(&sc->sc_super_ucom)) { + mtx_destroy(&sc->sc_mtx); + device_free_softc(sc); + } +} + +static void +ubsa_free(struct ucom_softc *ucom) +{ + ubsa_free_softc(ucom->sc_parent); +} + static void ubsa_cfg_request(struct ubsa_softc *sc, uint8_t index, uint16_t value) { Modified: stable/9/sys/dev/usb/serial/ubser.c ============================================================================== --- stable/9/sys/dev/usb/serial/ubser.c Tue Sep 18 16:23:23 2012 (r240658) +++ stable/9/sys/dev/usb/serial/ubser.c Tue Sep 18 16:28:49 2012 (r240659) @@ -141,7 +141,6 @@ struct ubser_softc { uint8_t sc_iface_no; uint8_t sc_iface_index; uint8_t sc_curr_tx_unit; - uint8_t sc_name[16]; }; /* prototypes */ @@ -149,10 +148,12 @@ struct ubser_softc { static device_probe_t ubser_probe; static device_attach_t ubser_attach; static device_detach_t ubser_detach; +static void ubser_free_softc(struct ubser_softc *); static usb_callback_t ubser_write_callback; static usb_callback_t ubser_read_callback; +static void ubser_free(struct ucom_softc *); static int ubser_pre_param(struct ucom_softc *, struct termios *); static void ubser_cfg_set_break(struct ucom_softc *, uint8_t); static void ubser_cfg_get_status(struct ucom_softc *, uint8_t *, @@ -193,13 +194,14 @@ static const struct ucom_callback ubser_ .ucom_start_write = &ubser_start_write, .ucom_stop_write = &ubser_stop_write, .ucom_poll = &ubser_poll, + .ucom_free = &ubser_free, }; static device_method_t ubser_methods[] = { DEVMETHOD(device_probe, ubser_probe), DEVMETHOD(device_attach, ubser_attach), DEVMETHOD(device_detach, ubser_detach), - {0, 0} + DEVMETHOD_END }; static devclass_t ubser_devclass; @@ -243,9 +245,7 @@ ubser_attach(device_t dev) device_set_usb_desc(dev); mtx_init(&sc->sc_mtx, "ubser", NULL, MTX_DEF); - - snprintf(sc->sc_name, sizeof(sc->sc_name), "%s", - device_get_nameunit(dev)); + ucom_ref(&sc->sc_super_ucom); sc->sc_iface_no = uaa->info.bIfaceNum; sc->sc_iface_index = uaa->info.bIfaceIndex; @@ -319,11 +319,31 @@ ubser_detach(device_t dev) ucom_detach(&sc->sc_super_ucom, sc->sc_ucom); usbd_transfer_unsetup(sc->sc_xfer, UBSER_N_TRANSFER); - mtx_destroy(&sc->sc_mtx); + + device_claim_softc(dev); + + ubser_free_softc(sc); return (0); } +UCOM_UNLOAD_DRAIN(ubser); + +static void +ubser_free_softc(struct ubser_softc *sc) +{ + if (ucom_unref(&sc->sc_super_ucom)) { + mtx_destroy(&sc->sc_mtx); + device_free_softc(sc); + } +} + +static void +ubser_free(struct ucom_softc *ucom) +{ + ubser_free_softc(ucom->sc_parent); +} + static int ubser_pre_param(struct ucom_softc *ucom, struct termios *t) { Modified: stable/9/sys/dev/usb/serial/uchcom.c ============================================================================== --- stable/9/sys/dev/usb/serial/uchcom.c Tue Sep 18 16:23:23 2012 (r240658) +++ stable/9/sys/dev/usb/serial/uchcom.c Tue Sep 18 16:28:49 2012 (r240659) @@ -212,6 +212,7 @@ static const STRUCT_USB_HOST_ID uchcom_d /* protypes */ +static void uchcom_free(struct ucom_softc *); static int uchcom_pre_param(struct ucom_softc *, struct termios *); static void uchcom_cfg_get_status(struct ucom_softc *, uint8_t *, uint8_t *); @@ -235,6 +236,7 @@ static void uchcom_poll(struct ucom_soft static device_probe_t uchcom_probe; static device_attach_t uchcom_attach; static device_detach_t uchcom_detach; +static void uchcom_free_softc(struct uchcom_softc *); static usb_callback_t uchcom_intr_callback; static usb_callback_t uchcom_write_callback; @@ -283,6 +285,7 @@ static struct ucom_callback uchcom_callb .ucom_start_write = &uchcom_start_write, .ucom_stop_write = &uchcom_stop_write, .ucom_poll = &uchcom_poll, + .ucom_free = &uchcom_free, }; /* ---------------------------------------------------------------------- @@ -320,6 +323,7 @@ uchcom_attach(device_t dev) device_set_usb_desc(dev); mtx_init(&sc->sc_mtx, "uchcom", NULL, MTX_DEF); + ucom_ref(&sc->sc_super_ucom); sc->sc_udev = uaa->device; @@ -372,11 +376,31 @@ uchcom_detach(device_t dev) ucom_detach(&sc->sc_super_ucom, &sc->sc_ucom); usbd_transfer_unsetup(sc->sc_xfer, UCHCOM_N_TRANSFER); - mtx_destroy(&sc->sc_mtx); + + device_claim_softc(dev); + + uchcom_free_softc(sc); return (0); } +UCOM_UNLOAD_DRAIN(uchcom); + +static void +uchcom_free_softc(struct uchcom_softc *sc) +{ + if (ucom_unref(&sc->sc_super_ucom)) { + mtx_destroy(&sc->sc_mtx); + device_free_softc(sc); + } +} + +static void +uchcom_free(struct ucom_softc *ucom) +{ + uchcom_free_softc(ucom->sc_parent); +} + /* ---------------------------------------------------------------------- * low level i/o */ @@ -842,8 +866,7 @@ static device_method_t uchcom_methods[] DEVMETHOD(device_probe, uchcom_probe), DEVMETHOD(device_attach, uchcom_attach), DEVMETHOD(device_detach, uchcom_detach), - - {0, 0} + DEVMETHOD_END }; static driver_t uchcom_driver = { Modified: stable/9/sys/dev/usb/serial/ucycom.c ============================================================================== --- stable/9/sys/dev/usb/serial/ucycom.c Tue Sep 18 16:23:23 2012 (r240658) +++ stable/9/sys/dev/usb/serial/ucycom.c Tue Sep 18 16:28:49 2012 (r240659) @@ -101,7 +101,6 @@ struct ucycom_softc { #define UCYCOM_CFG_STOPB 0x08 #define UCYCOM_CFG_DATAB 0x03 uint8_t sc_ist; /* status flags from last input */ - uint8_t sc_name[16]; uint8_t sc_iface_no; uint8_t sc_temp_cfg[32]; }; @@ -111,10 +110,12 @@ struct ucycom_softc { static device_probe_t ucycom_probe; static device_attach_t ucycom_attach; static device_detach_t ucycom_detach; +static void ucycom_free_softc(struct ucycom_softc *); static usb_callback_t ucycom_ctrl_write_callback; static usb_callback_t ucycom_intr_read_callback; +static void ucycom_free(struct ucom_softc *); static void ucycom_cfg_open(struct ucom_softc *); static void ucycom_start_read(struct ucom_softc *); static void ucycom_stop_read(struct ucom_softc *); @@ -155,13 +156,14 @@ static const struct ucom_callback ucycom .ucom_start_write = &ucycom_start_write, .ucom_stop_write = &ucycom_stop_write, .ucom_poll = &ucycom_poll, + .ucom_free = &ucycom_free, }; static device_method_t ucycom_methods[] = { DEVMETHOD(device_probe, ucycom_probe), DEVMETHOD(device_attach, ucycom_attach), DEVMETHOD(device_detach, ucycom_detach), - {0, 0} + DEVMETHOD_END }; static devclass_t ucycom_devclass; @@ -218,9 +220,7 @@ ucycom_attach(device_t dev) device_set_usb_desc(dev); mtx_init(&sc->sc_mtx, "ucycom", NULL, MTX_DEF); - - snprintf(sc->sc_name, sizeof(sc->sc_name), - "%s", device_get_nameunit(dev)); + ucom_ref(&sc->sc_super_ucom); DPRINTF("\n"); @@ -297,11 +297,31 @@ ucycom_detach(device_t dev) ucom_detach(&sc->sc_super_ucom, &sc->sc_ucom); usbd_transfer_unsetup(sc->sc_xfer, UCYCOM_N_TRANSFER); - mtx_destroy(&sc->sc_mtx); + + device_claim_softc(dev); + + ucycom_free_softc(sc); return (0); } +UCOM_UNLOAD_DRAIN(ucycom); + +static void +ucycom_free_softc(struct ucycom_softc *sc) +{ + if (ucom_unref(&sc->sc_super_ucom)) { + mtx_destroy(&sc->sc_mtx); + device_free_softc(sc); + } +} + +static void +ucycom_free(struct ucom_softc *ucom) +{ + ucycom_free_softc(ucom->sc_parent); +} + static void ucycom_cfg_open(struct ucom_softc *ucom) { Modified: stable/9/sys/dev/usb/serial/ufoma.c ============================================================================== --- stable/9/sys/dev/usb/serial/ufoma.c Tue Sep 18 16:23:23 2012 (r240658) +++ stable/9/sys/dev/usb/serial/ufoma.c Tue Sep 18 16:28:49 2012 (r240659) @@ -195,7 +195,6 @@ struct ufoma_softc { uint8_t sc_msr; uint8_t sc_modetoactivate; uint8_t sc_currentmode; - uint8_t sc_name[16]; }; /* prototypes */ @@ -203,6 +202,7 @@ struct ufoma_softc { static device_probe_t ufoma_probe; static device_attach_t ufoma_attach; static device_detach_t ufoma_detach; +static void ufoma_free_softc(struct ufoma_softc *); static usb_callback_t ufoma_ctrl_read_callback; static usb_callback_t ufoma_ctrl_write_callback; @@ -214,6 +214,7 @@ static void *ufoma_get_intconf(struct us struct usb_interface_descriptor *, uint8_t, uint8_t); static void ufoma_cfg_link_state(struct ufoma_softc *); static void ufoma_cfg_activate_state(struct ufoma_softc *, uint16_t); +static void ufoma_free(struct ucom_softc *); static void ufoma_cfg_open(struct ucom_softc *); static void ufoma_cfg_close(struct ucom_softc *); static void ufoma_cfg_set_break(struct ucom_softc *, uint8_t); @@ -304,6 +305,7 @@ static const struct ucom_callback ufoma_ .ucom_start_write = &ufoma_start_write, .ucom_stop_write = &ufoma_stop_write, .ucom_poll = &ufoma_poll, + .ucom_free = &ufoma_free, }; static device_method_t ufoma_methods[] = { @@ -311,7 +313,7 @@ static device_method_t ufoma_methods[] = DEVMETHOD(device_probe, ufoma_probe), DEVMETHOD(device_attach, ufoma_attach), DEVMETHOD(device_detach, ufoma_detach), - {0, 0} + DEVMETHOD_END }; static devclass_t ufoma_devclass; @@ -385,13 +387,11 @@ ufoma_attach(device_t dev) sc->sc_unit = device_get_unit(dev); mtx_init(&sc->sc_mtx, "ufoma", NULL, MTX_DEF); + ucom_ref(&sc->sc_super_ucom); cv_init(&sc->sc_cv, "CWAIT"); device_set_usb_desc(dev); - snprintf(sc->sc_name, sizeof(sc->sc_name), - "%s", device_get_nameunit(dev)); - DPRINTF("\n"); /* setup control transfers */ @@ -495,12 +495,32 @@ ufoma_detach(device_t dev) if (sc->sc_modetable) { free(sc->sc_modetable, M_USBDEV); } - mtx_destroy(&sc->sc_mtx); cv_destroy(&sc->sc_cv); + device_claim_softc(dev); + + ufoma_free_softc(sc); + return (0); } +UCOM_UNLOAD_DRAIN(ufoma); + +static void +ufoma_free_softc(struct ufoma_softc *sc) +{ + if (ucom_unref(&sc->sc_super_ucom)) { + mtx_destroy(&sc->sc_mtx); + device_free_softc(sc); + } +} + +static void +ufoma_free(struct ucom_softc *ucom) +{ + ufoma_free_softc(ucom->sc_parent); +} + static void * ufoma_get_intconf(struct usb_config_descriptor *cd, struct usb_interface_descriptor *id, uint8_t type, uint8_t subtype) Modified: stable/9/sys/dev/usb/serial/uftdi.c ============================================================================== --- stable/9/sys/dev/usb/serial/uftdi.c Tue Sep 18 16:23:23 2012 (r240658) +++ stable/9/sys/dev/usb/serial/uftdi.c Tue Sep 18 16:28:49 2012 (r240659) @@ -110,8 +110,6 @@ struct uftdi_softc { uint8_t sc_hdrlen; uint8_t sc_msr; uint8_t sc_lsr; - - uint8_t sc_name[16]; }; struct uftdi_param_config { @@ -127,10 +125,12 @@ struct uftdi_param_config { static device_probe_t uftdi_probe; static device_attach_t uftdi_attach; static device_detach_t uftdi_detach; +static void uftdi_free_softc(struct uftdi_softc *); static usb_callback_t uftdi_write_callback; static usb_callback_t uftdi_read_callback; +static void uftdi_free(struct ucom_softc *); static void uftdi_cfg_open(struct ucom_softc *); static void uftdi_cfg_set_dtr(struct ucom_softc *, uint8_t); static void uftdi_cfg_set_rts(struct ucom_softc *, uint8_t); @@ -182,6 +182,7 @@ static const struct ucom_callback uftdi_ .ucom_start_write = &uftdi_start_write, .ucom_stop_write = &uftdi_stop_write, .ucom_poll = &uftdi_poll, + .ucom_free = &uftdi_free, }; static device_method_t uftdi_methods[] = { @@ -189,7 +190,6 @@ static device_method_t uftdi_methods[] = DEVMETHOD(device_probe, uftdi_probe), DEVMETHOD(device_attach, uftdi_attach), DEVMETHOD(device_detach, uftdi_detach), - DEVMETHOD_END }; @@ -304,9 +304,7 @@ uftdi_attach(device_t dev) device_set_usb_desc(dev); mtx_init(&sc->sc_mtx, "uftdi", NULL, MTX_DEF); - - snprintf(sc->sc_name, sizeof(sc->sc_name), - "%s", device_get_nameunit(dev)); + ucom_ref(&sc->sc_super_ucom); DPRINTF("\n"); @@ -368,11 +366,31 @@ uftdi_detach(device_t dev) ucom_detach(&sc->sc_super_ucom, &sc->sc_ucom); usbd_transfer_unsetup(sc->sc_xfer, UFTDI_N_TRANSFER); - mtx_destroy(&sc->sc_mtx); + + device_claim_softc(dev); + + uftdi_free_softc(sc); return (0); } +UCOM_UNLOAD_DRAIN(uftdi); + +static void +uftdi_free_softc(struct uftdi_softc *sc) +{ + if (ucom_unref(&sc->sc_super_ucom)) { + mtx_destroy(&sc->sc_mtx); + device_free_softc(sc); + } +} + +static void +uftdi_free(struct ucom_softc *ucom) +{ + uftdi_free_softc(ucom->sc_parent); +} + static void uftdi_cfg_open(struct ucom_softc *ucom) { Modified: stable/9/sys/dev/usb/serial/ugensa.c ============================================================================== --- stable/9/sys/dev/usb/serial/ugensa.c Tue Sep 18 16:23:23 2012 (r240658) +++ stable/9/sys/dev/usb/serial/ugensa.c Tue Sep 18 16:28:49 2012 (r240659) @@ -94,10 +94,12 @@ struct ugensa_softc { static device_probe_t ugensa_probe; static device_attach_t ugensa_attach; static device_detach_t ugensa_detach; +static void ugensa_free_softc(struct ugensa_softc *); static usb_callback_t ugensa_bulk_write_callback; static usb_callback_t ugensa_bulk_read_callback; +static void ugensa_free(struct ucom_softc *); static void ugensa_start_read(struct ucom_softc *); static void ugensa_stop_read(struct ucom_softc *); static void ugensa_start_write(struct ucom_softc *); @@ -131,6 +133,7 @@ static const struct ucom_callback ugensa .ucom_start_write = &ugensa_start_write, .ucom_stop_write = &ugensa_stop_write, .ucom_poll = &ugensa_poll, + .ucom_free = &ugensa_free, }; static device_method_t ugensa_methods[] = { @@ -138,7 +141,7 @@ static device_method_t ugensa_methods[] DEVMETHOD(device_probe, ugensa_probe), DEVMETHOD(device_attach, ugensa_attach), DEVMETHOD(device_detach, ugensa_detach), - {0, 0} + DEVMETHOD_END }; static devclass_t ugensa_devclass; @@ -192,6 +195,7 @@ ugensa_attach(device_t dev) device_set_usb_desc(dev); mtx_init(&sc->sc_mtx, "ugensa", NULL, MTX_DEF); + ucom_ref(&sc->sc_super_ucom); /* Figure out how many interfaces this device has got */ for (cnt = 0; cnt < UGENSA_IFACE_MAX; cnt++) { @@ -266,11 +270,31 @@ ugensa_detach(device_t dev) for (x = 0; x < sc->sc_niface; x++) { usbd_transfer_unsetup(sc->sc_sub[x].sc_xfer, UGENSA_N_TRANSFER); } - mtx_destroy(&sc->sc_mtx); + + device_claim_softc(dev); + + ugensa_free_softc(sc); return (0); } +UCOM_UNLOAD_DRAIN(ugensa); + +static void +ugensa_free_softc(struct ugensa_softc *sc) +{ + if (ucom_unref(&sc->sc_super_ucom)) { + mtx_destroy(&sc->sc_mtx); + device_free_softc(sc); + } +} + +static void +ugensa_free(struct ucom_softc *ucom) +{ + ugensa_free_softc(ucom->sc_parent); +} + static void ugensa_bulk_write_callback(struct usb_xfer *xfer, usb_error_t error) { Modified: stable/9/sys/dev/usb/serial/uipaq.c ============================================================================== --- stable/9/sys/dev/usb/serial/uipaq.c Tue Sep 18 16:23:23 2012 (r240658) +++ stable/9/sys/dev/usb/serial/uipaq.c Tue Sep 18 16:28:49 2012 (r240659) @@ -103,10 +103,12 @@ struct uipaq_softc { static device_probe_t uipaq_probe; static device_attach_t uipaq_attach; static device_detach_t uipaq_detach; +static void uipaq_free_softc(struct uipaq_softc *); static usb_callback_t uipaq_write_callback; static usb_callback_t uipaq_read_callback; +static void uipaq_free(struct ucom_softc *); static void uipaq_start_read(struct ucom_softc *); static void uipaq_stop_read(struct ucom_softc *); static void uipaq_start_write(struct ucom_softc *); @@ -146,6 +148,7 @@ static const struct ucom_callback uipaq_ .ucom_start_write = &uipaq_start_write, .ucom_stop_write = &uipaq_stop_write, .ucom_poll = &uipaq_poll, + .ucom_free = &uipaq_free, }; /* @@ -1070,7 +1073,7 @@ static device_method_t uipaq_methods[] = DEVMETHOD(device_probe, uipaq_probe), DEVMETHOD(device_attach, uipaq_attach), DEVMETHOD(device_detach, uipaq_detach), - {0, 0} + DEVMETHOD_END }; static devclass_t uipaq_devclass; @@ -1121,6 +1124,7 @@ uipaq_attach(device_t dev) device_set_usb_desc(dev); mtx_init(&sc->sc_mtx, "uipaq", NULL, MTX_DEF); + ucom_ref(&sc->sc_super_ucom); /* * Send magic bytes, cribbed from Linux ipaq driver that @@ -1176,11 +1180,31 @@ uipaq_detach(device_t dev) ucom_detach(&sc->sc_super_ucom, &sc->sc_ucom); usbd_transfer_unsetup(sc->sc_xfer, UIPAQ_N_TRANSFER); - mtx_destroy(&sc->sc_mtx); + + device_claim_softc(dev); + + uipaq_free_softc(sc); return (0); } +UCOM_UNLOAD_DRAIN(uipaq); + +static void +uipaq_free_softc(struct uipaq_softc *sc) +{ + if (ucom_unref(&sc->sc_super_ucom)) { + mtx_destroy(&sc->sc_mtx); + device_free_softc(sc); + } +} + +static void +uipaq_free(struct ucom_softc *ucom) +{ + uipaq_free_softc(ucom->sc_parent); +} + static void uipaq_start_read(struct ucom_softc *ucom) { Modified: stable/9/sys/dev/usb/serial/ulpt.c ============================================================================== --- stable/9/sys/dev/usb/serial/ulpt.c Tue Sep 18 16:23:23 2012 (r240658) +++ stable/9/sys/dev/usb/serial/ulpt.c Tue Sep 18 16:28:49 2012 (r240659) @@ -747,7 +747,7 @@ static device_method_t ulpt_methods[] = DEVMETHOD(device_probe, ulpt_probe), DEVMETHOD(device_attach, ulpt_attach), DEVMETHOD(device_detach, ulpt_detach), - {0, 0} + DEVMETHOD_END }; static driver_t ulpt_driver = { Modified: stable/9/sys/dev/usb/serial/umcs.c ============================================================================== --- stable/9/sys/dev/usb/serial/umcs.c Tue Sep 18 16:23:23 2012 (r240658) +++ stable/9/sys/dev/usb/serial/umcs.c Tue Sep 18 16:28:49 2012 (r240659) @@ -154,6 +154,7 @@ static usb_error_t umcs7840_set_UART_reg static usb_error_t umcs7840_set_baudrate(struct umcs7840_softc *, uint8_t, uint32_t); static usb_error_t umcs7840_calc_baudrate(uint32_t rate, uint16_t *, uint8_t *); +static void umcs7840_free(struct ucom_softc *); static void umcs7840_cfg_get_status(struct ucom_softc *, uint8_t *, uint8_t *); static void umcs7840_cfg_set_dtr(struct ucom_softc *, uint8_t); static void umcs7840_cfg_set_rts(struct ucom_softc *, uint8_t); @@ -175,6 +176,7 @@ static void umcs7840_poll(struct ucom_so static device_probe_t umcs7840_probe; static device_attach_t umcs7840_attach; static device_detach_t umcs7840_detach; +static void umcs7840_free_softc(struct umcs7840_softc *); static usb_callback_t umcs7840_intr_callback; static usb_callback_t umcs7840_read_callback1; @@ -251,6 +253,7 @@ static struct ucom_callback umcs7840_cal .ucom_stop_write = &umcs7840_stop_write, *** DIFF OUTPUT TRUNCATED AT 1000 LINES *** From owner-svn-src-stable@FreeBSD.ORG Tue Sep 18 16:33:53 2012 Return-Path: Delivered-To: svn-src-stable@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id B63E1106564A; Tue, 18 Sep 2012 16:33:53 +0000 (UTC) (envelope-from hselasky@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 9FF478FC1D; Tue, 18 Sep 2012 16:33:53 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q8IGXrC7025332; Tue, 18 Sep 2012 16:33:53 GMT (envelope-from hselasky@svn.freebsd.org) Received: (from hselasky@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q8IGXrKx025330; Tue, 18 Sep 2012 16:33:53 GMT (envelope-from hselasky@svn.freebsd.org) Message-Id: <201209181633.q8IGXrKx025330@svn.freebsd.org> From: Hans Petter Selasky Date: Tue, 18 Sep 2012 16:33:53 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r240660 - stable/9/sys/dev/usb/serial X-BeenThere: svn-src-stable@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for all the -stable branches of the src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 18 Sep 2012 16:33:53 -0000 Author: hselasky Date: Tue Sep 18 16:33:53 2012 New Revision: 240660 URL: http://svn.freebsd.org/changeset/base/240660 Log: MFC r239050 and r239260: Rename command defines to match names used in the datasheet. Modified: stable/9/sys/dev/usb/serial/uslcom.c Directory Properties: stable/9/sys/ (props changed) stable/9/sys/dev/ (props changed) Modified: stable/9/sys/dev/usb/serial/uslcom.c ============================================================================== --- stable/9/sys/dev/usb/serial/uslcom.c Tue Sep 18 16:28:49 2012 (r240659) +++ stable/9/sys/dev/usb/serial/uslcom.c Tue Sep 18 16:33:53 2012 (r240660) @@ -19,6 +19,12 @@ __FBSDID("$FreeBSD$"); * OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. */ +/* + * Driver for Silicon Laboratories CP2101/CP2102/CP2103/CP2104/CP2105 + * USB-Serial adapters. Based on datasheet AN571, publicly available from + * http://www.silabs.com/Support%20Documents/TechnicalDocs/AN571.pdf + */ + #include #include #include @@ -61,55 +67,54 @@ SYSCTL_INT(_hw_usb_uslcom, OID_AUTO, deb #define USLCOM_BULK_BUF_SIZE 1024 #define USLCOM_CONFIG_INDEX 0 -#define USLCOM_SET_DATA_BITS(x) ((x) << 8) - /* Request types */ #define USLCOM_WRITE 0x41 #define USLCOM_READ 0xc1 /* Request codes */ -#define USLCOM_UART 0x00 -#define USLCOM_SET_BAUD_DIV 0x01 -#define USLCOM_DATA 0x03 -#define USLCOM_BREAK 0x05 -#define USLCOM_CTRL 0x07 -#define USLCOM_RCTRL 0x08 -#define USLCOM_SET_FLOWCTRL 0x13 -#define USLCOM_SET_BAUD_RATE 0x1e +#define USLCOM_IFC_ENABLE 0x00 +#define USLCOM_SET_BAUDDIV 0x01 +#define USLCOM_SET_LINE_CTL 0x03 +#define USLCOM_SET_BREAK 0x05 +#define USLCOM_SET_MHS 0x07 +#define USLCOM_GET_MDMSTS 0x08 +#define USLCOM_SET_FLOW 0x13 +#define USLCOM_SET_BAUDRATE 0x1e #define USLCOM_VENDOR_SPECIFIC 0xff -/* USLCOM_UART values */ -#define USLCOM_UART_DISABLE 0x00 -#define USLCOM_UART_ENABLE 0x01 - -/* USLCOM_CTRL/USLCOM_RCTRL values */ -#define USLCOM_CTRL_DTR_ON 0x0001 -#define USLCOM_CTRL_DTR_SET 0x0100 -#define USLCOM_CTRL_RTS_ON 0x0002 -#define USLCOM_CTRL_RTS_SET 0x0200 -#define USLCOM_CTRL_CTS 0x0010 -#define USLCOM_CTRL_DSR 0x0020 -#define USLCOM_CTRL_RI 0x0040 -#define USLCOM_CTRL_DCD 0x0080 +/* USLCOM_IFC_ENABLE values */ +#define USLCOM_IFC_ENABLE_DIS 0x00 +#define USLCOM_IFC_ENABLE_EN 0x01 + +/* USLCOM_SET_MHS/USLCOM_GET_MDMSTS values */ +#define USLCOM_MHS_DTR_ON 0x0001 +#define USLCOM_MHS_DTR_SET 0x0100 +#define USLCOM_MHS_RTS_ON 0x0002 +#define USLCOM_MHS_RTS_SET 0x0200 +#define USLCOM_MHS_CTS 0x0010 +#define USLCOM_MHS_DSR 0x0020 +#define USLCOM_MHS_RI 0x0040 +#define USLCOM_MHS_DCD 0x0080 -/* USLCOM_SET_BAUD_DIV values */ -#define USLCOM_BAUD_REF 3686400 /* 3.6864 MHz */ +/* USLCOM_SET_BAUDDIV values */ +#define USLCOM_BAUDDIV_REF 3686400 /* 3.6864 MHz */ -/* USLCOM_DATA values */ +/* USLCOM_SET_LINE_CTL values */ #define USLCOM_STOP_BITS_1 0x00 #define USLCOM_STOP_BITS_2 0x02 #define USLCOM_PARITY_NONE 0x00 #define USLCOM_PARITY_ODD 0x10 #define USLCOM_PARITY_EVEN 0x20 +#define USLCOM_SET_DATA_BITS(x) ((x) << 8) -/* USLCOM_BREAK values */ -#define USLCOM_BREAK_OFF 0x00 -#define USLCOM_BREAK_ON 0x01 +/* USLCOM_SET_BREAK values */ +#define USLCOM_SET_BREAK_OFF 0x00 +#define USLCOM_SET_BREAK_ON 0x01 -/* USLCOM_SET_FLOWCTRL values - 1st word */ +/* USLCOM_SET_FLOW values - 1st word */ #define USLCOM_FLOW_DTR_ON 0x00000001 /* DTR static active */ #define USLCOM_FLOW_CTS_HS 0x00000008 /* CTS handshake */ -/* USLCOM_SET_FLOWCTRL values - 2nd word */ +/* USLCOM_SET_FLOW values - 2nd word */ #define USLCOM_FLOW_RTS_ON 0x00000040 /* RTS static active */ #define USLCOM_FLOW_RTS_HS 0x00000080 /* RTS handshake */ @@ -460,8 +465,8 @@ uslcom_open(struct ucom_softc *ucom) struct usb_device_request req; req.bmRequestType = USLCOM_WRITE; - req.bRequest = USLCOM_UART; - USETW(req.wValue, USLCOM_UART_ENABLE); + req.bRequest = USLCOM_IFC_ENABLE; + USETW(req.wValue, USLCOM_IFC_ENABLE_EN); USETW(req.wIndex, sc->sc_iface_no); USETW(req.wLength, 0); @@ -484,8 +489,8 @@ uslcom_close(struct ucom_softc *ucom) usb_callout_stop(&sc->sc_watchdog); req.bmRequestType = USLCOM_WRITE; - req.bRequest = USLCOM_UART; - USETW(req.wValue, USLCOM_UART_DISABLE); + req.bRequest = USLCOM_IFC_ENABLE; + USETW(req.wValue, USLCOM_IFC_ENABLE_DIS); USETW(req.wIndex, sc->sc_iface_no); USETW(req.wLength, 0); @@ -504,11 +509,11 @@ uslcom_set_dtr(struct ucom_softc *ucom, DPRINTF("onoff = %d\n", onoff); - ctl = onoff ? USLCOM_CTRL_DTR_ON : 0; - ctl |= USLCOM_CTRL_DTR_SET; + ctl = onoff ? USLCOM_MHS_DTR_ON : 0; + ctl |= USLCOM_MHS_DTR_SET; req.bmRequestType = USLCOM_WRITE; - req.bRequest = USLCOM_CTRL; + req.bRequest = USLCOM_SET_MHS; USETW(req.wValue, ctl); USETW(req.wIndex, sc->sc_iface_no); USETW(req.wLength, 0); @@ -528,11 +533,11 @@ uslcom_set_rts(struct ucom_softc *ucom, DPRINTF("onoff = %d\n", onoff); - ctl = onoff ? USLCOM_CTRL_RTS_ON : 0; - ctl |= USLCOM_CTRL_RTS_SET; + ctl = onoff ? USLCOM_MHS_RTS_ON : 0; + ctl |= USLCOM_MHS_RTS_SET; req.bmRequestType = USLCOM_WRITE; - req.bRequest = USLCOM_CTRL; + req.bRequest = USLCOM_SET_MHS; USETW(req.wValue, ctl); USETW(req.wIndex, sc->sc_iface_no); USETW(req.wLength, 0); @@ -563,7 +568,7 @@ uslcom_param(struct ucom_softc *ucom, st baudrate = t->c_ospeed; req.bmRequestType = USLCOM_WRITE; - req.bRequest = USLCOM_SET_BAUD_RATE; + req.bRequest = USLCOM_SET_BAUDRATE; USETW(req.wValue, 0); USETW(req.wIndex, sc->sc_iface_no); USETW(req.wLength, sizeof(baudrate)); @@ -600,7 +605,7 @@ uslcom_param(struct ucom_softc *ucom, st } req.bmRequestType = USLCOM_WRITE; - req.bRequest = USLCOM_DATA; + req.bRequest = USLCOM_SET_LINE_CTL; USETW(req.wValue, data); USETW(req.wIndex, sc->sc_iface_no); USETW(req.wLength, 0); @@ -613,16 +618,14 @@ uslcom_param(struct ucom_softc *ucom, st if (t->c_cflag & CRTSCTS) { flowctrl[0] = htole32(USLCOM_FLOW_DTR_ON | USLCOM_FLOW_CTS_HS); flowctrl[1] = htole32(USLCOM_FLOW_RTS_HS); - flowctrl[2] = 0; - flowctrl[3] = 0; } else { flowctrl[0] = htole32(USLCOM_FLOW_DTR_ON); flowctrl[1] = htole32(USLCOM_FLOW_RTS_ON); - flowctrl[2] = 0; - flowctrl[3] = 0; } + flowctrl[2] = 0; + flowctrl[3] = 0; req.bmRequestType = USLCOM_WRITE; - req.bRequest = USLCOM_SET_FLOWCTRL; + req.bRequest = USLCOM_SET_FLOW; USETW(req.wValue, 0); USETW(req.wIndex, sc->sc_iface_no); USETW(req.wLength, sizeof(flowctrl)); @@ -649,10 +652,10 @@ uslcom_set_break(struct ucom_softc *ucom { struct uslcom_softc *sc = ucom->sc_parent; struct usb_device_request req; - uint16_t brk = onoff ? USLCOM_BREAK_ON : USLCOM_BREAK_OFF; + uint16_t brk = onoff ? USLCOM_SET_BREAK_ON : USLCOM_SET_BREAK_OFF; req.bmRequestType = USLCOM_WRITE; - req.bRequest = USLCOM_BREAK; + req.bRequest = USLCOM_SET_BREAK; USETW(req.wValue, brk); USETW(req.wIndex, sc->sc_iface_no); USETW(req.wLength, 0); @@ -787,13 +790,13 @@ uslcom_control_callback(struct usb_xfer case USB_ST_TRANSFERRED: pc = usbd_xfer_get_frame(xfer, 1); usbd_copy_out(pc, 0, &buf, sizeof(buf)); - if (buf & USLCOM_CTRL_CTS) + if (buf & USLCOM_MHS_CTS) msr |= SER_CTS; - if (buf & USLCOM_CTRL_DSR) + if (buf & USLCOM_MHS_DSR) msr |= SER_DSR; - if (buf & USLCOM_CTRL_RI) + if (buf & USLCOM_MHS_RI) msr |= SER_RI; - if (buf & USLCOM_CTRL_DCD) + if (buf & USLCOM_MHS_DCD) msr |= SER_DCD; if (msr != sc->sc_msr) { @@ -806,7 +809,7 @@ uslcom_control_callback(struct usb_xfer case USB_ST_SETUP: req.bmRequestType = USLCOM_READ; - req.bRequest = USLCOM_RCTRL; + req.bRequest = USLCOM_GET_MDMSTS; USETW(req.wValue, 0); USETW(req.wIndex, sc->sc_iface_no); USETW(req.wLength, sizeof(buf)); From owner-svn-src-stable@FreeBSD.ORG Tue Sep 18 16:37:12 2012 Return-Path: Delivered-To: svn-src-stable@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 43A67106564A; Tue, 18 Sep 2012 16:37:12 +0000 (UTC) (envelope-from hselasky@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 2BEA18FC0C; Tue, 18 Sep 2012 16:37:12 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q8IGbCYl025780; Tue, 18 Sep 2012 16:37:12 GMT (envelope-from hselasky@svn.freebsd.org) Received: (from hselasky@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q8IGbBZt025778; Tue, 18 Sep 2012 16:37:11 GMT (envelope-from hselasky@svn.freebsd.org) Message-Id: <201209181637.q8IGbBZt025778@svn.freebsd.org> From: Hans Petter Selasky Date: Tue, 18 Sep 2012 16:37:11 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r240661 - stable/9/sys/dev/usb/storage X-BeenThere: svn-src-stable@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for all the -stable branches of the src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 18 Sep 2012 16:37:12 -0000 Author: hselasky Date: Tue Sep 18 16:37:11 2012 New Revision: 240661 URL: http://svn.freebsd.org/changeset/base/240661 Log: MFC r232361: Style change: Expand redundant #if's. Remove a couple of empty lines. Modified: stable/9/sys/dev/usb/storage/umass.c Directory Properties: stable/9/sys/ (props changed) stable/9/sys/dev/ (props changed) Modified: stable/9/sys/dev/usb/storage/umass.c ============================================================================== --- stable/9/sys/dev/usb/storage/umass.c Tue Sep 18 16:33:53 2012 (r240660) +++ stable/9/sys/dev/usb/storage/umass.c Tue Sep 18 16:37:11 2012 (r240661) @@ -137,14 +137,6 @@ __FBSDID("$FreeBSD$"); #include -#define UMASS_EXT_BUFFER -#ifdef UMASS_EXT_BUFFER -/* this enables loading of virtual buffers into DMA */ -#define UMASS_USB_FLAGS .ext_buffer=1, -#else -#define UMASS_USB_FLAGS -#endif - #ifdef USB_DEBUG #define DIF(m, x) \ do { \ @@ -542,7 +534,7 @@ static struct usb_config umass_bbb_confi .endpoint = UE_ADDR_ANY, .direction = UE_DIR_IN, .bufsize = UMASS_BULK_SIZE, - .flags = {.proxy_buffer = 1,.short_xfer_ok = 1, UMASS_USB_FLAGS}, + .flags = {.proxy_buffer = 1,.short_xfer_ok = 1,.ext_buffer=1,}, .callback = &umass_t_bbb_data_read_callback, .timeout = 0, /* overwritten later */ }, @@ -561,7 +553,7 @@ static struct usb_config umass_bbb_confi .endpoint = UE_ADDR_ANY, .direction = UE_DIR_OUT, .bufsize = UMASS_BULK_SIZE, - .flags = {.proxy_buffer = 1,.short_xfer_ok = 1, UMASS_USB_FLAGS}, + .flags = {.proxy_buffer = 1,.short_xfer_ok = 1,.ext_buffer=1,}, .callback = &umass_t_bbb_data_write_callback, .timeout = 0, /* overwritten later */ }, @@ -634,7 +626,7 @@ static struct usb_config umass_cbi_confi .endpoint = UE_ADDR_ANY, .direction = UE_DIR_IN, .bufsize = UMASS_BULK_SIZE, - .flags = {.proxy_buffer = 1,.short_xfer_ok = 1, UMASS_USB_FLAGS}, + .flags = {.proxy_buffer = 1,.short_xfer_ok = 1,.ext_buffer=1,}, .callback = &umass_t_cbi_data_read_callback, .timeout = 0, /* overwritten later */ }, @@ -653,7 +645,7 @@ static struct usb_config umass_cbi_confi .endpoint = UE_ADDR_ANY, .direction = UE_DIR_OUT, .bufsize = UMASS_BULK_SIZE, - .flags = {.proxy_buffer = 1,.short_xfer_ok = 1, UMASS_USB_FLAGS}, + .flags = {.proxy_buffer = 1,.short_xfer_ok = 1,.ext_buffer=1,}, .callback = &umass_t_cbi_data_write_callback, .timeout = 0, /* overwritten later */ }, @@ -1053,14 +1045,11 @@ umass_detach(device_t dev) usbd_transfer_unsetup(sc->sc_xfer, UMASS_T_MAX); -#if (__FreeBSD_version >= 700037) mtx_lock(&sc->sc_mtx); -#endif umass_cam_detach_sim(sc); -#if (__FreeBSD_version >= 700037) mtx_unlock(&sc->sc_mtx); -#endif + mtx_destroy(&sc->sc_mtx); return (0); /* success */ @@ -1201,7 +1190,6 @@ umass_t_bbb_reset1_callback(struct usb_x default: /* Error */ umass_tr_error(xfer, error); return; - } } @@ -1240,7 +1228,6 @@ tr_transferred: default: /* Error */ umass_tr_error(xfer, error); return; - } } @@ -1326,7 +1313,6 @@ umass_t_bbb_command_callback(struct usb_ default: /* Error */ umass_tr_error(xfer, error); return; - } } @@ -1335,19 +1321,12 @@ umass_t_bbb_data_read_callback(struct us { struct umass_softc *sc = usbd_xfer_softc(xfer); uint32_t max_bulk = usbd_xfer_max_len(xfer); -#ifndef UMASS_EXT_BUFFER - struct usb_page_cache *pc; -#endif int actlen, sumlen; usbd_xfer_status(xfer, &actlen, &sumlen, NULL, NULL); switch (USB_GET_STATE(xfer)) { case USB_ST_TRANSFERRED: -#ifndef UMASS_EXT_BUFFER - pc = usbd_xfer_get_frame(xfer, 0); - usbd_copy_out(pc, 0, sc->sc_transfer.data_ptr, actlen); -#endif sc->sc_transfer.data_rem -= actlen; sc->sc_transfer.data_ptr += actlen; sc->sc_transfer.actlen += actlen; @@ -1369,12 +1348,9 @@ umass_t_bbb_data_read_callback(struct us } usbd_xfer_set_timeout(xfer, sc->sc_transfer.data_timeout); -#ifdef UMASS_EXT_BUFFER usbd_xfer_set_frame_data(xfer, 0, sc->sc_transfer.data_ptr, max_bulk); -#else - usbd_xfer_set_frame_len(xfer, 0, max_bulk); -#endif + usbd_transfer_submit(xfer); return; @@ -1385,7 +1361,6 @@ umass_t_bbb_data_read_callback(struct us umass_transfer_start(sc, UMASS_T_BBB_DATA_RD_CS); } return; - } } @@ -1401,9 +1376,6 @@ umass_t_bbb_data_write_callback(struct u { struct umass_softc *sc = usbd_xfer_softc(xfer); uint32_t max_bulk = usbd_xfer_max_len(xfer); -#ifndef UMASS_EXT_BUFFER - struct usb_page_cache *pc; -#endif int actlen, sumlen; usbd_xfer_status(xfer, &actlen, &sumlen, NULL, NULL); @@ -1431,14 +1403,8 @@ umass_t_bbb_data_write_callback(struct u } usbd_xfer_set_timeout(xfer, sc->sc_transfer.data_timeout); -#ifdef UMASS_EXT_BUFFER usbd_xfer_set_frame_data(xfer, 0, sc->sc_transfer.data_ptr, max_bulk); -#else - pc = usbd_xfer_get_frame(xfer, 0); - usbd_copy_in(pc, 0, sc->sc_transfer.data_ptr, max_bulk); - usbd_xfer_set_frame_len(xfer, 0, max_bulk); -#endif usbd_transfer_submit(xfer); return; @@ -1450,7 +1416,6 @@ umass_t_bbb_data_write_callback(struct u umass_transfer_start(sc, UMASS_T_BBB_DATA_WR_CS); } return; - } } @@ -1576,7 +1541,6 @@ tr_error: umass_transfer_start(sc, UMASS_T_BBB_DATA_RD_CS); } return; - } } @@ -1728,7 +1692,6 @@ umass_t_cbi_reset1_callback(struct usb_x else umass_transfer_start(sc, UMASS_T_CBI_RESET2); break; - } } @@ -1783,7 +1746,6 @@ tr_transferred: default: /* Error */ umass_tr_error(xfer, error); break; - } } @@ -1873,19 +1835,12 @@ umass_t_cbi_data_read_callback(struct us { struct umass_softc *sc = usbd_xfer_softc(xfer); uint32_t max_bulk = usbd_xfer_max_len(xfer); -#ifndef UMASS_EXT_BUFFER - struct usb_page_cache *pc; -#endif int actlen, sumlen; usbd_xfer_status(xfer, &actlen, &sumlen, NULL, NULL); switch (USB_GET_STATE(xfer)) { case USB_ST_TRANSFERRED: -#ifndef UMASS_EXT_BUFFER - pc = usbd_xfer_get_frame(xfer, 0); - usbd_copy_out(pc, 0, sc->sc_transfer.data_ptr, actlen); -#endif sc->sc_transfer.data_rem -= actlen; sc->sc_transfer.data_ptr += actlen; sc->sc_transfer.actlen += actlen; @@ -1907,12 +1862,9 @@ umass_t_cbi_data_read_callback(struct us } usbd_xfer_set_timeout(xfer, sc->sc_transfer.data_timeout); -#ifdef UMASS_EXT_BUFFER usbd_xfer_set_frame_data(xfer, 0, sc->sc_transfer.data_ptr, max_bulk); -#else - usbd_xfer_set_frame_len(xfer, 0, max_bulk); -#endif + usbd_transfer_submit(xfer); break; @@ -1924,7 +1876,6 @@ umass_t_cbi_data_read_callback(struct us umass_transfer_start(sc, UMASS_T_CBI_DATA_RD_CS); } break; - } } @@ -1940,9 +1891,6 @@ umass_t_cbi_data_write_callback(struct u { struct umass_softc *sc = usbd_xfer_softc(xfer); uint32_t max_bulk = usbd_xfer_max_len(xfer); -#ifndef UMASS_EXT_BUFFER - struct usb_page_cache *pc; -#endif int actlen, sumlen; usbd_xfer_status(xfer, &actlen, &sumlen, NULL, NULL); @@ -1970,14 +1918,8 @@ umass_t_cbi_data_write_callback(struct u } usbd_xfer_set_timeout(xfer, sc->sc_transfer.data_timeout); -#ifdef UMASS_EXT_BUFFER usbd_xfer_set_frame_data(xfer, 0, sc->sc_transfer.data_ptr, max_bulk); -#else - pc = usbd_xfer_get_frame(xfer, 0); - usbd_copy_in(pc, 0, sc->sc_transfer.data_ptr, max_bulk); - usbd_xfer_set_frame_len(xfer, 0, max_bulk); -#endif usbd_transfer_submit(xfer); break; @@ -1990,7 +1932,6 @@ umass_t_cbi_data_write_callback(struct u umass_transfer_start(sc, UMASS_T_CBI_DATA_WR_CS); } break; - } } @@ -2092,7 +2033,6 @@ tr_setup: usbd_errstr(error)); umass_tr_error(xfer, error); break; - } } @@ -2121,9 +2061,7 @@ umass_cam_attach_sim(struct umass_softc DEVNAME_SIM, sc /* priv */ , sc->sc_unit /* unit number */ , -#if (__FreeBSD_version >= 700037) &sc->sc_mtx /* mutex */ , -#endif 1 /* maximum device openings */ , 0 /* maximum tagged device openings */ , devq); @@ -2133,27 +2071,15 @@ umass_cam_attach_sim(struct umass_softc return (ENOMEM); } -#if (__FreeBSD_version >= 700037) mtx_lock(&sc->sc_mtx); -#endif -#if (__FreeBSD_version >= 700048) - if (xpt_bus_register(sc->sc_sim, sc->sc_dev, sc->sc_unit) != CAM_SUCCESS) { + if (xpt_bus_register(sc->sc_sim, sc->sc_dev, + sc->sc_unit) != CAM_SUCCESS) { mtx_unlock(&sc->sc_mtx); return (ENOMEM); } -#else - if (xpt_bus_register(sc->sc_sim, sc->sc_unit) != CAM_SUCCESS) { -#if (__FreeBSD_version >= 700037) - mtx_unlock(&sc->sc_mtx); -#endif - return (ENOMEM); - } -#endif - -#if (__FreeBSD_version >= 700037) mtx_unlock(&sc->sc_mtx); -#endif + return (0); } @@ -2204,11 +2130,6 @@ umass_cam_action(struct cam_sim *sim, un xpt_done(ccb); return; } - if (sc) { -#if (__FreeBSD_version < 700037) - mtx_lock(&sc->sc_mtx); -#endif - } /* * Verify, depending on the operation to perform, that we either got * a valid sc, because an existing target was referenced, or @@ -2411,12 +2332,11 @@ umass_cam_action(struct cam_sim *sim, un strlcpy(cpi->dev_name, cam_sim_name(sim), DEV_IDLEN); cpi->unit_number = cam_sim_unit(sim); cpi->bus_id = sc->sc_unit; -#if (__FreeBSD_version >= 700025) cpi->protocol = PROTO_SCSI; cpi->protocol_version = SCSI_REV_2; cpi->transport = XPORT_USB; cpi->transport_version = 0; -#endif + if (sc == NULL) { cpi->base_transfer_speed = 0; cpi->max_lun = 0; @@ -2468,16 +2388,12 @@ umass_cam_action(struct cam_sim *sim, un cam_sim_path(sc->sc_sim), ccb->ccb_h.target_id, ccb->ccb_h.target_lun); -#if (__FreeBSD_version >= 700025) cts->protocol = PROTO_SCSI; cts->protocol_version = SCSI_REV_2; cts->transport = XPORT_USB; cts->transport_version = 0; cts->xport_specific.valid = 0; -#else - cts->valid = 0; - cts->flags = 0; /* no disconnection, tagging */ -#endif + ccb->ccb_h.status = CAM_REQ_CMP; xpt_done(ccb); break; @@ -2520,11 +2436,6 @@ umass_cam_action(struct cam_sim *sim, un } done: -#if (__FreeBSD_version < 700037) - if (sc) { - mtx_unlock(&sc->sc_mtx); - } -#endif return; } From owner-svn-src-stable@FreeBSD.ORG Tue Sep 18 16:39:04 2012 Return-Path: Delivered-To: svn-src-stable@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id ACDBD1065673; Tue, 18 Sep 2012 16:39:04 +0000 (UTC) (envelope-from hselasky@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 972D78FC17; Tue, 18 Sep 2012 16:39:04 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q8IGd4vm026061; Tue, 18 Sep 2012 16:39:04 GMT (envelope-from hselasky@svn.freebsd.org) Received: (from hselasky@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q8IGd45G026059; Tue, 18 Sep 2012 16:39:04 GMT (envelope-from hselasky@svn.freebsd.org) Message-Id: <201209181639.q8IGd45G026059@svn.freebsd.org> From: Hans Petter Selasky Date: Tue, 18 Sep 2012 16:39:04 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r240662 - stable/9/sys/dev/usb/storage X-BeenThere: svn-src-stable@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for all the -stable branches of the src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 18 Sep 2012 16:39:04 -0000 Author: hselasky Date: Tue Sep 18 16:39:04 2012 New Revision: 240662 URL: http://svn.freebsd.org/changeset/base/240662 Log: MFC r232358: Close a detach race. Make sure all pending CCB's get canceled at device detach. Modified: stable/9/sys/dev/usb/storage/umass.c Directory Properties: stable/9/sys/ (props changed) stable/9/sys/dev/ (props changed) Modified: stable/9/sys/dev/usb/storage/umass.c ============================================================================== --- stable/9/sys/dev/usb/storage/umass.c Tue Sep 18 16:37:11 2012 (r240661) +++ stable/9/sys/dev/usb/storage/umass.c Tue Sep 18 16:39:04 2012 (r240662) @@ -1046,6 +1046,11 @@ umass_detach(device_t dev) usbd_transfer_unsetup(sc->sc_xfer, UMASS_T_MAX); mtx_lock(&sc->sc_mtx); + + /* cancel any leftover CCB's */ + + umass_cancel_ccb(sc); + umass_cam_detach_sim(sc); mtx_unlock(&sc->sc_mtx); @@ -1571,8 +1576,7 @@ umass_command_start(struct umass_softc * if (sc->sc_xfer[sc->sc_last_xfer_index]) { usbd_transfer_start(sc->sc_xfer[sc->sc_last_xfer_index]); } else { - ccb->ccb_h.status = CAM_TID_INVALID; - xpt_done(ccb); + umass_cancel_ccb(sc); } } From owner-svn-src-stable@FreeBSD.ORG Tue Sep 18 16:49:58 2012 Return-Path: Delivered-To: svn-src-stable@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 22D2D106567F; Tue, 18 Sep 2012 16:49:57 +0000 (UTC) (envelope-from gjb@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id D9D368FC1C; Tue, 18 Sep 2012 16:49:57 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q8IGnvAZ027508; Tue, 18 Sep 2012 16:49:57 GMT (envelope-from gjb@svn.freebsd.org) Received: (from gjb@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q8IGnvmK027506; Tue, 18 Sep 2012 16:49:57 GMT (envelope-from gjb@svn.freebsd.org) Message-Id: <201209181649.q8IGnvmK027506@svn.freebsd.org> From: Glen Barber Date: Tue, 18 Sep 2012 16:49:57 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r240663 - stable/9/release/doc/en_US.ISO8859-1/installation X-BeenThere: svn-src-stable@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for all the -stable branches of the src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 18 Sep 2012 16:49:58 -0000 Author: gjb (doc,ports committer) Date: Tue Sep 18 16:49:57 2012 New Revision: 240663 URL: http://svn.freebsd.org/changeset/base/240663 Log: Convert installation article to XML stanards. This commit should be the final fix for the 9-STABLE release build. This is a direct commit to stable/9. Modified: stable/9/release/doc/en_US.ISO8859-1/installation/article.sgml Modified: stable/9/release/doc/en_US.ISO8859-1/installation/article.sgml ============================================================================== --- stable/9/release/doc/en_US.ISO8859-1/installation/article.sgml Tue Sep 18 16:39:04 2012 (r240662) +++ stable/9/release/doc/en_US.ISO8859-1/installation/article.sgml Tue Sep 18 16:49:57 2012 (r240663) @@ -1,9 +1,15 @@ - -%articles.ent; + + +%entities; %release; + + + + + ]>
From owner-svn-src-stable@FreeBSD.ORG Tue Sep 18 17:03:33 2012 Return-Path: Delivered-To: svn-src-stable@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 087F31065701; Tue, 18 Sep 2012 17:03:33 +0000 (UTC) (envelope-from hselasky@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id E1CEA8FC15; Tue, 18 Sep 2012 17:03:32 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q8IH3WVB029256; Tue, 18 Sep 2012 17:03:32 GMT (envelope-from hselasky@svn.freebsd.org) Received: (from hselasky@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q8IH3WhV029251; Tue, 18 Sep 2012 17:03:32 GMT (envelope-from hselasky@svn.freebsd.org) Message-Id: <201209181703.q8IH3WhV029251@svn.freebsd.org> From: Hans Petter Selasky Date: Tue, 18 Sep 2012 17:03:32 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r240664 - in stable/9/sys/dev/usb: . quirk serial X-BeenThere: svn-src-stable@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for all the -stable branches of the src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 18 Sep 2012 17:03:33 -0000 Author: hselasky Date: Tue Sep 18 17:03:32 2012 New Revision: 240664 URL: http://svn.freebsd.org/changeset/base/240664 Log: MFC r237079, r238078, r238779, r238803, r238804, r239055, r239298, r239358 and r239567: Add new USB ID's and some quirks. Modified: stable/9/sys/dev/usb/quirk/usb_quirk.c stable/9/sys/dev/usb/serial/uftdi.c stable/9/sys/dev/usb/serial/uftdi_reg.h stable/9/sys/dev/usb/usbdevs Directory Properties: stable/9/sys/ (props changed) stable/9/sys/dev/ (props changed) Modified: stable/9/sys/dev/usb/quirk/usb_quirk.c ============================================================================== --- stable/9/sys/dev/usb/quirk/usb_quirk.c Tue Sep 18 16:49:57 2012 (r240663) +++ stable/9/sys/dev/usb/quirk/usb_quirk.c Tue Sep 18 17:03:32 2012 (r240664) @@ -125,6 +125,8 @@ static struct usb_quirk_entry usb_quirks /* MS keyboards do weird things */ USB_QUIRK(MICROSOFT, NATURAL4000, 0x0000, 0xFFFF, UQ_KBD_BOOTPROTO), USB_QUIRK(MICROSOFT, WLINTELLIMOUSE, 0x0000, 0xffff, UQ_MS_LEADING_BYTE), + /* Quirk for Corsair Vengeance K60 keyboard */ + USB_QUIRK(CORSAIR, K60, 0x0000, 0xffff, UQ_KBD_BOOTPROTO), /* umodem(4) device quirks */ USB_QUIRK(METRICOM, RICOCHET_GS, 0x100, 0x100, UQ_ASSUME_CM_OVER_DATA), USB_QUIRK(SANYO, SCP4900, 0x000, 0x000, UQ_ASSUME_CM_OVER_DATA), @@ -438,6 +440,9 @@ static struct usb_quirk_entry usb_quirks USB_QUIRK(MEIZU, M6_SL, 0x0000, 0xffff, UQ_MSC_FORCE_WIRE_BBB, UQ_MSC_FORCE_PROTO_SCSI, UQ_MSC_NO_INQUIRY, UQ_MSC_NO_SYNC_CACHE), + USB_QUIRK(TOSHIBA, TRANSMEMORY, 0x0000, 0xffff, UQ_MSC_NO_SYNC_CACHE), + USB_QUIRK(VIALABS, USB30SATABRIDGE, 0x0000, 0xffff, UQ_MSC_NO_SYNC_CACHE), + /* Non-standard USB MIDI devices */ USB_QUIRK(ROLAND, UM1, 0x0000, 0xffff, UQ_AU_VENDOR_CLASS), USB_QUIRK(ROLAND, SC8850, 0x0000, 0xffff, UQ_AU_VENDOR_CLASS), @@ -455,7 +460,13 @@ static struct usb_quirk_entry usb_quirks USB_QUIRK(ROLAND, SD20, 0x0000, 0xffff, UQ_AU_VENDOR_CLASS), USB_QUIRK(ROLAND, SD80, 0x0000, 0xffff, UQ_AU_VENDOR_CLASS), USB_QUIRK(ROLAND, UA700, 0x0000, 0xffff, UQ_AU_VENDOR_CLASS), + USB_QUIRK(EGO, M4U, 0x0000, 0xffff, UQ_SINGLE_CMD_MIDI), + USB_QUIRK(LOGILINK, U2M, 0x0000, 0xffff, UQ_SINGLE_CMD_MIDI), USB_QUIRK(MEDELI, DD305, 0x0000, 0xffff, UQ_SINGLE_CMD_MIDI, UQ_MATCH_VENDOR_ONLY), + USB_QUIRK(REDOCTANE, GHMIDI, 0x0000, 0xffff, UQ_SINGLE_CMD_MIDI), + USB_QUIRK(TEXTECH, U2M_1, 0x0000, 0xffff, UQ_SINGLE_CMD_MIDI), + USB_QUIRK(TEXTECH, U2M_2, 0x0000, 0xffff, UQ_SINGLE_CMD_MIDI), + USB_QUIRK(WCH2, U2M, 0x0000, 0xffff, UQ_SINGLE_CMD_MIDI), /* * Quirks for manufacturers which USB devices does not respond Modified: stable/9/sys/dev/usb/serial/uftdi.c ============================================================================== --- stable/9/sys/dev/usb/serial/uftdi.c Tue Sep 18 16:49:57 2012 (r240663) +++ stable/9/sys/dev/usb/serial/uftdi.c Tue Sep 18 17:03:32 2012 (r240664) @@ -209,53 +209,635 @@ MODULE_VERSION(uftdi, 1); static const STRUCT_USB_HOST_ID uftdi_devs[] = { #define UFTDI_DEV(v, p, i) \ { USB_VPI(USB_VENDOR_##v, USB_PRODUCT_##v##_##p, i) } + UFTDI_DEV(ACTON, SPECTRAPRO, UFTDI_TYPE_AUTO), + UFTDI_DEV(ALTI2, N3, UFTDI_TYPE_AUTO), + UFTDI_DEV(ANALOGDEVICES, GNICE, UFTDI_TYPE_AUTO | UFTDI_FLAG_JTAG), + UFTDI_DEV(ANALOGDEVICES, GNICEPLUS, UFTDI_TYPE_AUTO | UFTDI_FLAG_JTAG), UFTDI_DEV(ATMEL, STK541, UFTDI_TYPE_8U232AM), + UFTDI_DEV(BAYER, CONTOUR_CABLE, UFTDI_TYPE_AUTO), + UFTDI_DEV(BBELECTRONICS, 232USB9M, UFTDI_TYPE_AUTO), + UFTDI_DEV(BBELECTRONICS, 485USB9F_2W, UFTDI_TYPE_AUTO), + UFTDI_DEV(BBELECTRONICS, 485USB9F_4W, UFTDI_TYPE_AUTO), + UFTDI_DEV(BBELECTRONICS, 485USBTB_2W, UFTDI_TYPE_AUTO), + UFTDI_DEV(BBELECTRONICS, 485USBTB_4W, UFTDI_TYPE_AUTO), + UFTDI_DEV(BBELECTRONICS, TTL3USB9M, UFTDI_TYPE_AUTO), + UFTDI_DEV(BBELECTRONICS, TTL5USB9M, UFTDI_TYPE_AUTO), + UFTDI_DEV(BBELECTRONICS, USO9ML2, UFTDI_TYPE_AUTO), + UFTDI_DEV(BBELECTRONICS, USO9ML2DR, UFTDI_TYPE_AUTO), + UFTDI_DEV(BBELECTRONICS, USO9ML2DR_2, UFTDI_TYPE_AUTO), + UFTDI_DEV(BBELECTRONICS, USOPTL4, UFTDI_TYPE_AUTO), + UFTDI_DEV(BBELECTRONICS, USOPTL4DR, UFTDI_TYPE_AUTO), + UFTDI_DEV(BBELECTRONICS, USOPTL4DR2, UFTDI_TYPE_AUTO), UFTDI_DEV(BBELECTRONICS, USOTL4, UFTDI_TYPE_8U232AM), - UFTDI_DEV(DRESDENELEKTRONIK, SENSORTERMINALBOARD, - UFTDI_TYPE_8U232AM), - UFTDI_DEV(DRESDENELEKTRONIK, WIRELESSHANDHELDTERMINAL, - UFTDI_TYPE_8U232AM), + UFTDI_DEV(BBELECTRONICS, USPTL4, UFTDI_TYPE_AUTO), + UFTDI_DEV(BBELECTRONICS, USTL4, UFTDI_TYPE_AUTO), + UFTDI_DEV(BBELECTRONICS, ZZ_PROG1_USB, UFTDI_TYPE_AUTO), + UFTDI_DEV(CONTEC, COM1USBH, UFTDI_TYPE_AUTO), + UFTDI_DEV(DRESDENELEKTRONIK, SENSORTERMINALBOARD, UFTDI_TYPE_8U232AM), + UFTDI_DEV(DRESDENELEKTRONIK, WIRELESSHANDHELDTERMINAL, UFTDI_TYPE_8U232AM), + UFTDI_DEV(ELEKTOR, FT323R, UFTDI_TYPE_AUTO), + UFTDI_DEV(EVOLUTION, ER1, UFTDI_TYPE_AUTO), + UFTDI_DEV(EVOLUTION, HYBRID, UFTDI_TYPE_AUTO), + UFTDI_DEV(EVOLUTION, RCM4, UFTDI_TYPE_AUTO), + UFTDI_DEV(FALCOM, SAMBA, UFTDI_TYPE_AUTO), UFTDI_DEV(FALCOM, TWIST, UFTDI_TYPE_8U232AM), + UFTDI_DEV(FIC, NEO1973_DEBUG, UFTDI_TYPE_AUTO | UFTDI_FLAG_JTAG), + UFTDI_DEV(FIC, NEO1973_DEBUG, UFTDI_TYPE_AUTO | UFTDI_FLAG_JTAG), + UFTDI_DEV(FTDI, 232H, UFTDI_TYPE_AUTO), + UFTDI_DEV(FTDI, 232RL, UFTDI_TYPE_AUTO), + UFTDI_DEV(FTDI, 4N_GALAXY_DE_1, UFTDI_TYPE_AUTO), + UFTDI_DEV(FTDI, 4N_GALAXY_DE_2, UFTDI_TYPE_AUTO), + UFTDI_DEV(FTDI, 4N_GALAXY_DE_3, UFTDI_TYPE_AUTO), + UFTDI_DEV(FTDI, 8U232AM_ALT, UFTDI_TYPE_AUTO), + UFTDI_DEV(FTDI, ACCESSO, UFTDI_TYPE_AUTO), + UFTDI_DEV(FTDI, ACG_HFDUAL, UFTDI_TYPE_AUTO), + UFTDI_DEV(FTDI, ACTIVE_ROBOTS, UFTDI_TYPE_AUTO), + UFTDI_DEV(FTDI, ACTZWAVE, UFTDI_TYPE_AUTO), + UFTDI_DEV(FTDI, AMC232, UFTDI_TYPE_AUTO), + UFTDI_DEV(FTDI, ARTEMIS, UFTDI_TYPE_AUTO), + UFTDI_DEV(FTDI, ASK_RDR400, UFTDI_TYPE_AUTO), + UFTDI_DEV(FTDI, ATIK_ATK16, UFTDI_TYPE_AUTO), + UFTDI_DEV(FTDI, ATIK_ATK16C, UFTDI_TYPE_AUTO), + UFTDI_DEV(FTDI, ATIK_ATK16HR, UFTDI_TYPE_AUTO), + UFTDI_DEV(FTDI, ATIK_ATK16HRC, UFTDI_TYPE_AUTO), + UFTDI_DEV(FTDI, ATIK_ATK16IC, UFTDI_TYPE_AUTO), + UFTDI_DEV(FTDI, BCS_SE923, UFTDI_TYPE_AUTO), UFTDI_DEV(FTDI, BEAGLEBONE, UFTDI_TYPE_8U232AM), + UFTDI_DEV(FTDI, CANDAPTER, UFTDI_TYPE_AUTO), + UFTDI_DEV(FTDI, CANUSB, UFTDI_TYPE_AUTO), + UFTDI_DEV(FTDI, CCSICDU20_0, UFTDI_TYPE_AUTO), + UFTDI_DEV(FTDI, CCSICDU40_1, UFTDI_TYPE_AUTO), + UFTDI_DEV(FTDI, CCSICDU64_4, UFTDI_TYPE_AUTO), + UFTDI_DEV(FTDI, CCSLOAD_N_GO_3, UFTDI_TYPE_AUTO), + UFTDI_DEV(FTDI, CCSMACHX_2, UFTDI_TYPE_AUTO), + UFTDI_DEV(FTDI, CCSPRIME8_5, UFTDI_TYPE_AUTO), UFTDI_DEV(FTDI, CFA_631, UFTDI_TYPE_8U232AM), UFTDI_DEV(FTDI, CFA_632, UFTDI_TYPE_8U232AM), UFTDI_DEV(FTDI, CFA_633, UFTDI_TYPE_8U232AM), UFTDI_DEV(FTDI, CFA_634, UFTDI_TYPE_8U232AM), UFTDI_DEV(FTDI, CFA_635, UFTDI_TYPE_8U232AM), + UFTDI_DEV(FTDI, CHAMSYS_24_MASTER_WING, UFTDI_TYPE_AUTO), + UFTDI_DEV(FTDI, CHAMSYS_MAXI_WING, UFTDI_TYPE_AUTO), + UFTDI_DEV(FTDI, CHAMSYS_MEDIA_WING, UFTDI_TYPE_AUTO), + UFTDI_DEV(FTDI, CHAMSYS_MIDI_TIMECODE, UFTDI_TYPE_AUTO), + UFTDI_DEV(FTDI, CHAMSYS_MINI_WING, UFTDI_TYPE_AUTO), + UFTDI_DEV(FTDI, CHAMSYS_PC_WING, UFTDI_TYPE_AUTO), + UFTDI_DEV(FTDI, CHAMSYS_USB_DMX, UFTDI_TYPE_AUTO), + UFTDI_DEV(FTDI, CHAMSYS_WING, UFTDI_TYPE_AUTO), + UFTDI_DEV(FTDI, COM4SM, UFTDI_TYPE_AUTO), + UFTDI_DEV(FTDI, CONVERTER_0, UFTDI_TYPE_AUTO), + UFTDI_DEV(FTDI, CONVERTER_1, UFTDI_TYPE_AUTO), + UFTDI_DEV(FTDI, CONVERTER_2, UFTDI_TYPE_AUTO), + UFTDI_DEV(FTDI, CONVERTER_3, UFTDI_TYPE_AUTO), + UFTDI_DEV(FTDI, CONVERTER_4, UFTDI_TYPE_AUTO), + UFTDI_DEV(FTDI, CONVERTER_5, UFTDI_TYPE_AUTO), + UFTDI_DEV(FTDI, CONVERTER_6, UFTDI_TYPE_AUTO), + UFTDI_DEV(FTDI, CONVERTER_7, UFTDI_TYPE_AUTO), UFTDI_DEV(FTDI, CTI_USB_MINI_485, UFTDI_TYPE_8U232AM), UFTDI_DEV(FTDI, CTI_USB_NANO_485, UFTDI_TYPE_8U232AM), + UFTDI_DEV(FTDI, DMX4ALL, UFTDI_TYPE_AUTO), + UFTDI_DEV(FTDI, DOMINTELL_DGQG, UFTDI_TYPE_AUTO), + UFTDI_DEV(FTDI, DOMINTELL_DUSB, UFTDI_TYPE_AUTO), + UFTDI_DEV(FTDI, DOTEC, UFTDI_TYPE_AUTO), + UFTDI_DEV(FTDI, ECLO_COM_1WIRE, UFTDI_TYPE_AUTO), + UFTDI_DEV(FTDI, ECO_PRO_CDS, UFTDI_TYPE_AUTO), UFTDI_DEV(FTDI, EISCOU, UFTDI_TYPE_8U232AM), + UFTDI_DEV(FTDI, ELSTER_UNICOM, UFTDI_TYPE_AUTO), + UFTDI_DEV(FTDI, ELV_ALC8500, UFTDI_TYPE_AUTO), + UFTDI_DEV(FTDI, ELV_CLI7000, UFTDI_TYPE_AUTO), + UFTDI_DEV(FTDI, ELV_CSI8, UFTDI_TYPE_AUTO), + UFTDI_DEV(FTDI, ELV_EC3000, UFTDI_TYPE_AUTO), + UFTDI_DEV(FTDI, ELV_EM1000DL, UFTDI_TYPE_AUTO), + UFTDI_DEV(FTDI, ELV_EM1010PC, UFTDI_TYPE_AUTO), + UFTDI_DEV(FTDI, ELV_FEM, UFTDI_TYPE_AUTO), + UFTDI_DEV(FTDI, ELV_FHZ1000PC, UFTDI_TYPE_AUTO), + UFTDI_DEV(FTDI, ELV_FHZ1300PC, UFTDI_TYPE_AUTO), + UFTDI_DEV(FTDI, ELV_FM3RX, UFTDI_TYPE_AUTO), + UFTDI_DEV(FTDI, ELV_FS20SIG, UFTDI_TYPE_AUTO), + UFTDI_DEV(FTDI, ELV_HS485, UFTDI_TYPE_AUTO), + UFTDI_DEV(FTDI, ELV_KL100, UFTDI_TYPE_AUTO), + UFTDI_DEV(FTDI, ELV_MSM1, UFTDI_TYPE_AUTO), + UFTDI_DEV(FTDI, ELV_PCD200, UFTDI_TYPE_AUTO), + UFTDI_DEV(FTDI, ELV_PCK100, UFTDI_TYPE_AUTO), + UFTDI_DEV(FTDI, ELV_PPS7330, UFTDI_TYPE_AUTO), + UFTDI_DEV(FTDI, ELV_RFP500, UFTDI_TYPE_AUTO), + UFTDI_DEV(FTDI, ELV_T1100, UFTDI_TYPE_AUTO), + UFTDI_DEV(FTDI, ELV_TFD128, UFTDI_TYPE_AUTO), + UFTDI_DEV(FTDI, ELV_TFM100, UFTDI_TYPE_AUTO), + UFTDI_DEV(FTDI, ELV_TWS550, UFTDI_TYPE_AUTO), + UFTDI_DEV(FTDI, ELV_UAD8, UFTDI_TYPE_AUTO), + UFTDI_DEV(FTDI, ELV_UDA7, UFTDI_TYPE_AUTO), + UFTDI_DEV(FTDI, ELV_UDF77, UFTDI_TYPE_AUTO), + UFTDI_DEV(FTDI, ELV_UIO88, UFTDI_TYPE_AUTO), + UFTDI_DEV(FTDI, ELV_ULA200, UFTDI_TYPE_AUTO), + UFTDI_DEV(FTDI, ELV_UM100, UFTDI_TYPE_AUTO), + UFTDI_DEV(FTDI, ELV_UMS100, UFTDI_TYPE_AUTO), + UFTDI_DEV(FTDI, ELV_UO100, UFTDI_TYPE_AUTO), + UFTDI_DEV(FTDI, ELV_UR100, UFTDI_TYPE_AUTO), + UFTDI_DEV(FTDI, ELV_USI2, UFTDI_TYPE_AUTO), + UFTDI_DEV(FTDI, ELV_USR, UFTDI_TYPE_AUTO), + UFTDI_DEV(FTDI, ELV_UTP8, UFTDI_TYPE_AUTO), + UFTDI_DEV(FTDI, ELV_WS300PC, UFTDI_TYPE_AUTO), + UFTDI_DEV(FTDI, ELV_WS444PC, UFTDI_TYPE_AUTO), + UFTDI_DEV(FTDI, ELV_WS500, UFTDI_TYPE_AUTO), + UFTDI_DEV(FTDI, ELV_WS550, UFTDI_TYPE_AUTO), + UFTDI_DEV(FTDI, ELV_WS777, UFTDI_TYPE_AUTO), + UFTDI_DEV(FTDI, ELV_WS888, UFTDI_TYPE_AUTO), UFTDI_DEV(FTDI, EMCU2D, UFTDI_TYPE_8U232AM), UFTDI_DEV(FTDI, EMCU2H, UFTDI_TYPE_8U232AM), + UFTDI_DEV(FTDI, FUTURE_0, UFTDI_TYPE_AUTO), + UFTDI_DEV(FTDI, FUTURE_1, UFTDI_TYPE_AUTO), + UFTDI_DEV(FTDI, FUTURE_2, UFTDI_TYPE_AUTO), UFTDI_DEV(FTDI, GAMMASCOUT, UFTDI_TYPE_8U232AM), + UFTDI_DEV(FTDI, GENERIC, UFTDI_TYPE_AUTO), + UFTDI_DEV(FTDI, GUDEADS_E808, UFTDI_TYPE_AUTO), + UFTDI_DEV(FTDI, GUDEADS_E809, UFTDI_TYPE_AUTO), + UFTDI_DEV(FTDI, GUDEADS_E80A, UFTDI_TYPE_AUTO), + UFTDI_DEV(FTDI, GUDEADS_E80B, UFTDI_TYPE_AUTO), + UFTDI_DEV(FTDI, GUDEADS_E80C, UFTDI_TYPE_AUTO), + UFTDI_DEV(FTDI, GUDEADS_E80D, UFTDI_TYPE_AUTO), + UFTDI_DEV(FTDI, GUDEADS_E80E, UFTDI_TYPE_AUTO), + UFTDI_DEV(FTDI, GUDEADS_E80F, UFTDI_TYPE_AUTO), + UFTDI_DEV(FTDI, GUDEADS_E88D, UFTDI_TYPE_AUTO), + UFTDI_DEV(FTDI, GUDEADS_E88E, UFTDI_TYPE_AUTO), + UFTDI_DEV(FTDI, GUDEADS_E88F, UFTDI_TYPE_AUTO), + UFTDI_DEV(FTDI, HD_RADIO, UFTDI_TYPE_AUTO), + UFTDI_DEV(FTDI, HO720, UFTDI_TYPE_AUTO), + UFTDI_DEV(FTDI, HO730, UFTDI_TYPE_AUTO), + UFTDI_DEV(FTDI, HO820, UFTDI_TYPE_AUTO), + UFTDI_DEV(FTDI, HO870, UFTDI_TYPE_AUTO), + UFTDI_DEV(FTDI, IBS_APP70, UFTDI_TYPE_AUTO), + UFTDI_DEV(FTDI, IBS_PCMCIA, UFTDI_TYPE_AUTO), + UFTDI_DEV(FTDI, IBS_PEDO, UFTDI_TYPE_AUTO), + UFTDI_DEV(FTDI, IBS_PICPRO, UFTDI_TYPE_AUTO), + UFTDI_DEV(FTDI, IBS_PK1, UFTDI_TYPE_AUTO), + UFTDI_DEV(FTDI, IBS_PROD, UFTDI_TYPE_AUTO), + UFTDI_DEV(FTDI, IBS_RS232MON, UFTDI_TYPE_AUTO), + UFTDI_DEV(FTDI, IBS_US485, UFTDI_TYPE_AUTO), + UFTDI_DEV(FTDI, IPLUS, UFTDI_TYPE_AUTO), + UFTDI_DEV(FTDI, IPLUS2, UFTDI_TYPE_AUTO), + UFTDI_DEV(FTDI, IRTRANS, UFTDI_TYPE_AUTO), UFTDI_DEV(FTDI, KBS, UFTDI_TYPE_8U232AM), + UFTDI_DEV(FTDI, LENZ_LIUSB, UFTDI_TYPE_AUTO), UFTDI_DEV(FTDI, LK202, UFTDI_TYPE_8U232AM), UFTDI_DEV(FTDI, LK204, UFTDI_TYPE_8U232AM), + UFTDI_DEV(FTDI, LM3S_DEVEL_BOARD, UFTDI_TYPE_AUTO | UFTDI_FLAG_JTAG), + UFTDI_DEV(FTDI, LM3S_EVAL_BOARD, UFTDI_TYPE_AUTO | UFTDI_FLAG_JTAG), + UFTDI_DEV(FTDI, MASTERDEVEL2, UFTDI_TYPE_AUTO), UFTDI_DEV(FTDI, MAXSTREAM, UFTDI_TYPE_8U232AM), + UFTDI_DEV(FTDI, MHAM_DB9, UFTDI_TYPE_AUTO), + UFTDI_DEV(FTDI, MHAM_IC, UFTDI_TYPE_AUTO), + UFTDI_DEV(FTDI, MHAM_KW, UFTDI_TYPE_AUTO), + UFTDI_DEV(FTDI, MHAM_RS232, UFTDI_TYPE_AUTO), + UFTDI_DEV(FTDI, MHAM_Y6, UFTDI_TYPE_AUTO), + UFTDI_DEV(FTDI, MHAM_Y8, UFTDI_TYPE_AUTO), + UFTDI_DEV(FTDI, MHAM_Y9, UFTDI_TYPE_AUTO), + UFTDI_DEV(FTDI, MHAM_YS, UFTDI_TYPE_AUTO), + UFTDI_DEV(FTDI, MICRO_CHAMELEON, UFTDI_TYPE_AUTO), + UFTDI_DEV(FTDI, MTXORB_5, UFTDI_TYPE_AUTO), + UFTDI_DEV(FTDI, MTXORB_6, UFTDI_TYPE_AUTO), UFTDI_DEV(FTDI, MX2_3, UFTDI_TYPE_8U232AM), UFTDI_DEV(FTDI, MX4_5, UFTDI_TYPE_8U232AM), + UFTDI_DEV(FTDI, NXTCAM, UFTDI_TYPE_AUTO), + UFTDI_DEV(FTDI, OCEANIC, UFTDI_TYPE_AUTO), + UFTDI_DEV(FTDI, OOCDLINK, UFTDI_TYPE_AUTO | UFTDI_FLAG_JTAG), + UFTDI_DEV(FTDI, OPENDCC, UFTDI_TYPE_AUTO), + UFTDI_DEV(FTDI, OPENDCC_GATEWAY, UFTDI_TYPE_AUTO), + UFTDI_DEV(FTDI, OPENDCC_GBM, UFTDI_TYPE_AUTO), + UFTDI_DEV(FTDI, OPENDCC_SNIFFER, UFTDI_TYPE_AUTO), + UFTDI_DEV(FTDI, OPENDCC_THROTTLE, UFTDI_TYPE_AUTO), + UFTDI_DEV(FTDI, PCDJ_DAC2, UFTDI_TYPE_AUTO), UFTDI_DEV(FTDI, PCMSFU, UFTDI_TYPE_8U232AM), + UFTDI_DEV(FTDI, PERLE_ULTRAPORT, UFTDI_TYPE_AUTO), + UFTDI_DEV(FTDI, PHI_FISCO, UFTDI_TYPE_AUTO), + UFTDI_DEV(FTDI, PIEGROUP, UFTDI_TYPE_AUTO), + UFTDI_DEV(FTDI, PROPOX_JTAGCABLEII, UFTDI_TYPE_AUTO), + UFTDI_DEV(FTDI, R2000KU_TRUE_RNG, UFTDI_TYPE_AUTO), + UFTDI_DEV(FTDI, R2X0, UFTDI_TYPE_AUTO), + UFTDI_DEV(FTDI, RELAIS, UFTDI_TYPE_AUTO), + UFTDI_DEV(FTDI, REU_TINY, UFTDI_TYPE_AUTO), + UFTDI_DEV(FTDI, RMP200, UFTDI_TYPE_AUTO), + UFTDI_DEV(FTDI, RM_CANVIEW, UFTDI_TYPE_AUTO), + UFTDI_DEV(FTDI, RRCIRKITS_LOCOBUFFER, UFTDI_TYPE_AUTO), + UFTDI_DEV(FTDI, SCIENCESCOPE_HS_LOGBOOK, UFTDI_TYPE_AUTO), + UFTDI_DEV(FTDI, SCIENCESCOPE_LOGBOOKML, UFTDI_TYPE_AUTO), + UFTDI_DEV(FTDI, SCIENCESCOPE_LS_LOGBOOK, UFTDI_TYPE_AUTO), + UFTDI_DEV(FTDI, SCS_DEVICE_0, UFTDI_TYPE_AUTO), + UFTDI_DEV(FTDI, SCS_DEVICE_1, UFTDI_TYPE_AUTO), + UFTDI_DEV(FTDI, SCS_DEVICE_2, UFTDI_TYPE_AUTO), + UFTDI_DEV(FTDI, SCS_DEVICE_3, UFTDI_TYPE_AUTO), + UFTDI_DEV(FTDI, SCS_DEVICE_4, UFTDI_TYPE_AUTO), + UFTDI_DEV(FTDI, SCS_DEVICE_5, UFTDI_TYPE_AUTO), + UFTDI_DEV(FTDI, SCS_DEVICE_6, UFTDI_TYPE_AUTO), + UFTDI_DEV(FTDI, SCS_DEVICE_7, UFTDI_TYPE_AUTO), + UFTDI_DEV(FTDI, SDMUSBQSS, UFTDI_TYPE_AUTO), UFTDI_DEV(FTDI, SEMC_DSS20, UFTDI_TYPE_8U232AM), UFTDI_DEV(FTDI, SERIAL_2232C, UFTDI_TYPE_8U232AM), UFTDI_DEV(FTDI, SERIAL_2232D, UFTDI_TYPE_8U232AM), + UFTDI_DEV(FTDI, SERIAL_232RL, UFTDI_TYPE_AUTO), UFTDI_DEV(FTDI, SERIAL_4232H, UFTDI_TYPE_8U232AM), UFTDI_DEV(FTDI, SERIAL_8U100AX, UFTDI_TYPE_SIO), UFTDI_DEV(FTDI, SERIAL_8U232AM, UFTDI_TYPE_8U232AM), UFTDI_DEV(FTDI, SERIAL_8U232AM4, UFTDI_TYPE_8U232AM), + UFTDI_DEV(FTDI, SIGNALYZER_SH2, UFTDI_TYPE_AUTO | UFTDI_FLAG_JTAG), + UFTDI_DEV(FTDI, SIGNALYZER_SH4, UFTDI_TYPE_AUTO | UFTDI_FLAG_JTAG), + UFTDI_DEV(FTDI, SIGNALYZER_SLITE, UFTDI_TYPE_AUTO | UFTDI_FLAG_JTAG), + UFTDI_DEV(FTDI, SIGNALYZER_ST, UFTDI_TYPE_AUTO | UFTDI_FLAG_JTAG), + UFTDI_DEV(FTDI, SPECIAL_1, UFTDI_TYPE_AUTO), + UFTDI_DEV(FTDI, SPECIAL_3, UFTDI_TYPE_AUTO), + UFTDI_DEV(FTDI, SPECIAL_4, UFTDI_TYPE_AUTO), + UFTDI_DEV(FTDI, SPROG_II, UFTDI_TYPE_AUTO), + UFTDI_DEV(FTDI, SR_RADIO, UFTDI_TYPE_AUTO), + UFTDI_DEV(FTDI, SUUNTO_SPORTS, UFTDI_TYPE_AUTO), UFTDI_DEV(FTDI, TACTRIX_OPENPORT_13M, UFTDI_TYPE_8U232AM), UFTDI_DEV(FTDI, TACTRIX_OPENPORT_13S, UFTDI_TYPE_8U232AM), UFTDI_DEV(FTDI, TACTRIX_OPENPORT_13U, UFTDI_TYPE_8U232AM), + UFTDI_DEV(FTDI, TAVIR_STK500, UFTDI_TYPE_AUTO), + UFTDI_DEV(FTDI, TERATRONIK_D2XX, UFTDI_TYPE_AUTO), + UFTDI_DEV(FTDI, TERATRONIK_VCP, UFTDI_TYPE_AUTO), + UFTDI_DEV(FTDI, THORLABS, UFTDI_TYPE_AUTO), + UFTDI_DEV(FTDI, TNC_X, UFTDI_TYPE_AUTO), + UFTDI_DEV(FTDI, TTUSB, UFTDI_TYPE_AUTO), UFTDI_DEV(FTDI, TURTELIZER2, UFTDI_TYPE_8U232AM | UFTDI_FLAG_JTAG), UFTDI_DEV(FTDI, UOPTBR, UFTDI_TYPE_8U232AM), UFTDI_DEV(FTDI, USBSERIAL, UFTDI_TYPE_8U232AM), + UFTDI_DEV(FTDI, USBX_707, UFTDI_TYPE_AUTO), UFTDI_DEV(FTDI, USB_UIRT, UFTDI_TYPE_8U232AM), + UFTDI_DEV(FTDI, USINT_CAT, UFTDI_TYPE_AUTO), + UFTDI_DEV(FTDI, USINT_RS232, UFTDI_TYPE_AUTO), + UFTDI_DEV(FTDI, USINT_WKEY, UFTDI_TYPE_AUTO), + UFTDI_DEV(FTDI, VARDAAN, UFTDI_TYPE_AUTO), + UFTDI_DEV(FTDI, VNHCPCUSB_D, UFTDI_TYPE_AUTO), + UFTDI_DEV(FTDI, WESTREX_MODEL_777, UFTDI_TYPE_AUTO), + UFTDI_DEV(FTDI, WESTREX_MODEL_8900F, UFTDI_TYPE_AUTO), + UFTDI_DEV(FTDI, XF_547, UFTDI_TYPE_AUTO), + UFTDI_DEV(FTDI, XF_640, UFTDI_TYPE_AUTO), + UFTDI_DEV(FTDI, XF_642, UFTDI_TYPE_AUTO), + UFTDI_DEV(FTDI, XM_RADIO, UFTDI_TYPE_AUTO), + UFTDI_DEV(FTDI, YEI_SERVOCENTER31, UFTDI_TYPE_AUTO), + UFTDI_DEV(GNOTOMETRICS, USB, UFTDI_TYPE_AUTO), + UFTDI_DEV(ICOM, SP1, UFTDI_TYPE_AUTO), + UFTDI_DEV(ICOM, OPC_U_UC, UFTDI_TYPE_AUTO), + UFTDI_DEV(ICOM, RP2C1, UFTDI_TYPE_AUTO), + UFTDI_DEV(ICOM, RP2C2, UFTDI_TYPE_AUTO), + UFTDI_DEV(ICOM, RP2D, UFTDI_TYPE_AUTO), + UFTDI_DEV(ICOM, RP2KVR, UFTDI_TYPE_AUTO), + UFTDI_DEV(ICOM, RP2KVT, UFTDI_TYPE_AUTO), + UFTDI_DEV(ICOM, RP2VR, UFTDI_TYPE_AUTO), + UFTDI_DEV(ICOM, RP2VT, UFTDI_TYPE_AUTO), + UFTDI_DEV(ICOM, RP4KVR, UFTDI_TYPE_AUTO), + UFTDI_DEV(ICOM, RP4KVT, UFTDI_TYPE_AUTO), + UFTDI_DEV(IDTECH, IDT1221U, UFTDI_TYPE_AUTO), + UFTDI_DEV(INTERBIOMETRICS, IOBOARD, UFTDI_TYPE_AUTO), + UFTDI_DEV(INTERBIOMETRICS, MINI_IOBOARD, UFTDI_TYPE_AUTO), UFTDI_DEV(INTREPIDCS, NEOVI, UFTDI_TYPE_8U232AM), UFTDI_DEV(INTREPIDCS, VALUECAN, UFTDI_TYPE_8U232AM), + UFTDI_DEV(IONICS, PLUGCOMPUTER, UFTDI_TYPE_AUTO | UFTDI_FLAG_JTAG), + UFTDI_DEV(JETI, SPC1201, UFTDI_TYPE_AUTO), + UFTDI_DEV(KOBIL, CONV_B1, UFTDI_TYPE_AUTO), + UFTDI_DEV(KOBIL, CONV_KAAN, UFTDI_TYPE_AUTO), + UFTDI_DEV(LARSENBRUSGAARD, ALTITRACK, UFTDI_TYPE_AUTO), UFTDI_DEV(MARVELL, SHEEVAPLUG, UFTDI_TYPE_8U232AM), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_0100, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_0101, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_0102, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_0103, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_0104, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_0105, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_0106, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_0107, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_0108, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_0109, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_010A, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_010B, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_010C, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_010D, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_010E, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_010F, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_0110, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_0111, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_0112, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_0113, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_0114, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_0115, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_0116, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_0117, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_0118, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_0119, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_011A, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_011B, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_011C, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_011D, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_011E, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_011F, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_0120, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_0121, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_0122, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_0123, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_0124, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_0125, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_0126, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_0128, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_0129, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_012A, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_012B, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_012D, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_012E, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_012F, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_0130, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_0131, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_0132, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_0133, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_0134, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_0135, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_0136, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_0137, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_0138, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_0139, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_013A, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_013B, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_013C, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_013D, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_013E, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_013F, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_0140, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_0141, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_0142, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_0143, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_0144, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_0145, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_0146, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_0147, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_0148, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_0149, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_014A, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_014B, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_014C, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_014D, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_014E, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_014F, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_0150, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_0151, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_0152, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_0159, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_015A, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_015B, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_015C, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_015D, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_015E, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_015F, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_0160, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_0161, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_0162, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_0163, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_0164, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_0165, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_0166, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_0167, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_0168, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_0169, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_016A, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_016B, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_016C, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_016D, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_016E, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_016F, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_0170, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_0171, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_0172, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_0173, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_0174, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_0175, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_0176, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_0177, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_0178, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_0179, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_017A, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_017B, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_017C, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_017D, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_017E, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_017F, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_0180, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_0181, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_0182, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_0183, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_0184, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_0185, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_0186, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_0187, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_0188, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_0189, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_018A, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_018B, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_018C, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_018D, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_018E, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_018F, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_0190, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_0191, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_0192, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_0193, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_0194, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_0195, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_0196, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_0197, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_0198, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_0199, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_019A, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_019B, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_019C, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_019D, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_019E, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_019F, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_01A0, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_01A1, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_01A2, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_01A3, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_01A4, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_01A5, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_01A6, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_01A7, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_01A8, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_01A9, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_01AA, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_01AB, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_01AC, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_01AD, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_01AE, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_01AF, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_01B0, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_01B1, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_01B2, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_01B3, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_01B4, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_01B5, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_01B6, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_01B7, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_01B8, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_01B9, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_01BA, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_01BB, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_01BC, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_01BD, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_01BE, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_01BF, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_01C0, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_01C1, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_01C2, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_01C3, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_01C4, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_01C5, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_01C6, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_01C7, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_01C8, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_01C9, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_01CA, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_01CB, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_01CC, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_01CD, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_01CE, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_01CF, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_01D0, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_01D1, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_01D2, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_01D3, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_01D4, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_01D5, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_01D6, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_01D7, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_01D8, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_01D9, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_01DA, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_01DB, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_01DC, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_01DD, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_01DE, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_01DF, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_01E0, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_01E1, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_01E2, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_01E3, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_01E4, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_01E5, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_01E6, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_01E7, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_01E8, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_01E9, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_01EA, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_01EB, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_01EC, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_01ED, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_01EE, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_01EF, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_01F0, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_01F1, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_01F2, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_01F3, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_01F4, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_01F5, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_01F6, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_01F7, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_01F8, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_01F9, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_01FA, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_01FB, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_01FC, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_01FD, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_01FE, UFTDI_TYPE_AUTO), + UFTDI_DEV(MATRIXORBITAL, FTDI_RANGE_01FF, UFTDI_TYPE_AUTO), UFTDI_DEV(MATRIXORBITAL, MOUA, UFTDI_TYPE_8U232AM), UFTDI_DEV(MELCO, PCOPRS1, UFTDI_TYPE_8U232AM), + UFTDI_DEV(METAGEEK, TELLSTICK, UFTDI_TYPE_AUTO), + UFTDI_DEV(MOBILITY, USB_SERIAL, UFTDI_TYPE_AUTO), + UFTDI_DEV(OLIMEX, ARM_USB_OCD, UFTDI_TYPE_AUTO | UFTDI_FLAG_JTAG), + UFTDI_DEV(OLIMEX, ARM_USB_OCD_H, UFTDI_TYPE_AUTO | UFTDI_FLAG_JTAG), + UFTDI_DEV(PAPOUCH, AD4USB, UFTDI_TYPE_AUTO), + UFTDI_DEV(PAPOUCH, AP485, UFTDI_TYPE_AUTO), + UFTDI_DEV(PAPOUCH, AP485_2, UFTDI_TYPE_AUTO), + UFTDI_DEV(PAPOUCH, DRAK5, UFTDI_TYPE_AUTO), + UFTDI_DEV(PAPOUCH, DRAK6, UFTDI_TYPE_AUTO), + UFTDI_DEV(PAPOUCH, GMSR, UFTDI_TYPE_AUTO), + UFTDI_DEV(PAPOUCH, GMUX, UFTDI_TYPE_AUTO), + UFTDI_DEV(PAPOUCH, IRAMP, UFTDI_TYPE_AUTO), + UFTDI_DEV(PAPOUCH, LEC, UFTDI_TYPE_AUTO), + UFTDI_DEV(PAPOUCH, MU, UFTDI_TYPE_AUTO), + UFTDI_DEV(PAPOUCH, QUIDO10X1, UFTDI_TYPE_AUTO), + UFTDI_DEV(PAPOUCH, QUIDO2X16, UFTDI_TYPE_AUTO), + UFTDI_DEV(PAPOUCH, QUIDO2X2, UFTDI_TYPE_AUTO), + UFTDI_DEV(PAPOUCH, QUIDO30X3, UFTDI_TYPE_AUTO), + UFTDI_DEV(PAPOUCH, QUIDO3X32, UFTDI_TYPE_AUTO), + UFTDI_DEV(PAPOUCH, QUIDO4X4, UFTDI_TYPE_AUTO), + UFTDI_DEV(PAPOUCH, QUIDO60X3, UFTDI_TYPE_AUTO), + UFTDI_DEV(PAPOUCH, QUIDO8X8, UFTDI_TYPE_AUTO), + UFTDI_DEV(PAPOUCH, SB232, UFTDI_TYPE_AUTO), + UFTDI_DEV(PAPOUCH, SB422, UFTDI_TYPE_AUTO), + UFTDI_DEV(PAPOUCH, SB422_2, UFTDI_TYPE_AUTO), + UFTDI_DEV(PAPOUCH, SB485, UFTDI_TYPE_AUTO), + UFTDI_DEV(PAPOUCH, SB485C, UFTDI_TYPE_AUTO), + UFTDI_DEV(PAPOUCH, SB485S, UFTDI_TYPE_AUTO), + UFTDI_DEV(PAPOUCH, SB485_2, UFTDI_TYPE_AUTO), + UFTDI_DEV(PAPOUCH, SIMUKEY, UFTDI_TYPE_AUTO), + UFTDI_DEV(PAPOUCH, TMU, UFTDI_TYPE_AUTO), + UFTDI_DEV(PAPOUCH, UPSUSB, UFTDI_TYPE_AUTO), + UFTDI_DEV(POSIFLEX, PP7000, UFTDI_TYPE_AUTO), + UFTDI_DEV(QIHARDWARE, JTAGSERIAL, UFTDI_TYPE_AUTO | UFTDI_FLAG_JTAG), UFTDI_DEV(RATOC, REXUSB60F, UFTDI_TYPE_8U232AM), - UFTDI_DEV(SIIG2, US2308, UFTDI_TYPE_8U232AM) + UFTDI_DEV(RTSYSTEMS, CT29B, UFTDI_TYPE_AUTO), + UFTDI_DEV(RTSYSTEMS, SERIAL_VX7, UFTDI_TYPE_AUTO), + UFTDI_DEV(SEALEVEL, 2101, UFTDI_TYPE_AUTO), + UFTDI_DEV(SEALEVEL, 2102, UFTDI_TYPE_AUTO), + UFTDI_DEV(SEALEVEL, 2103, UFTDI_TYPE_AUTO), + UFTDI_DEV(SEALEVEL, 2104, UFTDI_TYPE_AUTO), + UFTDI_DEV(SEALEVEL, 2106, UFTDI_TYPE_AUTO), + UFTDI_DEV(SEALEVEL, 2201_1, UFTDI_TYPE_AUTO), + UFTDI_DEV(SEALEVEL, 2201_2, UFTDI_TYPE_AUTO), + UFTDI_DEV(SEALEVEL, 2202_1, UFTDI_TYPE_AUTO), + UFTDI_DEV(SEALEVEL, 2202_2, UFTDI_TYPE_AUTO), + UFTDI_DEV(SEALEVEL, 2203_1, UFTDI_TYPE_AUTO), + UFTDI_DEV(SEALEVEL, 2203_2, UFTDI_TYPE_AUTO), + UFTDI_DEV(SEALEVEL, 2401_1, UFTDI_TYPE_AUTO), + UFTDI_DEV(SEALEVEL, 2401_2, UFTDI_TYPE_AUTO), + UFTDI_DEV(SEALEVEL, 2401_3, UFTDI_TYPE_AUTO), + UFTDI_DEV(SEALEVEL, 2401_4, UFTDI_TYPE_AUTO), + UFTDI_DEV(SEALEVEL, 2402_1, UFTDI_TYPE_AUTO), + UFTDI_DEV(SEALEVEL, 2402_2, UFTDI_TYPE_AUTO), + UFTDI_DEV(SEALEVEL, 2402_3, UFTDI_TYPE_AUTO), + UFTDI_DEV(SEALEVEL, 2402_4, UFTDI_TYPE_AUTO), + UFTDI_DEV(SEALEVEL, 2403_1, UFTDI_TYPE_AUTO), + UFTDI_DEV(SEALEVEL, 2403_2, UFTDI_TYPE_AUTO), + UFTDI_DEV(SEALEVEL, 2403_3, UFTDI_TYPE_AUTO), + UFTDI_DEV(SEALEVEL, 2403_4, UFTDI_TYPE_AUTO), + UFTDI_DEV(SEALEVEL, 2801_1, UFTDI_TYPE_AUTO), + UFTDI_DEV(SEALEVEL, 2801_2, UFTDI_TYPE_AUTO), + UFTDI_DEV(SEALEVEL, 2801_3, UFTDI_TYPE_AUTO), + UFTDI_DEV(SEALEVEL, 2801_4, UFTDI_TYPE_AUTO), + UFTDI_DEV(SEALEVEL, 2801_5, UFTDI_TYPE_AUTO), + UFTDI_DEV(SEALEVEL, 2801_6, UFTDI_TYPE_AUTO), + UFTDI_DEV(SEALEVEL, 2801_7, UFTDI_TYPE_AUTO), + UFTDI_DEV(SEALEVEL, 2801_8, UFTDI_TYPE_AUTO), + UFTDI_DEV(SEALEVEL, 2802_1, UFTDI_TYPE_AUTO), + UFTDI_DEV(SEALEVEL, 2802_2, UFTDI_TYPE_AUTO), + UFTDI_DEV(SEALEVEL, 2802_3, UFTDI_TYPE_AUTO), + UFTDI_DEV(SEALEVEL, 2802_4, UFTDI_TYPE_AUTO), + UFTDI_DEV(SEALEVEL, 2802_5, UFTDI_TYPE_AUTO), + UFTDI_DEV(SEALEVEL, 2802_6, UFTDI_TYPE_AUTO), + UFTDI_DEV(SEALEVEL, 2802_7, UFTDI_TYPE_AUTO), + UFTDI_DEV(SEALEVEL, 2802_8, UFTDI_TYPE_AUTO), + UFTDI_DEV(SEALEVEL, 2803_1, UFTDI_TYPE_AUTO), + UFTDI_DEV(SEALEVEL, 2803_2, UFTDI_TYPE_AUTO), + UFTDI_DEV(SEALEVEL, 2803_3, UFTDI_TYPE_AUTO), + UFTDI_DEV(SEALEVEL, 2803_4, UFTDI_TYPE_AUTO), + UFTDI_DEV(SEALEVEL, 2803_5, UFTDI_TYPE_AUTO), + UFTDI_DEV(SEALEVEL, 2803_6, UFTDI_TYPE_AUTO), + UFTDI_DEV(SEALEVEL, 2803_7, UFTDI_TYPE_AUTO), + UFTDI_DEV(SEALEVEL, 2803_8, UFTDI_TYPE_AUTO), + UFTDI_DEV(SIIG2, DK201, UFTDI_TYPE_AUTO), + UFTDI_DEV(SIIG2, US2308, UFTDI_TYPE_8U232AM), + UFTDI_DEV(TESTO, USB_INTERFACE, UFTDI_TYPE_AUTO), + UFTDI_DEV(TML, USB_SERIAL, UFTDI_TYPE_AUTO), + UFTDI_DEV(TTI, QL355P, UFTDI_TYPE_AUTO), + UFTDI_DEV(UNKNOWN4, NF_RIC, UFTDI_TYPE_AUTO), #undef UFTDI_DEV }; @@ -312,6 +894,17 @@ uftdi_attach(device_t dev) sc->sc_type = USB_GET_DRIVER_INFO(uaa) & UFTDI_TYPE_MASK; switch (sc->sc_type) { + case UFTDI_TYPE_AUTO: + /* simplified type check */ + if (uaa->info.bcdDevice >= 0x0200 || + usbd_get_iface(uaa->device, 1) != NULL) { + sc->sc_type = UFTDI_TYPE_8U232AM; + sc->sc_hdrlen = 0; + } else { + sc->sc_type = UFTDI_TYPE_SIO; + sc->sc_hdrlen = 1; + } + break; case UFTDI_TYPE_SIO: sc->sc_hdrlen = 1; break; Modified: stable/9/sys/dev/usb/serial/uftdi_reg.h ============================================================================== --- stable/9/sys/dev/usb/serial/uftdi_reg.h Tue Sep 18 16:49:57 2012 (r240663) +++ stable/9/sys/dev/usb/serial/uftdi_reg.h Tue Sep 18 17:03:32 2012 (r240664) @@ -39,6 +39,7 @@ #define UFTDI_TYPE_MASK 0x000000ff #define UFTDI_TYPE_SIO 0x00000001 #define UFTDI_TYPE_8U232AM 0x00000002 +#define UFTDI_TYPE_AUTO (UFTDI_TYPE_SIO | UFTDI_TYPE_8U232AM) #define UFTDI_FLAG_MASK 0x0000ff00 #define UFTDI_FLAG_JTAG 0x00000100 Modified: stable/9/sys/dev/usb/usbdevs ============================================================================== --- stable/9/sys/dev/usb/usbdevs Tue Sep 18 16:49:57 2012 (r240663) +++ stable/9/sys/dev/usb/usbdevs Tue Sep 18 17:03:32 2012 (r240664) @@ -322,6 +322,7 @@ vendor VIVITAR 0x0636 Vivitar vendor GUNZE 0x0637 Gunze Electronics USA vendor AVISION 0x0638 Avision vendor TEAC 0x0644 TEAC +vendor ACTON 0x0647 Acton Research Corp. vendor SGI 0x065e Silicon Graphics vendor SANWASUPPLY 0x0663 Sanwa Supply vendor MEGATEC 0x0665 Megatec @@ -346,6 +347,7 @@ vendor AGFA 0x06bd AGFA-Gevaert vendor ASIAMD 0x06be Asia Microelectronic Development vendor BIZLINK 0x06c4 Bizlink International vendor KEYSPAN 0x06cd Keyspan / InnoSys Inc. +vendor CONTEC 0x06ce Contec products vendor AASHIMA 0x06d6 Aashima Technology vendor LIEBERT 0x06da Liebert vendor MULTITECH 0x06e0 MultiTech @@ -487,7 +489,9 @@ vendor BROADCOM 0x0a5c Broadcom vendor GREENHOUSE 0x0a6b GREENHOUSE vendor MEDELI 0x0a67 Medeli vendor GEOCAST 0x0a79 Geocast Network Systems -vendor IDQUANTIQUE 0x0aba id Quantique +vendor EGO 0x0a92 EGO systems +vendor IDQUANTIQUE 0x0aba ID Quantique +vendor IDTECH 0x0acd ID TECH vendor ZYDAS 0x0ace Zydas Technology Corporation vendor NEODIO 0x0aec Neodio vendor OPTION 0x0af0 Option N.V. @@ -514,14 +518,20 @@ vendor ADDONICS2 0x0bf6 Addonics Technol vendor FSC 0x0bf8 Fujitsu Siemens Computers vendor AGATE 0x0c08 Agate Technologies vendor DMI 0x0c0b DMI +vendor ICOM 0x0c26 Icom Inc. +vendor GNOTOMETRICS 0x0c33 GN Otometrics vendor CHICONY2 0x0c45 Chicony vendor REINERSCT 0x0c4b Reiner-SCT vendor SEALEVEL 0x0c52 Sealevel System +vendor JETI 0x0c6c Jeti vendor LUWEN 0x0c76 Luwen +vendor ELEKTOR 0x0c7d ELEKTOR Electronics vendor KYOCERA2 0x0c88 Kyocera Wireless Corp. vendor ZCOM 0x0cde Z-Com vendor ATHEROS2 0x0cf3 Atheros Communications +vendor POSIFLEX 0x0d3a POSIFLEX vendor TANGTOP 0x0d3d Tangtop +vendor KOBIL 0x0d46 KOBIL vendor SMC3 0x0d5c Standard Microsystems vendor ADDON 0x0d7d Add-on Technology vendor ACDC 0x0d7e American Computer & Digital Components @@ -530,6 +540,7 @@ vendor CONCEPTRONIC 0x0d8e Conceptronic vendor SKANHEX 0x0d96 Skanhex Technology, Inc. vendor MSI 0x0db0 Micro Star International vendor ELCON 0x0db7 ELCON Systemtechnik +vendor UNKNOWN4 0x0dcd Unknown vendor vendor NETAC 0x0dd8 Netac vendor SITECOMEU 0x0df6 Sitecom Europe vendor MOBILEACTION 0x0df7 Mobile Action @@ -553,6 +564,7 @@ vendor VTECH 0x0f88 VTech vendor FALCOM 0x0f94 Falcom Wireless Communications GmbH vendor RIM 0x0fca Research In Motion vendor DYNASTREAM 0x0fcf Dynastream Innovations +vendor LARSENBRUSGAARD 0x0fd8 Larsen and Brusgaard vendor KONTRON 0x0fe6 Kontron AG vendor QUALCOMM 0x1004 Qualcomm vendor APACER 0x1005 Apacer @@ -560,6 +572,7 @@ vendor MOTOROLA4 0x100d Motorola vendor AIRPLUS 0x1011 Airplus vendor DESKNOTE 0x1019 Desknote vendor NEC3 0x1033 NEC +vendor TTI 0x103e Thurlby Thandar Instruments vendor GIGABYTE 0x1044 GIGABYTE vendor WESTERN 0x1058 Western Digital vendor MOTOROLA 0x1063 Motorola @@ -588,12 +601,14 @@ vendor TOPFIELD 0x11db Topfield Co., Lt vendor SIEMENS3 0x11f5 Siemens vendor NETINDEX 0x11f6 NetIndex vendor ALCATEL 0x11f7 Alcatel +vendor INTERBIOMETRICS 0x1209 Interbiometrics vendor UNKNOWN3 0x1233 Unknown vendor vendor TSUNAMI 0x1241 Tsunami vendor PHEENET 0x124a Pheenet vendor TARGUS 0x1267 Targus vendor TWINMOS 0x126f TwinMOS vendor TENDA 0x1286 Tenda +vendor TESTO 0x128d Testo products vendor CREATIVE2 0x1292 Creative Labs vendor BELKIN2 0x1293 Belkin Components vendor CYBERTAN 0x129b CyberTAN Technology @@ -612,8 +627,10 @@ vendor INITIO 0x13fd Initio Corporation vendor EMTEC 0x13fe Emtec vendor NOVATEL 0x1410 Novatel Wireless vendor MERLIN 0x1416 Merlin +vendor REDOCTANE 0x1430 RedOctane vendor WISTRONNEWEB 0x1435 Wistron NeWeb vendor RADIOSHACK 0x1453 Radio Shack +vendor FIC 0x1457 FIC / OpenMoko vendor HUAWEI3COM 0x1472 Huawei-3Com vendor ABOCOM2 0x1482 AboCom Systems vendor SILICOM 0x1485 Silicom @@ -632,8 +649,10 @@ vendor OQO 0x1557 OQO vendor UMEDIA 0x157e U-MEDIA Communications vendor FIBERLINE 0x1582 Fiberline vendor SPARKLAN 0x15a9 SparkLAN +vendor OLIMEX 0x15ba Olimex vendor SOUNDGRAPH 0x15c2 Soundgraph, Inc. vendor AMIT2 0x15c5 AMIT +vendor TEXTECH 0x15ca Textech International Ltd. vendor SOHOWARE 0x15e8 SOHOware vendor UMAX 0x1606 UMAX Data Systems vendor INSIDEOUT 0x1608 Inside Out Networks @@ -665,13 +684,19 @@ vendor QCOM 0x18e8 Qcom vendor ELV 0x18ef ELV vendor LINKSYS3 0x1915 Linksys vendor QUALCOMMINC 0x19d2 Qualcomm, Incorporated +vendor BAYER 0x1a79 Bayer vendor WCH2 0x1a86 QinHeng Electronics vendor STELERA 0x1a8d Stelera Wireless +vendor CORSAIR 0x1b1c Corsair vendor MATRIXORBITAL 0x1b3d Matrix Orbital vendor OVISLINK 0x1b75 OvisLink +vendor TML 0x1b91 The Mobility Lab vendor TCTMOBILE 0x1bbb TCT Mobile +vendor ALTI2 0x1bc9 Alti-2 products +vendor SUNPLUS 0x1bcf Sunplus Innovation Technology Inc. vendor WAGO 0x1be3 WAGO Kontakttechnik GmbH. vendor TELIT 0x1bc7 Telit +vendor IONICS 0x1c0c Ionics PlugComputer vendor LONGCHEER 0x1c9e Longcheer Holdings, Ltd. vendor MPMAN 0x1cae MpMan vendor DRESDENELEKTRONIK 0x1cf1 dresden elektronik @@ -688,8 +713,11 @@ vendor PLANEX2 0x2019 Planex Communicat vendor HAUPPAUGE2 0x2040 Hauppauge Computer Works vendor TLAYTECH 0x20b9 Tlay Tech vendor ENCORE 0x203d Encore +vendor QIHARDWARE 0x20b7 QI-hardware vendor PARA 0x20b8 PARA Industrial vendor SIMTEC 0x20df Simtec Electronics +vendor RTSYSTEMS 0x2100 RTSYSTEMS +vendor VIALABS 0x2109 VIA Labs vendor ERICSSON 0x2282 Ericsson vendor MOTOROLA2 0x22b8 Motorola vendor TRIPPLITE 0x2478 Tripp-Lite @@ -709,6 +737,7 @@ vendor IRIVER 0x4102 iRiver vendor DELL 0x413c Dell vendor WCH 0x4348 QinHeng Electronics vendor ACEECA 0x4766 Aceeca +vendor PAPOUCH 0x5050 Papouch products vendor AVERATEC 0x50c2 Averatec vendor SWEEX 0x5173 Sweex vendor PROLIFIC2 0x5372 Prolific Technologies @@ -725,8 +754,10 @@ vendor SITECOM2 0x9016 Sitecom vendor MOSCHIP 0x9710 MosChip Semiconductor vendor MARVELL 0x9e88 Marvell Technology Group Ltd. vendor 3COM3 0xa727 3Com +vendor EVOLUTION 0xdeee Evolution Robotics products vendor DATAAPEX 0xdaae DataApex vendor HP2 0xf003 Hewlett Packard +vendor LOGILINK 0xfc08 LogiLink vendor USRP 0xfffe GNU Radio USRP /* @@ -780,6 +811,9 @@ product ABOCOM RT2573_3 0xb21d RT2573 product ABOCOM RT2573_4 0xb21e RT2573 product ABOCOM WUG2700 0xb21f WUG2700 +/* Acton Research Corp. */ +product ACTON SPECTRAPRO 0x0100 FTDI compatible adapter + /* Accton products */ product ACCTON USB320_EC 0x1046 USB320-EC Ethernet Adapter product ACCTON 2664W 0x3501 2664W @@ -943,6 +977,9 @@ product ALINK 3GU 0x9200 3G modem product ALTEC ADA70 0x0070 ADA70 Speakers product ALTEC ASC495 0xff05 ASC495 Speakers +/* Alti-2 products */ +product ALTI2 N3 0x6001 FTDI compatible adapter + /* Allied Telesyn International products */ product ALLIEDTELESYN ATUSB100 0xb100 AT-USB100 @@ -989,6 +1026,10 @@ product AMIT RT2870_1 0x0012 RT2870 /* AMIT(2) products */ product AMIT2 RT2870 0x0008 RT2870 +/* Analog Devices products */ +product ANALOGDEVICES GNICE 0xf000 FTDI compatible adapter +product ANALOGDEVICES GNICEPLUS 0xf001 FTDI compatible adapter + /* Anchor products */ product ANCHOR SERIAL 0x2008 Serial product ANCHOR EZUSB 0x2131 EZUSB @@ -1124,8 +1165,27 @@ product AZUREWAVE RT3070_3 0x3305 RT3070 /* Baltech products */ product BALTECH CARDREADER 0x9999 Card reader +/* Bayer products */ +product BAYER CONTOUR_CABLE 0x6001 FTDI compatible adapter + /* B&B Electronics products */ product BBELECTRONICS USOTL4 0xAC01 RS-422/485 +product BBELECTRONICS 232USB9M 0xac27 FTDI compatible adapter +product BBELECTRONICS 485USB9F_2W 0xac25 FTDI compatible adapter +product BBELECTRONICS 485USB9F_4W 0xac26 FTDI compatible adapter +product BBELECTRONICS 485USBTB_2W 0xac33 FTDI compatible adapter +product BBELECTRONICS 485USBTB_4W 0xac34 FTDI compatible adapter +product BBELECTRONICS TTL3USB9M 0xac50 FTDI compatible adapter +product BBELECTRONICS TTL5USB9M 0xac49 FTDI compatible adapter +product BBELECTRONICS USO9ML2 0xac03 FTDI compatible adapter +product BBELECTRONICS USO9ML2DR 0xac17 FTDI compatible adapter +product BBELECTRONICS USO9ML2DR_2 0xac16 FTDI compatible adapter +product BBELECTRONICS USOPTL4 0xac11 FTDI compatible adapter +product BBELECTRONICS USOPTL4DR 0xac19 FTDI compatible adapter +product BBELECTRONICS USOPTL4DR2 0xac18 FTDI compatible adapter +product BBELECTRONICS USPTL4 0xac12 FTDI compatible adapter +product BBELECTRONICS USTL4 0xac02 FTDI compatible adapter +product BBELECTRONICS ZZ_PROG1_USB 0xba02 FTDI compatible adapter /* Belkin products */ /*product BELKIN F5U111 0x???? F5U111 Ethernet*/ @@ -1292,6 +1352,9 @@ product CONCEPTRONIC2 RT2870_6 0x3c28 RT /* Connectix products */ product CONNECTIX QUICKCAM 0x0001 QuickCam +/* Conect products */ +product CONTEC COM1USBH 0x8311 FTDI compatible adapter + /* Corega products */ product COREGA ETHER_USB_T 0x0001 Ether USB-T product COREGA FETHER_USB_TX 0x0004 FEther USB-TX @@ -1312,6 +1375,9 @@ product COREGA CGWLUSB300GNM 0x0042 CG-W product COREGA WLUSB_11_STICK 0x7613 WLAN USB Stick 11 product COREGA FETHER_USB_TXC 0x9601 FEther USB-TXC +/* Corsair products */ +product CORSAIR K60 0x0a60 Corsair Vengeance K60 keyboard + /* Creative products */ product CREATIVE NOMAD_II 0x1002 Nomad II MP3 player product CREATIVE NOMAD_IIMG 0x4004 Nomad II MG @@ -1483,6 +1549,10 @@ product EGALAX TPANEL 0x0001 Touch Pane product EGALAX TPANEL2 0x0002 Touch Panel product EGALAX2 TPANEL 0x0001 Touch Panel +/* EGO Products */ +product EGO DUMMY 0x0000 Dummy Product +product EGO M4U 0x1020 ESI M4U + /* Eicon Networks */ product EICON DIVA852 0x4905 Diva 852 ISDN TA @@ -1504,6 +1574,9 @@ product ELECOM UCSGT 0x5003 UC-SGT product ELECOM UCSGT0 0x5004 UC-SGT product ELECOM LDUSBTX3 0xabc1 LD-USB/TX +/* Elektor products */ +product ELEKTOR FT323R 0x0005 FTDI compatible adapter + /* Elsa products */ product ELSA MODEM1 0x2265 ELSA Modem Board product ELSA USB2ETHERNET 0x3000 Microlink USB2Ethernet @@ -1581,11 +1654,17 @@ product EPSON SX400 0x084a SX400/NX400/ /* e-TEK Labs products */ product ETEK 1COM 0x8007 Serial +/* Evolution products */ +product EVOLUTION ER1 0x0300 FTDI compatible adapter +product EVOLUTION HYBRID 0x0302 FTDI compatible adapter +product EVOLUTION RCM4 0x0303 FTDI compatible adapter + /* Extended Systems products */ product EXTENDED XTNDACCESS 0x0100 XTNDAccess IrDA /* Falcom products */ product FALCOM TWIST 0x0001 USB GSM/GPRS Modem +product FALCOM SAMBA 0x0005 FTDI compatible adapter /* FEIYA products */ product FEIYA DUMMY 0x0000 Dummy product @@ -1599,6 +1678,9 @@ product FESTO CMSP 0x0501 CMSP /* Fiberline */ product FIBERLINE WL430U 0x6003 WL-430U +/* FIC / OpenMoko */ +product FIC NEO1973_DEBUG 0x5118 FTDI compatible adapter + /* Fossil, Inc products */ product FOSSIL WRISTPDA 0x0002 Wrist PDA @@ -1617,7 +1699,9 @@ product FSC E5400 0x1009 PrismGT USB 2. product FTDI SERIAL_8U100AX 0x8372 8U100AX Serial product FTDI SERIAL_8U232AM 0x6001 8U232AM Serial product FTDI SERIAL_8U232AM4 0x6004 8U232AM Serial *** DIFF OUTPUT TRUNCATED AT 1000 LINES *** From owner-svn-src-stable@FreeBSD.ORG Tue Sep 18 17:08:15 2012 Return-Path: Delivered-To: svn-src-stable@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 0CF3D106564A; Tue, 18 Sep 2012 17:08:15 +0000 (UTC) (envelope-from hselasky@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id EB6E68FC12; Tue, 18 Sep 2012 17:08:14 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q8IH8E14029890; Tue, 18 Sep 2012 17:08:14 GMT (envelope-from hselasky@svn.freebsd.org) Received: (from hselasky@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q8IH8E67029888; Tue, 18 Sep 2012 17:08:14 GMT (envelope-from hselasky@svn.freebsd.org) Message-Id: <201209181708.q8IH8E67029888@svn.freebsd.org> From: Hans Petter Selasky Date: Tue, 18 Sep 2012 17:08:14 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r240665 - stable/9/sys/dev/usb/serial X-BeenThere: svn-src-stable@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for all the -stable branches of the src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 18 Sep 2012 17:08:15 -0000 Author: hselasky Date: Tue Sep 18 17:08:14 2012 New Revision: 240665 URL: http://svn.freebsd.org/changeset/base/240665 Log: MFC r240382: Restart the USB transfer if the error is not USB_ERR_CANCELLED. Modified: stable/9/sys/dev/usb/serial/ufoma.c Directory Properties: stable/9/sys/ (props changed) stable/9/sys/dev/ (props changed) Modified: stable/9/sys/dev/usb/serial/ufoma.c ============================================================================== --- stable/9/sys/dev/usb/serial/ufoma.c Tue Sep 18 17:03:32 2012 (r240664) +++ stable/9/sys/dev/usb/serial/ufoma.c Tue Sep 18 17:08:14 2012 (r240665) @@ -631,10 +631,7 @@ tr_setup: if (error == USB_ERR_CANCELLED) { return; - } else { - goto tr_setup; } - goto tr_transferred; } } @@ -651,7 +648,6 @@ ufoma_ctrl_write_callback(struct usb_xfe case USB_ST_TRANSFERRED: tr_transferred: case USB_ST_SETUP: -tr_setup: pc = usbd_xfer_get_frame(xfer, 1); if (ucom_get_data(&sc->sc_ucom, pc, 0, 1, &actlen)) { @@ -677,10 +673,7 @@ tr_setup: if (error == USB_ERR_CANCELLED) { return; - } else { - goto tr_setup; } - goto tr_transferred; } } From owner-svn-src-stable@FreeBSD.ORG Tue Sep 18 17:10:26 2012 Return-Path: Delivered-To: svn-src-stable@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id CD3C91065673; Tue, 18 Sep 2012 17:10:26 +0000 (UTC) (envelope-from hselasky@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 9E5858FC19; Tue, 18 Sep 2012 17:10:26 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q8IHAQQR030233; Tue, 18 Sep 2012 17:10:26 GMT (envelope-from hselasky@svn.freebsd.org) Received: (from hselasky@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q8IHAQ32030231; Tue, 18 Sep 2012 17:10:26 GMT (envelope-from hselasky@svn.freebsd.org) Message-Id: <201209181710.q8IHAQ32030231@svn.freebsd.org> From: Hans Petter Selasky Date: Tue, 18 Sep 2012 17:10:26 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r240666 - stable/9/sys/dev/usb X-BeenThere: svn-src-stable@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for all the -stable branches of the src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 18 Sep 2012 17:10:26 -0000 Author: hselasky Date: Tue Sep 18 17:10:26 2012 New Revision: 240666 URL: http://svn.freebsd.org/changeset/base/240666 Log: MFC r239237: Improve auto-quirks detection for certain Kingston memory sticks. Modified: stable/9/sys/dev/usb/usb_msctest.c Directory Properties: stable/9/sys/ (props changed) stable/9/sys/dev/ (props changed) Modified: stable/9/sys/dev/usb/usb_msctest.c ============================================================================== --- stable/9/sys/dev/usb/usb_msctest.c Tue Sep 18 17:08:14 2012 (r240665) +++ stable/9/sys/dev/usb/usb_msctest.c Tue Sep 18 17:10:26 2012 (r240666) @@ -103,6 +103,8 @@ static uint8_t scsi_sync_cache[] = { 0x3 0x00, 0x00, 0x00, 0x00 }; static uint8_t scsi_request_sense[] = { 0x03, 0x00, 0x00, 0x00, 0x12, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00 }; +static uint8_t scsi_read_capacity[] = { 0x25, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00 }; #define BULK_SIZE 64 /* dummy */ #define ERR_CSW_FAILED -1 @@ -652,7 +654,7 @@ usb_msc_auto_quirk(struct usb_device *ud } is_no_direct = 1; - for (timeout = 4; timeout; timeout--) { + for (timeout = 4; timeout != 0; timeout--) { err = bbb_command_start(sc, DIR_IN, 0, sc->buffer, SCSI_INQ_LEN, &scsi_inquiry, sizeof(scsi_inquiry), USB_MS_HZ); @@ -681,7 +683,9 @@ usb_msc_auto_quirk(struct usb_device *ud if (err != ERR_CSW_FAILED) goto error; } + timeout = 1; +retry_sync_cache: err = bbb_command_start(sc, DIR_IN, 0, NULL, 0, &scsi_sync_cache, sizeof(scsi_sync_cache), USB_MS_HZ); @@ -694,6 +698,42 @@ usb_msc_auto_quirk(struct usb_device *ud DPRINTF("Device doesn't handle synchronize cache\n"); usbd_add_dynamic_quirk(udev, UQ_MSC_NO_SYNC_CACHE); + + } else { + + /* + * Certain Kingston memory sticks fail the first + * read capacity after a synchronize cache command + * has been issued. Disable the synchronize cache + * command for such devices. + */ + + err = bbb_command_start(sc, DIR_IN, 0, sc->buffer, 8, + &scsi_read_capacity, sizeof(scsi_read_capacity), + USB_MS_HZ); + + if (err != 0) { + if (err != ERR_CSW_FAILED) + goto error; + + err = bbb_command_start(sc, DIR_IN, 0, sc->buffer, 8, + &scsi_read_capacity, sizeof(scsi_read_capacity), + USB_MS_HZ); + + if (err == 0) { + if (timeout--) + goto retry_sync_cache; + + DPRINTF("Device most likely doesn't " + "handle synchronize cache\n"); + + usbd_add_dynamic_quirk(udev, + UQ_MSC_NO_SYNC_CACHE); + } else { + if (err != ERR_CSW_FAILED) + goto error; + } + } } /* clear sense status of any failed commands on the device */ From owner-svn-src-stable@FreeBSD.ORG Tue Sep 18 17:15:00 2012 Return-Path: Delivered-To: svn-src-stable@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 3AA06106564A; Tue, 18 Sep 2012 17:15:00 +0000 (UTC) (envelope-from hselasky@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 1AF148FC1A; Tue, 18 Sep 2012 17:15:00 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q8IHExxT030869; Tue, 18 Sep 2012 17:14:59 GMT (envelope-from hselasky@svn.freebsd.org) Received: (from hselasky@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q8IHEx4d030865; Tue, 18 Sep 2012 17:14:59 GMT (envelope-from hselasky@svn.freebsd.org) Message-Id: <201209181714.q8IHEx4d030865@svn.freebsd.org> From: Hans Petter Selasky Date: Tue, 18 Sep 2012 17:14:59 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r240667 - in stable/9/sys/dev/usb: input quirk X-BeenThere: svn-src-stable@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for all the -stable branches of the src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 18 Sep 2012 17:15:00 -0000 Author: hselasky Date: Tue Sep 18 17:14:59 2012 New Revision: 240667 URL: http://svn.freebsd.org/changeset/base/240667 Log: MFC r240615: Add UQ_UMS_IGNORE quirk. Wrap two long lines. Some minor spelling correction. PR: usb/171721 Modified: stable/9/sys/dev/usb/input/ums.c stable/9/sys/dev/usb/quirk/usb_quirk.c stable/9/sys/dev/usb/quirk/usb_quirk.h Directory Properties: stable/9/sys/ (props changed) stable/9/sys/dev/ (props changed) Modified: stable/9/sys/dev/usb/input/ums.c ============================================================================== --- stable/9/sys/dev/usb/input/ums.c Tue Sep 18 17:10:26 2012 (r240666) +++ stable/9/sys/dev/usb/input/ums.c Tue Sep 18 17:14:59 2012 (r240667) @@ -381,6 +381,9 @@ ums_probe(device_t dev) if (uaa->info.bInterfaceClass != UICLASS_HID) return (ENXIO); + if (usb_test_quirk(uaa, UQ_UMS_IGNORE)) + return (ENXIO); + if ((uaa->info.bInterfaceSubClass == UISUBCLASS_BOOT) && (uaa->info.bInterfaceProtocol == UIPROTO_MOUSE)) return (BUS_PROBE_DEFAULT); Modified: stable/9/sys/dev/usb/quirk/usb_quirk.c ============================================================================== --- stable/9/sys/dev/usb/quirk/usb_quirk.c Tue Sep 18 17:10:26 2012 (r240666) +++ stable/9/sys/dev/usb/quirk/usb_quirk.c Tue Sep 18 17:14:59 2012 (r240667) @@ -494,6 +494,7 @@ static const char *usb_quirk_str[USB_QUI [UQ_HID_IGNORE] = "UQ_HID_IGNORE", [UQ_KBD_IGNORE] = "UQ_KBD_IGNORE", [UQ_KBD_BOOTPROTO] = "UQ_KBD_BOOTPROTO", + [UQ_UMS_IGNORE] = "UQ_UMS_IGNORE", [UQ_MS_BAD_CLASS] = "UQ_MS_BAD_CLASS", [UQ_MS_LEADING_BYTE] = "UQ_MS_LEADING_BYTE", [UQ_MS_REVZ] = "UQ_MS_REVZ", Modified: stable/9/sys/dev/usb/quirk/usb_quirk.h ============================================================================== --- stable/9/sys/dev/usb/quirk/usb_quirk.h Tue Sep 18 17:10:26 2012 (r240666) +++ stable/9/sys/dev/usb/quirk/usb_quirk.h Tue Sep 18 17:14:59 2012 (r240667) @@ -29,7 +29,7 @@ enum { /* - * Keep in sync with theusb_quirk_str usb_quirk.c, and with the + * Keep in sync with usb_quirk_str in usb_quirk.c, and with * share/man/man4/usb_quirk.4 */ UQ_NONE, /* not a valid quirk */ @@ -49,6 +49,7 @@ enum { UQ_HID_IGNORE, /* device should be ignored by hid class */ UQ_KBD_IGNORE, /* device should be ignored by kbd class */ UQ_KBD_BOOTPROTO, /* device should set the boot protocol */ + UQ_UMS_IGNORE, /* device should be ignored by ums class */ UQ_MS_BAD_CLASS, /* doesn't identify properly */ UQ_MS_LEADING_BYTE, /* mouse sends an unknown leading byte */ UQ_MS_REVZ, /* mouse has Z-axis reversed */ @@ -64,7 +65,10 @@ enum { UQ_CFG_INDEX_0, /* select configuration index 0 by default */ UQ_ASSUME_CM_OVER_DATA, /* assume cm over data feature */ - /* USB Mass Storage Quirks. See "storage/umass.c" for a detailed description. */ + /* + * USB Mass Storage Quirks. See "storage/umass.c" for a + * detailed description. + */ UQ_MSC_NO_TEST_UNIT_READY, /* send start/stop instead of TUR */ UQ_MSC_NO_RS_CLEAR_UA, /* does not reset Unit Att. */ UQ_MSC_NO_START_STOP, /* does not support start/stop */ From owner-svn-src-stable@FreeBSD.ORG Tue Sep 18 17:17:04 2012 Return-Path: Delivered-To: svn-src-stable@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id BBD21106564A; Tue, 18 Sep 2012 17:17:04 +0000 (UTC) (envelope-from hselasky@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id A62318FC15; Tue, 18 Sep 2012 17:17:04 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q8IHH4Ck031203; Tue, 18 Sep 2012 17:17:04 GMT (envelope-from hselasky@svn.freebsd.org) Received: (from hselasky@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q8IHH48L031201; Tue, 18 Sep 2012 17:17:04 GMT (envelope-from hselasky@svn.freebsd.org) Message-Id: <201209181717.q8IHH48L031201@svn.freebsd.org> From: Hans Petter Selasky Date: Tue, 18 Sep 2012 17:17:04 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r240668 - stable/9/sys/dev/usb/net X-BeenThere: svn-src-stable@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for all the -stable branches of the src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 18 Sep 2012 17:17:04 -0000 Author: hselasky Date: Tue Sep 18 17:17:04 2012 New Revision: 240668 URL: http://svn.freebsd.org/changeset/base/240668 Log: MFC r240597: Remove unused variable cd. This variable is initialized but not used. Modified: stable/9/sys/dev/usb/net/uhso.c Directory Properties: stable/9/sys/ (props changed) stable/9/sys/dev/ (props changed) Modified: stable/9/sys/dev/usb/net/uhso.c ============================================================================== --- stable/9/sys/dev/usb/net/uhso.c Tue Sep 18 17:14:59 2012 (r240667) +++ stable/9/sys/dev/usb/net/uhso.c Tue Sep 18 17:17:04 2012 (r240668) @@ -540,7 +540,6 @@ uhso_attach(device_t self) { struct uhso_softc *sc = device_get_softc(self); struct usb_attach_arg *uaa = device_get_ivars(self); - struct usb_config_descriptor *cd; struct usb_interface_descriptor *id; struct sysctl_ctx_list *sctx; struct sysctl_oid *soid; @@ -561,7 +560,6 @@ uhso_attach(device_t self) sc->sc_ttys = 0; sc->sc_radio = 1; - cd = usbd_get_config_descriptor(uaa->device); id = usbd_get_interface_descriptor(uaa->iface); sc->sc_ctrl_iface_no = id->bInterfaceNumber; From owner-svn-src-stable@FreeBSD.ORG Tue Sep 18 17:23:00 2012 Return-Path: Delivered-To: svn-src-stable@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id B6E9B106566B; Tue, 18 Sep 2012 17:23:00 +0000 (UTC) (envelope-from hselasky@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 9738F8FC19; Tue, 18 Sep 2012 17:23:00 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q8IHN0tl032023; Tue, 18 Sep 2012 17:23:00 GMT (envelope-from hselasky@svn.freebsd.org) Received: (from hselasky@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q8IHN0rI032020; Tue, 18 Sep 2012 17:23:00 GMT (envelope-from hselasky@svn.freebsd.org) Message-Id: <201209181723.q8IHN0rI032020@svn.freebsd.org> From: Hans Petter Selasky Date: Tue, 18 Sep 2012 17:23:00 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r240669 - in stable/9/sys/dev/usb: . serial X-BeenThere: svn-src-stable@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for all the -stable branches of the src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 18 Sep 2012 17:23:01 -0000 Author: hselasky Date: Tue Sep 18 17:23:00 2012 New Revision: 240669 URL: http://svn.freebsd.org/changeset/base/240669 Log: MFC r238079, r238493, r238526, r238529 and r238717: Add new USB ID's. PR: usb/169789 Modified: stable/9/sys/dev/usb/serial/u3g.c stable/9/sys/dev/usb/usbdevs Directory Properties: stable/9/sys/ (props changed) stable/9/sys/dev/ (props changed) Modified: stable/9/sys/dev/usb/serial/u3g.c ============================================================================== --- stable/9/sys/dev/usb/serial/u3g.c Tue Sep 18 17:17:04 2012 (r240668) +++ stable/9/sys/dev/usb/serial/u3g.c Tue Sep 18 17:23:00 2012 (r240669) @@ -285,14 +285,18 @@ static const STRUCT_USB_HOST_ID u3g_devs U3G_DEV(HUAWEI, E143F, U3GINIT_HUAWEI), U3G_DEV(HUAWEI, E173, 0), U3G_DEV(HUAWEI, E173_INIT, U3GINIT_HUAWEISCSI), + U3G_DEV(HUAWEI, E3131, 0), + U3G_DEV(HUAWEI, E3131_INIT, U3GINIT_HUAWEISCSI), U3G_DEV(HUAWEI, E180V, U3GINIT_HUAWEI), U3G_DEV(HUAWEI, E220, U3GINIT_HUAWEI), U3G_DEV(HUAWEI, E220BIS, U3GINIT_HUAWEI), + U3G_DEV(HUAWEI, E392, U3GINIT_HUAWEISCSI), U3G_DEV(HUAWEI, MOBILE, U3GINIT_HUAWEI), U3G_DEV(HUAWEI, E1752, U3GINIT_HUAWEISCSI), U3G_DEV(HUAWEI, E1820, U3GINIT_HUAWEISCSI), U3G_DEV(HUAWEI, K3765, U3GINIT_HUAWEI), U3G_DEV(HUAWEI, K3765_INIT, U3GINIT_HUAWEISCSI), + U3G_DEV(HUAWEI, ETS2055, U3GINIT_HUAWEI), U3G_DEV(KYOCERA2, CDMA_MSM_K, 0), U3G_DEV(KYOCERA2, KPC680, 0), U3G_DEV(LONGCHEER, WM66, U3GINIT_HUAWEI), @@ -359,6 +363,8 @@ static const STRUCT_USB_HOST_ID u3g_devs U3G_DEV(QUALCOMM2, MF330, 0), U3G_DEV(QUALCOMM2, SIM5218, 0), U3G_DEV(QUALCOMM2, VW110L, U3GINIT_SCSIEJECT), + U3G_DEV(QUALCOMM2, GOBI2000_QDL, 0), + U3G_DEV(QUALCOMM2, GOBI2000, 0), U3G_DEV(QUALCOMMINC, AC2726, 0), U3G_DEV(QUALCOMMINC, AC8700, 0), U3G_DEV(QUALCOMMINC, AC8710, 0), Modified: stable/9/sys/dev/usb/usbdevs ============================================================================== --- stable/9/sys/dev/usb/usbdevs Tue Sep 18 17:17:04 2012 (r240668) +++ stable/9/sys/dev/usb/usbdevs Tue Sep 18 17:23:00 2012 (r240669) @@ -2184,7 +2184,11 @@ product HUAWEI E143F 0x143f 3G modem product HUAWEI E1752 0x1446 3G modem product HUAWEI K3765 0x1465 3G modem product HUAWEI E1820 0x14ac E1820 HSPA+ USB Slider +product HUAWEI E3131_INIT 0x14fe 3G modem initial +product HUAWEI E392 0x1505 LTE modem +product HUAWEI E3131 0x1506 3G modem product HUAWEI K3765_INIT 0x1520 K3765 Initial +product HUAWEI ETS2055 0x1803 CDMA modem product HUAWEI E173 0x1c05 3G modem product HUAWEI E173_INIT 0x1c0b 3G modem initial @@ -3328,6 +3332,8 @@ product QUALCOMM2 CDMA_MSM 0x3196 CDMA T product QUALCOMM2 AC8700 0x6000 AC8700 product QUALCOMM2 VW110L 0x1000 Vertex Wireless 110L modem product QUALCOMM2 SIM5218 0x9000 SIM5218 +product QUALCOMM2 GOBI2000_QDL 0x9204 Qualcomm Gobi 2000 QDL +product QUALCOMM2 GOBI2000 0x9205 Qualcomm Gobi 2000 modem product QUALCOMMINC CDMA_MSM 0x0001 CDMA Technologies MSM modem product QUALCOMMINC E0002 0x0002 3G modem product QUALCOMMINC E0003 0x0003 3G modem From owner-svn-src-stable@FreeBSD.ORG Tue Sep 18 17:27:10 2012 Return-Path: Delivered-To: svn-src-stable@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 389FA106564A; Tue, 18 Sep 2012 17:27:10 +0000 (UTC) (envelope-from kostikbel@gmail.com) Received: from mail.zoral.com.ua (mx0.zoral.com.ua [91.193.166.200]) by mx1.freebsd.org (Postfix) with ESMTP id A1C768FC16; Tue, 18 Sep 2012 17:27:09 +0000 (UTC) Received: from skuns.kiev.zoral.com.ua (localhost [127.0.0.1]) by mail.zoral.com.ua (8.14.2/8.14.2) with ESMTP id q8IHRHrA032535; Tue, 18 Sep 2012 20:27:17 +0300 (EEST) (envelope-from kostikbel@gmail.com) Received: from deviant.kiev.zoral.com.ua (kostik@localhost [127.0.0.1]) by deviant.kiev.zoral.com.ua (8.14.5/8.14.5) with ESMTP id q8IHR5nJ036320; Tue, 18 Sep 2012 20:27:05 +0300 (EEST) (envelope-from kostikbel@gmail.com) Received: (from kostik@localhost) by deviant.kiev.zoral.com.ua (8.14.5/8.14.5/Submit) id q8IHR52w036319; Tue, 18 Sep 2012 20:27:05 +0300 (EEST) (envelope-from kostikbel@gmail.com) X-Authentication-Warning: deviant.kiev.zoral.com.ua: kostik set sender to kostikbel@gmail.com using -f Date: Tue, 18 Sep 2012 20:27:05 +0300 From: Konstantin Belousov To: Hans Petter Selasky Message-ID: <20120918172705.GK37286@deviant.kiev.zoral.com.ua> References: <201209181628.q8IGSoOF024628@svn.freebsd.org> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="CZI63rpYmK/igF6U" Content-Disposition: inline In-Reply-To: <201209181628.q8IGSoOF024628@svn.freebsd.org> User-Agent: Mutt/1.5.21 (2010-09-15) X-Virus-Scanned: clamav-milter 0.95.2 at skuns.kiev.zoral.com.ua X-Virus-Status: Clean X-Spam-Status: No, score=-4.0 required=5.0 tests=ALL_TRUSTED,AWL,BAYES_00 autolearn=ham version=3.2.5 X-Spam-Checker-Version: SpamAssassin 3.2.5 (2008-06-10) on skuns.kiev.zoral.com.ua Cc: svn-src-stable@freebsd.org, svn-src-all@freebsd.org, src-committers@freebsd.org, svn-src-stable-9@freebsd.org Subject: Re: svn commit: r240659 - in stable/9/sys: dev/usb/net dev/usb/serial kern sys X-BeenThere: svn-src-stable@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for all the -stable branches of the src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 18 Sep 2012 17:27:10 -0000 --CZI63rpYmK/igF6U Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Tue, Sep 18, 2012 at 04:28:50PM +0000, Hans Petter Selasky wrote: > Author: hselasky > Date: Tue Sep 18 16:28:49 2012 > New Revision: 240659 > URL: http://svn.freebsd.org/changeset/base/240659 >=20 > Log: > MFC r239178, r239179, r239180, r239181, r239182 and r239299: > =20 > Fix detach of USB serial devices so that it doesn't block > the USB explore thread forever. To accomplish this two new > functions have been added to the kernel, to claim and free > the newbus allocated softc. > =20 > This change is backwards API compatible, but not binary > compatible. The FreeBSD version has been bumped to force > a recompile of all kernel modules. Thank you, I run with this change since it was committed to head, and the only issue left is that the same serial adapter reappears under the different cuaUNN name after the glitch. This causes apcupsd to not able to reconnect. And, the big question that still applies, is why UPSes are lost from the USB bus ? --CZI63rpYmK/igF6U Content-Type: application/pgp-signature -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.12 (FreeBSD) iEYEARECAAYFAlBYrukACgkQC3+MBN1Mb4jUgACgtcFReuqjU80Tmc5mCMK60ejL LkUAoONhTv3mqTuzH6kLyCW4bgI/5Val =4rX/ -----END PGP SIGNATURE----- --CZI63rpYmK/igF6U-- From owner-svn-src-stable@FreeBSD.ORG Tue Sep 18 17:30:11 2012 Return-Path: Delivered-To: svn-src-stable@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 9A3AC106567F; Tue, 18 Sep 2012 17:30:11 +0000 (UTC) (envelope-from hselasky@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 940E08FC14; Tue, 18 Sep 2012 17:30:09 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q8IHU83b032968; Tue, 18 Sep 2012 17:30:08 GMT (envelope-from hselasky@svn.freebsd.org) Received: (from hselasky@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q8IHU84e032966; Tue, 18 Sep 2012 17:30:08 GMT (envelope-from hselasky@svn.freebsd.org) Message-Id: <201209181730.q8IHU84e032966@svn.freebsd.org> From: Hans Petter Selasky Date: Tue, 18 Sep 2012 17:30:08 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r240670 - stable/9/etc/devd X-BeenThere: svn-src-stable@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for all the -stable branches of the src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 18 Sep 2012 17:30:11 -0000 Author: hselasky Date: Tue Sep 18 17:30:08 2012 New Revision: 240670 URL: http://svn.freebsd.org/changeset/base/240670 Log: MFC r239056: Regenerate usb.conf Modified: stable/9/etc/devd/usb.conf Directory Properties: stable/9/etc/ (props changed) Modified: stable/9/etc/devd/usb.conf ============================================================================== --- stable/9/etc/devd/usb.conf Tue Sep 18 17:23:00 2012 (r240669) +++ stable/9/etc/devd/usb.conf Tue Sep 18 17:30:08 2012 (r240670) @@ -157,7 +157,7 @@ nomatch 32 { match "bus" "uhub[0-9]+"; match "mode" "host"; match "vendor" "0x0403"; - match "product" "(0x6001|0x6004|0x6010|0x6011|0x8372|0x9e90|0xcc48|0xcc49|0xcc4a|0xd678|0xe6c8|0xe888|0xe889|0xe88a|0xe88b|0xe88c|0xee18|0xf608|0xf60b|0xf850|0xfa00|0xfa01|0xfa02|0xfa03|0xfa04|0xfc08|0xfc09|0xfc0b|0xfc0c|0xfc0d|0xfc82)"; + match "product" "(0x6001|0x6004|0x6006|0x6010|0x6011|0x6014|0x8372|0x9378|0x9379|0x937a|0x937c|0x9868|0x9e90|0x9f80|0xa6d0|0xabb8|0xb810|0xb811|0xb812|0xbaf8|0xbca0|0xbca1|0xbca2|0xbca4|0xbcd8|0xbcd9|0xbdc8|0xbfd8|0xbfd9|0xbfda|0xbfdb|0xbfdc|0xc7d0|0xc850|0xc991|0xcaa0|0xcc48|0xcc49|0xcc4a|0xd010|0xd011|0xd012|0xd013|0xd014|0xd015|0xd016|0xd017|0xd070|0xd071|0xd388|0xd389|0xd38a|0xd38b|0xd38c|0xd38d|0xd38e|0xd38f|0xd578|0xd678|0xd738|0xd780|0xdaf8|0xdaf9|0xdafa|0xdafb|0xdafc|0xdafd|0xdafe|0xdaff|0xdc00|0xdc01|0xdd20|0xdf28|0xdf30|0xdf31|0xdf32|0xdf33|0xdf35|0xe000|0xe001|0xe002|0xe004|0xe006|0xe008|0xe009|0xe00a|0xe050|0xe0e8|0xe0e9|0xe0ea|0xe0eb|0xe0ec|0xe0ed|0xe0ee|0xe0ef|0xe0f0|0xe0f1|0xe0f2|0xe0f3|0xe0f4|0xe0f5|0xe0f6|0xe0f7|0xe40b|0xe520|0xe548|0xe6c8|0xe700|0xe729|0xe808|0xe809|0xe80a|0xe80b|0xe80c|0xe80d|0xe80e|0xe80f|0xe888|0xe889|0xe88a|0xe88b|0xe88c|0xe88d|0xe88e|0xe88f|0xea90|0xebe0|0xec88|0xec89|0xed22|0xed71|0xed72|0xed73|0xed74|0xee18|0xeee8|0xeee9|0xeeea|0xeeeb|0xeee c|0xeeed|0xeeee|0xeeef|0xef50|0xef51|0xf068|0xf069|0xf06a|0xf06b|0xf06c|0xf06d|0xf06e|0xf06f|0xf070|0xf0c0|0xf0c8|0xf208|0xf2d0|0xf3c0|0xf3c1|0xf3c2|0xf448|0xf449|0xf44a|0xf44b|0xf44c|0xf460|0xf608|0xf60b|0xf680|0xf850|0xf857|0xf9d0|0xf9d1|0xf9d2|0xf9d3|0xf9d4|0xf9d5|0xfa00|0xfa01|0xfa02|0xfa03|0xfa04|0xfa05|0xfa06|0xfa10|0xfa33|0xfa88|0xfad0|0xfaf0|0xfb58|0xfb59|0xfb5a|0xfb5b|0xfb5c|0xfb5d|0xfb5e|0xfb5f|0xfb80|0xfb99|0xfbfa|0xfc08|0xfc09|0xfc0a|0xfc0b|0xfc0c|0xfc0d|0xfc0e|0xfc0f|0xfc60|0xfc70|0xfc71|0xfc72|0xfc73|0xfc82|0xfd60|0xfe38|0xff00|0xff18|0xff1c|0xff1d|0xff20|0xff38|0xff39|0xff3a|0xff3b|0xff3c|0xff3d|0xff3e|0xff3f|0xffa8)"; action "kldload -n uftdi"; }; @@ -293,7 +293,7 @@ nomatch 32 { match "bus" "uhub[0-9]+"; match "mode" "host"; match "vendor" "0x0411"; - match "product" "(0x0148|0x0150|0x015d|0x016f|0x01a2)"; + match "product" "(0x0148|0x0150|0x015d|0x016f|0x01a2|0x01ee)"; action "kldload -n if_run"; }; @@ -324,6 +324,14 @@ nomatch 32 { nomatch 32 { match "bus" "uhub[0-9]+"; match "mode" "host"; + match "vendor" "0x0456"; + match "product" "(0xf000|0xf001)"; + action "kldload -n uftdi"; +}; + +nomatch 32 { + match "bus" "uhub[0-9]+"; + match "mode" "host"; match "vendor" "0x045a"; match "product" "(0x5001|0x5002)"; action "kldload -n urio"; @@ -1021,7 +1029,7 @@ nomatch 32 { match "bus" "uhub[0-9]+"; match "mode" "host"; match "vendor" "0x05c6"; - match "product" "(0x1000|0x6000|0x6613|0x9000)"; + match "product" "(0x1000|0x6000|0x6613|0x9000|0x9204|0x9205)"; action "kldload -n u3g"; }; @@ -1068,6 +1076,14 @@ nomatch 32 { nomatch 32 { match "bus" "uhub[0-9]+"; match "mode" "host"; + match "vendor" "0x0647"; + match "product" "0x0100"; + action "kldload -n uftdi"; +}; + +nomatch 32 { + match "bus" "uhub[0-9]+"; + match "mode" "host"; match "vendor" "0x066b"; match "product" "(0x200c|0x2202)"; action "kldload -n if_aue"; @@ -1109,7 +1125,7 @@ nomatch 32 { match "bus" "uhub[0-9]+"; match "mode" "host"; match "vendor" "0x067b"; - match "product" "(0x04bb|0x0609|0x0611|0x0612|0x1234|0x206a|0x2303)"; + match "product" "(0x0307|0x04bb|0x0609|0x0611|0x0612|0x1234|0x206a|0x2303)"; action "kldload -n uplcom"; }; @@ -1156,6 +1172,14 @@ nomatch 32 { nomatch 32 { match "bus" "uhub[0-9]+"; match "mode" "host"; + match "vendor" "0x06ce"; + match "product" "0x8311"; + action "kldload -n uftdi"; +}; + +nomatch 32 { + match "bus" "uhub[0-9]+"; + match "mode" "host"; match "vendor" "0x06e1"; match "product" "(0x0008|0x0009)"; action "kldload -n if_kue"; @@ -1301,7 +1325,7 @@ nomatch 32 { match "bus" "uhub[0-9]+"; match "mode" "host"; match "vendor" "0x0789"; - match "product" "(0x0162|0x0163|0x0164|0x0166)"; + match "product" "(0x0162|0x0163|0x0164|0x0166|0x0168)"; action "kldload -n if_run"; }; @@ -1653,7 +1677,7 @@ nomatch 32 { match "bus" "uhub[0-9]+"; match "mode" "host"; match "vendor" "0x0856"; - match "product" "0xac01"; + match "product" "(0xac01|0xac02|0xac03|0xac11|0xac12|0xac16|0xac17|0xac18|0xac19|0xac25|0xac26|0xac27|0xac33|0xac34|0xac49|0xac50|0xba02)"; action "kldload -n uftdi"; }; @@ -1876,6 +1900,14 @@ nomatch 32 { nomatch 32 { match "bus" "uhub[0-9]+"; match "mode" "host"; + match "vendor" "0x0acd"; + match "product" "0x0300"; + action "kldload -n uftdi"; +}; + +nomatch 32 { + match "bus" "uhub[0-9]+"; + match "mode" "host"; match "vendor" "0x0ace"; match "product" "(0x1211|0x1215)"; action "kldload -n if_zyd"; @@ -2045,6 +2077,14 @@ nomatch 32 { match "bus" "uhub[0-9]+"; match "mode" "host"; match "vendor" "0x0b39"; + match "product" "0x0103"; + action "kldload -n uftdi"; +}; + +nomatch 32 { + match "bus" "uhub[0-9]+"; + match "mode" "host"; + match "vendor" "0x0b39"; match "product" "0x0109"; action "kldload -n if_aue"; }; @@ -2172,6 +2212,22 @@ nomatch 32 { nomatch 32 { match "bus" "uhub[0-9]+"; match "mode" "host"; + match "vendor" "0x0c26"; + match "product" "(0x0004|0x0009|0x000a|0x000b|0x000c|0x000d|0x0010|0x0011|0x0012|0x0013|0x0018)"; + action "kldload -n uftdi"; +}; + +nomatch 32 { + match "bus" "uhub[0-9]+"; + match "mode" "host"; + match "vendor" "0x0c33"; + match "product" "0x0010"; + action "kldload -n uftdi"; +}; + +nomatch 32 { + match "bus" "uhub[0-9]+"; + match "mode" "host"; match "vendor" "0x0c44"; match "product" "0x03a2"; action "kldload -n uipaq"; @@ -2180,6 +2236,30 @@ nomatch 32 { nomatch 32 { match "bus" "uhub[0-9]+"; match "mode" "host"; + match "vendor" "0x0c52"; + match "product" "(0x2101|0x2102|0x2103|0x2104|0x2211|0x2212|0x2213|0x2221|0x2222|0x2223|0x2411|0x2412|0x2413|0x2421|0x2422|0x2423|0x2431|0x2432|0x2433|0x2441|0x2442|0x2443|0x2811|0x2812|0x2813|0x2821|0x2822|0x2823|0x2831|0x2832|0x2833|0x2841|0x2842|0x2843|0x2851|0x2852|0x2853|0x2861|0x2862|0x2863|0x2871|0x2872|0x2873|0x2881|0x2882|0x2883|0x9020)"; + action "kldload -n uftdi"; +}; + +nomatch 32 { + match "bus" "uhub[0-9]+"; + match "mode" "host"; + match "vendor" "0x0c6c"; + match "product" "0x04b2"; + action "kldload -n uftdi"; +}; + +nomatch 32 { + match "bus" "uhub[0-9]+"; + match "mode" "host"; + match "vendor" "0x0c7d"; + match "product" "0x0005"; + action "kldload -n uftdi"; +}; + +nomatch 32 { + match "bus" "uhub[0-9]+"; + match "mode" "host"; match "vendor" "0x0c88"; match "product" "0x17da"; action "kldload -n u3g"; @@ -2276,6 +2356,22 @@ nomatch 32 { nomatch 32 { match "bus" "uhub[0-9]+"; match "mode" "host"; + match "vendor" "0x0d3a"; + match "product" "0x0300"; + action "kldload -n uftdi"; +}; + +nomatch 32 { + match "bus" "uhub[0-9]+"; + match "mode" "host"; + match "vendor" "0x0d46"; + match "product" "(0x2020|0x2021)"; + action "kldload -n uftdi"; +}; + +nomatch 32 { + match "bus" "uhub[0-9]+"; + match "mode" "host"; match "vendor" "0x0d8e"; match "product" "0x3762"; action "kldload -n if_upgt"; @@ -2340,6 +2436,14 @@ nomatch 32 { nomatch 32 { match "bus" "uhub[0-9]+"; match "mode" "host"; + match "vendor" "0x0dcd"; + match "product" "0x0001"; + action "kldload -n uftdi"; +}; + +nomatch 32 { + match "bus" "uhub[0-9]+"; + match "mode" "host"; match "vendor" "0x0df6"; match "product" "0x000d"; action "kldload -n if_urtw"; @@ -2557,7 +2661,7 @@ nomatch 32 { match "bus" "uhub[0-9]+"; match "mode" "host"; match "vendor" "0x0f94"; - match "product" "0x0001"; + match "product" "(0x0001|0x0005)"; action "kldload -n uftdi"; }; @@ -2588,6 +2692,14 @@ nomatch 32 { nomatch 32 { match "bus" "uhub[0-9]+"; match "mode" "host"; + match "vendor" "0x0fd8"; + match "product" "0x0001"; + action "kldload -n uftdi"; +}; + +nomatch 32 { + match "bus" "uhub[0-9]+"; + match "mode" "host"; match "vendor" "0x0fe6"; match "product" "(0x8101|0x9700)"; action "kldload -n if_udav"; @@ -2612,6 +2724,14 @@ nomatch 32 { nomatch 32 { match "bus" "uhub[0-9]+"; match "mode" "host"; + match "vendor" "0x103e"; + match "product" "0x03e8"; + action "kldload -n uftdi"; +}; + +nomatch 32 { + match "bus" "uhub[0-9]+"; + match "mode" "host"; match "vendor" "0x1044"; match "product" "0x8001"; action "kldload -n if_ural"; @@ -2725,7 +2845,7 @@ nomatch 32 { match "bus" "uhub[0-9]+"; match "mode" "host"; match "vendor" "0x10c4"; - match "product" "(0x8066|0x806f|0x807a|0x80ca|0x80dd|0x80ed|0x80f6|0x8115|0x813d|0x813f|0x814a|0x814a|0x814b|0x8156|0x815e|0x818b|0x819f|0x81a6|0x81ac|0x81ad|0x81c8|0x81e2|0x81e7|0x81e8|0x81f2|0x8218|0x822b|0x826b|0x8293|0x82f9|0x8341|0x8382|0x83a8|0x8411|0x846e|0x8477|0xea60|0xea61|0xea71|0xf001|0xf002|0xf003|0xf004)"; + match "product" "(0x8066|0x806f|0x807a|0x80c4|0x80ca|0x80dd|0x80ed|0x80f6|0x8115|0x813d|0x813f|0x814a|0x814a|0x814b|0x8156|0x815e|0x815f|0x818b|0x819f|0x81a6|0x81a9|0x81ac|0x81ad|0x81c8|0x81e2|0x81e7|0x81e8|0x81f2|0x8218|0x822b|0x826b|0x8293|0x82f9|0x8341|0x8382|0x83a8|0x83d8|0x8411|0x8418|0x846e|0x8477|0x85ea|0x85eb|0x8664|0x8665|0xea60|0xea61|0xea70|0xea71|0xea80|0xf001|0xf002|0xf003|0xf004)"; action "kldload -n uslcom"; }; @@ -2900,6 +3020,14 @@ nomatch 32 { nomatch 32 { match "bus" "uhub[0-9]+"; match "mode" "host"; + match "vendor" "0x1209"; + match "product" "(0x1002|0x1006)"; + action "kldload -n uftdi"; +}; + +nomatch 32 { + match "bus" "uhub[0-9]+"; + match "mode" "host"; match "vendor" "0x1231"; match "product" "(0xce01|0xce02)"; action "kldload -n uipaq"; @@ -2916,6 +3044,14 @@ nomatch 32 { nomatch 32 { match "bus" "uhub[0-9]+"; match "mode" "host"; + match "vendor" "0x128d"; + match "product" "0x0001"; + action "kldload -n uftdi"; +}; + +nomatch 32 { + match "bus" "uhub[0-9]+"; + match "mode" "host"; match "vendor" "0x129b"; match "product" "0x1666"; action "kldload -n if_zyd"; @@ -2933,7 +3069,7 @@ nomatch 32 { match "bus" "uhub[0-9]+"; match "mode" "host"; match "vendor" "0x12d1"; - match "product" "(0x1001|0x1003|0x1004|0x1401|0x1402|0x1403|0x1404|0x1405|0x1406|0x1407|0x1408|0x1409|0x140a|0x140b|0x140c|0x140d|0x140e|0x140f|0x1410|0x1411|0x1412|0x1413|0x1414|0x1415|0x1416|0x1417|0x1418|0x1419|0x141a|0x141b|0x141c|0x141d|0x141e|0x141f|0x1420|0x1421|0x1422|0x1423|0x1424|0x1425|0x1426|0x1427|0x1428|0x1429|0x142a|0x142b|0x142c|0x142d|0x142e|0x142f|0x1430|0x1431|0x1432|0x1433|0x1434|0x1435|0x1436|0x1437|0x1438|0x1439|0x143a|0x143b|0x143c|0x143d|0x143e|0x143f|0x1446|0x1465|0x14ac|0x1520|0x1c05|0x1c0b)"; + match "product" "(0x1001|0x1003|0x1004|0x1401|0x1402|0x1403|0x1404|0x1405|0x1406|0x1407|0x1408|0x1409|0x140a|0x140b|0x140c|0x140d|0x140e|0x140f|0x1410|0x1411|0x1412|0x1413|0x1414|0x1415|0x1416|0x1417|0x1418|0x1419|0x141a|0x141b|0x141c|0x141d|0x141e|0x141f|0x1420|0x1421|0x1422|0x1423|0x1424|0x1425|0x1426|0x1427|0x1428|0x1429|0x142a|0x142b|0x142c|0x142d|0x142e|0x142f|0x1430|0x1431|0x1432|0x1433|0x1434|0x1435|0x1436|0x1437|0x1438|0x1439|0x143a|0x143b|0x143c|0x143d|0x143e|0x143f|0x1446|0x1465|0x14ac|0x14fe|0x1505|0x1506|0x1520|0x1803|0x1c05|0x1c0b)"; action "kldload -n u3g"; }; @@ -2949,6 +3085,14 @@ nomatch 32 { match "bus" "uhub[0-9]+"; match "mode" "host"; match "vendor" "0x1342"; + match "product" "0x0202"; + action "kldload -n uftdi"; +}; + +nomatch 32 { + match "bus" "uhub[0-9]+"; + match "mode" "host"; + match "vendor" "0x1342"; match "product" "0x0204"; action "kldload -n if_kue"; }; @@ -3108,6 +3252,14 @@ nomatch 32 { nomatch 32 { match "bus" "uhub[0-9]+"; match "mode" "host"; + match "vendor" "0x1457"; + match "product" "(0x5118|0x5118)"; + action "kldload -n uftdi"; +}; + +nomatch 32 { + match "bus" "uhub[0-9]+"; + match "mode" "host"; match "vendor" "0x1472"; match "product" "0x0009"; action "kldload -n if_rum"; @@ -3332,6 +3484,14 @@ nomatch 32 { nomatch 32 { match "bus" "uhub[0-9]+"; match "mode" "host"; + match "vendor" "0x15ba"; + match "product" "(0x0003|0x002b)"; + action "kldload -n uftdi"; +}; + +nomatch 32 { + match "bus" "uhub[0-9]+"; + match "mode" "host"; match "vendor" "0x15c5"; match "product" "0x0008"; action "kldload -n if_run"; @@ -3381,7 +3541,7 @@ nomatch 32 { match "bus" "uhub[0-9]+"; match "mode" "host"; match "vendor" "0x166a"; - match "product" "0x0303"; + match "product" "(0x0101|0x0201|0x0301|0x0303|0x0304|0x0305|0x0401)"; action "kldload -n uslcom"; }; @@ -3477,7 +3637,7 @@ nomatch 32 { match "bus" "uhub[0-9]+"; match "mode" "host"; match "vendor" "0x16d6"; - match "product" "(0x0001|0x0001)"; + match "product" "0x0001"; action "kldload -n uslcom"; }; @@ -3596,6 +3756,22 @@ nomatch 32 { nomatch 32 { match "bus" "uhub[0-9]+"; match "mode" "host"; + match "vendor" "0x1781"; + match "product" "0x0c30"; + action "kldload -n uftdi"; +}; + +nomatch 32 { + match "bus" "uhub[0-9]+"; + match "mode" "host"; + match "vendor" "0x17a8"; + match "product" "(0x0001|0x0005)"; + action "kldload -n uslcom"; +}; + +nomatch 32 { + match "bus" "uhub[0-9]+"; + match "mode" "host"; match "vendor" "0x17f4"; match "product" "0xaaaa"; action "kldload -n uslcom"; @@ -3676,6 +3852,14 @@ nomatch 32 { nomatch 32 { match "bus" "uhub[0-9]+"; match "mode" "host"; + match "vendor" "0x1a79"; + match "product" "0x6001"; + action "kldload -n uftdi"; +}; + +nomatch 32 { + match "bus" "uhub[0-9]+"; + match "mode" "host"; match "vendor" "0x1a86"; match "product" "0x7523"; action "kldload -n uchcom"; @@ -3693,7 +3877,7 @@ nomatch 32 { match "bus" "uhub[0-9]+"; match "mode" "host"; match "vendor" "0x1b3d"; - match "product" "0x0153"; + match "product" "(0x0100|0x0101|0x0102|0x0103|0x0104|0x0105|0x0106|0x0107|0x0108|0x0109|0x010a|0x010b|0x010c|0x010d|0x010e|0x010f|0x0110|0x0111|0x0112|0x0113|0x0114|0x0115|0x0116|0x0117|0x0118|0x0119|0x011a|0x011b|0x011c|0x011d|0x011e|0x011f|0x0120|0x0121|0x0122|0x0123|0x0124|0x0125|0x0126|0x0128|0x0129|0x012a|0x012b|0x012d|0x012e|0x012f|0x0130|0x0131|0x0132|0x0133|0x0134|0x0135|0x0136|0x0137|0x0138|0x0139|0x013a|0x013b|0x013c|0x013d|0x013e|0x013f|0x0140|0x0141|0x0142|0x0143|0x0144|0x0145|0x0146|0x0147|0x0148|0x0149|0x014a|0x014b|0x014c|0x014d|0x014e|0x014f|0x0150|0x0151|0x0152|0x0153|0x0159|0x015a|0x015b|0x015c|0x015d|0x015e|0x015f|0x0160|0x0161|0x0162|0x0163|0x0164|0x0165|0x0166|0x0167|0x0168|0x0169|0x016a|0x016b|0x016c|0x016d|0x016e|0x016f|0x0170|0x0171|0x0172|0x0173|0x0174|0x0175|0x0176|0x0177|0x0178|0x0179|0x017a|0x017b|0x017c|0x017d|0x017e|0x017f|0x0180|0x0181|0x0182|0x0183|0x0184|0x0185|0x0186|0x0187|0x0188|0x0189|0x018a|0x018b|0x018c|0x018d|0x018e|0x018f|0x0190|0x0191|0x019 2|0x0193|0x0194|0x0195|0x0196|0x0197|0x0198|0x0199|0x019a|0x019b|0x019c|0x019d|0x019e|0x019f|0x01a0|0x01a1|0x01a2|0x01a3|0x01a4|0x01a5|0x01a6|0x01a7|0x01a8|0x01a9|0x01aa|0x01ab|0x01ac|0x01ad|0x01ae|0x01af|0x01b0|0x01b1|0x01b2|0x01b3|0x01b4|0x01b5|0x01b6|0x01b7|0x01b8|0x01b9|0x01ba|0x01bb|0x01bc|0x01bd|0x01be|0x01bf|0x01c0|0x01c1|0x01c2|0x01c3|0x01c4|0x01c5|0x01c6|0x01c7|0x01c8|0x01c9|0x01ca|0x01cb|0x01cc|0x01cd|0x01ce|0x01cf|0x01d0|0x01d1|0x01d2|0x01d3|0x01d4|0x01d5|0x01d6|0x01d7|0x01d8|0x01d9|0x01da|0x01db|0x01dc|0x01dd|0x01de|0x01df|0x01e0|0x01e1|0x01e2|0x01e3|0x01e4|0x01e5|0x01e6|0x01e7|0x01e8|0x01e9|0x01ea|0x01eb|0x01ec|0x01ed|0x01ee|0x01ef|0x01f0|0x01f1|0x01f2|0x01f3|0x01f4|0x01f5|0x01f6|0x01f7|0x01f8|0x01f9|0x01fa|0x01fb|0x01fc|0x01fd|0x01fe|0x01ff)"; action "kldload -n uftdi"; }; @@ -3716,6 +3900,14 @@ nomatch 32 { nomatch 32 { match "bus" "uhub[0-9]+"; match "mode" "host"; + match "vendor" "0x1b91"; + match "product" "0x0064"; + action "kldload -n uftdi"; +}; + +nomatch 32 { + match "bus" "uhub[0-9]+"; + match "mode" "host"; match "vendor" "0x1bbb"; match "product" "(0x0000|0xf000)"; action "kldload -n u3g"; @@ -3732,6 +3924,14 @@ nomatch 32 { nomatch 32 { match "bus" "uhub[0-9]+"; match "mode" "host"; + match "vendor" "0x1bc9"; + match "product" "0x6001"; + action "kldload -n uftdi"; +}; + +nomatch 32 { + match "bus" "uhub[0-9]+"; + match "mode" "host"; match "vendor" "0x1be3"; match "product" "0x07a6"; action "kldload -n uslcom"; @@ -3740,6 +3940,14 @@ nomatch 32 { nomatch 32 { match "bus" "uhub[0-9]+"; match "mode" "host"; + match "vendor" "0x1c0c"; + match "product" "0x0102"; + action "kldload -n uftdi"; +}; + +nomatch 32 { + match "bus" "uhub[0-9]+"; + match "mode" "host"; match "vendor" "0x1c9e"; match "product" "(0x6061|0x9603|0x9605|0xf000)"; action "kldload -n u3g"; @@ -3788,6 +3996,14 @@ nomatch 32 { nomatch 32 { match "bus" "uhub[0-9]+"; match "mode" "host"; + match "vendor" "0x1e29"; + match "product" "(0x0102|0x0501)"; + action "kldload -n uslcom"; +}; + +nomatch 32 { + match "bus" "uhub[0-9]+"; + match "mode" "host"; match "vendor" "0x1eda"; match "product" "0x2310"; action "kldload -n if_run"; @@ -3924,6 +4140,14 @@ nomatch 32 { nomatch 32 { match "bus" "uhub[0-9]+"; match "mode" "host"; + match "vendor" "0x20b7"; + match "product" "0x0713"; + action "kldload -n uftdi"; +}; + +nomatch 32 { + match "bus" "uhub[0-9]+"; + match "mode" "host"; match "vendor" "0x20b8"; match "product" "0x8888"; action "kldload -n if_run"; @@ -3940,6 +4164,14 @@ nomatch 32 { nomatch 32 { match "bus" "uhub[0-9]+"; match "mode" "host"; + match "vendor" "0x2100"; + match "product" "(0x9e52|0x9e54)"; + action "kldload -n uftdi"; +}; + +nomatch 32 { + match "bus" "uhub[0-9]+"; + match "mode" "host"; match "vendor" "0x22b8"; match "product" "(0x4204|0x4214|0x4224|0x4234|0x4244)"; action "kldload -n uipaq"; @@ -3964,6 +4196,14 @@ nomatch 32 { nomatch 32 { match "bus" "uhub[0-9]+"; match "mode" "host"; + match "vendor" "0x3195"; + match "product" "(0xf190|0xf280|0xf281)"; + action "kldload -n uslcom"; +}; + +nomatch 32 { + match "bus" "uhub[0-9]+"; + match "mode" "host"; match "vendor" "0x3334"; match "product" "0x1701"; action "kldload -n if_aue"; @@ -4052,6 +4292,14 @@ nomatch 32 { nomatch 32 { match "bus" "uhub[0-9]+"; match "mode" "host"; + match "vendor" "0x5050"; + match "product" "(0x0100|0x0101|0x0102|0x0103|0x0104|0x0105|0x0106|0x0107|0x0300|0x0301|0x0400|0x0500|0x0700|0x0800|0x0900|0x0a00|0x0b00|0x0c00|0x0d00|0x0e00|0x0f00|0x1000|0x8000|0x8001|0x8002|0x8003|0x8004|0x8005)"; + action "kldload -n uftdi"; +}; + +nomatch 32 { + match "bus" "uhub[0-9]+"; + match "mode" "host"; match "vendor" "0x5173"; match "product" "0x1809"; action "kldload -n if_zyd"; @@ -4204,6 +4452,14 @@ nomatch 32 { nomatch 32 { match "bus" "uhub[0-9]+"; match "mode" "host"; + match "vendor" "0xdeee"; + match "product" "(0x0300|0x0302|0x0303)"; + action "kldload -n uftdi"; +}; + +nomatch 32 { + match "bus" "uhub[0-9]+"; + match "mode" "host"; match "intclass" "0x02"; match "intsubclass" "0x02"; match "intprotocol" "0x01"; @@ -4344,5 +4600,5 @@ nomatch 32 { action "kldload -n umass"; }; -# 1654 USB entries processed +# 2271 USB entries processed From owner-svn-src-stable@FreeBSD.ORG Tue Sep 18 17:37:49 2012 Return-Path: Delivered-To: svn-src-stable@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 7D1821065686; Tue, 18 Sep 2012 17:37:49 +0000 (UTC) (envelope-from hselasky@c2i.net) Received: from swip.net (mailfe06.c2i.net [212.247.154.162]) by mx1.freebsd.org (Postfix) with ESMTP id 84C018FC17; Tue, 18 Sep 2012 17:37:47 +0000 (UTC) X-T2-Spam-Status: No, hits=-1.0 required=5.0 tests=ALL_TRUSTED Received: from [176.74.213.204] (account mc467741@c2i.net HELO laptop015.hselasky.homeunix.org) by mailfe06.swip.net (CommuniGate Pro SMTP 5.4.4) with ESMTPA id 320548105; Tue, 18 Sep 2012 19:37:46 +0200 From: Hans Petter Selasky To: Konstantin Belousov Date: Tue, 18 Sep 2012 19:38:58 +0200 User-Agent: KMail/1.13.7 (FreeBSD/9.1-PRERELEASE; KDE/4.8.4; amd64; ; ) References: <201209181628.q8IGSoOF024628@svn.freebsd.org> <20120918172705.GK37286@deviant.kiev.zoral.com.ua> In-Reply-To: <20120918172705.GK37286@deviant.kiev.zoral.com.ua> X-Face: 'mmZ:T{)),Oru^0c+/}w'`gU1$ubmG?lp!=R4Wy\ELYo2)@'UZ24N@d2+AyewRX}mAm; Yp |U[@, _z/([?1bCfM{_"B<.J>mICJCHAzzGHI{y7{%JVz%R~yJHIji`y>Y}k1C4TfysrsUI -%GU9V5]iUZF&nRn9mJ'?&>O MIME-Version: 1.0 Content-Type: Text/Plain; charset="iso-8859-15" Content-Transfer-Encoding: 7bit Message-Id: <201209181938.59008.hselasky@c2i.net> Cc: svn-src-stable@freebsd.org, svn-src-all@freebsd.org, src-committers@freebsd.org, svn-src-stable-9@freebsd.org Subject: Re: svn commit: r240659 - in stable/9/sys: dev/usb/net dev/usb/serial kern sys X-BeenThere: svn-src-stable@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for all the -stable branches of the src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 18 Sep 2012 17:37:49 -0000 On Tuesday 18 September 2012 19:27:05 Konstantin Belousov wrote: > On Tue, Sep 18, 2012 at 04:28:50PM +0000, Hans Petter Selasky wrote: > > Author: hselasky > > Date: Tue Sep 18 16:28:49 2012 > > New Revision: 240659 > > URL: http://svn.freebsd.org/changeset/base/240659 > > > > Log: > > MFC r239178, r239179, r239180, r239181, r239182 and r239299: > > > > Fix detach of USB serial devices so that it doesn't block > > the USB explore thread forever. To accomplish this two new > > functions have been added to the kernel, to claim and free > > the newbus allocated softc. > > > > This change is backwards API compatible, but not binary > > compatible. The FreeBSD version has been bumped to force > > a recompile of all kernel modules. > > Thank you, I run with this change since it was committed to head, and > the only issue left is that the same serial adapter reappears under the > different cuaUNN name after the glitch. This causes apcupsd to not able > to reconnect. > > And, the big question that still applies, is why UPSes are lost from the > USB bus ? Hi, Loss of VBUS (+5) and overcurrent are some natural reasons a device can suddenly disconnect. Do you have a bad/loose connector? Other reasons: Device firmware has restarted. Many serial applications fail to exit when reading from a serial device fails. --HPS From owner-svn-src-stable@FreeBSD.ORG Tue Sep 18 17:45:20 2012 Return-Path: Delivered-To: svn-src-stable@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 4A478106566B; Tue, 18 Sep 2012 17:45:20 +0000 (UTC) (envelope-from kostikbel@gmail.com) Received: from mail.zoral.com.ua (mx0.zoral.com.ua [91.193.166.200]) by mx1.freebsd.org (Postfix) with ESMTP id D3F038FC08; Tue, 18 Sep 2012 17:45:19 +0000 (UTC) Received: from skuns.kiev.zoral.com.ua (localhost [127.0.0.1]) by mail.zoral.com.ua (8.14.2/8.14.2) with ESMTP id q8IHjO4H034061; Tue, 18 Sep 2012 20:45:24 +0300 (EEST) (envelope-from kostikbel@gmail.com) Received: from deviant.kiev.zoral.com.ua (kostik@localhost [127.0.0.1]) by deviant.kiev.zoral.com.ua (8.14.5/8.14.5) with ESMTP id q8IHjCNX036459; Tue, 18 Sep 2012 20:45:12 +0300 (EEST) (envelope-from kostikbel@gmail.com) Received: (from kostik@localhost) by deviant.kiev.zoral.com.ua (8.14.5/8.14.5/Submit) id q8IHjCU0036458; Tue, 18 Sep 2012 20:45:12 +0300 (EEST) (envelope-from kostikbel@gmail.com) X-Authentication-Warning: deviant.kiev.zoral.com.ua: kostik set sender to kostikbel@gmail.com using -f Date: Tue, 18 Sep 2012 20:45:12 +0300 From: Konstantin Belousov To: Hans Petter Selasky Message-ID: <20120918174512.GL37286@deviant.kiev.zoral.com.ua> References: <201209181628.q8IGSoOF024628@svn.freebsd.org> <20120918172705.GK37286@deviant.kiev.zoral.com.ua> <201209181938.59008.hselasky@c2i.net> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="KasUm1oH6X2AfSvU" Content-Disposition: inline In-Reply-To: <201209181938.59008.hselasky@c2i.net> User-Agent: Mutt/1.5.21 (2010-09-15) X-Virus-Scanned: clamav-milter 0.95.2 at skuns.kiev.zoral.com.ua X-Virus-Status: Clean X-Spam-Status: No, score=-4.0 required=5.0 tests=ALL_TRUSTED,AWL,BAYES_00 autolearn=ham version=3.2.5 X-Spam-Checker-Version: SpamAssassin 3.2.5 (2008-06-10) on skuns.kiev.zoral.com.ua Cc: svn-src-stable@freebsd.org, svn-src-all@freebsd.org, src-committers@freebsd.org, svn-src-stable-9@freebsd.org Subject: Re: svn commit: r240659 - in stable/9/sys: dev/usb/net dev/usb/serial kern sys X-BeenThere: svn-src-stable@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for all the -stable branches of the src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 18 Sep 2012 17:45:20 -0000 --KasUm1oH6X2AfSvU Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Tue, Sep 18, 2012 at 07:38:58PM +0200, Hans Petter Selasky wrote: > On Tuesday 18 September 2012 19:27:05 Konstantin Belousov wrote: > > On Tue, Sep 18, 2012 at 04:28:50PM +0000, Hans Petter Selasky wrote: > > > Author: hselasky > > > Date: Tue Sep 18 16:28:49 2012 > > > New Revision: 240659 > > > URL: http://svn.freebsd.org/changeset/base/240659 > > >=20 > > > Log: > > > MFC r239178, r239179, r239180, r239181, r239182 and r239299: > > > =20 > > > Fix detach of USB serial devices so that it doesn't block > > > the USB explore thread forever. To accomplish this two new > > > functions have been added to the kernel, to claim and free > > > the newbus allocated softc. > > > =20 > > > This change is backwards API compatible, but not binary > > > compatible. The FreeBSD version has been bumped to force > > > a recompile of all kernel modules. > >=20 > > Thank you, I run with this change since it was committed to head, and > > the only issue left is that the same serial adapter reappears under the > > different cuaUNN name after the glitch. This causes apcupsd to not able > > to reconnect. > >=20 > > And, the big question that still applies, is why UPSes are lost from the > > USB bus ? >=20 > Hi, >=20 > Loss of VBUS (+5) and overcurrent are some natural reasons a device can= =20 > suddenly disconnect. >=20 > Do you have a bad/loose connector? I doubt it. The device reattaches momentarily after the loss. >=20 > Other reasons: Device firmware has restarted. Both 'devices' are APC UPSes, one is attached through the USB/serial cable driven by uplcom, another one (attached to different machine, with different chipset) is seen as gen device. I hear the relay clicks synchronous with the kernel reporting device lost. >=20 > Many serial applications fail to exit when reading from a serial device f= ails. This is apcupsd. --KasUm1oH6X2AfSvU Content-Type: application/pgp-signature -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.12 (FreeBSD) iEYEARECAAYFAlBYsygACgkQC3+MBN1Mb4jAcQCg4oGFoGe1qUBqt/ASvLovQwlU EDQAn1/yVUucnO4WA22HDOS9uzn/HsyA =E29A -----END PGP SIGNATURE----- --KasUm1oH6X2AfSvU-- From owner-svn-src-stable@FreeBSD.ORG Tue Sep 18 19:08:09 2012 Return-Path: Delivered-To: svn-src-stable@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id BABD81065692; Tue, 18 Sep 2012 19:08:08 +0000 (UTC) (envelope-from jkim@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 90C9F8FC0A; Tue, 18 Sep 2012 19:08:08 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q8IJ88cX045976; Tue, 18 Sep 2012 19:08:08 GMT (envelope-from jkim@svn.freebsd.org) Received: (from jkim@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q8IJ88U5045970; Tue, 18 Sep 2012 19:08:08 GMT (envelope-from jkim@svn.freebsd.org) Message-Id: <201209181908.q8IJ88U5045970@svn.freebsd.org> From: Jung-uk Kim Date: Tue, 18 Sep 2012 19:08:08 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r240673 - in stable/9/usr.sbin/pkg_install: add lib X-BeenThere: svn-src-stable@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for all the -stable branches of the src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 18 Sep 2012 19:08:09 -0000 Author: jkim Date: Tue Sep 18 19:08:07 2012 New Revision: 240673 URL: http://svn.freebsd.org/changeset/base/240673 Log: MFC: r240476 Do not change owner, group, or mode when package database directory and its contents are created with pkg_add(1). It may happen when the packing list contains @owner, @group, or @mode. Approved by: portmgr (bapt) Modified: stable/9/usr.sbin/pkg_install/add/add.h stable/9/usr.sbin/pkg_install/add/extract.c stable/9/usr.sbin/pkg_install/add/futil.c stable/9/usr.sbin/pkg_install/add/perform.c stable/9/usr.sbin/pkg_install/lib/lib.h Directory Properties: stable/9/usr.sbin/pkg_install/ (props changed) stable/9/usr.sbin/pkg_install/add/ (props changed) Modified: stable/9/usr.sbin/pkg_install/add/add.h ============================================================================== --- stable/9/usr.sbin/pkg_install/add/add.h Tue Sep 18 18:23:21 2012 (r240672) +++ stable/9/usr.sbin/pkg_install/add/add.h Tue Sep 18 19:08:07 2012 (r240673) @@ -41,7 +41,7 @@ extern char *PkgAddCmd; extern char FirstPen[]; extern add_mode_t AddMode; -int make_hierarchy(char *); +int make_hierarchy(char *, Boolean); void extract_plist(const char *, Package *); void apply_perms(const char *, const char *); Modified: stable/9/usr.sbin/pkg_install/add/extract.c ============================================================================== --- stable/9/usr.sbin/pkg_install/add/extract.c Tue Sep 18 18:23:21 2012 (r240672) +++ stable/9/usr.sbin/pkg_install/add/extract.c Tue Sep 18 19:08:07 2012 (r240673) @@ -225,7 +225,7 @@ extract_plist(const char *home, Package printf("extract: CWD to %s\n", p->name); PUSHOUT(Directory); if (strcmp(p->name, ".")) { - if (!Fake && make_hierarchy(p->name) == FAIL) { + if (!Fake && make_hierarchy(p->name, TRUE) == FAIL) { cleanup(0); errx(2, "%s: unable to cwd to '%s'", __func__, p->name); } Modified: stable/9/usr.sbin/pkg_install/add/futil.c ============================================================================== --- stable/9/usr.sbin/pkg_install/add/futil.c Tue Sep 18 18:23:21 2012 (r240672) +++ stable/9/usr.sbin/pkg_install/add/futil.c Tue Sep 18 19:08:07 2012 (r240673) @@ -31,7 +31,7 @@ __FBSDID("$FreeBSD$"); */ int -make_hierarchy(char *dir) +make_hierarchy(char *dir, Boolean set_perm) { char *cp1, *cp2; @@ -55,7 +55,8 @@ make_hierarchy(char *dir) *cp2 = '/'; return FAIL; } - apply_perms(NULL, dir); + if (set_perm) + apply_perms(NULL, dir); } /* Put it back */ if (cp2) { Modified: stable/9/usr.sbin/pkg_install/add/perform.c ============================================================================== --- stable/9/usr.sbin/pkg_install/add/perform.c Tue Sep 18 18:23:21 2012 (r240672) +++ stable/9/usr.sbin/pkg_install/add/perform.c Tue Sep 18 19:08:07 2012 (r240673) @@ -511,7 +511,7 @@ pkg_do(char *pkg) zapLogDir = 1; if (Verbose) printf("Attempting to record package into %s..\n", LogDir); - if (make_hierarchy(LogDir)) { + if (make_hierarchy(LogDir, FALSE)) { warnx("can't record package into '%s', you're on your own!", LogDir); bzero(LogDir, FILENAME_MAX); Modified: stable/9/usr.sbin/pkg_install/lib/lib.h ============================================================================== --- stable/9/usr.sbin/pkg_install/lib/lib.h Tue Sep 18 18:23:21 2012 (r240672) +++ stable/9/usr.sbin/pkg_install/lib/lib.h Tue Sep 18 19:08:07 2012 (r240673) @@ -99,7 +99,7 @@ * Version of the package tools - increase whenever you make a change * in the code that is not cosmetic only. */ -#define PKG_INSTALL_VERSION 20120530 +#define PKG_INSTALL_VERSION 20120913 #define PKG_WRAPCONF_FNAME "/var/db/pkg_install.conf" #define main(argc, argv) real_main(argc, argv) From owner-svn-src-stable@FreeBSD.ORG Tue Sep 18 20:20:30 2012 Return-Path: Delivered-To: svn-src-stable@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 1A30D1065676; Tue, 18 Sep 2012 20:20:30 +0000 (UTC) (envelope-from bapt@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 011048FC1C; Tue, 18 Sep 2012 20:20:30 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q8IKKTnY055893; Tue, 18 Sep 2012 20:20:29 GMT (envelope-from bapt@svn.freebsd.org) Received: (from bapt@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q8IKKT4q055880; Tue, 18 Sep 2012 20:20:29 GMT (envelope-from bapt@svn.freebsd.org) Message-Id: <201209182020.q8IKKT4q055880@svn.freebsd.org> From: Baptiste Daroussin Date: Tue, 18 Sep 2012 20:20:29 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-8@freebsd.org X-SVN-Group: stable-8 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r240674 - in stable/8/usr.sbin/pkg_install: add lib X-BeenThere: svn-src-stable@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for all the -stable branches of the src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 18 Sep 2012 20:20:30 -0000 Author: bapt Date: Tue Sep 18 20:20:29 2012 New Revision: 240674 URL: http://svn.freebsd.org/changeset/base/240674 Log: MFC: r236213, r236333, r236336, r240476 - Let pkg_add use the ENV variable PACKAGESUFFIX - Make sure that each va_start has one and only one matching va_end - Do not change owner, group, or mode when package database directory and its contents are created with pkg_add(1). It may happen when the packing list contains @owner, @group, or @mode. Modified: stable/8/usr.sbin/pkg_install/add/add.h stable/8/usr.sbin/pkg_install/add/extract.c stable/8/usr.sbin/pkg_install/add/futil.c stable/8/usr.sbin/pkg_install/add/main.c stable/8/usr.sbin/pkg_install/add/perform.c stable/8/usr.sbin/pkg_install/add/pkg_add.1 stable/8/usr.sbin/pkg_install/lib/exec.c stable/8/usr.sbin/pkg_install/lib/file.c stable/8/usr.sbin/pkg_install/lib/lib.h stable/8/usr.sbin/pkg_install/lib/msg.c stable/8/usr.sbin/pkg_install/lib/url.c Directory Properties: stable/8/usr.sbin/pkg_install/ (props changed) stable/8/usr.sbin/pkg_install/add/ (props changed) Modified: stable/8/usr.sbin/pkg_install/add/add.h ============================================================================== --- stable/8/usr.sbin/pkg_install/add/add.h Tue Sep 18 19:08:07 2012 (r240673) +++ stable/8/usr.sbin/pkg_install/add/add.h Tue Sep 18 20:20:29 2012 (r240674) @@ -41,7 +41,7 @@ extern char *PkgAddCmd; extern char FirstPen[]; extern add_mode_t AddMode; -int make_hierarchy(char *); +int make_hierarchy(char *, Boolean); void extract_plist(const char *, Package *); void apply_perms(const char *, const char *); Modified: stable/8/usr.sbin/pkg_install/add/extract.c ============================================================================== --- stable/8/usr.sbin/pkg_install/add/extract.c Tue Sep 18 19:08:07 2012 (r240673) +++ stable/8/usr.sbin/pkg_install/add/extract.c Tue Sep 18 20:20:29 2012 (r240674) @@ -225,7 +225,7 @@ extract_plist(const char *home, Package printf("extract: CWD to %s\n", p->name); PUSHOUT(Directory); if (strcmp(p->name, ".")) { - if (!Fake && make_hierarchy(p->name) == FAIL) { + if (!Fake && make_hierarchy(p->name, TRUE) == FAIL) { cleanup(0); errx(2, "%s: unable to cwd to '%s'", __func__, p->name); } Modified: stable/8/usr.sbin/pkg_install/add/futil.c ============================================================================== --- stable/8/usr.sbin/pkg_install/add/futil.c Tue Sep 18 19:08:07 2012 (r240673) +++ stable/8/usr.sbin/pkg_install/add/futil.c Tue Sep 18 20:20:29 2012 (r240674) @@ -31,7 +31,7 @@ __FBSDID("$FreeBSD$"); */ int -make_hierarchy(char *dir) +make_hierarchy(char *dir, Boolean set_perm) { char *cp1, *cp2; @@ -55,7 +55,8 @@ make_hierarchy(char *dir) *cp2 = '/'; return FAIL; } - apply_perms(NULL, dir); + if (set_perm) + apply_perms(NULL, dir); } /* Put it back */ if (cp2) { Modified: stable/8/usr.sbin/pkg_install/add/main.c ============================================================================== --- stable/8/usr.sbin/pkg_install/add/main.c Tue Sep 18 19:08:07 2012 (r240673) +++ stable/8/usr.sbin/pkg_install/add/main.c Tue Sep 18 20:20:29 2012 (r240674) @@ -234,10 +234,17 @@ main(int argc, char **argv) remotepkg = temppackageroot; if (!((ptr = strrchr(remotepkg, '.')) && ptr[1] == 't' && (ptr[2] == 'b' || ptr[2] == 'g' || ptr[2] == 'x') && - ptr[3] == 'z' && !ptr[4])) - if (strlcat(remotepkg, ".tbz", - sizeof(temppackageroot)) >= sizeof(temppackageroot)) - errx(1, "package name too long"); + ptr[3] == 'z' && !ptr[4])) { + if (getenv("PACKAGESUFFIX")) { + if (strlcat(remotepkg, getenv("PACKAGESUFFIX"), + sizeof(temppackageroot)) >= sizeof(temppackageroot)) + errx(1, "package name too long"); + } else { + if (strlcat(remotepkg, ".tbz", + sizeof(temppackageroot)) >= sizeof(temppackageroot)) + errx(1, "package name too long"); + } + } } if (!strcmp(*argv, "-")) /* stdin? */ pkgs[ch] = (char *)"-"; Modified: stable/8/usr.sbin/pkg_install/add/perform.c ============================================================================== --- stable/8/usr.sbin/pkg_install/add/perform.c Tue Sep 18 19:08:07 2012 (r240673) +++ stable/8/usr.sbin/pkg_install/add/perform.c Tue Sep 18 20:20:29 2012 (r240674) @@ -307,8 +307,12 @@ pkg_do(char *pkg) *sep = '\0'; strlcat(subpkg, "/All/", sizeof subpkg); strlcat(subpkg, p->name, sizeof subpkg); - if ((ext = strrchr(pkg, '.')) == NULL) - ext = ".tbz"; + if ((ext = strrchr(pkg, '.')) == NULL) { + if (getenv("PACKAGESUFFIX")) + ext = getenv("PACKAGESUFFIX"); + else + ext = ".tbz"; + } strlcat(subpkg, ext, sizeof subpkg); pkg_do(subpkg); } @@ -345,8 +349,13 @@ pkg_do(char *pkg) const char *ext; ext = strrchr(pkg_fullname, '.'); - if (ext == NULL) - ext = ".tbz"; + if (ext == NULL) { + if (getenv("PACKAGESUFFIX")) { + ext = getenv("PACKAGESUFFIX"); + } else { + ext = ".tbz"; + } + } snprintf(path, FILENAME_MAX, "%s/%s%s", getenv("_TOP"), p->name, ext); if (fexists(path)) cp = path; @@ -502,7 +511,7 @@ pkg_do(char *pkg) zapLogDir = 1; if (Verbose) printf("Attempting to record package into %s..\n", LogDir); - if (make_hierarchy(LogDir)) { + if (make_hierarchy(LogDir, FALSE)) { warnx("can't record package into '%s', you're on your own!", LogDir); bzero(LogDir, FILENAME_MAX); Modified: stable/8/usr.sbin/pkg_install/add/pkg_add.1 ============================================================================== --- stable/8/usr.sbin/pkg_install/add/pkg_add.1 Tue Sep 18 19:08:07 2012 (r240673) +++ stable/8/usr.sbin/pkg_install/add/pkg_add.1 Tue Sep 18 20:20:29 2012 (r240674) @@ -553,6 +553,11 @@ The environment variable specifies an alternative location to save downloaded packages to when .Fl K option is used. +.Pp +The environment variable +.Ev PACKAGESUFFIX +specifies an alternative file extension to use when fetching remote +packages. Default is .tbz .Sh FILES .Bl -tag -width /var/db/pkg -compact .It Pa /var/tmp Modified: stable/8/usr.sbin/pkg_install/lib/exec.c ============================================================================== --- stable/8/usr.sbin/pkg_install/lib/exec.c Tue Sep 18 19:08:07 2012 (r240673) +++ stable/8/usr.sbin/pkg_install/lib/exec.c Tue Sep 18 20:20:29 2012 (r240674) @@ -47,6 +47,7 @@ vsystem(const char *fmt, ...) va_start(args, fmt); if (vsnprintf(cmd, maxargs, fmt, args) > maxargs) { warnx("vsystem args are too long"); + va_end(args); return 1; } #ifdef DEBUG @@ -82,6 +83,7 @@ vpipe(const char *fmt, ...) va_start(args, fmt); if (vsnprintf(cmd, maxargs, fmt, args) > maxargs) { warnx("vsystem args are too long"); + va_end(args); return NULL; } #ifdef DEBUG Modified: stable/8/usr.sbin/pkg_install/lib/file.c ============================================================================== --- stable/8/usr.sbin/pkg_install/lib/file.c Tue Sep 18 19:08:07 2012 (r240673) +++ stable/8/usr.sbin/pkg_install/lib/file.c Tue Sep 18 20:20:29 2012 (r240674) @@ -140,7 +140,7 @@ fileFindByPath(const char *base, const c { static char tmp[FILENAME_MAX]; char *cp; - const char *suffixes[] = {".tbz", ".tgz", ".tar", NULL}; + const char *suffixes[] = {".tbz", ".tgz", ".tar", ".txz", NULL}; int i; if (fexists(fname) && isfile(fname)) { Modified: stable/8/usr.sbin/pkg_install/lib/lib.h ============================================================================== --- stable/8/usr.sbin/pkg_install/lib/lib.h Tue Sep 18 19:08:07 2012 (r240673) +++ stable/8/usr.sbin/pkg_install/lib/lib.h Tue Sep 18 20:20:29 2012 (r240674) @@ -99,7 +99,7 @@ * Version of the package tools - increase whenever you make a change * in the code that is not cosmetic only. */ -#define PKG_INSTALL_VERSION 20100403 +#define PKG_INSTALL_VERSION 20120913 #define PKG_WRAPCONF_FNAME "/var/db/pkg_install.conf" #define main(argc, argv) real_main(argc, argv) Modified: stable/8/usr.sbin/pkg_install/lib/msg.c ============================================================================== --- stable/8/usr.sbin/pkg_install/lib/msg.c Tue Sep 18 19:08:07 2012 (r240673) +++ stable/8/usr.sbin/pkg_install/lib/msg.c Tue Sep 18 20:20:29 2012 (r240674) @@ -71,5 +71,6 @@ y_or_n(Boolean def, const char *msg, ... ch = (def) ? 'Y' : 'N'; } fclose(tty) ; + va_end(args); return (ch == 'Y') ? TRUE : FALSE; } Modified: stable/8/usr.sbin/pkg_install/lib/url.c ============================================================================== --- stable/8/usr.sbin/pkg_install/lib/url.c Tue Sep 18 19:08:07 2012 (r240673) +++ stable/8/usr.sbin/pkg_install/lib/url.c Tue Sep 18 20:20:29 2012 (r240674) @@ -73,7 +73,10 @@ fileGetURL(const char *base, const char *(cp + 1) = '\0'; strcat(cp, "All/"); strcat(cp, spec); - strcat(cp, ".tbz"); + if (getenv("PACKAGESUFFIX")) + strcat(cp, getenv("PACKAGESUFFIX")); + else + strcat(cp, ".tbz"); } else return NULL; @@ -85,7 +88,10 @@ fileGetURL(const char *base, const char */ strcpy(fname, hint); strcat(fname, spec); - strcat(fname, ".tbz"); + if (getenv("PACKAGESUFFIX")) + strcat(fname, getenv("PACKAGESUFFIX")); + else + strcat(fname, ".tbz"); } } else From owner-svn-src-stable@FreeBSD.ORG Wed Sep 19 06:18:43 2012 Return-Path: Delivered-To: svn-src-stable@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 23DC31065672; Wed, 19 Sep 2012 06:18:43 +0000 (UTC) (envelope-from bapt@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 0DF248FC08; Wed, 19 Sep 2012 06:18:43 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q8J6Ig4H038338; Wed, 19 Sep 2012 06:18:42 GMT (envelope-from bapt@svn.freebsd.org) Received: (from bapt@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q8J6IgVU038336; Wed, 19 Sep 2012 06:18:42 GMT (envelope-from bapt@svn.freebsd.org) Message-Id: <201209190618.q8J6IgVU038336@svn.freebsd.org> From: Baptiste Daroussin Date: Wed, 19 Sep 2012 06:18:42 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r240687 - stable/9/lib/libutil X-BeenThere: svn-src-stable@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for all the -stable branches of the src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 19 Sep 2012 06:18:43 -0000 Author: bapt Date: Wed Sep 19 06:18:42 2012 New Revision: 240687 URL: http://svn.freebsd.org/changeset/base/240687 Log: MFC: r240391 Fix IEC / SI binary prefixes (Ki, Mi, Gi, etc) production by humanize_number(3) PR: bin/171487 Submitted by: matthew Modified: stable/9/lib/libutil/humanize_number.c Directory Properties: stable/9/lib/libutil/ (props changed) Modified: stable/9/lib/libutil/humanize_number.c ============================================================================== --- stable/9/lib/libutil/humanize_number.c Wed Sep 19 05:11:25 2012 (r240686) +++ stable/9/lib/libutil/humanize_number.c Wed Sep 19 06:18:42 2012 (r240687) @@ -76,7 +76,7 @@ humanize_number(char *buf, size_t len, i if (flags & HN_B) prefixes = "B\0\0Ki\0Mi\0Gi\0Ti\0Pi\0Ei"; else - prefixes = "\0\0Ki\0Mi\0Gi\0Ti\0Pi\0Ei"; + prefixes = "\0\0\0Ki\0Mi\0Gi\0Ti\0Pi\0Ei"; } else { baselen = 1; if (flags & HN_DIVISOR_1000) From owner-svn-src-stable@FreeBSD.ORG Wed Sep 19 06:20:26 2012 Return-Path: Delivered-To: svn-src-stable@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 2DAF5106566B; Wed, 19 Sep 2012 06:20:26 +0000 (UTC) (envelope-from bapt@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 191E48FC08; Wed, 19 Sep 2012 06:20:26 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q8J6KPMG038610; Wed, 19 Sep 2012 06:20:25 GMT (envelope-from bapt@svn.freebsd.org) Received: (from bapt@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q8J6KPVw038608; Wed, 19 Sep 2012 06:20:25 GMT (envelope-from bapt@svn.freebsd.org) Message-Id: <201209190620.q8J6KPVw038608@svn.freebsd.org> From: Baptiste Daroussin Date: Wed, 19 Sep 2012 06:20:25 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-8@freebsd.org X-SVN-Group: stable-8 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r240688 - stable/8/lib/libutil X-BeenThere: svn-src-stable@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for all the -stable branches of the src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 19 Sep 2012 06:20:26 -0000 Author: bapt Date: Wed Sep 19 06:20:25 2012 New Revision: 240688 URL: http://svn.freebsd.org/changeset/base/240688 Log: MFC: r240391 Fix IEC / SI binary prefixes (Ki, Mi, Gi, etc) production by humanize_number(3) PR: bin/171487 Submitted by: matthew Modified: stable/8/lib/libutil/humanize_number.c Directory Properties: stable/8/lib/libutil/ (props changed) Modified: stable/8/lib/libutil/humanize_number.c ============================================================================== --- stable/8/lib/libutil/humanize_number.c Wed Sep 19 06:18:42 2012 (r240687) +++ stable/8/lib/libutil/humanize_number.c Wed Sep 19 06:20:25 2012 (r240688) @@ -76,7 +76,7 @@ humanize_number(char *buf, size_t len, i if (flags & HN_B) prefixes = "B\0\0Ki\0Mi\0Gi\0Ti\0Pi\0Ei"; else - prefixes = "\0\0Ki\0Mi\0Gi\0Ti\0Pi\0Ei"; + prefixes = "\0\0\0Ki\0Mi\0Gi\0Ti\0Pi\0Ei"; } else { baselen = 1; if (flags & HN_DIVISOR_1000) From owner-svn-src-stable@FreeBSD.ORG Wed Sep 19 20:11:48 2012 Return-Path: Delivered-To: svn-src-stable@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 7B312106566C; Wed, 19 Sep 2012 20:11:48 +0000 (UTC) (envelope-from obrien@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 640F08FC12; Wed, 19 Sep 2012 20:11:48 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q8JKBmKp061531; Wed, 19 Sep 2012 20:11:48 GMT (envelope-from obrien@svn.freebsd.org) Received: (from obrien@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q8JKBmt7061527; Wed, 19 Sep 2012 20:11:48 GMT (envelope-from obrien@svn.freebsd.org) Message-Id: <201209192011.q8JKBmt7061527@svn.freebsd.org> From: "David E. O'Brien" Date: Wed, 19 Sep 2012 20:11:48 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-8@freebsd.org X-SVN-Group: stable-8 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r240707 - in stable/8: share/man/man4 sys/dev/filemon sys/modules sys/modules/filemon tools/regression/filemon X-BeenThere: svn-src-stable@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for all the -stable branches of the src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 19 Sep 2012 20:11:48 -0000 Author: obrien Date: Wed Sep 19 20:11:47 2012 New Revision: 240707 URL: http://svn.freebsd.org/changeset/base/240707 Log: MF9: r237795 MFC: r236592 r236593 r236594 r236620 r236621 r236622 r236637 r237794: filemon(4) Added: stable/8/share/man/man4/filemon.4 - copied unchanged from r237795, stable/9/share/man/man4/filemon.4 stable/8/sys/dev/filemon/ - copied from r237795, stable/9/sys/dev/filemon/ stable/8/sys/modules/filemon/ - copied from r237795, stable/9/sys/modules/filemon/ stable/8/tools/regression/filemon/ - copied from r237795, stable/9/tools/regression/filemon/ Modified: stable/8/share/man/man4/Makefile stable/8/sys/modules/Makefile Directory Properties: stable/8/ (props changed) stable/8/share/ (props changed) stable/8/share/man/ (props changed) stable/8/share/man/man4/ (props changed) stable/8/sys/ (props changed) stable/8/sys/dev/ (props changed) stable/8/sys/modules/ (props changed) stable/8/tools/ (props changed) Modified: stable/8/share/man/man4/Makefile ============================================================================== --- stable/8/share/man/man4/Makefile Wed Sep 19 19:59:15 2012 (r240706) +++ stable/8/share/man/man4/Makefile Wed Sep 19 20:11:47 2012 (r240707) @@ -118,6 +118,7 @@ MAN= aac.4 \ fatm.4 \ fd.4 \ fdc.4 \ + filemon.4 \ firewire.4 \ fpa.4 \ fwe.4 \ Copied: stable/8/share/man/man4/filemon.4 (from r237795, stable/9/share/man/man4/filemon.4) ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ stable/8/share/man/man4/filemon.4 Wed Sep 19 20:11:47 2012 (r240707, copy of r237795, stable/9/share/man/man4/filemon.4) @@ -0,0 +1,176 @@ +.\" Copyright (c) 2012 +.\" David E. O'Brien . All rights reserved. +.\" +.\" Redistribution and use in source and binary forms, with or without +.\" modification, are permitted provided that the following conditions +.\" are met: +.\" 1. Redistributions of source code must retain the above copyright +.\" notice, this list of conditions and the following disclaimer. +.\" 2. Redistributions in binary form must reproduce the above copyright +.\" notice, this list of conditions and the following disclaimer in the +.\" documentation and/or other materials provided with the distribution. +.\" 3. All advertising materials mentioning features or use of this software +.\" must display the following acknowledgement: +.\" This product includes software developed by David E. O'Brien and +.\" contributors. +.\" 4. Neither the name of the author nor the names of its contributors +.\" may be used to endorse or promote products derived from this software +.\" without specific prior written permission. +.\" +.\" THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND +.\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE +.\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE +.\" ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE +.\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL +.\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS +.\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) +.\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT +.\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY +.\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF +.\" SUCH DAMAGE. +.\" +.\" $FreeBSD$ +.\" +.Dd May 30, 2012 +.Dt FILEMON 4 +.Os +.Sh NAME +.Nm filemon +.Nd the filemon device +.Sh SYNOPSIS +.In dev/filemon/filemon.h +.Sh DESCRIPTION +The +.Nm +device allows a process to collect file operations data of its children. +The device +.Pa /dev/filemon +responds to two +.Xr ioctl 2 +calls. +.Pp +System calls are denoted using the following single letters: +.Pp +.Bl -tag -width indent -compact +.It Ql C +.Xr chdir 2 +.It Ql D +.Xr unlink 2 +.It Ql E +.Xr exec 2 +.It Ql F +.Xr fork 2 , +.Xr vfork 2 +.It Ql L +.Xr link 2 , +.Xr linkat 2 , +.Xr symlink 2 , +.Xr symlinkat 2 +.It Ql M +.Xr rename 2 +.It Ql R +.Xr open 2 +for read +.It Ql S +.Xr stat 2 +.It Ql W +.Xr open 2 +for write +.It Ql X +.Xr _exit 2 +.El +.Pp +Note that +.Ql R +following +.Ql W +records can represent a single +.Xr open 2 +for R/W, +or two seperate +.Xr open 2 +calls, one for +.Ql R +and one for +.Ql W . +.Sh IOCTLS +User mode programs communicate with the +.Nm +driver through a number of ioctls which are described below. +Each takes a single argument. +.Bl -tag -width ".Dv FILEMON_SET_PID" +.It Dv FILEMON_SET_FD +Write the internal tracing buffer to the supplied open file descriptor. +.It Dv FILEMON_SET_PID +Child process ID to trace. +.El +.Sh RETURN VALUES +.\" .Rv -std ioctl +The +.Fn ioctl +function returns the value 0 if successful; +otherwise the value \-1 is returned and the global variable +.Va errno +is set to indicate the error. +.Sh FILES +.Bl -tag -width ".Pa /dev/filemon" +.It Pa /dev/filemon +.El +.Sh EXAMPLES +.Bd -literal +#include +#include +#include +#include +#include +#include +#include + +static void +open_filemon(void) +{ + pid_t child; + int fm_fd, fm_log; + + if ((fm_fd = open("/dev/filemon", O_RDWR)) == -1) + err(1, "open(\e"/dev/filemon\e", O_RDWR)"); + if ((fm_log = open("filemon.out", + O_CREAT | O_WRONLY | O_TRUNC, DEFFILEMODE)) == -1) + err(1, "open(filemon.out)"); + + if (ioctl(fm_fd, FILEMON_SET_FD, &fm_log) == -1) + err(1, "Cannot set filemon log file descriptor"); + /* Set up these two fd's to close on exec. */ + (void)fcntl(fm_fd, F_SETFD, FD_CLOEXEC); + (void)fcntl(fm_log, F_SETFD, FD_CLOEXEC); + + if ((child = fork()) == 0) { + child = getpid(); + if (ioctl(fm_fd, FILEMON_SET_PID, &child) == -1) + err(1, "Cannot set filemon PID"); + /* Do something here. */ + return 0; + } else { + wait(&child); + close(fm_fd); + } + return 0; +} +.Ed +.Pp +Creates a file named +.Pa filemon.out +and configures the +.Nm +device to write the +.Nm +buffer contents to it. +.Sh SEE ALSO +.Xr dtrace 1 , +.Xr ktrace 1 , +.Xr truss 1 +.Sh HISTORY +A +.Nm +device appeared in +.Fx 9.1 . Modified: stable/8/sys/modules/Makefile ============================================================================== --- stable/8/sys/modules/Makefile Wed Sep 19 19:59:15 2012 (r240706) +++ stable/8/sys/modules/Makefile Wed Sep 19 20:11:47 2012 (r240707) @@ -2,7 +2,8 @@ .include -SUBDIR= ${_3dfx} \ +SUBDIR= \ + ${_3dfx} \ ${_3dfx_linux} \ ${_aac} \ accf_data \ @@ -96,6 +97,7 @@ SUBDIR= ${_3dfx} \ fdc \ fdescfs \ ${_fe} \ + ${_filemon} \ firewire \ firmware \ fxp \ @@ -336,6 +338,10 @@ SUBDIR= ${_3dfx} \ ${_zfs} \ zlib \ +.if ${MACHINE_ARCH} == "i386" || ${MACHINE_ARCH} == "amd64" +_filemon= filemon +.endif + .if ${MACHINE_ARCH} != "powerpc" && ${MACHINE_ARCH} != "arm" && \ ${MACHINE_ARCH} != "mips" _syscons= syscons From owner-svn-src-stable@FreeBSD.ORG Wed Sep 19 22:12:58 2012 Return-Path: Delivered-To: svn-src-stable@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 99023106564A; Wed, 19 Sep 2012 22:12:58 +0000 (UTC) (envelope-from delphij@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 805DD8FC16; Wed, 19 Sep 2012 22:12:58 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q8JMCwLn081422; Wed, 19 Sep 2012 22:12:58 GMT (envelope-from delphij@svn.freebsd.org) Received: (from delphij@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q8JMCwYi081417; Wed, 19 Sep 2012 22:12:58 GMT (envelope-from delphij@svn.freebsd.org) Message-Id: <201209192212.q8JMCwYi081417@svn.freebsd.org> From: Xin LI Date: Wed, 19 Sep 2012 22:12:58 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r240712 - in stable/9: share/man/man4 sys/dev/arcmsr X-BeenThere: svn-src-stable@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for all the -stable branches of the src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 19 Sep 2012 22:12:58 -0000 Author: delphij Date: Wed Sep 19 22:12:57 2012 New Revision: 240712 URL: http://svn.freebsd.org/changeset/base/240712 Log: MFC r240079: Update arcmsr(4) to vendor version 1.20.00.25. Many thanks to Areca for continuing to support FreeBSD. Submitted by: Ching-Lung Huang Modified: stable/9/share/man/man4/arcmsr.4 stable/9/sys/dev/arcmsr/arcmsr.c stable/9/sys/dev/arcmsr/arcmsr.h Directory Properties: stable/9/share/man/man4/ (props changed) stable/9/sys/ (props changed) stable/9/sys/dev/ (props changed) Modified: stable/9/share/man/man4/arcmsr.4 ============================================================================== --- stable/9/share/man/man4/arcmsr.4 Wed Sep 19 21:50:18 2012 (r240711) +++ stable/9/share/man/man4/arcmsr.4 Wed Sep 19 22:12:57 2012 (r240712) @@ -24,7 +24,7 @@ .\" .\" $FreeBSD$ .\" -.Dd November 25, 2010 +.Dd September 3, 2012 .Dt ARCMSR 4 .Os .Sh NAME @@ -98,10 +98,14 @@ ARC-1210 .It ARC-1212 .It +ARC-1213 +.It ARC-1220 .It ARC-1222 .It +ARC-1223 +.It ARC-1230 .It ARC-1231 @@ -133,6 +137,8 @@ ARC-1680 ARC-1681 .It ARC-1880 +.It +ARC-1882 .El .Sh FILES .Bl -tag -width ".Pa /dev/arcmsr?" -compact Modified: stable/9/sys/dev/arcmsr/arcmsr.c ============================================================================== --- stable/9/sys/dev/arcmsr/arcmsr.c Wed Sep 19 21:50:18 2012 (r240711) +++ stable/9/sys/dev/arcmsr/arcmsr.c Wed Sep 19 22:12:57 2012 (r240712) @@ -37,38 +37,43 @@ ************************************************************************** ** History ** -** REV# DATE NAME DESCRIPTION -** 1.00.00.00 03/31/2004 Erich Chen First release -** 1.20.00.02 11/29/2004 Erich Chen bug fix with arcmsr_bus_reset when PHY error -** 1.20.00.03 04/19/2005 Erich Chen add SATA 24 Ports adapter type support +** REV# DATE NAME DESCRIPTION +** 1.00.00.00 03/31/2004 Erich Chen First release +** 1.20.00.02 11/29/2004 Erich Chen bug fix with arcmsr_bus_reset when PHY error +** 1.20.00.03 04/19/2005 Erich Chen add SATA 24 Ports adapter type support ** clean unused function -** 1.20.00.12 09/12/2005 Erich Chen bug fix with abort command handling, +** 1.20.00.12 09/12/2005 Erich Chen bug fix with abort command handling, ** firmware version check ** and firmware update notify for hardware bug fix ** handling if none zero high part physical address ** of srb resource -** 1.20.00.13 08/18/2006 Erich Chen remove pending srb and report busy +** 1.20.00.13 08/18/2006 Erich Chen remove pending srb and report busy ** add iop message xfer ** with scsi pass-through command ** add new device id of sas raid adapters ** code fit for SPARC64 & PPC -** 1.20.00.14 02/05/2007 Erich Chen bug fix for incorrect ccb_h.status report +** 1.20.00.14 02/05/2007 Erich Chen bug fix for incorrect ccb_h.status report ** and cause g_vfs_done() read write error -** 1.20.00.15 10/10/2007 Erich Chen support new RAID adapter type ARC120x -** 1.20.00.16 10/10/2009 Erich Chen Bug fix for RAID adapter type ARC120x +** 1.20.00.15 10/10/2007 Erich Chen support new RAID adapter type ARC120x +** 1.20.00.16 10/10/2009 Erich Chen Bug fix for RAID adapter type ARC120x ** bus_dmamem_alloc() with BUS_DMA_ZERO -** 1.20.00.17 07/15/2010 Ching Huang Added support ARC1880 -** report CAM_DEV_NOT_THERE instead of CAM_SEL_TIMEOUT when device failed, -** prevent cam_periph_error removing all LUN devices of one Target id -** for any one LUN device failed -** 1.20.00.18 10/14/2010 Ching Huang Fixed "inquiry data fails comparion at DV1 step" -** 10/25/2010 Ching Huang Fixed bad range input in bus_alloc_resource for ADAPTER_TYPE_B -** 1.20.00.19 11/11/2010 Ching Huang Fixed arcmsr driver prevent arcsas support for Areca SAS HBA ARC13x0 -** 1.20.00.20 12/08/2010 Ching Huang Avoid calling atomic_set_int function -** 1.20.00.21 02/08/2011 Ching Huang Implement I/O request timeout -** 02/14/2011 Ching Huang Modified pktRequestCount -** 1.20.00.21 03/03/2011 Ching Huang if a command timeout, then wait its ccb back before free it -** 1.20.00.22 07/04/2011 Ching Huang Fixed multiple MTX panic +** 1.20.00.17 07/15/2010 Ching Huang Added support ARC1880 +** report CAM_DEV_NOT_THERE instead of CAM_SEL_TIMEOUT when device failed, +** prevent cam_periph_error removing all LUN devices of one Target id +** for any one LUN device failed +** 1.20.00.18 10/14/2010 Ching Huang Fixed "inquiry data fails comparion at DV1 step" +** 10/25/2010 Ching Huang Fixed bad range input in bus_alloc_resource for ADAPTER_TYPE_B +** 1.20.00.19 11/11/2010 Ching Huang Fixed arcmsr driver prevent arcsas support for Areca SAS HBA ARC13x0 +** 1.20.00.20 12/08/2010 Ching Huang Avoid calling atomic_set_int function +** 1.20.00.21 02/08/2011 Ching Huang Implement I/O request timeout +** 02/14/2011 Ching Huang Modified pktRequestCount +** 1.20.00.21 03/03/2011 Ching Huang if a command timeout, then wait its ccb back before free it +** 1.20.00.22 07/04/2011 Ching Huang Fixed multiple MTX panic +** 1.20.00.23 10/28/2011 Ching Huang Added TIMEOUT_DELAY in case of too many HDDs need to start +** 1.20.00.23 11/08/2011 Ching Huang Added report device transfer speed +** 1.20.00.23 01/30/2012 Ching Huang Fixed Request requeued and Retrying command +** 1.20.00.24 06/11/2012 Ching Huang Fixed return sense data condition +** 1.20.00.25 08/17/2012 Ching Huang Fixed hotplug device no function on type A adapter ****************************************************************************************** */ @@ -154,7 +159,7 @@ __FBSDID("$FreeBSD$"); #define arcmsr_callout_init(a) callout_init(a); #endif -#define ARCMSR_DRIVER_VERSION "Driver Version 1.20.00.22 2011-07-04" +#define ARCMSR_DRIVER_VERSION "Driver Version 1.20.00.25 2012-08-17" #include #define SRB_SIZE ((sizeof(struct CommandControlBlock)+0x1f) & 0xffe0) #define ARCMSR_SRBS_POOL_SIZE (SRB_SIZE * ARCMSR_MAX_FREESRB_NUM) @@ -296,7 +301,7 @@ static struct cdevsw arcmsr_cdevsw = { if(acb==NULL) { return ENXIO; } - return 0; + return (0); } /* ************************************************************************** @@ -347,7 +352,7 @@ static struct cdevsw arcmsr_cdevsw = { if(acb==NULL) { return ENXIO; } - return(arcmsr_iop_ioctlcmd(acb, ioctl_cmd, arg)); + return (arcmsr_iop_ioctlcmd(acb, ioctl_cmd, arg)); } /* ********************************************************************** @@ -378,7 +383,7 @@ static u_int32_t arcmsr_disable_allintr( } break; } - return(intmask_org); + return (intmask_org); } /* ********************************************************************** @@ -411,7 +416,6 @@ static void arcmsr_enable_allintr( struc } break; } - return; } /* ********************************************************************** @@ -431,7 +435,7 @@ static u_int8_t arcmsr_hba_wait_msgint_r UDELAY(10000); }/*max 1 seconds*/ }while(Retries++ < 20);/*max 20 sec*/ - return FALSE; + return (FALSE); } /* ********************************************************************** @@ -452,7 +456,7 @@ static u_int8_t arcmsr_hbb_wait_msgint_r UDELAY(10000); }/*max 1 seconds*/ }while(Retries++ < 20);/*max 20 sec*/ - return FALSE; + return (FALSE); } /* ********************************************************************** @@ -472,7 +476,7 @@ static u_int8_t arcmsr_hbc_wait_msgint_r UDELAY(10000); }/*max 1 seconds*/ }while(Retries++ < 20);/*max 20 sec*/ - return FALSE; + return (FALSE); } /* ************************************************************************ @@ -490,7 +494,6 @@ static void arcmsr_flush_hba_cache(struc retry_count--; } }while(retry_count!=0); - return; } /* ************************************************************************ @@ -509,7 +512,6 @@ static void arcmsr_flush_hbb_cache(struc retry_count--; } }while(retry_count!=0); - return; } /* ************************************************************************ @@ -528,7 +530,6 @@ static void arcmsr_flush_hbc_cache(struc retry_count--; } }while(retry_count!=0); - return; } /* ************************************************************************ @@ -550,7 +551,6 @@ static void arcmsr_flush_adapter_cache(s } break; } - return; } /* ******************************************************************************* @@ -596,7 +596,7 @@ static void arcmsr_async(void *cb_arg, u if((target_id > ARCMSR_MAX_TARGETID) || (target_lun > ARCMSR_MAX_TARGETLUN)) { break; } - printf("%s:scsi id=%d lun=%d device lost \n", device_get_name(acb->pci_dev), target_id, target_lun); + // printf("%s:scsi id=%d lun=%d device lost \n", device_get_name(acb->pci_dev), target_id, target_lun); break; default: break; @@ -612,14 +612,13 @@ static void arcmsr_report_sense_info(str pccb->ccb_h.status |= CAM_SCSI_STATUS_ERROR; pccb->csio.scsi_status = SCSI_STATUS_CHECK_COND; - if(&pccb->csio.sense_data) { + if(pccb->csio.sense_len) { memset(&pccb->csio.sense_data, 0, sizeof(pccb->csio.sense_data)); memcpy(&pccb->csio.sense_data, srb->arcmsr_cdb.SenseData, get_min(sizeof(struct SENSE_DATA), sizeof(pccb->csio.sense_data))); ((u_int8_t *)&pccb->csio.sense_data)[0] = (0x1 << 7 | 0x70); /* Valid,ErrorCode */ pccb->ccb_h.status |= CAM_AUTOSNS_VALID; } - return; } /* ********************************************************************* @@ -631,7 +630,6 @@ static void arcmsr_abort_hba_allcmd(stru if(!arcmsr_hba_wait_msgint_ready(acb)) { printf("arcmsr%d: wait 'abort all outstanding command' timeout \n", acb->pci_unit); } - return; } /* ********************************************************************* @@ -643,7 +641,6 @@ static void arcmsr_abort_hbb_allcmd(stru if(!arcmsr_hbb_wait_msgint_ready(acb)) { printf("arcmsr%d: wait 'abort all outstanding command' timeout \n", acb->pci_unit); } - return; } /* ********************************************************************* @@ -656,7 +653,6 @@ static void arcmsr_abort_hbc_allcmd(stru if(!arcmsr_hbc_wait_msgint_ready(acb)) { printf("arcmsr%d: wait 'abort all outstanding command' timeout \n", acb->pci_unit); } - return; } /* ********************************************************************* @@ -678,7 +674,6 @@ static void arcmsr_abort_allcmd(struct A } break; } - return; } /* ********************************************************************** @@ -716,7 +711,6 @@ static void arcmsr_srb_complete(struct C acb->pktReturnCount++; #endif xpt_done(pccb); - return; } /* ************************************************************************** @@ -768,7 +762,6 @@ static void arcmsr_report_srb_state(stru break; } } - return; } /* ************************************************************************** @@ -801,7 +794,6 @@ static void arcmsr_drain_donequeue(struc return; } arcmsr_report_srb_state(acb, srb, error); - return; } /* ************************************************************************** @@ -883,7 +875,6 @@ static void arcmsr_done4abort_postqueue( } break; } - return; } /* **************************************************************************** @@ -923,7 +914,6 @@ static void arcmsr_iop_reset(struct Adap acb->pktRequestCount = 0; acb->pktReturnCount = 0; #endif - return; } /* ********************************************************************** @@ -1011,7 +1001,6 @@ static void arcmsr_build_srb(struct Comm arcmsr_cdb->DataLength = 0; } srb->arc_cdb_size=arccdbsize; - return; } /* ************************************************************************** @@ -1072,7 +1061,6 @@ static void arcmsr_post_srb(struct Adapt } break; } - return; } /* ************************************************************************ @@ -1156,7 +1144,6 @@ static void arcmsr_iop_message_read(stru CHIP_REG_WRITE32(HBC_MessageUnit, 0, inbound_doorbell, ARCMSR_HBCMU_DRV2IOP_DATA_READ_OK); } } - return; } /* ************************************************************************** @@ -1221,7 +1208,6 @@ static void arcmsr_post_ioctldata2iop(st */ arcmsr_iop_message_wrote(acb); } - return; } /* ************************************************************************ @@ -1236,7 +1222,6 @@ static void arcmsr_stop_hba_bgrb(struct printf("arcmsr%d: wait 'stop adapter background rebulid' timeout \n" , acb->pci_unit); } - return; } /* ************************************************************************ @@ -1251,7 +1236,6 @@ static void arcmsr_stop_hbb_bgrb(struct printf( "arcmsr%d: wait 'stop adapter background rebulid' timeout \n" , acb->pci_unit); } - return; } /* ************************************************************************ @@ -1265,7 +1249,6 @@ static void arcmsr_stop_hbc_bgrb(struct if(!arcmsr_hbc_wait_msgint_ready(acb)) { printf("arcmsr%d: wait 'stop adapter background rebulid' timeout \n", acb->pci_unit); } - return; } /* ************************************************************************ @@ -1287,7 +1270,6 @@ static void arcmsr_stop_adapter_bgrb(str } break; } - return; } /* ************************************************************************ @@ -1305,7 +1287,6 @@ static void arcmsr_poll(struct cam_sim * arcmsr_interrupt(acb); if( mutex == 0 ) ARCMSR_LOCK_RELEASE(&acb->qbuffer_lock); - return; } /* ************************************************************************** @@ -1340,7 +1321,6 @@ static void arcmsr_iop2drv_data_wrote_ha } else { acb->acb_flags|=ACB_F_IOPDATA_OVERFLOW; } - return; } /* ************************************************************************** @@ -1383,7 +1363,6 @@ static void arcmsr_iop2drv_data_read_han if(acb->wqbuf_firstindex==acb->wqbuf_lastindex) { acb->acb_flags |= ACB_F_MESSAGE_WQBUFFER_CLEARED; } - return; } static void arcmsr_rescanLun_cb(struct cam_periph *periph, union ccb *ccb) @@ -1417,7 +1396,6 @@ static void arcmsr_rescan_lun(struct Ada ccb->ccb_h.cbfcnp = arcmsr_rescanLun_cb; ccb->crcn.flags = CAM_FLAG_NONE; xpt_action(ccb); - return; } @@ -1488,6 +1466,7 @@ static void arcmsr_dr_handle(struct Adap } break; } + if(acb->acb_flags & ACB_F_BUS_HANG_ON) { acb->acb_flags &= ~ACB_F_BUS_HANG_ON; @@ -1592,7 +1571,6 @@ static void arcmsr_hba_doorbell_isr(stru if(outbound_doorbell & ARCMSR_OUTBOUND_IOP331_DATA_READ_OK) { arcmsr_iop2drv_data_read_handle(acb); } - return; } /* ************************************************************************** @@ -1620,7 +1598,6 @@ static void arcmsr_hbc_doorbell_isr(stru if(outbound_doorbell & ARCMSR_HBCMU_IOP2DRV_MESSAGE_CMD_DONE) { arcmsr_hbc_message_isr(acb); /* messenger of "driver to iop commands" */ } - return; } /* ************************************************************************** @@ -1644,7 +1621,6 @@ static void arcmsr_hba_postqueue_isr(str error=(flag_srb & ARCMSR_SRBREPLY_FLAG_ERROR_MODE0)?TRUE:FALSE; arcmsr_drain_donequeue(acb, flag_srb, error); } /*drain reply FIFO*/ - return; } /* ************************************************************************** @@ -1674,7 +1650,6 @@ static void arcmsr_hbb_postqueue_isr(str error=(flag_srb & ARCMSR_SRBREPLY_FLAG_ERROR_MODE0)?TRUE:FALSE; arcmsr_drain_donequeue(acb, flag_srb, error); } /*drain reply FIFO*/ - return; } /* ************************************************************************** @@ -1704,7 +1679,6 @@ static void arcmsr_hbc_postqueue_isr(str } throttling++; } /*drain reply FIFO*/ - return; } /* ********************************************************************** @@ -1712,30 +1686,29 @@ static void arcmsr_hbc_postqueue_isr(str */ static void arcmsr_handle_hba_isr( struct AdapterControlBlock *acb) { - u_int32_t outbound_intstatus; + u_int32_t outbound_intStatus; /* ********************************************* ** check outbound intstatus ********************************************* */ - outbound_intstatus=CHIP_REG_READ32(HBA_MessageUnit, 0, outbound_intstatus) & acb->outbound_int_enable; - if(!outbound_intstatus) { + outbound_intStatus=CHIP_REG_READ32(HBA_MessageUnit, 0, outbound_intstatus) & acb->outbound_int_enable; + if(!outbound_intStatus) { /*it must be share irq*/ return; } - CHIP_REG_WRITE32(HBA_MessageUnit, 0, outbound_intstatus, outbound_intstatus);/*clear interrupt*/ + CHIP_REG_WRITE32(HBA_MessageUnit, 0, outbound_intstatus, outbound_intStatus);/*clear interrupt*/ /* MU doorbell interrupts*/ - if(outbound_intstatus & ARCMSR_MU_OUTBOUND_DOORBELL_INT) { + if(outbound_intStatus & ARCMSR_MU_OUTBOUND_DOORBELL_INT) { arcmsr_hba_doorbell_isr(acb); } /* MU post queue interrupts*/ - if(outbound_intstatus & ARCMSR_MU_OUTBOUND_POSTQUEUE_INT) { + if(outbound_intStatus & ARCMSR_MU_OUTBOUND_POSTQUEUE_INT) { arcmsr_hba_postqueue_isr(acb); } - if(outbound_intstatus & ARCMSR_MU_OUTBOUND_MESSAGE0_INT) { + if(outbound_intStatus & ARCMSR_MU_OUTBOUND_MESSAGE0_INT) { arcmsr_hba_message_isr(acb); } - return; } /* ********************************************************************** @@ -1771,7 +1744,6 @@ static void arcmsr_handle_hbb_isr( struc if(outbound_doorbell & ARCMSR_IOP2DRV_MESSAGE_CMD_DONE) { arcmsr_hbb_message_isr(acb); } - return; } /* ********************************************************************** @@ -1798,7 +1770,6 @@ static void arcmsr_handle_hbc_isr( struc if(host_interrupt_status & ARCMSR_HBCMU_OUTBOUND_POSTQUEUE_ISR) { arcmsr_hbc_postqueue_isr(acb); } - return; } /* ****************************************************************************** @@ -1821,7 +1792,6 @@ static void arcmsr_interrupt(struct Adap " unknow adapter type =%d\n", acb->pci_unit, acb->adapter_type); break; } - return; } /* ********************************************************************** @@ -1844,7 +1814,7 @@ static void arcmsr_polling_devmap(void* struct AdapterControlBlock *acb = (struct AdapterControlBlock *)arg; switch (acb->adapter_type) { case ACB_ADAPTER_TYPE_A: - CHIP_REG_WRITE32(HBC_MessageUnit, 0, inbound_msgaddr0, ARCMSR_INBOUND_MESG0_GET_CONFIG); + CHIP_REG_WRITE32(HBA_MessageUnit, 0, inbound_msgaddr0, ARCMSR_INBOUND_MESG0_GET_CONFIG); break; case ACB_ADAPTER_TYPE_B: @@ -2065,7 +2035,7 @@ u_int32_t arcmsr_iop_ioctlcmd(struct Ada break; } ARCMSR_LOCK_RELEASE(&acb->qbuffer_lock); - return retvalue; + return (retvalue); } /* ************************************************************************** @@ -2191,7 +2161,7 @@ static int arcmsr_iop_message_xfer(struc if (wqbuf_lastindex != wqbuf_firstindex) { arcmsr_post_ioctldata2iop(acb); /* has error report sensedata */ - if(&pccb->csio.sense_data) { + if(pccb->csio.sense_len) { ((u_int8_t *)&pccb->csio.sense_data)[0] = (0x1 << 7 | 0x70); /* Valid,ErrorCode */ ((u_int8_t *)&pccb->csio.sense_data)[2] = 0x05; @@ -2221,7 +2191,7 @@ static int arcmsr_iop_message_xfer(struc } } else { /* has error report sensedata */ - if(&pccb->csio.sense_data) { + if(pccb->csio.sense_len) { ((u_int8_t *)&pccb->csio.sense_data)[0] = (0x1 << 7 | 0x70); /* Valid,ErrorCode */ ((u_int8_t *)&pccb->csio.sense_data)[2] = 0x05; @@ -2312,7 +2282,7 @@ static int arcmsr_iop_message_xfer(struc retvalue = ARCMSR_MESSAGE_FAIL; } message_out: - return retvalue; + return (retvalue); } /* ********************************************************************* @@ -2375,7 +2345,7 @@ static void arcmsr_execute_srb(void *arg arcmsr_srb_complete(srb, 0); return; } - if(acb->srboutstandingcount >= ARCMSR_MAX_OUTSTANDING_CMD) { + if(acb->srboutstandingcount > ARCMSR_MAX_OUTSTANDING_CMD) { xpt_freeze_simq(acb->psim, 1); pccb->ccb_h.status = CAM_REQUEUE_REQ; acb->acb_flags |= ACB_F_CAM_DEV_QFRZN; @@ -2388,10 +2358,9 @@ static void arcmsr_execute_srb(void *arg if (pccb->ccb_h.timeout != CAM_TIME_INFINITY) { arcmsr_callout_init(&srb->ccb_callout); - callout_reset(&srb->ccb_callout, (pccb->ccb_h.timeout * hz ) / 1000, arcmsr_srb_timeout, srb); + callout_reset(&srb->ccb_callout, ((pccb->ccb_h.timeout + (ARCMSR_TIMEOUT_DELAY * 1000)) * hz) / 1000, arcmsr_srb_timeout, srb); srb->srb_flags |= SRB_FLAG_TIMER_START; } - return; } /* ***************************************************************************************** @@ -2455,7 +2424,6 @@ static void arcmsr_bus_reset(struct Adap } arcmsr_iop_reset(acb); acb->acb_flags &= ~ACB_F_BUS_RESET; - return; } /* ************************************************************************** @@ -2607,10 +2575,24 @@ static void arcmsr_action(struct cam_sim strncpy(cpi->dev_name, cam_sim_name(psim), DEV_IDLEN); cpi->unit_number=cam_sim_unit(psim); #ifdef CAM_NEW_TRAN_CODE - cpi->transport = XPORT_SPI; - cpi->transport_version = 2; + if(acb->adapter_bus_speed == ACB_BUS_SPEED_6G) + cpi->base_transfer_speed = 600000; + else + cpi->base_transfer_speed = 300000; + if((acb->vendor_device_id == PCIDevVenIDARC1880) || + (acb->vendor_device_id == PCIDevVenIDARC1680)) + { + cpi->transport = XPORT_SAS; + cpi->transport_version = 0; + cpi->protocol_version = SCSI_REV_SPC2; + } + else + { + cpi->transport = XPORT_SPI; + cpi->transport_version = 2; + cpi->protocol_version = SCSI_REV_2; + } cpi->protocol = PROTO_SCSI; - cpi->protocol_version = SCSI_REV_2; #endif cpi->ccb_h.status |= CAM_REQ_CMP; xpt_done(pccb); @@ -2674,28 +2656,46 @@ static void arcmsr_action(struct cam_sim { struct ccb_trans_settings_scsi *scsi; struct ccb_trans_settings_spi *spi; + struct ccb_trans_settings_sas *sas; scsi = &cts->proto_specific.scsi; - spi = &cts->xport_specific.spi; - cts->protocol = PROTO_SCSI; - cts->protocol_version = SCSI_REV_2; - cts->transport = XPORT_SPI; - cts->transport_version = 2; - spi->flags = CTS_SPI_FLAGS_DISC_ENB; - spi->sync_period=3; - spi->sync_offset=32; - spi->bus_width=MSG_EXT_WDTR_BUS_16_BIT; scsi->flags = CTS_SCSI_FLAGS_TAG_ENB; - spi->valid = CTS_SPI_VALID_DISC - | CTS_SPI_VALID_SYNC_RATE - | CTS_SPI_VALID_SYNC_OFFSET - | CTS_SPI_VALID_BUS_WIDTH; scsi->valid = CTS_SCSI_VALID_TQ; + cts->protocol = PROTO_SCSI; + + if((acb->vendor_device_id == PCIDevVenIDARC1880) || + (acb->vendor_device_id == PCIDevVenIDARC1680)) + { + cts->protocol_version = SCSI_REV_SPC2; + cts->transport_version = 0; + cts->transport = XPORT_SAS; + sas = &cts->xport_specific.sas; + sas->valid = CTS_SAS_VALID_SPEED; + if(acb->vendor_device_id == PCIDevVenIDARC1880) + sas->bitrate = 600000; + else if(acb->vendor_device_id == PCIDevVenIDARC1680) + sas->bitrate = 300000; + } + else + { + cts->protocol_version = SCSI_REV_2; + cts->transport_version = 2; + cts->transport = XPORT_SPI; + spi = &cts->xport_specific.spi; + spi->flags = CTS_SPI_FLAGS_DISC_ENB; + spi->sync_period=2; + spi->sync_offset=32; + spi->bus_width=MSG_EXT_WDTR_BUS_16_BIT; + spi->valid = CTS_SPI_VALID_DISC + | CTS_SPI_VALID_SYNC_RATE + | CTS_SPI_VALID_SYNC_OFFSET + | CTS_SPI_VALID_BUS_WIDTH; + } } #else { cts->flags=(CCB_TRANS_DISC_ENB | CCB_TRANS_TAG_ENB); - cts->sync_period=3; + cts->sync_period=2; cts->sync_offset=32; cts->bus_width=MSG_EXT_WDTR_BUS_16_BIT; cts->valid=CCB_TRANS_SYNC_RATE_VALID | @@ -2759,7 +2759,6 @@ static void arcmsr_action(struct cam_sim xpt_done(pccb); break; } - return; } /* ********************************************************************** @@ -2772,7 +2771,6 @@ static void arcmsr_start_hba_bgrb(struct if(!arcmsr_hba_wait_msgint_ready(acb)) { printf("arcmsr%d: wait 'start adapter background rebulid' timeout \n", acb->pci_unit); } - return; } /* ********************************************************************** @@ -2785,7 +2783,6 @@ static void arcmsr_start_hbb_bgrb(struct if(!arcmsr_hbb_wait_msgint_ready(acb)) { printf( "arcmsr%d: wait 'start adapter background rebulid' timeout \n", acb->pci_unit); } - return; } /* ********************************************************************** @@ -2799,7 +2796,6 @@ static void arcmsr_start_hbc_bgrb(struct if(!arcmsr_hbc_wait_msgint_ready(acb)) { printf("arcmsr%d: wait 'start adapter background rebulid' timeout \n", acb->pci_unit); } - return; } /* ********************************************************************** @@ -2818,7 +2814,6 @@ static void arcmsr_start_adapter_bgrb(st arcmsr_start_hbc_bgrb(acb); break; } - return; } /* ********************************************************************** @@ -2873,7 +2868,6 @@ polling_ccb_retry: } arcmsr_report_srb_state(acb, srb, error); } /*drain reply FIFO*/ - return; } /* ********************************************************************** @@ -2934,7 +2928,6 @@ polling_ccb_retry: } arcmsr_report_srb_state(acb, srb, error); } /*drain reply FIFO*/ - return; } /* ********************************************************************** @@ -2985,7 +2978,6 @@ polling_ccb_retry: } arcmsr_report_srb_state(acb, srb, error); } /*drain reply FIFO*/ - return; } /* ********************************************************************** @@ -3053,7 +3045,6 @@ static void arcmsr_get_hba_config(struct acb->firm_sdram_size=CHIP_REG_READ32(HBA_MessageUnit, 0, msgcode_rwbuffer[3]); /*firm_sdram_size, 3, 12-15*/ acb->firm_ide_channels=CHIP_REG_READ32(HBA_MessageUnit, 0, msgcode_rwbuffer[4]); /*firm_ide_channels, 4, 16-19*/ acb->firm_cfg_version=CHIP_REG_READ32(HBA_MessageUnit, 0, msgcode_rwbuffer[ARCMSR_FW_CFGVER_OFFSET]); /*firm_cfg_version, 25, */ - return; } /* ********************************************************************** @@ -3100,7 +3091,6 @@ static void arcmsr_get_hbb_config(struct acb->firm_sdram_size=CHIP_REG_READ32(HBB_RWBUFFER, 1, msgcode_rwbuffer[3]); /*firm_sdram_size, 3, 12-15*/ acb->firm_ide_channels=CHIP_REG_READ32(HBB_RWBUFFER, 1, msgcode_rwbuffer[4]); /*firm_ide_channels, 4, 16-19*/ acb->firm_cfg_version=CHIP_REG_READ32(HBB_RWBUFFER, 1, msgcode_rwbuffer[ARCMSR_FW_CFGVER_OFFSET]); /*firm_cfg_version, 25, */ - return; } /* ********************************************************************** @@ -3148,7 +3138,6 @@ static void arcmsr_get_hbc_config(struct acb->firm_sdram_size =CHIP_REG_READ32(HBC_MessageUnit, 0, msgcode_rwbuffer[3]); /*firm_sdram_size, 3, 12-15*/ acb->firm_ide_channels =CHIP_REG_READ32(HBC_MessageUnit, 0, msgcode_rwbuffer[4]); /*firm_ide_channels, 4, 16-19*/ acb->firm_cfg_version =CHIP_REG_READ32(HBC_MessageUnit, 0, msgcode_rwbuffer[ARCMSR_FW_CFGVER_OFFSET]); /*firm_cfg_version, 25, */ - return; } /* ********************************************************************** @@ -3170,7 +3159,6 @@ static void arcmsr_get_firmware_spec(str } break; } - return; } /* ********************************************************************** @@ -3219,7 +3207,6 @@ static void arcmsr_wait_firmware_ready( } break; } - return; } /* ********************************************************************** @@ -3253,7 +3240,6 @@ static void arcmsr_clear_doorbell_queue_ } break; } - return; } /* ************************************************************************ @@ -3336,7 +3322,7 @@ static u_int32_t arcmsr_iop_confirm(stru } break; } - return TRUE; + return (TRUE); } /* ************************************************************************ @@ -3359,7 +3345,6 @@ static void arcmsr_enable_eoi_mode(struc } break; } - return; } /* ********************************************************************** @@ -3382,7 +3367,6 @@ static void arcmsr_iop_init(struct Adapt /* enable outbound Post Queue, outbound doorbell Interrupt */ arcmsr_enable_allintr(acb, intmask_org); acb->acb_flags |=ACB_F_IOP_INITED; - return; } /* ********************************************************************** @@ -3414,7 +3398,6 @@ static void arcmsr_map_free_srb(void *ar srb_tmp = (struct CommandControlBlock *)((unsigned long)srb_tmp+SRB_SIZE); } acb->vir2phy_offset=(unsigned long)srb_tmp-(unsigned long)srb_phyaddr; - return; } /* ************************************************************************ @@ -3433,7 +3416,6 @@ static void arcmsr_free_resource(struct bus_dma_tag_destroy(acb->srb_dmat); bus_dma_tag_destroy(acb->dm_segs_dmat); bus_dma_tag_destroy(acb->parent_dmat); - return; } /* ************************************************************************ @@ -3444,16 +3426,24 @@ static u_int32_t arcmsr_initialize(devic struct AdapterControlBlock *acb=device_get_softc(dev); u_int16_t pci_command; int i, j,max_coherent_size; - - switch (pci_get_devid(dev)) { - case PCIDevVenIDARC1880: { + u_int32_t vendor_dev_id; + + vendor_dev_id = pci_get_devid(dev); + acb->vendor_device_id = vendor_dev_id; + switch (vendor_dev_id) { + case PCIDevVenIDARC1880: + case PCIDevVenIDARC1882: + case PCIDevVenIDARC1213: + case PCIDevVenIDARC1223: { acb->adapter_type=ACB_ADAPTER_TYPE_C; + acb->adapter_bus_speed = ACB_BUS_SPEED_6G; max_coherent_size=ARCMSR_SRBS_POOL_SIZE; } break; case PCIDevVenIDARC1200: case PCIDevVenIDARC1201: { acb->adapter_type=ACB_ADAPTER_TYPE_B; + acb->adapter_bus_speed = ACB_BUS_SPEED_3G; max_coherent_size=ARCMSR_SRBS_POOL_SIZE+(sizeof(struct HBB_MessageUnit)); } break; @@ -3477,6 +3467,7 @@ static u_int32_t arcmsr_initialize(devic case PCIDevVenIDARC1680: case PCIDevVenIDARC1681: { acb->adapter_type=ACB_ADAPTER_TYPE_A; + acb->adapter_bus_speed = ACB_BUS_SPEED_3G; max_coherent_size=ARCMSR_SRBS_POOL_SIZE; } break; @@ -3804,7 +3795,7 @@ static int arcmsr_attach(device_t dev) #endif arcmsr_callout_init(&acb->devmap_callout); callout_reset(&acb->devmap_callout, 60 * hz, arcmsr_polling_devmap, acb); - return 0; + return (0); } /* @@ -3851,6 +3842,9 @@ static int arcmsr_probe(device_t dev) type = "SAS 3G"; break; case PCIDevVenIDARC1880: + case PCIDevVenIDARC1882: + case PCIDevVenIDARC1213: + case PCIDevVenIDARC1223: type = "SAS 6G"; break; default: Modified: stable/9/sys/dev/arcmsr/arcmsr.h ============================================================================== --- stable/9/sys/dev/arcmsr/arcmsr.h Wed Sep 19 21:50:18 2012 (r240711) +++ stable/9/sys/dev/arcmsr/arcmsr.h Wed Sep 19 22:12:57 2012 (r240712) @@ -52,6 +52,7 @@ #define ARCMSR_MAX_ADAPTER 4 #define ARCMSR_RELEASE_SIMQ_LEVEL 230 #define ARCMSR_MAX_HBB_POSTQUEUE 264 /* (ARCMSR_MAX_OUTSTANDING_CMD+8) */ +#define ARCMSR_TIMEOUT_DELAY 60 /* in sec */ /* ********************************************************************* */ @@ -97,6 +98,13 @@ #define PCI_DEVICE_ID_ARECA_1681 0x1681 /* Device ID */ #define PCI_DEVICE_ID_ARECA_1880 0x1880 /* Device ID */ +#define ARECA_SUB_DEV_ID_1880 0x1880 /* Subsystem Device ID */ +#define ARECA_SUB_DEV_ID_1882 0x1882 /* Subsystem Device ID */ +#define ARECA_SUB_DEV_ID_1212 0x1212 /* Subsystem Device ID */ +#define ARECA_SUB_DEV_ID_1213 0x1213 /* Subsystem Device ID */ +#define ARECA_SUB_DEV_ID_1222 0x1222 /* Subsystem Device ID */ +#define ARECA_SUB_DEV_ID_1223 0x1223 /* Subsystem Device ID */ + #define PCIDevVenIDARC1110 0x111017D3 /* Vendor Device ID */ #define PCIDevVenIDARC1120 0x112017D3 /* Vendor Device ID */ #define PCIDevVenIDARC1130 0x113017D3 /* Vendor Device ID */ @@ -106,8 +114,10 @@ #define PCIDevVenIDARC1201 0x120117D3 /* Vendor Device ID */ #define PCIDevVenIDARC1210 0x121017D3 /* Vendor Device ID */ #define PCIDevVenIDARC1212 0x121217D3 /* Vendor Device ID */ +#define PCIDevVenIDARC1213 0x121317D3 /* Vendor Device ID */ #define PCIDevVenIDARC1220 0x122017D3 /* Vendor Device ID */ #define PCIDevVenIDARC1222 0x122217D3 /* Vendor Device ID */ +#define PCIDevVenIDARC1223 0x122317D3 /* Vendor Device ID */ #define PCIDevVenIDARC1230 0x123017D3 /* Vendor Device ID */ #define PCIDevVenIDARC1231 0x123117D3 /* Vendor Device ID */ #define PCIDevVenIDARC1260 0x126017D3 /* Vendor Device ID */ @@ -119,6 +129,7 @@ #define PCIDevVenIDARC1680 0x168017D3 /* Vendor Device ID */ #define PCIDevVenIDARC1681 0x168117D3 /* Vendor Device ID */ #define PCIDevVenIDARC1880 0x188017D3 /* Vendor Device ID */ +#define PCIDevVenIDARC1882 0x188217D3 /* Vendor Device ID */ #ifndef PCIR_BARS #define PCIR_BARS 0x10 @@ -830,6 +841,8 @@ struct AdapterControlBlock { u_int32_t pktRequestCount; u_int32_t pktReturnCount; #endif + u_int32_t vendor_device_id; + u_int32_t adapter_bus_speed; };/* HW_DEVICE_EXTENSION */ /* acb_flags */ #define ACB_F_SCSISTOPADAPTER 0x0001 @@ -848,6 +861,10 @@ struct AdapterControlBlock { /* devstate */ #define ARECA_RAID_GONE 0x55 #define ARECA_RAID_GOOD 0xaa +/* adapter_bus_speed */ +#define ACB_BUS_SPEED_3G 0 +#define ACB_BUS_SPEED_6G 1 +#define ACB_BUS_SPEED_12G 2 /* ********************************************************************* ** Message Unit structure From owner-svn-src-stable@FreeBSD.ORG Wed Sep 19 22:24:09 2012 Return-Path: Delivered-To: svn-src-stable@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id B2E2D1065673; Wed, 19 Sep 2012 22:24:09 +0000 (UTC) (envelope-from mjacob@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 9DA748FC17; Wed, 19 Sep 2012 22:24:09 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q8JMO9cF083637; Wed, 19 Sep 2012 22:24:09 GMT (envelope-from mjacob@svn.freebsd.org) Received: (from mjacob@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q8JMO9EE083635; Wed, 19 Sep 2012 22:24:09 GMT (envelope-from mjacob@svn.freebsd.org) Message-Id: <201209192224.q8JMO9EE083635@svn.freebsd.org> From: Matt Jacob Date: Wed, 19 Sep 2012 22:24:09 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r240713 - stable/9/sys/dev/isp X-BeenThere: svn-src-stable@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for all the -stable branches of the src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 19 Sep 2012 22:24:09 -0000 Author: mjacob Date: Wed Sep 19 22:24:09 2012 New Revision: 240713 URL: http://svn.freebsd.org/changeset/base/240713 Log: MFC of 240580 and 240590- correct some comments. Modified: stable/9/sys/dev/isp/isp_freebsd.c Directory Properties: stable/9/sys/ (props changed) stable/9/sys/dev/ (props changed) stable/9/sys/dev/isp/ (props changed) Modified: stable/9/sys/dev/isp/isp_freebsd.c ============================================================================== --- stable/9/sys/dev/isp/isp_freebsd.c Wed Sep 19 22:12:57 2012 (r240712) +++ stable/9/sys/dev/isp/isp_freebsd.c Wed Sep 19 22:24:09 2012 (r240713) @@ -1735,10 +1735,10 @@ isp_target_start_ctio(ispsoftc_t *isp, u /* * Mode 1, status, no data. Only possible when we are sending status, have - * no data to transfer, and any sense length can fit in the ct7_entry. + * no data to transfer, and any sense data can fit into a ct7_entry_t. * - * Mode 2, status, no data. We have to use this in the case sense data - * won't fit into a ct7_entry_t. + * Mode 2, status, no data. We have to use this in the case that + * the sense data won't fit into a ct7_entry_t. * */ if (sendstatus && xfrlen == 0) { From owner-svn-src-stable@FreeBSD.ORG Wed Sep 19 23:03:55 2012 Return-Path: Delivered-To: svn-src-stable@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 40073106566C; Wed, 19 Sep 2012 23:03:55 +0000 (UTC) (envelope-from delphij@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 287088FC14; Wed, 19 Sep 2012 23:03:55 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q8JN3tXD090577; Wed, 19 Sep 2012 23:03:55 GMT (envelope-from delphij@svn.freebsd.org) Received: (from delphij@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q8JN3slm090573; Wed, 19 Sep 2012 23:03:54 GMT (envelope-from delphij@svn.freebsd.org) Message-Id: <201209192303.q8JN3slm090573@svn.freebsd.org> From: Xin LI Date: Wed, 19 Sep 2012 23:03:54 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-8@freebsd.org X-SVN-Group: stable-8 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r240715 - in stable/8: share/man/man4 sys/dev/arcmsr X-BeenThere: svn-src-stable@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for all the -stable branches of the src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 19 Sep 2012 23:03:55 -0000 Author: delphij Date: Wed Sep 19 23:03:54 2012 New Revision: 240715 URL: http://svn.freebsd.org/changeset/base/240715 Log: MFC r240079,215837: Update arcmsr(4) to vendor version 1.20.00.25. Many thanks to Areca for continuing to support FreeBSD. Submitted by: Ching-Lung Huang Modified: stable/8/share/man/man4/arcmsr.4 stable/8/sys/dev/arcmsr/arcmsr.c stable/8/sys/dev/arcmsr/arcmsr.h Directory Properties: stable/8/share/man/man4/ (props changed) stable/8/sys/ (props changed) stable/8/sys/dev/ (props changed) stable/8/sys/dev/arcmsr/ (props changed) Modified: stable/8/share/man/man4/arcmsr.4 ============================================================================== --- stable/8/share/man/man4/arcmsr.4 Wed Sep 19 22:26:05 2012 (r240714) +++ stable/8/share/man/man4/arcmsr.4 Wed Sep 19 23:03:54 2012 (r240715) @@ -24,12 +24,12 @@ .\" .\" $FreeBSD$ .\" -.Dd March 28, 2008 +.Dd September 3, 2012 .Dt ARCMSR 4 .Os .Sh NAME .Nm arcmsr -.Nd Areca SATA II RAID Controller driver +.Nd Areca RAID Controller driver .Sh SYNOPSIS To compile this driver into the kernel, place the following lines in your @@ -50,11 +50,11 @@ arcmsr_load="YES" .Sh DESCRIPTION The .Nm -driver provides support for the Areca ARC-11xx and ARC-12xx series of SATA II -RAID controllers. +driver provides support for the Areca ARC-11xx, ARC-12xx, ARC-13xx, +ARC-16xx and ARC-18xx series of SAS and SATA RAID controllers. These controllers feature RAID-0, 1, 3, 5, 6, and 10 and JBOD acceleration for up to 16 SATA drives. -Raid level and stripe level +RAID level and stripe level migration, online capacity expansion, hot insertion/removal, automatic failover and rebuild, and SMART are also supported. Access to the arrays is provided @@ -82,8 +82,6 @@ ARC-1160 .It ARC-1170 .It -ARC-1180 -.It ARC-1110ML .It ARC-1120ML @@ -92,14 +90,32 @@ ARC-1130ML .It ARC-1160ML .It +ARC-1200 +.It +ARC-1201 +.It ARC-1210 .It +ARC-1212 +.It +ARC-1213 +.It ARC-1220 .It +ARC-1222 +.It +ARC-1223 +.It ARC-1230 .It +ARC-1231 +.It ARC-1260 .It +ARC-1261 +.It +ARC-1270 +.It ARC-1280 .It ARC-1210ML @@ -111,6 +127,18 @@ ARC-1231ML ARC-1261ML .It ARC-1280ML +.It +ARC-1380 +.It +ARC-1381 +.It +ARC-1680 +.It +ARC-1681 +.It +ARC-1880 +.It +ARC-1882 .El .Sh FILES .Bl -tag -width ".Pa /dev/arcmsr?" -compact Modified: stable/8/sys/dev/arcmsr/arcmsr.c ============================================================================== --- stable/8/sys/dev/arcmsr/arcmsr.c Wed Sep 19 22:26:05 2012 (r240714) +++ stable/8/sys/dev/arcmsr/arcmsr.c Wed Sep 19 23:03:54 2012 (r240715) @@ -37,38 +37,43 @@ ************************************************************************** ** History ** -** REV# DATE NAME DESCRIPTION -** 1.00.00.00 03/31/2004 Erich Chen First release -** 1.20.00.02 11/29/2004 Erich Chen bug fix with arcmsr_bus_reset when PHY error -** 1.20.00.03 04/19/2005 Erich Chen add SATA 24 Ports adapter type support +** REV# DATE NAME DESCRIPTION +** 1.00.00.00 03/31/2004 Erich Chen First release +** 1.20.00.02 11/29/2004 Erich Chen bug fix with arcmsr_bus_reset when PHY error +** 1.20.00.03 04/19/2005 Erich Chen add SATA 24 Ports adapter type support ** clean unused function -** 1.20.00.12 09/12/2005 Erich Chen bug fix with abort command handling, +** 1.20.00.12 09/12/2005 Erich Chen bug fix with abort command handling, ** firmware version check ** and firmware update notify for hardware bug fix ** handling if none zero high part physical address ** of srb resource -** 1.20.00.13 08/18/2006 Erich Chen remove pending srb and report busy +** 1.20.00.13 08/18/2006 Erich Chen remove pending srb and report busy ** add iop message xfer ** with scsi pass-through command ** add new device id of sas raid adapters ** code fit for SPARC64 & PPC -** 1.20.00.14 02/05/2007 Erich Chen bug fix for incorrect ccb_h.status report +** 1.20.00.14 02/05/2007 Erich Chen bug fix for incorrect ccb_h.status report ** and cause g_vfs_done() read write error -** 1.20.00.15 10/10/2007 Erich Chen support new RAID adapter type ARC120x -** 1.20.00.16 10/10/2009 Erich Chen Bug fix for RAID adapter type ARC120x +** 1.20.00.15 10/10/2007 Erich Chen support new RAID adapter type ARC120x +** 1.20.00.16 10/10/2009 Erich Chen Bug fix for RAID adapter type ARC120x ** bus_dmamem_alloc() with BUS_DMA_ZERO -** 1.20.00.17 07/15/2010 Ching Huang Added support ARC1880 -** report CAM_DEV_NOT_THERE instead of CAM_SEL_TIMEOUT when device failed, -** prevent cam_periph_error removing all LUN devices of one Target id -** for any one LUN device failed -** 1.20.00.18 10/14/2010 Ching Huang Fixed "inquiry data fails comparion at DV1 step" -** 10/25/2010 Ching Huang Fixed bad range input in bus_alloc_resource for ADAPTER_TYPE_B -** 1.20.00.19 11/11/2010 Ching Huang Fixed arcmsr driver prevent arcsas support for Areca SAS HBA ARC13x0 -** 1.20.00.20 12/08/2010 Ching Huang Avoid calling atomic_set_int function -** 1.20.00.21 02/08/2011 Ching Huang Implement I/O request timeout -** 02/14/2011 Ching Huang Modified pktRequestCount -** 1.20.00.21 03/03/2011 Ching Huang if a command timeout, then wait its ccb back before free it -** 1.20.00.22 07/04/2011 Ching Huang Fixed multiple MTX panic +** 1.20.00.17 07/15/2010 Ching Huang Added support ARC1880 +** report CAM_DEV_NOT_THERE instead of CAM_SEL_TIMEOUT when device failed, +** prevent cam_periph_error removing all LUN devices of one Target id +** for any one LUN device failed +** 1.20.00.18 10/14/2010 Ching Huang Fixed "inquiry data fails comparion at DV1 step" +** 10/25/2010 Ching Huang Fixed bad range input in bus_alloc_resource for ADAPTER_TYPE_B +** 1.20.00.19 11/11/2010 Ching Huang Fixed arcmsr driver prevent arcsas support for Areca SAS HBA ARC13x0 +** 1.20.00.20 12/08/2010 Ching Huang Avoid calling atomic_set_int function +** 1.20.00.21 02/08/2011 Ching Huang Implement I/O request timeout +** 02/14/2011 Ching Huang Modified pktRequestCount +** 1.20.00.21 03/03/2011 Ching Huang if a command timeout, then wait its ccb back before free it +** 1.20.00.22 07/04/2011 Ching Huang Fixed multiple MTX panic +** 1.20.00.23 10/28/2011 Ching Huang Added TIMEOUT_DELAY in case of too many HDDs need to start +** 1.20.00.23 11/08/2011 Ching Huang Added report device transfer speed +** 1.20.00.23 01/30/2012 Ching Huang Fixed Request requeued and Retrying command +** 1.20.00.24 06/11/2012 Ching Huang Fixed return sense data condition +** 1.20.00.25 08/17/2012 Ching Huang Fixed hotplug device no function on type A adapter ****************************************************************************************** */ @@ -154,7 +159,7 @@ __FBSDID("$FreeBSD$"); #define arcmsr_callout_init(a) callout_init(a); #endif -#define ARCMSR_DRIVER_VERSION "Driver Version 1.20.00.22 2011-07-04" +#define ARCMSR_DRIVER_VERSION "Driver Version 1.20.00.25 2012-08-17" #include #define SRB_SIZE ((sizeof(struct CommandControlBlock)+0x1f) & 0xffe0) #define ARCMSR_SRBS_POOL_SIZE (SRB_SIZE * ARCMSR_MAX_FREESRB_NUM) @@ -296,7 +301,7 @@ static struct cdevsw arcmsr_cdevsw = { if(acb==NULL) { return ENXIO; } - return 0; + return (0); } /* ************************************************************************** @@ -347,7 +352,7 @@ static struct cdevsw arcmsr_cdevsw = { if(acb==NULL) { return ENXIO; } - return(arcmsr_iop_ioctlcmd(acb, ioctl_cmd, arg)); + return (arcmsr_iop_ioctlcmd(acb, ioctl_cmd, arg)); } /* ********************************************************************** @@ -378,7 +383,7 @@ static u_int32_t arcmsr_disable_allintr( } break; } - return(intmask_org); + return (intmask_org); } /* ********************************************************************** @@ -411,7 +416,6 @@ static void arcmsr_enable_allintr( struc } break; } - return; } /* ********************************************************************** @@ -431,7 +435,7 @@ static u_int8_t arcmsr_hba_wait_msgint_r UDELAY(10000); }/*max 1 seconds*/ }while(Retries++ < 20);/*max 20 sec*/ - return FALSE; + return (FALSE); } /* ********************************************************************** @@ -452,7 +456,7 @@ static u_int8_t arcmsr_hbb_wait_msgint_r UDELAY(10000); }/*max 1 seconds*/ }while(Retries++ < 20);/*max 20 sec*/ - return FALSE; + return (FALSE); } /* ********************************************************************** @@ -472,7 +476,7 @@ static u_int8_t arcmsr_hbc_wait_msgint_r UDELAY(10000); }/*max 1 seconds*/ }while(Retries++ < 20);/*max 20 sec*/ - return FALSE; + return (FALSE); } /* ************************************************************************ @@ -490,7 +494,6 @@ static void arcmsr_flush_hba_cache(struc retry_count--; } }while(retry_count!=0); - return; } /* ************************************************************************ @@ -509,7 +512,6 @@ static void arcmsr_flush_hbb_cache(struc retry_count--; } }while(retry_count!=0); - return; } /* ************************************************************************ @@ -528,7 +530,6 @@ static void arcmsr_flush_hbc_cache(struc retry_count--; } }while(retry_count!=0); - return; } /* ************************************************************************ @@ -550,7 +551,6 @@ static void arcmsr_flush_adapter_cache(s } break; } - return; } /* ******************************************************************************* @@ -596,7 +596,7 @@ static void arcmsr_async(void *cb_arg, u if((target_id > ARCMSR_MAX_TARGETID) || (target_lun > ARCMSR_MAX_TARGETLUN)) { break; } - printf("%s:scsi id=%d lun=%d device lost \n", device_get_name(acb->pci_dev), target_id, target_lun); + // printf("%s:scsi id=%d lun=%d device lost \n", device_get_name(acb->pci_dev), target_id, target_lun); break; default: break; @@ -612,14 +612,13 @@ static void arcmsr_report_sense_info(str pccb->ccb_h.status |= CAM_SCSI_STATUS_ERROR; pccb->csio.scsi_status = SCSI_STATUS_CHECK_COND; - if(&pccb->csio.sense_data) { + if(pccb->csio.sense_len) { memset(&pccb->csio.sense_data, 0, sizeof(pccb->csio.sense_data)); memcpy(&pccb->csio.sense_data, srb->arcmsr_cdb.SenseData, get_min(sizeof(struct SENSE_DATA), sizeof(pccb->csio.sense_data))); ((u_int8_t *)&pccb->csio.sense_data)[0] = (0x1 << 7 | 0x70); /* Valid,ErrorCode */ pccb->ccb_h.status |= CAM_AUTOSNS_VALID; } - return; } /* ********************************************************************* @@ -631,7 +630,6 @@ static void arcmsr_abort_hba_allcmd(stru if(!arcmsr_hba_wait_msgint_ready(acb)) { printf("arcmsr%d: wait 'abort all outstanding command' timeout \n", acb->pci_unit); } - return; } /* ********************************************************************* @@ -643,7 +641,6 @@ static void arcmsr_abort_hbb_allcmd(stru if(!arcmsr_hbb_wait_msgint_ready(acb)) { printf("arcmsr%d: wait 'abort all outstanding command' timeout \n", acb->pci_unit); } - return; } /* ********************************************************************* @@ -656,7 +653,6 @@ static void arcmsr_abort_hbc_allcmd(stru if(!arcmsr_hbc_wait_msgint_ready(acb)) { printf("arcmsr%d: wait 'abort all outstanding command' timeout \n", acb->pci_unit); } - return; } /* ********************************************************************* @@ -678,7 +674,6 @@ static void arcmsr_abort_allcmd(struct A } break; } - return; } /* ********************************************************************** @@ -716,7 +711,6 @@ static void arcmsr_srb_complete(struct C acb->pktReturnCount++; #endif xpt_done(pccb); - return; } /* ************************************************************************** @@ -768,7 +762,6 @@ static void arcmsr_report_srb_state(stru break; } } - return; } /* ************************************************************************** @@ -801,7 +794,6 @@ static void arcmsr_drain_donequeue(struc return; } arcmsr_report_srb_state(acb, srb, error); - return; } /* ************************************************************************** @@ -883,7 +875,6 @@ static void arcmsr_done4abort_postqueue( } break; } - return; } /* **************************************************************************** @@ -923,7 +914,6 @@ static void arcmsr_iop_reset(struct Adap acb->pktRequestCount = 0; acb->pktReturnCount = 0; #endif - return; } /* ********************************************************************** @@ -1011,7 +1001,6 @@ static void arcmsr_build_srb(struct Comm arcmsr_cdb->DataLength = 0; } srb->arc_cdb_size=arccdbsize; - return; } /* ************************************************************************** @@ -1072,7 +1061,6 @@ static void arcmsr_post_srb(struct Adapt } break; } - return; } /* ************************************************************************ @@ -1156,7 +1144,6 @@ static void arcmsr_iop_message_read(stru CHIP_REG_WRITE32(HBC_MessageUnit, 0, inbound_doorbell, ARCMSR_HBCMU_DRV2IOP_DATA_READ_OK); } } - return; } /* ************************************************************************** @@ -1221,7 +1208,6 @@ static void arcmsr_post_ioctldata2iop(st */ arcmsr_iop_message_wrote(acb); } - return; } /* ************************************************************************ @@ -1236,7 +1222,6 @@ static void arcmsr_stop_hba_bgrb(struct printf("arcmsr%d: wait 'stop adapter background rebulid' timeout \n" , acb->pci_unit); } - return; } /* ************************************************************************ @@ -1251,7 +1236,6 @@ static void arcmsr_stop_hbb_bgrb(struct printf( "arcmsr%d: wait 'stop adapter background rebulid' timeout \n" , acb->pci_unit); } - return; } /* ************************************************************************ @@ -1265,7 +1249,6 @@ static void arcmsr_stop_hbc_bgrb(struct if(!arcmsr_hbc_wait_msgint_ready(acb)) { printf("arcmsr%d: wait 'stop adapter background rebulid' timeout \n", acb->pci_unit); } - return; } /* ************************************************************************ @@ -1287,7 +1270,6 @@ static void arcmsr_stop_adapter_bgrb(str } break; } - return; } /* ************************************************************************ @@ -1305,7 +1287,6 @@ static void arcmsr_poll(struct cam_sim * arcmsr_interrupt(acb); if( mutex == 0 ) ARCMSR_LOCK_RELEASE(&acb->qbuffer_lock); - return; } /* ************************************************************************** @@ -1340,7 +1321,6 @@ static void arcmsr_iop2drv_data_wrote_ha } else { acb->acb_flags|=ACB_F_IOPDATA_OVERFLOW; } - return; } /* ************************************************************************** @@ -1383,7 +1363,6 @@ static void arcmsr_iop2drv_data_read_han if(acb->wqbuf_firstindex==acb->wqbuf_lastindex) { acb->acb_flags |= ACB_F_MESSAGE_WQBUFFER_CLEARED; } - return; } static void arcmsr_rescanLun_cb(struct cam_periph *periph, union ccb *ccb) @@ -1417,7 +1396,6 @@ static void arcmsr_rescan_lun(struct Ada ccb->ccb_h.cbfcnp = arcmsr_rescanLun_cb; ccb->crcn.flags = CAM_FLAG_NONE; xpt_action(ccb); - return; } @@ -1488,6 +1466,7 @@ static void arcmsr_dr_handle(struct Adap } break; } + if(acb->acb_flags & ACB_F_BUS_HANG_ON) { acb->acb_flags &= ~ACB_F_BUS_HANG_ON; @@ -1592,7 +1571,6 @@ static void arcmsr_hba_doorbell_isr(stru if(outbound_doorbell & ARCMSR_OUTBOUND_IOP331_DATA_READ_OK) { arcmsr_iop2drv_data_read_handle(acb); } - return; } /* ************************************************************************** @@ -1620,7 +1598,6 @@ static void arcmsr_hbc_doorbell_isr(stru if(outbound_doorbell & ARCMSR_HBCMU_IOP2DRV_MESSAGE_CMD_DONE) { arcmsr_hbc_message_isr(acb); /* messenger of "driver to iop commands" */ } - return; } /* ************************************************************************** @@ -1644,7 +1621,6 @@ static void arcmsr_hba_postqueue_isr(str error=(flag_srb & ARCMSR_SRBREPLY_FLAG_ERROR_MODE0)?TRUE:FALSE; arcmsr_drain_donequeue(acb, flag_srb, error); } /*drain reply FIFO*/ - return; } /* ************************************************************************** @@ -1674,7 +1650,6 @@ static void arcmsr_hbb_postqueue_isr(str error=(flag_srb & ARCMSR_SRBREPLY_FLAG_ERROR_MODE0)?TRUE:FALSE; arcmsr_drain_donequeue(acb, flag_srb, error); } /*drain reply FIFO*/ - return; } /* ************************************************************************** @@ -1704,7 +1679,6 @@ static void arcmsr_hbc_postqueue_isr(str } throttling++; } /*drain reply FIFO*/ - return; } /* ********************************************************************** @@ -1712,30 +1686,29 @@ static void arcmsr_hbc_postqueue_isr(str */ static void arcmsr_handle_hba_isr( struct AdapterControlBlock *acb) { - u_int32_t outbound_intstatus; + u_int32_t outbound_intStatus; /* ********************************************* ** check outbound intstatus ********************************************* */ - outbound_intstatus=CHIP_REG_READ32(HBA_MessageUnit, 0, outbound_intstatus) & acb->outbound_int_enable; - if(!outbound_intstatus) { + outbound_intStatus=CHIP_REG_READ32(HBA_MessageUnit, 0, outbound_intstatus) & acb->outbound_int_enable; + if(!outbound_intStatus) { /*it must be share irq*/ return; } - CHIP_REG_WRITE32(HBA_MessageUnit, 0, outbound_intstatus, outbound_intstatus);/*clear interrupt*/ + CHIP_REG_WRITE32(HBA_MessageUnit, 0, outbound_intstatus, outbound_intStatus);/*clear interrupt*/ /* MU doorbell interrupts*/ - if(outbound_intstatus & ARCMSR_MU_OUTBOUND_DOORBELL_INT) { + if(outbound_intStatus & ARCMSR_MU_OUTBOUND_DOORBELL_INT) { arcmsr_hba_doorbell_isr(acb); } /* MU post queue interrupts*/ - if(outbound_intstatus & ARCMSR_MU_OUTBOUND_POSTQUEUE_INT) { + if(outbound_intStatus & ARCMSR_MU_OUTBOUND_POSTQUEUE_INT) { arcmsr_hba_postqueue_isr(acb); } - if(outbound_intstatus & ARCMSR_MU_OUTBOUND_MESSAGE0_INT) { + if(outbound_intStatus & ARCMSR_MU_OUTBOUND_MESSAGE0_INT) { arcmsr_hba_message_isr(acb); } - return; } /* ********************************************************************** @@ -1771,7 +1744,6 @@ static void arcmsr_handle_hbb_isr( struc if(outbound_doorbell & ARCMSR_IOP2DRV_MESSAGE_CMD_DONE) { arcmsr_hbb_message_isr(acb); } - return; } /* ********************************************************************** @@ -1798,7 +1770,6 @@ static void arcmsr_handle_hbc_isr( struc if(host_interrupt_status & ARCMSR_HBCMU_OUTBOUND_POSTQUEUE_ISR) { arcmsr_hbc_postqueue_isr(acb); } - return; } /* ****************************************************************************** @@ -1821,7 +1792,6 @@ static void arcmsr_interrupt(struct Adap " unknow adapter type =%d\n", acb->pci_unit, acb->adapter_type); break; } - return; } /* ********************************************************************** @@ -1844,7 +1814,7 @@ static void arcmsr_polling_devmap(void* struct AdapterControlBlock *acb = (struct AdapterControlBlock *)arg; switch (acb->adapter_type) { case ACB_ADAPTER_TYPE_A: - CHIP_REG_WRITE32(HBC_MessageUnit, 0, inbound_msgaddr0, ARCMSR_INBOUND_MESG0_GET_CONFIG); + CHIP_REG_WRITE32(HBA_MessageUnit, 0, inbound_msgaddr0, ARCMSR_INBOUND_MESG0_GET_CONFIG); break; case ACB_ADAPTER_TYPE_B: @@ -2065,7 +2035,7 @@ u_int32_t arcmsr_iop_ioctlcmd(struct Ada break; } ARCMSR_LOCK_RELEASE(&acb->qbuffer_lock); - return retvalue; + return (retvalue); } /* ************************************************************************** @@ -2191,7 +2161,7 @@ static int arcmsr_iop_message_xfer(struc if (wqbuf_lastindex != wqbuf_firstindex) { arcmsr_post_ioctldata2iop(acb); /* has error report sensedata */ - if(&pccb->csio.sense_data) { + if(pccb->csio.sense_len) { ((u_int8_t *)&pccb->csio.sense_data)[0] = (0x1 << 7 | 0x70); /* Valid,ErrorCode */ ((u_int8_t *)&pccb->csio.sense_data)[2] = 0x05; @@ -2221,7 +2191,7 @@ static int arcmsr_iop_message_xfer(struc } } else { /* has error report sensedata */ - if(&pccb->csio.sense_data) { + if(pccb->csio.sense_len) { ((u_int8_t *)&pccb->csio.sense_data)[0] = (0x1 << 7 | 0x70); /* Valid,ErrorCode */ ((u_int8_t *)&pccb->csio.sense_data)[2] = 0x05; @@ -2312,7 +2282,7 @@ static int arcmsr_iop_message_xfer(struc retvalue = ARCMSR_MESSAGE_FAIL; } message_out: - return retvalue; + return (retvalue); } /* ********************************************************************* @@ -2375,7 +2345,7 @@ static void arcmsr_execute_srb(void *arg arcmsr_srb_complete(srb, 0); return; } - if(acb->srboutstandingcount >= ARCMSR_MAX_OUTSTANDING_CMD) { + if(acb->srboutstandingcount > ARCMSR_MAX_OUTSTANDING_CMD) { xpt_freeze_simq(acb->psim, 1); pccb->ccb_h.status = CAM_REQUEUE_REQ; acb->acb_flags |= ACB_F_CAM_DEV_QFRZN; @@ -2388,10 +2358,9 @@ static void arcmsr_execute_srb(void *arg if (pccb->ccb_h.timeout != CAM_TIME_INFINITY) { arcmsr_callout_init(&srb->ccb_callout); - callout_reset(&srb->ccb_callout, (pccb->ccb_h.timeout * hz ) / 1000, arcmsr_srb_timeout, srb); + callout_reset(&srb->ccb_callout, ((pccb->ccb_h.timeout + (ARCMSR_TIMEOUT_DELAY * 1000)) * hz) / 1000, arcmsr_srb_timeout, srb); srb->srb_flags |= SRB_FLAG_TIMER_START; } - return; } /* ***************************************************************************************** @@ -2455,7 +2424,6 @@ static void arcmsr_bus_reset(struct Adap } arcmsr_iop_reset(acb); acb->acb_flags &= ~ACB_F_BUS_RESET; - return; } /* ************************************************************************** @@ -2607,10 +2575,24 @@ static void arcmsr_action(struct cam_sim strncpy(cpi->dev_name, cam_sim_name(psim), DEV_IDLEN); cpi->unit_number=cam_sim_unit(psim); #ifdef CAM_NEW_TRAN_CODE - cpi->transport = XPORT_SPI; - cpi->transport_version = 2; + if(acb->adapter_bus_speed == ACB_BUS_SPEED_6G) + cpi->base_transfer_speed = 600000; + else + cpi->base_transfer_speed = 300000; + if((acb->vendor_device_id == PCIDevVenIDARC1880) || + (acb->vendor_device_id == PCIDevVenIDARC1680)) + { + cpi->transport = XPORT_SAS; + cpi->transport_version = 0; + cpi->protocol_version = SCSI_REV_SPC2; + } + else + { + cpi->transport = XPORT_SPI; + cpi->transport_version = 2; + cpi->protocol_version = SCSI_REV_2; + } cpi->protocol = PROTO_SCSI; - cpi->protocol_version = SCSI_REV_2; #endif cpi->ccb_h.status |= CAM_REQ_CMP; xpt_done(pccb); @@ -2674,28 +2656,46 @@ static void arcmsr_action(struct cam_sim { struct ccb_trans_settings_scsi *scsi; struct ccb_trans_settings_spi *spi; + struct ccb_trans_settings_sas *sas; scsi = &cts->proto_specific.scsi; - spi = &cts->xport_specific.spi; - cts->protocol = PROTO_SCSI; - cts->protocol_version = SCSI_REV_2; - cts->transport = XPORT_SPI; - cts->transport_version = 2; - spi->flags = CTS_SPI_FLAGS_DISC_ENB; - spi->sync_period=3; - spi->sync_offset=32; - spi->bus_width=MSG_EXT_WDTR_BUS_16_BIT; scsi->flags = CTS_SCSI_FLAGS_TAG_ENB; - spi->valid = CTS_SPI_VALID_DISC - | CTS_SPI_VALID_SYNC_RATE - | CTS_SPI_VALID_SYNC_OFFSET - | CTS_SPI_VALID_BUS_WIDTH; scsi->valid = CTS_SCSI_VALID_TQ; + cts->protocol = PROTO_SCSI; + + if((acb->vendor_device_id == PCIDevVenIDARC1880) || + (acb->vendor_device_id == PCIDevVenIDARC1680)) + { + cts->protocol_version = SCSI_REV_SPC2; + cts->transport_version = 0; + cts->transport = XPORT_SAS; + sas = &cts->xport_specific.sas; + sas->valid = CTS_SAS_VALID_SPEED; + if(acb->vendor_device_id == PCIDevVenIDARC1880) + sas->bitrate = 600000; + else if(acb->vendor_device_id == PCIDevVenIDARC1680) + sas->bitrate = 300000; + } + else + { + cts->protocol_version = SCSI_REV_2; + cts->transport_version = 2; + cts->transport = XPORT_SPI; + spi = &cts->xport_specific.spi; + spi->flags = CTS_SPI_FLAGS_DISC_ENB; + spi->sync_period=2; + spi->sync_offset=32; + spi->bus_width=MSG_EXT_WDTR_BUS_16_BIT; + spi->valid = CTS_SPI_VALID_DISC + | CTS_SPI_VALID_SYNC_RATE + | CTS_SPI_VALID_SYNC_OFFSET + | CTS_SPI_VALID_BUS_WIDTH; + } } #else { cts->flags=(CCB_TRANS_DISC_ENB | CCB_TRANS_TAG_ENB); - cts->sync_period=3; + cts->sync_period=2; cts->sync_offset=32; cts->bus_width=MSG_EXT_WDTR_BUS_16_BIT; cts->valid=CCB_TRANS_SYNC_RATE_VALID | @@ -2759,7 +2759,6 @@ static void arcmsr_action(struct cam_sim xpt_done(pccb); break; } - return; } /* ********************************************************************** @@ -2772,7 +2771,6 @@ static void arcmsr_start_hba_bgrb(struct if(!arcmsr_hba_wait_msgint_ready(acb)) { printf("arcmsr%d: wait 'start adapter background rebulid' timeout \n", acb->pci_unit); } - return; } /* ********************************************************************** @@ -2785,7 +2783,6 @@ static void arcmsr_start_hbb_bgrb(struct if(!arcmsr_hbb_wait_msgint_ready(acb)) { printf( "arcmsr%d: wait 'start adapter background rebulid' timeout \n", acb->pci_unit); } - return; } /* ********************************************************************** @@ -2799,7 +2796,6 @@ static void arcmsr_start_hbc_bgrb(struct if(!arcmsr_hbc_wait_msgint_ready(acb)) { printf("arcmsr%d: wait 'start adapter background rebulid' timeout \n", acb->pci_unit); } - return; } /* ********************************************************************** @@ -2818,7 +2814,6 @@ static void arcmsr_start_adapter_bgrb(st arcmsr_start_hbc_bgrb(acb); break; } - return; } /* ********************************************************************** @@ -2873,7 +2868,6 @@ polling_ccb_retry: } arcmsr_report_srb_state(acb, srb, error); } /*drain reply FIFO*/ - return; } /* ********************************************************************** @@ -2934,7 +2928,6 @@ polling_ccb_retry: } arcmsr_report_srb_state(acb, srb, error); } /*drain reply FIFO*/ - return; } /* ********************************************************************** @@ -2985,7 +2978,6 @@ polling_ccb_retry: } arcmsr_report_srb_state(acb, srb, error); } /*drain reply FIFO*/ - return; } /* ********************************************************************** @@ -3053,7 +3045,6 @@ static void arcmsr_get_hba_config(struct acb->firm_sdram_size=CHIP_REG_READ32(HBA_MessageUnit, 0, msgcode_rwbuffer[3]); /*firm_sdram_size, 3, 12-15*/ acb->firm_ide_channels=CHIP_REG_READ32(HBA_MessageUnit, 0, msgcode_rwbuffer[4]); /*firm_ide_channels, 4, 16-19*/ acb->firm_cfg_version=CHIP_REG_READ32(HBA_MessageUnit, 0, msgcode_rwbuffer[ARCMSR_FW_CFGVER_OFFSET]); /*firm_cfg_version, 25, */ - return; } /* ********************************************************************** @@ -3100,7 +3091,6 @@ static void arcmsr_get_hbb_config(struct acb->firm_sdram_size=CHIP_REG_READ32(HBB_RWBUFFER, 1, msgcode_rwbuffer[3]); /*firm_sdram_size, 3, 12-15*/ acb->firm_ide_channels=CHIP_REG_READ32(HBB_RWBUFFER, 1, msgcode_rwbuffer[4]); /*firm_ide_channels, 4, 16-19*/ acb->firm_cfg_version=CHIP_REG_READ32(HBB_RWBUFFER, 1, msgcode_rwbuffer[ARCMSR_FW_CFGVER_OFFSET]); /*firm_cfg_version, 25, */ - return; } /* ********************************************************************** @@ -3148,7 +3138,6 @@ static void arcmsr_get_hbc_config(struct acb->firm_sdram_size =CHIP_REG_READ32(HBC_MessageUnit, 0, msgcode_rwbuffer[3]); /*firm_sdram_size, 3, 12-15*/ acb->firm_ide_channels =CHIP_REG_READ32(HBC_MessageUnit, 0, msgcode_rwbuffer[4]); /*firm_ide_channels, 4, 16-19*/ acb->firm_cfg_version =CHIP_REG_READ32(HBC_MessageUnit, 0, msgcode_rwbuffer[ARCMSR_FW_CFGVER_OFFSET]); /*firm_cfg_version, 25, */ - return; } /* ********************************************************************** @@ -3170,7 +3159,6 @@ static void arcmsr_get_firmware_spec(str } break; } - return; } /* ********************************************************************** @@ -3219,7 +3207,6 @@ static void arcmsr_wait_firmware_ready( } break; } - return; } /* ********************************************************************** @@ -3253,7 +3240,6 @@ static void arcmsr_clear_doorbell_queue_ } break; } - return; } /* ************************************************************************ @@ -3336,7 +3322,7 @@ static u_int32_t arcmsr_iop_confirm(stru } break; } - return TRUE; + return (TRUE); } /* ************************************************************************ @@ -3359,7 +3345,6 @@ static void arcmsr_enable_eoi_mode(struc } break; } - return; } /* ********************************************************************** @@ -3382,7 +3367,6 @@ static void arcmsr_iop_init(struct Adapt /* enable outbound Post Queue, outbound doorbell Interrupt */ arcmsr_enable_allintr(acb, intmask_org); acb->acb_flags |=ACB_F_IOP_INITED; - return; } /* ********************************************************************** @@ -3414,7 +3398,6 @@ static void arcmsr_map_free_srb(void *ar srb_tmp = (struct CommandControlBlock *)((unsigned long)srb_tmp+SRB_SIZE); } acb->vir2phy_offset=(unsigned long)srb_tmp-(unsigned long)srb_phyaddr; - return; } /* ************************************************************************ @@ -3433,7 +3416,6 @@ static void arcmsr_free_resource(struct bus_dma_tag_destroy(acb->srb_dmat); bus_dma_tag_destroy(acb->dm_segs_dmat); bus_dma_tag_destroy(acb->parent_dmat); - return; } /* ************************************************************************ @@ -3444,16 +3426,24 @@ static u_int32_t arcmsr_initialize(devic struct AdapterControlBlock *acb=device_get_softc(dev); u_int16_t pci_command; int i, j,max_coherent_size; - - switch (pci_get_devid(dev)) { - case PCIDevVenIDARC1880: { + u_int32_t vendor_dev_id; + + vendor_dev_id = pci_get_devid(dev); + acb->vendor_device_id = vendor_dev_id; + switch (vendor_dev_id) { + case PCIDevVenIDARC1880: + case PCIDevVenIDARC1882: + case PCIDevVenIDARC1213: + case PCIDevVenIDARC1223: { acb->adapter_type=ACB_ADAPTER_TYPE_C; + acb->adapter_bus_speed = ACB_BUS_SPEED_6G; max_coherent_size=ARCMSR_SRBS_POOL_SIZE; } break; case PCIDevVenIDARC1200: case PCIDevVenIDARC1201: { acb->adapter_type=ACB_ADAPTER_TYPE_B; + acb->adapter_bus_speed = ACB_BUS_SPEED_3G; max_coherent_size=ARCMSR_SRBS_POOL_SIZE+(sizeof(struct HBB_MessageUnit)); } break; @@ -3477,6 +3467,7 @@ static u_int32_t arcmsr_initialize(devic case PCIDevVenIDARC1680: case PCIDevVenIDARC1681: { acb->adapter_type=ACB_ADAPTER_TYPE_A; + acb->adapter_bus_speed = ACB_BUS_SPEED_3G; max_coherent_size=ARCMSR_SRBS_POOL_SIZE; } break; @@ -3804,7 +3795,7 @@ static int arcmsr_attach(device_t dev) #endif arcmsr_callout_init(&acb->devmap_callout); callout_reset(&acb->devmap_callout, 60 * hz, arcmsr_polling_devmap, acb); - return 0; + return (0); } /* @@ -3851,6 +3842,9 @@ static int arcmsr_probe(device_t dev) type = "SAS 3G"; break; case PCIDevVenIDARC1880: + case PCIDevVenIDARC1882: + case PCIDevVenIDARC1213: + case PCIDevVenIDARC1223: type = "SAS 6G"; break; default: Modified: stable/8/sys/dev/arcmsr/arcmsr.h ============================================================================== --- stable/8/sys/dev/arcmsr/arcmsr.h Wed Sep 19 22:26:05 2012 (r240714) +++ stable/8/sys/dev/arcmsr/arcmsr.h Wed Sep 19 23:03:54 2012 (r240715) @@ -52,6 +52,7 @@ #define ARCMSR_MAX_ADAPTER 4 #define ARCMSR_RELEASE_SIMQ_LEVEL 230 #define ARCMSR_MAX_HBB_POSTQUEUE 264 /* (ARCMSR_MAX_OUTSTANDING_CMD+8) */ +#define ARCMSR_TIMEOUT_DELAY 60 /* in sec */ /* ********************************************************************* */ @@ -97,6 +98,13 @@ #define PCI_DEVICE_ID_ARECA_1681 0x1681 /* Device ID */ #define PCI_DEVICE_ID_ARECA_1880 0x1880 /* Device ID */ +#define ARECA_SUB_DEV_ID_1880 0x1880 /* Subsystem Device ID */ +#define ARECA_SUB_DEV_ID_1882 0x1882 /* Subsystem Device ID */ +#define ARECA_SUB_DEV_ID_1212 0x1212 /* Subsystem Device ID */ +#define ARECA_SUB_DEV_ID_1213 0x1213 /* Subsystem Device ID */ +#define ARECA_SUB_DEV_ID_1222 0x1222 /* Subsystem Device ID */ +#define ARECA_SUB_DEV_ID_1223 0x1223 /* Subsystem Device ID */ + #define PCIDevVenIDARC1110 0x111017D3 /* Vendor Device ID */ #define PCIDevVenIDARC1120 0x112017D3 /* Vendor Device ID */ #define PCIDevVenIDARC1130 0x113017D3 /* Vendor Device ID */ @@ -106,8 +114,10 @@ #define PCIDevVenIDARC1201 0x120117D3 /* Vendor Device ID */ #define PCIDevVenIDARC1210 0x121017D3 /* Vendor Device ID */ #define PCIDevVenIDARC1212 0x121217D3 /* Vendor Device ID */ +#define PCIDevVenIDARC1213 0x121317D3 /* Vendor Device ID */ #define PCIDevVenIDARC1220 0x122017D3 /* Vendor Device ID */ #define PCIDevVenIDARC1222 0x122217D3 /* Vendor Device ID */ +#define PCIDevVenIDARC1223 0x122317D3 /* Vendor Device ID */ #define PCIDevVenIDARC1230 0x123017D3 /* Vendor Device ID */ #define PCIDevVenIDARC1231 0x123117D3 /* Vendor Device ID */ #define PCIDevVenIDARC1260 0x126017D3 /* Vendor Device ID */ @@ -119,6 +129,7 @@ #define PCIDevVenIDARC1680 0x168017D3 /* Vendor Device ID */ #define PCIDevVenIDARC1681 0x168117D3 /* Vendor Device ID */ #define PCIDevVenIDARC1880 0x188017D3 /* Vendor Device ID */ +#define PCIDevVenIDARC1882 0x188217D3 /* Vendor Device ID */ #ifndef PCIR_BARS #define PCIR_BARS 0x10 @@ -830,6 +841,8 @@ struct AdapterControlBlock { u_int32_t pktRequestCount; u_int32_t pktReturnCount; #endif + u_int32_t vendor_device_id; + u_int32_t adapter_bus_speed; };/* HW_DEVICE_EXTENSION */ /* acb_flags */ #define ACB_F_SCSISTOPADAPTER 0x0001 @@ -848,6 +861,10 @@ struct AdapterControlBlock { /* devstate */ #define ARECA_RAID_GONE 0x55 #define ARECA_RAID_GOOD 0xaa +/* adapter_bus_speed */ +#define ACB_BUS_SPEED_3G 0 +#define ACB_BUS_SPEED_6G 1 +#define ACB_BUS_SPEED_12G 2 /* ********************************************************************* ** Message Unit structure *** DIFF OUTPUT TRUNCATED AT 1000 LINES *** From owner-svn-src-stable@FreeBSD.ORG Thu Sep 20 00:51:10 2012 Return-Path: Delivered-To: svn-src-stable@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 8F775106564A; Thu, 20 Sep 2012 00:51:10 +0000 (UTC) (envelope-from mjacob@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 6EF988FC0A; Thu, 20 Sep 2012 00:51:10 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q8K0pAK4009477; Thu, 20 Sep 2012 00:51:10 GMT (envelope-from mjacob@svn.freebsd.org) Received: (from mjacob@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q8K0pAHd009473; Thu, 20 Sep 2012 00:51:10 GMT (envelope-from mjacob@svn.freebsd.org) Message-Id: <201209200051.q8K0pAHd009473@svn.freebsd.org> From: Matt Jacob Date: Thu, 20 Sep 2012 00:51:10 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r240717 - stable/9/sys/dev/isp X-BeenThere: svn-src-stable@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for all the -stable branches of the src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 20 Sep 2012 00:51:10 -0000 Author: mjacob Date: Thu Sep 20 00:51:09 2012 New Revision: 240717 URL: http://svn.freebsd.org/changeset/base/240717 Log: MFC of 239502: Remove dependence on MAXPHYS. Modified: stable/9/sys/dev/isp/isp_freebsd.h stable/9/sys/dev/isp/isp_pci.c stable/9/sys/dev/isp/isp_sbus.c Directory Properties: stable/9/sys/ (props changed) stable/9/sys/dev/ (props changed) stable/9/sys/dev/isp/ (props changed) Modified: stable/9/sys/dev/isp/isp_freebsd.h ============================================================================== --- stable/9/sys/dev/isp/isp_freebsd.h Wed Sep 19 23:25:24 2012 (r240716) +++ stable/9/sys/dev/isp/isp_freebsd.h Thu Sep 20 00:51:09 2012 (r240717) @@ -726,9 +726,6 @@ int isp_fcp_next_crn(ispsoftc_t *, uint8 #define isp_sim_alloc(a, b, c, d, e, f, g, h) \ cam_sim_alloc(a, b, c, d, e, &(d)->isp_osinfo.lock, f, g, h) -/* Should be BUS_SPACE_MAXSIZE, but MAXPHYS is larger than BUS_SPACE_MAXSIZE */ -#define ISP_NSEGS ((MAXPHYS / PAGE_SIZE) + 1) - #define ISP_PATH_PRT(i, l, p, ...) \ if ((l) == ISP_LOGALL || ((l)& (i)->isp_dblev) != 0) { \ xpt_print(p, __VA_ARGS__); \ Modified: stable/9/sys/dev/isp/isp_pci.c ============================================================================== --- stable/9/sys/dev/isp/isp_pci.c Wed Sep 19 23:25:24 2012 (r240716) +++ stable/9/sys/dev/isp/isp_pci.c Thu Sep 20 00:51:09 2012 (r240717) @@ -1525,7 +1525,7 @@ static int isp_pci_mbxdma(ispsoftc_t *isp) { caddr_t base; - uint32_t len; + uint32_t len, nsegs; int i, error, ns, cmap = 0; bus_size_t slim; /* segment size */ bus_addr_t llim; /* low limit of unavailable dma */ @@ -1567,6 +1567,11 @@ isp_pci_mbxdma(ispsoftc_t *isp) return (1); } + if (isp->isp_osinfo.sixtyfourbit) { + nsegs = ISP_NSEG64_MAX; + } else { + nsegs = ISP_NSEG_MAX; + } #ifdef ISP_TARGET_MODE /* * XXX: We don't really support 64 bit target mode for parallel scsi yet @@ -1579,7 +1584,7 @@ isp_pci_mbxdma(ispsoftc_t *isp) } #endif - if (isp_dma_tag_create(BUS_DMA_ROOTARG(ISP_PCD(isp)), 1, slim, llim, hlim, NULL, NULL, BUS_SPACE_MAXSIZE, ISP_NSEGS, slim, 0, &isp->isp_osinfo.dmat)) { + if (isp_dma_tag_create(BUS_DMA_ROOTARG(ISP_PCD(isp)), 1, slim, llim, hlim, NULL, NULL, BUS_SPACE_MAXSIZE, nsegs, slim, 0, &isp->isp_osinfo.dmat)) { free(isp->isp_osinfo.pcmd_pool, M_DEVBUF); ISP_LOCK(isp); isp_prt(isp, ISP_LOGERR, "could not create master dma tag"); Modified: stable/9/sys/dev/isp/isp_sbus.c ============================================================================== --- stable/9/sys/dev/isp/isp_sbus.c Wed Sep 19 23:25:24 2012 (r240716) +++ stable/9/sys/dev/isp/isp_sbus.c Thu Sep 20 00:51:09 2012 (r240717) @@ -497,7 +497,7 @@ isp_sbus_mbxdma(ispsoftc_t *isp) if (isp_dma_tag_create(BUS_DMA_ROOTARG(ISP_SBD(isp)), 1, BUS_SPACE_MAXADDR_24BIT+1, BUS_SPACE_MAXADDR_32BIT, BUS_SPACE_MAXADDR_32BIT, NULL, NULL, BUS_SPACE_MAXSIZE_32BIT, - ISP_NSEGS, BUS_SPACE_MAXADDR_24BIT, 0, &isp->isp_osinfo.dmat)) { + ISP_NSEG_MAX, BUS_SPACE_MAXADDR_24BIT, 0, &isp->isp_osinfo.dmat)) { isp_prt(isp, ISP_LOGERR, "could not create master dma tag"); free(isp->isp_osinfo.pcmd_pool, M_DEVBUF); free(isp->isp_xflist, M_DEVBUF); From owner-svn-src-stable@FreeBSD.ORG Thu Sep 20 01:23:55 2012 Return-Path: Delivered-To: svn-src-stable@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 4AA861065702; Thu, 20 Sep 2012 01:23:55 +0000 (UTC) (envelope-from scottl@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 338E38FC14; Thu, 20 Sep 2012 01:23:55 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q8K1NtDF013984; Thu, 20 Sep 2012 01:23:55 GMT (envelope-from scottl@svn.freebsd.org) Received: (from scottl@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q8K1NsPV013979; Thu, 20 Sep 2012 01:23:54 GMT (envelope-from scottl@svn.freebsd.org) Message-Id: <201209200123.q8K1NsPV013979@svn.freebsd.org> From: Scott Long Date: Thu, 20 Sep 2012 01:23:54 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r240718 - stable/9/sys/dev/ixgbe X-BeenThere: svn-src-stable@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for all the -stable branches of the src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 20 Sep 2012 01:23:55 -0000 Author: scottl Date: Thu Sep 20 01:23:54 2012 New Revision: 240718 URL: http://svn.freebsd.org/changeset/base/240718 Log: Sync the ixgbe driver from HEAD to stable/9 r236627 - Fix driver deadlock due to OACTIVE flag r236729 - Fix prefetch programming typo r239940 - Improve small RX packet performance r240155 - Fix missing braces in PHY configuration r240366 - Remove a prefetch directive that hurts performance Approved by: jfv Obtained from: Netflix, inc. Modified: stable/9/sys/dev/ixgbe/ixgbe.c stable/9/sys/dev/ixgbe/ixgbe.h stable/9/sys/dev/ixgbe/ixgbe_osdep.h Directory Properties: stable/9/sys/dev/ixgbe/ (props changed) Modified: stable/9/sys/dev/ixgbe/ixgbe.c ============================================================================== --- stable/9/sys/dev/ixgbe/ixgbe.c Thu Sep 20 00:51:09 2012 (r240717) +++ stable/9/sys/dev/ixgbe/ixgbe.c Thu Sep 20 01:23:54 2012 (r240718) @@ -1145,7 +1145,7 @@ ixgbe_init_locked(struct adapter *adapte * from the Intel linux driver 3.8.21. * Prefetching enables tx line rate even with 1 queue. */ - txdctl |= (16 << 0) | (1 << 8); + txdctl |= (32 << 0) | (1 << 8); IXGBE_WRITE_REG(hw, IXGBE_TXDCTL(i), txdctl); } @@ -1390,7 +1390,7 @@ ixgbe_handle_que(void *context, int pend ixgbe_start_locked(txr, ifp); #endif IXGBE_TX_UNLOCK(txr); - if (more || (ifp->if_drv_flags & IFF_DRV_OACTIVE)) { + if (more) { taskqueue_enqueue(que->tq, &que->que_task); return; } @@ -3698,21 +3698,30 @@ no_split: mp = rxbuf->m_pack; mp->m_pkthdr.len = mp->m_len = adapter->rx_mbuf_sz; - /* Get the memory mapping */ - error = bus_dmamap_load_mbuf_sg(rxr->ptag, - rxbuf->pmap, mp, pseg, &nsegs, BUS_DMA_NOWAIT); - if (error != 0) { - printf("Refresh mbufs: payload dmamap load" - " failure - %d\n", error); - m_free(mp); - rxbuf->m_pack = NULL; - goto update; + + /* If we're dealing with an mbuf that was copied rather + * than replaced, there's no need to go through busdma. + */ + if ((rxbuf->flags & IXGBE_RX_COPY) == 0) { + /* Get the memory mapping */ + error = bus_dmamap_load_mbuf_sg(rxr->ptag, + rxbuf->pmap, mp, pseg, &nsegs, BUS_DMA_NOWAIT); + if (error != 0) { + printf("Refresh mbufs: payload dmamap load" + " failure - %d\n", error); + m_free(mp); + rxbuf->m_pack = NULL; + goto update; + } + rxbuf->m_pack = mp; + bus_dmamap_sync(rxr->ptag, rxbuf->pmap, + BUS_DMASYNC_PREREAD); + rxbuf->paddr = rxr->rx_base[i].read.pkt_addr = + htole64(pseg[0].ds_addr); + } else { + rxr->rx_base[i].read.pkt_addr = rxbuf->paddr; + rxbuf->flags &= ~IXGBE_RX_COPY; } - rxbuf->m_pack = mp; - bus_dmamap_sync(rxr->ptag, rxbuf->pmap, - BUS_DMASYNC_PREREAD); - rxr->rx_base[i].read.pkt_addr = - htole64(pseg[0].ds_addr); refreshed = TRUE; /* Next is precalculated */ @@ -4025,6 +4034,7 @@ skip_head: rxr->next_to_refresh = 0; rxr->lro_enabled = FALSE; rxr->rx_split_packets = 0; + rxr->rx_copies = 0; rxr->rx_bytes = 0; rxr->discard = FALSE; rxr->vtag_strip = FALSE; @@ -4580,14 +4590,36 @@ ixgbe_rxeof(struct ix_queue *que, int co ** that determines what we are */ sendmp = rbuf->fmp; - rbuf->m_pack = rbuf->fmp = NULL; if (sendmp != NULL) { /* secondary frag */ + rbuf->m_pack = rbuf->fmp = NULL; mp->m_flags &= ~M_PKTHDR; sendmp->m_pkthdr.len += mp->m_len; } else { + /* + * Optimize. This might be a small packet, + * maybe just a TCP ACK. Do a fast copy that + * is cache aligned into a new mbuf, and + * leave the old mbuf+cluster for re-use. + */ + if (eop && plen <= IXGBE_RX_COPY_LEN) { + sendmp = m_gethdr(M_DONTWAIT, MT_DATA); + if (sendmp != NULL) { + sendmp->m_data += + IXGBE_RX_COPY_ALIGN; + ixgbe_bcopy(mp->m_data, + sendmp->m_data, plen); + sendmp->m_len = plen; + rxr->rx_copies++; + rbuf->flags |= IXGBE_RX_COPY; + } + } + if (sendmp == NULL) { + rbuf->m_pack = rbuf->fmp = NULL; + sendmp = mp; + } + /* first desc of a non-ps chain */ - sendmp = mp; sendmp->m_flags |= M_PKTHDR; sendmp->m_pkthdr.len = mp->m_len; if (staterr & IXGBE_RXD_STAT_VP) { @@ -5438,6 +5470,9 @@ ixgbe_add_hw_stats(struct adapter *adapt SYSCTL_ADD_UQUAD(ctx, queue_list, OID_AUTO, "rx_bytes", CTLFLAG_RD, &rxr->rx_bytes, "Queue Bytes Received"); + SYSCTL_ADD_UQUAD(ctx, queue_list, OID_AUTO, "rx_copies", + CTLFLAG_RD, &rxr->rx_copies, + "Copied RX Frames"); SYSCTL_ADD_INT(ctx, queue_list, OID_AUTO, "lro_queued", CTLFLAG_RD, &lro->lro_queued, 0, "LRO Queued"); Modified: stable/9/sys/dev/ixgbe/ixgbe.h ============================================================================== --- stable/9/sys/dev/ixgbe/ixgbe.h Thu Sep 20 00:51:09 2012 (r240717) +++ stable/9/sys/dev/ixgbe/ixgbe.h Thu Sep 20 01:23:54 2012 (r240718) @@ -154,6 +154,19 @@ #define IXGBE_FC_HI 0x20000 #define IXGBE_FC_LO 0x10000 +/* + * Used for optimizing small rx mbufs. Effort is made to keep the copy + * small and aligned for the CPU L1 cache. + * + * MHLEN is typically 168 bytes, giving us 8-byte alignment. Getting + * 32 byte alignment needed for the fast bcopy results in 8 bytes being + * wasted. Getting 64 byte alignment, which _should_ be ideal for + * modern Intel CPUs, results in 40 bytes wasted and a significant drop + * in observed efficiency of the optimization, 97.9% -> 81.8%. + */ +#define IXGBE_RX_COPY_LEN 160 +#define IXGBE_RX_COPY_ALIGN (MHLEN - IXGBE_RX_COPY_LEN) + /* Keep older OS drivers building... */ #if !defined(SYSCTL_ADD_UQUAD) #define SYSCTL_ADD_UQUAD SYSCTL_ADD_QUAD @@ -245,6 +258,9 @@ struct ixgbe_rx_buf { struct mbuf *fmp; bus_dmamap_t hmap; bus_dmamap_t pmap; + u_int flags; +#define IXGBE_RX_COPY 0x01 + uint64_t paddr; }; /* @@ -339,6 +355,7 @@ struct rx_ring { /* Soft stats */ u64 rx_irq; u64 rx_split_packets; + u64 rx_copies; u64 rx_packets; u64 rx_bytes; u64 rx_discarded; Modified: stable/9/sys/dev/ixgbe/ixgbe_osdep.h ============================================================================== --- stable/9/sys/dev/ixgbe/ixgbe_osdep.h Thu Sep 20 00:51:09 2012 (r240717) +++ stable/9/sys/dev/ixgbe/ixgbe_osdep.h Thu Sep 20 01:23:54 2012 (r240718) @@ -143,6 +143,25 @@ void prefetch(void *x) #define prefetch(x) #endif +/* + * Optimized bcopy thanks to Luigi Rizzo's investigative work. Assumes + * non-overlapping regions and 32-byte padding on both src and dst. + */ +static __inline int +ixgbe_bcopy(void *_src, void *_dst, int l) +{ + uint64_t *src = _src; + uint64_t *dst = _dst; + + for (; l > 0; l -= 32) { + *dst++ = *src++; + *dst++ = *src++; + *dst++ = *src++; + *dst++ = *src++; + } + return (0); +} + struct ixgbe_osdep { bus_space_tag_t mem_bus_space_tag; From owner-svn-src-stable@FreeBSD.ORG Thu Sep 20 04:35:21 2012 Return-Path: Delivered-To: svn-src-stable@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 9E532106564A; Thu, 20 Sep 2012 04:35:21 +0000 (UTC) (envelope-from dougb@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 878F08FC08; Thu, 20 Sep 2012 04:35:21 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q8K4ZLfC041316; Thu, 20 Sep 2012 04:35:21 GMT (envelope-from dougb@svn.freebsd.org) Received: (from dougb@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q8K4ZLRI041307; Thu, 20 Sep 2012 04:35:21 GMT (envelope-from dougb@svn.freebsd.org) Message-Id: <201209200435.q8K4ZLRI041307@svn.freebsd.org> From: Doug Barton Date: Thu, 20 Sep 2012 04:35:21 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-8@freebsd.org X-SVN-Group: stable-8 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r240732 - in stable/8/contrib/bind9: . bin/named bin/nsupdate lib/dns lib/dns/include/dns X-BeenThere: svn-src-stable@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for all the -stable branches of the src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 20 Sep 2012 04:35:21 -0000 Author: dougb Date: Thu Sep 20 04:35:20 2012 New Revision: 240732 URL: http://svn.freebsd.org/changeset/base/240732 Log: Upgrade to 9.6-ESV-R7-P3: Prevents a crash when queried for a record whose RDATA exceeds 65535 bytes. Prevents a crash when validating caused by using "Bad cache" data before it has been initialized. ISC_QUEUE handling for recursive clients was updated to address a race condition that could cause a memory leak. This rarely occurred with UDP clients, but could be a significant problem for a server handling a steady rate of TCP queries. A condition has been corrected where improper handling of zero-length RDATA could cause undesirable behavior, including termination of the named process. For more information: https://kb.isc.org/article/AA-00788 Modified: stable/8/contrib/bind9/CHANGES stable/8/contrib/bind9/bin/named/server.c stable/8/contrib/bind9/bin/nsupdate/nsupdate.c stable/8/contrib/bind9/lib/dns/include/dns/rdata.h stable/8/contrib/bind9/lib/dns/master.c stable/8/contrib/bind9/lib/dns/rdata.c stable/8/contrib/bind9/lib/dns/rdataslab.c stable/8/contrib/bind9/version Directory Properties: stable/8/contrib/bind9/ (props changed) Modified: stable/8/contrib/bind9/CHANGES ============================================================================== --- stable/8/contrib/bind9/CHANGES Thu Sep 20 04:21:29 2012 (r240731) +++ stable/8/contrib/bind9/CHANGES Thu Sep 20 04:35:20 2012 (r240732) @@ -1,3 +1,11 @@ + --- 9.6-ESV-R7-P3 released --- + +3364. [security] Named could die on specially crafted record. + [RT #30416] + +3358 [bug] Fix declaration of fatal in bin/named/server.c + and bin/nsupdate/main.c. [RT #30522] + --- 9.6-ESV-R7-P2 released --- 3346. [security] Bad-cache data could be used before it was Modified: stable/8/contrib/bind9/bin/named/server.c ============================================================================== --- stable/8/contrib/bind9/bin/named/server.c Thu Sep 20 04:21:29 2012 (r240731) +++ stable/8/contrib/bind9/bin/named/server.c Thu Sep 20 04:35:20 2012 (r240732) @@ -228,7 +228,7 @@ static const struct { { NULL, ISC_FALSE } }; -ISC_PLATFORM_NORETURN_POST static void +ISC_PLATFORM_NORETURN_PRE static void fatal(const char *msg, isc_result_t result) ISC_PLATFORM_NORETURN_POST; static void Modified: stable/8/contrib/bind9/bin/nsupdate/nsupdate.c ============================================================================== --- stable/8/contrib/bind9/bin/nsupdate/nsupdate.c Thu Sep 20 04:21:29 2012 (r240731) +++ stable/8/contrib/bind9/bin/nsupdate/nsupdate.c Thu Sep 20 04:35:20 2012 (r240732) @@ -174,7 +174,7 @@ typedef struct nsu_requestinfo { static void sendrequest(isc_sockaddr_t *srcaddr, isc_sockaddr_t *destaddr, dns_message_t *msg, dns_request_t **request); -ISC_PLATFORM_NORETURN_POST static void +ISC_PLATFORM_NORETURN_PRE static void fatal(const char *format, ...) ISC_FORMAT_PRINTF(1, 2) ISC_PLATFORM_NORETURN_POST; Modified: stable/8/contrib/bind9/lib/dns/include/dns/rdata.h ============================================================================== --- stable/8/contrib/bind9/lib/dns/include/dns/rdata.h Thu Sep 20 04:21:29 2012 (r240731) +++ stable/8/contrib/bind9/lib/dns/include/dns/rdata.h Thu Sep 20 04:35:20 2012 (r240732) @@ -128,6 +128,17 @@ struct dns_rdata { #define DNS_RDATA_OFFLINE 0x0002 /*%< RRSIG has a offline key. */ /* + * The maximum length of a RDATA that can be sent on the wire. + * Max packet size (65535) less header (12), less name (1), type (2), + * class (2), ttl(4), length (2). + * + * None of the defined types that support name compression can exceed + * this and all new types are to be sent uncompressed. + */ + +#define DNS_RDATA_MAXLENGTH 65512U + +/* * Flags affecting rdata formatting style. Flags 0xFFFF0000 * are used by masterfile-level formatting and defined elsewhere. * See additional comments at dns_rdata_tofmttext(). Modified: stable/8/contrib/bind9/lib/dns/master.c ============================================================================== --- stable/8/contrib/bind9/lib/dns/master.c Thu Sep 20 04:21:29 2012 (r240731) +++ stable/8/contrib/bind9/lib/dns/master.c Thu Sep 20 04:35:20 2012 (r240732) @@ -75,7 +75,7 @@ /*% * max message size - header - root - type - class - ttl - rdlen */ -#define MINTSIZ (65535 - 12 - 1 - 2 - 2 - 4 - 2) +#define MINTSIZ DNS_RDATA_MAXLENGTH /*% * Size for tokens in the presentation format, * The largest tokens are the base64 blocks in KEY and CERT records, Modified: stable/8/contrib/bind9/lib/dns/rdata.c ============================================================================== --- stable/8/contrib/bind9/lib/dns/rdata.c Thu Sep 20 04:21:29 2012 (r240731) +++ stable/8/contrib/bind9/lib/dns/rdata.c Thu Sep 20 04:35:20 2012 (r240732) @@ -414,6 +414,7 @@ dns_rdata_fromwire(dns_rdata_t *rdata, d isc_buffer_t st; isc_boolean_t use_default = ISC_FALSE; isc_uint32_t activelength; + size_t length; REQUIRE(dctx != NULL); if (rdata != NULL) { @@ -444,6 +445,14 @@ dns_rdata_fromwire(dns_rdata_t *rdata, d } /* + * Reject any rdata that expands out to more than DNS_RDATA_MAXLENGTH + * as we cannot transmit it. + */ + length = isc_buffer_usedlength(target) - isc_buffer_usedlength(&st); + if (result == ISC_R_SUCCESS && length > DNS_RDATA_MAXLENGTH) + result = DNS_R_FORMERR; + + /* * We should have consumed all of our buffer. */ if (result == ISC_R_SUCCESS && !buffer_empty(source)) @@ -451,8 +460,7 @@ dns_rdata_fromwire(dns_rdata_t *rdata, d if (rdata != NULL && result == ISC_R_SUCCESS) { region.base = isc_buffer_used(&st); - region.length = isc_buffer_usedlength(target) - - isc_buffer_usedlength(&st); + region.length = length; dns_rdata_fromregion(rdata, rdclass, type, ®ion); } @@ -587,6 +595,7 @@ dns_rdata_fromtext(dns_rdata_t *rdata, d unsigned long line; void (*callback)(dns_rdatacallbacks_t *, const char *, ...); isc_result_t tresult; + size_t length; REQUIRE(origin == NULL || dns_name_isabsolute(origin) == ISC_TRUE); if (rdata != NULL) { @@ -658,10 +667,13 @@ dns_rdata_fromtext(dns_rdata_t *rdata, d } } while (1); + length = isc_buffer_usedlength(target) - isc_buffer_usedlength(&st); + if (result == ISC_R_SUCCESS && length > DNS_RDATA_MAXLENGTH) + result = ISC_R_NOSPACE; + if (rdata != NULL && result == ISC_R_SUCCESS) { region.base = isc_buffer_used(&st); - region.length = isc_buffer_usedlength(target) - - isc_buffer_usedlength(&st); + region.length = length; dns_rdata_fromregion(rdata, rdclass, type, ®ion); } if (result != ISC_R_SUCCESS) { @@ -789,6 +801,7 @@ dns_rdata_fromstruct(dns_rdata_t *rdata, isc_buffer_t st; isc_region_t region; isc_boolean_t use_default = ISC_FALSE; + size_t length; REQUIRE(source != NULL); if (rdata != NULL) { @@ -803,10 +816,13 @@ dns_rdata_fromstruct(dns_rdata_t *rdata, if (use_default) (void)NULL; + length = isc_buffer_usedlength(target) - isc_buffer_usedlength(&st); + if (result == ISC_R_SUCCESS && length > DNS_RDATA_MAXLENGTH) + result = ISC_R_NOSPACE; + if (rdata != NULL && result == ISC_R_SUCCESS) { region.base = isc_buffer_used(&st); - region.length = isc_buffer_usedlength(target) - - isc_buffer_usedlength(&st); + region.length = length; dns_rdata_fromregion(rdata, rdclass, type, ®ion); } if (result != ISC_R_SUCCESS) Modified: stable/8/contrib/bind9/lib/dns/rdataslab.c ============================================================================== --- stable/8/contrib/bind9/lib/dns/rdataslab.c Thu Sep 20 04:21:29 2012 (r240731) +++ stable/8/contrib/bind9/lib/dns/rdataslab.c Thu Sep 20 04:35:20 2012 (r240732) @@ -298,6 +298,7 @@ dns_rdataslab_fromrdataset(dns_rdataset_ length = x[i].rdata.length; if (rdataset->type == dns_rdatatype_rrsig) length++; + INSIST(length <= 0xffff); *rawbuf++ = (length & 0xff00) >> 8; *rawbuf++ = (length & 0x00ff); #if DNS_RDATASET_FIXED Modified: stable/8/contrib/bind9/version ============================================================================== --- stable/8/contrib/bind9/version Thu Sep 20 04:21:29 2012 (r240731) +++ stable/8/contrib/bind9/version Thu Sep 20 04:35:20 2012 (r240732) @@ -7,4 +7,4 @@ MAJORVER=9 MINORVER=6 PATCHVER= RELEASETYPE=-ESV -RELEASEVER=-R7-P2 +RELEASEVER=-R7-P3 From owner-svn-src-stable@FreeBSD.ORG Thu Sep 20 10:13:14 2012 Return-Path: Delivered-To: svn-src-stable@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id E7A251065670; Thu, 20 Sep 2012 10:13:14 +0000 (UTC) (envelope-from kib@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id B8ED48FC0C; Thu, 20 Sep 2012 10:13:14 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q8KADEos095892; Thu, 20 Sep 2012 10:13:14 GMT (envelope-from kib@svn.freebsd.org) Received: (from kib@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q8KADE9a095890; Thu, 20 Sep 2012 10:13:14 GMT (envelope-from kib@svn.freebsd.org) Message-Id: <201209201013.q8KADE9a095890@svn.freebsd.org> From: Konstantin Belousov Date: Thu, 20 Sep 2012 10:13:14 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r240744 - stable/9/sys/fs/deadfs X-BeenThere: svn-src-stable@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for all the -stable branches of the src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 20 Sep 2012 10:13:15 -0000 Author: kib Date: Thu Sep 20 10:13:14 2012 New Revision: 240744 URL: http://svn.freebsd.org/changeset/base/240744 Log: MFC r240464: The deadfs VOPs for vop_ioctl and vop_bmap call itself recursively, which is an elaborate way to cause kernel panic. Change the VOPs implementation to return EBADF for a reclaimed vnode. Modified: stable/9/sys/fs/deadfs/dead_vnops.c Directory Properties: stable/9/sys/ (props changed) stable/9/sys/fs/ (props changed) Modified: stable/9/sys/fs/deadfs/dead_vnops.c ============================================================================== --- stable/9/sys/fs/deadfs/dead_vnops.c Thu Sep 20 10:07:31 2012 (r240743) +++ stable/9/sys/fs/deadfs/dead_vnops.c Thu Sep 20 10:13:14 2012 (r240744) @@ -41,8 +41,6 @@ /* * Prototypes for dead operations on vnodes. */ -static vop_bmap_t dead_bmap; -static vop_ioctl_t dead_ioctl; static vop_lookup_t dead_lookup; static vop_open_t dead_open; static vop_poll_t dead_poll; @@ -56,12 +54,12 @@ struct vop_vector dead_vnodeops = { .vop_access = VOP_EBADF, .vop_advlock = VOP_EBADF, - .vop_bmap = dead_bmap, + .vop_bmap = VOP_EBADF, .vop_create = VOP_PANIC, .vop_getattr = VOP_EBADF, .vop_getwritemount = dead_getwritemount, .vop_inactive = VOP_NULL, - .vop_ioctl = dead_ioctl, + .vop_ioctl = VOP_EBADF, .vop_link = VOP_PANIC, .vop_lookup = dead_lookup, .vop_mkdir = VOP_PANIC, @@ -166,43 +164,6 @@ dead_write(ap) } /* - * Device ioctl operation. - */ -/* ARGSUSED */ -static int -dead_ioctl(ap) - struct vop_ioctl_args /* { - struct vnode *a_vp; - u_long a_command; - caddr_t a_data; - int a_fflag; - struct ucred *a_cred; - struct proc *a_p; - } */ *ap; -{ - /* XXX: Doesn't this just recurse back here ? */ - return (VOP_IOCTL_AP(ap)); -} - -/* - * Wait until the vnode has finished changing state. - */ -static int -dead_bmap(ap) - struct vop_bmap_args /* { - struct vnode *a_vp; - daddr_t a_bn; - struct bufobj **a_bop; - daddr_t *a_bnp; - int *a_runp; - int *a_runb; - } */ *ap; -{ - - return (VOP_BMAP(ap->a_vp, ap->a_bn, ap->a_bop, ap->a_bnp, ap->a_runp, ap->a_runb)); -} - -/* * Trivial poll routine that always returns POLLHUP. * This is necessary so that a process which is polling a file * gets notified when that file is revoke()d. From owner-svn-src-stable@FreeBSD.ORG Thu Sep 20 10:28:44 2012 Return-Path: Delivered-To: svn-src-stable@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id B323F106566C; Thu, 20 Sep 2012 10:28:44 +0000 (UTC) (envelope-from kib@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 83F848FC08; Thu, 20 Sep 2012 10:28:44 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q8KASieA000545; Thu, 20 Sep 2012 10:28:44 GMT (envelope-from kib@svn.freebsd.org) Received: (from kib@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q8KASiN3000543; Thu, 20 Sep 2012 10:28:44 GMT (envelope-from kib@svn.freebsd.org) Message-Id: <201209201028.q8KASiN3000543@svn.freebsd.org> From: Konstantin Belousov Date: Thu, 20 Sep 2012 10:28:44 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-8@freebsd.org X-SVN-Group: stable-8 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r240745 - stable/8/sys/fs/deadfs X-BeenThere: svn-src-stable@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for all the -stable branches of the src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 20 Sep 2012 10:28:44 -0000 Author: kib Date: Thu Sep 20 10:28:44 2012 New Revision: 240745 URL: http://svn.freebsd.org/changeset/base/240745 Log: MFC r240464: The deadfs VOPs for vop_ioctl and vop_bmap call itself recursively, which is an elaborate way to cause kernel panic. Change the VOPs implementation to return EBADF for a reclaimed vnode. Modified: stable/8/sys/fs/deadfs/dead_vnops.c Directory Properties: stable/8/sys/ (props changed) stable/8/sys/fs/ (props changed) Modified: stable/8/sys/fs/deadfs/dead_vnops.c ============================================================================== --- stable/8/sys/fs/deadfs/dead_vnops.c Thu Sep 20 10:13:14 2012 (r240744) +++ stable/8/sys/fs/deadfs/dead_vnops.c Thu Sep 20 10:28:44 2012 (r240745) @@ -41,8 +41,6 @@ /* * Prototypes for dead operations on vnodes. */ -static vop_bmap_t dead_bmap; -static vop_ioctl_t dead_ioctl; static vop_lookup_t dead_lookup; static vop_open_t dead_open; static vop_poll_t dead_poll; @@ -56,12 +54,12 @@ struct vop_vector dead_vnodeops = { .vop_access = VOP_EBADF, .vop_advlock = VOP_EBADF, - .vop_bmap = dead_bmap, + .vop_bmap = VOP_EBADF, .vop_create = VOP_PANIC, .vop_getattr = VOP_EBADF, .vop_getwritemount = dead_getwritemount, .vop_inactive = VOP_NULL, - .vop_ioctl = dead_ioctl, + .vop_ioctl = VOP_EBADF, .vop_link = VOP_PANIC, .vop_lookup = dead_lookup, .vop_mkdir = VOP_PANIC, @@ -166,43 +164,6 @@ dead_write(ap) } /* - * Device ioctl operation. - */ -/* ARGSUSED */ -static int -dead_ioctl(ap) - struct vop_ioctl_args /* { - struct vnode *a_vp; - u_long a_command; - caddr_t a_data; - int a_fflag; - struct ucred *a_cred; - struct proc *a_p; - } */ *ap; -{ - /* XXX: Doesn't this just recurse back here ? */ - return (VOP_IOCTL_AP(ap)); -} - -/* - * Wait until the vnode has finished changing state. - */ -static int -dead_bmap(ap) - struct vop_bmap_args /* { - struct vnode *a_vp; - daddr_t a_bn; - struct bufobj **a_bop; - daddr_t *a_bnp; - int *a_runp; - int *a_runb; - } */ *ap; -{ - - return (VOP_BMAP(ap->a_vp, ap->a_bn, ap->a_bop, ap->a_bnp, ap->a_runp, ap->a_runb)); -} - -/* * Trivial poll routine that always returns POLLHUP. * This is necessary so that a process which is polling a file * gets notified when that file is revoke()d. From owner-svn-src-stable@FreeBSD.ORG Thu Sep 20 16:03:05 2012 Return-Path: Delivered-To: svn-src-stable@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 9E0A8106566C; Thu, 20 Sep 2012 16:03:05 +0000 (UTC) (envelope-from alc@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 881158FC12; Thu, 20 Sep 2012 16:03:05 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q8KG35Nh048471; Thu, 20 Sep 2012 16:03:05 GMT (envelope-from alc@svn.freebsd.org) Received: (from alc@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q8KG35nY048466; Thu, 20 Sep 2012 16:03:05 GMT (envelope-from alc@svn.freebsd.org) Message-Id: <201209201603.q8KG35nY048466@svn.freebsd.org> From: Alan Cox Date: Thu, 20 Sep 2012 16:03:05 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r240754 - in stable/9/sys: amd64/amd64 i386/i386 i386/xen mips/mips X-BeenThere: svn-src-stable@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for all the -stable branches of the src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 20 Sep 2012 16:03:05 -0000 Author: alc Date: Thu Sep 20 16:03:04 2012 New Revision: 240754 URL: http://svn.freebsd.org/changeset/base/240754 Log: MFC r240317 Simplify pmap_unmapdev(). Don't set PTE_W on the page table entry in pmap_kenter{,_attr}() on MIPS. Modified: stable/9/sys/amd64/amd64/pmap.c stable/9/sys/i386/i386/pmap.c stable/9/sys/i386/xen/pmap.c stable/9/sys/mips/mips/pmap.c Directory Properties: stable/9/sys/ (props changed) Modified: stable/9/sys/amd64/amd64/pmap.c ============================================================================== --- stable/9/sys/amd64/amd64/pmap.c Thu Sep 20 15:53:55 2012 (r240753) +++ stable/9/sys/amd64/amd64/pmap.c Thu Sep 20 16:03:04 2012 (r240754) @@ -4998,7 +4998,7 @@ pmap_mapbios(vm_paddr_t pa, vm_size_t si void pmap_unmapdev(vm_offset_t va, vm_size_t size) { - vm_offset_t base, offset, tmpva; + vm_offset_t base, offset; /* If we gave a direct map region in pmap_mapdev, do nothing */ if (va >= DMAP_MIN_ADDRESS && va < DMAP_MAX_ADDRESS) @@ -5006,9 +5006,6 @@ pmap_unmapdev(vm_offset_t va, vm_size_t base = trunc_page(va); offset = va & PAGE_MASK; size = roundup(offset + size, PAGE_SIZE); - for (tmpva = base; tmpva < (base + size); tmpva += PAGE_SIZE) - pmap_kremove(tmpva); - pmap_invalidate_range(kernel_pmap, va, tmpva); kmem_free(kernel_map, base, size); } Modified: stable/9/sys/i386/i386/pmap.c ============================================================================== --- stable/9/sys/i386/i386/pmap.c Thu Sep 20 15:53:55 2012 (r240753) +++ stable/9/sys/i386/i386/pmap.c Thu Sep 20 16:03:04 2012 (r240754) @@ -5011,16 +5011,13 @@ pmap_mapbios(vm_paddr_t pa, vm_size_t si void pmap_unmapdev(vm_offset_t va, vm_size_t size) { - vm_offset_t base, offset, tmpva; + vm_offset_t base, offset; if (va >= KERNBASE && va + size <= KERNBASE + KERNLOAD) return; base = trunc_page(va); offset = va & PAGE_MASK; size = roundup(offset + size, PAGE_SIZE); - for (tmpva = base; tmpva < (base + size); tmpva += PAGE_SIZE) - pmap_kremove(tmpva); - pmap_invalidate_range(kernel_pmap, va, tmpva); kmem_free(kernel_map, base, size); } Modified: stable/9/sys/i386/xen/pmap.c ============================================================================== --- stable/9/sys/i386/xen/pmap.c Thu Sep 20 15:53:55 2012 (r240753) +++ stable/9/sys/i386/xen/pmap.c Thu Sep 20 16:03:04 2012 (r240754) @@ -3992,18 +3992,13 @@ pmap_mapbios(vm_paddr_t pa, vm_size_t si void pmap_unmapdev(vm_offset_t va, vm_size_t size) { - vm_offset_t base, offset, tmpva; + vm_offset_t base, offset; if (va >= KERNBASE && va + size <= KERNBASE + KERNLOAD) return; base = trunc_page(va); offset = va & PAGE_MASK; size = roundup(offset + size, PAGE_SIZE); - critical_enter(); - for (tmpva = base; tmpva < (base + size); tmpva += PAGE_SIZE) - pmap_kremove(tmpva); - pmap_invalidate_range(kernel_pmap, va, tmpva); - critical_exit(); kmem_free(kernel_map, base, size); } Modified: stable/9/sys/mips/mips/pmap.c ============================================================================== --- stable/9/sys/mips/mips/pmap.c Thu Sep 20 15:53:55 2012 (r240753) +++ stable/9/sys/mips/mips/pmap.c Thu Sep 20 16:03:04 2012 (r240754) @@ -837,10 +837,10 @@ pmap_kenter_attr(vm_offset_t va, vm_padd #ifdef PMAP_DEBUG printf("pmap_kenter: va: %p -> pa: %p\n", (void *)va, (void *)pa); #endif - npte = TLBLO_PA_TO_PFN(pa) | PTE_D | PTE_V | PTE_G | PTE_W | attr; pte = pmap_pte(kernel_pmap, va); opte = *pte; + npte = TLBLO_PA_TO_PFN(pa) | attr | PTE_D | PTE_V | PTE_G; *pte = npte; if (pte_test(&opte, PTE_V) && opte != npte) pmap_update_page(kernel_pmap, va, npte); @@ -2877,7 +2877,7 @@ void pmap_unmapdev(vm_offset_t va, vm_size_t size) { #ifndef __mips_n64 - vm_offset_t base, offset, tmpva; + vm_offset_t base, offset; /* If the address is within KSEG1 then there is nothing to do */ if (va >= MIPS_KSEG1_START && va <= MIPS_KSEG1_END) @@ -2886,8 +2886,6 @@ pmap_unmapdev(vm_offset_t va, vm_size_t base = trunc_page(va); offset = va & PAGE_MASK; size = roundup(size + offset, PAGE_SIZE); - for (tmpva = base; tmpva < base + size; tmpva += PAGE_SIZE) - pmap_kremove(tmpva); kmem_free(kernel_map, base, size); #endif } From owner-svn-src-stable@FreeBSD.ORG Thu Sep 20 16:27:22 2012 Return-Path: Delivered-To: svn-src-stable@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 608FA1065673; Thu, 20 Sep 2012 16:27:22 +0000 (UTC) (envelope-from issyl0@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 4B5168FC08; Thu, 20 Sep 2012 16:27:22 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q8KGRMpT052467; Thu, 20 Sep 2012 16:27:22 GMT (envelope-from issyl0@svn.freebsd.org) Received: (from issyl0@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q8KGRMBI052465; Thu, 20 Sep 2012 16:27:22 GMT (envelope-from issyl0@svn.freebsd.org) Message-Id: <201209201627.q8KGRMBI052465@svn.freebsd.org> From: Isabell Long Date: Thu, 20 Sep 2012 16:27:22 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r240755 - stable/9/usr.sbin/adduser X-BeenThere: svn-src-stable@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for all the -stable branches of the src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 20 Sep 2012 16:27:22 -0000 Author: issyl0 (doc committer) Date: Thu Sep 20 16:27:21 2012 New Revision: 240755 URL: http://svn.freebsd.org/changeset/base/240755 Log: MFC r240530 from HEAD: - Remove a reference to CVS and freefall from a user-facing man page. PR: docs/171658 Approved by: gabor (mentor) Modified: stable/9/usr.sbin/adduser/adduser.8 Directory Properties: stable/9/usr.sbin/adduser/ (props changed) Modified: stable/9/usr.sbin/adduser/adduser.8 ============================================================================== --- stable/9/usr.sbin/adduser/adduser.8 Thu Sep 20 16:03:04 2012 (r240754) +++ stable/9/usr.sbin/adduser/adduser.8 Thu Sep 20 16:27:21 2012 (r240755) @@ -26,7 +26,7 @@ .\" .\" $FreeBSD$ .\" -.Dd March 16, 2008 +.Dd September 15, 2012 .Dt ADDUSER 8 .Os .Sh NAME @@ -129,9 +129,8 @@ they can safely run with a umask of 002 and create files in their home directory without worrying about others being able to change them. .Pp -For a shared area you create a separate UID/GID (like cvs or ncvs on freefall), -you place each person that should be able to access this area into that new -group. +For a shared area you create a separate UID/GID, you place each person +that should be able to access this area into that new group. .Pp This model of UID/GID administration allows far greater flexibility than lumping users into groups and having to muck with the umask when working in a shared From owner-svn-src-stable@FreeBSD.ORG Thu Sep 20 17:02:05 2012 Return-Path: Delivered-To: svn-src-stable@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 5ED27106566C; Thu, 20 Sep 2012 17:02:05 +0000 (UTC) (envelope-from alc@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 3FEB98FC12; Thu, 20 Sep 2012 17:02:05 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q8KH256V057348; Thu, 20 Sep 2012 17:02:05 GMT (envelope-from alc@svn.freebsd.org) Received: (from alc@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q8KH25ha057346; Thu, 20 Sep 2012 17:02:05 GMT (envelope-from alc@svn.freebsd.org) Message-Id: <201209201702.q8KH25ha057346@svn.freebsd.org> From: Alan Cox Date: Thu, 20 Sep 2012 17:02:05 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r240757 - stable/9/sys/vm X-BeenThere: svn-src-stable@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for all the -stable branches of the src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 20 Sep 2012 17:02:05 -0000 Author: alc Date: Thu Sep 20 17:02:04 2012 New Revision: 240757 URL: http://svn.freebsd.org/changeset/base/240757 Log: MFC r238456 and r238536 Various improvements to vm_contig_grow_cache(). Modified: stable/9/sys/vm/vm_contig.c Directory Properties: stable/9/sys/ (props changed) Modified: stable/9/sys/vm/vm_contig.c ============================================================================== --- stable/9/sys/vm/vm_contig.c Thu Sep 20 16:36:58 2012 (r240756) +++ stable/9/sys/vm/vm_contig.c Thu Sep 20 17:02:04 2012 (r240757) @@ -64,6 +64,7 @@ __FBSDID("$FreeBSD$"); #include #include +#include #include #include #include @@ -87,7 +88,7 @@ __FBSDID("$FreeBSD$"); #include static int -vm_contig_launder_page(vm_page_t m, vm_page_t *next) +vm_contig_launder_page(vm_page_t m, vm_page_t *next, int tries) { vm_object_t object; vm_page_t m_tmp; @@ -96,7 +97,10 @@ vm_contig_launder_page(vm_page_t m, vm_p int vfslocked; mtx_assert(&vm_page_queue_mtx, MA_OWNED); - vm_page_lock_assert(m, MA_OWNED); + if (!vm_pageout_page_lock(m, next) || m->hold_count != 0) { + vm_page_unlock(m); + return (EAGAIN); + } object = m->object; if (!VM_OBJECT_TRYLOCK(object) && (!vm_pageout_fallback_object_lock(m, next) || m->hold_count != 0)) { @@ -104,7 +108,13 @@ vm_contig_launder_page(vm_page_t m, vm_p VM_OBJECT_UNLOCK(object); return (EAGAIN); } - if (vm_page_sleep_if_busy(m, TRUE, "vpctw0")) { + if ((m->oflags & VPO_BUSY) != 0 || m->busy != 0) { + if (tries == 0) { + vm_page_unlock(m); + VM_OBJECT_UNLOCK(object); + return (EAGAIN); + } + vm_page_sleep(m, "vpctw0"); VM_OBJECT_UNLOCK(object); vm_page_lock_queues(); return (EBUSY); @@ -114,7 +124,7 @@ vm_contig_launder_page(vm_page_t m, vm_p pmap_remove_all(m); if (m->dirty != 0) { vm_page_unlock(m); - if ((object->flags & OBJ_DEAD) != 0) { + if (tries == 0 || (object->flags & OBJ_DEAD) != 0) { VM_OBJECT_UNLOCK(object); return (EAGAIN); } @@ -150,34 +160,25 @@ vm_contig_launder_page(vm_page_t m, vm_p vm_page_unlock(m); } VM_OBJECT_UNLOCK(object); - return (0); + return (EAGAIN); } static int -vm_contig_launder(int queue, vm_paddr_t low, vm_paddr_t high) +vm_contig_launder(int queue, int tries, vm_paddr_t low, vm_paddr_t high) { vm_page_t m, next; vm_paddr_t pa; int error; TAILQ_FOREACH_SAFE(m, &vm_page_queues[queue].pl, pageq, next) { - - /* Skip marker pages */ + KASSERT(m->queue == queue, + ("vm_contig_launder: page %p's queue is not %d", m, queue)); if ((m->flags & PG_MARKER) != 0) continue; - pa = VM_PAGE_TO_PHYS(m); if (pa < low || pa + PAGE_SIZE > high) continue; - - if (!vm_pageout_page_lock(m, &next) || m->hold_count != 0) { - vm_page_unlock(m); - continue; - } - KASSERT(m->queue == queue, - ("vm_contig_launder: page %p's queue is not %d", m, queue)); - error = vm_contig_launder_page(m, &next); - vm_page_lock_assert(m, MA_NOTOWNED); + error = vm_contig_launder_page(m, &next, tries); if (error == 0) return (TRUE); if (error == EBUSY) @@ -203,24 +204,47 @@ vm_page_release_contig(vm_page_t m, vm_p } /* - * Increase the number of cached pages. + * Increase the number of cached pages. The specified value, "tries", + * determines which categories of pages are cached: + * + * 0: All clean, inactive pages within the specified physical address range + * are cached. Will not sleep. + * 1: The vm_lowmem handlers are called. All inactive pages within + * the specified physical address range are cached. May sleep. + * 2: The vm_lowmem handlers are called. All inactive and active pages + * within the specified physical address range are cached. May sleep. */ void vm_contig_grow_cache(int tries, vm_paddr_t low, vm_paddr_t high) { int actl, actmax, inactl, inactmax; + if (tries > 0) { + /* + * Decrease registered cache sizes. The vm_lowmem handlers + * may acquire locks and/or sleep, so they can only be invoked + * when "tries" is greater than zero. + */ + EVENTHANDLER_INVOKE(vm_lowmem, 0); + + /* + * We do this explicitly after the caches have been drained + * above. + */ + uma_reclaim(); + } vm_page_lock_queues(); inactl = 0; - inactmax = tries < 1 ? 0 : cnt.v_inactive_count; + inactmax = cnt.v_inactive_count; actl = 0; actmax = tries < 2 ? 0 : cnt.v_active_count; again: - if (inactl < inactmax && vm_contig_launder(PQ_INACTIVE, low, high)) { + if (inactl < inactmax && vm_contig_launder(PQ_INACTIVE, tries, low, + high)) { inactl++; goto again; } - if (actl < actmax && vm_contig_launder(PQ_ACTIVE, low, high)) { + if (actl < actmax && vm_contig_launder(PQ_ACTIVE, tries, low, high)) { actl++; goto again; } From owner-svn-src-stable@FreeBSD.ORG Thu Sep 20 17:39:07 2012 Return-Path: Delivered-To: svn-src-stable@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 9036A106566C; Thu, 20 Sep 2012 17:39:07 +0000 (UTC) (envelope-from issyl0@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 7A0C28FC17; Thu, 20 Sep 2012 17:39:07 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q8KHd7Rq062674; Thu, 20 Sep 2012 17:39:07 GMT (envelope-from issyl0@svn.freebsd.org) Received: (from issyl0@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q8KHd7Rv062672; Thu, 20 Sep 2012 17:39:07 GMT (envelope-from issyl0@svn.freebsd.org) Message-Id: <201209201739.q8KHd7Rv062672@svn.freebsd.org> From: Isabell Long Date: Thu, 20 Sep 2012 17:39:07 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-8@freebsd.org X-SVN-Group: stable-8 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r240759 - stable/8/usr.sbin/adduser X-BeenThere: svn-src-stable@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for all the -stable branches of the src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 20 Sep 2012 17:39:07 -0000 Author: issyl0 (doc committer) Date: Thu Sep 20 17:39:07 2012 New Revision: 240759 URL: http://svn.freebsd.org/changeset/base/240759 Log: MFC r240530 from HEAD: - Remove a reference to CVS and freefall from a user-facing man page. PR: docs/171658 Approved by: gabor (mentor) Modified: stable/8/usr.sbin/adduser/adduser.8 Directory Properties: stable/8/usr.sbin/adduser/ (props changed) Modified: stable/8/usr.sbin/adduser/adduser.8 ============================================================================== --- stable/8/usr.sbin/adduser/adduser.8 Thu Sep 20 17:30:26 2012 (r240758) +++ stable/8/usr.sbin/adduser/adduser.8 Thu Sep 20 17:39:07 2012 (r240759) @@ -26,7 +26,7 @@ .\" .\" $FreeBSD$ .\" -.Dd March 16, 2008 +.Dd September 15, 2012 .Dt ADDUSER 8 .Os .Sh NAME @@ -129,9 +129,8 @@ they can safely run with a umask of 002 and create files in their home directory without worrying about others being able to change them. .Pp -For a shared area you create a separate UID/GID (like cvs or ncvs on freefall), -you place each person that should be able to access this area into that new -group. +For a shared area you create a separate UID/GID, you place each person +that should be able to access this area into that new group. .Pp This model of UID/GID administration allows far greater flexibility than lumping users into groups and having to muck with the umask when working in a shared From owner-svn-src-stable@FreeBSD.ORG Thu Sep 20 18:21:30 2012 Return-Path: Delivered-To: svn-src-stable@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 9110C106566B; Thu, 20 Sep 2012 18:21:30 +0000 (UTC) (envelope-from alc@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 7978D8FC0A; Thu, 20 Sep 2012 18:21:30 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q8KILUis069311; Thu, 20 Sep 2012 18:21:30 GMT (envelope-from alc@svn.freebsd.org) Received: (from alc@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q8KILUMV069297; Thu, 20 Sep 2012 18:21:30 GMT (envelope-from alc@svn.freebsd.org) Message-Id: <201209201821.q8KILUMV069297@svn.freebsd.org> From: Alan Cox Date: Thu, 20 Sep 2012 18:21:30 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r240760 - in stable/9/sys: amd64/include arm/include i386/include ia64/include mips/include powerpc/include sparc64/include vm X-BeenThere: svn-src-stable@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for all the -stable branches of the src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 20 Sep 2012 18:21:30 -0000 Author: alc Date: Thu Sep 20 18:21:29 2012 New Revision: 240760 URL: http://svn.freebsd.org/changeset/base/240760 Log: MFC r237168 The page flag PGA_WRITEABLE is set and cleared exclusively by the pmap layer, but it is read directly by the MI VM layer. This change introduces pmap_page_is_write_mapped() in order to completely encapsulate all direct access to PGA_WRITEABLE in the pmap layer. Modified: stable/9/sys/amd64/include/pmap.h stable/9/sys/arm/include/pmap.h stable/9/sys/i386/include/pmap.h stable/9/sys/ia64/include/pmap.h stable/9/sys/mips/include/pmap.h stable/9/sys/powerpc/include/pmap.h stable/9/sys/sparc64/include/pmap.h stable/9/sys/vm/pmap.h stable/9/sys/vm/swap_pager.c stable/9/sys/vm/vm_page.c stable/9/sys/vm/vm_page.h stable/9/sys/vm/vm_pageout.c stable/9/sys/vm/vnode_pager.c Directory Properties: stable/9/sys/ (props changed) Modified: stable/9/sys/amd64/include/pmap.h ============================================================================== --- stable/9/sys/amd64/include/pmap.h Thu Sep 20 17:39:07 2012 (r240759) +++ stable/9/sys/amd64/include/pmap.h Thu Sep 20 18:21:29 2012 (r240760) @@ -309,6 +309,7 @@ extern vm_offset_t virtual_avail; extern vm_offset_t virtual_end; #define pmap_page_get_memattr(m) ((vm_memattr_t)(m)->md.pat_mode) +#define pmap_page_is_write_mapped(m) (((m)->aflags & PGA_WRITEABLE) != 0) #define pmap_unmapbios(va, sz) pmap_unmapdev((va), (sz)) void pmap_bootstrap(vm_paddr_t *); Modified: stable/9/sys/arm/include/pmap.h ============================================================================== --- stable/9/sys/arm/include/pmap.h Thu Sep 20 17:39:07 2012 (r240759) +++ stable/9/sys/arm/include/pmap.h Thu Sep 20 18:21:29 2012 (r240760) @@ -78,6 +78,7 @@ #define pmap_page_get_memattr(m) VM_MEMATTR_DEFAULT #define pmap_page_is_mapped(m) (!TAILQ_EMPTY(&(m)->md.pv_list)) +#define pmap_page_is_write_mapped(m) (((m)->aflags & PGA_WRITEABLE) != 0) #define pmap_page_set_memattr(m, ma) (void)0 /* Modified: stable/9/sys/i386/include/pmap.h ============================================================================== --- stable/9/sys/i386/include/pmap.h Thu Sep 20 17:39:07 2012 (r240759) +++ stable/9/sys/i386/include/pmap.h Thu Sep 20 18:21:29 2012 (r240760) @@ -498,6 +498,7 @@ extern vm_offset_t virtual_avail; extern vm_offset_t virtual_end; #define pmap_page_get_memattr(m) ((vm_memattr_t)(m)->md.pat_mode) +#define pmap_page_is_write_mapped(m) (((m)->aflags & PGA_WRITEABLE) != 0) #define pmap_unmapbios(va, sz) pmap_unmapdev((va), (sz)) /* Modified: stable/9/sys/ia64/include/pmap.h ============================================================================== --- stable/9/sys/ia64/include/pmap.h Thu Sep 20 17:39:07 2012 (r240759) +++ stable/9/sys/ia64/include/pmap.h Thu Sep 20 18:21:29 2012 (r240760) @@ -118,6 +118,7 @@ extern int pmap_vhpt_log2size; #define pmap_page_get_memattr(m) ((m)->md.memattr) #define pmap_page_is_mapped(m) (!TAILQ_EMPTY(&(m)->md.pv_list)) +#define pmap_page_is_write_mapped(m) (((m)->aflags & PGA_WRITEABLE) != 0) #define pmap_mapbios(pa, sz) pmap_mapdev(pa, sz) #define pmap_unmapbios(va, sz) pmap_unmapdev(va, sz) Modified: stable/9/sys/mips/include/pmap.h ============================================================================== --- stable/9/sys/mips/include/pmap.h Thu Sep 20 17:39:07 2012 (r240759) +++ stable/9/sys/mips/include/pmap.h Thu Sep 20 18:21:29 2012 (r240760) @@ -151,6 +151,7 @@ extern vm_paddr_t dump_avail[PHYS_AVAIL_ #define pmap_page_get_memattr(m) VM_MEMATTR_DEFAULT #define pmap_page_is_mapped(m) (!TAILQ_EMPTY(&(m)->md.pv_list)) +#define pmap_page_is_write_mapped(m) (((m)->aflags & PGA_WRITEABLE) != 0) #define pmap_page_set_memattr(m, ma) (void)0 void pmap_bootstrap(void); Modified: stable/9/sys/powerpc/include/pmap.h ============================================================================== --- stable/9/sys/powerpc/include/pmap.h Thu Sep 20 17:39:07 2012 (r240759) +++ stable/9/sys/powerpc/include/pmap.h Thu Sep 20 18:21:29 2012 (r240760) @@ -220,6 +220,8 @@ extern struct pmap kernel_pmap_store; #define PMAP_TRYLOCK(pmap) mtx_trylock(&(pmap)->pm_mtx) #define PMAP_UNLOCK(pmap) mtx_unlock(&(pmap)->pm_mtx) +#define pmap_page_is_write_mapped(m) (((m)->aflags & PGA_WRITEABLE) != 0) + void pmap_bootstrap(vm_offset_t, vm_offset_t); void pmap_kenter(vm_offset_t va, vm_offset_t pa); void pmap_kenter_attr(vm_offset_t va, vm_offset_t pa, vm_memattr_t); Modified: stable/9/sys/sparc64/include/pmap.h ============================================================================== --- stable/9/sys/sparc64/include/pmap.h Thu Sep 20 17:39:07 2012 (r240759) +++ stable/9/sys/sparc64/include/pmap.h Thu Sep 20 18:21:29 2012 (r240760) @@ -85,6 +85,7 @@ struct tte_list_lock { #define PMAP_UNLOCK(pmap) mtx_unlock(&(pmap)->pm_mtx) #define pmap_page_get_memattr(m) VM_MEMATTR_DEFAULT +#define pmap_page_is_write_mapped(m) (((m)->aflags & PGA_WRITEABLE) != 0) #define pmap_page_set_memattr(m, ma) (void)0 void pmap_bootstrap(u_int cpu_impl); Modified: stable/9/sys/vm/pmap.h ============================================================================== --- stable/9/sys/vm/pmap.h Thu Sep 20 17:39:07 2012 (r240759) +++ stable/9/sys/vm/pmap.h Thu Sep 20 18:21:29 2012 (r240760) @@ -80,10 +80,11 @@ struct pmap_statistics { typedef struct pmap_statistics *pmap_statistics_t; /* - * Each machine dependent implementation is expected to provide: + * Each machine-dependent implementation is required to provide: * * vm_memattr_t pmap_page_get_memattr(vm_page_t); * boolean_t pmap_page_is_mapped(vm_page_t); + * boolean_t pmap_page_is_write_mapped(vm_page_t); * void pmap_page_set_memattr(vm_page_t, vm_memattr_t); */ #include Modified: stable/9/sys/vm/swap_pager.c ============================================================================== --- stable/9/sys/vm/swap_pager.c Thu Sep 20 17:39:07 2012 (r240759) +++ stable/9/sys/vm/swap_pager.c Thu Sep 20 18:21:29 2012 (r240760) @@ -1593,7 +1593,7 @@ swp_pager_async_iodone(struct buf *bp) * status, then finish the I/O ( which decrements the * busy count and possibly wakes waiter's up ). */ - KASSERT((m->aflags & PGA_WRITEABLE) == 0, + KASSERT(!pmap_page_is_write_mapped(m), ("swp_pager_async_iodone: page %p is not write" " protected", m)); vm_page_undirty(m); Modified: stable/9/sys/vm/vm_page.c ============================================================================== --- stable/9/sys/vm/vm_page.c Thu Sep 20 17:39:07 2012 (r240759) +++ stable/9/sys/vm/vm_page.c Thu Sep 20 18:21:29 2012 (r240760) @@ -965,7 +965,7 @@ vm_page_insert(vm_page_t m, vm_object_t * Since we are inserting a new and possibly dirty page, * update the object's OBJ_MIGHTBEDIRTY flag. */ - if (m->aflags & PGA_WRITEABLE) + if (pmap_page_is_write_mapped(m)) vm_object_set_writeable_dirty(object); } @@ -2504,11 +2504,11 @@ vm_page_clear_dirty_mask(vm_page_t m, vm /* * If the object is locked and the page is neither VPO_BUSY nor - * PGA_WRITEABLE, then the page's dirty field cannot possibly be + * write mapped, then the page's dirty field cannot possibly be * set by a concurrent pmap operation. */ VM_OBJECT_LOCK_ASSERT(m->object, MA_OWNED); - if ((m->oflags & VPO_BUSY) == 0 && (m->aflags & PGA_WRITEABLE) == 0) + if ((m->oflags & VPO_BUSY) == 0 && !pmap_page_is_write_mapped(m)) m->dirty &= ~pagebits; else { /* Modified: stable/9/sys/vm/vm_page.h ============================================================================== --- stable/9/sys/vm/vm_page.h Thu Sep 20 17:39:07 2012 (r240759) +++ stable/9/sys/vm/vm_page.h Thu Sep 20 18:21:29 2012 (r240760) @@ -237,20 +237,22 @@ extern struct vpglocks pa_lock[]; #endif #define vm_page_queue_free_mtx vm_page_queue_free_lock.data + /* * These are the flags defined for vm_page. * - * aflags are updated by atomic accesses. Use the vm_page_aflag_set() + * aflags are updated by atomic accesses. Use the vm_page_aflag_set() * and vm_page_aflag_clear() functions to set and clear the flags. * * PGA_REFERENCED may be cleared only if the object containing the page is - * locked. + * locked. It is set by both the MI and MD VM layers. * * PGA_WRITEABLE is set exclusively on managed pages by pmap_enter(). When it - * does so, the page must be VPO_BUSY. + * does so, the page must be VPO_BUSY. The MI VM layer must never access this + * flag directly. Instead, it should call pmap_page_is_write_mapped(). * * PGA_EXECUTABLE may be set by pmap routines, and indicates that a page has - * at least one executable mapping. It is not consumed by the VM layer. + * at least one executable mapping. It is not consumed by the MI VM layer. */ #define PGA_WRITEABLE 0x01 /* page may be mapped writeable */ #define PGA_REFERENCED 0x02 /* page has been referenced */ @@ -262,12 +264,12 @@ extern struct vpglocks pa_lock[]; */ #define PG_CACHED 0x01 /* page is cached */ #define PG_FREE 0x02 /* page is free */ -#define PG_FICTITIOUS 0x04 /* physical page doesn't exist (O) */ +#define PG_FICTITIOUS 0x04 /* physical page doesn't exist */ #define PG_ZERO 0x08 /* page is zeroed */ #define PG_MARKER 0x10 /* special queue marker page */ #define PG_SLAB 0x20 /* object pointer is actually a slab */ #define PG_WINATCFLS 0x40 /* flush dirty page on inactive q */ -#define PG_NODUMP 0x80 /* don't include this page in the dump */ +#define PG_NODUMP 0x80 /* don't include this page in a dump */ /* * Misc constants. Modified: stable/9/sys/vm/vm_pageout.c ============================================================================== --- stable/9/sys/vm/vm_pageout.c Thu Sep 20 17:39:07 2012 (r240759) +++ stable/9/sys/vm/vm_pageout.c Thu Sep 20 18:21:29 2012 (r240760) @@ -503,7 +503,7 @@ vm_pageout_flush(vm_page_t *mc, int coun vm_page_t mt = mc[i]; KASSERT(pageout_status[i] == VM_PAGER_PEND || - (mt->aflags & PGA_WRITEABLE) == 0, + !pmap_page_is_write_mapped(mt), ("vm_pageout_flush: page %p is not write protected", mt)); switch (pageout_status[i]) { case VM_PAGER_OK: @@ -922,7 +922,7 @@ vm_pageout_scan(int pass) * be updated. */ if (m->dirty != VM_PAGE_BITS_ALL && - (m->aflags & PGA_WRITEABLE) != 0) { + pmap_page_is_write_mapped(m)) { /* * Avoid a race condition: Unless write access is * removed from the page, another processor could Modified: stable/9/sys/vm/vnode_pager.c ============================================================================== --- stable/9/sys/vm/vnode_pager.c Thu Sep 20 17:39:07 2012 (r240759) +++ stable/9/sys/vm/vnode_pager.c Thu Sep 20 18:21:29 2012 (r240760) @@ -1116,7 +1116,7 @@ vnode_pager_generic_putpages(struct vnod m = ma[ncount - 1]; KASSERT(m->busy > 0, ("vnode_pager_generic_putpages: page %p is not busy", m)); - KASSERT((m->aflags & PGA_WRITEABLE) == 0, + KASSERT(!pmap_page_is_write_mapped(m), ("vnode_pager_generic_putpages: page %p is not read-only", m)); vm_page_clear_dirty(m, pgoff, PAGE_SIZE - pgoff); From owner-svn-src-stable@FreeBSD.ORG Thu Sep 20 18:59:51 2012 Return-Path: Delivered-To: svn-src-stable@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 8027F106564A; Thu, 20 Sep 2012 18:59:51 +0000 (UTC) (envelope-from mav@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 6C0988FC1F; Thu, 20 Sep 2012 18:59:51 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q8KIxp7g075982; Thu, 20 Sep 2012 18:59:51 GMT (envelope-from mav@svn.freebsd.org) Received: (from mav@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q8KIxpOP075980; Thu, 20 Sep 2012 18:59:51 GMT (envelope-from mav@svn.freebsd.org) Message-Id: <201209201859.q8KIxpOP075980@svn.freebsd.org> From: Alexander Motin Date: Thu, 20 Sep 2012 18:59:51 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r240763 - stable/9/sys/dev/ahci X-BeenThere: svn-src-stable@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for all the -stable branches of the src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 20 Sep 2012 18:59:51 -0000 Author: mav Date: Thu Sep 20 18:59:50 2012 New Revision: 240763 URL: http://svn.freebsd.org/changeset/base/240763 Log: MFC r240383: Fix AHCI 1.2 version checks. This should be mostly cosmetic. Modified: stable/9/sys/dev/ahci/ahci.c Directory Properties: stable/9/sys/ (props changed) stable/9/sys/dev/ (props changed) Modified: stable/9/sys/dev/ahci/ahci.c ============================================================================== --- stable/9/sys/dev/ahci/ahci.c Thu Sep 20 18:56:27 2012 (r240762) +++ stable/9/sys/dev/ahci/ahci.c Thu Sep 20 18:59:50 2012 (r240763) @@ -409,7 +409,7 @@ ahci_attach(device_t dev) /* Get the HW capabilities */ version = ATA_INL(ctlr->r_mem, AHCI_VS); ctlr->caps = ATA_INL(ctlr->r_mem, AHCI_CAP); - if (version >= 0x00010020) + if (version >= 0x00010200) ctlr->caps2 = ATA_INL(ctlr->r_mem, AHCI_CAP2); if (ctlr->caps & AHCI_CAP_EMS) ctlr->capsem = ATA_INL(ctlr->r_mem, AHCI_EM_CTL); @@ -490,7 +490,7 @@ ahci_attach(device_t dev) (ctlr->caps & AHCI_CAP_SXS) ? " eSATA":"", (ctlr->caps & AHCI_CAP_NPMASK) + 1); } - if (bootverbose && version >= 0x00010020) { + if (bootverbose && version >= 0x00010200) { device_printf(dev, "Caps2:%s%s%s\n", (ctlr->caps2 & AHCI_CAP2_APST) ? " APST":"", (ctlr->caps2 & AHCI_CAP2_NVMP) ? " NVMP":"", @@ -975,7 +975,7 @@ ahci_ch_attach(device_t dev) } ch->chcaps = ATA_INL(ch->r_mem, AHCI_P_CMD); version = ATA_INL(ctlr->r_mem, AHCI_VS); - if (version < 0x00010020 && (ctlr->caps & AHCI_CAP_FBSS)) + if (version < 0x00010200 && (ctlr->caps & AHCI_CAP_FBSS)) ch->chcaps |= AHCI_P_CMD_FBSCP; if (bootverbose) { device_printf(dev, "Caps:%s%s%s%s%s\n", From owner-svn-src-stable@FreeBSD.ORG Thu Sep 20 19:05:24 2012 Return-Path: Delivered-To: svn-src-stable@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id D3516106566B; Thu, 20 Sep 2012 19:05:24 +0000 (UTC) (envelope-from mav@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id BDD9F8FC08; Thu, 20 Sep 2012 19:05:24 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q8KJ5OpH076964; Thu, 20 Sep 2012 19:05:24 GMT (envelope-from mav@svn.freebsd.org) Received: (from mav@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q8KJ5Ori076961; Thu, 20 Sep 2012 19:05:24 GMT (envelope-from mav@svn.freebsd.org) Message-Id: <201209201905.q8KJ5Ori076961@svn.freebsd.org> From: Alexander Motin Date: Thu, 20 Sep 2012 19:05:24 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-8@freebsd.org X-SVN-Group: stable-8 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r240764 - stable/8/sys/dev/ahci X-BeenThere: svn-src-stable@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for all the -stable branches of the src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 20 Sep 2012 19:05:25 -0000 Author: mav Date: Thu Sep 20 19:05:24 2012 New Revision: 240764 URL: http://svn.freebsd.org/changeset/base/240764 Log: MFC r240383: Fix AHCI 1.2 version checks. This should be mostly cosmetic. Modified: stable/8/sys/dev/ahci/ahci.c Directory Properties: stable/8/sys/ (props changed) stable/8/sys/dev/ (props changed) stable/8/sys/dev/ahci/ (props changed) Modified: stable/8/sys/dev/ahci/ahci.c ============================================================================== --- stable/8/sys/dev/ahci/ahci.c Thu Sep 20 18:59:50 2012 (r240763) +++ stable/8/sys/dev/ahci/ahci.c Thu Sep 20 19:05:24 2012 (r240764) @@ -408,7 +408,7 @@ ahci_attach(device_t dev) /* Get the HW capabilities */ version = ATA_INL(ctlr->r_mem, AHCI_VS); ctlr->caps = ATA_INL(ctlr->r_mem, AHCI_CAP); - if (version >= 0x00010020) + if (version >= 0x00010200) ctlr->caps2 = ATA_INL(ctlr->r_mem, AHCI_CAP2); if (ctlr->caps & AHCI_CAP_EMS) ctlr->capsem = ATA_INL(ctlr->r_mem, AHCI_EM_CTL); @@ -489,7 +489,7 @@ ahci_attach(device_t dev) (ctlr->caps & AHCI_CAP_SXS) ? " eSATA":"", (ctlr->caps & AHCI_CAP_NPMASK) + 1); } - if (bootverbose && version >= 0x00010020) { + if (bootverbose && version >= 0x00010200) { device_printf(dev, "Caps2:%s%s%s\n", (ctlr->caps2 & AHCI_CAP2_APST) ? " APST":"", (ctlr->caps2 & AHCI_CAP2_NVMP) ? " NVMP":"", @@ -972,7 +972,7 @@ ahci_ch_attach(device_t dev) } ch->chcaps = ATA_INL(ch->r_mem, AHCI_P_CMD); version = ATA_INL(ctlr->r_mem, AHCI_VS); - if (version < 0x00010020 && (ctlr->caps & AHCI_CAP_FBSS)) + if (version < 0x00010200 && (ctlr->caps & AHCI_CAP_FBSS)) ch->chcaps |= AHCI_P_CMD_FBSCP; if (bootverbose) { device_printf(dev, "Caps:%s%s%s%s%s\n", From owner-svn-src-stable@FreeBSD.ORG Fri Sep 21 00:36:35 2012 Return-Path: Delivered-To: svn-src-stable@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id AD75E106564A; Fri, 21 Sep 2012 00:36:35 +0000 (UTC) (envelope-from mjacob@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 9772E8FC0C; Fri, 21 Sep 2012 00:36:35 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q8L0aZVg022761; Fri, 21 Sep 2012 00:36:35 GMT (envelope-from mjacob@svn.freebsd.org) Received: (from mjacob@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q8L0aZpd022759; Fri, 21 Sep 2012 00:36:35 GMT (envelope-from mjacob@svn.freebsd.org) Message-Id: <201209210036.q8L0aZpd022759@svn.freebsd.org> From: Matt Jacob Date: Fri, 21 Sep 2012 00:36:35 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r240769 - stable/9/sys/dev/isp X-BeenThere: svn-src-stable@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for all the -stable branches of the src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 21 Sep 2012 00:36:35 -0000 Author: mjacob Date: Fri Sep 21 00:36:35 2012 New Revision: 240769 URL: http://svn.freebsd.org/changeset/base/240769 Log: MFC of 240219 - remove useless test. Modified: stable/9/sys/dev/isp/isp_pci.c Directory Properties: stable/9/sys/ (props changed) stable/9/sys/dev/ (props changed) stable/9/sys/dev/isp/ (props changed) Modified: stable/9/sys/dev/isp/isp_pci.c ============================================================================== --- stable/9/sys/dev/isp/isp_pci.c Thu Sep 20 23:44:13 2012 (r240768) +++ stable/9/sys/dev/isp/isp_pci.c Fri Sep 21 00:36:35 2012 (r240769) @@ -1268,8 +1268,7 @@ isp_pci_rd_reg_1080(ispsoftc_t *isp, int { uint32_t rv, oc = 0; - if ((regoff & _BLK_REG_MASK) == SXP_BLOCK || - (regoff & _BLK_REG_MASK) == (SXP_BLOCK|SXP_BANK1_SELECT)) { + if ((regoff & _BLK_REG_MASK) == SXP_BLOCK) { uint32_t tc; /* * We will assume that someone has paused the RISC processor. @@ -1301,8 +1300,7 @@ isp_pci_wr_reg_1080(ispsoftc_t *isp, int { int oc = 0; - if ((regoff & _BLK_REG_MASK) == SXP_BLOCK || - (regoff & _BLK_REG_MASK) == (SXP_BLOCK|SXP_BANK1_SELECT)) { + if ((regoff & _BLK_REG_MASK) == SXP_BLOCK) { uint32_t tc; /* * We will assume that someone has paused the RISC processor. From owner-svn-src-stable@FreeBSD.ORG Fri Sep 21 12:28:56 2012 Return-Path: Delivered-To: svn-src-stable@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id A0D33106564A; Fri, 21 Sep 2012 12:28:56 +0000 (UTC) (envelope-from jilles@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 716768FC1A; Fri, 21 Sep 2012 12:28:56 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q8LCSuLF033381; Fri, 21 Sep 2012 12:28:56 GMT (envelope-from jilles@svn.freebsd.org) Received: (from jilles@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q8LCSujN033379; Fri, 21 Sep 2012 12:28:56 GMT (envelope-from jilles@svn.freebsd.org) Message-Id: <201209211228.q8LCSujN033379@svn.freebsd.org> From: Jilles Tjoelker Date: Fri, 21 Sep 2012 12:28:56 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r240775 - stable/9/share/man/man3 X-BeenThere: svn-src-stable@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for all the -stable branches of the src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 21 Sep 2012 12:28:56 -0000 Author: jilles Date: Fri Sep 21 12:28:56 2012 New Revision: 240775 URL: http://svn.freebsd.org/changeset/base/240775 Log: MFC r240552: siginfo(3): Document SI_USER and SI_KERNEL signal codes. Modified: stable/9/share/man/man3/siginfo.3 Directory Properties: stable/9/share/man/man3/ (props changed) Modified: stable/9/share/man/man3/siginfo.3 ============================================================================== --- stable/9/share/man/man3/siginfo.3 Fri Sep 21 12:19:36 2012 (r240774) +++ stable/9/share/man/man3/siginfo.3 Fri Sep 21 12:28:56 2012 (r240775) @@ -27,7 +27,7 @@ .\" .\" $FreeBSD$ .\" -.Dd December 8, 2005 +.Dd September 14, 2012 .Dt SIGINFO 3 .Os .Sh NAME @@ -195,6 +195,8 @@ signal generated by expiration of a time signal generated by completion of an asynchronous I/O request .It Ta Dv SI_MESGQ Ta signal generated by arrival of a message on an empty message queue +.It Ta Dv SI_KERNEL Ta +signal generated by miscellaneous parts of the kernel .El .Pp In addition, the following signal-specific information is available: @@ -235,6 +237,10 @@ or Finally, the following code-specific information is available: .Bl -column ".Dv SI_QUEUE" ".Va si_overrun" .It Sy "Code Member Value" +.It Dv SI_USER Ta Va si_pid Ta +the process ID that sent the signal +.It Ta Va si_uid Ta +real user ID of the process that sent the signal .It Dv SI_QUEUE Ta Va si_value Ta the value passed to .Xr sigqueue 2 @@ -277,6 +283,14 @@ signal is queued when a process changed .Tn POSIX Realtime Extensions like aio, timer, and message queue also queue signals. +Signals with code +.Dv SI_USER +or +.Dv SI_KERNEL +are only queued if there are sufficient resources; +otherwise, +.Dv SI_NOINFO +results. For some hardware architectures, the exact value of .Va si_addr might not be available. @@ -289,7 +303,8 @@ might not be available. .Xr sigwaitinfo 2 , .Xr timer_create 2 , .Xr timer_settime 2 , -.Xr waitpid 2 +.Xr waitpid 2 , +.Xr pthread_kill 3 .Sh STANDARDS The .Vt siginfo_t @@ -300,6 +315,12 @@ Full support for .Tn POSIX signal information first appeared in .Fx 7.0 . +The codes +.Dv SI_USER +and +.Dv SI_KERNEL +can be generated as of +.Fx 8.1 . .Sh AUTHORS This manual page was written by .An "David Xu" Aq davidxu@FreeBSD.org . From owner-svn-src-stable@FreeBSD.ORG Fri Sep 21 12:31:37 2012 Return-Path: Delivered-To: svn-src-stable@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id E4828106564A; Fri, 21 Sep 2012 12:31:37 +0000 (UTC) (envelope-from jilles@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id CFBE98FC18; Fri, 21 Sep 2012 12:31:37 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q8LCVbBC033734; Fri, 21 Sep 2012 12:31:37 GMT (envelope-from jilles@svn.freebsd.org) Received: (from jilles@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q8LCVblT033732; Fri, 21 Sep 2012 12:31:37 GMT (envelope-from jilles@svn.freebsd.org) Message-Id: <201209211231.q8LCVblT033732@svn.freebsd.org> From: Jilles Tjoelker Date: Fri, 21 Sep 2012 12:31:37 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r240776 - stable/9/share/man/man3 X-BeenThere: svn-src-stable@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for all the -stable branches of the src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 21 Sep 2012 12:31:38 -0000 Author: jilles Date: Fri Sep 21 12:31:37 2012 New Revision: 240776 URL: http://svn.freebsd.org/changeset/base/240776 Log: MFC r240523: siginfo(3): Document SI_LWP signal code. Describe SI_LWP as being generated by pthread_kill() because thr_kill() is a private undocumented function. Modified: stable/9/share/man/man3/siginfo.3 Directory Properties: stable/9/share/man/man3/ (props changed) Modified: stable/9/share/man/man3/siginfo.3 ============================================================================== --- stable/9/share/man/man3/siginfo.3 Fri Sep 21 12:28:56 2012 (r240775) +++ stable/9/share/man/man3/siginfo.3 Fri Sep 21 12:31:37 2012 (r240776) @@ -197,6 +197,9 @@ signal generated by completion of an asy signal generated by arrival of a message on an empty message queue .It Ta Dv SI_KERNEL Ta signal generated by miscellaneous parts of the kernel +.It Ta Dv SI_LWP Ta +signal sent by +.Xr pthread_kill 3 .El .Pp In addition, the following signal-specific information is available: @@ -273,6 +276,10 @@ the value passed to system call .It Ta Va si_mqd Ta the ID of the message queue which generated the signal +.It Dv SI_LWP Ta Va si_pid Ta +the process ID that sent the signal +.It Ta Va si_uid Ta +real user ID of the process that sent the signal .El .Sh NOTES Currently, the kernel never generates the @@ -284,9 +291,10 @@ signal is queued when a process changed Realtime Extensions like aio, timer, and message queue also queue signals. Signals with code -.Dv SI_USER -or +.Dv SI_USER , .Dv SI_KERNEL +or +.Dv SI_LWP are only queued if there are sufficient resources; otherwise, .Dv SI_NOINFO @@ -321,6 +329,10 @@ and .Dv SI_KERNEL can be generated as of .Fx 8.1 . +The code +.Dv SI_LWP +can be generated as of +.Fx 9.0 . .Sh AUTHORS This manual page was written by .An "David Xu" Aq davidxu@FreeBSD.org . From owner-svn-src-stable@FreeBSD.ORG Fri Sep 21 12:33:25 2012 Return-Path: Delivered-To: svn-src-stable@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id A87231065678; Fri, 21 Sep 2012 12:33:25 +0000 (UTC) (envelope-from jilles@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 938C48FC0A; Fri, 21 Sep 2012 12:33:25 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q8LCXPkQ034065; Fri, 21 Sep 2012 12:33:25 GMT (envelope-from jilles@svn.freebsd.org) Received: (from jilles@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q8LCXPVN034063; Fri, 21 Sep 2012 12:33:25 GMT (envelope-from jilles@svn.freebsd.org) Message-Id: <201209211233.q8LCXPVN034063@svn.freebsd.org> From: Jilles Tjoelker Date: Fri, 21 Sep 2012 12:33:25 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r240777 - stable/9/share/man/man3 X-BeenThere: svn-src-stable@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for all the -stable branches of the src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 21 Sep 2012 12:33:25 -0000 Author: jilles Date: Fri Sep 21 12:33:25 2012 New Revision: 240777 URL: http://svn.freebsd.org/changeset/base/240777 Log: MFC r240524: siginfo(3): Document TRAP_DTRACE signal code. Modified: stable/9/share/man/man3/siginfo.3 Directory Properties: stable/9/share/man/man3/ (props changed) Modified: stable/9/share/man/man3/siginfo.3 ============================================================================== --- stable/9/share/man/man3/siginfo.3 Fri Sep 21 12:31:37 2012 (r240776) +++ stable/9/share/man/man3/siginfo.3 Fri Sep 21 12:33:25 2012 (r240777) @@ -154,6 +154,8 @@ object-specific hardware error process breakpoint .It Ta Dv TRAP_TRACE Ta process trace trap +.It Ta Dv TRAP_DTRACE Ta +DTrace induced trap .It Dv SIGCHLD Ta Dv CLD_EXITED Ta child has exited .It Ta Dv CLD_KILLED Ta From owner-svn-src-stable@FreeBSD.ORG Fri Sep 21 12:38:52 2012 Return-Path: Delivered-To: svn-src-stable@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id BAA16106566B; Fri, 21 Sep 2012 12:38:52 +0000 (UTC) (envelope-from jilles@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 8AD1F8FC0C; Fri, 21 Sep 2012 12:38:52 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q8LCcqZe034924; Fri, 21 Sep 2012 12:38:52 GMT (envelope-from jilles@svn.freebsd.org) Received: (from jilles@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q8LCcqFt034922; Fri, 21 Sep 2012 12:38:52 GMT (envelope-from jilles@svn.freebsd.org) Message-Id: <201209211238.q8LCcqFt034922@svn.freebsd.org> From: Jilles Tjoelker Date: Fri, 21 Sep 2012 12:38:52 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-8@freebsd.org X-SVN-Group: stable-8 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r240778 - stable/8/share/man/man3 X-BeenThere: svn-src-stable@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for all the -stable branches of the src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 21 Sep 2012 12:38:52 -0000 Author: jilles Date: Fri Sep 21 12:38:52 2012 New Revision: 240778 URL: http://svn.freebsd.org/changeset/base/240778 Log: siginfo(3): Document SI_USER and SI_KERNEL signal codes. Different from stable/9 and head, do not mention pthread_kill(3), which generates a different code (SI_USER) in stable/8. Modified: stable/8/share/man/man3/siginfo.3 Directory Properties: stable/8/share/man/man3/ (props changed) Modified: stable/8/share/man/man3/siginfo.3 ============================================================================== --- stable/8/share/man/man3/siginfo.3 Fri Sep 21 12:33:25 2012 (r240777) +++ stable/8/share/man/man3/siginfo.3 Fri Sep 21 12:38:52 2012 (r240778) @@ -27,7 +27,7 @@ .\" .\" $FreeBSD$ .\" -.Dd December 8, 2005 +.Dd September 14, 2012 .Dt SIGINFO 3 .Os .Sh NAME @@ -195,6 +195,8 @@ signal generated by expiration of a time signal generated by completion of an asynchronous I/O request .It Ta Dv SI_MESGQ Ta signal generated by arrival of a message on an empty message queue +.It Ta Dv SI_KERNEL Ta +signal generated by miscellaneous parts of the kernel .El .Pp In addition, the following signal-specific information is available: @@ -235,6 +237,10 @@ or Finally, the following code-specific information is available: .Bl -column ".Dv SI_QUEUE" ".Va si_overrun" .It Sy "Code Member Value" +.It Dv SI_USER Ta Va si_pid Ta +the process ID that sent the signal +.It Ta Va si_uid Ta +real user ID of the process that sent the signal .It Dv SI_QUEUE Ta Va si_value Ta the value passed to .Xr sigqueue 2 @@ -281,6 +287,14 @@ signal is queued when a process changed .Tn POSIX Realtime Extensions like aio, timer, and message queue also queue signals. +Signals with code +.Dv SI_USER +or +.Dv SI_KERNEL +are only queued if there are sufficient resources; +otherwise, +.Dv SI_NOINFO +results. For some hardware architectures, the exact value of .Va si_addr might not be available. @@ -304,6 +318,12 @@ Full support for .Tn POSIX signal information first appeared in .Fx 7.0 . +The codes +.Dv SI_USER +and +.Dv SI_KERNEL +can be generated as of +.Fx 8.1 . .Sh AUTHORS This manual page was written by .An "David Xu" Aq davidxu@FreeBSD.org . From owner-svn-src-stable@FreeBSD.ORG Fri Sep 21 12:40:32 2012 Return-Path: Delivered-To: svn-src-stable@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 6341A1065670; Fri, 21 Sep 2012 12:40:32 +0000 (UTC) (envelope-from jilles@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 4DF9B8FC15; Fri, 21 Sep 2012 12:40:32 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q8LCeW71035142; Fri, 21 Sep 2012 12:40:32 GMT (envelope-from jilles@svn.freebsd.org) Received: (from jilles@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q8LCeW2N035140; Fri, 21 Sep 2012 12:40:32 GMT (envelope-from jilles@svn.freebsd.org) Message-Id: <201209211240.q8LCeW2N035140@svn.freebsd.org> From: Jilles Tjoelker Date: Fri, 21 Sep 2012 12:40:32 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-8@freebsd.org X-SVN-Group: stable-8 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r240779 - stable/8/share/man/man3 X-BeenThere: svn-src-stable@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for all the -stable branches of the src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 21 Sep 2012 12:40:32 -0000 Author: jilles Date: Fri Sep 21 12:40:31 2012 New Revision: 240779 URL: http://svn.freebsd.org/changeset/base/240779 Log: MFC r240524: siginfo(3): Document TRAP_DTRACE signal code. Modified: stable/8/share/man/man3/siginfo.3 Directory Properties: stable/8/share/man/man3/ (props changed) Modified: stable/8/share/man/man3/siginfo.3 ============================================================================== --- stable/8/share/man/man3/siginfo.3 Fri Sep 21 12:38:52 2012 (r240778) +++ stable/8/share/man/man3/siginfo.3 Fri Sep 21 12:40:31 2012 (r240779) @@ -154,6 +154,8 @@ object-specific hardware error process breakpoint .It Ta Dv TRAP_TRACE Ta process trace trap +.It Ta Dv TRAP_DTRACE Ta +DTrace induced trap .It Dv SIGCHLD Ta Dv CLD_EXITED Ta child has exited .It Ta Dv CLD_KILLED Ta From owner-svn-src-stable@FreeBSD.ORG Sat Sep 22 04:18:43 2012 Return-Path: Delivered-To: svn-src-stable@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id D5DF4106566B; Sat, 22 Sep 2012 04:18:43 +0000 (UTC) (envelope-from pfg@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id BE8DF8FC0A; Sat, 22 Sep 2012 04:18:43 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q8M4Ih6d083083; Sat, 22 Sep 2012 04:18:43 GMT (envelope-from pfg@svn.freebsd.org) Received: (from pfg@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q8M4Ihkl083067; Sat, 22 Sep 2012 04:18:43 GMT (envelope-from pfg@svn.freebsd.org) Message-Id: <201209220418.q8M4Ihkl083067@svn.freebsd.org> From: "Pedro F. Giffuni" Date: Sat, 22 Sep 2012 04:18:43 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r240799 - in stable/9: include/rpc lib/libc/rpc sys/rpc X-BeenThere: svn-src-stable@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for all the -stable branches of the src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 22 Sep 2012 04:18:44 -0000 Author: pfg Date: Sat Sep 22 04:18:42 2012 New Revision: 240799 URL: http://svn.freebsd.org/changeset/base/240799 Log: MFC r239963: Bring some changes from Bull's NFSv4 libtirpc implementation. ____ Fixed infinite loop in svc_run() ____ __rpc_taddr2uaddr_af() assumes the netbuf to always have a non-zero data. This is a bad assumption and can lead to a seg-fault. This patch adds a check for zero length and returns NULL when found. ____ Changed clnt_spcreateerror() to return clearer and more concise error messages. ____ Converted all uid and gid variables of the type uid_t and gid_t. ____ libtirpc: set r_netid and r_owner in __rpcb_findaddr_timed These fields in the rpcbind GETADDR call are being passed uninitialized to CLNT_CALL. In the case of x86_64 at least, this usually leads to a segfault. On x86, it sometimes causes segfaults and other times causes garbage to be sent on the wire. rpcbind generally ignores the r_owner field for calls that come in over the wire, so it really doesn't matter what we send in that slot. We just need to send something. The reference implementation from Sun seems to send a blank string. Have ours follow suit. ____ libtirpc: be sure to free cl_netid and cl_tp When creating a client with clnt_tli_create, it uses strdup to copy strings for these fields if nconf is passed in. clnt_dg_destroy frees these strings already. Make sure clnt_vc_destroy frees them in the same way. ____ Obtained from: Bull GNU/Linux NFSv4 Project Modified: stable/9/include/rpc/auth.h stable/9/include/rpc/auth_unix.h stable/9/lib/libc/rpc/auth_unix.c stable/9/lib/libc/rpc/authunix_prot.c stable/9/lib/libc/rpc/clnt_perror.c stable/9/lib/libc/rpc/clnt_vc.c stable/9/lib/libc/rpc/rpc_generic.c stable/9/lib/libc/rpc/rpc_soc.3 stable/9/lib/libc/rpc/rpcb_clnt.c stable/9/lib/libc/rpc/svc_auth_unix.c stable/9/lib/libc/rpc/svc_run.c stable/9/sys/rpc/auth.h stable/9/sys/rpc/clnt_vc.c stable/9/sys/rpc/rpcb_clnt.c Directory Properties: stable/9/include/ (props changed) stable/9/lib/ (props changed) stable/9/lib/libc/ (props changed) Modified: stable/9/include/rpc/auth.h ============================================================================== --- stable/9/include/rpc/auth.h Sat Sep 22 04:04:02 2012 (r240798) +++ stable/9/include/rpc/auth.h Sat Sep 22 04:18:42 2012 (r240799) @@ -243,14 +243,13 @@ __END_DECLS * System style authentication * AUTH *authunix_create(machname, uid, gid, len, aup_gids) * char *machname; - * int uid; - * int gid; + * uid_t uid; + * gid_t gid; * int len; - * int *aup_gids; + * gid_t *aup_gids; */ __BEGIN_DECLS -extern AUTH *authunix_create(char *, int, int, int, - int *); +extern AUTH *authunix_create(char *, uid_t, gid_t, int, gid_t *); extern AUTH *authunix_create_default(void); /* takes no parameters */ extern AUTH *authnone_create(void); /* takes no parameters */ __END_DECLS Modified: stable/9/include/rpc/auth_unix.h ============================================================================== --- stable/9/include/rpc/auth_unix.h Sat Sep 22 04:04:02 2012 (r240798) +++ stable/9/include/rpc/auth_unix.h Sat Sep 22 04:18:42 2012 (r240799) @@ -60,10 +60,10 @@ struct authunix_parms { u_long aup_time; char *aup_machname; - int aup_uid; - int aup_gid; + uid_t aup_uid; + gid_t aup_gid; u_int aup_len; - int *aup_gids; + gid_t *aup_gids; }; #define authsys_parms authunix_parms Modified: stable/9/lib/libc/rpc/auth_unix.c ============================================================================== --- stable/9/lib/libc/rpc/auth_unix.c Sat Sep 22 04:04:02 2012 (r240798) +++ stable/9/lib/libc/rpc/auth_unix.c Sat Sep 22 04:18:42 2012 (r240799) @@ -94,10 +94,10 @@ struct audata { AUTH * authunix_create(machname, uid, gid, len, aup_gids) char *machname; - int uid; - int gid; + uid_t uid; + gid_t gid; int len; - int *aup_gids; + gid_t *aup_gids; { struct authunix_parms aup; char mymem[MAX_AUTH_BYTES]; @@ -207,9 +207,7 @@ authunix_create_default() abort(); if (ngids > NGRPS) ngids = NGRPS; - /* XXX: interface problem; those should all have been unsigned */ - auth = authunix_create(machname, (int)uid, (int)gid, ngids, - (int *)gids); + auth = authunix_create(machname, uid, gid, ngids, gids); free(gids); return (auth); } Modified: stable/9/lib/libc/rpc/authunix_prot.c ============================================================================== --- stable/9/lib/libc/rpc/authunix_prot.c Sat Sep 22 04:04:02 2012 (r240798) +++ stable/9/lib/libc/rpc/authunix_prot.c Sat Sep 22 04:18:42 2012 (r240799) @@ -60,7 +60,7 @@ xdr_authunix_parms(xdrs, p) XDR *xdrs; struct authunix_parms *p; { - int **paup_gids; + gid_t **paup_gids; assert(xdrs != NULL); assert(p != NULL); @@ -69,8 +69,8 @@ xdr_authunix_parms(xdrs, p) if (xdr_u_long(xdrs, &(p->aup_time)) && xdr_string(xdrs, &(p->aup_machname), MAX_MACHINE_NAME) - && xdr_int(xdrs, &(p->aup_uid)) - && xdr_int(xdrs, &(p->aup_gid)) + && xdr_u_int(xdrs, &(p->aup_uid)) + && xdr_u_int(xdrs, &(p->aup_gid)) && xdr_array(xdrs, (char **) paup_gids, &(p->aup_len), NGRPS, sizeof(int), (xdrproc_t)xdr_int) ) { return (TRUE); Modified: stable/9/lib/libc/rpc/clnt_perror.c ============================================================================== --- stable/9/lib/libc/rpc/clnt_perror.c Sat Sep 22 04:04:02 2012 (r240798) +++ stable/9/lib/libc/rpc/clnt_perror.c Sat Sep 22 04:18:42 2012 (r240799) @@ -242,7 +242,7 @@ char * clnt_spcreateerror(s) const char *s; { - char *str; + char *str, *err; size_t len, i; assert(s != NULL); @@ -258,8 +258,21 @@ clnt_spcreateerror(s) switch (rpc_createerr.cf_stat) { case RPC_PMAPFAILURE: (void) strncat(str, " - ", len - 1); - (void) strncat(str, - clnt_sperrno(rpc_createerr.cf_error.re_status), len - 4); + err = clnt_sperrno(rpc_createerr.cf_error.re_status); + if (err) + (void) strncat(str, err+5, len-5); + switch(rpc_createerr.cf_error.re_status) { + case RPC_CANTSEND: + case RPC_CANTRECV: + i = strlen(str); + len -= i; + snprintf(str+i, len, ": errno %d (%s)", + rpc_createerr.cf_error.re_errno, + strerror(rpc_createerr.cf_error.re_errno)); + break; + default: + break; + } break; case RPC_SYSTEMERROR: Modified: stable/9/lib/libc/rpc/clnt_vc.c ============================================================================== --- stable/9/lib/libc/rpc/clnt_vc.c Sat Sep 22 04:04:02 2012 (r240798) +++ stable/9/lib/libc/rpc/clnt_vc.c Sat Sep 22 04:18:42 2012 (r240799) @@ -672,6 +672,10 @@ clnt_vc_destroy(cl) if (ct->ct_addr.buf) free(ct->ct_addr.buf); mem_free(ct, sizeof(struct ct_data)); + if (cl->cl_netid && cl->cl_netid[0]) + mem_free(cl->cl_netid, strlen(cl->cl_netid) +1); + if (cl->cl_tp && cl->cl_tp[0]) + mem_free(cl->cl_tp, strlen(cl->cl_tp) +1); mem_free(cl, sizeof(CLIENT)); mutex_unlock(&clnt_fd_lock); thr_sigsetmask(SIG_SETMASK, &(mask), NULL); Modified: stable/9/lib/libc/rpc/rpc_generic.c ============================================================================== --- stable/9/lib/libc/rpc/rpc_generic.c Sat Sep 22 04:04:02 2012 (r240798) +++ stable/9/lib/libc/rpc/rpc_generic.c Sat Sep 22 04:18:42 2012 (r240799) @@ -269,7 +269,8 @@ __rpc_getconfip(nettype) } while ((nconf = getnetconfig(confighandle)) != NULL) { if (strcmp(nconf->nc_protofmly, NC_INET) == 0) { - if (strcmp(nconf->nc_proto, NC_TCP) == 0) { + if (strcmp(nconf->nc_proto, NC_TCP) == 0 && + netid_tcp == NULL) { netid_tcp = strdup(nconf->nc_netid); if (main_thread) netid_tcp_main = netid_tcp; @@ -277,7 +278,8 @@ __rpc_getconfip(nettype) thr_setspecific(tcp_key, (void *) netid_tcp); } else - if (strcmp(nconf->nc_proto, NC_UDP) == 0) { + if (strcmp(nconf->nc_proto, NC_UDP) == 0 && + netid_udp == NULL) { netid_udp = strdup(nconf->nc_netid); if (main_thread) netid_udp_main = netid_udp; @@ -616,6 +618,9 @@ __rpc_taddr2uaddr_af(int af, const struc #endif u_int16_t port; + if (nbuf->len <= 0) + return NULL; + switch (af) { case AF_INET: sin = nbuf->buf; Modified: stable/9/lib/libc/rpc/rpc_soc.3 ============================================================================== --- stable/9/lib/libc/rpc/rpc_soc.3 Sat Sep 22 04:04:02 2012 (r240798) +++ stable/9/lib/libc/rpc/rpc_soc.3 Sat Sep 22 04:18:42 2012 (r240799) @@ -148,7 +148,7 @@ default authentication used by .Ft "AUTH *" .Xc .It Xo -.Fn authunix_create "char *host" "int uid" "int gid" "int len" "int *aup_gids" +.Fn authunix_create "char *host" "uid_t uid" "gid_t gid" "int len" "gid_t *aup_gids" .Xc .Pp Create and return an Modified: stable/9/lib/libc/rpc/rpcb_clnt.c ============================================================================== --- stable/9/lib/libc/rpc/rpcb_clnt.c Sat Sep 22 04:04:02 2012 (r240798) +++ stable/9/lib/libc/rpc/rpcb_clnt.c Sat Sep 22 04:18:42 2012 (r240799) @@ -770,6 +770,13 @@ __rpcb_findaddr_timed(program, version, } parms.r_addr = NULL; + parms.r_netid = nconf->nc_netid; + + /* + * According to wire captures, the reference implementation + * (OpenSolaris) sends a blank string here too. + */ + parms.r_owner = ""; /* * Use default total timeout if no timeout is specified. Modified: stable/9/lib/libc/rpc/svc_auth_unix.c ============================================================================== --- stable/9/lib/libc/rpc/svc_auth_unix.c Sat Sep 22 04:04:02 2012 (r240798) +++ stable/9/lib/libc/rpc/svc_auth_unix.c Sat Sep 22 04:18:42 2012 (r240799) @@ -68,7 +68,7 @@ _svcauth_unix(rqst, msg) struct area { struct authunix_parms area_aup; char area_machname[MAX_MACHINE_NAME+1]; - int area_gids[NGRPS]; + gid_t area_gids[NGRPS]; } *area; u_int auth_len; size_t str_len, gid_len; Modified: stable/9/lib/libc/rpc/svc_run.c ============================================================================== --- stable/9/lib/libc/rpc/svc_run.c Sat Sep 22 04:04:02 2012 (r240798) +++ stable/9/lib/libc/rpc/svc_run.c Sat Sep 22 04:18:42 2012 (r240799) @@ -60,14 +60,13 @@ svc_run() fd_set readfds, cleanfds; struct timeval timeout; - timeout.tv_sec = 30; - timeout.tv_usec = 0; - for (;;) { rwlock_rdlock(&svc_fd_lock); readfds = svc_fdset; cleanfds = svc_fdset; rwlock_unlock(&svc_fd_lock); + timeout.tv_sec = 30; + timeout.tv_usec = 0; switch (_select(svc_maxfd+1, &readfds, NULL, NULL, &timeout)) { case -1: FD_ZERO(&readfds); Modified: stable/9/sys/rpc/auth.h ============================================================================== --- stable/9/sys/rpc/auth.h Sat Sep 22 04:04:02 2012 (r240798) +++ stable/9/sys/rpc/auth.h Sat Sep 22 04:18:42 2012 (r240799) @@ -234,18 +234,17 @@ __END_DECLS * System style authentication * AUTH *authunix_create(machname, uid, gid, len, aup_gids) * char *machname; - * int uid; - * int gid; + * uid_t uid; + * gid_t gid; * int len; - * int *aup_gids; + * gid_t *aup_gids; */ __BEGIN_DECLS #ifdef _KERNEL struct ucred; extern AUTH *authunix_create(struct ucred *); #else -extern AUTH *authunix_create(char *, int, int, int, - int *); +extern AUTH *authunix_create(char *, uid_t, gid_t, int, gid_t *); extern AUTH *authunix_create_default(void); /* takes no parameters */ #endif extern AUTH *authnone_create(void); /* takes no parameters */ Modified: stable/9/sys/rpc/clnt_vc.c ============================================================================== --- stable/9/sys/rpc/clnt_vc.c Sat Sep 22 04:04:02 2012 (r240798) +++ stable/9/sys/rpc/clnt_vc.c Sat Sep 22 04:18:42 2012 (r240799) @@ -836,6 +836,10 @@ clnt_vc_destroy(CLIENT *cl) soclose(so); } mem_free(ct, sizeof(struct ct_data)); + if (cl->cl_netid && cl->cl_netid[0]) + mem_free(cl->cl_netid, strlen(cl->cl_netid) +1); + if (cl->cl_tp && cl->cl_tp[0]) + mem_free(cl->cl_tp, strlen(cl->cl_tp) +1); mem_free(cl, sizeof(CLIENT)); } Modified: stable/9/sys/rpc/rpcb_clnt.c ============================================================================== --- stable/9/sys/rpc/rpcb_clnt.c Sat Sep 22 04:04:02 2012 (r240798) +++ stable/9/sys/rpc/rpcb_clnt.c Sat Sep 22 04:18:42 2012 (r240799) @@ -780,6 +780,13 @@ __rpcb_findaddr_timed(program, version, } parms.r_addr = NULL; + parms.r_netid = nconf->nc_netid; + + /* + * According to wire captures, the reference implementation + * (OpenSolaris) sends a blank string here too. + */ + parms.r_owner = ""; /* * Use default total timeout if no timeout is specified. From owner-svn-src-stable@FreeBSD.ORG Sat Sep 22 04:22:18 2012 Return-Path: Delivered-To: svn-src-stable@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id A5EEB106564A; Sat, 22 Sep 2012 04:22:18 +0000 (UTC) (envelope-from pfg@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 8EC088FC0A; Sat, 22 Sep 2012 04:22:18 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q8M4MI5v083730; Sat, 22 Sep 2012 04:22:18 GMT (envelope-from pfg@svn.freebsd.org) Received: (from pfg@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q8M4MIUH083715; Sat, 22 Sep 2012 04:22:18 GMT (envelope-from pfg@svn.freebsd.org) Message-Id: <201209220422.q8M4MIUH083715@svn.freebsd.org> From: "Pedro F. Giffuni" Date: Sat, 22 Sep 2012 04:22:18 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-8@freebsd.org X-SVN-Group: stable-8 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r240800 - in stable/8: include/rpc lib/libc/rpc sys/rpc X-BeenThere: svn-src-stable@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for all the -stable branches of the src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 22 Sep 2012 04:22:19 -0000 Author: pfg Date: Sat Sep 22 04:22:17 2012 New Revision: 240800 URL: http://svn.freebsd.org/changeset/base/240800 Log: MFC r239963: Bring some changes from Bull's NFSv4 libtirpc implementation. ____ Fixed infinite loop in svc_run() ____ __rpc_taddr2uaddr_af() assumes the netbuf to always have a non-zero data. This is a bad assumption and can lead to a seg-fault. This patch adds a check for zero length and returns NULL when found. ____ Changed clnt_spcreateerror() to return clearer and more concise error messages. ____ Converted all uid and gid variables of the type uid_t and gid_t. ____ libtirpc: set r_netid and r_owner in __rpcb_findaddr_timed These fields in the rpcbind GETADDR call are being passed uninitialized to CLNT_CALL. In the case of x86_64 at least, this usually leads to a segfault. On x86, it sometimes causes segfaults and other times causes garbage to be sent on the wire. rpcbind generally ignores the r_owner field for calls that come in over the wire, so it really doesn't matter what we send in that slot. We just need to send something. The reference implementation from Sun seems to send a blank string. Have ours follow suit. ____ libtirpc: be sure to free cl_netid and cl_tp When creating a client with clnt_tli_create, it uses strdup to copy strings for these fields if nconf is passed in. clnt_dg_destroy frees these strings already. Make sure clnt_vc_destroy frees them in the same way. ____ Obtained from: Bull GNU/Linux NFSv4 Project Modified: stable/8/include/rpc/auth.h stable/8/include/rpc/auth_unix.h stable/8/lib/libc/rpc/auth_unix.c stable/8/lib/libc/rpc/authunix_prot.c stable/8/lib/libc/rpc/clnt_perror.c stable/8/lib/libc/rpc/clnt_vc.c stable/8/lib/libc/rpc/rpc_generic.c stable/8/lib/libc/rpc/rpc_soc.3 stable/8/lib/libc/rpc/rpcb_clnt.c stable/8/lib/libc/rpc/svc_auth_unix.c stable/8/lib/libc/rpc/svc_run.c stable/8/sys/rpc/auth.h stable/8/sys/rpc/clnt_vc.c stable/8/sys/rpc/rpcb_clnt.c Directory Properties: stable/8/include/ (props changed) stable/8/include/rpc/ (props changed) stable/8/lib/ (props changed) stable/8/lib/libc/ (props changed) stable/8/lib/libc/rpc/ (props changed) stable/8/sys/ (props changed) stable/8/sys/rpc/ (props changed) Modified: stable/8/include/rpc/auth.h ============================================================================== --- stable/8/include/rpc/auth.h Sat Sep 22 04:18:42 2012 (r240799) +++ stable/8/include/rpc/auth.h Sat Sep 22 04:22:17 2012 (r240800) @@ -243,14 +243,13 @@ __END_DECLS * System style authentication * AUTH *authunix_create(machname, uid, gid, len, aup_gids) * char *machname; - * int uid; - * int gid; + * uid_t uid; + * gid_t gid; * int len; - * int *aup_gids; + * gid_t *aup_gids; */ __BEGIN_DECLS -extern AUTH *authunix_create(char *, int, int, int, - int *); +extern AUTH *authunix_create(char *, uid_t, gid_t, int, gid_t *); extern AUTH *authunix_create_default(void); /* takes no parameters */ extern AUTH *authnone_create(void); /* takes no parameters */ __END_DECLS Modified: stable/8/include/rpc/auth_unix.h ============================================================================== --- stable/8/include/rpc/auth_unix.h Sat Sep 22 04:18:42 2012 (r240799) +++ stable/8/include/rpc/auth_unix.h Sat Sep 22 04:22:17 2012 (r240800) @@ -60,10 +60,10 @@ struct authunix_parms { u_long aup_time; char *aup_machname; - int aup_uid; - int aup_gid; + uid_t aup_uid; + gid_t aup_gid; u_int aup_len; - int *aup_gids; + gid_t *aup_gids; }; #define authsys_parms authunix_parms Modified: stable/8/lib/libc/rpc/auth_unix.c ============================================================================== --- stable/8/lib/libc/rpc/auth_unix.c Sat Sep 22 04:18:42 2012 (r240799) +++ stable/8/lib/libc/rpc/auth_unix.c Sat Sep 22 04:22:17 2012 (r240800) @@ -94,10 +94,10 @@ struct audata { AUTH * authunix_create(machname, uid, gid, len, aup_gids) char *machname; - int uid; - int gid; + uid_t uid; + gid_t gid; int len; - int *aup_gids; + gid_t *aup_gids; { struct authunix_parms aup; char mymem[MAX_AUTH_BYTES]; @@ -207,9 +207,7 @@ authunix_create_default() abort(); if (ngids > NGRPS) ngids = NGRPS; - /* XXX: interface problem; those should all have been unsigned */ - auth = authunix_create(machname, (int)uid, (int)gid, ngids, - (int *)gids); + auth = authunix_create(machname, uid, gid, ngids, gids); free(gids); return (auth); } Modified: stable/8/lib/libc/rpc/authunix_prot.c ============================================================================== --- stable/8/lib/libc/rpc/authunix_prot.c Sat Sep 22 04:18:42 2012 (r240799) +++ stable/8/lib/libc/rpc/authunix_prot.c Sat Sep 22 04:22:17 2012 (r240800) @@ -60,7 +60,7 @@ xdr_authunix_parms(xdrs, p) XDR *xdrs; struct authunix_parms *p; { - int **paup_gids; + gid_t **paup_gids; assert(xdrs != NULL); assert(p != NULL); @@ -69,8 +69,8 @@ xdr_authunix_parms(xdrs, p) if (xdr_u_long(xdrs, &(p->aup_time)) && xdr_string(xdrs, &(p->aup_machname), MAX_MACHINE_NAME) - && xdr_int(xdrs, &(p->aup_uid)) - && xdr_int(xdrs, &(p->aup_gid)) + && xdr_u_int(xdrs, &(p->aup_uid)) + && xdr_u_int(xdrs, &(p->aup_gid)) && xdr_array(xdrs, (char **) paup_gids, &(p->aup_len), NGRPS, sizeof(int), (xdrproc_t)xdr_int) ) { return (TRUE); Modified: stable/8/lib/libc/rpc/clnt_perror.c ============================================================================== --- stable/8/lib/libc/rpc/clnt_perror.c Sat Sep 22 04:18:42 2012 (r240799) +++ stable/8/lib/libc/rpc/clnt_perror.c Sat Sep 22 04:22:17 2012 (r240800) @@ -242,7 +242,7 @@ char * clnt_spcreateerror(s) const char *s; { - char *str; + char *str, *err; size_t len, i; assert(s != NULL); @@ -258,8 +258,21 @@ clnt_spcreateerror(s) switch (rpc_createerr.cf_stat) { case RPC_PMAPFAILURE: (void) strncat(str, " - ", len - 1); - (void) strncat(str, - clnt_sperrno(rpc_createerr.cf_error.re_status), len - 4); + err = clnt_sperrno(rpc_createerr.cf_error.re_status); + if (err) + (void) strncat(str, err+5, len-5); + switch(rpc_createerr.cf_error.re_status) { + case RPC_CANTSEND: + case RPC_CANTRECV: + i = strlen(str); + len -= i; + snprintf(str+i, len, ": errno %d (%s)", + rpc_createerr.cf_error.re_errno, + strerror(rpc_createerr.cf_error.re_errno)); + break; + default: + break; + } break; case RPC_SYSTEMERROR: Modified: stable/8/lib/libc/rpc/clnt_vc.c ============================================================================== --- stable/8/lib/libc/rpc/clnt_vc.c Sat Sep 22 04:18:42 2012 (r240799) +++ stable/8/lib/libc/rpc/clnt_vc.c Sat Sep 22 04:22:17 2012 (r240800) @@ -672,6 +672,10 @@ clnt_vc_destroy(cl) if (ct->ct_addr.buf) free(ct->ct_addr.buf); mem_free(ct, sizeof(struct ct_data)); + if (cl->cl_netid && cl->cl_netid[0]) + mem_free(cl->cl_netid, strlen(cl->cl_netid) +1); + if (cl->cl_tp && cl->cl_tp[0]) + mem_free(cl->cl_tp, strlen(cl->cl_tp) +1); mem_free(cl, sizeof(CLIENT)); mutex_unlock(&clnt_fd_lock); thr_sigsetmask(SIG_SETMASK, &(mask), NULL); Modified: stable/8/lib/libc/rpc/rpc_generic.c ============================================================================== --- stable/8/lib/libc/rpc/rpc_generic.c Sat Sep 22 04:18:42 2012 (r240799) +++ stable/8/lib/libc/rpc/rpc_generic.c Sat Sep 22 04:22:17 2012 (r240800) @@ -269,7 +269,8 @@ __rpc_getconfip(nettype) } while ((nconf = getnetconfig(confighandle)) != NULL) { if (strcmp(nconf->nc_protofmly, NC_INET) == 0) { - if (strcmp(nconf->nc_proto, NC_TCP) == 0) { + if (strcmp(nconf->nc_proto, NC_TCP) == 0 && + netid_tcp == NULL) { netid_tcp = strdup(nconf->nc_netid); if (main_thread) netid_tcp_main = netid_tcp; @@ -277,7 +278,8 @@ __rpc_getconfip(nettype) thr_setspecific(tcp_key, (void *) netid_tcp); } else - if (strcmp(nconf->nc_proto, NC_UDP) == 0) { + if (strcmp(nconf->nc_proto, NC_UDP) == 0 && + netid_udp == NULL) { netid_udp = strdup(nconf->nc_netid); if (main_thread) netid_udp_main = netid_udp; @@ -616,6 +618,9 @@ __rpc_taddr2uaddr_af(int af, const struc #endif u_int16_t port; + if (nbuf->len <= 0) + return NULL; + switch (af) { case AF_INET: sin = nbuf->buf; Modified: stable/8/lib/libc/rpc/rpc_soc.3 ============================================================================== --- stable/8/lib/libc/rpc/rpc_soc.3 Sat Sep 22 04:18:42 2012 (r240799) +++ stable/8/lib/libc/rpc/rpc_soc.3 Sat Sep 22 04:22:17 2012 (r240800) @@ -148,7 +148,7 @@ default authentication used by .Ft "AUTH *" .Xc .It Xo -.Fn authunix_create "char *host" "int uid" "int gid" "int len" "int *aup_gids" +.Fn authunix_create "char *host" "uid_t uid" "gid_t gid" "int len" "gid_t *aup_gids" .Xc .Pp Create and return an Modified: stable/8/lib/libc/rpc/rpcb_clnt.c ============================================================================== --- stable/8/lib/libc/rpc/rpcb_clnt.c Sat Sep 22 04:18:42 2012 (r240799) +++ stable/8/lib/libc/rpc/rpcb_clnt.c Sat Sep 22 04:22:17 2012 (r240800) @@ -770,6 +770,13 @@ __rpcb_findaddr_timed(program, version, } parms.r_addr = NULL; + parms.r_netid = nconf->nc_netid; + + /* + * According to wire captures, the reference implementation + * (OpenSolaris) sends a blank string here too. + */ + parms.r_owner = ""; /* * Use default total timeout if no timeout is specified. Modified: stable/8/lib/libc/rpc/svc_auth_unix.c ============================================================================== --- stable/8/lib/libc/rpc/svc_auth_unix.c Sat Sep 22 04:18:42 2012 (r240799) +++ stable/8/lib/libc/rpc/svc_auth_unix.c Sat Sep 22 04:22:17 2012 (r240800) @@ -68,7 +68,7 @@ _svcauth_unix(rqst, msg) struct area { struct authunix_parms area_aup; char area_machname[MAX_MACHINE_NAME+1]; - int area_gids[NGRPS]; + gid_t area_gids[NGRPS]; } *area; u_int auth_len; size_t str_len, gid_len; Modified: stable/8/lib/libc/rpc/svc_run.c ============================================================================== --- stable/8/lib/libc/rpc/svc_run.c Sat Sep 22 04:18:42 2012 (r240799) +++ stable/8/lib/libc/rpc/svc_run.c Sat Sep 22 04:22:17 2012 (r240800) @@ -60,14 +60,13 @@ svc_run() fd_set readfds, cleanfds; struct timeval timeout; - timeout.tv_sec = 30; - timeout.tv_usec = 0; - for (;;) { rwlock_rdlock(&svc_fd_lock); readfds = svc_fdset; cleanfds = svc_fdset; rwlock_unlock(&svc_fd_lock); + timeout.tv_sec = 30; + timeout.tv_usec = 0; switch (_select(svc_maxfd+1, &readfds, NULL, NULL, &timeout)) { case -1: FD_ZERO(&readfds); Modified: stable/8/sys/rpc/auth.h ============================================================================== --- stable/8/sys/rpc/auth.h Sat Sep 22 04:18:42 2012 (r240799) +++ stable/8/sys/rpc/auth.h Sat Sep 22 04:22:17 2012 (r240800) @@ -234,18 +234,17 @@ __END_DECLS * System style authentication * AUTH *authunix_create(machname, uid, gid, len, aup_gids) * char *machname; - * int uid; - * int gid; + * uid_t uid; + * gid_t gid; * int len; - * int *aup_gids; + * gid_t *aup_gids; */ __BEGIN_DECLS #ifdef _KERNEL struct ucred; extern AUTH *authunix_create(struct ucred *); #else -extern AUTH *authunix_create(char *, int, int, int, - int *); +extern AUTH *authunix_create(char *, uid_t, gid_t, int, gid_t *); extern AUTH *authunix_create_default(void); /* takes no parameters */ #endif extern AUTH *authnone_create(void); /* takes no parameters */ Modified: stable/8/sys/rpc/clnt_vc.c ============================================================================== --- stable/8/sys/rpc/clnt_vc.c Sat Sep 22 04:18:42 2012 (r240799) +++ stable/8/sys/rpc/clnt_vc.c Sat Sep 22 04:22:17 2012 (r240800) @@ -836,6 +836,10 @@ clnt_vc_destroy(CLIENT *cl) soclose(so); } mem_free(ct, sizeof(struct ct_data)); + if (cl->cl_netid && cl->cl_netid[0]) + mem_free(cl->cl_netid, strlen(cl->cl_netid) +1); + if (cl->cl_tp && cl->cl_tp[0]) + mem_free(cl->cl_tp, strlen(cl->cl_tp) +1); mem_free(cl, sizeof(CLIENT)); } Modified: stable/8/sys/rpc/rpcb_clnt.c ============================================================================== --- stable/8/sys/rpc/rpcb_clnt.c Sat Sep 22 04:18:42 2012 (r240799) +++ stable/8/sys/rpc/rpcb_clnt.c Sat Sep 22 04:22:17 2012 (r240800) @@ -780,6 +780,13 @@ __rpcb_findaddr_timed(program, version, } parms.r_addr = NULL; + parms.r_netid = nconf->nc_netid; + + /* + * According to wire captures, the reference implementation + * (OpenSolaris) sends a blank string here too. + */ + parms.r_owner = ""; /* * Use default total timeout if no timeout is specified. From owner-svn-src-stable@FreeBSD.ORG Sat Sep 22 05:27:48 2012 Return-Path: Delivered-To: svn-src-stable@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 07586106566B; Sat, 22 Sep 2012 05:27:48 +0000 (UTC) (envelope-from kib@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id E5EC68FC0C; Sat, 22 Sep 2012 05:27:47 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q8M5RlVM094773; Sat, 22 Sep 2012 05:27:47 GMT (envelope-from kib@svn.freebsd.org) Received: (from kib@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q8M5RlNH094771; Sat, 22 Sep 2012 05:27:47 GMT (envelope-from kib@svn.freebsd.org) Message-Id: <201209220527.q8M5RlNH094771@svn.freebsd.org> From: Konstantin Belousov Date: Sat, 22 Sep 2012 05:27:47 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r240801 - stable/9/libexec/rtld-elf X-BeenThere: svn-src-stable@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for all the -stable branches of the src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 22 Sep 2012 05:27:48 -0000 Author: kib Date: Sat Sep 22 05:27:47 2012 New Revision: 240801 URL: http://svn.freebsd.org/changeset/base/240801 Log: MFC r240686: Do not reference z_nodeflib for !objgiven case, thus fixing LD_PRELOAD for a non-absolute path. PR: bin/171604 Modified: stable/9/libexec/rtld-elf/rtld.c Directory Properties: stable/9/libexec/rtld-elf/ (props changed) Modified: stable/9/libexec/rtld-elf/rtld.c ============================================================================== --- stable/9/libexec/rtld-elf/rtld.c Sat Sep 22 04:22:17 2012 (r240800) +++ stable/9/libexec/rtld-elf/rtld.c Sat Sep 22 05:27:47 2012 (r240801) @@ -1429,7 +1429,7 @@ find_library(const char *xname, const Ob { char *pathname; char *name; - bool objgiven; + bool nodeflib, objgiven; objgiven = refobj != NULL; if (strchr(xname, '/') != NULL) { /* Hard coded pathname */ @@ -1464,6 +1464,7 @@ find_library(const char *xname, const Ob (pathname = search_library_path(name, STANDARD_LIBRARY_PATH)) != NULL) return (pathname); } else { + nodeflib = objgiven ? refobj->z_nodeflib : false; if ((objgiven && (pathname = search_library_path(name, refobj->rpath)) != NULL) || (objgiven && refobj->runpath == NULL && refobj != obj_main && @@ -1471,9 +1472,8 @@ find_library(const char *xname, const Ob (pathname = search_library_path(name, ld_library_path)) != NULL || (objgiven && (pathname = search_library_path(name, refobj->runpath)) != NULL) || - (pathname = search_library_path(name, gethints(refobj->z_nodeflib))) - != NULL || - (objgiven && !refobj->z_nodeflib && + (pathname = search_library_path(name, gethints(nodeflib))) != NULL || + (objgiven && !nodeflib && (pathname = search_library_path(name, STANDARD_LIBRARY_PATH)) != NULL)) return (pathname); } From owner-svn-src-stable@FreeBSD.ORG Sat Sep 22 08:47:30 2012 Return-Path: Delivered-To: svn-src-stable@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 5FBEB10656A6; Sat, 22 Sep 2012 08:47:30 +0000 (UTC) (envelope-from delphij@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 4971F8FC0A; Sat, 22 Sep 2012 08:47:30 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q8M8lUd8029993; Sat, 22 Sep 2012 08:47:30 GMT (envelope-from delphij@svn.freebsd.org) Received: (from delphij@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q8M8lUNV029986; Sat, 22 Sep 2012 08:47:30 GMT (envelope-from delphij@svn.freebsd.org) Message-Id: <201209220847.q8M8lUNV029986@svn.freebsd.org> From: Xin LI Date: Sat, 22 Sep 2012 08:47:30 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r240807 - in stable/9/contrib/bind9: . lib/dns lib/dns/include/dns X-BeenThere: svn-src-stable@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for all the -stable branches of the src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 22 Sep 2012 08:47:30 -0000 Author: delphij Date: Sat Sep 22 08:47:29 2012 New Revision: 240807 URL: http://svn.freebsd.org/changeset/base/240807 Log: MFC 240729 (dougb): Upgrade to 9.8.3-P3: Prevents a crash when queried for a record whose RDATA exceeds 65535 bytes. Prevents a crash when validating caused by using "Bad cache" data before it has been initialized. ISC_QUEUE handling for recursive clients was updated to address a race condition that could cause a memory leak. This rarely occurred with UDP clients, but could be a significant problem for a server handling a steady rate of TCP queries. A condition has been corrected where improper handling of zero-length RDATA could cause undesirable behavior, including termination of the named process. For more information: https://kb.isc.org/article/AA-00788 Modified: stable/9/contrib/bind9/CHANGES stable/9/contrib/bind9/lib/dns/include/dns/rdata.h stable/9/contrib/bind9/lib/dns/master.c stable/9/contrib/bind9/lib/dns/rdata.c stable/9/contrib/bind9/lib/dns/rdataslab.c stable/9/contrib/bind9/version Directory Properties: stable/9/contrib/bind9/ (props changed) Modified: stable/9/contrib/bind9/CHANGES ============================================================================== --- stable/9/contrib/bind9/CHANGES Sat Sep 22 08:02:42 2012 (r240806) +++ stable/9/contrib/bind9/CHANGES Sat Sep 22 08:47:29 2012 (r240807) @@ -1,3 +1,8 @@ + --- 9.8.3-P3 released --- + +3364. [security] Named could die on specially crafted record. + [RT #30416] + --- 9.8.3-P2 released --- 3346. [security] Bad-cache data could be used before it was Modified: stable/9/contrib/bind9/lib/dns/include/dns/rdata.h ============================================================================== --- stable/9/contrib/bind9/lib/dns/include/dns/rdata.h Sat Sep 22 08:02:42 2012 (r240806) +++ stable/9/contrib/bind9/lib/dns/include/dns/rdata.h Sat Sep 22 08:47:29 2012 (r240807) @@ -147,6 +147,17 @@ struct dns_rdata { (((rdata)->flags & ~(DNS_RDATA_UPDATE|DNS_RDATA_OFFLINE)) == 0) /* + * The maximum length of a RDATA that can be sent on the wire. + * Max packet size (65535) less header (12), less name (1), type (2), + * class (2), ttl(4), length (2). + * + * None of the defined types that support name compression can exceed + * this and all new types are to be sent uncompressed. + */ + +#define DNS_RDATA_MAXLENGTH 65512U + +/* * Flags affecting rdata formatting style. Flags 0xFFFF0000 * are used by masterfile-level formatting and defined elsewhere. * See additional comments at dns_rdata_tofmttext(). Modified: stable/9/contrib/bind9/lib/dns/master.c ============================================================================== --- stable/9/contrib/bind9/lib/dns/master.c Sat Sep 22 08:02:42 2012 (r240806) +++ stable/9/contrib/bind9/lib/dns/master.c Sat Sep 22 08:47:29 2012 (r240807) @@ -75,7 +75,7 @@ /*% * max message size - header - root - type - class - ttl - rdlen */ -#define MINTSIZ (65535 - 12 - 1 - 2 - 2 - 4 - 2) +#define MINTSIZ DNS_RDATA_MAXLENGTH /*% * Size for tokens in the presentation format, * The largest tokens are the base64 blocks in KEY and CERT records, Modified: stable/9/contrib/bind9/lib/dns/rdata.c ============================================================================== --- stable/9/contrib/bind9/lib/dns/rdata.c Sat Sep 22 08:02:42 2012 (r240806) +++ stable/9/contrib/bind9/lib/dns/rdata.c Sat Sep 22 08:47:29 2012 (r240807) @@ -429,6 +429,7 @@ dns_rdata_fromwire(dns_rdata_t *rdata, d isc_buffer_t st; isc_boolean_t use_default = ISC_FALSE; isc_uint32_t activelength; + size_t length; REQUIRE(dctx != NULL); if (rdata != NULL) { @@ -459,6 +460,14 @@ dns_rdata_fromwire(dns_rdata_t *rdata, d } /* + * Reject any rdata that expands out to more than DNS_RDATA_MAXLENGTH + * as we cannot transmit it. + */ + length = isc_buffer_usedlength(target) - isc_buffer_usedlength(&st); + if (result == ISC_R_SUCCESS && length > DNS_RDATA_MAXLENGTH) + result = DNS_R_FORMERR; + + /* * We should have consumed all of our buffer. */ if (result == ISC_R_SUCCESS && !buffer_empty(source)) @@ -466,8 +475,7 @@ dns_rdata_fromwire(dns_rdata_t *rdata, d if (rdata != NULL && result == ISC_R_SUCCESS) { region.base = isc_buffer_used(&st); - region.length = isc_buffer_usedlength(target) - - isc_buffer_usedlength(&st); + region.length = length; dns_rdata_fromregion(rdata, rdclass, type, ®ion); } @@ -602,6 +610,7 @@ dns_rdata_fromtext(dns_rdata_t *rdata, d unsigned long line; void (*callback)(dns_rdatacallbacks_t *, const char *, ...); isc_result_t tresult; + size_t length; REQUIRE(origin == NULL || dns_name_isabsolute(origin) == ISC_TRUE); if (rdata != NULL) { @@ -673,10 +682,13 @@ dns_rdata_fromtext(dns_rdata_t *rdata, d } } while (1); + length = isc_buffer_usedlength(target) - isc_buffer_usedlength(&st); + if (result == ISC_R_SUCCESS && length > DNS_RDATA_MAXLENGTH) + result = ISC_R_NOSPACE; + if (rdata != NULL && result == ISC_R_SUCCESS) { region.base = isc_buffer_used(&st); - region.length = isc_buffer_usedlength(target) - - isc_buffer_usedlength(&st); + region.length = length; dns_rdata_fromregion(rdata, rdclass, type, ®ion); } if (result != ISC_R_SUCCESS) { @@ -804,6 +816,7 @@ dns_rdata_fromstruct(dns_rdata_t *rdata, isc_buffer_t st; isc_region_t region; isc_boolean_t use_default = ISC_FALSE; + size_t length; REQUIRE(source != NULL); if (rdata != NULL) { @@ -818,10 +831,13 @@ dns_rdata_fromstruct(dns_rdata_t *rdata, if (use_default) (void)NULL; + length = isc_buffer_usedlength(target) - isc_buffer_usedlength(&st); + if (result == ISC_R_SUCCESS && length > DNS_RDATA_MAXLENGTH) + result = ISC_R_NOSPACE; + if (rdata != NULL && result == ISC_R_SUCCESS) { region.base = isc_buffer_used(&st); - region.length = isc_buffer_usedlength(target) - - isc_buffer_usedlength(&st); + region.length = length; dns_rdata_fromregion(rdata, rdclass, type, ®ion); } if (result != ISC_R_SUCCESS) Modified: stable/9/contrib/bind9/lib/dns/rdataslab.c ============================================================================== --- stable/9/contrib/bind9/lib/dns/rdataslab.c Sat Sep 22 08:02:42 2012 (r240806) +++ stable/9/contrib/bind9/lib/dns/rdataslab.c Sat Sep 22 08:47:29 2012 (r240807) @@ -305,6 +305,7 @@ dns_rdataslab_fromrdataset(dns_rdataset_ length = x[i].rdata.length; if (rdataset->type == dns_rdatatype_rrsig) length++; + INSIST(length <= 0xffff); *rawbuf++ = (length & 0xff00) >> 8; *rawbuf++ = (length & 0x00ff); #if DNS_RDATASET_FIXED Modified: stable/9/contrib/bind9/version ============================================================================== --- stable/9/contrib/bind9/version Sat Sep 22 08:02:42 2012 (r240806) +++ stable/9/contrib/bind9/version Sat Sep 22 08:47:29 2012 (r240807) @@ -7,4 +7,4 @@ MAJORVER=9 MINORVER=8 PATCHVER=3 RELEASETYPE=-P -RELEASEVER=2 +RELEASEVER=3 From owner-svn-src-stable@FreeBSD.ORG Sat Sep 22 12:27:51 2012 Return-Path: Delivered-To: svn-src-stable@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id E9F8C106564A; Sat, 22 Sep 2012 12:27:50 +0000 (UTC) (envelope-from kib@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id D40D78FC1E; Sat, 22 Sep 2012 12:27:50 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q8MCRop9065765; Sat, 22 Sep 2012 12:27:50 GMT (envelope-from kib@svn.freebsd.org) Received: (from kib@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q8MCRohF065762; Sat, 22 Sep 2012 12:27:50 GMT (envelope-from kib@svn.freebsd.org) Message-Id: <201209221227.q8MCRohF065762@svn.freebsd.org> From: Konstantin Belousov Date: Sat, 22 Sep 2012 12:27:50 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r240814 - in stable/9/sys: kern sys X-BeenThere: svn-src-stable@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for all the -stable branches of the src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 22 Sep 2012 12:27:51 -0000 Author: kib Date: Sat Sep 22 12:27:50 2012 New Revision: 240814 URL: http://svn.freebsd.org/changeset/base/240814 Log: MFC r237431: Enchance the shared page chunk allocator. Modified: stable/9/sys/kern/kern_exec.c stable/9/sys/sys/sysent.h Directory Properties: stable/9/sys/ (props changed) Modified: stable/9/sys/kern/kern_exec.c ============================================================================== --- stable/9/sys/kern/kern_exec.c Sat Sep 22 12:17:09 2012 (r240813) +++ stable/9/sys/kern/kern_exec.c Sat Sep 22 12:27:50 2012 (r240814) @@ -1514,33 +1514,81 @@ exec_unregister(execsw_arg) return (0); } +static struct sx shared_page_alloc_sx; static vm_object_t shared_page_obj; static int shared_page_free; -int -shared_page_fill(int size, int align, const char *data) +struct sf_buf * +shared_page_write_start(int base) { vm_page_t m; struct sf_buf *s; + + VM_OBJECT_LOCK(shared_page_obj); + m = vm_page_grab(shared_page_obj, OFF_TO_IDX(base), VM_ALLOC_RETRY); + VM_OBJECT_UNLOCK(shared_page_obj); + s = sf_buf_alloc(m, SFB_DEFAULT); + return (s); +} + +void +shared_page_write_end(struct sf_buf *sf) +{ + vm_page_t m; + + m = sf_buf_page(sf); + sf_buf_free(sf); + VM_OBJECT_LOCK(shared_page_obj); + vm_page_wakeup(m); + VM_OBJECT_UNLOCK(shared_page_obj); +} + +void +shared_page_write(int base, int size, const void *data) +{ + struct sf_buf *sf; vm_offset_t sk; + + sf = shared_page_write_start(base); + sk = sf_buf_kva(sf); + bcopy(data, (void *)(sk + (base & PAGE_MASK)), size); + shared_page_write_end(sf); +} + +static int +shared_page_alloc_locked(int size, int align) +{ int res; - VM_OBJECT_LOCK(shared_page_obj); - m = vm_page_grab(shared_page_obj, 0, VM_ALLOC_RETRY); res = roundup(shared_page_free, align); if (res + size >= IDX_TO_OFF(shared_page_obj->size)) res = -1; - else { - VM_OBJECT_UNLOCK(shared_page_obj); - s = sf_buf_alloc(m, SFB_DEFAULT); - sk = sf_buf_kva(s); - bcopy(data, (void *)(sk + res), size); + else shared_page_free = res + size; - sf_buf_free(s); - VM_OBJECT_LOCK(shared_page_obj); - } - vm_page_wakeup(m); - VM_OBJECT_UNLOCK(shared_page_obj); + return (res); +} + +int +shared_page_alloc(int size, int align) +{ + int res; + + sx_xlock(&shared_page_alloc_sx); + res = shared_page_alloc_locked(size, align); + sx_xunlock(&shared_page_alloc_sx); + return (res); +} + +int +shared_page_fill(int size, int align, const void *data) +{ + int res; + + sx_xlock(&shared_page_alloc_sx); + res = shared_page_alloc_locked(size, align); + if (res != -1) + shared_page_write(res, size, data); + sx_xunlock(&shared_page_alloc_sx); return (res); } @@ -1549,6 +1597,7 @@ shared_page_init(void *dummy __unused) { vm_page_t m; + sx_init(&shared_page_alloc_sx, "shpsx"); shared_page_obj = vm_pager_allocate(OBJT_PHYS, 0, PAGE_SIZE, VM_PROT_DEFAULT, 0, NULL); VM_OBJECT_LOCK(shared_page_obj); Modified: stable/9/sys/sys/sysent.h ============================================================================== --- stable/9/sys/sys/sysent.h Sat Sep 22 12:17:09 2012 (r240813) +++ stable/9/sys/sys/sysent.h Sat Sep 22 12:27:50 2012 (r240814) @@ -256,8 +256,13 @@ int lkmressys(struct thread *, struct no int syscall_thread_enter(struct thread *td, struct sysent *se); void syscall_thread_exit(struct thread *td, struct sysent *se); -int shared_page_fill(int size, int align, const char *data); +struct sf_buf; +int shared_page_alloc(int size, int align); +int shared_page_fill(int size, int align, const void *data); +void shared_page_write(int base, int size, const void *data); void exec_sysvec_init(void *param); +struct sf_buf *shared_page_write_start(int base); +void shared_page_write_end(struct sf_buf *sf); #define INIT_SYSENTVEC(name, sv) \ SYSINIT(name, SI_SUB_EXEC, SI_ORDER_ANY, \ From owner-svn-src-stable@FreeBSD.ORG Sat Sep 22 12:32:04 2012 Return-Path: Delivered-To: svn-src-stable@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id A1AB8106564A; Sat, 22 Sep 2012 12:32:04 +0000 (UTC) (envelope-from kib@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 875938FC14; Sat, 22 Sep 2012 12:32:04 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q8MCW4we066414; Sat, 22 Sep 2012 12:32:04 GMT (envelope-from kib@svn.freebsd.org) Received: (from kib@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q8MCW4K6066393; Sat, 22 Sep 2012 12:32:04 GMT (envelope-from kib@svn.freebsd.org) Message-Id: <201209221232.q8MCW4K6066393@svn.freebsd.org> From: Konstantin Belousov Date: Sat, 22 Sep 2012 12:32:04 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r240815 - in stable/9/sys: amd64/include arm/include conf i386/include ia64/include kern mips/include pc98/include powerpc/include sparc64/include sys x86/include x86/x86 X-BeenThere: svn-src-stable@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for all the -stable branches of the src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 22 Sep 2012 12:32:04 -0000 Author: kib Date: Sat Sep 22 12:32:00 2012 New Revision: 240815 URL: http://svn.freebsd.org/changeset/base/240815 Log: MFC r237433: Implement mechanism to export some kernel timekeeping data to usermode, using shared page. MFC r237474: Stop updating the struct vdso_timehands from even handler executed in the scheduled task from tc_windup(). Do it directly from tc_windup in interrupt context. Added: stable/9/sys/amd64/include/vdso.h - copied unchanged from r237433, head/sys/amd64/include/vdso.h stable/9/sys/arm/include/vdso.h - copied unchanged from r237433, head/sys/arm/include/vdso.h stable/9/sys/i386/include/vdso.h - copied unchanged from r237433, head/sys/i386/include/vdso.h stable/9/sys/ia64/include/vdso.h - copied unchanged from r237433, head/sys/ia64/include/vdso.h stable/9/sys/kern/subr_dummy_vdso_tc.c - copied unchanged from r237433, head/sys/kern/subr_dummy_vdso_tc.c stable/9/sys/mips/include/vdso.h - copied unchanged from r237433, head/sys/mips/include/vdso.h stable/9/sys/pc98/include/vdso.h - copied unchanged from r237433, head/sys/pc98/include/vdso.h stable/9/sys/powerpc/include/vdso.h - copied unchanged from r237433, head/sys/powerpc/include/vdso.h stable/9/sys/sparc64/include/vdso.h - copied unchanged from r237433, head/sys/sparc64/include/vdso.h stable/9/sys/sys/vdso.h - copied, changed from r237433, head/sys/sys/vdso.h stable/9/sys/x86/include/vdso.h - copied unchanged from r237433, head/sys/x86/include/vdso.h Modified: stable/9/sys/conf/files.arm stable/9/sys/conf/files.ia64 stable/9/sys/conf/files.mips stable/9/sys/conf/files.powerpc stable/9/sys/conf/files.sparc64 stable/9/sys/kern/imgact_elf.c stable/9/sys/kern/kern_exec.c stable/9/sys/kern/kern_tc.c stable/9/sys/sys/sysent.h stable/9/sys/x86/x86/tsc.c Directory Properties: stable/9/sys/ (props changed) stable/9/sys/conf/ (props changed) Copied: stable/9/sys/amd64/include/vdso.h (from r237433, head/sys/amd64/include/vdso.h) ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ stable/9/sys/amd64/include/vdso.h Sat Sep 22 12:32:00 2012 (r240815, copy of r237433, head/sys/amd64/include/vdso.h) @@ -0,0 +1,6 @@ +/*- + * This file is in the public domain. + */ +/* $FreeBSD$ */ + +#include Copied: stable/9/sys/arm/include/vdso.h (from r237433, head/sys/arm/include/vdso.h) ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ stable/9/sys/arm/include/vdso.h Sat Sep 22 12:32:00 2012 (r240815, copy of r237433, head/sys/arm/include/vdso.h) @@ -0,0 +1,34 @@ +/*- + * Copyright 2012 Konstantin Belousov . + * All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR + * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. + * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, + * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT + * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, + * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY + * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT + * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF + * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * $FreeBSD$ + */ + +#ifndef _ARM_VDSO_H +#define _ARM_VDSO_H + +#define VDSO_TIMEHANDS_MD \ + uint32_t th_res[8]; + +#endif Modified: stable/9/sys/conf/files.arm ============================================================================== --- stable/9/sys/conf/files.arm Sat Sep 22 12:27:50 2012 (r240814) +++ stable/9/sys/conf/files.arm Sat Sep 22 12:32:00 2012 (r240815) @@ -76,3 +76,5 @@ libkern/umoddi3.c standard #XXX: We can't use these versions, as strcmp.c is included conf/files #libkern/arm/strcmp.S standard #libkern/arm/strncmp.S standard +# +kern/subr_dummy_vdso_tc.c standard Modified: stable/9/sys/conf/files.ia64 ============================================================================== --- stable/9/sys/conf/files.ia64 Sat Sep 22 12:27:50 2012 (r240814) +++ stable/9/sys/conf/files.ia64 Sat Sep 22 12:32:00 2012 (r240815) @@ -137,3 +137,4 @@ libkern/ia64/bswap16.S standard libkern/ia64/bswap32.S standard libkern/memmove.c standard libkern/memset.c standard +kern/subr_dummy_vdso_tc.c standard Modified: stable/9/sys/conf/files.mips ============================================================================== --- stable/9/sys/conf/files.mips Sat Sep 22 12:27:50 2012 (r240814) +++ stable/9/sys/conf/files.mips Sat Sep 22 12:32:00 2012 (r240815) @@ -89,6 +89,8 @@ libkern/umoddi3.c optional isa_mips32 #libkern/mips/strcmp.S standard #libkern/mips/strncmp.S standard +kern/subr_dummy_vdso_tc.c standard + kern/kern_clocksource.c standard kern/link_elf_obj.c standard Modified: stable/9/sys/conf/files.powerpc ============================================================================== --- stable/9/sys/conf/files.powerpc Sat Sep 22 12:27:50 2012 (r240814) +++ stable/9/sys/conf/files.powerpc Sat Sep 22 12:32:00 2012 (r240815) @@ -58,6 +58,7 @@ dev/tsec/if_tsec.c optional tsec dev/tsec/if_tsec_fdt.c optional tsec fdt dev/uart/uart_cpu_powerpc.c optional uart aim kern/kern_clocksource.c standard +kern/subr_dummy_vdso_tc.c standard kern/syscalls.c optional ktr libkern/ashldi3.c optional powerpc libkern/ashrdi3.c optional powerpc Modified: stable/9/sys/conf/files.sparc64 ============================================================================== --- stable/9/sys/conf/files.sparc64 Sat Sep 22 12:27:50 2012 (r240814) +++ stable/9/sys/conf/files.sparc64 Sat Sep 22 12:32:00 2012 (r240815) @@ -60,6 +60,7 @@ dev/syscons/scvtb.c optional sc dev/uart/uart_cpu_sparc64.c optional uart dev/uart/uart_kbd_sun.c optional uart sc kern/kern_clocksource.c standard +kern/subr_dummy_vdso_tc.c standard kern/syscalls.c optional ktr libkern/ffs.c standard libkern/ffsl.c standard Copied: stable/9/sys/i386/include/vdso.h (from r237433, head/sys/i386/include/vdso.h) ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ stable/9/sys/i386/include/vdso.h Sat Sep 22 12:32:00 2012 (r240815, copy of r237433, head/sys/i386/include/vdso.h) @@ -0,0 +1,6 @@ +/*- + * This file is in the public domain. + */ +/* $FreeBSD$ */ + +#include Copied: stable/9/sys/ia64/include/vdso.h (from r237433, head/sys/ia64/include/vdso.h) ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ stable/9/sys/ia64/include/vdso.h Sat Sep 22 12:32:00 2012 (r240815, copy of r237433, head/sys/ia64/include/vdso.h) @@ -0,0 +1,41 @@ +/*- + * Copyright 2012 Konstantin Belousov . + * All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR + * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. + * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, + * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT + * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, + * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY + * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT + * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF + * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * $FreeBSD$ + */ + +#ifndef _IA64_VDSO_H +#define _IA64_VDSO_H + +#define VDSO_TIMEHANDS_MD \ + uint32_t th_res[8]; + +#ifdef _KERNEL +#ifdef COMPAT_FREEBSD32 + +#define VDSO_TIMEHANDS_MD32 VDSO_TIMEHANDS_MD + +#endif +#endif +#endif Modified: stable/9/sys/kern/imgact_elf.c ============================================================================== --- stable/9/sys/kern/imgact_elf.c Sat Sep 22 12:27:50 2012 (r240814) +++ stable/9/sys/kern/imgact_elf.c Sat Sep 22 12:32:00 2012 (r240815) @@ -1015,6 +1015,10 @@ __elfN(freebsd_fixup)(register_t **stack AUXARGS_ENTRY(pos, AT_PAGESIZES, imgp->pagesizes); AUXARGS_ENTRY(pos, AT_PAGESIZESLEN, imgp->pagesizeslen); } + if (imgp->sysent->sv_timekeep_base != 0) { + AUXARGS_ENTRY(pos, AT_TIMEKEEP, + imgp->sysent->sv_timekeep_base); + } AUXARGS_ENTRY(pos, AT_STACKPROT, imgp->sysent->sv_shared_page_obj != NULL && imgp->stack_prot != 0 ? imgp->stack_prot : imgp->sysent->sv_stackprot); Modified: stable/9/sys/kern/kern_exec.c ============================================================================== --- stable/9/sys/kern/kern_exec.c Sat Sep 22 12:27:50 2012 (r240814) +++ stable/9/sys/kern/kern_exec.c Sat Sep 22 12:32:00 2012 (r240815) @@ -28,6 +28,7 @@ __FBSDID("$FreeBSD$"); #include "opt_capsicum.h" +#include "opt_compat.h" #include "opt_hwpmc_hooks.h" #include "opt_kdtrace.h" #include "opt_ktrace.h" @@ -64,6 +65,7 @@ __FBSDID("$FreeBSD$"); #include #include #include +#include #include #include #ifdef KTRACE @@ -1517,42 +1519,13 @@ exec_unregister(execsw_arg) static struct sx shared_page_alloc_sx; static vm_object_t shared_page_obj; static int shared_page_free; - -struct sf_buf * -shared_page_write_start(int base) -{ - vm_page_t m; - struct sf_buf *s; - - VM_OBJECT_LOCK(shared_page_obj); - m = vm_page_grab(shared_page_obj, OFF_TO_IDX(base), VM_ALLOC_RETRY); - VM_OBJECT_UNLOCK(shared_page_obj); - s = sf_buf_alloc(m, SFB_DEFAULT); - return (s); -} - -void -shared_page_write_end(struct sf_buf *sf) -{ - vm_page_t m; - - m = sf_buf_page(sf); - sf_buf_free(sf); - VM_OBJECT_LOCK(shared_page_obj); - vm_page_wakeup(m); - VM_OBJECT_UNLOCK(shared_page_obj); -} +char *shared_page_mapping; void shared_page_write(int base, int size, const void *data) { - struct sf_buf *sf; - vm_offset_t sk; - sf = shared_page_write_start(base); - sk = sf_buf_kva(sf); - bcopy(data, (void *)(sk + (base & PAGE_MASK)), size); - shared_page_write_end(sf); + bcopy(data, shared_page_mapping + base, size); } static int @@ -1596,6 +1569,7 @@ static void shared_page_init(void *dummy __unused) { vm_page_t m; + vm_offset_t addr; sx_init(&shared_page_alloc_sx, "shpsx"); shared_page_obj = vm_pager_allocate(OBJT_PHYS, 0, PAGE_SIZE, @@ -1605,15 +1579,95 @@ shared_page_init(void *dummy __unused) VM_ALLOC_ZERO); m->valid = VM_PAGE_BITS_ALL; VM_OBJECT_UNLOCK(shared_page_obj); + addr = kmem_alloc_nofault(kernel_map, PAGE_SIZE); + pmap_qenter(addr, &m, 1); + shared_page_mapping = (char *)addr; } SYSINIT(shp, SI_SUB_EXEC, SI_ORDER_FIRST, (sysinit_cfunc_t)shared_page_init, NULL); +static void +timehands_update(struct sysentvec *sv) +{ + struct vdso_timehands th; + struct vdso_timekeep *tk; + uint32_t enabled, idx; + + enabled = tc_fill_vdso_timehands(&th); + tk = (struct vdso_timekeep *)(shared_page_mapping + + sv->sv_timekeep_off); + idx = sv->sv_timekeep_curr; + atomic_store_rel_32(&tk->tk_th[idx].th_gen, 0); + if (++idx >= VDSO_TH_NUM) + idx = 0; + sv->sv_timekeep_curr = idx; + if (++sv->sv_timekeep_gen == 0) + sv->sv_timekeep_gen = 1; + th.th_gen = 0; + if (enabled) + tk->tk_th[idx] = th; + tk->tk_enabled = enabled; + atomic_store_rel_32(&tk->tk_th[idx].th_gen, sv->sv_timekeep_gen); + tk->tk_current = idx; +} + +#ifdef COMPAT_FREEBSD32 +static void +timehands_update32(struct sysentvec *sv) +{ + struct vdso_timekeep32 *tk; + struct vdso_timehands32 th; + uint32_t enabled, idx; + + enabled = tc_fill_vdso_timehands32(&th); + tk = (struct vdso_timekeep32 *)(shared_page_mapping + + sv->sv_timekeep_off); + idx = sv->sv_timekeep_curr; + atomic_store_rel_32(&tk->tk_th[idx].th_gen, 0); + if (++idx >= VDSO_TH_NUM) + idx = 0; + sv->sv_timekeep_curr = idx; + if (++sv->sv_timekeep_gen == 0) + sv->sv_timekeep_gen = 1; + th.th_gen = 0; + if (enabled) + tk->tk_th[idx] = th; + tk->tk_enabled = enabled; + atomic_store_rel_32(&tk->tk_th[idx].th_gen, sv->sv_timekeep_gen); + tk->tk_current = idx; +} +#endif + +/* + * This is hackish, but easiest way to avoid creating list structures + * that needs to be iterated over from the hardclock interrupt + * context. + */ +static struct sysentvec *host_sysentvec; +#ifdef COMPAT_FREEBSD32 +static struct sysentvec *compat32_sysentvec; +#endif + +void +timekeep_push_vdso(void) +{ + + if (host_sysentvec != NULL && host_sysentvec->sv_timekeep_base != 0) + timehands_update(host_sysentvec); +#ifdef COMPAT_FREEBSD32 + if (compat32_sysentvec != NULL && + compat32_sysentvec->sv_timekeep_base != 0) + timehands_update32(compat32_sysentvec); +#endif +} + void exec_sysvec_init(void *param) { struct sysentvec *sv; + int tk_base; + uint32_t tk_ver; sv = (struct sysentvec *)param; @@ -1622,4 +1676,32 @@ exec_sysvec_init(void *param) sv->sv_shared_page_obj = shared_page_obj; sv->sv_sigcode_base = sv->sv_shared_page_base + shared_page_fill(*(sv->sv_szsigcode), 16, sv->sv_sigcode); + if ((sv->sv_flags & SV_ABI_MASK) != SV_ABI_FREEBSD) + return; + tk_ver = VDSO_TK_VER_CURR; +#ifdef COMPAT_FREEBSD32 + if ((sv->sv_flags & SV_ILP32) != 0) { + tk_base = shared_page_alloc(sizeof(struct vdso_timekeep32) + + sizeof(struct vdso_timehands32) * VDSO_TH_NUM, 16); + KASSERT(tk_base != -1, ("tk_base -1 for 32bit")); + shared_page_write(tk_base + offsetof(struct vdso_timekeep32, + tk_ver), sizeof(uint32_t), &tk_ver); + KASSERT(compat32_sysentvec == 0, + ("Native compat32 already registered")); + compat32_sysentvec = sv; + } else { +#endif + tk_base = shared_page_alloc(sizeof(struct vdso_timekeep) + + sizeof(struct vdso_timehands) * VDSO_TH_NUM, 16); + KASSERT(tk_base != -1, ("tk_base -1 for native")); + shared_page_write(tk_base + offsetof(struct vdso_timekeep, + tk_ver), sizeof(uint32_t), &tk_ver); + KASSERT(host_sysentvec == 0, ("Native already registered")); + host_sysentvec = sv; +#ifdef COMPAT_FREEBSD32 + } +#endif + sv->sv_timekeep_base = sv->sv_shared_page_base + tk_base; + sv->sv_timekeep_off = tk_base; + timekeep_push_vdso(); } Modified: stable/9/sys/kern/kern_tc.c ============================================================================== --- stable/9/sys/kern/kern_tc.c Sat Sep 22 12:27:50 2012 (r240814) +++ stable/9/sys/kern/kern_tc.c Sat Sep 22 12:32:00 2012 (r240815) @@ -10,6 +10,7 @@ #include __FBSDID("$FreeBSD$"); +#include "opt_compat.h" #include "opt_ntp.h" #include @@ -20,6 +21,7 @@ __FBSDID("$FreeBSD$"); #include #include #include +#include /* * A large step happens on boot. This constant detects such steps. @@ -544,6 +546,7 @@ tc_windup(void) time_second = th->th_microtime.tv_sec; time_uptime = th->th_offset.sec; timehands = th; + timekeep_push_vdso(); } /* Report or change the active timecounter hardware. */ @@ -570,6 +573,7 @@ sysctl_kern_timecounter_hardware(SYSCTL_ (void)newtc->tc_get_timecount(newtc); timecounter = newtc; + timekeep_push_vdso(); return (0); } return (EINVAL); @@ -960,3 +964,63 @@ cputick2usec(uint64_t tick) } cpu_tick_f *cpu_ticks = tc_cpu_ticks; + +static int vdso_th_enable = 1; +static int +sysctl_fast_gettime(SYSCTL_HANDLER_ARGS) +{ + int old_vdso_th_enable, error; + + old_vdso_th_enable = vdso_th_enable; + error = sysctl_handle_int(oidp, &old_vdso_th_enable, 0, req); + if (error != 0) + return (error); + vdso_th_enable = old_vdso_th_enable; + timekeep_push_vdso(); + return (0); +} +SYSCTL_PROC(_kern_timecounter, OID_AUTO, fast_gettime, + CTLTYPE_INT | CTLFLAG_RW | CTLFLAG_MPSAFE, + NULL, 0, sysctl_fast_gettime, "I", "Enable fast time of day"); + +uint32_t +tc_fill_vdso_timehands(struct vdso_timehands *vdso_th) +{ + struct timehands *th; + uint32_t enabled; + + th = timehands; + vdso_th->th_algo = VDSO_TH_ALGO_1; + vdso_th->th_scale = th->th_scale; + vdso_th->th_offset_count = th->th_offset_count; + vdso_th->th_counter_mask = th->th_counter->tc_counter_mask; + vdso_th->th_offset = th->th_offset; + vdso_th->th_boottime = boottimebin; + enabled = cpu_fill_vdso_timehands(vdso_th); + if (!vdso_th_enable) + enabled = 0; + return (enabled); +} + +#ifdef COMPAT_FREEBSD32 +uint32_t +tc_fill_vdso_timehands32(struct vdso_timehands32 *vdso_th32) +{ + struct timehands *th; + uint32_t enabled; + + th = timehands; + vdso_th32->th_algo = VDSO_TH_ALGO_1; + *(uint64_t *)&vdso_th32->th_scale[0] = th->th_scale; + vdso_th32->th_offset_count = th->th_offset_count; + vdso_th32->th_counter_mask = th->th_counter->tc_counter_mask; + vdso_th32->th_offset.sec = th->th_offset.sec; + *(uint64_t *)&vdso_th32->th_offset.frac[0] = th->th_offset.frac; + vdso_th32->th_boottime.sec = boottimebin.sec; + *(uint64_t *)&vdso_th32->th_boottime.frac[0] = boottimebin.frac; + enabled = cpu_fill_vdso_timehands32(vdso_th32); + if (!vdso_th_enable) + enabled = 0; + return (enabled); +} +#endif Copied: stable/9/sys/kern/subr_dummy_vdso_tc.c (from r237433, head/sys/kern/subr_dummy_vdso_tc.c) ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ stable/9/sys/kern/subr_dummy_vdso_tc.c Sat Sep 22 12:32:00 2012 (r240815, copy of r237433, head/sys/kern/subr_dummy_vdso_tc.c) @@ -0,0 +1,49 @@ +/*- + * Copyright 2012 Konstantin Belousov . + * All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR + * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. + * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, + * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT + * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, + * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY + * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT + * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF + * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + */ + +#include +__FBSDID("$FreeBSD$"); + +#include "opt_compat.h" + +#include +#include + +uint32_t +cpu_fill_vdso_timehands(struct vdso_timehands *vdso_th) +{ + + return (0); +} + +#ifdef COMPAT_FREEBSD32 +uint32_t +cpu_fill_vdso_timehands32(struct vdso_timehands32 *vdso_th32) +{ + + return (0); +} +#endif Copied: stable/9/sys/mips/include/vdso.h (from r237433, head/sys/mips/include/vdso.h) ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ stable/9/sys/mips/include/vdso.h Sat Sep 22 12:32:00 2012 (r240815, copy of r237433, head/sys/mips/include/vdso.h) @@ -0,0 +1,41 @@ +/*- + * Copyright 2012 Konstantin Belousov . + * All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR + * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. + * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, + * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT + * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, + * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY + * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT + * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF + * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * $FreeBSD$ + */ + +#ifndef _MIPS_VDSO_H +#define _MIPS_VDSO_H + +#define VDSO_TIMEHANDS_MD \ + uint32_t th_res[8]; + +#ifdef _KERNEL +#ifdef COMPAT_FREEBSD32 + +#define VDSO_TIMEHANDS_MD32 VDSO_TIMEHANDS_MD + +#endif +#endif +#endif Copied: stable/9/sys/pc98/include/vdso.h (from r237433, head/sys/pc98/include/vdso.h) ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ stable/9/sys/pc98/include/vdso.h Sat Sep 22 12:32:00 2012 (r240815, copy of r237433, head/sys/pc98/include/vdso.h) @@ -0,0 +1,6 @@ +/*- + * This file is in the public domain. + */ +/* $FreeBSD$ */ + +#include Copied: stable/9/sys/powerpc/include/vdso.h (from r237433, head/sys/powerpc/include/vdso.h) ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ stable/9/sys/powerpc/include/vdso.h Sat Sep 22 12:32:00 2012 (r240815, copy of r237433, head/sys/powerpc/include/vdso.h) @@ -0,0 +1,41 @@ +/*- + * Copyright 2012 Konstantin Belousov . + * All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR + * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. + * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, + * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT + * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, + * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY + * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT + * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF + * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * $FreeBSD$ + */ + +#ifndef _POWERPC_VDSO_H +#define _POWERPC_VDSO_H + +#define VDSO_TIMEHANDS_MD \ + uint32_t th_res[8]; + +#ifdef _KERNEL +#ifdef COMPAT_FREEBSD32 + +#define VDSO_TIMEHANDS_MD32 VDSO_TIMEHANDS_MD + +#endif +#endif +#endif Copied: stable/9/sys/sparc64/include/vdso.h (from r237433, head/sys/sparc64/include/vdso.h) ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ stable/9/sys/sparc64/include/vdso.h Sat Sep 22 12:32:00 2012 (r240815, copy of r237433, head/sys/sparc64/include/vdso.h) @@ -0,0 +1,34 @@ +/*- + * Copyright 2012 Konstantin Belousov . + * All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR + * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. + * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, + * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT + * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, + * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY + * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT + * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF + * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * $FreeBSD$ + */ + +#ifndef _SPARC64_VDSO_H +#define _SPARC64_VDSO_H + +#define VDSO_TIMEHANDS_MD \ + uint32_t th_res[8]; + +#endif Modified: stable/9/sys/sys/sysent.h ============================================================================== --- stable/9/sys/sys/sysent.h Sat Sep 22 12:27:50 2012 (r240814) +++ stable/9/sys/sys/sysent.h Sat Sep 22 12:32:00 2012 (r240815) @@ -124,6 +124,10 @@ struct sysentvec { vm_offset_t sv_shared_page_base; vm_offset_t sv_shared_page_len; vm_offset_t sv_sigcode_base; + vm_offset_t sv_timekeep_base; + int sv_timekeep_off; + int sv_timekeep_curr; + uint32_t sv_timekeep_gen; void *sv_shared_page_obj; void (*sv_schedtail)(struct thread *); }; @@ -261,8 +265,6 @@ int shared_page_alloc(int size, int alig int shared_page_fill(int size, int align, const void *data); void shared_page_write(int base, int size, const void *data); void exec_sysvec_init(void *param); -struct sf_buf *shared_page_write_start(int base); -void shared_page_write_end(struct sf_buf *sf); #define INIT_SYSENTVEC(name, sv) \ SYSINIT(name, SI_SUB_EXEC, SI_ORDER_ANY, \ Copied and modified: stable/9/sys/sys/vdso.h (from r237433, head/sys/sys/vdso.h) ============================================================================== --- head/sys/sys/vdso.h Fri Jun 22 07:06:40 2012 (r237433, copy source) +++ stable/9/sys/sys/vdso.h Sat Sep 22 12:32:00 2012 (r240815) @@ -29,7 +29,6 @@ #define _SYS_VDSO_H #include -#include #include struct vdso_timehands { @@ -74,6 +73,8 @@ u_int __vdso_gettc(const struct vdso_tim #ifdef _KERNEL +void timekeep_push_vdso(void); + uint32_t tc_fill_vdso_timehands(struct vdso_timehands *vdso_th); /* @@ -86,9 +87,6 @@ uint32_t tc_fill_vdso_timehands(struct v */ uint32_t cpu_fill_vdso_timehands(struct vdso_timehands *vdso_th); -typedef void (*tc_windup_fn)(void *); -EVENTHANDLER_DECLARE(tc_windup, tc_windup_fn); - #define VDSO_TH_NUM 4 #ifdef COMPAT_FREEBSD32 Copied: stable/9/sys/x86/include/vdso.h (from r237433, head/sys/x86/include/vdso.h) ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ stable/9/sys/x86/include/vdso.h Sat Sep 22 12:32:00 2012 (r240815, copy of r237433, head/sys/x86/include/vdso.h) @@ -0,0 +1,42 @@ +/*- + * Copyright 2012 Konstantin Belousov . + * All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR + * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. + * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, + * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT + * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, + * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY + * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT + * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF + * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * $FreeBSD$ + */ + +#ifndef _X86_VDSO_H +#define _X86_VDSO_H + +#define VDSO_TIMEHANDS_MD \ + uint32_t th_x86_shift; \ + uint32_t th_res[7]; + +#ifdef _KERNEL +#ifdef COMPAT_FREEBSD32 + +#define VDSO_TIMEHANDS_MD32 VDSO_TIMEHANDS_MD + +#endif +#endif +#endif Modified: stable/9/sys/x86/x86/tsc.c ============================================================================== --- stable/9/sys/x86/x86/tsc.c Sat Sep 22 12:27:50 2012 (r240814) +++ stable/9/sys/x86/x86/tsc.c Sat Sep 22 12:32:00 2012 (r240815) @@ -27,6 +27,7 @@ #include __FBSDID("$FreeBSD$"); +#include "opt_compat.h" #include "opt_clock.h" #include @@ -41,6 +42,7 @@ __FBSDID("$FreeBSD$"); #include #include #include +#include #include #include #include @@ -606,3 +608,23 @@ tsc_get_timecount_low(struct timecounter : "=a" (rv) : "c" ((int)(intptr_t)tc->tc_priv) : "edx"); return (rv); } + +uint32_t +cpu_fill_vdso_timehands(struct vdso_timehands *vdso_th) +{ + + vdso_th->th_x86_shift = (int)(intptr_t)timecounter->tc_priv; + bzero(vdso_th->th_res, sizeof(vdso_th->th_res)); + return (timecounter == &tsc_timecounter); +} + +#ifdef COMPAT_FREEBSD32 +uint32_t +cpu_fill_vdso_timehands32(struct vdso_timehands32 *vdso_th32) +{ + + vdso_th32->th_x86_shift = (int)(intptr_t)timecounter->tc_priv; + bzero(vdso_th32->th_res, sizeof(vdso_th32->th_res)); + return (timecounter == &tsc_timecounter); +} +#endif From owner-svn-src-stable@FreeBSD.ORG Sat Sep 22 12:34:02 2012 Return-Path: Delivered-To: svn-src-stable@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id AD1C11065674; Sat, 22 Sep 2012 12:34:02 +0000 (UTC) (envelope-from kib@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 97A8A8FC08; Sat, 22 Sep 2012 12:34:02 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q8MCY2Um066707; Sat, 22 Sep 2012 12:34:02 GMT (envelope-from kib@svn.freebsd.org) Received: (from kib@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q8MCY2qT066703; Sat, 22 Sep 2012 12:34:02 GMT (envelope-from kib@svn.freebsd.org) Message-Id: <201209221234.q8MCY2qT066703@svn.freebsd.org> From: Konstantin Belousov Date: Sat, 22 Sep 2012 12:34:02 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r240816 - in stable/9/sys/i386: i386 include X-BeenThere: svn-src-stable@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for all the -stable branches of the src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 22 Sep 2012 12:34:02 -0000 Author: kib Date: Sat Sep 22 12:34:02 2012 New Revision: 240816 URL: http://svn.freebsd.org/changeset/base/240816 Log: MFC r237435: Enable shared page on i386, now it has a use for vdso_timehands. MFC r237445: Commit changes missed from r237435. Properly calculate the signal trampoline addresses after the shared page is enabled. Handle FreeBSD ABIs without shared page support too. Modified: stable/9/sys/i386/i386/elf_machdep.c stable/9/sys/i386/i386/machdep.c stable/9/sys/i386/include/vmparam.h Directory Properties: stable/9/sys/ (props changed) Modified: stable/9/sys/i386/i386/elf_machdep.c ============================================================================== --- stable/9/sys/i386/i386/elf_machdep.c Sat Sep 22 12:32:00 2012 (r240815) +++ stable/9/sys/i386/i386/elf_machdep.c Sat Sep 22 12:34:02 2012 (r240816) @@ -74,12 +74,15 @@ struct sysentvec elf32_freebsd_sysvec = .sv_setregs = exec_setregs, .sv_fixlimit = NULL, .sv_maxssiz = NULL, - .sv_flags = SV_ABI_FREEBSD | SV_IA32 | SV_ILP32, + .sv_flags = SV_ABI_FREEBSD | SV_IA32 | SV_ILP32 | SV_SHP, .sv_set_syscall_retval = cpu_set_syscall_retval, .sv_fetch_syscall_args = cpu_fetch_syscall_args, .sv_syscallnames = syscallnames, + .sv_shared_page_base = SHAREDPAGE, + .sv_shared_page_len = PAGE_SIZE, .sv_schedtail = NULL, }; +INIT_SYSENTVEC(elf32_sysvec, &elf32_freebsd_sysvec); static Elf32_Brandinfo freebsd_brand_info = { .brand = ELFOSABI_FREEBSD, Modified: stable/9/sys/i386/i386/machdep.c ============================================================================== --- stable/9/sys/i386/i386/machdep.c Sat Sep 22 12:32:00 2012 (r240815) +++ stable/9/sys/i386/i386/machdep.c Sat Sep 22 12:34:02 2012 (r240816) @@ -472,7 +472,13 @@ osendsig(sig_t catcher, ksiginfo_t *ksi, } regs->tf_esp = (int)fp; - regs->tf_eip = PS_STRINGS - szosigcode; + if (p->p_sysent->sv_sigcode_base != 0) { + regs->tf_eip = p->p_sysent->sv_sigcode_base + szsigcode - + szosigcode; + } else { + /* a.out sysentvec does not use shared page */ + regs->tf_eip = p->p_sysent->sv_psstrings - szosigcode; + } regs->tf_eflags &= ~(PSL_T | PSL_D); regs->tf_cs = _ucodesel; regs->tf_ds = _udatasel; @@ -599,7 +605,8 @@ freebsd4_sendsig(sig_t catcher, ksiginfo } regs->tf_esp = (int)sfp; - regs->tf_eip = PS_STRINGS - szfreebsd4_sigcode; + regs->tf_eip = p->p_sysent->sv_sigcode_base + szsigcode - + szfreebsd4_sigcode; regs->tf_eflags &= ~(PSL_T | PSL_D); regs->tf_cs = _ucodesel; regs->tf_ds = _udatasel; @@ -750,7 +757,7 @@ sendsig(sig_t catcher, ksiginfo_t *ksi, } regs->tf_esp = (int)sfp; - regs->tf_eip = PS_STRINGS - *(p->p_sysent->sv_szsigcode); + regs->tf_eip = p->p_sysent->sv_sigcode_base; regs->tf_eflags &= ~(PSL_T | PSL_D); regs->tf_cs = _ucodesel; regs->tf_ds = _udatasel; Modified: stable/9/sys/i386/include/vmparam.h ============================================================================== --- stable/9/sys/i386/include/vmparam.h Sat Sep 22 12:32:00 2012 (r240815) +++ stable/9/sys/i386/include/vmparam.h Sat Sep 22 12:34:02 2012 (r240816) @@ -165,7 +165,8 @@ #define VM_MAXUSER_ADDRESS VADDR(PTDPTDI, 0) -#define USRSTACK VM_MAXUSER_ADDRESS +#define SHAREDPAGE (VM_MAXUSER_ADDRESS - PAGE_SIZE) +#define USRSTACK SHAREDPAGE #define VM_MAX_ADDRESS VADDR(PTDPTDI, PTDPTDI) #define VM_MIN_ADDRESS ((vm_offset_t)0) From owner-svn-src-stable@FreeBSD.ORG Sat Sep 22 12:35:23 2012 Return-Path: Delivered-To: svn-src-stable@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 49DEC106564A; Sat, 22 Sep 2012 12:35:23 +0000 (UTC) (envelope-from kib@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 34B3F8FC0C; Sat, 22 Sep 2012 12:35:23 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q8MCZNgm066911; Sat, 22 Sep 2012 12:35:23 GMT (envelope-from kib@svn.freebsd.org) Received: (from kib@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q8MCZNj8066908; Sat, 22 Sep 2012 12:35:23 GMT (envelope-from kib@svn.freebsd.org) Message-Id: <201209221235.q8MCZNj8066908@svn.freebsd.org> From: Konstantin Belousov Date: Sat, 22 Sep 2012 12:35:23 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r240817 - stable/9/sys/sys X-BeenThere: svn-src-stable@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for all the -stable branches of the src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 22 Sep 2012 12:35:23 -0000 Author: kib Date: Sat Sep 22 12:35:22 2012 New Revision: 240817 URL: http://svn.freebsd.org/changeset/base/240817 Log: MFC r237476: Remove no longer needed forward declaration for struct sf_buf. Modified: stable/9/sys/sys/sysent.h Directory Properties: stable/9/sys/ (props changed) Modified: stable/9/sys/sys/sysent.h ============================================================================== --- stable/9/sys/sys/sysent.h Sat Sep 22 12:34:02 2012 (r240816) +++ stable/9/sys/sys/sysent.h Sat Sep 22 12:35:22 2012 (r240817) @@ -260,7 +260,6 @@ int lkmressys(struct thread *, struct no int syscall_thread_enter(struct thread *td, struct sysent *se); void syscall_thread_exit(struct thread *td, struct sysent *se); -struct sf_buf; int shared_page_alloc(int size, int align); int shared_page_fill(int size, int align, const void *data); void shared_page_write(int base, int size, const void *data); From owner-svn-src-stable@FreeBSD.ORG Sat Sep 22 12:36:32 2012 Return-Path: Delivered-To: svn-src-stable@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 8A5BE106566B; Sat, 22 Sep 2012 12:36:32 +0000 (UTC) (envelope-from kib@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 6B2BD8FC18; Sat, 22 Sep 2012 12:36:32 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q8MCaWpC067123; Sat, 22 Sep 2012 12:36:32 GMT (envelope-from kib@svn.freebsd.org) Received: (from kib@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q8MCaW4w067119; Sat, 22 Sep 2012 12:36:32 GMT (envelope-from kib@svn.freebsd.org) Message-Id: <201209221236.q8MCaW4w067119@svn.freebsd.org> From: Konstantin Belousov Date: Sat, 22 Sep 2012 12:36:32 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r240818 - in stable/9/sys: conf kern X-BeenThere: svn-src-stable@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for all the -stable branches of the src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 22 Sep 2012 12:36:32 -0000 Author: kib Date: Sat Sep 22 12:36:31 2012 New Revision: 240818 URL: http://svn.freebsd.org/changeset/base/240818 Log: MFC r237477: Move the code dealing with shared page into a dedicated kern_sharedpage.c source file from kern_exec.c. Added: stable/9/sys/kern/kern_sharedpage.c - copied unchanged from r237477, head/sys/kern/kern_sharedpage.c Modified: stable/9/sys/conf/files stable/9/sys/kern/kern_exec.c Directory Properties: stable/9/sys/ (props changed) stable/9/sys/conf/ (props changed) Modified: stable/9/sys/conf/files ============================================================================== --- stable/9/sys/conf/files Sat Sep 22 12:35:22 2012 (r240817) +++ stable/9/sys/conf/files Sat Sep 22 12:36:31 2012 (r240818) @@ -2388,6 +2388,7 @@ kern/kern_rmlock.c standard kern/kern_rwlock.c standard kern/kern_sdt.c optional kdtrace_hooks kern/kern_sema.c standard +kern/kern_sharedpage.c standard kern/kern_shutdown.c standard kern/kern_sig.c standard kern/kern_switch.c standard Modified: stable/9/sys/kern/kern_exec.c ============================================================================== --- stable/9/sys/kern/kern_exec.c Sat Sep 22 12:35:22 2012 (r240817) +++ stable/9/sys/kern/kern_exec.c Sat Sep 22 12:36:31 2012 (r240818) @@ -28,7 +28,6 @@ __FBSDID("$FreeBSD$"); #include "opt_capsicum.h" -#include "opt_compat.h" #include "opt_hwpmc_hooks.h" #include "opt_kdtrace.h" #include "opt_ktrace.h" @@ -65,7 +64,6 @@ __FBSDID("$FreeBSD$"); #include #include #include -#include #include #include #ifdef KTRACE @@ -1515,193 +1513,3 @@ exec_unregister(execsw_arg) execsw = newexecsw; return (0); } - -static struct sx shared_page_alloc_sx; -static vm_object_t shared_page_obj; -static int shared_page_free; -char *shared_page_mapping; - -void -shared_page_write(int base, int size, const void *data) -{ - - bcopy(data, shared_page_mapping + base, size); -} - -static int -shared_page_alloc_locked(int size, int align) -{ - int res; - - res = roundup(shared_page_free, align); - if (res + size >= IDX_TO_OFF(shared_page_obj->size)) - res = -1; - else - shared_page_free = res + size; - return (res); -} - -int -shared_page_alloc(int size, int align) -{ - int res; - - sx_xlock(&shared_page_alloc_sx); - res = shared_page_alloc_locked(size, align); - sx_xunlock(&shared_page_alloc_sx); - return (res); -} - -int -shared_page_fill(int size, int align, const void *data) -{ - int res; - - sx_xlock(&shared_page_alloc_sx); - res = shared_page_alloc_locked(size, align); - if (res != -1) - shared_page_write(res, size, data); - sx_xunlock(&shared_page_alloc_sx); - return (res); -} - -static void -shared_page_init(void *dummy __unused) -{ - vm_page_t m; - vm_offset_t addr; - - sx_init(&shared_page_alloc_sx, "shpsx"); - shared_page_obj = vm_pager_allocate(OBJT_PHYS, 0, PAGE_SIZE, - VM_PROT_DEFAULT, 0, NULL); - VM_OBJECT_LOCK(shared_page_obj); - m = vm_page_grab(shared_page_obj, 0, VM_ALLOC_RETRY | VM_ALLOC_NOBUSY | - VM_ALLOC_ZERO); - m->valid = VM_PAGE_BITS_ALL; - VM_OBJECT_UNLOCK(shared_page_obj); - addr = kmem_alloc_nofault(kernel_map, PAGE_SIZE); - pmap_qenter(addr, &m, 1); - shared_page_mapping = (char *)addr; -} - -SYSINIT(shp, SI_SUB_EXEC, SI_ORDER_FIRST, (sysinit_cfunc_t)shared_page_init, - NULL); - -static void -timehands_update(struct sysentvec *sv) -{ - struct vdso_timehands th; - struct vdso_timekeep *tk; - uint32_t enabled, idx; - - enabled = tc_fill_vdso_timehands(&th); - tk = (struct vdso_timekeep *)(shared_page_mapping + - sv->sv_timekeep_off); - idx = sv->sv_timekeep_curr; - atomic_store_rel_32(&tk->tk_th[idx].th_gen, 0); - if (++idx >= VDSO_TH_NUM) - idx = 0; - sv->sv_timekeep_curr = idx; - if (++sv->sv_timekeep_gen == 0) - sv->sv_timekeep_gen = 1; - th.th_gen = 0; - if (enabled) - tk->tk_th[idx] = th; - tk->tk_enabled = enabled; - atomic_store_rel_32(&tk->tk_th[idx].th_gen, sv->sv_timekeep_gen); - tk->tk_current = idx; -} - -#ifdef COMPAT_FREEBSD32 -static void -timehands_update32(struct sysentvec *sv) -{ - struct vdso_timekeep32 *tk; - struct vdso_timehands32 th; - uint32_t enabled, idx; - - enabled = tc_fill_vdso_timehands32(&th); - tk = (struct vdso_timekeep32 *)(shared_page_mapping + - sv->sv_timekeep_off); - idx = sv->sv_timekeep_curr; - atomic_store_rel_32(&tk->tk_th[idx].th_gen, 0); - if (++idx >= VDSO_TH_NUM) - idx = 0; - sv->sv_timekeep_curr = idx; - if (++sv->sv_timekeep_gen == 0) - sv->sv_timekeep_gen = 1; - th.th_gen = 0; - if (enabled) - tk->tk_th[idx] = th; - tk->tk_enabled = enabled; - atomic_store_rel_32(&tk->tk_th[idx].th_gen, sv->sv_timekeep_gen); - tk->tk_current = idx; -} -#endif - -/* - * This is hackish, but easiest way to avoid creating list structures - * that needs to be iterated over from the hardclock interrupt - * context. - */ -static struct sysentvec *host_sysentvec; -#ifdef COMPAT_FREEBSD32 -static struct sysentvec *compat32_sysentvec; -#endif - -void -timekeep_push_vdso(void) -{ - - if (host_sysentvec != NULL && host_sysentvec->sv_timekeep_base != 0) - timehands_update(host_sysentvec); -#ifdef COMPAT_FREEBSD32 - if (compat32_sysentvec != NULL && - compat32_sysentvec->sv_timekeep_base != 0) - timehands_update32(compat32_sysentvec); -#endif -} - -void -exec_sysvec_init(void *param) -{ - struct sysentvec *sv; - int tk_base; - uint32_t tk_ver; - - sv = (struct sysentvec *)param; - - if ((sv->sv_flags & SV_SHP) == 0) - return; - sv->sv_shared_page_obj = shared_page_obj; - sv->sv_sigcode_base = sv->sv_shared_page_base + - shared_page_fill(*(sv->sv_szsigcode), 16, sv->sv_sigcode); - if ((sv->sv_flags & SV_ABI_MASK) != SV_ABI_FREEBSD) - return; - tk_ver = VDSO_TK_VER_CURR; -#ifdef COMPAT_FREEBSD32 - if ((sv->sv_flags & SV_ILP32) != 0) { - tk_base = shared_page_alloc(sizeof(struct vdso_timekeep32) + - sizeof(struct vdso_timehands32) * VDSO_TH_NUM, 16); - KASSERT(tk_base != -1, ("tk_base -1 for 32bit")); - shared_page_write(tk_base + offsetof(struct vdso_timekeep32, - tk_ver), sizeof(uint32_t), &tk_ver); - KASSERT(compat32_sysentvec == 0, - ("Native compat32 already registered")); - compat32_sysentvec = sv; - } else { -#endif - tk_base = shared_page_alloc(sizeof(struct vdso_timekeep) + - sizeof(struct vdso_timehands) * VDSO_TH_NUM, 16); - KASSERT(tk_base != -1, ("tk_base -1 for native")); - shared_page_write(tk_base + offsetof(struct vdso_timekeep, - tk_ver), sizeof(uint32_t), &tk_ver); - KASSERT(host_sysentvec == 0, ("Native already registered")); - host_sysentvec = sv; -#ifdef COMPAT_FREEBSD32 - } -#endif - sv->sv_timekeep_base = sv->sv_shared_page_base + tk_base; - sv->sv_timekeep_off = tk_base; - timekeep_push_vdso(); -} Copied: stable/9/sys/kern/kern_sharedpage.c (from r237477, head/sys/kern/kern_sharedpage.c) ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ stable/9/sys/kern/kern_sharedpage.c Sat Sep 22 12:36:31 2012 (r240818, copy of r237477, head/sys/kern/kern_sharedpage.c) @@ -0,0 +1,240 @@ +/*- + * Copyright (c) 2010, 2012 Konstantin Belousov + * All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND + * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE + * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE + * ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE + * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL + * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS + * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) + * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT + * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY + * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF + * SUCH DAMAGE. + */ + +#include +__FBSDID("$FreeBSD$"); + +#include "opt_compat.h" +#include "opt_vm.h" + +#include +#include +#include +#include +#include +#include +#include +#include + +#include +#include +#include +#include +#include +#include +#include +#include +#include + +static struct sx shared_page_alloc_sx; +static vm_object_t shared_page_obj; +static int shared_page_free; +char *shared_page_mapping; + +void +shared_page_write(int base, int size, const void *data) +{ + + bcopy(data, shared_page_mapping + base, size); +} + +static int +shared_page_alloc_locked(int size, int align) +{ + int res; + + res = roundup(shared_page_free, align); + if (res + size >= IDX_TO_OFF(shared_page_obj->size)) + res = -1; + else + shared_page_free = res + size; + return (res); +} + +int +shared_page_alloc(int size, int align) +{ + int res; + + sx_xlock(&shared_page_alloc_sx); + res = shared_page_alloc_locked(size, align); + sx_xunlock(&shared_page_alloc_sx); + return (res); +} + +int +shared_page_fill(int size, int align, const void *data) +{ + int res; + + sx_xlock(&shared_page_alloc_sx); + res = shared_page_alloc_locked(size, align); + if (res != -1) + shared_page_write(res, size, data); + sx_xunlock(&shared_page_alloc_sx); + return (res); +} + +static void +shared_page_init(void *dummy __unused) +{ + vm_page_t m; + vm_offset_t addr; + + sx_init(&shared_page_alloc_sx, "shpsx"); + shared_page_obj = vm_pager_allocate(OBJT_PHYS, 0, PAGE_SIZE, + VM_PROT_DEFAULT, 0, NULL); + VM_OBJECT_LOCK(shared_page_obj); + m = vm_page_grab(shared_page_obj, 0, VM_ALLOC_RETRY | VM_ALLOC_NOBUSY | + VM_ALLOC_ZERO); + m->valid = VM_PAGE_BITS_ALL; + VM_OBJECT_UNLOCK(shared_page_obj); + addr = kmem_alloc_nofault(kernel_map, PAGE_SIZE); + pmap_qenter(addr, &m, 1); + shared_page_mapping = (char *)addr; +} + +SYSINIT(shp, SI_SUB_EXEC, SI_ORDER_FIRST, (sysinit_cfunc_t)shared_page_init, + NULL); + +static void +timehands_update(struct sysentvec *sv) +{ + struct vdso_timehands th; + struct vdso_timekeep *tk; + uint32_t enabled, idx; + + enabled = tc_fill_vdso_timehands(&th); + tk = (struct vdso_timekeep *)(shared_page_mapping + + sv->sv_timekeep_off); + idx = sv->sv_timekeep_curr; + atomic_store_rel_32(&tk->tk_th[idx].th_gen, 0); + if (++idx >= VDSO_TH_NUM) + idx = 0; + sv->sv_timekeep_curr = idx; + if (++sv->sv_timekeep_gen == 0) + sv->sv_timekeep_gen = 1; + th.th_gen = 0; + if (enabled) + tk->tk_th[idx] = th; + tk->tk_enabled = enabled; + atomic_store_rel_32(&tk->tk_th[idx].th_gen, sv->sv_timekeep_gen); + tk->tk_current = idx; +} + +#ifdef COMPAT_FREEBSD32 +static void +timehands_update32(struct sysentvec *sv) +{ + struct vdso_timekeep32 *tk; + struct vdso_timehands32 th; + uint32_t enabled, idx; + + enabled = tc_fill_vdso_timehands32(&th); + tk = (struct vdso_timekeep32 *)(shared_page_mapping + + sv->sv_timekeep_off); + idx = sv->sv_timekeep_curr; + atomic_store_rel_32(&tk->tk_th[idx].th_gen, 0); + if (++idx >= VDSO_TH_NUM) + idx = 0; + sv->sv_timekeep_curr = idx; + if (++sv->sv_timekeep_gen == 0) + sv->sv_timekeep_gen = 1; + th.th_gen = 0; + if (enabled) + tk->tk_th[idx] = th; + tk->tk_enabled = enabled; + atomic_store_rel_32(&tk->tk_th[idx].th_gen, sv->sv_timekeep_gen); + tk->tk_current = idx; +} +#endif + +/* + * This is hackish, but easiest way to avoid creating list structures + * that needs to be iterated over from the hardclock interrupt + * context. + */ +static struct sysentvec *host_sysentvec; +#ifdef COMPAT_FREEBSD32 +static struct sysentvec *compat32_sysentvec; +#endif + +void +timekeep_push_vdso(void) +{ + + if (host_sysentvec != NULL && host_sysentvec->sv_timekeep_base != 0) + timehands_update(host_sysentvec); +#ifdef COMPAT_FREEBSD32 + if (compat32_sysentvec != NULL && + compat32_sysentvec->sv_timekeep_base != 0) + timehands_update32(compat32_sysentvec); +#endif +} + +void +exec_sysvec_init(void *param) +{ + struct sysentvec *sv; + int tk_base; + uint32_t tk_ver; + + sv = (struct sysentvec *)param; + + if ((sv->sv_flags & SV_SHP) == 0) + return; + sv->sv_shared_page_obj = shared_page_obj; + sv->sv_sigcode_base = sv->sv_shared_page_base + + shared_page_fill(*(sv->sv_szsigcode), 16, sv->sv_sigcode); + if ((sv->sv_flags & SV_ABI_MASK) != SV_ABI_FREEBSD) + return; + tk_ver = VDSO_TK_VER_CURR; +#ifdef COMPAT_FREEBSD32 + if ((sv->sv_flags & SV_ILP32) != 0) { + tk_base = shared_page_alloc(sizeof(struct vdso_timekeep32) + + sizeof(struct vdso_timehands32) * VDSO_TH_NUM, 16); + KASSERT(tk_base != -1, ("tk_base -1 for 32bit")); + shared_page_write(tk_base + offsetof(struct vdso_timekeep32, + tk_ver), sizeof(uint32_t), &tk_ver); + KASSERT(compat32_sysentvec == 0, + ("Native compat32 already registered")); + compat32_sysentvec = sv; + } else { +#endif + tk_base = shared_page_alloc(sizeof(struct vdso_timekeep) + + sizeof(struct vdso_timehands) * VDSO_TH_NUM, 16); + KASSERT(tk_base != -1, ("tk_base -1 for native")); + shared_page_write(tk_base + offsetof(struct vdso_timekeep, + tk_ver), sizeof(uint32_t), &tk_ver); + KASSERT(host_sysentvec == 0, ("Native already registered")); + host_sysentvec = sv; +#ifdef COMPAT_FREEBSD32 + } +#endif + sv->sv_timekeep_base = sv->sv_shared_page_base + tk_base; + sv->sv_timekeep_off = tk_base; + timekeep_push_vdso(); +} From owner-svn-src-stable@FreeBSD.ORG Sat Sep 22 12:38:20 2012 Return-Path: Delivered-To: svn-src-stable@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 474DA1065676; Sat, 22 Sep 2012 12:38:20 +0000 (UTC) (envelope-from kib@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 2E8508FC1C; Sat, 22 Sep 2012 12:38:20 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q8MCcKaj067397; Sat, 22 Sep 2012 12:38:20 GMT (envelope-from kib@svn.freebsd.org) Received: (from kib@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q8MCcJPC067386; Sat, 22 Sep 2012 12:38:19 GMT (envelope-from kib@svn.freebsd.org) Message-Id: <201209221238.q8MCcJPC067386@svn.freebsd.org> From: Konstantin Belousov Date: Sat, 22 Sep 2012 12:38:19 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r240819 - in stable/9/lib/libc: amd64/sys gen i386/sys include sys X-BeenThere: svn-src-stable@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for all the -stable branches of the src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 22 Sep 2012 12:38:20 -0000 Author: kib Date: Sat Sep 22 12:38:19 2012 New Revision: 240819 URL: http://svn.freebsd.org/changeset/base/240819 Log: MFC r237434: Use struct vdso_timehands data to implement fast gettimeofday(2) and clock_gettime(2) functions if supported. Added: stable/9/lib/libc/amd64/sys/__vdso_gettc.c - copied unchanged from r237434, head/lib/libc/amd64/sys/__vdso_gettc.c stable/9/lib/libc/i386/sys/__vdso_gettc.c - copied unchanged from r237434, head/lib/libc/i386/sys/__vdso_gettc.c stable/9/lib/libc/sys/__vdso_gettimeofday.c - copied unchanged from r237434, head/lib/libc/sys/__vdso_gettimeofday.c stable/9/lib/libc/sys/clock_gettime.c - copied unchanged from r237434, head/lib/libc/sys/clock_gettime.c stable/9/lib/libc/sys/gettimeofday.c - copied unchanged from r237434, head/lib/libc/sys/gettimeofday.c Modified: stable/9/lib/libc/amd64/sys/Makefile.inc stable/9/lib/libc/gen/aux.c stable/9/lib/libc/i386/sys/Makefile.inc stable/9/lib/libc/include/libc_private.h stable/9/lib/libc/sys/Makefile.inc Directory Properties: stable/9/lib/libc/ (props changed) stable/9/lib/libc/sys/ (props changed) Modified: stable/9/lib/libc/amd64/sys/Makefile.inc ============================================================================== --- stable/9/lib/libc/amd64/sys/Makefile.inc Sat Sep 22 12:36:31 2012 (r240818) +++ stable/9/lib/libc/amd64/sys/Makefile.inc Sat Sep 22 12:38:19 2012 (r240819) @@ -1,7 +1,8 @@ # from: Makefile.inc,v 1.1 1993/09/03 19:04:23 jtc Exp # $FreeBSD$ -SRCS+= amd64_get_fsbase.c amd64_get_gsbase.c amd64_set_fsbase.c amd64_set_gsbase.c +SRCS+= amd64_get_fsbase.c amd64_get_gsbase.c amd64_set_fsbase.c \ + amd64_set_gsbase.c __vdso_gettc.c MDASM= vfork.S brk.S cerror.S exect.S getcontext.S pipe.S ptrace.S \ reboot.S sbrk.S setlogin.S sigreturn.S Copied: stable/9/lib/libc/amd64/sys/__vdso_gettc.c (from r237434, head/lib/libc/amd64/sys/__vdso_gettc.c) ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ stable/9/lib/libc/amd64/sys/__vdso_gettc.c Sat Sep 22 12:38:19 2012 (r240819, copy of r237434, head/lib/libc/amd64/sys/__vdso_gettc.c) @@ -0,0 +1,49 @@ +/*- + * Copyright (c) 2012 Konstantin Belousov + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND + * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE + * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE + * ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE + * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL + * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS + * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) + * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT + * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY + * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF + * SUCH DAMAGE. + */ + +#include +__FBSDID("$FreeBSD$"); + +#include +#include +#include +#include + +static u_int +__vdso_gettc_low(const struct vdso_timehands *th) +{ + uint32_t rv; + + __asm __volatile("rdtsc; shrd %%cl, %%edx, %0" + : "=a" (rv) : "c" (th->th_x86_shift) : "edx"); + return (rv); +} + +u_int +__vdso_gettc(const struct vdso_timehands *th) +{ + + return (th->th_x86_shift > 0 ? __vdso_gettc_low(th) : rdtsc32()); +} Modified: stable/9/lib/libc/gen/aux.c ============================================================================== --- stable/9/lib/libc/gen/aux.c Sat Sep 22 12:36:31 2012 (r240818) +++ stable/9/lib/libc/gen/aux.c Sat Sep 22 12:38:19 2012 (r240819) @@ -66,6 +66,7 @@ __init_elf_aux_vector(void) static pthread_once_t aux_once = PTHREAD_ONCE_INIT; static int pagesize, osreldate, canary_len, ncpus, pagesizes_len; static char *canary, *pagesizes; +static void *timekeep; static void init_aux(void) @@ -101,6 +102,10 @@ init_aux(void) case AT_NCPUS: ncpus = aux->a_un.a_val; break; + + case AT_TIMEKEEP: + timekeep = aux->a_un.a_ptr; + break; } } } @@ -163,6 +168,16 @@ _elf_aux_info(int aux, void *buf, int bu } else res = EINVAL; break; + case AT_TIMEKEEP: + if (buflen == sizeof(void *)) { + if (timekeep != NULL) { + *(void **)buf = timekeep; + res = 0; + } else + res = ENOENT; + } else + res = EINVAL; + break; default: res = ENOENT; break; Modified: stable/9/lib/libc/i386/sys/Makefile.inc ============================================================================== --- stable/9/lib/libc/i386/sys/Makefile.inc Sat Sep 22 12:36:31 2012 (r240818) +++ stable/9/lib/libc/i386/sys/Makefile.inc Sat Sep 22 12:38:19 2012 (r240819) @@ -5,7 +5,8 @@ SRCS+= i386_clr_watch.c i386_set_watch.c i386_vm86.c .endif SRCS+= i386_get_fsbase.c i386_get_gsbase.c i386_get_ioperm.c i386_get_ldt.c \ - i386_set_fsbase.c i386_set_gsbase.c i386_set_ioperm.c i386_set_ldt.c + i386_set_fsbase.c i386_set_gsbase.c i386_set_ioperm.c i386_set_ldt.c \ + __vdso_gettc.c MDASM= Ovfork.S brk.S cerror.S exect.S getcontext.S pipe.S ptrace.S \ reboot.S sbrk.S setlogin.S sigreturn.S syscall.S Copied: stable/9/lib/libc/i386/sys/__vdso_gettc.c (from r237434, head/lib/libc/i386/sys/__vdso_gettc.c) ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ stable/9/lib/libc/i386/sys/__vdso_gettc.c Sat Sep 22 12:38:19 2012 (r240819, copy of r237434, head/lib/libc/i386/sys/__vdso_gettc.c) @@ -0,0 +1,50 @@ +/*- + * Copyright (c) 2012 Konstantin Belousov + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND + * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE + * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE + * ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE + * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL + * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS + * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) + * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT + * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY + * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF + * SUCH DAMAGE. + */ + +#include +__FBSDID("$FreeBSD$"); + +#include +#include +#include +#include + +static u_int +__vdso_gettc_low(const struct vdso_timehands *th) +{ + uint32_t rv; + + __asm __volatile("rdtsc; shrd %%cl, %%edx, %0" + : "=a" (rv) : "c" (th->th_x86_shift) : "edx"); + return (rv); +} + +#pragma weak __vdso_gettc +u_int +__vdso_gettc(const struct vdso_timehands *th) +{ + + return (th->th_x86_shift > 0 ? __vdso_gettc_low(th) : rdtsc32()); +} Modified: stable/9/lib/libc/include/libc_private.h ============================================================================== --- stable/9/lib/libc/include/libc_private.h Sat Sep 22 12:36:31 2012 (r240818) +++ stable/9/lib/libc/include/libc_private.h Sat Sep 22 12:38:19 2012 (r240819) @@ -34,6 +34,7 @@ #ifndef _LIBC_PRIVATE_H_ #define _LIBC_PRIVATE_H_ +#include #include /* @@ -245,6 +246,12 @@ extern void * __sys_freebsd6_mmap(void * /* Without back-compat translation */ extern int __sys_fcntl(int, int, ...); +struct timespec; +struct timeval; +struct timezone; +int __sys_gettimeofday(struct timeval *, struct timezone *); +int __sys_clock_gettime(__clockid_t, struct timespec *ts); + /* execve() with PATH processing to implement posix_spawnp() */ int _execvpe(const char *, char * const *, char * const *); Modified: stable/9/lib/libc/sys/Makefile.inc ============================================================================== --- stable/9/lib/libc/sys/Makefile.inc Sat Sep 22 12:36:31 2012 (r240818) +++ stable/9/lib/libc/sys/Makefile.inc Sat Sep 22 12:38:19 2012 (r240819) @@ -15,6 +15,10 @@ # .sinclude "${.CURDIR}/${LIBC_ARCH}/sys/Makefile.inc" +SRCS+= clock_gettime.c gettimeofday.c __vdso_gettimeofday.c +NOASM+= clock_gettime.o gettimeofday.o +PSEUDO+= _clock_gettime.o _gettimeofday.o + # Sources common to both syscall interfaces: SRCS+= stack_protector.c stack_protector_compat.c __error.c .if !defined(WITHOUT_SYSCALL_COMPAT) Copied: stable/9/lib/libc/sys/__vdso_gettimeofday.c (from r237434, head/lib/libc/sys/__vdso_gettimeofday.c) ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ stable/9/lib/libc/sys/__vdso_gettimeofday.c Sat Sep 22 12:38:19 2012 (r240819, copy of r237434, head/lib/libc/sys/__vdso_gettimeofday.c) @@ -0,0 +1,142 @@ +/*- + * Copyright (c) 2012 Konstantin Belousov + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND + * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE + * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE + * ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE + * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL + * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS + * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) + * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT + * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY + * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF + * SUCH DAMAGE. + */ + +#include +__FBSDID("$FreeBSD$"); + +#include +#include +#include +#include +#include +#include +#include "libc_private.h" + +static u_int +tc_delta(const struct vdso_timehands *th) +{ + + return ((__vdso_gettc(th) - th->th_offset_count) & + th->th_counter_mask); +} + +static int +binuptime(struct bintime *bt, struct vdso_timekeep *tk, int abs) +{ + struct vdso_timehands *th; + uint32_t curr, gen; + + do { + if (!tk->tk_enabled) + return (ENOSYS); + + /* + * XXXKIB. The load of tk->tk_current should use + * atomic_load_acq_32 to provide load barrier. But + * since tk points to r/o mapped page, x86 + * implementation of atomic_load_acq faults. + */ + curr = tk->tk_current; + rmb(); + th = &tk->tk_th[curr]; + if (th->th_algo != VDSO_TH_ALGO_1) + return (ENOSYS); + gen = th->th_gen; + *bt = th->th_offset; + bintime_addx(bt, th->th_scale * tc_delta(th)); + if (abs) + bintime_add(bt, &th->th_boottime); + + /* + * Barrier for load of both tk->tk_current and th->th_gen. + */ + rmb(); + } while (curr != tk->tk_current || gen == 0 || gen != th->th_gen); + return (0); +} + +static struct vdso_timekeep *tk; + +int +__vdso_gettimeofday(struct timeval *tv, struct timezone *tz) +{ + struct bintime bt; + int error; + + if (tz != NULL) + return (ENOSYS); + if (tk == NULL) { + error = _elf_aux_info(AT_TIMEKEEP, &tk, sizeof(tk)); + if (error != 0 || tk == NULL) + return (ENOSYS); + } + if (tk->tk_ver != VDSO_TK_VER_CURR) + return (ENOSYS); + error = binuptime(&bt, tk, 1); + if (error != 0) + return (error); + bintime2timeval(&bt, tv); + return (0); +} + +int +__vdso_clock_gettime(clockid_t clock_id, struct timespec *ts) +{ + struct bintime bt; + int abs, error; + + if (tk == NULL) { + error = _elf_aux_info(AT_TIMEKEEP, &tk, sizeof(tk)); + if (error != 0 || tk == NULL) + return (ENOSYS); + } + if (tk->tk_ver != VDSO_TK_VER_CURR) + return (ENOSYS); + switch (clock_id) { + case CLOCK_REALTIME: + case CLOCK_REALTIME_PRECISE: + case CLOCK_REALTIME_FAST: + case CLOCK_SECOND: + abs = 1; + break; + case CLOCK_MONOTONIC: + case CLOCK_MONOTONIC_PRECISE: + case CLOCK_MONOTONIC_FAST: + case CLOCK_UPTIME: + case CLOCK_UPTIME_PRECISE: + case CLOCK_UPTIME_FAST: + abs = 0; + break; + default: + return (ENOSYS); + } + error = binuptime(&bt, tk, abs); + if (error != 0) + return (error); + bintime2timespec(&bt, ts); + if (clock_id == CLOCK_SECOND) + ts->tv_nsec = 0; + return (0); +} Copied: stable/9/lib/libc/sys/clock_gettime.c (from r237434, head/lib/libc/sys/clock_gettime.c) ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ stable/9/lib/libc/sys/clock_gettime.c Sat Sep 22 12:38:19 2012 (r240819, copy of r237434, head/lib/libc/sys/clock_gettime.c) @@ -0,0 +1,52 @@ +/*- + * Copyright (c) 2012 Konstantin Belousov + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND + * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE + * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE + * ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE + * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL + * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS + * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) + * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT + * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY + * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF + * SUCH DAMAGE. + */ + +#include +__FBSDID("$FreeBSD$"); + +#include +#include +#include +#include +#include +#include "libc_private.h" + +int __clock_gettime(clockid_t, struct timespec *ts); + +__weak_reference(__clock_gettime, clock_gettime); + +int +__clock_gettime(clockid_t clock_id, struct timespec *ts) +{ + int error; + + if (__vdso_clock_gettime != NULL && __vdso_gettc != NULL) + error = __vdso_clock_gettime(clock_id, ts); + else + error = ENOSYS; + if (error == ENOSYS) + error = __sys_clock_gettime(clock_id, ts); + return (error); +} Copied: stable/9/lib/libc/sys/gettimeofday.c (from r237434, head/lib/libc/sys/gettimeofday.c) ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ stable/9/lib/libc/sys/gettimeofday.c Sat Sep 22 12:38:19 2012 (r240819, copy of r237434, head/lib/libc/sys/gettimeofday.c) @@ -0,0 +1,51 @@ +/*- + * Copyright (c) 2012 Konstantin Belousov + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND + * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE + * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE + * ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE + * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL + * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS + * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) + * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT + * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY + * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF + * SUCH DAMAGE. + */ + +#include +__FBSDID("$FreeBSD$"); + +#include +#include +#include +#include +#include "libc_private.h" + +int __gettimeofday(struct timeval *tv, struct timezone *tz); + +__weak_reference(__gettimeofday, gettimeofday); + +int +__gettimeofday(struct timeval *tv, struct timezone *tz) +{ + int error; + + if (__vdso_gettimeofday != NULL && __vdso_gettc != NULL) + error = __vdso_gettimeofday(tv, tz); + else + error = ENOSYS; + if (error == ENOSYS) + error = __sys_gettimeofday(tv, tz); + return (error); +} From owner-svn-src-stable@FreeBSD.ORG Sat Sep 22 12:40:53 2012 Return-Path: Delivered-To: svn-src-stable@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 0D9BF1065672; Sat, 22 Sep 2012 12:40:53 +0000 (UTC) (envelope-from kib@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id E2B488FC16; Sat, 22 Sep 2012 12:40:52 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q8MCeqYX067794; Sat, 22 Sep 2012 12:40:52 GMT (envelope-from kib@svn.freebsd.org) Received: (from kib@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q8MCeqM9067792; Sat, 22 Sep 2012 12:40:52 GMT (envelope-from kib@svn.freebsd.org) Message-Id: <201209221240.q8MCeqM9067792@svn.freebsd.org> From: Konstantin Belousov Date: Sat, 22 Sep 2012 12:40:52 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r240821 - stable/9/sys/x86/x86 X-BeenThere: svn-src-stable@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for all the -stable branches of the src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 22 Sep 2012 12:40:53 -0000 Author: kib Date: Sat Sep 22 12:40:52 2012 New Revision: 240821 URL: http://svn.freebsd.org/changeset/base/240821 Log: MFC r238973,r238975: Add explicit fences right before rdtsc in the timecounters 'get' functions. Modified: stable/9/sys/x86/x86/tsc.c Directory Properties: stable/9/sys/ (props changed) Modified: stable/9/sys/x86/x86/tsc.c ============================================================================== --- stable/9/sys/x86/x86/tsc.c Sat Sep 22 12:40:00 2012 (r240820) +++ stable/9/sys/x86/x86/tsc.c Sat Sep 22 12:40:52 2012 (r240821) @@ -82,7 +82,11 @@ static void tsc_freq_changed(void *arg, static void tsc_freq_changing(void *arg, const struct cf_level *level, int *status); static unsigned tsc_get_timecount(struct timecounter *tc); -static unsigned tsc_get_timecount_low(struct timecounter *tc); +static inline unsigned tsc_get_timecount_low(struct timecounter *tc); +static unsigned tsc_get_timecount_lfence(struct timecounter *tc); +static unsigned tsc_get_timecount_low_lfence(struct timecounter *tc); +static unsigned tsc_get_timecount_mfence(struct timecounter *tc); +static unsigned tsc_get_timecount_low_mfence(struct timecounter *tc); static void tsc_levels_changed(void *arg, int unit); static struct timecounter tsc_timecounter = { @@ -262,6 +266,10 @@ probe_tsc_freq(void) (vm_guest == VM_GUEST_NO && CPUID_TO_FAMILY(cpu_id) >= 0x10)) tsc_is_invariant = 1; + if (cpu_feature & CPUID_SSE2) { + tsc_timecounter.tc_get_timecount = + tsc_get_timecount_mfence; + } break; case CPU_VENDOR_INTEL: if ((amd_pminfo & AMDPM_TSC_INVARIANT) != 0 || @@ -271,6 +279,10 @@ probe_tsc_freq(void) (CPUID_TO_FAMILY(cpu_id) == 0xf && CPUID_TO_MODEL(cpu_id) >= 0x3)))) tsc_is_invariant = 1; + if (cpu_feature & CPUID_SSE2) { + tsc_timecounter.tc_get_timecount = + tsc_get_timecount_lfence; + } break; case CPU_VENDOR_CENTAUR: if (vm_guest == VM_GUEST_NO && @@ -278,6 +290,10 @@ probe_tsc_freq(void) CPUID_TO_MODEL(cpu_id) >= 0xf && (rdmsr(0x1203) & 0x100000000ULL) == 0) tsc_is_invariant = 1; + if (cpu_feature & CPUID_SSE2) { + tsc_timecounter.tc_get_timecount = + tsc_get_timecount_lfence; + } break; } @@ -328,16 +344,30 @@ init_TSC(void) #ifdef SMP -/* rmb is required here because rdtsc is not a serializing instruction. */ -#define TSC_READ(x) \ -static void \ -tsc_read_##x(void *arg) \ -{ \ - uint32_t *tsc = arg; \ - u_int cpu = PCPU_GET(cpuid); \ - \ - rmb(); \ - tsc[cpu * 3 + x] = rdtsc32(); \ +/* + * RDTSC is not a serializing instruction, and does not drain + * instruction stream, so we need to drain the stream before executing + * it. It could be fixed by use of RDTSCP, except the instruction is + * not available everywhere. + * + * Use CPUID for draining in the boot-time SMP constistency test. The + * timecounters use MFENCE for AMD CPUs, and LFENCE for others (Intel + * and VIA) when SSE2 is present, and nothing on older machines which + * also do not issue RDTSC prematurely. There, testing for SSE2 and + * vendor is too cumbersome, and we learn about TSC presence from CPUID. + * + * Do not use do_cpuid(), since we do not need CPUID results, which + * have to be written into memory with do_cpuid(). + */ +#define TSC_READ(x) \ +static void \ +tsc_read_##x(void *arg) \ +{ \ + uint32_t *tsc = arg; \ + u_int cpu = PCPU_GET(cpuid); \ + \ + __asm __volatile("cpuid" : : : "eax", "ebx", "ecx", "edx"); \ + tsc[cpu * 3 + x] = rdtsc32(); \ } TSC_READ(0) TSC_READ(1) @@ -487,7 +517,16 @@ init: for (shift = 0; shift < 31 && (tsc_freq >> shift) > max_freq; shift++) ; if (shift > 0) { - tsc_timecounter.tc_get_timecount = tsc_get_timecount_low; + if (cpu_feature & CPUID_SSE2) { + if (cpu_vendor_id == CPU_VENDOR_AMD) { + tsc_timecounter.tc_get_timecount = + tsc_get_timecount_low_mfence; + } else { + tsc_timecounter.tc_get_timecount = + tsc_get_timecount_low_lfence; + } + } else + tsc_timecounter.tc_get_timecount = tsc_get_timecount_low; tsc_timecounter.tc_name = "TSC-low"; if (bootverbose) printf("TSC timecounter discards lower %d bit(s)\n", @@ -599,16 +638,48 @@ tsc_get_timecount(struct timecounter *tc return (rdtsc32()); } -static u_int +static inline u_int tsc_get_timecount_low(struct timecounter *tc) { uint32_t rv; __asm __volatile("rdtsc; shrd %%cl, %%edx, %0" - : "=a" (rv) : "c" ((int)(intptr_t)tc->tc_priv) : "edx"); + : "=a" (rv) : "c" ((int)(intptr_t)tc->tc_priv) : "edx"); return (rv); } +static u_int +tsc_get_timecount_lfence(struct timecounter *tc __unused) +{ + + lfence(); + return (rdtsc32()); +} + +static u_int +tsc_get_timecount_low_lfence(struct timecounter *tc) +{ + + lfence(); + return (tsc_get_timecount_low(tc)); +} + +static u_int +tsc_get_timecount_mfence(struct timecounter *tc __unused) +{ + + mfence(); + return (rdtsc32()); +} + +static u_int +tsc_get_timecount_low_mfence(struct timecounter *tc) +{ + + mfence(); + return (tsc_get_timecount_low(tc)); +} + uint32_t cpu_fill_vdso_timehands(struct vdso_timehands *vdso_th) { From owner-svn-src-stable@FreeBSD.ORG Sat Sep 22 21:13:35 2012 Return-Path: Delivered-To: svn-src-stable@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 4FEF4106566B; Sat, 22 Sep 2012 21:13:35 +0000 (UTC) (envelope-from avg@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 30B148FC08; Sat, 22 Sep 2012 21:13:35 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q8MLDZKd042970; Sat, 22 Sep 2012 21:13:35 GMT (envelope-from avg@svn.freebsd.org) Received: (from avg@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q8MLDYT7042966; Sat, 22 Sep 2012 21:13:34 GMT (envelope-from avg@svn.freebsd.org) Message-Id: <201209222113.q8MLDYT7042966@svn.freebsd.org> From: Andriy Gapon Date: Sat, 22 Sep 2012 21:13:34 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r240837 - in stable/9/sys: boot/zfs cddl/boot/zfs X-BeenThere: svn-src-stable@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for all the -stable branches of the src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 22 Sep 2012 21:13:35 -0000 Author: avg Date: Sat Sep 22 21:13:34 2012 New Revision: 240837 URL: http://svn.freebsd.org/changeset/base/240837 Log: MFC r240346,240356: zfs boot: bring zap_leaf_chunk field names in sync with kernel code Modified: stable/9/sys/boot/zfs/zfs.c stable/9/sys/boot/zfs/zfsimpl.c stable/9/sys/cddl/boot/zfs/zfsimpl.h Directory Properties: stable/9/sys/ (props changed) stable/9/sys/boot/ (props changed) Modified: stable/9/sys/boot/zfs/zfs.c ============================================================================== --- stable/9/sys/boot/zfs/zfs.c Sat Sep 22 19:03:11 2012 (r240836) +++ stable/9/sys/boot/zfs/zfs.c Sat Sep 22 21:13:34 2012 (r240837) @@ -317,7 +317,7 @@ zfs_readdir(struct open_file *f, struct if (zc->l_entry.le_type != ZAP_CHUNK_ENTRY) goto fzap_next; - namelen = zc->l_entry.le_name_length; + namelen = zc->l_entry.le_name_numints; if (namelen > sizeof(d->d_name)) namelen = sizeof(d->d_name); Modified: stable/9/sys/boot/zfs/zfsimpl.c ============================================================================== --- stable/9/sys/boot/zfs/zfsimpl.c Sat Sep 22 19:03:11 2012 (r240836) +++ stable/9/sys/boot/zfs/zfsimpl.c Sat Sep 22 21:13:34 2012 (r240837) @@ -1179,7 +1179,7 @@ fzap_name_equal(const zap_leaf_t *zl, co const zap_leaf_chunk_t *nc; const char *p; - namelen = zc->l_entry.le_name_length; + namelen = zc->l_entry.le_name_numints; nc = &ZAP_LEAF_CHUNK(zl, zc->l_entry.le_name_chunk); p = name; @@ -1392,7 +1392,7 @@ fzap_list(const spa_t *spa, const dnode_ zc = &ZAP_LEAF_CHUNK(&zl, j); if (zc->l_entry.le_type != ZAP_CHUNK_ENTRY) continue; - namelen = zc->l_entry.le_name_length; + namelen = zc->l_entry.le_name_numints; if (namelen > sizeof(name)) namelen = sizeof(name); @@ -1491,7 +1491,7 @@ fzap_name_copy(const zap_leaf_t *zl, con const zap_leaf_chunk_t *nc; char *p; - namelen = zc->l_entry.le_name_length; + namelen = zc->l_entry.le_name_numints; nc = &ZAP_LEAF_CHUNK(zl, zc->l_entry.le_name_chunk); p = name; Modified: stable/9/sys/cddl/boot/zfs/zfsimpl.h ============================================================================== --- stable/9/sys/cddl/boot/zfs/zfsimpl.h Sat Sep 22 19:03:11 2012 (r240836) +++ stable/9/sys/cddl/boot/zfs/zfsimpl.h Sat Sep 22 21:13:34 2012 (r240837) @@ -1171,12 +1171,12 @@ typedef struct zap_leaf_phys { typedef union zap_leaf_chunk { struct zap_leaf_entry { uint8_t le_type; /* always ZAP_CHUNK_ENTRY */ - uint8_t le_int_size; /* size of ints */ + uint8_t le_value_intlen; /* size of ints */ uint16_t le_next; /* next entry in hash chain */ uint16_t le_name_chunk; /* first chunk of the name */ - uint16_t le_name_length; /* bytes in name, incl null */ + uint16_t le_name_numints; /* bytes in name, incl null */ uint16_t le_value_chunk; /* first chunk of the value */ - uint16_t le_value_length; /* value length in ints */ + uint16_t le_value_numints; /* value length in ints */ uint32_t le_cd; /* collision differentiator */ uint64_t le_hash; /* hash value of the name */ } l_entry; From owner-svn-src-stable@FreeBSD.ORG Sat Sep 22 21:14:54 2012 Return-Path: Delivered-To: svn-src-stable@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 6422D1065672; Sat, 22 Sep 2012 21:14:54 +0000 (UTC) (envelope-from avg@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 452A88FC0A; Sat, 22 Sep 2012 21:14:54 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q8MLEssq043222; Sat, 22 Sep 2012 21:14:54 GMT (envelope-from avg@svn.freebsd.org) Received: (from avg@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q8MLEsVp043218; Sat, 22 Sep 2012 21:14:54 GMT (envelope-from avg@svn.freebsd.org) Message-Id: <201209222114.q8MLEsVp043218@svn.freebsd.org> From: Andriy Gapon Date: Sat, 22 Sep 2012 21:14:54 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-8@freebsd.org X-SVN-Group: stable-8 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r240838 - in stable/8/sys: boot/zfs cddl/boot/zfs X-BeenThere: svn-src-stable@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for all the -stable branches of the src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 22 Sep 2012 21:14:54 -0000 Author: avg Date: Sat Sep 22 21:14:53 2012 New Revision: 240838 URL: http://svn.freebsd.org/changeset/base/240838 Log: MFC r240346,240356: zfs boot: bring zap_leaf_chunk field names in sync with kernel code Modified: stable/8/sys/boot/zfs/zfs.c stable/8/sys/boot/zfs/zfsimpl.c stable/8/sys/cddl/boot/zfs/zfsimpl.h Directory Properties: stable/8/sys/ (props changed) stable/8/sys/boot/ (props changed) stable/8/sys/cddl/ (props changed) Modified: stable/8/sys/boot/zfs/zfs.c ============================================================================== --- stable/8/sys/boot/zfs/zfs.c Sat Sep 22 21:13:34 2012 (r240837) +++ stable/8/sys/boot/zfs/zfs.c Sat Sep 22 21:14:53 2012 (r240838) @@ -317,7 +317,7 @@ zfs_readdir(struct open_file *f, struct if (zc->l_entry.le_type != ZAP_CHUNK_ENTRY) goto fzap_next; - namelen = zc->l_entry.le_name_length; + namelen = zc->l_entry.le_name_numints; if (namelen > sizeof(d->d_name)) namelen = sizeof(d->d_name); Modified: stable/8/sys/boot/zfs/zfsimpl.c ============================================================================== --- stable/8/sys/boot/zfs/zfsimpl.c Sat Sep 22 21:13:34 2012 (r240837) +++ stable/8/sys/boot/zfs/zfsimpl.c Sat Sep 22 21:14:53 2012 (r240838) @@ -1179,7 +1179,7 @@ fzap_name_equal(const zap_leaf_t *zl, co const zap_leaf_chunk_t *nc; const char *p; - namelen = zc->l_entry.le_name_length; + namelen = zc->l_entry.le_name_numints; nc = &ZAP_LEAF_CHUNK(zl, zc->l_entry.le_name_chunk); p = name; @@ -1392,7 +1392,7 @@ fzap_list(const spa_t *spa, const dnode_ zc = &ZAP_LEAF_CHUNK(&zl, j); if (zc->l_entry.le_type != ZAP_CHUNK_ENTRY) continue; - namelen = zc->l_entry.le_name_length; + namelen = zc->l_entry.le_name_numints; if (namelen > sizeof(name)) namelen = sizeof(name); @@ -1491,7 +1491,7 @@ fzap_name_copy(const zap_leaf_t *zl, con const zap_leaf_chunk_t *nc; char *p; - namelen = zc->l_entry.le_name_length; + namelen = zc->l_entry.le_name_numints; nc = &ZAP_LEAF_CHUNK(zl, zc->l_entry.le_name_chunk); p = name; Modified: stable/8/sys/cddl/boot/zfs/zfsimpl.h ============================================================================== --- stable/8/sys/cddl/boot/zfs/zfsimpl.h Sat Sep 22 21:13:34 2012 (r240837) +++ stable/8/sys/cddl/boot/zfs/zfsimpl.h Sat Sep 22 21:14:53 2012 (r240838) @@ -1171,12 +1171,12 @@ typedef struct zap_leaf_phys { typedef union zap_leaf_chunk { struct zap_leaf_entry { uint8_t le_type; /* always ZAP_CHUNK_ENTRY */ - uint8_t le_int_size; /* size of ints */ + uint8_t le_value_intlen; /* size of ints */ uint16_t le_next; /* next entry in hash chain */ uint16_t le_name_chunk; /* first chunk of the name */ - uint16_t le_name_length; /* bytes in name, incl null */ + uint16_t le_name_numints; /* bytes in name, incl null */ uint16_t le_value_chunk; /* first chunk of the value */ - uint16_t le_value_length; /* value length in ints */ + uint16_t le_value_numints; /* value length in ints */ uint32_t le_cd; /* collision differentiator */ uint64_t le_hash; /* hash value of the name */ } l_entry; From owner-svn-src-stable@FreeBSD.ORG Sat Sep 22 21:18:31 2012 Return-Path: Delivered-To: svn-src-stable@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 94C7C1065673; Sat, 22 Sep 2012 21:18:31 +0000 (UTC) (envelope-from avg@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 8023F8FC0A; Sat, 22 Sep 2012 21:18:31 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q8MLIVFD044483; Sat, 22 Sep 2012 21:18:31 GMT (envelope-from avg@svn.freebsd.org) Received: (from avg@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q8MLIVQG044481; Sat, 22 Sep 2012 21:18:31 GMT (envelope-from avg@svn.freebsd.org) Message-Id: <201209222118.q8MLIVQG044481@svn.freebsd.org> From: Andriy Gapon Date: Sat, 22 Sep 2012 21:18:31 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r240839 - stable/9/sys/kern X-BeenThere: svn-src-stable@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for all the -stable branches of the src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 22 Sep 2012 21:18:31 -0000 Author: avg Date: Sat Sep 22 21:18:30 2012 New Revision: 240839 URL: http://svn.freebsd.org/changeset/base/240839 Log: MFC r240513: sched_ule: fix inverted condition in reporting of priority lending via ktr Modified: stable/9/sys/kern/sched_ule.c Directory Properties: stable/9/sys/ (props changed) Modified: stable/9/sys/kern/sched_ule.c ============================================================================== --- stable/9/sys/kern/sched_ule.c Sat Sep 22 21:14:53 2012 (r240838) +++ stable/9/sys/kern/sched_ule.c Sat Sep 22 21:18:30 2012 (r240839) @@ -1647,7 +1647,7 @@ sched_thread_priority(struct thread *td, "prio:%d", td->td_priority, "new prio:%d", prio, KTR_ATTR_LINKED, sched_tdname(curthread)); SDT_PROBE3(sched, , , change_pri, td, td->td_proc, prio); - if (td != curthread && prio > td->td_priority) { + if (td != curthread && prio < td->td_priority) { KTR_POINT3(KTR_SCHED, "thread", sched_tdname(curthread), "lend prio", "prio:%d", td->td_priority, "new prio:%d", prio, KTR_ATTR_LINKED, sched_tdname(td)); From owner-svn-src-stable@FreeBSD.ORG Sat Sep 22 21:19:50 2012 Return-Path: Delivered-To: svn-src-stable@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 4F336106566C; Sat, 22 Sep 2012 21:19:50 +0000 (UTC) (envelope-from avg@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 3AB9C8FC14; Sat, 22 Sep 2012 21:19:50 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q8MLJoQ5044758; Sat, 22 Sep 2012 21:19:50 GMT (envelope-from avg@svn.freebsd.org) Received: (from avg@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q8MLJoGN044756; Sat, 22 Sep 2012 21:19:50 GMT (envelope-from avg@svn.freebsd.org) Message-Id: <201209222119.q8MLJoGN044756@svn.freebsd.org> From: Andriy Gapon Date: Sat, 22 Sep 2012 21:19:50 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-8@freebsd.org X-SVN-Group: stable-8 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r240840 - stable/8/sys/kern X-BeenThere: svn-src-stable@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for all the -stable branches of the src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 22 Sep 2012 21:19:50 -0000 Author: avg Date: Sat Sep 22 21:19:49 2012 New Revision: 240840 URL: http://svn.freebsd.org/changeset/base/240840 Log: MFC r240513: sched_ule: fix inverted condition in reporting of priority lending via ktr Modified: stable/8/sys/kern/sched_ule.c Directory Properties: stable/8/sys/ (props changed) stable/8/sys/kern/ (props changed) Modified: stable/8/sys/kern/sched_ule.c ============================================================================== --- stable/8/sys/kern/sched_ule.c Sat Sep 22 21:18:30 2012 (r240839) +++ stable/8/sys/kern/sched_ule.c Sat Sep 22 21:19:49 2012 (r240840) @@ -1599,7 +1599,7 @@ sched_thread_priority(struct thread *td, "prio:%d", td->td_priority, "new prio:%d", prio, KTR_ATTR_LINKED, sched_tdname(curthread)); SDT_PROBE3(sched, , , change_pri, td, td->td_proc, prio); - if (td != curthread && prio > td->td_priority) { + if (td != curthread && prio < td->td_priority) { KTR_POINT3(KTR_SCHED, "thread", sched_tdname(curthread), "lend prio", "prio:%d", td->td_priority, "new prio:%d", prio, KTR_ATTR_LINKED, sched_tdname(td));