From owner-svn-src-all@FreeBSD.ORG Sun May 12 00:35:58 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id DE2E03A6; Sun, 12 May 2013 00:35:58 +0000 (UTC) (envelope-from brooks@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id D08E714C; Sun, 12 May 2013 00:35:58 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.6/8.14.6) with ESMTP id r4C0ZwQO043273; Sun, 12 May 2013 00:35:58 GMT (envelope-from brooks@svn.freebsd.org) Received: (from brooks@localhost) by svn.freebsd.org (8.14.6/8.14.5/Submit) id r4C0Zw0H043272; Sun, 12 May 2013 00:35:58 GMT (envelope-from brooks@svn.freebsd.org) Message-Id: <201305120035.r4C0Zw0H043272@svn.freebsd.org> From: Brooks Davis Date: Sun, 12 May 2013 00:35:58 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org Subject: svn commit: r250534 - stable/9/cddl/lib/drti X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 12 May 2013 00:35:58 -0000 Author: brooks Date: Sun May 12 00:35:57 2013 New Revision: 250534 URL: http://svnweb.freebsd.org/changeset/base/250534 Log: MFC r250337 Work around the implementation of LIBRARIES_ONLY. It causes drti.o to not be installed in /usr/lib32 on systems with compat-32 support. This fix has two parts. First, the build is forced by linking drti.o into a dummy internal library. Second, the object file is installed manually in the LIBRARIES_ONLY case. Modified: stable/9/cddl/lib/drti/Makefile Directory Properties: stable/9/cddl/lib/drti/ (props changed) Modified: stable/9/cddl/lib/drti/Makefile ============================================================================== --- stable/9/cddl/lib/drti/Makefile Sat May 11 23:55:43 2013 (r250533) +++ stable/9/cddl/lib/drti/Makefile Sun May 12 00:35:57 2013 (r250534) @@ -9,6 +9,8 @@ FILESGRP= ${LIBGRP} FILESMODE= ${LIBMODE} FILESDIR= ${LIBDIR}/dtrace CLEANFILES= ${FILES} +LIB= drti-dummy +INTERNALLIB= CFLAGS+= -I${.CURDIR}/../../../sys/cddl/compat/opensolaris \ -I${.CURDIR}/../../../cddl/compat/opensolaris/include \ @@ -18,4 +20,10 @@ CFLAGS+= -I${.CURDIR}/../../../sys/cddl/ -I${OPENSOLARIS_SYS_DISTDIR}/uts/common \ -DPIC ${PICFLAG} +.if make(install) && defined(LIBRARIES_ONLY) +install: + ${INSTALL} -o ${FILESOWN} -g ${FILESGRP} -m ${FILESMODE} \ + ${FILES} ${DESTDIR}${FILESDIR} +.endif + .include From owner-svn-src-all@FreeBSD.ORG Sun May 12 00:39:26 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id 47F9D52A; Sun, 12 May 2013 00:39:26 +0000 (UTC) (envelope-from dteske@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id 35FEC15D; Sun, 12 May 2013 00:39:26 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.6/8.14.6) with ESMTP id r4C0dQno043934; Sun, 12 May 2013 00:39:26 GMT (envelope-from dteske@svn.freebsd.org) Received: (from dteske@localhost) by svn.freebsd.org (8.14.6/8.14.5/Submit) id r4C0dQdH043933; Sun, 12 May 2013 00:39:26 GMT (envelope-from dteske@svn.freebsd.org) Message-Id: <201305120039.r4C0dQdH043933@svn.freebsd.org> From: Devin Teske Date: Sun, 12 May 2013 00:39:26 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r250535 - head/usr.sbin/bsdconfig/share/media X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 12 May 2013 00:39:26 -0000 Author: dteske Date: Sun May 12 00:39:25 2013 New Revision: 250535 URL: http://svnweb.freebsd.org/changeset/base/250535 Log: Whitespace. Modified: head/usr.sbin/bsdconfig/share/media/any.subr Modified: head/usr.sbin/bsdconfig/share/media/any.subr ============================================================================== --- head/usr.sbin/bsdconfig/share/media/any.subr Sun May 12 00:35:57 2013 (r250534) +++ head/usr.sbin/bsdconfig/share/media/any.subr Sun May 12 00:39:25 2013 (r250535) @@ -72,8 +72,8 @@ f_media_get_type() local menu_list size menu_list=" - '1 $msg_cd_dvd' '$msg_install_from_a_freebsd_cd_dvd' - '2 $msg_ftp' '$msg_install_from_an_ftp_server' + '1 $msg_cd_dvd' '$msg_install_from_a_freebsd_cd_dvd' + '2 $msg_ftp' '$msg_install_from_an_ftp_server' '3 $msg_ftp_passive' '$msg_install_from_an_ftp_server_thru_firewall' '4 $msg_http' '$msg_install_from_an_ftp_server_thru_proxy' From owner-svn-src-all@FreeBSD.ORG Sun May 12 00:40:50 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id 080996B8; Sun, 12 May 2013 00:40:50 +0000 (UTC) (envelope-from dteske@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id EEC11175; Sun, 12 May 2013 00:40:49 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.6/8.14.6) with ESMTP id r4C0enFr045676; Sun, 12 May 2013 00:40:49 GMT (envelope-from dteske@svn.freebsd.org) Received: (from dteske@localhost) by svn.freebsd.org (8.14.6/8.14.5/Submit) id r4C0en5T045675; Sun, 12 May 2013 00:40:49 GMT (envelope-from dteske@svn.freebsd.org) Message-Id: <201305120040.r4C0en5T045675@svn.freebsd.org> From: Devin Teske Date: Sun, 12 May 2013 00:40:49 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r250536 - head/usr.sbin/bsdconfig/share/packages X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 12 May 2013 00:40:50 -0000 Author: dteske Date: Sun May 12 00:40:49 2013 New Revision: 250536 URL: http://svnweb.freebsd.org/changeset/base/250536 Log: Comments. Modified: head/usr.sbin/bsdconfig/share/packages/categories.subr Modified: head/usr.sbin/bsdconfig/share/packages/categories.subr ============================================================================== --- head/usr.sbin/bsdconfig/share/packages/categories.subr Sun May 12 00:39:25 2013 (r250535) +++ head/usr.sbin/bsdconfig/share/packages/categories.subr Sun May 12 00:40:49 2013 (r250536) @@ -99,7 +99,11 @@ f_category_desc_set() ############################################################ MAIN # -# Load descriptions for package categories +# Load descriptions for package categories. Note that we don't internationalize +# category names because this would be confusing for people used to that browse +# the FTP mirrors or are otherwise familiar with an interface that does not +# provide internationalized names. The descriptions can be used to provide i18n +# users a description of the non-i18n category name. # f_category() { f_category_desc_set "$1" "$2"; } f_category All "$msg_all_available_packages_in_all_categories" From owner-svn-src-all@FreeBSD.ORG Sun May 12 00:44:41 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id 7C15983B; Sun, 12 May 2013 00:44:41 +0000 (UTC) (envelope-from dteske@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id 6CFCB180; Sun, 12 May 2013 00:44:41 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.6/8.14.6) with ESMTP id r4C0ifEX046598; Sun, 12 May 2013 00:44:41 GMT (envelope-from dteske@svn.freebsd.org) Received: (from dteske@localhost) by svn.freebsd.org (8.14.6/8.14.5/Submit) id r4C0ifEA046596; Sun, 12 May 2013 00:44:41 GMT (envelope-from dteske@svn.freebsd.org) Message-Id: <201305120044.r4C0ifEA046596@svn.freebsd.org> From: Devin Teske Date: Sun, 12 May 2013 00:44:41 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r250537 - in head/usr.sbin/bsdconfig: include share/packages X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 12 May 2013 00:44:41 -0000 Author: dteske Date: Sun May 12 00:44:40 2013 New Revision: 250537 URL: http://svnweb.freebsd.org/changeset/base/250537 Log: Remove duplicated string. Modified: head/usr.sbin/bsdconfig/include/messages.subr head/usr.sbin/bsdconfig/share/packages/categories.subr Modified: head/usr.sbin/bsdconfig/include/messages.subr ============================================================================== --- head/usr.sbin/bsdconfig/include/messages.subr Sun May 12 00:40:49 2013 (r250536) +++ head/usr.sbin/bsdconfig/include/messages.subr Sun May 12 00:44:40 2013 (r250537) @@ -36,7 +36,6 @@ msg_accept_continue="Accept/Continue" msg_accessibility_desc="Ports to help disabled users." msg_afterstep_desc="Ports to support the AfterStep window manager." msg_all="All" -msg_all_available_packages_in_all_categories="All available packages in all categories." msg_all_desc="All available packages in all categories." msg_always_try_sudo_when_run_as="Always try sudo(8) when run as %s" msg_arabic_desc="Ported software for Arab countries." Modified: head/usr.sbin/bsdconfig/share/packages/categories.subr ============================================================================== --- head/usr.sbin/bsdconfig/share/packages/categories.subr Sun May 12 00:40:49 2013 (r250536) +++ head/usr.sbin/bsdconfig/share/packages/categories.subr Sun May 12 00:44:40 2013 (r250537) @@ -106,7 +106,7 @@ f_category_desc_set() # users a description of the non-i18n category name. # f_category() { f_category_desc_set "$1" "$2"; } -f_category All "$msg_all_available_packages_in_all_categories" +f_category All "$msg_all_desc" f_category accessibility "$msg_accessibility_desc" f_category afterstep "$msg_afterstep_desc" f_category arabic "$msg_arabic_desc" From owner-svn-src-all@FreeBSD.ORG Sun May 12 00:46:19 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id 3B741A15; Sun, 12 May 2013 00:46:19 +0000 (UTC) (envelope-from dteske@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id 1DC6018A; Sun, 12 May 2013 00:46:19 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.6/8.14.6) with ESMTP id r4C0kIR1047003; Sun, 12 May 2013 00:46:19 GMT (envelope-from dteske@svn.freebsd.org) Received: (from dteske@localhost) by svn.freebsd.org (8.14.6/8.14.5/Submit) id r4C0kI57046997; Sun, 12 May 2013 00:46:18 GMT (envelope-from dteske@svn.freebsd.org) Message-Id: <201305120046.r4C0kI57046997@svn.freebsd.org> From: Devin Teske Date: Sun, 12 May 2013 00:46:18 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r250538 - in head/usr.sbin/bsdconfig: include share/packages X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 12 May 2013 00:46:19 -0000 Author: dteske Date: Sun May 12 00:46:18 2013 New Revision: 250538 URL: http://svnweb.freebsd.org/changeset/base/250538 Log: Fix i18n violations in the package management module. A few words like `packages', `installed', and `selected' were not internationalized. Modified: head/usr.sbin/bsdconfig/include/messages.subr head/usr.sbin/bsdconfig/share/packages/index.subr head/usr.sbin/bsdconfig/share/packages/packages.subr Modified: head/usr.sbin/bsdconfig/include/messages.subr ============================================================================== --- head/usr.sbin/bsdconfig/include/messages.subr Sun May 12 00:44:40 2013 (r250537) +++ head/usr.sbin/bsdconfig/include/messages.subr Sun May 12 00:46:18 2013 (r250538) @@ -164,6 +164,7 @@ msg_install_from_an_ftp_server_thru_prox msg_install_from_the_existing_filesystem="Install from the existing filesystem" msg_install_over_nfs="Install over NFS" msg_installed="Installed" +msg_installed_lc="installed" msg_installed_desc="Leave package as-is, installed" msg_invalid_gateway_ipv4_address_specified="Invalid gateway IPv4 address specified" msg_invalid_hostname_value="Invalid hostname value" @@ -248,6 +249,7 @@ msg_options="Options" msg_options_editor="Options Editor" msg_other="other" msg_package_temp="Package Temp" +msg_packages="packages" msg_page_of_npages="(Page %s of %s)" msg_palm_desc="Software support for the Palm(tm) series." msg_parallel_desc="Applications dealing with parallelism in computing." @@ -318,6 +320,7 @@ msg_secure_mode_requires_x11="Secure-mod msg_security_desc="System security software." msg_select="Select" msg_select_a_site_thats_close="Select a site that's close!" +msg_selected="selected" msg_server_error_when_requesting_url="Server error when requesting %s, you could try an other server" msg_shells_desc="Various shells (tcsh, bash, etc)." msg_singapore="Singapore" Modified: head/usr.sbin/bsdconfig/share/packages/index.subr ============================================================================== --- head/usr.sbin/bsdconfig/share/packages/index.subr Sun May 12 00:44:40 2013 (r250537) +++ head/usr.sbin/bsdconfig/share/packages/index.subr Sun May 12 00:46:18 2013 (r250538) @@ -112,6 +112,7 @@ f_index_read() export msg_no_description_provided export msg_all msg_all_desc export VALID_VARNAME_CHARS + export msg_packages eval "$( debug= f_getvar "$var_to_get" | awk -F'|' ' function asorti(src, dest) @@ -140,12 +141,13 @@ f_index_read() # cached (also acting as a visitation indicator) if ( ENVIRON["_index_page_" varcat "_1"] ) cat = cat "*" - printf "'\''%s'\'' '\''%s packages'\'' '\''%s'\''\n", + printf "'\''%s'\'' '\''%s " packages "'\'' '\''%s'\''\n", cat, npkgs, desc } BEGIN { valid_chars = ENVIRON["VALID_VARNAME_CHARS"] default_desc = ENVIRON["msg_no_description_provided"] + packages = ENVIRON["msg_packages"] tpkgs = 0 prefix = "" } @@ -221,11 +223,12 @@ f_index_extract_pages() debug= f_getvar "$var_to_get" | awk -F'|' \ -v cat="$category" \ -v pagesize="$pagesize" \ - -v var_basename="$var_basename" ' + -v var_basename="$var_basename" \ + -v i18n_all="$msg_all" ' BEGIN { n = page = 0 } /'\''/{ gsub(/'\''/, "'\''\\'\'\''") } { - if ( cat !~ /(^$|^All$)/ && $7 !~ \ + if ( cat !~ "(^$|^" i18n_all "$)" && $7 !~ \ "(^|[[:space:]])" cat "([[:space:]]|$)" ) next starting_new_page = (n++ == (pagesize * page)) if ( starting_new_page ) Modified: head/usr.sbin/bsdconfig/share/packages/packages.subr ============================================================================== --- head/usr.sbin/bsdconfig/share/packages/packages.subr Sun May 12 00:44:40 2013 (r250537) +++ head/usr.sbin/bsdconfig/share/packages/packages.subr Sun May 12 00:46:18 2013 (r250538) @@ -78,20 +78,28 @@ f_package_accent_category_menu() while [ $# -gt 0 ]; do cat="${1%\*}" desc="${2%%; *}" help="$3" shift 3 # cat/desc/help - f_str2varname "${cat# }" varcat - # Add an asterisk to the category if its index has been cached - f_isset _index_page_${varcat}_1 && cat="$cat*" + cat="${cat# }" # Trim leading space inserted by sort-method + f_str2varname "$cat" varcat # Add number of installed packages for this category (if any) n=0 - debug= f_getvar "_${varcat}_ninstalled" n && - [ $n -ge 1 ] && desc="$desc; $n installed" + case "$cat" in + "$msg_all") debug= f_getvar "_All_ninstalled" n ;; + *) debug= f_getvar "_${varcat}_ninstalled" n ;; + esac && + [ $n -ge 1 ] && desc="$desc; $n $msg_installed_lc" # Add number of selected packages for this category (if any) n=0 - debug= f_getvar "_${varcat}_nselected" n && - [ $n -ge 1 ] && desc="$desc; $n selected" + case "$cat" in + "$msg_all") debug= f_getvar "_All_nselected" n ;; + *) debug= f_getvar "_${varcat}_nselected" n ;; + esac && + [ $n -ge 1 ] && desc="$desc; $n $msg_selected" + + # Add an asterisk to the category if its index has been cached + f_isset _index_page_${varcat}_1 && cat="$cat*" # Update buffer with modified elements menu_buf="$menu_buf @@ -365,7 +373,7 @@ f_package_menu_select() # Get number of packages for this category case "$category" in - "All"|"") npkgs="${_npkgs:-0}";; + "$msg_all"|"") npkgs="${_npkgs:-0}";; *) f_getvar _npkgs_$varcat npkgs esac @@ -437,7 +445,12 @@ f_package_menu_select() " # End-Quote local prompt="" - f_category_desc_get "$category" prompt + # Accept/Translate i18n "All" but other category names must + # match tree definitions from INDEX, ports, FTP, etc. + case "$category" in + "$msg_all"|"") f_category_desc_get "All" prompt ;; + *) f_category_desc_get "$category" prompt ;; + esac prompt="$prompt $( printf "$msg_page_of_npages" \ "$page" "$npages" )" From owner-svn-src-all@FreeBSD.ORG Sun May 12 00:48:43 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id 35F59BA5 for ; Sun, 12 May 2013 00:48:43 +0000 (UTC) (envelope-from jroberson@jroberson.net) Received: from mail-pa0-f51.google.com (mail-pa0-f51.google.com [209.85.220.51]) by mx1.freebsd.org (Postfix) with ESMTP id 0A9FD1A2 for ; Sun, 12 May 2013 00:48:42 +0000 (UTC) Received: by mail-pa0-f51.google.com with SMTP id ld10so3739192pab.24 for ; Sat, 11 May 2013 17:48:42 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20120113; h=x-received:date:from:x-x-sender:to:cc:subject:in-reply-to :message-id:references:user-agent:mime-version:content-type :x-gm-message-state; bh=NO9QKmZ1iWC+qzV7fhC24/1RSvvXKv0cEcLMLKjhIVE=; b=mqJwY2HGsiTC8hGjbIEasYs90F9tTBAwbnpvsVbnpfj8WByVl8d7vHhKWr2DQD1gpA xVdxp/BjFESthtElxD/fnIRO5UtpYAlcVj/a1eptim05igTVrUxOfvVbJhe7cfVsAZSc g102orQ52J2PBThUkeR6QeqHhNdLv5Bm1O2leYD6cYn2bakeWTILs+Le0SgZTpQTPvz/ RL2wzKiSidb+VY2GkVcnViUDzml+HeNr720V+kP3W0TB8iC1YpUQQNlFDRVveFB1W9b3 KsiKGmydxt7MD+I48GoDgH5pMgD9FswmGSCNICzoWdAWGBO70eYaNWM3QSS3lS6mULMV hJVQ== X-Received: by 10.66.151.46 with SMTP id un14mr24183267pab.14.1368319722330; Sat, 11 May 2013 17:48:42 -0700 (PDT) Received: from rrcs-66-91-135-210.west.biz.rr.com (rrcs-66-91-135-210.west.biz.rr.com. [66.91.135.210]) by mx.google.com with ESMTPSA id gc5sm8175246pbb.19.2013.05.11.17.48.39 for (version=TLSv1 cipher=RC4-SHA bits=128/128); Sat, 11 May 2013 17:48:41 -0700 (PDT) Date: Sat, 11 May 2013 14:43:00 -1000 (HST) From: Jeff Roberson X-X-Sender: jroberson@desktop To: Marcel Moolenaar , jhb@freebsd.org, alfred@freebsd.org, attilio@freebsd.org Subject: Re: svn commit: r250411 - in head/sys: conf kern sys In-Reply-To: <201305091628.r49GSI33039873@svn.freebsd.org> Message-ID: References: <201305091628.r49GSI33039873@svn.freebsd.org> User-Agent: Alpine 2.00 (BSF 1167 2008-08-23) MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII; format=flowed X-Gm-Message-State: ALoCoQmjYLpERKurJSy7Hbr/+3FddOVbgaa63fygjU4T00J/oHPB0yVWKZi7AExJRRvs8NbeX5g/ Cc: svn-src-head@freebsd.org, svn-src-all@freebsd.org, src-committers@freebsd.org X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 12 May 2013 00:48:43 -0000 On Thu, 9 May 2013, Marcel Moolenaar wrote: > Author: marcel > Date: Thu May 9 16:28:18 2013 > New Revision: 250411 > URL: http://svnweb.freebsd.org/changeset/base/250411 > > Log: > Add option WITNESS_NO_VNODE to suppress printing LORs between VNODE > locks. To support this, VNODE locks are created with the LK_IS_VNODE > flag. This flag is propagated down using the LO_IS_VNODE flag. > > Note that WITNESS still records the LOR. Only the printing and the > optional entering into the kernel debugger is bypassed with the > WITNESS_NO_VNODE option. I'm replying to the original commit because the resulting thread got way out of hand. We need to all take a deep breath and take a pragmatic approach to solving the problem at hand. Let me first say I understand the utility here as this is also coming up in my organization. Test, and users, do not want to see erroneous warning messages. I understand that. Let's find a solution. Secondly, I think this project has grown too far for us to commit changes like this without some focused discussion. We need to be more mindful of the size of the impact and the number of people who are interested in a particular area. I'm not picking on you Marcel because this sort of thing has been coming up lately and we have all been guilty of it from time to time. There are more companies and individuals than ever trying to push work into the repository and we're having some growing pains. I am intimately familiar with the problems that lead to these erroneous witness messages as I have tracked down many of them and am even responsible for the code that generates them in some cases. Let me first outline a handful of generic problems. The root cause is that witness can not determine the real order between two locks due to relationships too complex to describe with a pair of strings. One example, which has been brought up, is the hierarchical nature of vnode locks. This impacts vnodes within one filesystem but it also involves vnodes between two different filesystems as you cross mount points. We can construct perfectly valid and deadlock free chains of mount points that have two different filesystem types in different orders which will LOR at the boundaries. We already skip duplicates to avoid this problem within each filesystem. We need to skip cross-filesystem duplicates, most desirably at the few specific places where this happens. This problem comes up especially for devfs because we lock devvps while file vnodes are locked but we lock devfs directories after the rootfs lock when crossing mountpoints in lookup. A second example, is locks of a fundamentally different type that have a complex ordering relationship. For example, a vnode lock may be acquired after a buf lock belonging to the parent's directory block. A cg buf lock may be acquired after any file buf lock. Here we want to ignore interactions between these two specific types at this particular location but not others as they may be unsafe. The third example, is a complex locking pattern with shared locks as presented by dirhash. We are seeing a similar pattern develop in the vm where we are going to use an exclusive object lock to protect pages or a shared object lock + a page lock. The semantics only get more complex as we push for more scalability. I expect to see more of these patterns develop. None of these problems can be solved with names alone. So far we've just lived with the warnings and we're no longer willing to accept that. What we need is a solution that blesses the specific instances and the specific lock classes involved without silencing legitimate warnings that may only occur after new code is added. For example, it may be safe to add a sx lock around some vnode code but you may not notice that you LOR if you silence all witness warnings related to the vnode lock site. I believe that the perfect solution would be a mechanism that could teach witness about and enforce these specific relationships. However, that may be computationally prohibitive and too complex to code. A more reasonable option would be to bless the specific relationships at the specific call sites. Turning all witness off at particular sites or with particular types renders important infrastructure useless for very large functional areas. It's also important to distinguish between squelching the error message from eliminating the other state that is saved at lock sites. We already have lock names and types. What I would propose we do is make the type 'vnode' for all vnodes and 'buf' for all bufs with the names used for the specific filesystems. Then you could specify a DUPOK that automatically blesses any filesystem to filesystem related LORs. In this way witness still records the call sites and unrelated LORs or panics still have the acquisition information. You could eventually unwind this to only DUPOK at the specific currently known places that we anticipate multiple vnodes. To solve the buf and other complex LORs involving multiple types you would make lock variants that accept a blessed list of the specific locks you are blessing. We already have support for a blessed list in witness. We just want something like this per-call. For example; When acquiring a child vnode lock after a parent lock when a parent's buf is held I would do something like this: vn_lock_flags(vp, LK_EXCLUSIVE, { "vnode", "bufwait", NULL }); Written properly dead code elimination will take care of it for non-debug builds. You could come up with other ways of writing this that don't involve passing pointers down the stack. For example, making a unique token for this blessed pair and passing it in the high bits of the flags. I don't really care about the particular implementation but I think this is the right model. Thanks, Jeff > > Modified: > head/sys/conf/options > head/sys/kern/kern_lock.c > head/sys/kern/subr_witness.c > head/sys/kern/vfs_subr.c > head/sys/sys/lock.h > head/sys/sys/lockmgr.h > > Modified: head/sys/conf/options > ============================================================================== > --- head/sys/conf/options Thu May 9 16:09:39 2013 (r250410) > +++ head/sys/conf/options Thu May 9 16:28:18 2013 (r250411) > @@ -672,6 +672,7 @@ KTR_ENTRIES opt_global.h > KTR_VERBOSE opt_ktr.h > WITNESS opt_global.h > WITNESS_KDB opt_witness.h > +WITNESS_NO_VNODE opt_witness.h > WITNESS_SKIPSPIN opt_witness.h > > # options for ACPI support > > Modified: head/sys/kern/kern_lock.c > ============================================================================== > --- head/sys/kern/kern_lock.c Thu May 9 16:09:39 2013 (r250410) > +++ head/sys/kern/kern_lock.c Thu May 9 16:28:18 2013 (r250411) > @@ -393,6 +393,8 @@ lockinit(struct lock *lk, int pri, const > iflags |= LO_WITNESS; > if (flags & LK_QUIET) > iflags |= LO_QUIET; > + if (flags & LK_IS_VNODE) > + iflags |= LO_IS_VNODE; > iflags |= flags & (LK_ADAPTIVE | LK_NOSHARE); > > lk->lk_lock = LK_UNLOCKED; > > Modified: head/sys/kern/subr_witness.c > ============================================================================== > --- head/sys/kern/subr_witness.c Thu May 9 16:09:39 2013 (r250410) > +++ head/sys/kern/subr_witness.c Thu May 9 16:28:18 2013 (r250411) > @@ -1289,7 +1289,19 @@ witness_checkorder(struct lock_object *l > w->w_reversed = w1->w_reversed = 1; > witness_increment_graph_generation(); > mtx_unlock_spin(&w_mtx); > - > + > +#ifdef WITNESS_NO_VNODE > + /* > + * There are known LORs between VNODE locks. They are > + * not an indication of a bug. VNODE locks are flagged > + * as such (LO_IS_VNODE) and we don't yell if the LOR > + * is between 2 VNODE locks. > + */ > + if ((lock->lo_flags & LO_IS_VNODE) != 0 && > + (lock1->li_lock->lo_flags & LO_IS_VNODE) != 0) > + return; > +#endif > + > /* > * Ok, yell about it. > */ > > Modified: head/sys/kern/vfs_subr.c > ============================================================================== > --- head/sys/kern/vfs_subr.c Thu May 9 16:09:39 2013 (r250410) > +++ head/sys/kern/vfs_subr.c Thu May 9 16:28:18 2013 (r250411) > @@ -1037,7 +1037,7 @@ alloc: > * By default, don't allow shared locks unless filesystems > * opt-in. > */ > - lockinit(vp->v_vnlock, PVFS, tag, VLKTIMEOUT, LK_NOSHARE); > + lockinit(vp->v_vnlock, PVFS, tag, VLKTIMEOUT, LK_NOSHARE | LK_IS_VNODE); > /* > * Initialize bufobj. > */ > > Modified: head/sys/sys/lock.h > ============================================================================== > --- head/sys/sys/lock.h Thu May 9 16:09:39 2013 (r250410) > +++ head/sys/sys/lock.h Thu May 9 16:28:18 2013 (r250411) > @@ -79,6 +79,7 @@ struct lock_class { > #define LO_SLEEPABLE 0x00100000 /* Lock may be held while sleeping. */ > #define LO_UPGRADABLE 0x00200000 /* Lock may be upgraded/downgraded. */ > #define LO_DUPOK 0x00400000 /* Don't check for duplicate acquires */ > +#define LO_IS_VNODE 0x00800000 /* Tell WITNESS about a VNODE lock */ > #define LO_CLASSMASK 0x0f000000 /* Class index bitmask. */ > #define LO_NOPROFILE 0x10000000 /* Don't profile this lock */ > > > Modified: head/sys/sys/lockmgr.h > ============================================================================== > --- head/sys/sys/lockmgr.h Thu May 9 16:09:39 2013 (r250410) > +++ head/sys/sys/lockmgr.h Thu May 9 16:28:18 2013 (r250411) > @@ -146,6 +146,7 @@ _lockmgr_args_rw(struct lock *lk, u_int > #define LK_NOWITNESS 0x000010 > #define LK_QUIET 0x000020 > #define LK_ADAPTIVE 0x000040 > +#define LK_IS_VNODE 0x000080 /* Tell WITNESS about a VNODE lock */ > > /* > * Additional attributes to be used in lockmgr(). > From owner-svn-src-all@FreeBSD.ORG Sun May 12 00:50:19 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id F1709D1B; Sun, 12 May 2013 00:50:18 +0000 (UTC) (envelope-from dteske@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id E2D7C1A8; Sun, 12 May 2013 00:50:18 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.6/8.14.6) with ESMTP id r4C0oIQa049345; Sun, 12 May 2013 00:50:18 GMT (envelope-from dteske@svn.freebsd.org) Received: (from dteske@localhost) by svn.freebsd.org (8.14.6/8.14.5/Submit) id r4C0oIeX049344; Sun, 12 May 2013 00:50:18 GMT (envelope-from dteske@svn.freebsd.org) Message-Id: <201305120050.r4C0oIeX049344@svn.freebsd.org> From: Devin Teske Date: Sun, 12 May 2013 00:50:18 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r250539 - head/usr.sbin/bsdconfig/share/packages X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 12 May 2013 00:50:19 -0000 Author: dteske Date: Sun May 12 00:50:18 2013 New Revision: 250539 URL: http://svnweb.freebsd.org/changeset/base/250539 Log: Comment. Modified: head/usr.sbin/bsdconfig/share/packages/categories.subr Modified: head/usr.sbin/bsdconfig/share/packages/categories.subr ============================================================================== --- head/usr.sbin/bsdconfig/share/packages/categories.subr Sun May 12 00:46:18 2013 (r250538) +++ head/usr.sbin/bsdconfig/share/packages/categories.subr Sun May 12 00:50:18 2013 (r250539) @@ -100,7 +100,7 @@ f_category_desc_set() # # Load descriptions for package categories. Note that we don't internationalize -# category names because this would be confusing for people used to that browse +# category names because this would be confusing for people used to browsing # the FTP mirrors or are otherwise familiar with an interface that does not # provide internationalized names. The descriptions can be used to provide i18n # users a description of the non-i18n category name. From owner-svn-src-all@FreeBSD.ORG Sun May 12 01:29:19 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id 1CDC744D; Sun, 12 May 2013 01:29:19 +0000 (UTC) (envelope-from imp@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id 0E7EB2B2; Sun, 12 May 2013 01:29:19 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.6/8.14.6) with ESMTP id r4C1TInc061928; Sun, 12 May 2013 01:29:18 GMT (envelope-from imp@svn.freebsd.org) Received: (from imp@localhost) by svn.freebsd.org (8.14.6/8.14.5/Submit) id r4C1TIAZ061927; Sun, 12 May 2013 01:29:18 GMT (envelope-from imp@svn.freebsd.org) Message-Id: <201305120129.r4C1TIAZ061927@svn.freebsd.org> From: Warner Losh Date: Sun, 12 May 2013 01:29:18 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r250540 - head/sys/contrib/octeon-sdk X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 12 May 2013 01:29:19 -0000 Author: imp Date: Sun May 12 01:29:18 2013 New Revision: 250540 URL: http://svnweb.freebsd.org/changeset/base/250540 Log: Turns out that there really isn't an RTC chip on this board, at all. Modified: head/sys/contrib/octeon-sdk/cvmx-rtc.h Modified: head/sys/contrib/octeon-sdk/cvmx-rtc.h ============================================================================== --- head/sys/contrib/octeon-sdk/cvmx-rtc.h Sun May 12 00:50:18 2013 (r250539) +++ head/sys/contrib/octeon-sdk/cvmx-rtc.h Sun May 12 01:29:18 2013 (r250540) @@ -90,9 +90,6 @@ static inline cvmx_rtc_options_t cvmx_rt case CVMX_BOARD_TYPE_EBH3000: case CVMX_BOARD_TYPE_CN3010_EVB_HS5: case CVMX_BOARD_TYPE_EBH5200: -#if defined(OCTEON_VENDOR_GEFES) - case CVMX_BOARD_TYPE_CUST_W63XX: -#endif supported = CVMX_RTC_READ | CVMX_RTC_WRITE | CVMX_RTC_TIME_CAL; break; From owner-svn-src-all@FreeBSD.ORG Sun May 12 01:37:56 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id 6C73B772; Sun, 12 May 2013 01:37:56 +0000 (UTC) (envelope-from eadler@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id 5E96B301; Sun, 12 May 2013 01:37:56 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.6/8.14.6) with ESMTP id r4C1buCG065132; Sun, 12 May 2013 01:37:56 GMT (envelope-from eadler@svn.freebsd.org) Received: (from eadler@localhost) by svn.freebsd.org (8.14.6/8.14.5/Submit) id r4C1buw4065131; Sun, 12 May 2013 01:37:56 GMT (envelope-from eadler@svn.freebsd.org) Message-Id: <201305120137.r4C1buw4065131@svn.freebsd.org> From: Eitan Adler Date: Sun, 12 May 2013 01:37:56 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org Subject: svn commit: r250541 - stable/9/share/examples/BSD_daemon X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 12 May 2013 01:37:56 -0000 Author: eadler Date: Sun May 12 01:37:55 2013 New Revision: 250541 URL: http://svnweb.freebsd.org/changeset/base/250541 Log: MFC r250012: Add an alternate version of beastie to the examples directory. PR: docs/38556 Added: stable/9/share/examples/BSD_daemon/beastie2.eps - copied unchanged from r250012, head/share/examples/BSD_daemon/beastie2.eps Modified: stable/9/share/examples/BSD_daemon/README Directory Properties: stable/9/share/ (props changed) stable/9/share/examples/ (props changed) Modified: stable/9/share/examples/BSD_daemon/README ============================================================================== --- stable/9/share/examples/BSD_daemon/README Sun May 12 01:29:18 2013 (r250540) +++ stable/9/share/examples/BSD_daemon/README Sun May 12 01:37:55 2013 (r250541) @@ -35,6 +35,10 @@ beastie.eps Before committing this, clean out the comment brought over from the .fig file to avoid Dollar-FreeBSD-Dollar junk +beastie2.eps + Written by Rahul Siddharthan beaste2.eps is a + smaller, simpler version of the beastie eps graphic. + eps.patch Add some comments about tweakables in the .eps file and set the linecaps to round to improve visual appearance. Copied: stable/9/share/examples/BSD_daemon/beastie2.eps (from r250012, head/share/examples/BSD_daemon/beastie2.eps) ============================================================================== Binary file (source and/or target). No diff available. From owner-svn-src-all@FreeBSD.ORG Sun May 12 01:38:02 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id 8C9AF878; Sun, 12 May 2013 01:38:02 +0000 (UTC) (envelope-from eadler@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id 69B67303; Sun, 12 May 2013 01:38:02 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.6/8.14.6) with ESMTP id r4C1c2LL065220; Sun, 12 May 2013 01:38:02 GMT (envelope-from eadler@svn.freebsd.org) Received: (from eadler@localhost) by svn.freebsd.org (8.14.6/8.14.5/Submit) id r4C1c2sb065218; Sun, 12 May 2013 01:38:02 GMT (envelope-from eadler@svn.freebsd.org) Message-Id: <201305120138.r4C1c2sb065218@svn.freebsd.org> From: Eitan Adler Date: Sun, 12 May 2013 01:38:02 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-8@freebsd.org Subject: svn commit: r250542 - stable/8/share/examples/BSD_daemon X-SVN-Group: stable-8 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 12 May 2013 01:38:02 -0000 Author: eadler Date: Sun May 12 01:38:01 2013 New Revision: 250542 URL: http://svnweb.freebsd.org/changeset/base/250542 Log: MFC r250012: Add an alternate version of beastie to the examples directory. PR: docs/38556 Added: stable/8/share/examples/BSD_daemon/beastie2.eps - copied unchanged from r250012, head/share/examples/BSD_daemon/beastie2.eps Modified: stable/8/share/examples/BSD_daemon/README Directory Properties: stable/8/share/ (props changed) stable/8/share/examples/ (props changed) Modified: stable/8/share/examples/BSD_daemon/README ============================================================================== --- stable/8/share/examples/BSD_daemon/README Sun May 12 01:37:55 2013 (r250541) +++ stable/8/share/examples/BSD_daemon/README Sun May 12 01:38:01 2013 (r250542) @@ -35,6 +35,10 @@ beastie.eps Before committing this, clean out the comment brought over from the .fig file to avoid Dollar-FreeBSD-Dollar junk +beastie2.eps + Written by Rahul Siddharthan beaste2.eps is a + smaller, simpler version of the beastie eps graphic. + eps.patch Add some comments about tweakables in the .eps file and set the linecaps to round to improve visual appearance. Copied: stable/8/share/examples/BSD_daemon/beastie2.eps (from r250012, head/share/examples/BSD_daemon/beastie2.eps) ============================================================================== Binary file (source and/or target). No diff available. From owner-svn-src-all@FreeBSD.ORG Sun May 12 01:53:48 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id 1327AF0C; Sun, 12 May 2013 01:53:48 +0000 (UTC) (envelope-from peter@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id 044F7377; Sun, 12 May 2013 01:53:48 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.6/8.14.6) with ESMTP id r4C1rlZZ071368; Sun, 12 May 2013 01:53:47 GMT (envelope-from peter@svn.freebsd.org) Received: (from peter@localhost) by svn.freebsd.org (8.14.6/8.14.5/Submit) id r4C1rlqi071367; Sun, 12 May 2013 01:53:47 GMT (envelope-from peter@svn.freebsd.org) Message-Id: <201305120153.r4C1rlqi071367@svn.freebsd.org> From: Peter Wemm Date: Sun, 12 May 2013 01:53:47 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org Subject: svn commit: r250544 - head/sys/amd64/compile head/sys/amd64/conf head/sys/arm/compile head/sys/arm/conf head/sys/i386/compile head/sys/i386/conf head/sys/ia64/compile head/sys/ia64/conf head/sys/mi... X-SVN-Group: defaults MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 12 May 2013 01:53:48 -0000 Author: peter Date: Sun May 12 01:53:47 2013 New Revision: 250544 URL: http://svnweb.freebsd.org/changeset/base/250544 Log: Tidy up some CVS workarounds. Deleted: stable/2.0.5/sys/compile/.keep_me stable/2.1/sys/compile/.keep_me stable/2.2/sys/compile/.keep_me Changes in other areas also in this revision: Deleted: head/sys/amd64/compile/.cvsignore head/sys/amd64/conf/.cvsignore head/sys/arm/compile/.cvsignore head/sys/arm/conf/.cvsignore head/sys/i386/compile/.cvsignore head/sys/i386/conf/.cvsignore head/sys/ia64/compile/.cvsignore head/sys/ia64/conf/.cvsignore head/sys/mips/compile/.cvsignore head/sys/mips/conf/.cvsignore head/sys/pc98/compile/.cvsignore head/sys/pc98/conf/.cvsignore head/sys/powerpc/compile/.cvsignore head/sys/powerpc/conf/.cvsignore head/sys/sparc64/compile/.cvsignore head/sys/sparc64/conf/.cvsignore head/tools/regression/geom_uzip/.cvsignore stable/3/sys/compile/.keep_me stable/4/sys/compile/.keep_me stable/5/crypto/openssh/.cvsignore stable/5/crypto/openssh/openbsd-compat/.cvsignore stable/5/crypto/openssh/scard/.cvsignore stable/5/sys/alpha/compile/.cvsignore stable/5/sys/amd64/compile/.cvsignore stable/5/sys/i386/compile/.cvsignore stable/5/sys/ia64/compile/.cvsignore stable/5/sys/pc98/compile/.cvsignore stable/5/sys/sparc64/compile/.cvsignore stable/5/tools/regression/geom_uzip/.cvsignore stable/6/sys/alpha/compile/.cvsignore stable/6/sys/alpha/conf/.cvsignore stable/6/sys/amd64/compile/.cvsignore stable/6/sys/amd64/conf/.cvsignore stable/6/sys/arm/compile/.cvsignore stable/6/sys/arm/conf/.cvsignore stable/6/sys/i386/compile/.cvsignore stable/6/sys/i386/conf/.cvsignore stable/6/sys/ia64/compile/.cvsignore stable/6/sys/ia64/conf/.cvsignore stable/6/sys/pc98/compile/.cvsignore stable/6/sys/pc98/conf/.cvsignore stable/6/sys/powerpc/compile/.cvsignore stable/6/sys/powerpc/conf/.cvsignore stable/6/sys/sparc64/compile/.cvsignore stable/6/sys/sparc64/conf/.cvsignore stable/6/tools/regression/geom_uzip/.cvsignore stable/7/sys/amd64/compile/.cvsignore stable/7/sys/amd64/conf/.cvsignore stable/7/sys/arm/compile/.cvsignore stable/7/sys/arm/conf/.cvsignore stable/7/sys/i386/compile/.cvsignore stable/7/sys/i386/conf/.cvsignore stable/7/sys/ia64/compile/.cvsignore stable/7/sys/ia64/conf/.cvsignore stable/7/sys/pc98/compile/.cvsignore stable/7/sys/pc98/conf/.cvsignore stable/7/sys/powerpc/compile/.cvsignore stable/7/sys/powerpc/conf/.cvsignore stable/7/sys/sparc64/compile/.cvsignore stable/7/sys/sparc64/conf/.cvsignore stable/7/sys/sun4v/compile/.cvsignore stable/7/sys/sun4v/conf/.cvsignore stable/7/tools/regression/geom_uzip/.cvsignore stable/8/sys/amd64/compile/.cvsignore stable/8/sys/amd64/conf/.cvsignore stable/8/sys/arm/compile/.cvsignore stable/8/sys/arm/conf/.cvsignore stable/8/sys/i386/compile/.cvsignore stable/8/sys/i386/conf/.cvsignore stable/8/sys/ia64/compile/.cvsignore stable/8/sys/ia64/conf/.cvsignore stable/8/sys/mips/compile/.cvsignore stable/8/sys/mips/conf/.cvsignore stable/8/sys/pc98/compile/.cvsignore stable/8/sys/pc98/conf/.cvsignore stable/8/sys/powerpc/compile/.cvsignore stable/8/sys/powerpc/conf/.cvsignore stable/8/sys/sparc64/compile/.cvsignore stable/8/sys/sparc64/conf/.cvsignore stable/8/sys/sun4v/compile/.cvsignore stable/8/sys/sun4v/conf/.cvsignore stable/8/tools/regression/geom_uzip/.cvsignore stable/9/sys/amd64/compile/.cvsignore stable/9/sys/amd64/conf/.cvsignore stable/9/sys/arm/compile/.cvsignore stable/9/sys/arm/conf/.cvsignore stable/9/sys/i386/compile/.cvsignore stable/9/sys/i386/conf/.cvsignore stable/9/sys/ia64/compile/.cvsignore stable/9/sys/ia64/conf/.cvsignore stable/9/sys/mips/compile/.cvsignore stable/9/sys/mips/conf/.cvsignore stable/9/sys/pc98/compile/.cvsignore stable/9/sys/pc98/conf/.cvsignore stable/9/sys/powerpc/compile/.cvsignore stable/9/sys/powerpc/conf/.cvsignore stable/9/sys/sparc64/compile/.cvsignore stable/9/sys/sparc64/conf/.cvsignore stable/9/tools/regression/geom_uzip/.cvsignore From owner-svn-src-all@FreeBSD.ORG Sun May 12 01:53:48 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id 6AB50F0D; Sun, 12 May 2013 01:53:48 +0000 (UTC) (envelope-from peter@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id 5ABE1378; Sun, 12 May 2013 01:53:48 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.6/8.14.6) with ESMTP id r4C1rmaZ071373; Sun, 12 May 2013 01:53:48 GMT (envelope-from peter@svn.freebsd.org) Received: (from peter@localhost) by svn.freebsd.org (8.14.6/8.14.5/Submit) id r4C1rmXY071372; Sun, 12 May 2013 01:53:48 GMT (envelope-from peter@svn.freebsd.org) Message-Id: <201305120153.r4C1rmXY071372@svn.freebsd.org> From: Peter Wemm Date: Sun, 12 May 2013 01:53:48 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-other@freebsd.org Subject: svn commit: r250544 - head/sys/amd64/compile head/sys/amd64/conf head/sys/arm/compile head/sys/arm/conf head/sys/i386/compile head/sys/i386/conf head/sys/ia64/compile head/sys/ia64/conf head/sys/mi... X-SVN-Group: stable-other MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 12 May 2013 01:53:48 -0000 Author: peter Date: Sun May 12 01:53:47 2013 New Revision: 250544 URL: http://svnweb.freebsd.org/changeset/base/250544 Log: Tidy up some CVS workarounds. Deleted: stable/3/sys/compile/.keep_me stable/4/sys/compile/.keep_me stable/5/crypto/openssh/.cvsignore stable/5/crypto/openssh/openbsd-compat/.cvsignore stable/5/crypto/openssh/scard/.cvsignore stable/5/sys/alpha/compile/.cvsignore stable/5/sys/amd64/compile/.cvsignore stable/5/sys/i386/compile/.cvsignore stable/5/sys/ia64/compile/.cvsignore stable/5/sys/pc98/compile/.cvsignore stable/5/sys/sparc64/compile/.cvsignore stable/5/tools/regression/geom_uzip/.cvsignore Changes in other areas also in this revision: Deleted: head/sys/amd64/compile/.cvsignore head/sys/amd64/conf/.cvsignore head/sys/arm/compile/.cvsignore head/sys/arm/conf/.cvsignore head/sys/i386/compile/.cvsignore head/sys/i386/conf/.cvsignore head/sys/ia64/compile/.cvsignore head/sys/ia64/conf/.cvsignore head/sys/mips/compile/.cvsignore head/sys/mips/conf/.cvsignore head/sys/pc98/compile/.cvsignore head/sys/pc98/conf/.cvsignore head/sys/powerpc/compile/.cvsignore head/sys/powerpc/conf/.cvsignore head/sys/sparc64/compile/.cvsignore head/sys/sparc64/conf/.cvsignore head/tools/regression/geom_uzip/.cvsignore stable/2.0.5/sys/compile/.keep_me stable/2.1/sys/compile/.keep_me stable/2.2/sys/compile/.keep_me stable/6/sys/alpha/compile/.cvsignore stable/6/sys/alpha/conf/.cvsignore stable/6/sys/amd64/compile/.cvsignore stable/6/sys/amd64/conf/.cvsignore stable/6/sys/arm/compile/.cvsignore stable/6/sys/arm/conf/.cvsignore stable/6/sys/i386/compile/.cvsignore stable/6/sys/i386/conf/.cvsignore stable/6/sys/ia64/compile/.cvsignore stable/6/sys/ia64/conf/.cvsignore stable/6/sys/pc98/compile/.cvsignore stable/6/sys/pc98/conf/.cvsignore stable/6/sys/powerpc/compile/.cvsignore stable/6/sys/powerpc/conf/.cvsignore stable/6/sys/sparc64/compile/.cvsignore stable/6/sys/sparc64/conf/.cvsignore stable/6/tools/regression/geom_uzip/.cvsignore stable/7/sys/amd64/compile/.cvsignore stable/7/sys/amd64/conf/.cvsignore stable/7/sys/arm/compile/.cvsignore stable/7/sys/arm/conf/.cvsignore stable/7/sys/i386/compile/.cvsignore stable/7/sys/i386/conf/.cvsignore stable/7/sys/ia64/compile/.cvsignore stable/7/sys/ia64/conf/.cvsignore stable/7/sys/pc98/compile/.cvsignore stable/7/sys/pc98/conf/.cvsignore stable/7/sys/powerpc/compile/.cvsignore stable/7/sys/powerpc/conf/.cvsignore stable/7/sys/sparc64/compile/.cvsignore stable/7/sys/sparc64/conf/.cvsignore stable/7/sys/sun4v/compile/.cvsignore stable/7/sys/sun4v/conf/.cvsignore stable/7/tools/regression/geom_uzip/.cvsignore stable/8/sys/amd64/compile/.cvsignore stable/8/sys/amd64/conf/.cvsignore stable/8/sys/arm/compile/.cvsignore stable/8/sys/arm/conf/.cvsignore stable/8/sys/i386/compile/.cvsignore stable/8/sys/i386/conf/.cvsignore stable/8/sys/ia64/compile/.cvsignore stable/8/sys/ia64/conf/.cvsignore stable/8/sys/mips/compile/.cvsignore stable/8/sys/mips/conf/.cvsignore stable/8/sys/pc98/compile/.cvsignore stable/8/sys/pc98/conf/.cvsignore stable/8/sys/powerpc/compile/.cvsignore stable/8/sys/powerpc/conf/.cvsignore stable/8/sys/sparc64/compile/.cvsignore stable/8/sys/sparc64/conf/.cvsignore stable/8/sys/sun4v/compile/.cvsignore stable/8/sys/sun4v/conf/.cvsignore stable/8/tools/regression/geom_uzip/.cvsignore stable/9/sys/amd64/compile/.cvsignore stable/9/sys/amd64/conf/.cvsignore stable/9/sys/arm/compile/.cvsignore stable/9/sys/arm/conf/.cvsignore stable/9/sys/i386/compile/.cvsignore stable/9/sys/i386/conf/.cvsignore stable/9/sys/ia64/compile/.cvsignore stable/9/sys/ia64/conf/.cvsignore stable/9/sys/mips/compile/.cvsignore stable/9/sys/mips/conf/.cvsignore stable/9/sys/pc98/compile/.cvsignore stable/9/sys/pc98/conf/.cvsignore stable/9/sys/powerpc/compile/.cvsignore stable/9/sys/powerpc/conf/.cvsignore stable/9/sys/sparc64/compile/.cvsignore stable/9/sys/sparc64/conf/.cvsignore stable/9/tools/regression/geom_uzip/.cvsignore From owner-svn-src-all@FreeBSD.ORG Sun May 12 01:53:48 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id BF5F8F0E; Sun, 12 May 2013 01:53:48 +0000 (UTC) (envelope-from peter@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id AFC4C379; Sun, 12 May 2013 01:53:48 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.6/8.14.6) with ESMTP id r4C1rmN5071378; Sun, 12 May 2013 01:53:48 GMT (envelope-from peter@svn.freebsd.org) Received: (from peter@localhost) by svn.freebsd.org (8.14.6/8.14.5/Submit) id r4C1rmn6071377; Sun, 12 May 2013 01:53:48 GMT (envelope-from peter@svn.freebsd.org) Message-Id: <201305120153.r4C1rmn6071377@svn.freebsd.org> From: Peter Wemm Date: Sun, 12 May 2013 01:53:48 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-6@freebsd.org Subject: svn commit: r250544 - head/sys/amd64/compile head/sys/amd64/conf head/sys/arm/compile head/sys/arm/conf head/sys/i386/compile head/sys/i386/conf head/sys/ia64/compile head/sys/ia64/conf head/sys/mi... X-SVN-Group: stable-6 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 12 May 2013 01:53:48 -0000 Author: peter Date: Sun May 12 01:53:47 2013 New Revision: 250544 URL: http://svnweb.freebsd.org/changeset/base/250544 Log: Tidy up some CVS workarounds. Deleted: stable/6/sys/alpha/compile/.cvsignore stable/6/sys/alpha/conf/.cvsignore stable/6/sys/amd64/compile/.cvsignore stable/6/sys/amd64/conf/.cvsignore stable/6/sys/arm/compile/.cvsignore stable/6/sys/arm/conf/.cvsignore stable/6/sys/i386/compile/.cvsignore stable/6/sys/i386/conf/.cvsignore stable/6/sys/ia64/compile/.cvsignore stable/6/sys/ia64/conf/.cvsignore stable/6/sys/pc98/compile/.cvsignore stable/6/sys/pc98/conf/.cvsignore stable/6/sys/powerpc/compile/.cvsignore stable/6/sys/powerpc/conf/.cvsignore stable/6/sys/sparc64/compile/.cvsignore stable/6/sys/sparc64/conf/.cvsignore stable/6/tools/regression/geom_uzip/.cvsignore Changes in other areas also in this revision: Deleted: head/sys/amd64/compile/.cvsignore head/sys/amd64/conf/.cvsignore head/sys/arm/compile/.cvsignore head/sys/arm/conf/.cvsignore head/sys/i386/compile/.cvsignore head/sys/i386/conf/.cvsignore head/sys/ia64/compile/.cvsignore head/sys/ia64/conf/.cvsignore head/sys/mips/compile/.cvsignore head/sys/mips/conf/.cvsignore head/sys/pc98/compile/.cvsignore head/sys/pc98/conf/.cvsignore head/sys/powerpc/compile/.cvsignore head/sys/powerpc/conf/.cvsignore head/sys/sparc64/compile/.cvsignore head/sys/sparc64/conf/.cvsignore head/tools/regression/geom_uzip/.cvsignore stable/2.0.5/sys/compile/.keep_me stable/2.1/sys/compile/.keep_me stable/2.2/sys/compile/.keep_me stable/3/sys/compile/.keep_me stable/4/sys/compile/.keep_me stable/5/crypto/openssh/.cvsignore stable/5/crypto/openssh/openbsd-compat/.cvsignore stable/5/crypto/openssh/scard/.cvsignore stable/5/sys/alpha/compile/.cvsignore stable/5/sys/amd64/compile/.cvsignore stable/5/sys/i386/compile/.cvsignore stable/5/sys/ia64/compile/.cvsignore stable/5/sys/pc98/compile/.cvsignore stable/5/sys/sparc64/compile/.cvsignore stable/5/tools/regression/geom_uzip/.cvsignore stable/7/sys/amd64/compile/.cvsignore stable/7/sys/amd64/conf/.cvsignore stable/7/sys/arm/compile/.cvsignore stable/7/sys/arm/conf/.cvsignore stable/7/sys/i386/compile/.cvsignore stable/7/sys/i386/conf/.cvsignore stable/7/sys/ia64/compile/.cvsignore stable/7/sys/ia64/conf/.cvsignore stable/7/sys/pc98/compile/.cvsignore stable/7/sys/pc98/conf/.cvsignore stable/7/sys/powerpc/compile/.cvsignore stable/7/sys/powerpc/conf/.cvsignore stable/7/sys/sparc64/compile/.cvsignore stable/7/sys/sparc64/conf/.cvsignore stable/7/sys/sun4v/compile/.cvsignore stable/7/sys/sun4v/conf/.cvsignore stable/7/tools/regression/geom_uzip/.cvsignore stable/8/sys/amd64/compile/.cvsignore stable/8/sys/amd64/conf/.cvsignore stable/8/sys/arm/compile/.cvsignore stable/8/sys/arm/conf/.cvsignore stable/8/sys/i386/compile/.cvsignore stable/8/sys/i386/conf/.cvsignore stable/8/sys/ia64/compile/.cvsignore stable/8/sys/ia64/conf/.cvsignore stable/8/sys/mips/compile/.cvsignore stable/8/sys/mips/conf/.cvsignore stable/8/sys/pc98/compile/.cvsignore stable/8/sys/pc98/conf/.cvsignore stable/8/sys/powerpc/compile/.cvsignore stable/8/sys/powerpc/conf/.cvsignore stable/8/sys/sparc64/compile/.cvsignore stable/8/sys/sparc64/conf/.cvsignore stable/8/sys/sun4v/compile/.cvsignore stable/8/sys/sun4v/conf/.cvsignore stable/8/tools/regression/geom_uzip/.cvsignore stable/9/sys/amd64/compile/.cvsignore stable/9/sys/amd64/conf/.cvsignore stable/9/sys/arm/compile/.cvsignore stable/9/sys/arm/conf/.cvsignore stable/9/sys/i386/compile/.cvsignore stable/9/sys/i386/conf/.cvsignore stable/9/sys/ia64/compile/.cvsignore stable/9/sys/ia64/conf/.cvsignore stable/9/sys/mips/compile/.cvsignore stable/9/sys/mips/conf/.cvsignore stable/9/sys/pc98/compile/.cvsignore stable/9/sys/pc98/conf/.cvsignore stable/9/sys/powerpc/compile/.cvsignore stable/9/sys/powerpc/conf/.cvsignore stable/9/sys/sparc64/compile/.cvsignore stable/9/sys/sparc64/conf/.cvsignore stable/9/tools/regression/geom_uzip/.cvsignore From owner-svn-src-all@FreeBSD.ORG Sun May 12 01:53:49 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id 1FB6AF0F; Sun, 12 May 2013 01:53:49 +0000 (UTC) (envelope-from peter@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id 100F537A; Sun, 12 May 2013 01:53:49 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.6/8.14.6) with ESMTP id r4C1rmZ9071385; Sun, 12 May 2013 01:53:48 GMT (envelope-from peter@svn.freebsd.org) Received: (from peter@localhost) by svn.freebsd.org (8.14.6/8.14.5/Submit) id r4C1rmhU071383; Sun, 12 May 2013 01:53:48 GMT (envelope-from peter@svn.freebsd.org) Message-Id: <201305120153.r4C1rmhU071383@svn.freebsd.org> From: Peter Wemm Date: Sun, 12 May 2013 01:53:48 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-7@freebsd.org Subject: svn commit: r250544 - head/sys/amd64/compile head/sys/amd64/conf head/sys/arm/compile head/sys/arm/conf head/sys/i386/compile head/sys/i386/conf head/sys/ia64/compile head/sys/ia64/conf head/sys/mi... X-SVN-Group: stable-7 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 12 May 2013 01:53:49 -0000 Author: peter Date: Sun May 12 01:53:47 2013 New Revision: 250544 URL: http://svnweb.freebsd.org/changeset/base/250544 Log: Tidy up some CVS workarounds. Deleted: stable/7/sys/amd64/compile/.cvsignore stable/7/sys/amd64/conf/.cvsignore stable/7/sys/arm/compile/.cvsignore stable/7/sys/arm/conf/.cvsignore stable/7/sys/i386/compile/.cvsignore stable/7/sys/i386/conf/.cvsignore stable/7/sys/ia64/compile/.cvsignore stable/7/sys/ia64/conf/.cvsignore stable/7/sys/pc98/compile/.cvsignore stable/7/sys/pc98/conf/.cvsignore stable/7/sys/powerpc/compile/.cvsignore stable/7/sys/powerpc/conf/.cvsignore stable/7/sys/sparc64/compile/.cvsignore stable/7/sys/sparc64/conf/.cvsignore stable/7/sys/sun4v/compile/.cvsignore stable/7/sys/sun4v/conf/.cvsignore stable/7/tools/regression/geom_uzip/.cvsignore Changes in other areas also in this revision: Deleted: head/sys/amd64/compile/.cvsignore head/sys/amd64/conf/.cvsignore head/sys/arm/compile/.cvsignore head/sys/arm/conf/.cvsignore head/sys/i386/compile/.cvsignore head/sys/i386/conf/.cvsignore head/sys/ia64/compile/.cvsignore head/sys/ia64/conf/.cvsignore head/sys/mips/compile/.cvsignore head/sys/mips/conf/.cvsignore head/sys/pc98/compile/.cvsignore head/sys/pc98/conf/.cvsignore head/sys/powerpc/compile/.cvsignore head/sys/powerpc/conf/.cvsignore head/sys/sparc64/compile/.cvsignore head/sys/sparc64/conf/.cvsignore head/tools/regression/geom_uzip/.cvsignore stable/2.0.5/sys/compile/.keep_me stable/2.1/sys/compile/.keep_me stable/2.2/sys/compile/.keep_me stable/3/sys/compile/.keep_me stable/4/sys/compile/.keep_me stable/5/crypto/openssh/.cvsignore stable/5/crypto/openssh/openbsd-compat/.cvsignore stable/5/crypto/openssh/scard/.cvsignore stable/5/sys/alpha/compile/.cvsignore stable/5/sys/amd64/compile/.cvsignore stable/5/sys/i386/compile/.cvsignore stable/5/sys/ia64/compile/.cvsignore stable/5/sys/pc98/compile/.cvsignore stable/5/sys/sparc64/compile/.cvsignore stable/5/tools/regression/geom_uzip/.cvsignore stable/6/sys/alpha/compile/.cvsignore stable/6/sys/alpha/conf/.cvsignore stable/6/sys/amd64/compile/.cvsignore stable/6/sys/amd64/conf/.cvsignore stable/6/sys/arm/compile/.cvsignore stable/6/sys/arm/conf/.cvsignore stable/6/sys/i386/compile/.cvsignore stable/6/sys/i386/conf/.cvsignore stable/6/sys/ia64/compile/.cvsignore stable/6/sys/ia64/conf/.cvsignore stable/6/sys/pc98/compile/.cvsignore stable/6/sys/pc98/conf/.cvsignore stable/6/sys/powerpc/compile/.cvsignore stable/6/sys/powerpc/conf/.cvsignore stable/6/sys/sparc64/compile/.cvsignore stable/6/sys/sparc64/conf/.cvsignore stable/6/tools/regression/geom_uzip/.cvsignore stable/8/sys/amd64/compile/.cvsignore stable/8/sys/amd64/conf/.cvsignore stable/8/sys/arm/compile/.cvsignore stable/8/sys/arm/conf/.cvsignore stable/8/sys/i386/compile/.cvsignore stable/8/sys/i386/conf/.cvsignore stable/8/sys/ia64/compile/.cvsignore stable/8/sys/ia64/conf/.cvsignore stable/8/sys/mips/compile/.cvsignore stable/8/sys/mips/conf/.cvsignore stable/8/sys/pc98/compile/.cvsignore stable/8/sys/pc98/conf/.cvsignore stable/8/sys/powerpc/compile/.cvsignore stable/8/sys/powerpc/conf/.cvsignore stable/8/sys/sparc64/compile/.cvsignore stable/8/sys/sparc64/conf/.cvsignore stable/8/sys/sun4v/compile/.cvsignore stable/8/sys/sun4v/conf/.cvsignore stable/8/tools/regression/geom_uzip/.cvsignore stable/9/sys/amd64/compile/.cvsignore stable/9/sys/amd64/conf/.cvsignore stable/9/sys/arm/compile/.cvsignore stable/9/sys/arm/conf/.cvsignore stable/9/sys/i386/compile/.cvsignore stable/9/sys/i386/conf/.cvsignore stable/9/sys/ia64/compile/.cvsignore stable/9/sys/ia64/conf/.cvsignore stable/9/sys/mips/compile/.cvsignore stable/9/sys/mips/conf/.cvsignore stable/9/sys/pc98/compile/.cvsignore stable/9/sys/pc98/conf/.cvsignore stable/9/sys/powerpc/compile/.cvsignore stable/9/sys/powerpc/conf/.cvsignore stable/9/sys/sparc64/compile/.cvsignore stable/9/sys/sparc64/conf/.cvsignore stable/9/tools/regression/geom_uzip/.cvsignore From owner-svn-src-all@FreeBSD.ORG Sun May 12 01:53:49 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id 72222F10; Sun, 12 May 2013 01:53:49 +0000 (UTC) (envelope-from peter@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id 62A7F37B; Sun, 12 May 2013 01:53:49 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.6/8.14.6) with ESMTP id r4C1rndl071391; Sun, 12 May 2013 01:53:49 GMT (envelope-from peter@svn.freebsd.org) Received: (from peter@localhost) by svn.freebsd.org (8.14.6/8.14.5/Submit) id r4C1rnHe071390; Sun, 12 May 2013 01:53:49 GMT (envelope-from peter@svn.freebsd.org) Message-Id: <201305120153.r4C1rnHe071390@svn.freebsd.org> From: Peter Wemm Date: Sun, 12 May 2013 01:53:49 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-8@freebsd.org Subject: svn commit: r250544 - head/sys/amd64/compile head/sys/amd64/conf head/sys/arm/compile head/sys/arm/conf head/sys/i386/compile head/sys/i386/conf head/sys/ia64/compile head/sys/ia64/conf head/sys/mi... X-SVN-Group: stable-8 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 12 May 2013 01:53:49 -0000 Author: peter Date: Sun May 12 01:53:47 2013 New Revision: 250544 URL: http://svnweb.freebsd.org/changeset/base/250544 Log: Tidy up some CVS workarounds. Deleted: stable/8/sys/amd64/compile/.cvsignore stable/8/sys/amd64/conf/.cvsignore stable/8/sys/arm/compile/.cvsignore stable/8/sys/arm/conf/.cvsignore stable/8/sys/i386/compile/.cvsignore stable/8/sys/i386/conf/.cvsignore stable/8/sys/ia64/compile/.cvsignore stable/8/sys/ia64/conf/.cvsignore stable/8/sys/mips/compile/.cvsignore stable/8/sys/mips/conf/.cvsignore stable/8/sys/pc98/compile/.cvsignore stable/8/sys/pc98/conf/.cvsignore stable/8/sys/powerpc/compile/.cvsignore stable/8/sys/powerpc/conf/.cvsignore stable/8/sys/sparc64/compile/.cvsignore stable/8/sys/sparc64/conf/.cvsignore stable/8/sys/sun4v/compile/.cvsignore stable/8/sys/sun4v/conf/.cvsignore stable/8/tools/regression/geom_uzip/.cvsignore Changes in other areas also in this revision: Deleted: head/sys/amd64/compile/.cvsignore head/sys/amd64/conf/.cvsignore head/sys/arm/compile/.cvsignore head/sys/arm/conf/.cvsignore head/sys/i386/compile/.cvsignore head/sys/i386/conf/.cvsignore head/sys/ia64/compile/.cvsignore head/sys/ia64/conf/.cvsignore head/sys/mips/compile/.cvsignore head/sys/mips/conf/.cvsignore head/sys/pc98/compile/.cvsignore head/sys/pc98/conf/.cvsignore head/sys/powerpc/compile/.cvsignore head/sys/powerpc/conf/.cvsignore head/sys/sparc64/compile/.cvsignore head/sys/sparc64/conf/.cvsignore head/tools/regression/geom_uzip/.cvsignore stable/2.0.5/sys/compile/.keep_me stable/2.1/sys/compile/.keep_me stable/2.2/sys/compile/.keep_me stable/3/sys/compile/.keep_me stable/4/sys/compile/.keep_me stable/5/crypto/openssh/.cvsignore stable/5/crypto/openssh/openbsd-compat/.cvsignore stable/5/crypto/openssh/scard/.cvsignore stable/5/sys/alpha/compile/.cvsignore stable/5/sys/amd64/compile/.cvsignore stable/5/sys/i386/compile/.cvsignore stable/5/sys/ia64/compile/.cvsignore stable/5/sys/pc98/compile/.cvsignore stable/5/sys/sparc64/compile/.cvsignore stable/5/tools/regression/geom_uzip/.cvsignore stable/6/sys/alpha/compile/.cvsignore stable/6/sys/alpha/conf/.cvsignore stable/6/sys/amd64/compile/.cvsignore stable/6/sys/amd64/conf/.cvsignore stable/6/sys/arm/compile/.cvsignore stable/6/sys/arm/conf/.cvsignore stable/6/sys/i386/compile/.cvsignore stable/6/sys/i386/conf/.cvsignore stable/6/sys/ia64/compile/.cvsignore stable/6/sys/ia64/conf/.cvsignore stable/6/sys/pc98/compile/.cvsignore stable/6/sys/pc98/conf/.cvsignore stable/6/sys/powerpc/compile/.cvsignore stable/6/sys/powerpc/conf/.cvsignore stable/6/sys/sparc64/compile/.cvsignore stable/6/sys/sparc64/conf/.cvsignore stable/6/tools/regression/geom_uzip/.cvsignore stable/7/sys/amd64/compile/.cvsignore stable/7/sys/amd64/conf/.cvsignore stable/7/sys/arm/compile/.cvsignore stable/7/sys/arm/conf/.cvsignore stable/7/sys/i386/compile/.cvsignore stable/7/sys/i386/conf/.cvsignore stable/7/sys/ia64/compile/.cvsignore stable/7/sys/ia64/conf/.cvsignore stable/7/sys/pc98/compile/.cvsignore stable/7/sys/pc98/conf/.cvsignore stable/7/sys/powerpc/compile/.cvsignore stable/7/sys/powerpc/conf/.cvsignore stable/7/sys/sparc64/compile/.cvsignore stable/7/sys/sparc64/conf/.cvsignore stable/7/sys/sun4v/compile/.cvsignore stable/7/sys/sun4v/conf/.cvsignore stable/7/tools/regression/geom_uzip/.cvsignore stable/9/sys/amd64/compile/.cvsignore stable/9/sys/amd64/conf/.cvsignore stable/9/sys/arm/compile/.cvsignore stable/9/sys/arm/conf/.cvsignore stable/9/sys/i386/compile/.cvsignore stable/9/sys/i386/conf/.cvsignore stable/9/sys/ia64/compile/.cvsignore stable/9/sys/ia64/conf/.cvsignore stable/9/sys/mips/compile/.cvsignore stable/9/sys/mips/conf/.cvsignore stable/9/sys/pc98/compile/.cvsignore stable/9/sys/pc98/conf/.cvsignore stable/9/sys/powerpc/compile/.cvsignore stable/9/sys/powerpc/conf/.cvsignore stable/9/sys/sparc64/compile/.cvsignore stable/9/sys/sparc64/conf/.cvsignore stable/9/tools/regression/geom_uzip/.cvsignore From owner-svn-src-all@FreeBSD.ORG Sun May 12 01:53:49 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id C54E7F11; Sun, 12 May 2013 01:53:49 +0000 (UTC) (envelope-from peter@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id B5DC637C; Sun, 12 May 2013 01:53:49 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.6/8.14.6) with ESMTP id r4C1rnYV071398; Sun, 12 May 2013 01:53:49 GMT (envelope-from peter@svn.freebsd.org) Received: (from peter@localhost) by svn.freebsd.org (8.14.6/8.14.5/Submit) id r4C1rnqF071397; Sun, 12 May 2013 01:53:49 GMT (envelope-from peter@svn.freebsd.org) Message-Id: <201305120153.r4C1rnqF071397@svn.freebsd.org> From: Peter Wemm Date: Sun, 12 May 2013 01:53:49 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org Subject: svn commit: r250544 - head/sys/amd64/compile head/sys/amd64/conf head/sys/arm/compile head/sys/arm/conf head/sys/i386/compile head/sys/i386/conf head/sys/ia64/compile head/sys/ia64/conf head/sys/mi... X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 12 May 2013 01:53:49 -0000 Author: peter Date: Sun May 12 01:53:47 2013 New Revision: 250544 URL: http://svnweb.freebsd.org/changeset/base/250544 Log: Tidy up some CVS workarounds. Deleted: stable/9/sys/amd64/compile/.cvsignore stable/9/sys/amd64/conf/.cvsignore stable/9/sys/arm/compile/.cvsignore stable/9/sys/arm/conf/.cvsignore stable/9/sys/i386/compile/.cvsignore stable/9/sys/i386/conf/.cvsignore stable/9/sys/ia64/compile/.cvsignore stable/9/sys/ia64/conf/.cvsignore stable/9/sys/mips/compile/.cvsignore stable/9/sys/mips/conf/.cvsignore stable/9/sys/pc98/compile/.cvsignore stable/9/sys/pc98/conf/.cvsignore stable/9/sys/powerpc/compile/.cvsignore stable/9/sys/powerpc/conf/.cvsignore stable/9/sys/sparc64/compile/.cvsignore stable/9/sys/sparc64/conf/.cvsignore stable/9/tools/regression/geom_uzip/.cvsignore Changes in other areas also in this revision: Deleted: head/sys/amd64/compile/.cvsignore head/sys/amd64/conf/.cvsignore head/sys/arm/compile/.cvsignore head/sys/arm/conf/.cvsignore head/sys/i386/compile/.cvsignore head/sys/i386/conf/.cvsignore head/sys/ia64/compile/.cvsignore head/sys/ia64/conf/.cvsignore head/sys/mips/compile/.cvsignore head/sys/mips/conf/.cvsignore head/sys/pc98/compile/.cvsignore head/sys/pc98/conf/.cvsignore head/sys/powerpc/compile/.cvsignore head/sys/powerpc/conf/.cvsignore head/sys/sparc64/compile/.cvsignore head/sys/sparc64/conf/.cvsignore head/tools/regression/geom_uzip/.cvsignore stable/2.0.5/sys/compile/.keep_me stable/2.1/sys/compile/.keep_me stable/2.2/sys/compile/.keep_me stable/3/sys/compile/.keep_me stable/4/sys/compile/.keep_me stable/5/crypto/openssh/.cvsignore stable/5/crypto/openssh/openbsd-compat/.cvsignore stable/5/crypto/openssh/scard/.cvsignore stable/5/sys/alpha/compile/.cvsignore stable/5/sys/amd64/compile/.cvsignore stable/5/sys/i386/compile/.cvsignore stable/5/sys/ia64/compile/.cvsignore stable/5/sys/pc98/compile/.cvsignore stable/5/sys/sparc64/compile/.cvsignore stable/5/tools/regression/geom_uzip/.cvsignore stable/6/sys/alpha/compile/.cvsignore stable/6/sys/alpha/conf/.cvsignore stable/6/sys/amd64/compile/.cvsignore stable/6/sys/amd64/conf/.cvsignore stable/6/sys/arm/compile/.cvsignore stable/6/sys/arm/conf/.cvsignore stable/6/sys/i386/compile/.cvsignore stable/6/sys/i386/conf/.cvsignore stable/6/sys/ia64/compile/.cvsignore stable/6/sys/ia64/conf/.cvsignore stable/6/sys/pc98/compile/.cvsignore stable/6/sys/pc98/conf/.cvsignore stable/6/sys/powerpc/compile/.cvsignore stable/6/sys/powerpc/conf/.cvsignore stable/6/sys/sparc64/compile/.cvsignore stable/6/sys/sparc64/conf/.cvsignore stable/6/tools/regression/geom_uzip/.cvsignore stable/7/sys/amd64/compile/.cvsignore stable/7/sys/amd64/conf/.cvsignore stable/7/sys/arm/compile/.cvsignore stable/7/sys/arm/conf/.cvsignore stable/7/sys/i386/compile/.cvsignore stable/7/sys/i386/conf/.cvsignore stable/7/sys/ia64/compile/.cvsignore stable/7/sys/ia64/conf/.cvsignore stable/7/sys/pc98/compile/.cvsignore stable/7/sys/pc98/conf/.cvsignore stable/7/sys/powerpc/compile/.cvsignore stable/7/sys/powerpc/conf/.cvsignore stable/7/sys/sparc64/compile/.cvsignore stable/7/sys/sparc64/conf/.cvsignore stable/7/sys/sun4v/compile/.cvsignore stable/7/sys/sun4v/conf/.cvsignore stable/7/tools/regression/geom_uzip/.cvsignore stable/8/sys/amd64/compile/.cvsignore stable/8/sys/amd64/conf/.cvsignore stable/8/sys/arm/compile/.cvsignore stable/8/sys/arm/conf/.cvsignore stable/8/sys/i386/compile/.cvsignore stable/8/sys/i386/conf/.cvsignore stable/8/sys/ia64/compile/.cvsignore stable/8/sys/ia64/conf/.cvsignore stable/8/sys/mips/compile/.cvsignore stable/8/sys/mips/conf/.cvsignore stable/8/sys/pc98/compile/.cvsignore stable/8/sys/pc98/conf/.cvsignore stable/8/sys/powerpc/compile/.cvsignore stable/8/sys/powerpc/conf/.cvsignore stable/8/sys/sparc64/compile/.cvsignore stable/8/sys/sparc64/conf/.cvsignore stable/8/sys/sun4v/compile/.cvsignore stable/8/sys/sun4v/conf/.cvsignore stable/8/tools/regression/geom_uzip/.cvsignore From owner-svn-src-all@FreeBSD.ORG Sun May 12 01:53:50 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id 2508CF12; Sun, 12 May 2013 01:53:50 +0000 (UTC) (envelope-from peter@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id 1614F37D; Sun, 12 May 2013 01:53:50 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.6/8.14.6) with ESMTP id r4C1rnTu071404; Sun, 12 May 2013 01:53:49 GMT (envelope-from peter@svn.freebsd.org) Received: (from peter@localhost) by svn.freebsd.org (8.14.6/8.14.5/Submit) id r4C1rnE2071403; Sun, 12 May 2013 01:53:49 GMT (envelope-from peter@svn.freebsd.org) Message-Id: <201305120153.r4C1rnE2071403@svn.freebsd.org> From: Peter Wemm Date: Sun, 12 May 2013 01:53:49 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r250544 - head/sys/amd64/compile head/sys/amd64/conf head/sys/arm/compile head/sys/arm/conf head/sys/i386/compile head/sys/i386/conf head/sys/ia64/compile head/sys/ia64/conf head/sys/mi... X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 12 May 2013 01:53:50 -0000 Author: peter Date: Sun May 12 01:53:47 2013 New Revision: 250544 URL: http://svnweb.freebsd.org/changeset/base/250544 Log: Tidy up some CVS workarounds. Deleted: head/sys/amd64/compile/.cvsignore head/sys/amd64/conf/.cvsignore head/sys/arm/compile/.cvsignore head/sys/arm/conf/.cvsignore head/sys/i386/compile/.cvsignore head/sys/i386/conf/.cvsignore head/sys/ia64/compile/.cvsignore head/sys/ia64/conf/.cvsignore head/sys/mips/compile/.cvsignore head/sys/mips/conf/.cvsignore head/sys/pc98/compile/.cvsignore head/sys/pc98/conf/.cvsignore head/sys/powerpc/compile/.cvsignore head/sys/powerpc/conf/.cvsignore head/sys/sparc64/compile/.cvsignore head/sys/sparc64/conf/.cvsignore head/tools/regression/geom_uzip/.cvsignore Changes in other areas also in this revision: Deleted: stable/2.0.5/sys/compile/.keep_me stable/2.1/sys/compile/.keep_me stable/2.2/sys/compile/.keep_me stable/3/sys/compile/.keep_me stable/4/sys/compile/.keep_me stable/5/crypto/openssh/.cvsignore stable/5/crypto/openssh/openbsd-compat/.cvsignore stable/5/crypto/openssh/scard/.cvsignore stable/5/sys/alpha/compile/.cvsignore stable/5/sys/amd64/compile/.cvsignore stable/5/sys/i386/compile/.cvsignore stable/5/sys/ia64/compile/.cvsignore stable/5/sys/pc98/compile/.cvsignore stable/5/sys/sparc64/compile/.cvsignore stable/5/tools/regression/geom_uzip/.cvsignore stable/6/sys/alpha/compile/.cvsignore stable/6/sys/alpha/conf/.cvsignore stable/6/sys/amd64/compile/.cvsignore stable/6/sys/amd64/conf/.cvsignore stable/6/sys/arm/compile/.cvsignore stable/6/sys/arm/conf/.cvsignore stable/6/sys/i386/compile/.cvsignore stable/6/sys/i386/conf/.cvsignore stable/6/sys/ia64/compile/.cvsignore stable/6/sys/ia64/conf/.cvsignore stable/6/sys/pc98/compile/.cvsignore stable/6/sys/pc98/conf/.cvsignore stable/6/sys/powerpc/compile/.cvsignore stable/6/sys/powerpc/conf/.cvsignore stable/6/sys/sparc64/compile/.cvsignore stable/6/sys/sparc64/conf/.cvsignore stable/6/tools/regression/geom_uzip/.cvsignore stable/7/sys/amd64/compile/.cvsignore stable/7/sys/amd64/conf/.cvsignore stable/7/sys/arm/compile/.cvsignore stable/7/sys/arm/conf/.cvsignore stable/7/sys/i386/compile/.cvsignore stable/7/sys/i386/conf/.cvsignore stable/7/sys/ia64/compile/.cvsignore stable/7/sys/ia64/conf/.cvsignore stable/7/sys/pc98/compile/.cvsignore stable/7/sys/pc98/conf/.cvsignore stable/7/sys/powerpc/compile/.cvsignore stable/7/sys/powerpc/conf/.cvsignore stable/7/sys/sparc64/compile/.cvsignore stable/7/sys/sparc64/conf/.cvsignore stable/7/sys/sun4v/compile/.cvsignore stable/7/sys/sun4v/conf/.cvsignore stable/7/tools/regression/geom_uzip/.cvsignore stable/8/sys/amd64/compile/.cvsignore stable/8/sys/amd64/conf/.cvsignore stable/8/sys/arm/compile/.cvsignore stable/8/sys/arm/conf/.cvsignore stable/8/sys/i386/compile/.cvsignore stable/8/sys/i386/conf/.cvsignore stable/8/sys/ia64/compile/.cvsignore stable/8/sys/ia64/conf/.cvsignore stable/8/sys/mips/compile/.cvsignore stable/8/sys/mips/conf/.cvsignore stable/8/sys/pc98/compile/.cvsignore stable/8/sys/pc98/conf/.cvsignore stable/8/sys/powerpc/compile/.cvsignore stable/8/sys/powerpc/conf/.cvsignore stable/8/sys/sparc64/compile/.cvsignore stable/8/sys/sparc64/conf/.cvsignore stable/8/sys/sun4v/compile/.cvsignore stable/8/sys/sun4v/conf/.cvsignore stable/8/tools/regression/geom_uzip/.cvsignore stable/9/sys/amd64/compile/.cvsignore stable/9/sys/amd64/conf/.cvsignore stable/9/sys/arm/compile/.cvsignore stable/9/sys/arm/conf/.cvsignore stable/9/sys/i386/compile/.cvsignore stable/9/sys/i386/conf/.cvsignore stable/9/sys/ia64/compile/.cvsignore stable/9/sys/ia64/conf/.cvsignore stable/9/sys/mips/compile/.cvsignore stable/9/sys/mips/conf/.cvsignore stable/9/sys/pc98/compile/.cvsignore stable/9/sys/pc98/conf/.cvsignore stable/9/sys/powerpc/compile/.cvsignore stable/9/sys/powerpc/conf/.cvsignore stable/9/sys/sparc64/compile/.cvsignore stable/9/sys/sparc64/conf/.cvsignore stable/9/tools/regression/geom_uzip/.cvsignore From owner-svn-src-all@FreeBSD.ORG Sun May 12 01:58:05 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id 2AB6A9A8; Sun, 12 May 2013 01:58:05 +0000 (UTC) (envelope-from markj@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id 038083D6; Sun, 12 May 2013 01:58:05 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.6/8.14.6) with ESMTP id r4C1w4Sb072289; Sun, 12 May 2013 01:58:04 GMT (envelope-from markj@svn.freebsd.org) Received: (from markj@localhost) by svn.freebsd.org (8.14.6/8.14.5/Submit) id r4C1w4Qf072288; Sun, 12 May 2013 01:58:04 GMT (envelope-from markj@svn.freebsd.org) Message-Id: <201305120158.r4C1w4Qf072288@svn.freebsd.org> From: Mark Johnston Date: Sun, 12 May 2013 01:58:04 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r250545 - head/usr.sbin/newsyslog X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 12 May 2013 01:58:05 -0000 Author: markj Date: Sun May 12 01:58:04 2013 New Revision: 250545 URL: http://svnweb.freebsd.org/changeset/base/250545 Log: Some filesystems (NFS in particular) do not fill out the d_type field when returning directory entries through readdir(3). In this case we need to obtain the file type ourselves; otherwise newsyslog -t will not be able to find archived log files and will fail to both delete old log files and to do interval-based rotations properly. Reported by: jilles Reviewed by: jilles MFC after: 2 weeks Modified: head/usr.sbin/newsyslog/newsyslog.c Modified: head/usr.sbin/newsyslog/newsyslog.c ============================================================================== --- head/usr.sbin/newsyslog/newsyslog.c Sun May 12 01:53:47 2013 (r250544) +++ head/usr.sbin/newsyslog/newsyslog.c Sun May 12 01:58:04 2013 (r250545) @@ -1452,16 +1452,27 @@ oldlog_entry_compare(const void *a, cons * tm if this is the case; otherwise return false. */ static int -validate_old_timelog(const struct dirent *dp, const char *logfname, struct tm *tm) +validate_old_timelog(int fd, const struct dirent *dp, const char *logfname, + struct tm *tm) { + struct stat sb; size_t logfname_len; char *s; int c; logfname_len = strlen(logfname); - if (dp->d_type != DT_REG) - return (0); + if (dp->d_type != DT_REG) { + /* + * Some filesystems (e.g. NFS) don't fill out the d_type field + * and leave it set to DT_UNKNOWN; in this case we must obtain + * the file type ourselves. + */ + if (dp->d_type != DT_UNKNOWN || + fstatat(fd, dp->d_name, &sb, AT_SYMLINK_NOFOLLOW) != 0 || + !S_ISREG(sb.st_mode)) + return (0); + } /* Ignore everything but files with our logfile prefix. */ if (strncmp(dp->d_name, logfname, logfname_len) != 0) return (0); @@ -1547,7 +1558,7 @@ delete_oldest_timelog(const struct conf_ err(1, "Cannot open log directory '%s'", dir); dir_fd = dirfd(dirp); while ((dp = readdir(dirp)) != NULL) { - if (validate_old_timelog(dp, logfname, &tm) == 0) + if (validate_old_timelog(dir_fd, dp, logfname, &tm) == 0) continue; /* @@ -2312,10 +2323,10 @@ mtime_old_timelog(const char *file) dir_fd = dirfd(dirp); /* Open the archive dir and find the most recent archive of logfname. */ while ((dp = readdir(dirp)) != NULL) { - if (validate_old_timelog(dp, logfname, &tm) == 0) + if (validate_old_timelog(dir_fd, dp, logfname, &tm) == 0) continue; - if (fstatat(dir_fd, logfname, &sb, 0) == -1) { + if (fstatat(dir_fd, logfname, &sb, AT_SYMLINK_NOFOLLOW) == -1) { warn("Cannot stat '%s'", file); continue; } From owner-svn-src-all@FreeBSD.ORG Sun May 12 03:36:28 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id EC02DC01; Sun, 12 May 2013 03:36:28 +0000 (UTC) (envelope-from pfg@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id DC37991A; Sun, 12 May 2013 03:36:28 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.6/8.14.6) with ESMTP id r4C3aSId008263; Sun, 12 May 2013 03:36:28 GMT (envelope-from pfg@svn.freebsd.org) Received: (from pfg@localhost) by svn.freebsd.org (8.14.6/8.14.5/Submit) id r4C3aSFr008262; Sun, 12 May 2013 03:36:28 GMT (envelope-from pfg@svn.freebsd.org) Message-Id: <201305120336.r4C3aSFr008262@svn.freebsd.org> From: "Pedro F. Giffuni" Date: Sun, 12 May 2013 03:36:28 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r250550 - head/contrib/gcc X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 12 May 2013 03:36:29 -0000 Author: pfg Date: Sun May 12 03:36:28 2013 New Revision: 250550 URL: http://svnweb.freebsd.org/changeset/base/250550 Log: Update the gcc43 changelog. The issue solved in r250392 actually originated upstream and was fixed in upstream gcc43 branch in 2006/10/24 (under GPLv2). Register it in the appropriate ChangeLog for reference. MFC after: 3 days Modified: head/contrib/gcc/ChangeLog.gcc43 Modified: head/contrib/gcc/ChangeLog.gcc43 ============================================================================== --- head/contrib/gcc/ChangeLog.gcc43 Sun May 12 02:19:05 2013 (r250549) +++ head/contrib/gcc/ChangeLog.gcc43 Sun May 12 03:36:28 2013 (r250550) @@ -182,6 +182,10 @@ * doc/invoke.texi: Document -mssse3/-mno-ssse3 switches. +2006-10-22 H.J. Lu + + * config/i386/tmmintrin.h: Remove the duplicated content. + 2006-10-21 Richard Guenther (r117932) PR tree-optimization/3511 From owner-svn-src-all@FreeBSD.ORG Sun May 12 04:05:03 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id 3DA39EB5; Sun, 12 May 2013 04:05:03 +0000 (UTC) (envelope-from jeff@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id 1E9569BB; Sun, 12 May 2013 04:05:03 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.6/8.14.6) with ESMTP id r4C4520j018377; Sun, 12 May 2013 04:05:02 GMT (envelope-from jeff@svn.freebsd.org) Received: (from jeff@localhost) by svn.freebsd.org (8.14.6/8.14.5/Submit) id r4C452fr018368; Sun, 12 May 2013 04:05:02 GMT (envelope-from jeff@svn.freebsd.org) Message-Id: <201305120405.r4C452fr018368@svn.freebsd.org> From: Jeff Roberson Date: Sun, 12 May 2013 04:05:02 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r250551 - in head/sys: conf kern sys X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 12 May 2013 04:05:03 -0000 Author: jeff Date: Sun May 12 04:05:01 2013 New Revision: 250551 URL: http://svnweb.freebsd.org/changeset/base/250551 Log: - Add a new general purpose path-compressed radix trie which can be used with any structure containing a uint64_t index. The tree code auto-generates type safe wrappers. - Eliminate the buf splay and replace it with pctrie. This is not only significantly faster with large files but also allows for the possibility of shared locking. Reviewed by: alc, attilio Sponsored by: EMC / Isilon Storage Division Added: head/sys/kern/subr_pctrie.c (contents, props changed) head/sys/sys/_pctrie.h - copied, changed from r249323, head/sys/vm/_vm_radix.h head/sys/sys/pctrie.h (contents, props changed) Modified: head/sys/conf/files head/sys/kern/vfs_subr.c head/sys/sys/buf.h head/sys/sys/bufobj.h Modified: head/sys/conf/files ============================================================================== --- head/sys/conf/files Sun May 12 03:36:28 2013 (r250550) +++ head/sys/conf/files Sun May 12 04:05:01 2013 (r250551) @@ -2760,6 +2760,7 @@ kern/subr_module.c standard kern/subr_msgbuf.c standard kern/subr_param.c standard kern/subr_pcpu.c standard +kern/subr_pctrie.c standard kern/subr_power.c standard kern/subr_prf.c standard kern/subr_prof.c standard Added: head/sys/kern/subr_pctrie.c ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ head/sys/kern/subr_pctrie.c Sun May 12 04:05:01 2013 (r250551) @@ -0,0 +1,705 @@ +/* + * Copyright (c) 2013 EMC Corp. + * Copyright (c) 2011 Jeffrey Roberson + * Copyright (c) 2008 Mayur Shardul + * 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. + * + */ + +/* + * Path-compressed radix trie implementation. + * + * The implementation takes into account the following rationale: + * - Size of the nodes should be as small as possible but still big enough + * to avoid a large maximum depth for the trie. This is a balance + * between the necessity to not wire too much physical memory for the nodes + * and the necessity to avoid too much cache pollution during the trie + * operations. + * - There is not a huge bias toward the number of lookup operations over + * the number of insert and remove operations. This basically implies + * that optimizations supposedly helping one operation but hurting the + * other might be carefully evaluated. + * - On average not many nodes are expected to be fully populated, hence + * level compression may just complicate things. + */ + +#include +__FBSDID("$FreeBSD$"); + +#include "opt_ddb.h" + +#include +#include +#include +#include + +#ifdef DDB +#include +#endif + +/* + * These widths should allow the pointers to a node's children to fit within + * a single cache line. The extra levels from a narrow width should not be + * a problem thanks to path compression. + */ +#ifdef __LP64__ +#define PCTRIE_WIDTH 4 +#else +#define PCTRIE_WIDTH 3 +#endif + +#define PCTRIE_COUNT (1 << PCTRIE_WIDTH) +#define PCTRIE_MASK (PCTRIE_COUNT - 1) +#define PCTRIE_LIMIT (howmany((sizeof(uint64_t) * NBBY), PCTRIE_WIDTH) - 1) + +/* Flag bits stored in node pointers. */ +#define PCTRIE_ISLEAF 0x1 +#define PCTRIE_FLAGS 0x1 +#define PCTRIE_PAD PCTRIE_FLAGS + +/* Returns one unit associated with specified level. */ +#define PCTRIE_UNITLEVEL(lev) \ + ((uint64_t)1 << ((lev) * PCTRIE_WIDTH)) + +struct pctrie_node { + uint64_t pn_owner; /* Owner of record. */ + uint16_t pn_count; /* Valid children. */ + uint16_t pn_clev; /* Current level. */ + void *pn_child[PCTRIE_COUNT]; /* Child nodes. */ +}; + +/* + * Allocate a node. Pre-allocation should ensure that the request + * will always be satisfied. + */ +static __inline struct pctrie_node * +pctrie_node_get(struct pctrie *ptree, pctrie_alloc_t allocfn, uint64_t owner, + uint16_t count, uint16_t clevel) +{ + struct pctrie_node *node; + + node = allocfn(ptree); + if (node == NULL) + return (NULL); + node->pn_owner = owner; + node->pn_count = count; + node->pn_clev = clevel; + + return (node); +} + +/* + * Free radix node. + */ +static __inline void +pctrie_node_put(struct pctrie *ptree, struct pctrie_node *node, + pctrie_free_t freefn) +{ +#ifdef INVARIANTS + int slot; + + KASSERT(node->pn_count == 0, + ("pctrie_node_put: node %p has %d children", node, + node->pn_count)); + for (slot = 0; slot < PCTRIE_COUNT; slot++) + KASSERT(node->pn_child[slot] == NULL, + ("pctrie_node_put: node %p has a child", node)); +#endif + freefn(ptree, node); +} + +/* + * Return the position in the array for a given level. + */ +static __inline int +pctrie_slot(uint64_t index, uint16_t level) +{ + + return ((index >> (level * PCTRIE_WIDTH)) & PCTRIE_MASK); +} + +/* Trims the key after the specified level. */ +static __inline uint64_t +pctrie_trimkey(uint64_t index, uint16_t level) +{ + uint64_t ret; + + ret = index; + if (level > 0) { + ret >>= level * PCTRIE_WIDTH; + ret <<= level * PCTRIE_WIDTH; + } + return (ret); +} + +/* + * Get the root node for a tree. + */ +static __inline struct pctrie_node * +pctrie_getroot(struct pctrie *ptree) +{ + + return ((struct pctrie_node *)ptree->pt_root); +} + +/* + * Set the root node for a tree. + */ +static __inline void +pctrie_setroot(struct pctrie *ptree, struct pctrie_node *node) +{ + + ptree->pt_root = (uintptr_t)node; +} + +/* + * Returns TRUE if the specified node is a leaf and FALSE otherwise. + */ +static __inline boolean_t +pctrie_isleaf(struct pctrie_node *node) +{ + + return (((uintptr_t)node & PCTRIE_ISLEAF) != 0); +} + +/* + * Returns the associated val extracted from node. + */ +static __inline uint64_t * +pctrie_toval(struct pctrie_node *node) +{ + + return ((uint64_t *)((uintptr_t)node & ~PCTRIE_FLAGS)); +} + +/* + * Adds the val as a child of the provided node. + */ +static __inline void +pctrie_addval(struct pctrie_node *node, uint64_t index, uint16_t clev, + uint64_t *val) +{ + int slot; + + slot = pctrie_slot(index, clev); + node->pn_child[slot] = (void *)((uintptr_t)val | PCTRIE_ISLEAF); +} + +/* + * Returns the slot where two keys differ. + * It cannot accept 2 equal keys. + */ +static __inline uint16_t +pctrie_keydiff(uint64_t index1, uint64_t index2) +{ + uint16_t clev; + + KASSERT(index1 != index2, ("%s: passing the same key value %jx", + __func__, (uintmax_t)index1)); + + index1 ^= index2; + for (clev = PCTRIE_LIMIT;; clev--) + if (pctrie_slot(index1, clev) != 0) + return (clev); +} + +/* + * Returns TRUE if it can be determined that key does not belong to the + * specified node. Otherwise, returns FALSE. + */ +static __inline boolean_t +pctrie_keybarr(struct pctrie_node *node, uint64_t idx) +{ + + if (node->pn_clev < PCTRIE_LIMIT) { + idx = pctrie_trimkey(idx, node->pn_clev + 1); + return (idx != node->pn_owner); + } + return (FALSE); +} + +/* + * Internal helper for pctrie_reclaim_allnodes(). + * This function is recursive. + */ +static void +pctrie_reclaim_allnodes_int(struct pctrie *ptree, struct pctrie_node *node, + pctrie_free_t freefn) +{ + int slot; + + KASSERT(node->pn_count <= PCTRIE_COUNT, + ("pctrie_reclaim_allnodes_int: bad count in node %p", node)); + for (slot = 0; node->pn_count != 0; slot++) { + if (node->pn_child[slot] == NULL) + continue; + if (!pctrie_isleaf(node->pn_child[slot])) + pctrie_reclaim_allnodes_int(ptree, + node->pn_child[slot], freefn); + node->pn_child[slot] = NULL; + node->pn_count--; + } + pctrie_node_put(ptree, node, freefn); +} + +/* + * pctrie node zone initializer. + */ +int +pctrie_zone_init(void *mem, int size __unused, int flags __unused) +{ + struct pctrie_node *node; + + node = mem; + memset(node->pn_child, 0, sizeof(node->pn_child)); + return (0); +} + +size_t +pctrie_node_size(void) +{ + + return (sizeof(struct pctrie_node)); +} + +/* + * Inserts the key-value pair into the trie. + * Panics if the key already exists. + */ +int +pctrie_insert(struct pctrie *ptree, uint64_t *val, pctrie_alloc_t allocfn) +{ + uint64_t index, newind; + void **parentp; + struct pctrie_node *node, *tmp; + uint64_t *m; + int slot; + uint16_t clev; + + index = *val; + + /* + * The owner of record for root is not really important because it + * will never be used. + */ + node = pctrie_getroot(ptree); + if (node == NULL) { + ptree->pt_root = (uintptr_t)val | PCTRIE_ISLEAF; + return (0); + } + parentp = (void **)&ptree->pt_root; + for (;;) { + if (pctrie_isleaf(node)) { + m = pctrie_toval(node); + if (*m == index) + panic("%s: key %jx is already present", + __func__, (uintmax_t)index); + clev = pctrie_keydiff(*m, index); + tmp = pctrie_node_get(ptree, allocfn, + pctrie_trimkey(index, clev + 1), 2, clev); + if (tmp == NULL) + return (ENOMEM); + *parentp = tmp; + pctrie_addval(tmp, index, clev, val); + pctrie_addval(tmp, *m, clev, m); + return (0); + } else if (pctrie_keybarr(node, index)) + break; + slot = pctrie_slot(index, node->pn_clev); + if (node->pn_child[slot] == NULL) { + node->pn_count++; + pctrie_addval(node, index, node->pn_clev, val); + return (0); + } + parentp = &node->pn_child[slot]; + node = node->pn_child[slot]; + } + + /* + * A new node is needed because the right insertion level is reached. + * Setup the new intermediate node and add the 2 children: the + * new object and the older edge. + */ + newind = node->pn_owner; + clev = pctrie_keydiff(newind, index); + tmp = pctrie_node_get(ptree, allocfn, + pctrie_trimkey(index, clev + 1), 2, clev); + if (tmp == NULL) + return (ENOMEM); + *parentp = tmp; + pctrie_addval(tmp, index, clev, val); + slot = pctrie_slot(newind, clev); + tmp->pn_child[slot] = node; + + return (0); +} + +/* + * Returns the value stored at the index. If the index is not present, + * NULL is returned. + */ +uint64_t * +pctrie_lookup(struct pctrie *ptree, uint64_t index) +{ + struct pctrie_node *node; + uint64_t *m; + int slot; + + node = pctrie_getroot(ptree); + while (node != NULL) { + if (pctrie_isleaf(node)) { + m = pctrie_toval(node); + if (*m == index) + return (m); + else + break; + } else if (pctrie_keybarr(node, index)) + break; + slot = pctrie_slot(index, node->pn_clev); + node = node->pn_child[slot]; + } + return (NULL); +} + +/* + * Look up the nearest entry at a position bigger than or equal to index. + */ +uint64_t * +pctrie_lookup_ge(struct pctrie *ptree, uint64_t index) +{ + struct pctrie_node *stack[PCTRIE_LIMIT]; + uint64_t inc; + uint64_t *m; + struct pctrie_node *child, *node; +#ifdef INVARIANTS + int loops = 0; +#endif + int slot, tos; + + node = pctrie_getroot(ptree); + if (node == NULL) + return (NULL); + else if (pctrie_isleaf(node)) { + m = pctrie_toval(node); + if (*m >= index) + return (m); + else + return (NULL); + } + tos = 0; + for (;;) { + /* + * If the keys differ before the current bisection node, + * then the search key might rollback to the earliest + * available bisection node or to the smallest key + * in the current node (if the owner is bigger than the + * search key). + */ + if (pctrie_keybarr(node, index)) { + if (index > node->pn_owner) { +ascend: + KASSERT(++loops < 1000, + ("pctrie_lookup_ge: too many loops")); + + /* + * Pop nodes from the stack until either the + * stack is empty or a node that could have a + * matching descendant is found. + */ + do { + if (tos == 0) + return (NULL); + node = stack[--tos]; + } while (pctrie_slot(index, + node->pn_clev) == (PCTRIE_COUNT - 1)); + + /* + * The following computation cannot overflow + * because index's slot at the current level + * is less than PCTRIE_COUNT - 1. + */ + index = pctrie_trimkey(index, + node->pn_clev); + index += PCTRIE_UNITLEVEL(node->pn_clev); + } else + index = node->pn_owner; + KASSERT(!pctrie_keybarr(node, index), + ("pctrie_lookup_ge: keybarr failed")); + } + slot = pctrie_slot(index, node->pn_clev); + child = node->pn_child[slot]; + if (pctrie_isleaf(child)) { + m = pctrie_toval(child); + if (*m >= index) + return (m); + } else if (child != NULL) + goto descend; + + /* + * Look for an available edge or val within the current + * bisection node. + */ + if (slot < (PCTRIE_COUNT - 1)) { + inc = PCTRIE_UNITLEVEL(node->pn_clev); + index = pctrie_trimkey(index, node->pn_clev); + do { + index += inc; + slot++; + child = node->pn_child[slot]; + if (pctrie_isleaf(child)) { + m = pctrie_toval(child); + if (*m >= index) + return (m); + } else if (child != NULL) + goto descend; + } while (slot < (PCTRIE_COUNT - 1)); + } + KASSERT(child == NULL || pctrie_isleaf(child), + ("pctrie_lookup_ge: child is radix node")); + + /* + * If a value or edge bigger than the search slot is not found + * in the current node, ascend to the next higher-level node. + */ + goto ascend; +descend: + KASSERT(node->pn_clev > 0, + ("pctrie_lookup_ge: pushing leaf's parent")); + KASSERT(tos < PCTRIE_LIMIT, + ("pctrie_lookup_ge: stack overflow")); + stack[tos++] = node; + node = child; + } +} + +/* + * Look up the nearest entry at a position less than or equal to index. + */ +uint64_t * +pctrie_lookup_le(struct pctrie *ptree, uint64_t index) +{ + struct pctrie_node *stack[PCTRIE_LIMIT]; + uint64_t inc; + uint64_t *m; + struct pctrie_node *child, *node; +#ifdef INVARIANTS + int loops = 0; +#endif + int slot, tos; + + node = pctrie_getroot(ptree); + if (node == NULL) + return (NULL); + else if (pctrie_isleaf(node)) { + m = pctrie_toval(node); + if (*m <= index) + return (m); + else + return (NULL); + } + tos = 0; + for (;;) { + /* + * If the keys differ before the current bisection node, + * then the search key might rollback to the earliest + * available bisection node or to the largest key + * in the current node (if the owner is smaller than the + * search key). + */ + if (pctrie_keybarr(node, index)) { + if (index > node->pn_owner) { + index = node->pn_owner + PCTRIE_COUNT * + PCTRIE_UNITLEVEL(node->pn_clev); + } else { +ascend: + KASSERT(++loops < 1000, + ("pctrie_lookup_le: too many loops")); + + /* + * Pop nodes from the stack until either the + * stack is empty or a node that could have a + * matching descendant is found. + */ + do { + if (tos == 0) + return (NULL); + node = stack[--tos]; + } while (pctrie_slot(index, + node->pn_clev) == 0); + + /* + * The following computation cannot overflow + * because index's slot at the current level + * is greater than 0. + */ + index = pctrie_trimkey(index, + node->pn_clev); + } + index--; + KASSERT(!pctrie_keybarr(node, index), + ("pctrie_lookup_le: keybarr failed")); + } + slot = pctrie_slot(index, node->pn_clev); + child = node->pn_child[slot]; + if (pctrie_isleaf(child)) { + m = pctrie_toval(child); + if (*m <= index) + return (m); + } else if (child != NULL) + goto descend; + + /* + * Look for an available edge or value within the current + * bisection node. + */ + if (slot > 0) { + inc = PCTRIE_UNITLEVEL(node->pn_clev); + index |= inc - 1; + do { + index -= inc; + slot--; + child = node->pn_child[slot]; + if (pctrie_isleaf(child)) { + m = pctrie_toval(child); + if (*m <= index) + return (m); + } else if (child != NULL) + goto descend; + } while (slot > 0); + } + KASSERT(child == NULL || pctrie_isleaf(child), + ("pctrie_lookup_le: child is radix node")); + + /* + * If a value or edge smaller than the search slot is not found + * in the current node, ascend to the next higher-level node. + */ + goto ascend; +descend: + KASSERT(node->pn_clev > 0, + ("pctrie_lookup_le: pushing leaf's parent")); + KASSERT(tos < PCTRIE_LIMIT, + ("pctrie_lookup_le: stack overflow")); + stack[tos++] = node; + node = child; + } +} + +/* + * Remove the specified index from the tree. + * Panics if the key is not present. + */ +void +pctrie_remove(struct pctrie *ptree, uint64_t index, pctrie_free_t freefn) +{ + struct pctrie_node *node, *parent; + uint64_t *m; + int i, slot; + + node = pctrie_getroot(ptree); + if (pctrie_isleaf(node)) { + m = pctrie_toval(node); + if (*m != index) + panic("%s: invalid key found", __func__); + pctrie_setroot(ptree, NULL); + return; + } + parent = NULL; + for (;;) { + if (node == NULL) + panic("pctrie_remove: impossible to locate the key"); + slot = pctrie_slot(index, node->pn_clev); + if (pctrie_isleaf(node->pn_child[slot])) { + m = pctrie_toval(node->pn_child[slot]); + if (*m != index) + panic("%s: invalid key found", __func__); + node->pn_child[slot] = NULL; + node->pn_count--; + if (node->pn_count > 1) + break; + for (i = 0; i < PCTRIE_COUNT; i++) + if (node->pn_child[i] != NULL) + break; + KASSERT(i != PCTRIE_COUNT, + ("%s: invalid node configuration", __func__)); + if (parent == NULL) + pctrie_setroot(ptree, node->pn_child[i]); + else { + slot = pctrie_slot(index, parent->pn_clev); + KASSERT(parent->pn_child[slot] == node, + ("%s: invalid child value", __func__)); + parent->pn_child[slot] = node->pn_child[i]; + } + node->pn_count--; + node->pn_child[i] = NULL; + pctrie_node_put(ptree, node, freefn); + break; + } + parent = node; + node = node->pn_child[slot]; + } +} + +/* + * Remove and free all the nodes from the tree. + * This function is recursive but there is a tight control on it as the + * maximum depth of the tree is fixed. + */ +void +pctrie_reclaim_allnodes(struct pctrie *ptree, pctrie_free_t freefn) +{ + struct pctrie_node *root; + + root = pctrie_getroot(ptree); + if (root == NULL) + return; + pctrie_setroot(ptree, NULL); + if (!pctrie_isleaf(root)) + pctrie_reclaim_allnodes_int(ptree, root, freefn); +} + +#ifdef DDB +/* + * Show details about the given node. + */ +DB_SHOW_COMMAND(pctrienode, db_show_pctrienode) +{ + struct pctrie_node *node; + int i; + + if (!have_addr) + return; + node = (struct pctrie_node *)addr; + db_printf("node %p, owner %jx, children count %u, level %u:\n", + (void *)node, (uintmax_t)node->pn_owner, node->pn_count, + node->pn_clev); + for (i = 0; i < PCTRIE_COUNT; i++) + if (node->pn_child[i] != NULL) + db_printf("slot: %d, val: %p, value: %p, clev: %d\n", + i, (void *)node->pn_child[i], + pctrie_isleaf(node->pn_child[i]) ? + pctrie_toval(node->pn_child[i]) : NULL, + node->pn_clev); +} +#endif /* DDB */ Modified: head/sys/kern/vfs_subr.c ============================================================================== --- head/sys/kern/vfs_subr.c Sun May 12 03:36:28 2013 (r250550) +++ head/sys/kern/vfs_subr.c Sun May 12 04:05:01 2013 (r250551) @@ -65,6 +65,7 @@ __FBSDID("$FreeBSD$"); #include #include #include +#include #include #include #include @@ -184,6 +185,8 @@ static struct mtx vnode_free_list_mtx; /* Publicly exported FS */ struct nfs_public nfs_pub; +static uma_zone_t buf_trie_zone; + /* Zone for allocation of new vnodes - used exclusively by getnewvnode() */ static uma_zone_t vnode_zone; static uma_zone_t vnodepoll_zone; @@ -284,6 +287,24 @@ SYSCTL_INT(_debug, OID_AUTO, vnlru_nowhe static int vnsz2log; /* + * Support for the bufobj clean & dirty pctrie. + */ +static void * +buf_trie_alloc(struct pctrie *ptree) +{ + + return uma_zalloc(buf_trie_zone, M_NOWAIT); +} + +static void +buf_trie_free(struct pctrie *ptree, void *node) +{ + + uma_zfree(buf_trie_zone, node); +} +PCTRIE_DEFINE(BUF, buf, b_lblkno, buf_trie_alloc, buf_trie_free); + +/* * Initialize the vnode management data structures. * * Reevaluate the following cap on the number of vnodes after the physical @@ -329,6 +350,15 @@ vntblinit(void *dummy __unused) vnodepoll_zone = uma_zcreate("VNODEPOLL", sizeof (struct vpollinfo), NULL, NULL, NULL, NULL, UMA_ALIGN_PTR, 0); /* + * Preallocate enough nodes to support one-per buf so that + * we can not fail an insert. reassignbuf() callers can not + * tolerate the insertion failure. + */ + buf_trie_zone = uma_zcreate("BUF TRIE", pctrie_node_size(), + NULL, NULL, pctrie_zone_init, NULL, UMA_ALIGN_PTR, + UMA_ZONE_NOFREE | UMA_ZONE_VM); + uma_prealloc(buf_trie_zone, nbuf); + /* * Initialize the filesystem syncer. */ syncer_workitem_pending = hashinit(syncer_maxdelay, M_VNODE, @@ -1476,75 +1506,9 @@ restartsync: return (0); } -/* - * buf_splay() - splay tree core for the clean/dirty list of buffers in - * a vnode. - * - * NOTE: We have to deal with the special case of a background bitmap - * buffer, a situation where two buffers will have the same logical - * block offset. We want (1) only the foreground buffer to be accessed - * in a lookup and (2) must differentiate between the foreground and - * background buffer in the splay tree algorithm because the splay - * tree cannot normally handle multiple entities with the same 'index'. - * We accomplish this by adding differentiating flags to the splay tree's - * numerical domain. - */ -static -struct buf * -buf_splay(daddr_t lblkno, b_xflags_t xflags, struct buf *root) -{ - struct buf dummy; - struct buf *lefttreemax, *righttreemin, *y; - - if (root == NULL) - return (NULL); - lefttreemax = righttreemin = &dummy; - for (;;) { - if (lblkno < root->b_lblkno) { - if ((y = root->b_left) == NULL) - break; - if (lblkno < y->b_lblkno) { - /* Rotate right. */ - root->b_left = y->b_right; - y->b_right = root; - root = y; - if ((y = root->b_left) == NULL) - break; - } - /* Link into the new root's right tree. */ - righttreemin->b_left = root; - righttreemin = root; - } else if (lblkno > root->b_lblkno) { - if ((y = root->b_right) == NULL) - break; - if (lblkno > y->b_lblkno) { - /* Rotate left. */ - root->b_right = y->b_left; - y->b_left = root; - root = y; - if ((y = root->b_right) == NULL) - break; - } - /* Link into the new root's left tree. */ - lefttreemax->b_right = root; - lefttreemax = root; - } else { - break; - } - root = y; - } - /* Assemble the new root. */ - lefttreemax->b_right = root->b_left; - righttreemin->b_left = root->b_right; - root->b_left = dummy.b_right; - root->b_right = dummy.b_left; - return (root); -} - static void buf_vlist_remove(struct buf *bp) { - struct buf *root; struct bufv *bv; KASSERT(bp->b_bufobj != NULL, ("No b_bufobj %p", bp)); @@ -1556,33 +1520,23 @@ buf_vlist_remove(struct buf *bp) bv = &bp->b_bufobj->bo_dirty; else bv = &bp->b_bufobj->bo_clean; - if (bp != bv->bv_root) { - root = buf_splay(bp->b_lblkno, bp->b_xflags, bv->bv_root); - KASSERT(root == bp, ("splay lookup failed in remove")); - } - if (bp->b_left == NULL) { - root = bp->b_right; - } else { - root = buf_splay(bp->b_lblkno, bp->b_xflags, bp->b_left); - root->b_right = bp->b_right; - } - bv->bv_root = root; + BUF_PCTRIE_REMOVE(&bv->bv_root, bp->b_lblkno); TAILQ_REMOVE(&bv->bv_hd, bp, b_bobufs); bv->bv_cnt--; bp->b_xflags &= ~(BX_VNDIRTY | BX_VNCLEAN); } /* - * Add the buffer to the sorted clean or dirty block list using a - * splay tree algorithm. + * Add the buffer to the sorted clean or dirty block list. * * NOTE: xflags is passed as a constant, optimizing this inline function! */ static void buf_vlist_add(struct buf *bp, struct bufobj *bo, b_xflags_t xflags) { - struct buf *root; struct bufv *bv; + struct buf *n; + int error; ASSERT_BO_LOCKED(bo); KASSERT((bp->b_xflags & (BX_VNDIRTY|BX_VNCLEAN)) == 0, @@ -1593,24 +1547,22 @@ buf_vlist_add(struct buf *bp, struct buf else bv = &bo->bo_clean; - root = buf_splay(bp->b_lblkno, bp->b_xflags, bv->bv_root); - if (root == NULL) { - bp->b_left = NULL; - bp->b_right = NULL; + /* + * Keep the list ordered. Optimize empty list insertion. Assume + * we tend to grow at the tail so lookup_le should usually be cheaper + * than _ge. + */ + if (bv->bv_cnt == 0 || + bp->b_lblkno > TAILQ_LAST(&bv->bv_hd, buflists)->b_lblkno) TAILQ_INSERT_TAIL(&bv->bv_hd, bp, b_bobufs); - } else if (bp->b_lblkno < root->b_lblkno) { - bp->b_left = root->b_left; - bp->b_right = root; - root->b_left = NULL; - TAILQ_INSERT_BEFORE(root, bp, b_bobufs); - } else { - bp->b_right = root->b_right; - bp->b_left = root; - root->b_right = NULL; - TAILQ_INSERT_AFTER(&bv->bv_hd, root, bp, b_bobufs); - } + else if ((n = BUF_PCTRIE_LOOKUP_LE(&bv->bv_root, bp->b_lblkno)) == NULL) + TAILQ_INSERT_HEAD(&bv->bv_hd, bp, b_bobufs); + else + TAILQ_INSERT_AFTER(&bv->bv_hd, n, bp, b_bobufs); + error = BUF_PCTRIE_INSERT(&bv->bv_root, bp); + if (error) + panic("buf_vlist_add: Preallocated nodes insufficient."); bv->bv_cnt++; - bv->bv_root = bp; } /* @@ -1631,21 +1583,10 @@ gbincore(struct bufobj *bo, daddr_t lblk struct buf *bp; ASSERT_BO_LOCKED(bo); - if ((bp = bo->bo_clean.bv_root) != NULL && bp->b_lblkno == lblkno) + bp = BUF_PCTRIE_LOOKUP(&bo->bo_clean.bv_root, lblkno); + if (bp != NULL) return (bp); - if ((bp = bo->bo_dirty.bv_root) != NULL && bp->b_lblkno == lblkno) - return (bp); - if ((bp = bo->bo_clean.bv_root) != NULL) { - bo->bo_clean.bv_root = bp = buf_splay(lblkno, 0, bp); - if (bp->b_lblkno == lblkno) - return (bp); - } - if ((bp = bo->bo_dirty.bv_root) != NULL) { - bo->bo_dirty.bv_root = bp = buf_splay(lblkno, 0, bp); - if (bp->b_lblkno == lblkno) - return (bp); - } - return (NULL); + return BUF_PCTRIE_LOOKUP(&bo->bo_dirty.bv_root, lblkno); } /* @@ -2460,9 +2401,11 @@ vdropl(struct vnode *vp) VNASSERT(vp->v_writecount == 0, vp, ("Non-zero write count")); VNASSERT(bo->bo_numoutput == 0, vp, ("Clean vnode has pending I/O's")); VNASSERT(bo->bo_clean.bv_cnt == 0, vp, ("cleanbufcnt not 0")); - VNASSERT(bo->bo_clean.bv_root == NULL, vp, ("cleanblkroot not NULL")); + VNASSERT(pctrie_is_empty(&bo->bo_clean.bv_root), vp, + ("clean blk trie not empty")); VNASSERT(bo->bo_dirty.bv_cnt == 0, vp, ("dirtybufcnt not 0")); - VNASSERT(bo->bo_dirty.bv_root == NULL, vp, ("dirtyblkroot not NULL")); + VNASSERT(pctrie_is_empty(&bo->bo_dirty.bv_root), vp, + ("dirty blk trie not empty")); VNASSERT(TAILQ_EMPTY(&vp->v_cache_dst), vp, ("vp has namecache dst")); VNASSERT(LIST_EMPTY(&vp->v_cache_src), vp, ("vp has namecache src")); VNASSERT(vp->v_cache_dd == NULL, vp, ("vp has namecache for ..")); Copied and modified: head/sys/sys/_pctrie.h (from r249323, head/sys/vm/_vm_radix.h) ============================================================================== --- head/sys/vm/_vm_radix.h Wed Apr 10 02:40:03 2013 (r249323, copy source) +++ head/sys/sys/_pctrie.h Sun May 12 04:05:01 2013 (r250551) @@ -28,24 +28,24 @@ * $FreeBSD$ */ -#ifndef __VM_RADIX_H_ -#define __VM_RADIX_H_ +#ifndef __SYS_PCTRIE_H_ +#define __SYS_PCTRIE_H_ /* * Radix tree root. */ -struct vm_radix { - uintptr_t rt_root; +struct pctrie { + uintptr_t pt_root; }; #ifdef _KERNEL static __inline boolean_t -vm_radix_is_empty(struct vm_radix *rtree) +pctrie_is_empty(struct pctrie *ptree) { - return (rtree->rt_root == 0); + return (ptree->pt_root == 0); } *** DIFF OUTPUT TRUNCATED AT 1000 LINES *** From owner-svn-src-all@FreeBSD.ORG Sun May 12 04:09:03 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id 77D61D8; Sun, 12 May 2013 04:09:03 +0000 (UTC) (envelope-from brde@optusnet.com.au) Received: from fallbackmx08.syd.optusnet.com.au (fallbackmx08.syd.optusnet.com.au [211.29.132.10]) by mx1.freebsd.org (Postfix) with ESMTP id F22E69D1; Sun, 12 May 2013 04:09:02 +0000 (UTC) Received: from mail03.syd.optusnet.com.au (mail03.syd.optusnet.com.au [211.29.132.184]) by fallbackmx08.syd.optusnet.com.au (8.13.1/8.13.1) with ESMTP id r4C429Sw021801; Sun, 12 May 2013 14:02:09 +1000 Received: from etaplex.bde.org ([139.218.225.48]) (authenticated sender brde) by mail03.syd.optusnet.com.au (8.13.1/8.13.1) with ESMTP id r4C41oSB023559 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO); Sun, 12 May 2013 14:02:01 +1000 Date: Sun, 12 May 2013 14:01:58 +1000 (EST) From: Bruce Evans X-X-Sender: bde@etaplex.bde.org To: John Baldwin Subject: Re: svn commit: r250220 - head/sys/kern In-Reply-To: <201305101142.32086.jhb@freebsd.org> Message-ID: <20130512140150.E646@etaplex.bde.org> References: <201305031908.r43J8xnI094418@svn.freebsd.org> <201305061355.20826.jhb@freebsd.org> <20130510123842.B637@etaplex.bde.org> <201305101142.32086.jhb@freebsd.org> MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII; format=flowed X-Optus-CM-Score: 0 X-Optus-CM-Analysis: v=2.0 cv=BPvrNysG c=1 sm=1 a=5CeyE4nVUmB46QZCKVgZLQ==:17 a=8aH1kwsY6JcA:10 a=kj9zAlcOel0A:10 a=PO7r1zJSAAAA:8 a=JzwRw_2MAAAA:8 a=M4roAWbnUW4A:10 a=Ec_1SRHOmNCRhhinIKgA:9 a=CjuIK1q_8ugA:10 a=5CeyE4nVUmB46QZCKVgZLQ==:117 Cc: svn-src-head@freebsd.org, svn-src-all@freebsd.org, Bruce Evans X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 12 May 2013 04:09:03 -0000 On Fri, 10 May 2013, John Baldwin wrote: > On Thursday, May 09, 2013 11:05:46 pm Bruce Evans wrote: >> On Mon, 6 May 2013, John Baldwin wrote: >> ... >>> static int >>> vn_ioctl(fp, com, data, active_cred, td) >>> struct file *fp; >>> u_long com; >>> void *data; >>> struct ucred *active_cred; >>> struct thread *td; >>> { >>> struct vnode *vp = fp->f_vnode; >>> struct vattr vattr; >>> >>> switch (vp->v_type) { >>> case VREG: >>> case VDIR: >>> switch (com) { >>> case FIONREAD: >>> vn_lock(vp, LK_SHARED | LK_RETRY); >>> error = VOP_GETATTR(vp, &vattr, active_cred); >>> VOP_UNLOCK(vp, 0); >>> if (!error) >>> *(int *)data = vattr.va_size - fp->f_offset; >>> return (error); >>> case FIONBIO: >>> case FIOASYNC: >>> return (0); /* XXX */ >>> default: >>> return (VOP_IOCTL(vp, com, data, fp->f_flag, >>> active_cred, td)); >>> } >>> default: >>> return (ENOTTY); >>> } >>> } > ... >>> (The 'XXX' comment could perhaps be expanded to something along the lines of >>> 'Allow fcntl() to toggle FNONBLOCK and FASYNC.') >> >> Is that what it is about? IIRC, upper layers do some partial handling >> and then call lower layers to possibly do some more handling. But here >> and in some other places there is nothing more to be done. No comment >> is needed, but maybe the XXX's were reminders to clean up the layering. >> FreeBSD has cleaned up the layering a bit, by using differnt fops for >> different file types. > > The problem is this code in fcntl() which I ran into when working on a > tutorial for writing character devices: > > case F_SETFL: > error = fget_unlocked(fdp, fd, CAP_FCNTL, F_SETFL, &fp, NULL); > if (error != 0) > break; > do { > tmp = flg = fp->f_flag; > tmp &= ~FCNTLFLAGS; > tmp |= FFLAGS(arg & ~O_ACCMODE) & FCNTLFLAGS; > } while(atomic_cmpset_int(&fp->f_flag, flg, tmp) == 0); > tmp = fp->f_flag & FNONBLOCK; > error = fo_ioctl(fp, FIONBIO, &tmp, td->td_ucred, td); > if (error != 0) { > fdrop(fp, td); > break; > } > tmp = fp->f_flag & FASYNC; > error = fo_ioctl(fp, FIOASYNC, &tmp, td->td_ucred, td); > if (error == 0) { > fdrop(fp, td); > break; > } > atomic_clear_int(&fp->f_flag, FNONBLOCK); > tmp = 0; > (void)fo_ioctl(fp, FIONBIO, &tmp, td->td_ucred, td); > fdrop(fp, td); > break; > > Hmm, this seems to have the bug that if you had FNONBLOCK set and > tried to set FASYNC via fcntl() but FIOASYNC isn't supported, > FNONBLOCK is cleared. It seems we should only clear FNONBLOCK > if it wasn't set in 'flg'. I think this would fix that: sys_socket.c mishandles this differently by voiding the result of all fo_ioctls(). The above only assumes that since the first fo_ioctl() for FIONBIO succeeded, the second one will too. I now remember more about this bad code: - it is still very broken for devices. ioctls are inherently per-device, but file flags aren't even per-file -- they are per-file-descriptor -- so the device state becomes inconsistent with the file descriptor state if more than 1 fd is open on a device and any non-null change of the file flags is made using one of the fd's (applications might be able to keep the file flags fairly consistent by doing fcntl for all the fd's (including ones shared across processes), but the file flags would be at least transiently inconsistent. Only the FNONBLOCK (O_NONBLOCK) and FASYNC (O_ASYNC) flags are passed down. O_NONBLOCK works right for some devices because it is also passed to open() and read()/write() (so it will work right for ioctl() if the device driver ignores it then). There are related not so bad cases for F_GETFL, F_GETOWN and F_SETOWN. F_GETFL returns per-fd flags. There are no per-fd ownerships, so F_GETOWN has to use an ioctl to fetch a non-per-fd ownership (the one set by F_SETOWN) which is at least consistently not per-fd. Most drivers/file types are actually non-broken for FIONBIO and do nothing except return 0 for it (I only grepped for FIONBIO; not for O_NONBLOCK or FNONBLOCK). This return is sometimes XXX'ed, but it really shouldn't be. Returning 0 and not doing anything means that the driver supports O_NONBLOCK correctly (by checking it per-fd in the flag passed to open() and read/write()). It is the drivers that do something which deserve an XXX. The only broken ioctl routines for FIONBIO are now: - subr_bus.c: devioctl() - sys_socket.c: soo_ioctl() - pcm/dsp.c: dsp_ioctl() - audit/audit_pipe.c: audit_pipe_ioctl() - cbus/fdc.c: fdioctl(). This is different from fdc/fdc.c. The latter just returns 0 and claims that this is for backwards compatibility with old utilities. Apparently the pc98 version hasn't been moved to userland as much as the pc98 version. But the comment is wrong, since old utilities are just broken since they depend on kernel features that were removed. IIRC, not much more than soo_ioctl() had this bug in 4.4BSD, except F_SETOWN as more complicated and broken (but not supported for as many devices/file types). truckman@ did a lot of work to fix F_SETOWN and assoicated signal handling. > Index: kern_descrip.c > =================================================================== > --- kern_descrip.c (revision 250451) > +++ kern_descrip.c (working copy) > @@ -539,7 +539,7 @@ kern_fcntl(struct thread *td, int fd, int cmd, int > } > tmp = fp->f_flag & FASYNC; > error = fo_ioctl(fp, FIOASYNC, &tmp, td->td_ucred, td); > - if (error == 0) { > + if (error == 0 || (flg & FNONBLOCK)) { > fdrop(fp, td); > break; > } > > This would mean you would no longer have to support the FIOASYNC > ioctl just to allow FIONBLOCK to be set. Looks good, but... > Note, btw, that kern_ioctl() doesn't enforce quite the same > requirement as F_SETFL in that FIONBIO doesn't check for FASYNC and vice > versa. ioctl() also doesn't revert the change if the backing fo_ioctl > method fails. ... it's bogus to back out of just the FIONBIO setting. Other flags changes (to O_APPEND and O_DIRECT) are not backed out of. Apparently the idea in fcntl was to back out of all changes. This may have even worked before O_APPEND was supported. O_DIRECT didn't exist until later. ioctl() is too complicated to have ever attempted this. This causes problems for applications programming: I don't know what the spec for fcntl() or ioctl() says, but for tcsetattr() (which is implemented using ioctl() in FreeBSD), POSIX says that the syscall shall (?) succeed if at least one attribute was "set" (changed?). So when you ask tcsetattr() to change lots of attributes, the only correct way to determine if it succeeded is to call tcgetattr() and check that all the changes that you care about actually occurred). > I actually think that fcntl should probably ignore ENOTTY errors > if the flag is not set. Otherwise using fcntl to toggle some other > flag can succeed but still return an error. I think ENOTTY errors for FIONBIO are rare, since too many places copy the code that returns 0 for FIONBIO even when O_NONBLOCK is not supported. E.g., the non-pc98 fdc driver doesn't support O_NONBLOCK, but it has a compatibiity excuse for claiming support. I think fo_ioctl() shouldn't be called for null changes (especially from the unset case to the unset case). Calling it should fail quite often and thus give ENOTTY even for callers that have no interest in FNONBLOCK or FASYNC but want to toggle some other changes. However, always calling it minimises the inconsistencies for drivers(...) that act on it -- this syncs the driver state with the fd state from the last fcntl() on the set of fd's referencing the device, irrespective of whether the current fcntl() is toggling the state. Bruce From owner-svn-src-all@FreeBSD.ORG Sun May 12 04:24:25 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id B95661BA; Sun, 12 May 2013 04:24:25 +0000 (UTC) (envelope-from kib@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id AC81FA0B; Sun, 12 May 2013 04:24:25 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.6/8.14.6) with ESMTP id r4C4OPYB025251; Sun, 12 May 2013 04:24:25 GMT (envelope-from kib@svn.freebsd.org) Received: (from kib@localhost) by svn.freebsd.org (8.14.6/8.14.5/Submit) id r4C4OPWH025250; Sun, 12 May 2013 04:24:25 GMT (envelope-from kib@svn.freebsd.org) Message-Id: <201305120424.r4C4OPWH025250@svn.freebsd.org> From: Konstantin Belousov Date: Sun, 12 May 2013 04:24:25 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org Subject: svn commit: r250552 - stable/9/sys/amd64/amd64 X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 12 May 2013 04:24:25 -0000 Author: kib Date: Sun May 12 04:24:25 2013 New Revision: 250552 URL: http://svnweb.freebsd.org/changeset/base/250552 Log: MFC r250415: Correct the type for the literal used on the left side of the shift up to 63 bit positions. Do not fill the save area and do not set the saved bit in the xstate bit vector for the state which is not marked as enabled in xsave_mask. Modified: stable/9/sys/amd64/amd64/fpu.c Directory Properties: stable/9/sys/ (props changed) Modified: stable/9/sys/amd64/amd64/fpu.c ============================================================================== --- stable/9/sys/amd64/amd64/fpu.c Sun May 12 04:05:01 2013 (r250551) +++ stable/9/sys/amd64/amd64/fpu.c Sun May 12 04:24:25 2013 (r250552) @@ -687,8 +687,8 @@ fpugetregs(struct thread *td) offsetof(struct xstate_hdr, xstate_bv)); max_ext_n = flsl(xsave_mask); for (i = 0; i < max_ext_n; i++) { - bit = 1 << i; - if ((*xstate_bv & bit) != 0) + bit = 1ULL << i; + if ((xsave_mask & bit) == 0 || (*xstate_bv & bit) != 0) continue; bcopy((char *)fpu_initialstate + xsave_area_desc[i].offset, From owner-svn-src-all@FreeBSD.ORG Sun May 12 04:34:55 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id CE8F9463; Sun, 12 May 2013 04:34:55 +0000 (UTC) (envelope-from eadler@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id C0805A40; Sun, 12 May 2013 04:34:55 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.6/8.14.6) with ESMTP id r4C4YtYW028718; Sun, 12 May 2013 04:34:55 GMT (envelope-from eadler@svn.freebsd.org) Received: (from eadler@localhost) by svn.freebsd.org (8.14.6/8.14.5/Submit) id r4C4YtVa028717; Sun, 12 May 2013 04:34:55 GMT (envelope-from eadler@svn.freebsd.org) Message-Id: <201305120434.r4C4YtVa028717@svn.freebsd.org> From: Eitan Adler Date: Sun, 12 May 2013 04:34:55 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r250553 - head/share/syscons/fonts X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 12 May 2013 04:34:55 -0000 Author: eadler Date: Sun May 12 04:34:55 2013 New Revision: 250553 URL: http://svnweb.freebsd.org/changeset/base/250553 Log: Add the letter 'x' to the font iso05-8x16.fnt PR: 169797 Submitted by: Takefu MFC after: 3 days Modified: head/share/syscons/fonts/iso04-wide-8x16.fnt Modified: head/share/syscons/fonts/iso04-wide-8x16.fnt ============================================================================== --- head/share/syscons/fonts/iso04-wide-8x16.fnt Sun May 12 04:24:25 2013 (r250552) +++ head/share/syscons/fonts/iso04-wide-8x16.fnt Sun May 12 04:34:55 2013 (r250553) @@ -42,7 +42,7 @@ MS'@``.!@8&!F9FQX;&9FY@`````X&!@8&!@8&!@ MP\/#``````````#<9F9F9F9F9@``````````?,;&QL;&QGP``````````-YC M8V-C8V-^8/````````![QL;&QL;&?@8/````````WG-C8&!@8/`````````` M`'S&P'` Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id 97322F32; Sun, 12 May 2013 05:54:58 +0000 (UTC) (envelope-from pluknet@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id 886B4C2B; Sun, 12 May 2013 05:54:58 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.6/8.14.6) with ESMTP id r4C5sw9J056121; Sun, 12 May 2013 05:54:58 GMT (envelope-from pluknet@svn.freebsd.org) Received: (from pluknet@localhost) by svn.freebsd.org (8.14.6/8.14.5/Submit) id r4C5swKv056120; Sun, 12 May 2013 05:54:58 GMT (envelope-from pluknet@svn.freebsd.org) Message-Id: <201305120554.r4C5swKv056120@svn.freebsd.org> From: Sergey Kandaurov Date: Sun, 12 May 2013 05:54:58 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r250554 - head/lib/libc/gen X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 12 May 2013 05:54:58 -0000 Author: pluknet Date: Sun May 12 05:54:58 2013 New Revision: 250554 URL: http://svnweb.freebsd.org/changeset/base/250554 Log: Typo. Modified: head/lib/libc/gen/posix_spawn_file_actions_addopen.3 Modified: head/lib/libc/gen/posix_spawn_file_actions_addopen.3 ============================================================================== --- head/lib/libc/gen/posix_spawn_file_actions_addopen.3 Sun May 12 04:34:55 2013 (r250553) +++ head/lib/libc/gen/posix_spawn_file_actions_addopen.3 Sun May 12 05:54:58 2013 (r250554) @@ -190,7 +190,7 @@ is equal to .Fa newfildes (clearing .Dv FD_CLOEXEC ) . -A future update of the Standard is expected to require this behavior, +A future update of the Standard is expected to require this behavior. .Sh HISTORY The .Fn posix_spawn_file_actions_addopen , From owner-svn-src-all@FreeBSD.ORG Sun May 12 06:09:39 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id E50912A2; Sun, 12 May 2013 06:09:39 +0000 (UTC) (envelope-from bright@mu.org) Received: from elvis.mu.org (elvis.mu.org [192.203.228.196]) by mx1.freebsd.org (Postfix) with ESMTP id 7441FCDC; Sun, 12 May 2013 06:09:39 +0000 (UTC) Received: from Alfreds-MacBook-Pro-9.local (c-67-180-208-218.hsd1.ca.comcast.net [67.180.208.218]) by elvis.mu.org (Postfix) with ESMTPSA id E4C2B1A3C80; Sat, 11 May 2013 23:09:36 -0700 (PDT) Message-ID: <518F320D.3070304@mu.org> Date: Sat, 11 May 2013 23:09:17 -0700 From: Alfred Perlstein User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.7; rv:17.0) Gecko/20130328 Thunderbird/17.0.5 MIME-Version: 1.0 To: Jeff Roberson Subject: Re: svn commit: r250411 - in head/sys: conf kern sys References: <201305091628.r49GSI33039873@svn.freebsd.org> In-Reply-To: Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Cc: Marcel Moolenaar , jhb@freebsd.org, svn-src-all@freebsd.org, alfred@freebsd.org, attilio@freebsd.org, src-committers@freebsd.org, svn-src-head@freebsd.org X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 12 May 2013 06:09:40 -0000 Can we just admit to ourselves that tweaks to debugging macros/printing and WITNESS are our kernel developer's "bikeshed zone" and get over the fact that people's needs may diverge and changing non-default behavior in non-critical paths is not going to be the death of the kernel as we know it? I could certainly believe that this sort of thing needs long and thorough discussion if it wasn't the equivalent of style tweaks to manpages. Let's leave the long and lengthy discussions to things that matter such as standards compliance, ABI, API and really cool performance and stability stuff. -Alfred On 5/11/13 5:43 PM, Jeff Roberson wrote: > On Thu, 9 May 2013, Marcel Moolenaar wrote: > >> Author: marcel >> Date: Thu May 9 16:28:18 2013 >> New Revision: 250411 >> URL: http://svnweb.freebsd.org/changeset/base/250411 >> >> Log: >> Add option WITNESS_NO_VNODE to suppress printing LORs between VNODE >> locks. To support this, VNODE locks are created with the LK_IS_VNODE >> flag. This flag is propagated down using the LO_IS_VNODE flag. >> >> Note that WITNESS still records the LOR. Only the printing and the >> optional entering into the kernel debugger is bypassed with the >> WITNESS_NO_VNODE option. > > I'm replying to the original commit because the resulting thread got > way out of hand. We need to all take a deep breath and take a > pragmatic approach to solving the problem at hand. > > Let me first say I understand the utility here as this is also coming > up in my organization. Test, and users, do not want to see erroneous > warning messages. I understand that. Let's find a solution. > > Secondly, I think this project has grown too far for us to commit > changes like this without some focused discussion. We need to be more > mindful of the size of the impact and the number of people who are > interested in a particular area. I'm not picking on you Marcel > because this sort of thing has been coming up lately and we have all > been guilty of it from time to time. There are more companies and > individuals than ever trying to push work into the repository and > we're having some growing pains. > > I am intimately familiar with the problems that lead to these > erroneous witness messages as I have tracked down many of them and am > even responsible for the code that generates them in some cases. Let > me first outline a handful of generic problems. The root cause is > that witness can not determine the real order between two locks due to > relationships too complex to describe with a pair of strings. > > One example, which has been brought up, is the hierarchical nature of > vnode locks. This impacts vnodes within one filesystem but it also > involves vnodes between two different filesystems as you cross mount > points. We can construct perfectly valid and deadlock free chains of > mount points that have two different filesystem types in different > orders which will LOR at the boundaries. We already skip duplicates > to avoid this problem within each filesystem. We need to skip > cross-filesystem duplicates, most desirably at the few specific places > where this happens. This problem comes up especially for devfs because > we lock devvps while file vnodes are locked but we lock devfs > directories after the rootfs lock when crossing mountpoints in lookup. > > A second example, is locks of a fundamentally different type that have > a complex ordering relationship. For example, a vnode lock may be > acquired after a buf lock belonging to the parent's directory block. > A cg buf lock may be acquired after any file buf lock. Here we want > to ignore interactions between these two specific types at this > particular location but not others as they may be unsafe. > > The third example, is a complex locking pattern with shared locks as > presented by dirhash. We are seeing a similar pattern develop in the > vm where we are going to use an exclusive object lock to protect pages > or a shared object lock + a page lock. The semantics only get more > complex as we push for more scalability. I expect to see more of these > patterns develop. > > None of these problems can be solved with names alone. So far we've > just lived with the warnings and we're no longer willing to accept > that. What we need is a solution that blesses the specific instances > and the specific lock classes involved without silencing legitimate > warnings that may only occur after new code is added. For example, it > may be safe to add a sx lock around some vnode code but you may not > notice that you LOR if you silence all witness warnings related to the > vnode lock site. > > I believe that the perfect solution would be a mechanism that could > teach witness about and enforce these specific relationships. > However, that may be computationally prohibitive and too complex to > code. A more reasonable option would be to bless the specific > relationships at the specific call sites. Turning all witness off at > particular sites or with particular types renders important > infrastructure useless for very large functional areas. It's also > important to distinguish between squelching the error message from > eliminating the other state that is saved at lock sites. > > We already have lock names and types. What I would propose we do is > make the type 'vnode' for all vnodes and 'buf' for all bufs with the > names used for the specific filesystems. Then you could specify a > DUPOK that automatically blesses any filesystem to filesystem related > LORs. In this way witness still records the call sites and unrelated > LORs or panics still have the acquisition information. You could > eventually unwind this to only DUPOK at the specific currently known > places that we anticipate multiple vnodes. > > To solve the buf and other complex LORs involving multiple types you > would make lock variants that accept a blessed list of the specific > locks you are blessing. We already have support for a blessed list in > witness. We just want something like this per-call. > > For example; When acquiring a child vnode lock after a parent lock > when a parent's buf is held I would do something like this: > > vn_lock_flags(vp, LK_EXCLUSIVE, { "vnode", "bufwait", NULL }); > > Written properly dead code elimination will take care of it for > non-debug builds. You could come up with other ways of writing this > that don't involve passing pointers down the stack. For example, > making a unique token for this blessed pair and passing it in the high > bits of the flags. I don't really care about the particular > implementation but I think this is the right model. > > Thanks, > Jeff > >> >> Modified: >> head/sys/conf/options >> head/sys/kern/kern_lock.c >> head/sys/kern/subr_witness.c >> head/sys/kern/vfs_subr.c >> head/sys/sys/lock.h >> head/sys/sys/lockmgr.h >> >> Modified: head/sys/conf/options >> ============================================================================== >> >> --- head/sys/conf/options Thu May 9 16:09:39 2013 (r250410) >> +++ head/sys/conf/options Thu May 9 16:28:18 2013 (r250411) >> @@ -672,6 +672,7 @@ KTR_ENTRIES opt_global.h >> KTR_VERBOSE opt_ktr.h >> WITNESS opt_global.h >> WITNESS_KDB opt_witness.h >> +WITNESS_NO_VNODE opt_witness.h >> WITNESS_SKIPSPIN opt_witness.h >> >> # options for ACPI support >> >> Modified: head/sys/kern/kern_lock.c >> ============================================================================== >> >> --- head/sys/kern/kern_lock.c Thu May 9 16:09:39 2013 (r250410) >> +++ head/sys/kern/kern_lock.c Thu May 9 16:28:18 2013 (r250411) >> @@ -393,6 +393,8 @@ lockinit(struct lock *lk, int pri, const >> iflags |= LO_WITNESS; >> if (flags & LK_QUIET) >> iflags |= LO_QUIET; >> + if (flags & LK_IS_VNODE) >> + iflags |= LO_IS_VNODE; >> iflags |= flags & (LK_ADAPTIVE | LK_NOSHARE); >> >> lk->lk_lock = LK_UNLOCKED; >> >> Modified: head/sys/kern/subr_witness.c >> ============================================================================== >> >> --- head/sys/kern/subr_witness.c Thu May 9 16:09:39 2013 (r250410) >> +++ head/sys/kern/subr_witness.c Thu May 9 16:28:18 2013 (r250411) >> @@ -1289,7 +1289,19 @@ witness_checkorder(struct lock_object *l >> w->w_reversed = w1->w_reversed = 1; >> witness_increment_graph_generation(); >> mtx_unlock_spin(&w_mtx); >> - >> + >> +#ifdef WITNESS_NO_VNODE >> + /* >> + * There are known LORs between VNODE locks. They are >> + * not an indication of a bug. VNODE locks are flagged >> + * as such (LO_IS_VNODE) and we don't yell if the LOR >> + * is between 2 VNODE locks. >> + */ >> + if ((lock->lo_flags & LO_IS_VNODE) != 0 && >> + (lock1->li_lock->lo_flags & LO_IS_VNODE) != 0) >> + return; >> +#endif >> + >> /* >> * Ok, yell about it. >> */ >> >> Modified: head/sys/kern/vfs_subr.c >> ============================================================================== >> >> --- head/sys/kern/vfs_subr.c Thu May 9 16:09:39 2013 (r250410) >> +++ head/sys/kern/vfs_subr.c Thu May 9 16:28:18 2013 (r250411) >> @@ -1037,7 +1037,7 @@ alloc: >> * By default, don't allow shared locks unless filesystems >> * opt-in. >> */ >> - lockinit(vp->v_vnlock, PVFS, tag, VLKTIMEOUT, LK_NOSHARE); >> + lockinit(vp->v_vnlock, PVFS, tag, VLKTIMEOUT, LK_NOSHARE | >> LK_IS_VNODE); >> /* >> * Initialize bufobj. >> */ >> >> Modified: head/sys/sys/lock.h >> ============================================================================== >> >> --- head/sys/sys/lock.h Thu May 9 16:09:39 2013 (r250410) >> +++ head/sys/sys/lock.h Thu May 9 16:28:18 2013 (r250411) >> @@ -79,6 +79,7 @@ struct lock_class { >> #define LO_SLEEPABLE 0x00100000 /* Lock may be held while >> sleeping. */ >> #define LO_UPGRADABLE 0x00200000 /* Lock may be >> upgraded/downgraded. */ >> #define LO_DUPOK 0x00400000 /* Don't check for duplicate >> acquires */ >> +#define LO_IS_VNODE 0x00800000 /* Tell WITNESS about a >> VNODE lock */ >> #define LO_CLASSMASK 0x0f000000 /* Class index bitmask. */ >> #define LO_NOPROFILE 0x10000000 /* Don't profile this lock */ >> >> >> Modified: head/sys/sys/lockmgr.h >> ============================================================================== >> >> --- head/sys/sys/lockmgr.h Thu May 9 16:09:39 2013 (r250410) >> +++ head/sys/sys/lockmgr.h Thu May 9 16:28:18 2013 (r250411) >> @@ -146,6 +146,7 @@ _lockmgr_args_rw(struct lock *lk, u_int >> #define LK_NOWITNESS 0x000010 >> #define LK_QUIET 0x000020 >> #define LK_ADAPTIVE 0x000040 >> +#define LK_IS_VNODE 0x000080 /* Tell WITNESS about a VNODE >> lock */ >> >> /* >> * Additional attributes to be used in lockmgr(). >> > From owner-svn-src-all@FreeBSD.ORG Sun May 12 09:33:34 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id 579F856E; Sun, 12 May 2013 09:33:34 +0000 (UTC) (envelope-from mav@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id 4A3EF260; Sun, 12 May 2013 09:33:34 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.6/8.14.6) with ESMTP id r4C9XYh5032544; Sun, 12 May 2013 09:33:34 GMT (envelope-from mav@svn.freebsd.org) Received: (from mav@localhost) by svn.freebsd.org (8.14.6/8.14.5/Submit) id r4C9XYGe032543; Sun, 12 May 2013 09:33:34 GMT (envelope-from mav@svn.freebsd.org) Message-Id: <201305120933.r4C9XYGe032543@svn.freebsd.org> From: Alexander Motin Date: Sun, 12 May 2013 09:33:34 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r250557 - head/sys/cam/scsi X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 12 May 2013 09:33:34 -0000 Author: mav Date: Sun May 12 09:33:33 2013 New Revision: 250557 URL: http://svnweb.freebsd.org/changeset/base/250557 Log: Suppress error printing for "PREVENT ALLOW MEDIUM REMOVAL" on da open. Change at r250208 exposed more errors here, hidden before. The same flag is used in cd driver. Modified: head/sys/cam/scsi/scsi_da.c Modified: head/sys/cam/scsi/scsi_da.c ============================================================================== --- head/sys/cam/scsi/scsi_da.c Sun May 12 06:20:54 2013 (r250556) +++ head/sys/cam/scsi/scsi_da.c Sun May 12 09:33:33 2013 (r250557) @@ -3355,7 +3355,7 @@ daprevent(struct cam_periph *periph, int 5000); error = cam_periph_runccb(ccb, daerror, CAM_RETRY_SELTO, - SF_RETRY_UA | SF_QUIET_IR, softc->disk->d_devstat); + SF_RETRY_UA | SF_NO_PRINT, softc->disk->d_devstat); if (error == 0) { if (action == PR_ALLOW) From owner-svn-src-all@FreeBSD.ORG Sun May 12 09:42:18 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id 903678BF; Sun, 12 May 2013 09:42:18 +0000 (UTC) (envelope-from jh@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id 814CA2C2; Sun, 12 May 2013 09:42:18 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.6/8.14.6) with ESMTP id r4C9gHpr035727; Sun, 12 May 2013 09:42:17 GMT (envelope-from jh@svn.freebsd.org) Received: (from jh@localhost) by svn.freebsd.org (8.14.6/8.14.5/Submit) id r4C9gHHs035726; Sun, 12 May 2013 09:42:17 GMT (envelope-from jh@svn.freebsd.org) Message-Id: <201305120942.r4C9gHHs035726@svn.freebsd.org> From: Jaakko Heinonen Date: Sun, 12 May 2013 09:42:17 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org Subject: svn commit: r250558 - stable/9/sys/kern X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 12 May 2013 09:42:18 -0000 Author: jh Date: Sun May 12 09:42:17 2013 New Revision: 250558 URL: http://svnweb.freebsd.org/changeset/base/250558 Log: MFC r249650: Include PID in the error message which is printed when the maxproc limit is exceeded. Improve formatting of the message while here. PR: kern/60550 Modified: stable/9/sys/kern/kern_fork.c Directory Properties: stable/9/sys/ (props changed) Modified: stable/9/sys/kern/kern_fork.c ============================================================================== --- stable/9/sys/kern/kern_fork.c Sun May 12 09:33:33 2013 (r250557) +++ stable/9/sys/kern/kern_fork.c Sun May 12 09:42:17 2013 (r250558) @@ -929,8 +929,8 @@ fork1(struct thread *td, int flags, int fail: sx_sunlock(&proctree_lock); if (ppsratecheck(&lastfail, &curfail, 1)) - printf("maxproc limit exceeded by uid %i, please see tuning(7) and login.conf(5).\n", - td->td_ucred->cr_ruid); + printf("maxproc limit exceeded by uid %u (pid %d); see tuning(7) and login.conf(5)\n", + td->td_ucred->cr_ruid, p1->p_pid); sx_xunlock(&allproc_lock); #ifdef MAC mac_proc_destroy(newproc); From owner-svn-src-all@FreeBSD.ORG Sun May 12 09:49:53 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id 0BE2BBF7; Sun, 12 May 2013 09:49:53 +0000 (UTC) (envelope-from dim@FreeBSD.org) Received: from tensor.andric.com (tensor.andric.com [87.251.56.140]) by mx1.freebsd.org (Postfix) with ESMTP id C3FC6303; Sun, 12 May 2013 09:49:52 +0000 (UTC) Received: from [192.168.1.103] (035-126-045-062.dynamic.caiway.nl [62.45.126.35]) (using TLSv1 with cipher AES128-SHA (128/128 bits)) (No client certificate requested) by tensor.andric.com (Postfix) with ESMTPSA id C76845C44; Sun, 12 May 2013 11:49:43 +0200 (CEST) Content-Type: text/plain; charset=us-ascii Mime-Version: 1.0 (Mac OS X Mail 6.3 \(1503\)) Subject: Re: svn commit: r250550 - head/contrib/gcc From: Dimitry Andric In-Reply-To: <201305120336.r4C3aSFr008262@svn.freebsd.org> Date: Sun, 12 May 2013 11:49:42 +0200 Content-Transfer-Encoding: 7bit Message-Id: References: <201305120336.r4C3aSFr008262@svn.freebsd.org> To: Pedro F. Giffuni X-Mailer: Apple Mail (2.1503) Cc: svn-src-head@freebsd.org, svn-src-all@freebsd.org, src-committers@freebsd.org X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 12 May 2013 09:49:53 -0000 On May 12, 2013, at 05:36, Pedro F. Giffuni wrote: > Author: pfg > Date: Sun May 12 03:36:28 2013 > New Revision: 250550 > URL: http://svnweb.freebsd.org/changeset/base/250550 > > Log: > Update the gcc43 changelog. > > The issue solved in r250392 actually originated upstream and was > fixed in upstream gcc43 branch in 2006/10/24 (under GPLv2). > > Register it in the appropriate ChangeLog for reference. Ah, I did not realize this, thanks for adding the comment! From owner-svn-src-all@FreeBSD.ORG Sun May 12 12:09:09 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id 2254C204; Sun, 12 May 2013 12:09:09 +0000 (UTC) (envelope-from hselasky@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id 1340C8F4; Sun, 12 May 2013 12:09:09 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.6/8.14.6) with ESMTP id r4CC98js086040; Sun, 12 May 2013 12:09:08 GMT (envelope-from hselasky@svn.freebsd.org) Received: (from hselasky@localhost) by svn.freebsd.org (8.14.6/8.14.5/Submit) id r4CC98VT086039; Sun, 12 May 2013 12:09:08 GMT (envelope-from hselasky@svn.freebsd.org) Message-Id: <201305121209.r4CC98VT086039@svn.freebsd.org> From: Hans Petter Selasky Date: Sun, 12 May 2013 12:09:08 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org Subject: svn commit: r250559 - stable/9/sys/dev/usb/controller X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 12 May 2013 12:09:09 -0000 Author: hselasky Date: Sun May 12 12:09:08 2013 New Revision: 250559 URL: http://svnweb.freebsd.org/changeset/base/250559 Log: MFC r249725: Add new OHCI controller ID. Modified: stable/9/sys/dev/usb/controller/ohci_pci.c Directory Properties: stable/9/sys/ (props changed) stable/9/sys/dev/ (props changed) Modified: stable/9/sys/dev/usb/controller/ohci_pci.c ============================================================================== --- stable/9/sys/dev/usb/controller/ohci_pci.c Sun May 12 09:42:17 2013 (r250558) +++ stable/9/sys/dev/usb/controller/ohci_pci.c Sun May 12 12:09:08 2013 (r250559) @@ -134,6 +134,8 @@ ohci_pci_match(device_t self) return "ATI SB400 USB Controller"; case 0x43971002: return ("AMD SB7x0/SB8x0/SB9x0 USB controller"); + case 0x43981002: + return ("AMD SB7x0/SB8x0/SB9x0 USB controller"); case 0x43991002: return ("AMD SB7x0/SB8x0/SB9x0 USB controller"); From owner-svn-src-all@FreeBSD.ORG Sun May 12 12:13:24 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id C3453393; Sun, 12 May 2013 12:13:24 +0000 (UTC) (envelope-from hselasky@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id 9BEBD90B; Sun, 12 May 2013 12:13:24 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.6/8.14.6) with ESMTP id r4CCDOZw088606; Sun, 12 May 2013 12:13:24 GMT (envelope-from hselasky@svn.freebsd.org) Received: (from hselasky@localhost) by svn.freebsd.org (8.14.6/8.14.5/Submit) id r4CCDOl1088602; Sun, 12 May 2013 12:13:24 GMT (envelope-from hselasky@svn.freebsd.org) Message-Id: <201305121213.r4CCDOl1088602@svn.freebsd.org> From: Hans Petter Selasky Date: Sun, 12 May 2013 12:13:24 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org Subject: svn commit: r250560 - in stable/9/sys/dev/usb: . controller X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 12 May 2013 12:13:24 -0000 Author: hselasky Date: Sun May 12 12:13:23 2013 New Revision: 250560 URL: http://svnweb.freebsd.org/changeset/base/250560 Log: MFC r249795: Add convenience wrapper functions to run callbacks in the context of the USB explore thread. Modified: stable/9/sys/dev/usb/controller/usb_controller.c stable/9/sys/dev/usb/usb_process.h Directory Properties: stable/9/sys/ (props changed) stable/9/sys/dev/ (props changed) Modified: stable/9/sys/dev/usb/controller/usb_controller.c ============================================================================== --- stable/9/sys/dev/usb/controller/usb_controller.c Sun May 12 12:09:08 2013 (r250559) +++ stable/9/sys/dev/usb/controller/usb_controller.c Sun May 12 12:13:23 2013 (r250560) @@ -877,3 +877,28 @@ usb_bus_mem_free_all(struct usb_bus *bus mtx_destroy(&bus->bus_mtx); } + +/* convenience wrappers */ +void +usb_proc_explore_mwait(struct usb_device *udev, void *pm1, void *pm2) +{ + usb_proc_mwait(&udev->bus->explore_proc, pm1, pm2); +} + +void * +usb_proc_explore_msignal(struct usb_device *udev, void *pm1, void *pm2) +{ + return (usb_proc_msignal(&udev->bus->explore_proc, pm1, pm2)); +} + +void +usb_proc_explore_lock(struct usb_device *udev) +{ + USB_BUS_LOCK(udev->bus); +} + +void +usb_proc_explore_unlock(struct usb_device *udev) +{ + USB_BUS_UNLOCK(udev->bus); +} Modified: stable/9/sys/dev/usb/usb_process.h ============================================================================== --- stable/9/sys/dev/usb/usb_process.h Sun May 12 12:09:08 2013 (r250559) +++ stable/9/sys/dev/usb/usb_process.h Sun May 12 12:13:23 2013 (r250560) @@ -42,6 +42,7 @@ /* structure prototypes */ struct usb_proc_msg; +struct usb_device; /* * The following structure defines the USB process. @@ -79,4 +80,9 @@ void usb_proc_free(struct usb_process *u void *usb_proc_msignal(struct usb_process *up, void *pm0, void *pm1); void usb_proc_rewakeup(struct usb_process *up); +void usb_proc_explore_mwait(struct usb_device *, void *, void *); +void *usb_proc_explore_msignal(struct usb_device *, void *, void *); +void usb_proc_explore_lock(struct usb_device *); +void usb_proc_explore_unlock(struct usb_device *); + #endif /* _USB_PROCESS_H_ */ From owner-svn-src-all@FreeBSD.ORG Sun May 12 12:20:04 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id E223D794; Sun, 12 May 2013 12:20:04 +0000 (UTC) (envelope-from hselasky@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id B4DCC942; Sun, 12 May 2013 12:20:04 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.6/8.14.6) with ESMTP id r4CCK4l5089965; Sun, 12 May 2013 12:20:04 GMT (envelope-from hselasky@svn.freebsd.org) Received: (from hselasky@localhost) by svn.freebsd.org (8.14.6/8.14.5/Submit) id r4CCK4B6089964; Sun, 12 May 2013 12:20:04 GMT (envelope-from hselasky@svn.freebsd.org) Message-Id: <201305121220.r4CCK4B6089964@svn.freebsd.org> From: Hans Petter Selasky Date: Sun, 12 May 2013 12:20:04 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org Subject: svn commit: r250561 - stable/9/sys/dev/sound/usb X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 12 May 2013 12:20:05 -0000 Author: hselasky Date: Sun May 12 12:20:04 2013 New Revision: 250561 URL: http://svnweb.freebsd.org/changeset/base/250561 Log: MFC r249796, r249830, r249844 and r249845: USB audio fixes and improvements. - Fix runtime switching of sample rate - Fix feedback endpoint algorithm Modified: stable/9/sys/dev/sound/usb/uaudio.c Directory Properties: stable/9/sys/ (props changed) stable/9/sys/dev/ (props changed) Modified: stable/9/sys/dev/sound/usb/uaudio.c ============================================================================== --- stable/9/sys/dev/sound/usb/uaudio.c Sun May 12 12:13:23 2013 (r250560) +++ stable/9/sys/dev/sound/usb/uaudio.c Sun May 12 12:20:04 2013 (r250561) @@ -73,6 +73,7 @@ __FBSDID("$FreeBSD$"); #include #include #include +#include #define USB_DEBUG_VAR uaudio_debug #include @@ -176,19 +177,34 @@ struct uaudio_mixer_node { struct uaudio_mixer_node *next; }; +struct uaudio_configure_msg { + struct usb_proc_msg hdr; + struct uaudio_softc *sc; +}; + +#define CHAN_MAX_ALT 20 + +struct uaudio_chan_alt { + union uaudio_asf1d p_asf1d; + union uaudio_sed p_sed; + const usb_endpoint_descriptor_audio_t *p_ed1; + const struct uaudio_format *p_fmt; + const struct usb_config *usb_cfg; + uint32_t sample_rate; /* in Hz */ + uint16_t sample_size; + uint8_t iface_index; + uint8_t iface_alt_index; + uint8_t channels; +}; + struct uaudio_chan { struct pcmchan_caps pcm_cap; /* capabilities */ - + struct uaudio_chan_alt usb_alt[CHAN_MAX_ALT]; struct snd_dbuf *pcm_buf; - const struct usb_config *usb_cfg; struct mtx *pcm_mtx; /* lock protecting this structure */ struct uaudio_softc *priv_sc; struct pcm_channel *pcm_ch; struct usb_xfer *xfer[UAUDIO_NCHANBUFS + 1]; - union uaudio_asf1d p_asf1d; - union uaudio_sed p_sed; - const usb_endpoint_descriptor_audio_t *p_ed1; - const struct uaudio_format *p_fmt; uint8_t *buf; /* pointer to buffer */ uint8_t *start; /* upper layer buffer start */ @@ -196,24 +212,24 @@ struct uaudio_chan { uint8_t *cur; /* current position in upper layer * buffer */ - uint32_t intr_size; /* in bytes */ uint32_t intr_frames; /* in units */ - uint32_t sample_rate; uint32_t frames_per_second; uint32_t sample_rem; uint32_t sample_curr; + uint32_t max_buf; - uint32_t format; uint32_t pcm_format[2]; uint16_t bytes_per_frame[2]; - uint16_t sample_size; - - uint8_t valid; - uint8_t iface_index; - uint8_t iface_alt_index; - uint8_t channels; + uint8_t num_alt; + uint8_t cur_alt; + uint8_t set_alt; + uint8_t operation; +#define CHAN_OP_NONE 0 +#define CHAN_OP_START 1 +#define CHAN_OP_STOP 2 +#define CHAN_OP_DRAIN 3 uint8_t last_sync_time; uint8_t last_sync_state; @@ -309,6 +325,7 @@ struct uaudio_softc { struct uaudio_hid sc_hid; struct uaudio_search_result sc_mixer_clocks; struct uaudio_mixer_node sc_mixer_node; + struct uaudio_configure_msg sc_config_msg[2]; struct mtx *sc_mixer_lock; struct snd_mixer *sc_mixer_dev; @@ -434,6 +451,8 @@ static usb_callback_t umidi_bulk_read_ca static usb_callback_t umidi_bulk_write_callback; static usb_callback_t uaudio_hid_rx_callback; +static usb_proc_callback_t uaudio_configure_msg; + /* ==== USB mixer ==== */ static int uaudio_mixer_sysctl_handler(SYSCTL_HANDLER_ARGS); @@ -856,6 +875,10 @@ uaudio_attach(device_t dev) sc->sc_udev = uaa->device; sc->sc_mixer_iface_index = uaa->info.bIfaceIndex; sc->sc_mixer_iface_no = uaa->info.bIfaceNum; + sc->sc_config_msg[0].hdr.pm_callback = &uaudio_configure_msg; + sc->sc_config_msg[0].sc = sc; + sc->sc_config_msg[1].hdr.pm_callback = &uaudio_configure_msg; + sc->sc_config_msg[1].sc = sc; if (usb_test_quirk(uaa, UQ_AUDIO_SWAP_LR)) sc->sc_uq_audio_swap_lr = 1; @@ -900,22 +923,28 @@ uaudio_attach(device_t dev) DPRINTF("%d mixer controls\n", sc->sc_mixer_count); - if (sc->sc_play_chan.valid) { - device_printf(dev, "Play: %d Hz, %d ch, %s format, " - "2x8ms buffer.\n", - sc->sc_play_chan.sample_rate, - sc->sc_play_chan.channels, - sc->sc_play_chan.p_fmt->description); + if (sc->sc_play_chan.num_alt > 0) { + uint8_t x; + for (x = 0; x != sc->sc_play_chan.num_alt; x++) { + device_printf(dev, "Play: %d Hz, %d ch, %s format, " + "2x8ms buffer.\n", + sc->sc_play_chan.usb_alt[x].sample_rate, + sc->sc_play_chan.usb_alt[x].channels, + sc->sc_play_chan.usb_alt[x].p_fmt->description); + } } else { device_printf(dev, "No playback.\n"); } - if (sc->sc_rec_chan.valid) { - device_printf(dev, "Record: %d Hz, %d ch, %s format, " - "2x8ms buffer.\n", - sc->sc_rec_chan.sample_rate, - sc->sc_rec_chan.channels, - sc->sc_rec_chan.p_fmt->description); + if (sc->sc_rec_chan.num_alt > 0) { + uint8_t x; + for (x = 0; x != sc->sc_rec_chan.num_alt; x++) { + device_printf(dev, "Record: %d Hz, %d ch, %s format, " + "2x8ms buffer.\n", + sc->sc_rec_chan.usb_alt[x].sample_rate, + sc->sc_rec_chan.usb_alt[x].channels, + sc->sc_rec_chan.usb_alt[x].p_fmt->description); + } } else { device_printf(dev, "No recording.\n"); } @@ -950,8 +979,8 @@ uaudio_attach(device_t dev) * Only attach a PCM device if we have a playback, recording * or mixer device present: */ - if (sc->sc_play_chan.valid || - sc->sc_rec_chan.valid || + if (sc->sc_play_chan.num_alt > 0 || + sc->sc_rec_chan.num_alt > 0 || sc->sc_mix_info) { child = device_add_child(dev, "pcm", -1); @@ -1020,18 +1049,18 @@ uaudio_attach_sub(device_t dev, kobj_cla snprintf(status, sizeof(status), "at ? %s", PCM_KLDSTRING(snd_uaudio)); if (pcm_register(dev, sc, - sc->sc_play_chan.valid ? 1 : 0, - sc->sc_rec_chan.valid ? 1 : 0)) { + (sc->sc_play_chan.num_alt > 0) ? 1 : 0, + (sc->sc_rec_chan.num_alt > 0) ? 1 : 0)) { goto detach; } uaudio_pcm_setflags(dev, SD_F_MPSAFE); sc->sc_pcm_registered = 1; - if (sc->sc_play_chan.valid) { + if (sc->sc_play_chan.num_alt > 0) { pcm_addchan(dev, PCMDIR_PLAY, chan_class, sc); } - if (sc->sc_rec_chan.valid) { + if (sc->sc_rec_chan.num_alt > 0) { pcm_addchan(dev, PCMDIR_REC, chan_class, sc); } pcm_setstatus(dev, status); @@ -1078,10 +1107,15 @@ uaudio_detach(device_t dev) * will time out and close opened /dev/dspX.Y device(s), if * any. */ - if (sc->sc_play_chan.valid) - usbd_transfer_unsetup(sc->sc_play_chan.xfer, UAUDIO_NCHANBUFS + 1); - if (sc->sc_rec_chan.valid) - usbd_transfer_unsetup(sc->sc_rec_chan.xfer, UAUDIO_NCHANBUFS + 1); + usb_proc_explore_lock(sc->sc_udev); + sc->sc_play_chan.operation = CHAN_OP_DRAIN; + sc->sc_rec_chan.operation = CHAN_OP_DRAIN; + usb_proc_explore_mwait(sc->sc_udev, + &sc->sc_config_msg[0], &sc->sc_config_msg[1]); + usb_proc_explore_unlock(sc->sc_udev); + + usbd_transfer_unsetup(sc->sc_play_chan.xfer, UAUDIO_NCHANBUFS + 1); + usbd_transfer_unsetup(sc->sc_rec_chan.xfer, UAUDIO_NCHANBUFS + 1); uaudio_hid_detach(sc); @@ -1100,6 +1134,201 @@ uaudio_detach(device_t dev) return (0); } +static uint32_t +uaudio_get_buffer_size(struct uaudio_chan *ch, uint8_t alt) +{ + struct uaudio_chan_alt *chan_alt = &ch->usb_alt[alt]; + /* We use 2 times 8ms of buffer */ + uint32_t buf_size = (((chan_alt->sample_rate * (UAUDIO_NFRAMES / 8)) + + 1000 - 1) / 1000) * chan_alt->sample_size; + return (buf_size); +} + +static void +uaudio_configure_msg_sub(struct uaudio_softc *sc, + struct uaudio_chan *chan, int dir) +{ + struct uaudio_chan_alt *chan_alt; + uint32_t frames; + uint32_t buf_size; + uint16_t fps; + uint8_t set_alt; + uint8_t fps_shift; + uint8_t operation; + usb_error_t err; + + if (chan->num_alt <= 0) + return; + + DPRINTF("\n"); + + usb_proc_explore_lock(sc->sc_udev); + operation = chan->operation; + chan->operation = CHAN_OP_NONE; + usb_proc_explore_unlock(sc->sc_udev); + + mtx_lock(chan->pcm_mtx); + if (chan->cur_alt != chan->set_alt) + set_alt = chan->set_alt; + else + set_alt = CHAN_MAX_ALT; + mtx_unlock(chan->pcm_mtx); + + if (set_alt >= chan->num_alt) + goto done; + + chan_alt = chan->usb_alt + set_alt; + + usbd_transfer_unsetup(chan->xfer, UAUDIO_NCHANBUFS + 1); + + err = usbd_set_alt_interface_index(sc->sc_udev, + chan_alt->iface_index, chan_alt->iface_alt_index); + if (err) { + DPRINTF("setting of alternate index failed: %s!\n", + usbd_errstr(err)); + goto error; + } + + /* + * Only set the sample rate if the channel reports that it + * supports the frequency control. + */ + + if (sc->sc_audio_rev >= UAUDIO_VERSION_30) { + /* FALLTHROUGH */ + } else if (sc->sc_audio_rev >= UAUDIO_VERSION_20) { + unsigned int x; + + for (x = 0; x != 256; x++) { + if (dir == PCMDIR_PLAY) { + if (!(sc->sc_mixer_clocks.bit_output[x / 8] & + (1 << (x % 8)))) { + continue; + } + } else { + if (!(sc->sc_mixer_clocks.bit_input[x / 8] & + (1 << (x % 8)))) { + continue; + } + } + + if (uaudio20_set_speed(sc->sc_udev, + sc->sc_mixer_iface_no, x, chan_alt->sample_rate)) { + /* + * If the endpoint is adaptive setting + * the speed may fail. + */ + DPRINTF("setting of sample rate failed! " + "(continuing anyway)\n"); + } + } + } else if (chan_alt->p_sed.v1->bmAttributes & UA_SED_FREQ_CONTROL) { + if (uaudio_set_speed(sc->sc_udev, + chan_alt->p_ed1->bEndpointAddress, chan_alt->sample_rate)) { + /* + * If the endpoint is adaptive setting the + * speed may fail. + */ + DPRINTF("setting of sample rate failed! " + "(continuing anyway)\n"); + } + } + if (usbd_transfer_setup(sc->sc_udev, &chan_alt->iface_index, chan->xfer, + chan_alt->usb_cfg, UAUDIO_NCHANBUFS + 1, chan, chan->pcm_mtx)) { + DPRINTF("could not allocate USB transfers!\n"); + goto error; + } + + fps = usbd_get_isoc_fps(sc->sc_udev); + + if (fps < 8000) { + /* FULL speed USB */ + frames = 8; + } else { + /* HIGH speed USB */ + frames = UAUDIO_NFRAMES; + } + + fps_shift = usbd_xfer_get_fps_shift(chan->xfer[0]); + + /* down shift number of frames per second, if any */ + fps >>= fps_shift; + frames >>= fps_shift; + + /* bytes per frame should not be zero */ + chan->bytes_per_frame[0] = + ((chan_alt->sample_rate / fps) * chan_alt->sample_size); + chan->bytes_per_frame[1] = + (((chan_alt->sample_rate + fps - 1) / fps) * chan_alt->sample_size); + + /* setup data rate dithering, if any */ + chan->frames_per_second = fps; + chan->sample_rem = chan_alt->sample_rate % fps; + chan->sample_curr = 0; + chan->frames_per_second = fps; + + /* compute required buffer size */ + buf_size = (chan->bytes_per_frame[1] * frames); + + if (buf_size > (chan->end - chan->start)) { + DPRINTF("buffer size is too big\n"); + goto error; + } + + chan->intr_frames = frames; + + DPRINTF("fps=%d sample_rem=%d\n", (int)fps, (int)chan->sample_rem); + + if (chan->intr_frames == 0) { + DPRINTF("frame shift is too high!\n"); + goto error; + } + + mtx_lock(chan->pcm_mtx); + chan->cur_alt = set_alt; + mtx_unlock(chan->pcm_mtx); + +done: +#if (UAUDIO_NCHANBUFS != 2) +#error "please update code" +#endif + switch (operation) { + case CHAN_OP_START: + mtx_lock(chan->pcm_mtx); + usbd_transfer_start(chan->xfer[0]); + usbd_transfer_start(chan->xfer[1]); + mtx_unlock(chan->pcm_mtx); + break; + case CHAN_OP_STOP: + mtx_lock(chan->pcm_mtx); + usbd_transfer_stop(chan->xfer[0]); + usbd_transfer_stop(chan->xfer[1]); + mtx_unlock(chan->pcm_mtx); + break; + default: + break; + } + return; + +error: + usbd_transfer_unsetup(chan->xfer, UAUDIO_NCHANBUFS + 1); + + mtx_lock(chan->pcm_mtx); + chan->cur_alt = CHAN_MAX_ALT; + mtx_unlock(chan->pcm_mtx); +} + +static void +uaudio_configure_msg(struct usb_proc_msg *pm) +{ + struct uaudio_softc *sc = ((struct uaudio_configure_msg *)pm)->sc; + + usb_proc_explore_unlock(sc->sc_udev); + uaudio_configure_msg_sub(sc, &sc->sc_play_chan, PCMDIR_PLAY); + uaudio_configure_msg_sub(sc, &sc->sc_rec_chan, PCMDIR_REC); + usb_proc_explore_lock(sc->sc_udev); +} + /*========================================================================* * AS - Audio Stream - routines *========================================================================*/ @@ -1237,6 +1466,8 @@ uaudio_chan_fill_info_sub(struct uaudio_ struct usb_interface_descriptor *id; const struct uaudio_format *p_fmt = NULL; struct uaudio_chan *chan; + struct uaudio_chan_alt *chan_alt; + uint32_t format; uint16_t curidx = 0xFFFF; uint16_t lastidx = 0xFFFF; uint16_t alt_index = 0; @@ -1414,6 +1645,10 @@ uaudio_chan_fill_info_sub(struct uaudio_ bBitResolution = asf1d.v2->bBitResolution; bSubslotSize = asf1d.v2->bSubslotSize; + /* Map 4-byte aligned 24-bit samples into 32-bit */ + if (bBitResolution == 24 && bSubslotSize == 4) + bBitResolution = 32; + if (bBitResolution != (bSubslotSize * 8)) { DPRINTF("Invalid bSubslotSize\n"); goto next_ep; @@ -1508,14 +1743,19 @@ uaudio_chan_fill_info_sub(struct uaudio_ chan = (ep_dir == UE_DIR_IN) ? &sc->sc_rec_chan : &sc->sc_play_chan; - if (chan->valid != 0 || - usbd_get_iface(udev, curidx) == NULL) { - DPRINTF("Channel already exists or " - "interface is not valid\n"); + if (usbd_get_iface(udev, curidx) == NULL) { + DPRINTF("Interface is not valid\n"); goto next_ep; } + if (chan->num_alt == CHAN_MAX_ALT) { + DPRINTF("Too many alternate settings\n"); + goto next_ep; + } + chan->set_alt = 0; + chan->cur_alt = CHAN_MAX_ALT; + + chan_alt = &chan->usb_alt[chan->num_alt++]; - chan->valid = 1; #ifdef USB_DEBUG uaudio_chan_dump_ep_desc(ed1); #endif @@ -1523,30 +1763,81 @@ uaudio_chan_fill_info_sub(struct uaudio_ "bits = %d, format = %s\n", rate, channels, bit_resolution, p_fmt->description); - chan->sample_rate = rate; - chan->p_asf1d = asf1d; - chan->p_ed1 = ed1; - chan->p_fmt = p_fmt; - chan->p_sed = sed; - chan->iface_index = curidx; - chan->iface_alt_index = alt_index; + chan_alt->sample_rate = rate; + chan_alt->p_asf1d = asf1d; + chan_alt->p_ed1 = ed1; + chan_alt->p_fmt = p_fmt; + chan_alt->p_sed = sed; + chan_alt->iface_index = curidx; + chan_alt->iface_alt_index = alt_index; + + usbd_set_parent_iface(sc->sc_udev, curidx, + sc->sc_mixer_iface_index); if (ep_dir == UE_DIR_IN) - chan->usb_cfg = uaudio_cfg_record; + chan_alt->usb_cfg = uaudio_cfg_record; else - chan->usb_cfg = uaudio_cfg_play; + chan_alt->usb_cfg = uaudio_cfg_play; - chan->sample_size = (UAUDIO_MAX_CHAN(channels) * + chan_alt->sample_size = (UAUDIO_MAX_CHAN(channels) * p_fmt->bPrecision) / 8; - chan->channels = channels; + chan_alt->channels = channels; if (ep_dir == UE_DIR_IN && usbd_get_speed(udev) == USB_SPEED_FULL) { uaudio_record_fix_fs(ed1, - chan->sample_size * (rate / 1000), - chan->sample_size * (rate / 4000)); + chan_alt->sample_size * (rate / 1000), + chan_alt->sample_size * (rate / 4000)); } + /* setup play/record format */ + + format = chan_alt->p_fmt->freebsd_fmt; + + switch (chan_alt->channels) { + case 2: + /* stereo */ + format = SND_FORMAT(format, 2, 0); + break; + case 1: + /* mono */ + format = SND_FORMAT(format, 1, 0); + break; + default: + /* surround and more */ + format = feeder_matrix_default_format( + SND_FORMAT(format, chan_alt->channels, 0)); + break; + } + + /* check if format is not supported */ + if (format == 0) { + DPRINTF("The selected audio format is not supported\n"); + chan->num_alt--; + goto next_ep; + } + if (chan->num_alt > 1) { + /* we only accumulate one format at different sample rates */ + if (chan->pcm_format[0] != format) { + DPRINTF("Multiple formats is not supported\n"); + chan->num_alt--; + goto next_ep; + } + /* ignore if duplicate sample rate entry */ + if (rate == chan->usb_alt[chan->num_alt - 2].sample_rate) { + DPRINTF("Duplicate sample rate detected\n"); + chan->num_alt--; + goto next_ep; + } + } + chan->pcm_cap.fmtlist = chan->pcm_format; + chan->pcm_cap.fmtlist[0] = format; + + if (rate < chan->pcm_cap.minspeed || chan->pcm_cap.minspeed == 0) + chan->pcm_cap.minspeed = rate; + if (rate > chan->pcm_cap.maxspeed || chan->pcm_cap.maxspeed == 0) + chan->pcm_cap.maxspeed = rate; + if (sc->sc_sndstat_valid != 0) { sbuf_printf(&sc->sc_sndstat, "\n\t" "mode %d.%d:(%s) %dch, %dbit, %s, %dHz", @@ -1564,8 +1855,9 @@ uaudio_chan_fill_info_sub(struct uaudio_ /* This structure defines all the supported rates. */ -static const uint32_t uaudio_rate_list[] = { +static const uint32_t uaudio_rate_list[CHAN_MAX_ALT] = { 96000, + 88200, 88000, 80000, 72000, @@ -1630,21 +1922,12 @@ uaudio_chan_fill_info(struct uaudio_soft uaudio_chan_fill_info_sub(sc, udev, rate, x, y); /* try find a matching rate, if any */ - for (z = 0; uaudio_rate_list[z]; z++) { + for (z = 0; uaudio_rate_list[z]; z++) uaudio_chan_fill_info_sub(sc, udev, uaudio_rate_list[z], x, y); - - if (sc->sc_rec_chan.valid && - sc->sc_play_chan.valid) { - goto done; - } - } } } - -done: - if (sc->sc_sndstat_valid) { + if (sc->sc_sndstat_valid) sbuf_finish(&sc->sc_sndstat); - } } static void @@ -1652,6 +1935,7 @@ uaudio_chan_play_sync_callback(struct us { struct uaudio_chan *ch = usbd_xfer_softc(xfer); struct usb_page_cache *pc; + uint64_t sample_rate = ch->usb_alt[ch->cur_alt].sample_rate; uint8_t buf[4]; uint64_t temp; int len; @@ -1698,24 +1982,20 @@ uaudio_chan_play_sync_callback(struct us /* auto adjust */ - while (temp < (ch->sample_rate - (ch->sample_rate / 4))) + while (temp < (sample_rate - (sample_rate / 4))) temp *= 2; - while (temp > (ch->sample_rate + (ch->sample_rate / 2))) + while (temp > (sample_rate + (sample_rate / 2))) temp /= 2; - /* bias */ - - temp += (ch->sample_rate + 1999) / 2000; - /* compare */ DPRINTF("Comparing %d < %d\n", - (int)temp, (int)ch->sample_rate); + (int)temp, (int)sample_rate); - if (temp == ch->sample_rate) + if (temp == sample_rate) ch->last_sync_state = UAUDIO_SYNC_NONE; - else if (temp > ch->sample_rate) + else if (temp > sample_rate) ch->last_sync_state = UAUDIO_SYNC_MORE; else ch->last_sync_state = UAUDIO_SYNC_LESS; @@ -1737,6 +2017,7 @@ uaudio_chan_play_callback(struct usb_xfe { struct uaudio_chan *ch = usbd_xfer_softc(xfer); struct usb_page_cache *pc; + uint32_t sample_size = ch->usb_alt[ch->cur_alt].sample_size; uint32_t mfl; uint32_t total; uint32_t blockcount; @@ -1800,14 +2081,14 @@ tr_transferred: switch (ch->last_sync_state) { case UAUDIO_SYNC_MORE: DPRINTFN(6, "sending one sample more\n"); - if ((frame_len + ch->sample_size) <= mfl) - frame_len += ch->sample_size; + if ((frame_len + sample_size) <= mfl) + frame_len += sample_size; ch->last_sync_state = UAUDIO_SYNC_NONE; break; case UAUDIO_SYNC_LESS: DPRINTFN(6, "sending one sample less\n"); - if (frame_len >= ch->sample_size) - frame_len -= ch->sample_size; + if (frame_len >= sample_size) + frame_len -= sample_size; ch->last_sync_state = UAUDIO_SYNC_NONE; break; default: @@ -1944,187 +2225,43 @@ uaudio_chan_init(struct uaudio_softc *sc struct uaudio_chan *ch = ((dir == PCMDIR_PLAY) ? &sc->sc_play_chan : &sc->sc_rec_chan); uint32_t buf_size; - uint32_t frames; - uint32_t format; - uint16_t fps; - uint8_t endpoint; - uint8_t blocks; - uint8_t iface_index; - uint8_t alt_index; - uint8_t fps_shift; - usb_error_t err; - - fps = usbd_get_isoc_fps(sc->sc_udev); - - if (fps < 8000) { - /* FULL speed USB */ - frames = 8; - } else { - /* HIGH speed USB */ - frames = UAUDIO_NFRAMES; - } - - /* setup play/record format */ - - ch->pcm_cap.fmtlist = ch->pcm_format; - - ch->pcm_format[0] = 0; - ch->pcm_format[1] = 0; - - ch->pcm_cap.minspeed = ch->sample_rate; - ch->pcm_cap.maxspeed = ch->sample_rate; + uint8_t x; - /* setup mutex and PCM channel */ + /* store mutex and PCM channel */ ch->pcm_ch = c; ch->pcm_mtx = c->lock; - format = ch->p_fmt->freebsd_fmt; - - switch (ch->channels) { - case 2: - /* stereo */ - format = SND_FORMAT(format, 2, 0); - break; - case 1: - /* mono */ - format = SND_FORMAT(format, 1, 0); - break; - default: - /* surround and more */ - format = feeder_matrix_default_format( - SND_FORMAT(format, ch->channels, 0)); - break; - } - - ch->pcm_cap.fmtlist[0] = format; - ch->pcm_cap.fmtlist[1] = 0; - - /* check if format is not supported */ - - if (format == 0) { - DPRINTF("The selected audio format is not supported\n"); - goto error; - } - - /* set alternate interface corresponding to the mode */ - - endpoint = ch->p_ed1->bEndpointAddress; - iface_index = ch->iface_index; - alt_index = ch->iface_alt_index; - - DPRINTF("endpoint=0x%02x, speed=%d, iface=%d alt=%d\n", - endpoint, ch->sample_rate, iface_index, alt_index); + /* compute worst case buffer */ - err = usbd_set_alt_interface_index(sc->sc_udev, iface_index, alt_index); - if (err) { - DPRINTF("setting of alternate index failed: %s!\n", - usbd_errstr(err)); - goto error; + buf_size = 0; + for (x = 0; x != ch->num_alt; x++) { + uint32_t temp = uaudio_get_buffer_size(ch, x); + if (temp > buf_size) + buf_size = temp; } - usbd_set_parent_iface(sc->sc_udev, iface_index, - sc->sc_mixer_iface_index); - - /* - * Only set the sample rate if the channel reports that it - * supports the frequency control. - */ - if (sc->sc_audio_rev >= UAUDIO_VERSION_30) { - /* FALLTHROUGH */ - } else if (sc->sc_audio_rev >= UAUDIO_VERSION_20) { - unsigned int x; - - for (x = 0; x != 256; x++) { - if (dir == PCMDIR_PLAY) { - if (!(sc->sc_mixer_clocks.bit_output[x / 8] & - (1 << (x % 8)))) { - continue; - } - } else { - if (!(sc->sc_mixer_clocks.bit_input[x / 8] & - (1 << (x % 8)))) { - continue; - } - } - - if (uaudio20_set_speed(sc->sc_udev, - sc->sc_mixer_iface_no, x, ch->sample_rate)) { - /* - * If the endpoint is adaptive setting - * the speed may fail. - */ - DPRINTF("setting of sample rate failed! " - "(continuing anyway)\n"); - } - } - } else if (ch->p_sed.v1->bmAttributes & UA_SED_FREQ_CONTROL) { - if (uaudio_set_speed(sc->sc_udev, endpoint, ch->sample_rate)) { - /* - * If the endpoint is adaptive setting the - * speed may fail. - */ - DPRINTF("setting of sample rate failed! " - "(continuing anyway)\n"); - } - } - if (usbd_transfer_setup(sc->sc_udev, &iface_index, ch->xfer, - ch->usb_cfg, UAUDIO_NCHANBUFS + 1, ch, ch->pcm_mtx)) { - DPRINTF("could not allocate USB transfers!\n"); - goto error; - } - - fps_shift = usbd_xfer_get_fps_shift(ch->xfer[0]); - - /* down shift number of frames per second, if any */ - fps >>= fps_shift; - frames >>= fps_shift; - - /* bytes per frame should not be zero */ - ch->bytes_per_frame[0] = ((ch->sample_rate / fps) * ch->sample_size); - ch->bytes_per_frame[1] = (((ch->sample_rate + fps - 1) / fps) * ch->sample_size); - - /* setup data rate dithering, if any */ - ch->frames_per_second = fps; - ch->sample_rem = ch->sample_rate % fps; - ch->sample_curr = 0; - ch->frames_per_second = fps; - - /* compute required buffer size */ - buf_size = (ch->bytes_per_frame[1] * frames); - - ch->intr_size = buf_size; - ch->intr_frames = frames; - - DPRINTF("fps=%d sample_rem=%d\n", fps, ch->sample_rem); - - if (ch->intr_frames == 0) { - DPRINTF("frame shift is too high!\n"); - goto error; - } - - /* setup double buffering */ + /* allow double buffering */ buf_size *= 2; - blocks = 2; + + DPRINTF("Worst case buffer is %d bytes\n", (int)buf_size); ch->buf = malloc(buf_size, M_DEVBUF, M_WAITOK | M_ZERO); if (ch->buf == NULL) goto error; if (sndbuf_setup(b, ch->buf, buf_size) != 0) goto error; - if (sndbuf_resize(b, blocks, ch->intr_size)) - goto error; ch->start = ch->buf; ch->end = ch->buf + buf_size; ch->cur = ch->buf; ch->pcm_buf = b; + ch->max_buf = buf_size; if (ch->pcm_mtx == NULL) { DPRINTF("ERROR: PCM channels does not have a mutex!\n"); goto error; } - return (ch); error: @@ -2141,7 +2278,7 @@ uaudio_chan_free(struct uaudio_chan *ch) } usbd_transfer_unsetup(ch->xfer, UAUDIO_NCHANBUFS + 1); - ch->valid = 0; + ch->num_alt = 0; return (0); } @@ -2149,7 +2286,15 @@ uaudio_chan_free(struct uaudio_chan *ch) int uaudio_chan_set_param_blocksize(struct uaudio_chan *ch, uint32_t blocksize) { - return (ch->intr_size); + uint32_t temp = 2 * uaudio_get_buffer_size(ch, ch->set_alt); + + sndbuf_setup(ch->pcm_buf, ch->buf, temp); + + ch->start = ch->buf; + ch->end = ch->buf + temp; + ch->cur = ch->buf; + + return (temp / 2); } int @@ -2162,10 +2307,23 @@ uaudio_chan_set_param_fragments(struct u int uaudio_chan_set_param_speed(struct uaudio_chan *ch, uint32_t speed) { - if (speed != ch->sample_rate) { - DPRINTF("rate conversion required\n"); + uint8_t x; + + for (x = 0; x < ch->num_alt; x++) { + if (ch->usb_alt[x].sample_rate < speed) { + /* sample rate is too low */ + break; + } } - return (ch->sample_rate); + + if (x != 0) + x--; + + ch->set_alt = x; + + DPRINTF("Selecting alt %d\n", (int)x); + + return (ch->usb_alt[x].sample_rate); } int @@ -2228,31 +2386,61 @@ uaudio_chan_getmatrix(struct uaudio_chan int uaudio_chan_set_param_format(struct uaudio_chan *ch, uint32_t format) { - ch->format = format; + DPRINTF("Selecting format 0x%08x\n", (unsigned int)format); return (0); } int uaudio_chan_start(struct uaudio_chan *ch) { - ch->cur = ch->start; + struct uaudio_softc *sc = ch->priv_sc; + int do_start = 0; -#if (UAUDIO_NCHANBUFS != 2) -#error "please update code" -#endif - usbd_transfer_start(ch->xfer[0]); - usbd_transfer_start(ch->xfer[1]); + usb_proc_explore_lock(sc->sc_udev); + if (ch->operation != CHAN_OP_DRAIN) { + if (ch->cur_alt == ch->set_alt && + ch->operation == CHAN_OP_NONE) { + /* save doing the explore task */ + do_start = 1; + } else { + ch->operation = CHAN_OP_START; + (void)usb_proc_explore_msignal(sc->sc_udev, + &sc->sc_config_msg[0], &sc->sc_config_msg[1]); + } + } + usb_proc_explore_unlock(sc->sc_udev); + + if (do_start) { + usbd_transfer_start(ch->xfer[0]); + usbd_transfer_start(ch->xfer[1]); + } return (0); } int uaudio_chan_stop(struct uaudio_chan *ch) { -#if (UAUDIO_NCHANBUFS != 2) -#error "please update code" -#endif - usbd_transfer_stop(ch->xfer[0]); - usbd_transfer_stop(ch->xfer[1]); + struct uaudio_softc *sc = ch->priv_sc; + int do_stop = 0; + + usb_proc_explore_lock(sc->sc_udev); + if (ch->operation != CHAN_OP_DRAIN) { + if (ch->cur_alt == ch->set_alt && + ch->operation == CHAN_OP_NONE) { + /* save doing the explore task */ + do_stop = 1; + } else { + ch->operation = CHAN_OP_STOP; + (void)usb_proc_explore_msignal(sc->sc_udev, + &sc->sc_config_msg[0], &sc->sc_config_msg[1]); + } + } + usb_proc_explore_unlock(sc->sc_udev); + + if (do_stop) { + usbd_transfer_stop(ch->xfer[0]); + usbd_transfer_stop(ch->xfer[1]); + } return (0); } From owner-svn-src-all@FreeBSD.ORG Sun May 12 12:24:30 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id 7A01DA2E; Sun, 12 May 2013 12:24:30 +0000 (UTC) (envelope-from hselasky@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id 524BF974; Sun, 12 May 2013 12:24:30 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.6/8.14.6) with ESMTP id r4CCOUR5092350; Sun, 12 May 2013 12:24:30 GMT (envelope-from hselasky@svn.freebsd.org) Received: (from hselasky@localhost) by svn.freebsd.org (8.14.6/8.14.5/Submit) id r4CCOTS4092346; Sun, 12 May 2013 12:24:29 GMT (envelope-from hselasky@svn.freebsd.org) Message-Id: <201305121224.r4CCOTS4092346@svn.freebsd.org> From: Hans Petter Selasky Date: Sun, 12 May 2013 12:24:29 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-8@freebsd.org Subject: svn commit: r250562 - in stable/8/sys/dev/usb: . controller X-SVN-Group: stable-8 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 12 May 2013 12:24:30 -0000 Author: hselasky Date: Sun May 12 12:24:29 2013 New Revision: 250562 URL: http://svnweb.freebsd.org/changeset/base/250562 Log: MFC r249795: Add convenience wrapper functions to run callbacks in the context of the USB explore thread. Modified: stable/8/sys/dev/usb/controller/usb_controller.c stable/8/sys/dev/usb/usb_process.h 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/controller/usb_controller.c ============================================================================== --- stable/8/sys/dev/usb/controller/usb_controller.c Sun May 12 12:20:04 2013 (r250561) +++ stable/8/sys/dev/usb/controller/usb_controller.c Sun May 12 12:24:29 2013 (r250562) @@ -877,3 +877,28 @@ usb_bus_mem_free_all(struct usb_bus *bus mtx_destroy(&bus->bus_mtx); } + +/* convenience wrappers */ +void +usb_proc_explore_mwait(struct usb_device *udev, void *pm1, void *pm2) +{ + usb_proc_mwait(&udev->bus->explore_proc, pm1, pm2); +} + +void * +usb_proc_explore_msignal(struct usb_device *udev, void *pm1, void *pm2) +{ + return (usb_proc_msignal(&udev->bus->explore_proc, pm1, pm2)); +} + +void +usb_proc_explore_lock(struct usb_device *udev) +{ + USB_BUS_LOCK(udev->bus); +} + +void +usb_proc_explore_unlock(struct usb_device *udev) +{ + USB_BUS_UNLOCK(udev->bus); +} Modified: stable/8/sys/dev/usb/usb_process.h ============================================================================== --- stable/8/sys/dev/usb/usb_process.h Sun May 12 12:20:04 2013 (r250561) +++ stable/8/sys/dev/usb/usb_process.h Sun May 12 12:24:29 2013 (r250562) @@ -42,6 +42,7 @@ /* structure prototypes */ struct usb_proc_msg; +struct usb_device; /* * The following structure defines the USB process. @@ -79,4 +80,9 @@ void usb_proc_free(struct usb_process *u void *usb_proc_msignal(struct usb_process *up, void *pm0, void *pm1); void usb_proc_rewakeup(struct usb_process *up); +void usb_proc_explore_mwait(struct usb_device *, void *, void *); +void *usb_proc_explore_msignal(struct usb_device *, void *, void *); +void usb_proc_explore_lock(struct usb_device *); +void usb_proc_explore_unlock(struct usb_device *); + #endif /* _USB_PROCESS_H_ */ From owner-svn-src-all@FreeBSD.ORG Sun May 12 12:30:42 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id 71D3CDA3; Sun, 12 May 2013 12:30:42 +0000 (UTC) (envelope-from hselasky@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id 625609A0; Sun, 12 May 2013 12:30:42 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.6/8.14.6) with ESMTP id r4CCUgaO095205; Sun, 12 May 2013 12:30:42 GMT (envelope-from hselasky@svn.freebsd.org) Received: (from hselasky@localhost) by svn.freebsd.org (8.14.6/8.14.5/Submit) id r4CCUg6O095204; Sun, 12 May 2013 12:30:42 GMT (envelope-from hselasky@svn.freebsd.org) Message-Id: <201305121230.r4CCUg6O095204@svn.freebsd.org> From: Hans Petter Selasky Date: Sun, 12 May 2013 12:30:42 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-8@freebsd.org Subject: svn commit: r250563 - stable/8/sys/dev/sound/usb X-SVN-Group: stable-8 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 12 May 2013 12:30:42 -0000 Author: hselasky Date: Sun May 12 12:30:42 2013 New Revision: 250563 URL: http://svnweb.freebsd.org/changeset/base/250563 Log: MFC r249796, r249830, r249844 and r249845: USB audio fixes and improvements. - Fix runtime switching of sample rate - Fix feedback endpoint algorithm Modified: stable/8/sys/dev/sound/usb/uaudio.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/usb/ (props changed) Modified: stable/8/sys/dev/sound/usb/uaudio.c ============================================================================== --- stable/8/sys/dev/sound/usb/uaudio.c Sun May 12 12:24:29 2013 (r250562) +++ stable/8/sys/dev/sound/usb/uaudio.c Sun May 12 12:30:42 2013 (r250563) @@ -73,6 +73,7 @@ __FBSDID("$FreeBSD$"); #include #include #include +#include #define USB_DEBUG_VAR uaudio_debug #include @@ -176,19 +177,34 @@ struct uaudio_mixer_node { struct uaudio_mixer_node *next; }; +struct uaudio_configure_msg { + struct usb_proc_msg hdr; + struct uaudio_softc *sc; +}; + +#define CHAN_MAX_ALT 20 + +struct uaudio_chan_alt { + union uaudio_asf1d p_asf1d; + union uaudio_sed p_sed; + const usb_endpoint_descriptor_audio_t *p_ed1; + const struct uaudio_format *p_fmt; + const struct usb_config *usb_cfg; + uint32_t sample_rate; /* in Hz */ + uint16_t sample_size; + uint8_t iface_index; + uint8_t iface_alt_index; + uint8_t channels; +}; + struct uaudio_chan { struct pcmchan_caps pcm_cap; /* capabilities */ - + struct uaudio_chan_alt usb_alt[CHAN_MAX_ALT]; struct snd_dbuf *pcm_buf; - const struct usb_config *usb_cfg; struct mtx *pcm_mtx; /* lock protecting this structure */ struct uaudio_softc *priv_sc; struct pcm_channel *pcm_ch; struct usb_xfer *xfer[UAUDIO_NCHANBUFS + 1]; - union uaudio_asf1d p_asf1d; - union uaudio_sed p_sed; - const usb_endpoint_descriptor_audio_t *p_ed1; - const struct uaudio_format *p_fmt; uint8_t *buf; /* pointer to buffer */ uint8_t *start; /* upper layer buffer start */ @@ -196,24 +212,24 @@ struct uaudio_chan { uint8_t *cur; /* current position in upper layer * buffer */ - uint32_t intr_size; /* in bytes */ uint32_t intr_frames; /* in units */ - uint32_t sample_rate; uint32_t frames_per_second; uint32_t sample_rem; uint32_t sample_curr; + uint32_t max_buf; - uint32_t format; uint32_t pcm_format[2]; uint16_t bytes_per_frame[2]; - uint16_t sample_size; - - uint8_t valid; - uint8_t iface_index; - uint8_t iface_alt_index; - uint8_t channels; + uint8_t num_alt; + uint8_t cur_alt; + uint8_t set_alt; + uint8_t operation; +#define CHAN_OP_NONE 0 +#define CHAN_OP_START 1 +#define CHAN_OP_STOP 2 +#define CHAN_OP_DRAIN 3 uint8_t last_sync_time; uint8_t last_sync_state; @@ -309,6 +325,7 @@ struct uaudio_softc { struct uaudio_hid sc_hid; struct uaudio_search_result sc_mixer_clocks; struct uaudio_mixer_node sc_mixer_node; + struct uaudio_configure_msg sc_config_msg[2]; struct mtx *sc_mixer_lock; struct snd_mixer *sc_mixer_dev; @@ -434,6 +451,8 @@ static usb_callback_t umidi_bulk_read_ca static usb_callback_t umidi_bulk_write_callback; static usb_callback_t uaudio_hid_rx_callback; +static usb_proc_callback_t uaudio_configure_msg; + /* ==== USB mixer ==== */ static int uaudio_mixer_sysctl_handler(SYSCTL_HANDLER_ARGS); @@ -856,6 +875,10 @@ uaudio_attach(device_t dev) sc->sc_udev = uaa->device; sc->sc_mixer_iface_index = uaa->info.bIfaceIndex; sc->sc_mixer_iface_no = uaa->info.bIfaceNum; + sc->sc_config_msg[0].hdr.pm_callback = &uaudio_configure_msg; + sc->sc_config_msg[0].sc = sc; + sc->sc_config_msg[1].hdr.pm_callback = &uaudio_configure_msg; + sc->sc_config_msg[1].sc = sc; if (usb_test_quirk(uaa, UQ_AUDIO_SWAP_LR)) sc->sc_uq_audio_swap_lr = 1; @@ -900,22 +923,28 @@ uaudio_attach(device_t dev) DPRINTF("%d mixer controls\n", sc->sc_mixer_count); - if (sc->sc_play_chan.valid) { - device_printf(dev, "Play: %d Hz, %d ch, %s format, " - "2x8ms buffer.\n", - sc->sc_play_chan.sample_rate, - sc->sc_play_chan.channels, - sc->sc_play_chan.p_fmt->description); + if (sc->sc_play_chan.num_alt > 0) { + uint8_t x; + for (x = 0; x != sc->sc_play_chan.num_alt; x++) { + device_printf(dev, "Play: %d Hz, %d ch, %s format, " + "2x8ms buffer.\n", + sc->sc_play_chan.usb_alt[x].sample_rate, + sc->sc_play_chan.usb_alt[x].channels, + sc->sc_play_chan.usb_alt[x].p_fmt->description); + } } else { device_printf(dev, "No playback.\n"); } - if (sc->sc_rec_chan.valid) { - device_printf(dev, "Record: %d Hz, %d ch, %s format, " - "2x8ms buffer.\n", - sc->sc_rec_chan.sample_rate, - sc->sc_rec_chan.channels, - sc->sc_rec_chan.p_fmt->description); + if (sc->sc_rec_chan.num_alt > 0) { + uint8_t x; + for (x = 0; x != sc->sc_rec_chan.num_alt; x++) { + device_printf(dev, "Record: %d Hz, %d ch, %s format, " + "2x8ms buffer.\n", + sc->sc_rec_chan.usb_alt[x].sample_rate, + sc->sc_rec_chan.usb_alt[x].channels, + sc->sc_rec_chan.usb_alt[x].p_fmt->description); + } } else { device_printf(dev, "No recording.\n"); } @@ -950,8 +979,8 @@ uaudio_attach(device_t dev) * Only attach a PCM device if we have a playback, recording * or mixer device present: */ - if (sc->sc_play_chan.valid || - sc->sc_rec_chan.valid || + if (sc->sc_play_chan.num_alt > 0 || + sc->sc_rec_chan.num_alt > 0 || sc->sc_mix_info) { child = device_add_child(dev, "pcm", -1); @@ -1020,18 +1049,18 @@ uaudio_attach_sub(device_t dev, kobj_cla snprintf(status, sizeof(status), "at ? %s", PCM_KLDSTRING(snd_uaudio)); if (pcm_register(dev, sc, - sc->sc_play_chan.valid ? 1 : 0, - sc->sc_rec_chan.valid ? 1 : 0)) { + (sc->sc_play_chan.num_alt > 0) ? 1 : 0, + (sc->sc_rec_chan.num_alt > 0) ? 1 : 0)) { goto detach; } uaudio_pcm_setflags(dev, SD_F_MPSAFE); sc->sc_pcm_registered = 1; - if (sc->sc_play_chan.valid) { + if (sc->sc_play_chan.num_alt > 0) { pcm_addchan(dev, PCMDIR_PLAY, chan_class, sc); } - if (sc->sc_rec_chan.valid) { + if (sc->sc_rec_chan.num_alt > 0) { pcm_addchan(dev, PCMDIR_REC, chan_class, sc); } pcm_setstatus(dev, status); @@ -1078,10 +1107,15 @@ uaudio_detach(device_t dev) * will time out and close opened /dev/dspX.Y device(s), if * any. */ - if (sc->sc_play_chan.valid) - usbd_transfer_unsetup(sc->sc_play_chan.xfer, UAUDIO_NCHANBUFS + 1); - if (sc->sc_rec_chan.valid) - usbd_transfer_unsetup(sc->sc_rec_chan.xfer, UAUDIO_NCHANBUFS + 1); + usb_proc_explore_lock(sc->sc_udev); + sc->sc_play_chan.operation = CHAN_OP_DRAIN; + sc->sc_rec_chan.operation = CHAN_OP_DRAIN; + usb_proc_explore_mwait(sc->sc_udev, + &sc->sc_config_msg[0], &sc->sc_config_msg[1]); + usb_proc_explore_unlock(sc->sc_udev); + + usbd_transfer_unsetup(sc->sc_play_chan.xfer, UAUDIO_NCHANBUFS + 1); + usbd_transfer_unsetup(sc->sc_rec_chan.xfer, UAUDIO_NCHANBUFS + 1); uaudio_hid_detach(sc); @@ -1100,6 +1134,201 @@ uaudio_detach(device_t dev) return (0); } +static uint32_t +uaudio_get_buffer_size(struct uaudio_chan *ch, uint8_t alt) +{ + struct uaudio_chan_alt *chan_alt = &ch->usb_alt[alt]; + /* We use 2 times 8ms of buffer */ + uint32_t buf_size = (((chan_alt->sample_rate * (UAUDIO_NFRAMES / 8)) + + 1000 - 1) / 1000) * chan_alt->sample_size; + return (buf_size); +} + +static void +uaudio_configure_msg_sub(struct uaudio_softc *sc, + struct uaudio_chan *chan, int dir) +{ + struct uaudio_chan_alt *chan_alt; + uint32_t frames; + uint32_t buf_size; + uint16_t fps; + uint8_t set_alt; + uint8_t fps_shift; + uint8_t operation; + usb_error_t err; + + if (chan->num_alt <= 0) + return; + + DPRINTF("\n"); + + usb_proc_explore_lock(sc->sc_udev); + operation = chan->operation; + chan->operation = CHAN_OP_NONE; + usb_proc_explore_unlock(sc->sc_udev); + + mtx_lock(chan->pcm_mtx); + if (chan->cur_alt != chan->set_alt) + set_alt = chan->set_alt; + else + set_alt = CHAN_MAX_ALT; + mtx_unlock(chan->pcm_mtx); + + if (set_alt >= chan->num_alt) + goto done; + + chan_alt = chan->usb_alt + set_alt; + + usbd_transfer_unsetup(chan->xfer, UAUDIO_NCHANBUFS + 1); + + err = usbd_set_alt_interface_index(sc->sc_udev, + chan_alt->iface_index, chan_alt->iface_alt_index); + if (err) { + DPRINTF("setting of alternate index failed: %s!\n", + usbd_errstr(err)); + goto error; + } + + /* + * Only set the sample rate if the channel reports that it + * supports the frequency control. + */ + + if (sc->sc_audio_rev >= UAUDIO_VERSION_30) { + /* FALLTHROUGH */ + } else if (sc->sc_audio_rev >= UAUDIO_VERSION_20) { + unsigned int x; + + for (x = 0; x != 256; x++) { + if (dir == PCMDIR_PLAY) { + if (!(sc->sc_mixer_clocks.bit_output[x / 8] & + (1 << (x % 8)))) { + continue; + } + } else { + if (!(sc->sc_mixer_clocks.bit_input[x / 8] & + (1 << (x % 8)))) { + continue; + } + } + + if (uaudio20_set_speed(sc->sc_udev, + sc->sc_mixer_iface_no, x, chan_alt->sample_rate)) { + /* + * If the endpoint is adaptive setting + * the speed may fail. + */ + DPRINTF("setting of sample rate failed! " + "(continuing anyway)\n"); + } + } + } else if (chan_alt->p_sed.v1->bmAttributes & UA_SED_FREQ_CONTROL) { + if (uaudio_set_speed(sc->sc_udev, + chan_alt->p_ed1->bEndpointAddress, chan_alt->sample_rate)) { + /* + * If the endpoint is adaptive setting the + * speed may fail. + */ + DPRINTF("setting of sample rate failed! " + "(continuing anyway)\n"); + } + } + if (usbd_transfer_setup(sc->sc_udev, &chan_alt->iface_index, chan->xfer, + chan_alt->usb_cfg, UAUDIO_NCHANBUFS + 1, chan, chan->pcm_mtx)) { + DPRINTF("could not allocate USB transfers!\n"); + goto error; + } + + fps = usbd_get_isoc_fps(sc->sc_udev); + + if (fps < 8000) { + /* FULL speed USB */ + frames = 8; + } else { + /* HIGH speed USB */ + frames = UAUDIO_NFRAMES; + } + + fps_shift = usbd_xfer_get_fps_shift(chan->xfer[0]); + + /* down shift number of frames per second, if any */ + fps >>= fps_shift; + frames >>= fps_shift; + + /* bytes per frame should not be zero */ + chan->bytes_per_frame[0] = + ((chan_alt->sample_rate / fps) * chan_alt->sample_size); + chan->bytes_per_frame[1] = + (((chan_alt->sample_rate + fps - 1) / fps) * chan_alt->sample_size); + + /* setup data rate dithering, if any */ + chan->frames_per_second = fps; + chan->sample_rem = chan_alt->sample_rate % fps; + chan->sample_curr = 0; + chan->frames_per_second = fps; + + /* compute required buffer size */ + buf_size = (chan->bytes_per_frame[1] * frames); + + if (buf_size > (chan->end - chan->start)) { + DPRINTF("buffer size is too big\n"); + goto error; + } + + chan->intr_frames = frames; + + DPRINTF("fps=%d sample_rem=%d\n", (int)fps, (int)chan->sample_rem); + + if (chan->intr_frames == 0) { + DPRINTF("frame shift is too high!\n"); + goto error; + } + + mtx_lock(chan->pcm_mtx); + chan->cur_alt = set_alt; + mtx_unlock(chan->pcm_mtx); + +done: +#if (UAUDIO_NCHANBUFS != 2) +#error "please update code" +#endif + switch (operation) { + case CHAN_OP_START: + mtx_lock(chan->pcm_mtx); + usbd_transfer_start(chan->xfer[0]); + usbd_transfer_start(chan->xfer[1]); + mtx_unlock(chan->pcm_mtx); + break; + case CHAN_OP_STOP: + mtx_lock(chan->pcm_mtx); + usbd_transfer_stop(chan->xfer[0]); + usbd_transfer_stop(chan->xfer[1]); + mtx_unlock(chan->pcm_mtx); + break; + default: + break; + } + return; + +error: + usbd_transfer_unsetup(chan->xfer, UAUDIO_NCHANBUFS + 1); + + mtx_lock(chan->pcm_mtx); + chan->cur_alt = CHAN_MAX_ALT; + mtx_unlock(chan->pcm_mtx); +} + +static void +uaudio_configure_msg(struct usb_proc_msg *pm) +{ + struct uaudio_softc *sc = ((struct uaudio_configure_msg *)pm)->sc; + + usb_proc_explore_unlock(sc->sc_udev); + uaudio_configure_msg_sub(sc, &sc->sc_play_chan, PCMDIR_PLAY); + uaudio_configure_msg_sub(sc, &sc->sc_rec_chan, PCMDIR_REC); + usb_proc_explore_lock(sc->sc_udev); +} + /*========================================================================* * AS - Audio Stream - routines *========================================================================*/ @@ -1237,6 +1466,8 @@ uaudio_chan_fill_info_sub(struct uaudio_ struct usb_interface_descriptor *id; const struct uaudio_format *p_fmt = NULL; struct uaudio_chan *chan; + struct uaudio_chan_alt *chan_alt; + uint32_t format; uint16_t curidx = 0xFFFF; uint16_t lastidx = 0xFFFF; uint16_t alt_index = 0; @@ -1414,6 +1645,10 @@ uaudio_chan_fill_info_sub(struct uaudio_ bBitResolution = asf1d.v2->bBitResolution; bSubslotSize = asf1d.v2->bSubslotSize; + /* Map 4-byte aligned 24-bit samples into 32-bit */ + if (bBitResolution == 24 && bSubslotSize == 4) + bBitResolution = 32; + if (bBitResolution != (bSubslotSize * 8)) { DPRINTF("Invalid bSubslotSize\n"); goto next_ep; @@ -1508,14 +1743,19 @@ uaudio_chan_fill_info_sub(struct uaudio_ chan = (ep_dir == UE_DIR_IN) ? &sc->sc_rec_chan : &sc->sc_play_chan; - if (chan->valid != 0 || - usbd_get_iface(udev, curidx) == NULL) { - DPRINTF("Channel already exists or " - "interface is not valid\n"); + if (usbd_get_iface(udev, curidx) == NULL) { + DPRINTF("Interface is not valid\n"); goto next_ep; } + if (chan->num_alt == CHAN_MAX_ALT) { + DPRINTF("Too many alternate settings\n"); + goto next_ep; + } + chan->set_alt = 0; + chan->cur_alt = CHAN_MAX_ALT; + + chan_alt = &chan->usb_alt[chan->num_alt++]; - chan->valid = 1; #ifdef USB_DEBUG uaudio_chan_dump_ep_desc(ed1); #endif @@ -1523,30 +1763,81 @@ uaudio_chan_fill_info_sub(struct uaudio_ "bits = %d, format = %s\n", rate, channels, bit_resolution, p_fmt->description); - chan->sample_rate = rate; - chan->p_asf1d = asf1d; - chan->p_ed1 = ed1; - chan->p_fmt = p_fmt; - chan->p_sed = sed; - chan->iface_index = curidx; - chan->iface_alt_index = alt_index; + chan_alt->sample_rate = rate; + chan_alt->p_asf1d = asf1d; + chan_alt->p_ed1 = ed1; + chan_alt->p_fmt = p_fmt; + chan_alt->p_sed = sed; + chan_alt->iface_index = curidx; + chan_alt->iface_alt_index = alt_index; + + usbd_set_parent_iface(sc->sc_udev, curidx, + sc->sc_mixer_iface_index); if (ep_dir == UE_DIR_IN) - chan->usb_cfg = uaudio_cfg_record; + chan_alt->usb_cfg = uaudio_cfg_record; else - chan->usb_cfg = uaudio_cfg_play; + chan_alt->usb_cfg = uaudio_cfg_play; - chan->sample_size = (UAUDIO_MAX_CHAN(channels) * + chan_alt->sample_size = (UAUDIO_MAX_CHAN(channels) * p_fmt->bPrecision) / 8; - chan->channels = channels; + chan_alt->channels = channels; if (ep_dir == UE_DIR_IN && usbd_get_speed(udev) == USB_SPEED_FULL) { uaudio_record_fix_fs(ed1, - chan->sample_size * (rate / 1000), - chan->sample_size * (rate / 4000)); + chan_alt->sample_size * (rate / 1000), + chan_alt->sample_size * (rate / 4000)); } + /* setup play/record format */ + + format = chan_alt->p_fmt->freebsd_fmt; + + switch (chan_alt->channels) { + case 2: + /* stereo */ + format = SND_FORMAT(format, 2, 0); + break; + case 1: + /* mono */ + format = SND_FORMAT(format, 1, 0); + break; + default: + /* surround and more */ + format = feeder_matrix_default_format( + SND_FORMAT(format, chan_alt->channels, 0)); + break; + } + + /* check if format is not supported */ + if (format == 0) { + DPRINTF("The selected audio format is not supported\n"); + chan->num_alt--; + goto next_ep; + } + if (chan->num_alt > 1) { + /* we only accumulate one format at different sample rates */ + if (chan->pcm_format[0] != format) { + DPRINTF("Multiple formats is not supported\n"); + chan->num_alt--; + goto next_ep; + } + /* ignore if duplicate sample rate entry */ + if (rate == chan->usb_alt[chan->num_alt - 2].sample_rate) { + DPRINTF("Duplicate sample rate detected\n"); + chan->num_alt--; + goto next_ep; + } + } + chan->pcm_cap.fmtlist = chan->pcm_format; + chan->pcm_cap.fmtlist[0] = format; + + if (rate < chan->pcm_cap.minspeed || chan->pcm_cap.minspeed == 0) + chan->pcm_cap.minspeed = rate; + if (rate > chan->pcm_cap.maxspeed || chan->pcm_cap.maxspeed == 0) + chan->pcm_cap.maxspeed = rate; + if (sc->sc_sndstat_valid != 0) { sbuf_printf(&sc->sc_sndstat, "\n\t" "mode %d.%d:(%s) %dch, %dbit, %s, %dHz", @@ -1564,8 +1855,9 @@ uaudio_chan_fill_info_sub(struct uaudio_ /* This structure defines all the supported rates. */ -static const uint32_t uaudio_rate_list[] = { +static const uint32_t uaudio_rate_list[CHAN_MAX_ALT] = { 96000, + 88200, 88000, 80000, 72000, @@ -1630,21 +1922,12 @@ uaudio_chan_fill_info(struct uaudio_soft uaudio_chan_fill_info_sub(sc, udev, rate, x, y); /* try find a matching rate, if any */ - for (z = 0; uaudio_rate_list[z]; z++) { + for (z = 0; uaudio_rate_list[z]; z++) uaudio_chan_fill_info_sub(sc, udev, uaudio_rate_list[z], x, y); - - if (sc->sc_rec_chan.valid && - sc->sc_play_chan.valid) { - goto done; - } - } } } - -done: - if (sc->sc_sndstat_valid) { + if (sc->sc_sndstat_valid) sbuf_finish(&sc->sc_sndstat); - } } static void @@ -1652,6 +1935,7 @@ uaudio_chan_play_sync_callback(struct us { struct uaudio_chan *ch = usbd_xfer_softc(xfer); struct usb_page_cache *pc; + uint64_t sample_rate = ch->usb_alt[ch->cur_alt].sample_rate; uint8_t buf[4]; uint64_t temp; int len; @@ -1698,24 +1982,20 @@ uaudio_chan_play_sync_callback(struct us /* auto adjust */ - while (temp < (ch->sample_rate - (ch->sample_rate / 4))) + while (temp < (sample_rate - (sample_rate / 4))) temp *= 2; - while (temp > (ch->sample_rate + (ch->sample_rate / 2))) + while (temp > (sample_rate + (sample_rate / 2))) temp /= 2; - /* bias */ - - temp += (ch->sample_rate + 1999) / 2000; - /* compare */ DPRINTF("Comparing %d < %d\n", - (int)temp, (int)ch->sample_rate); + (int)temp, (int)sample_rate); - if (temp == ch->sample_rate) + if (temp == sample_rate) ch->last_sync_state = UAUDIO_SYNC_NONE; - else if (temp > ch->sample_rate) + else if (temp > sample_rate) ch->last_sync_state = UAUDIO_SYNC_MORE; else ch->last_sync_state = UAUDIO_SYNC_LESS; @@ -1737,6 +2017,7 @@ uaudio_chan_play_callback(struct usb_xfe { struct uaudio_chan *ch = usbd_xfer_softc(xfer); struct usb_page_cache *pc; + uint32_t sample_size = ch->usb_alt[ch->cur_alt].sample_size; uint32_t mfl; uint32_t total; uint32_t blockcount; @@ -1800,14 +2081,14 @@ tr_transferred: switch (ch->last_sync_state) { case UAUDIO_SYNC_MORE: DPRINTFN(6, "sending one sample more\n"); - if ((frame_len + ch->sample_size) <= mfl) - frame_len += ch->sample_size; + if ((frame_len + sample_size) <= mfl) + frame_len += sample_size; ch->last_sync_state = UAUDIO_SYNC_NONE; break; case UAUDIO_SYNC_LESS: DPRINTFN(6, "sending one sample less\n"); - if (frame_len >= ch->sample_size) - frame_len -= ch->sample_size; + if (frame_len >= sample_size) + frame_len -= sample_size; ch->last_sync_state = UAUDIO_SYNC_NONE; break; default: @@ -1944,187 +2225,43 @@ uaudio_chan_init(struct uaudio_softc *sc struct uaudio_chan *ch = ((dir == PCMDIR_PLAY) ? &sc->sc_play_chan : &sc->sc_rec_chan); uint32_t buf_size; - uint32_t frames; - uint32_t format; - uint16_t fps; - uint8_t endpoint; - uint8_t blocks; - uint8_t iface_index; - uint8_t alt_index; - uint8_t fps_shift; - usb_error_t err; - - fps = usbd_get_isoc_fps(sc->sc_udev); - - if (fps < 8000) { - /* FULL speed USB */ - frames = 8; - } else { - /* HIGH speed USB */ - frames = UAUDIO_NFRAMES; - } - - /* setup play/record format */ - - ch->pcm_cap.fmtlist = ch->pcm_format; - - ch->pcm_format[0] = 0; - ch->pcm_format[1] = 0; - - ch->pcm_cap.minspeed = ch->sample_rate; - ch->pcm_cap.maxspeed = ch->sample_rate; + uint8_t x; - /* setup mutex and PCM channel */ + /* store mutex and PCM channel */ ch->pcm_ch = c; ch->pcm_mtx = c->lock; - format = ch->p_fmt->freebsd_fmt; - - switch (ch->channels) { - case 2: - /* stereo */ - format = SND_FORMAT(format, 2, 0); - break; - case 1: - /* mono */ - format = SND_FORMAT(format, 1, 0); - break; - default: - /* surround and more */ - format = feeder_matrix_default_format( - SND_FORMAT(format, ch->channels, 0)); - break; - } - - ch->pcm_cap.fmtlist[0] = format; - ch->pcm_cap.fmtlist[1] = 0; - - /* check if format is not supported */ - - if (format == 0) { - DPRINTF("The selected audio format is not supported\n"); - goto error; - } - - /* set alternate interface corresponding to the mode */ - - endpoint = ch->p_ed1->bEndpointAddress; - iface_index = ch->iface_index; - alt_index = ch->iface_alt_index; - - DPRINTF("endpoint=0x%02x, speed=%d, iface=%d alt=%d\n", - endpoint, ch->sample_rate, iface_index, alt_index); + /* compute worst case buffer */ - err = usbd_set_alt_interface_index(sc->sc_udev, iface_index, alt_index); - if (err) { - DPRINTF("setting of alternate index failed: %s!\n", - usbd_errstr(err)); - goto error; + buf_size = 0; + for (x = 0; x != ch->num_alt; x++) { + uint32_t temp = uaudio_get_buffer_size(ch, x); + if (temp > buf_size) + buf_size = temp; } - usbd_set_parent_iface(sc->sc_udev, iface_index, - sc->sc_mixer_iface_index); - - /* - * Only set the sample rate if the channel reports that it - * supports the frequency control. - */ - if (sc->sc_audio_rev >= UAUDIO_VERSION_30) { - /* FALLTHROUGH */ - } else if (sc->sc_audio_rev >= UAUDIO_VERSION_20) { - unsigned int x; - - for (x = 0; x != 256; x++) { - if (dir == PCMDIR_PLAY) { - if (!(sc->sc_mixer_clocks.bit_output[x / 8] & - (1 << (x % 8)))) { - continue; - } - } else { - if (!(sc->sc_mixer_clocks.bit_input[x / 8] & - (1 << (x % 8)))) { - continue; - } - } - - if (uaudio20_set_speed(sc->sc_udev, - sc->sc_mixer_iface_no, x, ch->sample_rate)) { - /* - * If the endpoint is adaptive setting - * the speed may fail. - */ - DPRINTF("setting of sample rate failed! " - "(continuing anyway)\n"); - } - } - } else if (ch->p_sed.v1->bmAttributes & UA_SED_FREQ_CONTROL) { - if (uaudio_set_speed(sc->sc_udev, endpoint, ch->sample_rate)) { - /* - * If the endpoint is adaptive setting the - * speed may fail. - */ - DPRINTF("setting of sample rate failed! " - "(continuing anyway)\n"); - } - } - if (usbd_transfer_setup(sc->sc_udev, &iface_index, ch->xfer, - ch->usb_cfg, UAUDIO_NCHANBUFS + 1, ch, ch->pcm_mtx)) { - DPRINTF("could not allocate USB transfers!\n"); - goto error; - } - - fps_shift = usbd_xfer_get_fps_shift(ch->xfer[0]); - - /* down shift number of frames per second, if any */ - fps >>= fps_shift; - frames >>= fps_shift; - - /* bytes per frame should not be zero */ - ch->bytes_per_frame[0] = ((ch->sample_rate / fps) * ch->sample_size); - ch->bytes_per_frame[1] = (((ch->sample_rate + fps - 1) / fps) * ch->sample_size); - - /* setup data rate dithering, if any */ - ch->frames_per_second = fps; - ch->sample_rem = ch->sample_rate % fps; - ch->sample_curr = 0; - ch->frames_per_second = fps; - - /* compute required buffer size */ - buf_size = (ch->bytes_per_frame[1] * frames); - - ch->intr_size = buf_size; - ch->intr_frames = frames; - - DPRINTF("fps=%d sample_rem=%d\n", fps, ch->sample_rem); - - if (ch->intr_frames == 0) { - DPRINTF("frame shift is too high!\n"); - goto error; - } - - /* setup double buffering */ + /* allow double buffering */ buf_size *= 2; - blocks = 2; + + DPRINTF("Worst case buffer is %d bytes\n", (int)buf_size); ch->buf = malloc(buf_size, M_DEVBUF, M_WAITOK | M_ZERO); if (ch->buf == NULL) goto error; if (sndbuf_setup(b, ch->buf, buf_size) != 0) goto error; - if (sndbuf_resize(b, blocks, ch->intr_size)) - goto error; ch->start = ch->buf; ch->end = ch->buf + buf_size; ch->cur = ch->buf; ch->pcm_buf = b; + ch->max_buf = buf_size; if (ch->pcm_mtx == NULL) { DPRINTF("ERROR: PCM channels does not have a mutex!\n"); goto error; } - return (ch); error: @@ -2141,7 +2278,7 @@ uaudio_chan_free(struct uaudio_chan *ch) } usbd_transfer_unsetup(ch->xfer, UAUDIO_NCHANBUFS + 1); - ch->valid = 0; + ch->num_alt = 0; return (0); } @@ -2149,7 +2286,15 @@ uaudio_chan_free(struct uaudio_chan *ch) int uaudio_chan_set_param_blocksize(struct uaudio_chan *ch, uint32_t blocksize) { - return (ch->intr_size); + uint32_t temp = 2 * uaudio_get_buffer_size(ch, ch->set_alt); + + sndbuf_setup(ch->pcm_buf, ch->buf, temp); + + ch->start = ch->buf; + ch->end = ch->buf + temp; + ch->cur = ch->buf; + + return (temp / 2); } int @@ -2162,10 +2307,23 @@ uaudio_chan_set_param_fragments(struct u int uaudio_chan_set_param_speed(struct uaudio_chan *ch, uint32_t speed) { - if (speed != ch->sample_rate) { - DPRINTF("rate conversion required\n"); + uint8_t x; + + for (x = 0; x < ch->num_alt; x++) { + if (ch->usb_alt[x].sample_rate < speed) { + /* sample rate is too low */ + break; + } } - return (ch->sample_rate); + + if (x != 0) + x--; + + ch->set_alt = x; + + DPRINTF("Selecting alt %d\n", (int)x); + + return (ch->usb_alt[x].sample_rate); } int @@ -2228,31 +2386,61 @@ uaudio_chan_getmatrix(struct uaudio_chan int uaudio_chan_set_param_format(struct uaudio_chan *ch, uint32_t format) { - ch->format = format; + DPRINTF("Selecting format 0x%08x\n", (unsigned int)format); return (0); } int uaudio_chan_start(struct uaudio_chan *ch) { - ch->cur = ch->start; + struct uaudio_softc *sc = ch->priv_sc; + int do_start = 0; -#if (UAUDIO_NCHANBUFS != 2) -#error "please update code" -#endif - usbd_transfer_start(ch->xfer[0]); - usbd_transfer_start(ch->xfer[1]); + usb_proc_explore_lock(sc->sc_udev); + if (ch->operation != CHAN_OP_DRAIN) { + if (ch->cur_alt == ch->set_alt && + ch->operation == CHAN_OP_NONE) { + /* save doing the explore task */ + do_start = 1; + } else { + ch->operation = CHAN_OP_START; + (void)usb_proc_explore_msignal(sc->sc_udev, + &sc->sc_config_msg[0], &sc->sc_config_msg[1]); + } + } + usb_proc_explore_unlock(sc->sc_udev); + + if (do_start) { + usbd_transfer_start(ch->xfer[0]); + usbd_transfer_start(ch->xfer[1]); + } return (0); } int uaudio_chan_stop(struct uaudio_chan *ch) { -#if (UAUDIO_NCHANBUFS != 2) -#error "please update code" -#endif - usbd_transfer_stop(ch->xfer[0]); - usbd_transfer_stop(ch->xfer[1]); + struct uaudio_softc *sc = ch->priv_sc; + int do_stop = 0; + + usb_proc_explore_lock(sc->sc_udev); + if (ch->operation != CHAN_OP_DRAIN) { + if (ch->cur_alt == ch->set_alt && + ch->operation == CHAN_OP_NONE) { + /* save doing the explore task */ + do_stop = 1; + } else { + ch->operation = CHAN_OP_STOP; + (void)usb_proc_explore_msignal(sc->sc_udev, + &sc->sc_config_msg[0], &sc->sc_config_msg[1]); + } + } + usb_proc_explore_unlock(sc->sc_udev); + + if (do_stop) { + usbd_transfer_stop(ch->xfer[0]); + usbd_transfer_stop(ch->xfer[1]); + } return (0); } From owner-svn-src-all@FreeBSD.ORG Sun May 12 13:42:50 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id 3BA9FF5A; Sun, 12 May 2013 13:42:50 +0000 (UTC) (envelope-from trociny@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id 2E6BEC2F; Sun, 12 May 2013 13:42:50 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.6/8.14.6) with ESMTP id r4CDgowE020381; Sun, 12 May 2013 13:42:50 GMT (envelope-from trociny@svn.freebsd.org) Received: (from trociny@localhost) by svn.freebsd.org (8.14.6/8.14.5/Submit) id r4CDgon5020380; Sun, 12 May 2013 13:42:50 GMT (envelope-from trociny@svn.freebsd.org) Message-Id: <201305121342.r4CDgon5020380@svn.freebsd.org> From: Mikolaj Golub Date: Sun, 12 May 2013 13:42:50 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r250564 - head/usr.sbin/bsnmpd/modules X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 12 May 2013 13:42:50 -0000 Author: trociny Date: Sun May 12 13:42:49 2013 New Revision: 250564 URL: http://svnweb.freebsd.org/changeset/base/250564 Log: Revert r250394, which disabled snmp_hast due to libl dependency issue -- the dependency has been removed in r250503. Modified: head/usr.sbin/bsnmpd/modules/Makefile Modified: head/usr.sbin/bsnmpd/modules/Makefile ============================================================================== --- head/usr.sbin/bsnmpd/modules/Makefile Sun May 12 12:30:42 2013 (r250563) +++ head/usr.sbin/bsnmpd/modules/Makefile Sun May 12 13:42:49 2013 (r250564) @@ -10,6 +10,7 @@ _snmp_atm= snmp_atm SUBDIR= ${_snmp_atm} \ snmp_bridge \ + snmp_hast \ snmp_hostres \ snmp_mibII \ snmp_pf \ From owner-svn-src-all@FreeBSD.ORG Sun May 12 15:24:00 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id 11FE7989; Sun, 12 May 2013 15:24:00 +0000 (UTC) (envelope-from eadler@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id DDFF7F84; Sun, 12 May 2013 15:23:59 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.6/8.14.6) with ESMTP id r4CFNxID055569; Sun, 12 May 2013 15:23:59 GMT (envelope-from eadler@svn.freebsd.org) Received: (from eadler@localhost) by svn.freebsd.org (8.14.6/8.14.5/Submit) id r4CFNxBR055568; Sun, 12 May 2013 15:23:59 GMT (envelope-from eadler@svn.freebsd.org) Message-Id: <201305121523.r4CFNxBR055568@svn.freebsd.org> From: Eitan Adler Date: Sun, 12 May 2013 15:23:59 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r250565 - head/etc X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 12 May 2013 15:24:00 -0000 Author: eadler Date: Sun May 12 15:23:59 2013 New Revision: 250565 URL: http://svnweb.freebsd.org/changeset/base/250565 Log: Make newsyslog compress logs with xz instead of bzip2 to save space. PR: conf/178504 Submitted by: ak Reviewed by: smh Modified: head/etc/newsyslog.conf Modified: head/etc/newsyslog.conf ============================================================================== --- head/etc/newsyslog.conf Sun May 12 13:42:49 2013 (r250564) +++ head/etc/newsyslog.conf Sun May 12 15:23:59 2013 (r250565) @@ -17,23 +17,23 @@ # future, these defaults may change to more conservative ones. # # logfilename [owner:group] mode count size when flags [/pid_file] [sig_num] -/var/log/all.log 600 7 * @T00 J -/var/log/amd.log 644 7 100 * J -/var/log/auth.log 600 7 100 @0101T JC -/var/log/console.log 600 5 100 * J -/var/log/cron 600 3 100 * JC -/var/log/daily.log 640 7 * @T00 JN -/var/log/debug.log 600 7 100 * JC -/var/log/init.log 644 3 100 * J -/var/log/kerberos.log 600 7 100 * J -/var/log/lpd-errs 644 7 100 * JC -/var/log/maillog 640 7 * @T00 JC -/var/log/messages 644 5 100 @0101T JC -/var/log/monthly.log 640 12 * $M1D0 JN -/var/log/pflog 600 3 100 * JB /var/run/pflogd.pid -/var/log/ppp.log root:network 640 3 100 * JC -/var/log/security 600 10 100 * JC +/var/log/all.log 600 7 * @T00 X +/var/log/amd.log 644 7 100 * X +/var/log/auth.log 600 7 100 @0101T XC +/var/log/console.log 600 5 100 * X +/var/log/cron 600 3 100 * XC +/var/log/daily.log 640 7 * @T00 XN +/var/log/debug.log 600 7 100 * XC +/var/log/init.log 644 3 100 * X +/var/log/kerberos.log 600 7 100 * X +/var/log/lpd-errs 644 7 100 * XC +/var/log/maillog 640 7 * @T00 XC +/var/log/messages 644 5 100 @0101T XC +/var/log/monthly.log 640 12 * $M1D0 XN +/var/log/pflog 600 3 100 * XB /var/run/pflogd.pid +/var/log/ppp.log root:network 640 3 100 * XC +/var/log/security 600 10 100 * XC /var/log/sendmail.st 640 10 * 168 BN /var/log/utx.log 644 3 * @01T05 B -/var/log/weekly.log 640 5 * $W6D0 JN -/var/log/xferlog 600 7 100 * JC +/var/log/weekly.log 640 5 * $W6D0 XN +/var/log/xferlog 600 7 100 * XC From owner-svn-src-all@FreeBSD.ORG Sun May 12 15:29:36 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id 337C2C08; Sun, 12 May 2013 15:29:36 +0000 (UTC) (envelope-from pfg@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id 1586FFC5; Sun, 12 May 2013 15:29:36 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.6/8.14.6) with ESMTP id r4CFTZIg056589; Sun, 12 May 2013 15:29:35 GMT (envelope-from pfg@svn.freebsd.org) Received: (from pfg@localhost) by svn.freebsd.org (8.14.6/8.14.5/Submit) id r4CFTZ0w056586; Sun, 12 May 2013 15:29:35 GMT (envelope-from pfg@svn.freebsd.org) Message-Id: <201305121529.r4CFTZ0w056586@svn.freebsd.org> From: "Pedro F. Giffuni" Date: Sun, 12 May 2013 15:29:35 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r250566 - in head/contrib: gcc gcclibs/libcpp gcclibs/libcpp/include X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 12 May 2013 15:29:36 -0000 Author: pfg Date: Sun May 12 15:29:35 2013 New Revision: 250566 URL: http://svnweb.freebsd.org/changeset/base/250566 Log: Add support for "d" floating-point suffix, as defined by draft N1312 of TR 24732. Emit pedantic warning if the feature is being used. Should solve GCC bug 39027. Obtained from: OpenBSD MFC after: 2 weeks Modified: head/contrib/gcc/c-lex.c head/contrib/gcclibs/libcpp/expr.c head/contrib/gcclibs/libcpp/include/cpplib.h Modified: head/contrib/gcc/c-lex.c ============================================================================== --- head/contrib/gcc/c-lex.c Sun May 12 15:23:59 2013 (r250565) +++ head/contrib/gcc/c-lex.c Sun May 12 15:29:35 2013 (r250566) @@ -640,6 +640,13 @@ interpret_float (const cpp_token *token, char *copy; size_t copylen; + /* Default (no suffix) is double. */ + if (flags & CPP_N_DEFAULT) + { + flags ^= CPP_N_DEFAULT; + flags |= CPP_N_MEDIUM; + } + /* Decode type based on width and properties. */ if (flags & CPP_N_DFLOAT) if ((flags & CPP_N_WIDTH) == CPP_N_LARGE) Modified: head/contrib/gcclibs/libcpp/expr.c ============================================================================== --- head/contrib/gcclibs/libcpp/expr.c Sun May 12 15:23:59 2013 (r250565) +++ head/contrib/gcclibs/libcpp/expr.c Sun May 12 15:29:35 2013 (r250566) @@ -82,7 +82,7 @@ static void check_promotion (cpp_reader static unsigned int interpret_float_suffix (const uchar *s, size_t len) { - size_t f = 0, l = 0, i = 0, d = 0; + size_t f = 0, l = 0, i = 0, d = 0, d0 = 0; while (len--) switch (s[len]) @@ -101,7 +101,12 @@ interpret_float_suffix (const uchar *s, return 0; } - if (f + l > 1 || i > 1) + if (d == 1 && !f && !l) { + d = 0; + d0 = 1; + } + + if (f + d0 + l > 1 || i > 1) return 0; /* Allow dd, df, dl suffixes for decimal float constants. */ @@ -110,7 +115,8 @@ interpret_float_suffix (const uchar *s, return ((i ? CPP_N_IMAGINARY : 0) | (f ? CPP_N_SMALL : - l ? CPP_N_LARGE : CPP_N_MEDIUM) + d0 ? CPP_N_MEDIUM : + l ? CPP_N_LARGE : CPP_N_DEFAULT) | (d ? CPP_N_DFLOAT : 0)); } @@ -261,6 +267,13 @@ cpp_classify_number (cpp_reader *pfile, "traditional C rejects the \"%.*s\" suffix", (int) (limit - str), str); + /* A suffix for double is a GCC extension via decimal float support. + If the suffix also specifies an imaginary value we'll catch that + later. */ + if ((result == CPP_N_MEDIUM) && CPP_PEDANTIC (pfile)) + cpp_error (pfile, CPP_DL_PEDWARN, + "suffix for double constant is a GCC extension"); + /* Radix must be 10 for decimal floats. */ if ((result & CPP_N_DFLOAT) && radix != 10) { Modified: head/contrib/gcclibs/libcpp/include/cpplib.h ============================================================================== --- head/contrib/gcclibs/libcpp/include/cpplib.h Sun May 12 15:23:59 2013 (r250565) +++ head/contrib/gcclibs/libcpp/include/cpplib.h Sun May 12 15:29:35 2013 (r250566) @@ -749,6 +749,7 @@ struct cpp_num #define CPP_N_UNSIGNED 0x1000 /* Properties. */ #define CPP_N_IMAGINARY 0x2000 #define CPP_N_DFLOAT 0x4000 +#define CPP_N_DEFAULT 0x8000 /* Classify a CPP_NUMBER token. The return value is a combination of the flags from the above sets. */ From owner-svn-src-all@FreeBSD.ORG Sun May 12 15:44:50 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id 487D0D8; Sun, 12 May 2013 15:44:50 +0000 (UTC) (envelope-from jilles@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id 392BDA6; Sun, 12 May 2013 15:44:50 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.6/8.14.6) with ESMTP id r4CFioFV062699; Sun, 12 May 2013 15:44:50 GMT (envelope-from jilles@svn.freebsd.org) Received: (from jilles@localhost) by svn.freebsd.org (8.14.6/8.14.5/Submit) id r4CFioFG062698; Sun, 12 May 2013 15:44:50 GMT (envelope-from jilles@svn.freebsd.org) Message-Id: <201305121544.r4CFioFG062698@svn.freebsd.org> From: Jilles Tjoelker Date: Sun, 12 May 2013 15:44:50 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r250567 - head/sys/fs/fdescfs X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 12 May 2013 15:44:50 -0000 Author: jilles Date: Sun May 12 15:44:49 2013 New Revision: 250567 URL: http://svnweb.freebsd.org/changeset/base/250567 Log: fdescfs: Supply a real value for d_type in readdir. All the fdescfs nodes (except . and ..) appear as character devices to stat(), so DT_CHR is correct. Modified: head/sys/fs/fdescfs/fdesc_vnops.c Modified: head/sys/fs/fdescfs/fdesc_vnops.c ============================================================================== --- head/sys/fs/fdescfs/fdesc_vnops.c Sun May 12 15:29:35 2013 (r250566) +++ head/sys/fs/fdescfs/fdesc_vnops.c Sun May 12 15:44:49 2013 (r250567) @@ -538,7 +538,7 @@ fdesc_readdir(ap) break; dp->d_namlen = sprintf(dp->d_name, "%d", fcnt); dp->d_reclen = UIO_MX; - dp->d_type = DT_UNKNOWN; + dp->d_type = DT_CHR; dp->d_fileno = i + FD_DESC; break; } From owner-svn-src-all@FreeBSD.ORG Sun May 12 15:54:14 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id 8E3B44EF; Sun, 12 May 2013 15:54:14 +0000 (UTC) (envelope-from marck@rinet.ru) Received: from woozle.rinet.ru (woozle.rinet.ru [195.54.192.68]) by mx1.freebsd.org (Postfix) with ESMTP id 20709F1; Sun, 12 May 2013 15:54:12 +0000 (UTC) Received: from localhost (localhost [127.0.0.1]) by woozle.rinet.ru (8.14.5/8.14.5) with ESMTP id r4CFsBBc059536; Sun, 12 May 2013 19:54:11 +0400 (MSK) (envelope-from marck@rinet.ru) Date: Sun, 12 May 2013 19:54:11 +0400 (MSK) From: Dmitry Morozovsky To: Eitan Adler Subject: Re: svn commit: r250565 - head/etc In-Reply-To: <201305121523.r4CFNxBR055568@svn.freebsd.org> Message-ID: References: <201305121523.r4CFNxBR055568@svn.freebsd.org> User-Agent: Alpine 2.00 (BSF 1167 2008-08-23) X-NCC-RegID: ru.rinet X-OpenPGP-Key-ID: 6B691B03 MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-4.4.3 (woozle.rinet.ru [0.0.0.0]); Sun, 12 May 2013 19:54:11 +0400 (MSK) Cc: svn-src-head@freebsd.org, svn-src-all@freebsd.org, src-committers@freebsd.org X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 12 May 2013 15:54:14 -0000 On Sun, 12 May 2013, Eitan Adler wrote: > Author: eadler > Date: Sun May 12 15:23:59 2013 > New Revision: 250565 > URL: http://svnweb.freebsd.org/changeset/base/250565 > > Log: > Make newsyslog compress logs with xz instead of bzip2 to save space. While it may be useful for contemporary x64 machines, where CPU power is not an issue, I'm afraid it could produce more harm than goodness on old hardware and/or other architectures like arm. Do you have any estimation chart on different CPUs and architectures? -- Sincerely, D.Marck [DM5020, MCK-RIPE, DM3-RIPN] [ FreeBSD committer: marck@FreeBSD.org ] ------------------------------------------------------------------------ *** Dmitry Morozovsky --- D.Marck --- Wild Woozle --- marck@rinet.ru *** ------------------------------------------------------------------------ From owner-svn-src-all@FreeBSD.ORG Sun May 12 16:07:24 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id 0EDCEE11; Sun, 12 May 2013 16:07:24 +0000 (UTC) (envelope-from eadler@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id 0184F152; Sun, 12 May 2013 16:07:24 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.6/8.14.6) with ESMTP id r4CG7Npa070359; Sun, 12 May 2013 16:07:23 GMT (envelope-from eadler@svn.freebsd.org) Received: (from eadler@localhost) by svn.freebsd.org (8.14.6/8.14.5/Submit) id r4CG7NAl070358; Sun, 12 May 2013 16:07:23 GMT (envelope-from eadler@svn.freebsd.org) Message-Id: <201305121607.r4CG7NAl070358@svn.freebsd.org> From: Eitan Adler Date: Sun, 12 May 2013 16:07:23 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r250568 - head X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 12 May 2013 16:07:24 -0000 Author: eadler Date: Sun May 12 16:07:23 2013 New Revision: 250568 URL: http://svnweb.freebsd.org/changeset/base/250568 Log: Fix typo in UPDATING Submitted by: Rainer Hurling Modified: head/UPDATING Modified: head/UPDATING ============================================================================== --- head/UPDATING Sun May 12 15:44:49 2013 (r250567) +++ head/UPDATING Sun May 12 16:07:23 2013 (r250568) @@ -108,7 +108,7 @@ NOTE TO PEOPLE WHO THINK THAT FreeBSD 10 Due to the use of the new -l option to install(1) during build and install, you must take care not to directly set the INSTALL make variable in your /etc/make.conf, /etc/src.conf, or on the - command line. If you with to use the -C flag for all installs + command line. If you wish to use the -C flag for all installs you may be able to add INSTALL+=-C to /etc/make.conf or /etc/src.conf. From owner-svn-src-all@FreeBSD.ORG Sun May 12 16:11:24 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id 3EB9F15A; Sun, 12 May 2013 16:11:24 +0000 (UTC) (envelope-from jilles@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id 1680717E; Sun, 12 May 2013 16:11:24 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.6/8.14.6) with ESMTP id r4CGBNI2072891; Sun, 12 May 2013 16:11:23 GMT (envelope-from jilles@svn.freebsd.org) Received: (from jilles@localhost) by svn.freebsd.org (8.14.6/8.14.5/Submit) id r4CGBNAH072888; Sun, 12 May 2013 16:11:23 GMT (envelope-from jilles@svn.freebsd.org) Message-Id: <201305121611.r4CGBNAH072888@svn.freebsd.org> From: Jilles Tjoelker Date: Sun, 12 May 2013 16:11:23 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org Subject: svn commit: r250569 - in stable/9: lib/libc/gen sys/kern X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 12 May 2013 16:11:24 -0000 Author: jilles Date: Sun May 12 16:11:23 2013 New Revision: 250569 URL: http://svnweb.freebsd.org/changeset/base/250569 Log: MFC r249566,r249644: EINTR in POSIX sem_*. Document that sem_wait() can fail with [EINTR]. Programs often do not expect an [EINTR] return from sem_wait() and POSIX only allows it if the signal was installed without SA_RESTART. The timeout in sem_timedwait() is absolute so it can be restarted normally. The old POSIX semaphore implementation did this correctly, unlike the new umtx one. Specific to 9-stable: UMTX_ABSTIME does not exist and therefore sem_timedwait() is erroneously not restarted after a SA_RESTART signal handler. It may be desirable to avoid [EINTR] completely, which matches the pthread functions and is explicitly permitted by POSIX. However, the kernel must return [EINTR] at least for signals with SA_RESTART clear, otherwise pthread cancellation will not abort a semaphore wait. In this commit, only restore the 8.x behaviour which is also permitted by POSIX, as far as possible with the ABI in 9-stable. Modified: stable/9/lib/libc/gen/sem_wait.3 stable/9/sys/kern/kern_umtx.c Directory Properties: stable/9/lib/libc/ (props changed) stable/9/sys/ (props changed) Modified: stable/9/lib/libc/gen/sem_wait.3 ============================================================================== --- stable/9/lib/libc/gen/sem_wait.3 Sun May 12 16:07:23 2013 (r250568) +++ stable/9/lib/libc/gen/sem_wait.3 Sun May 12 16:11:23 2013 (r250569) @@ -27,7 +27,7 @@ .\" .\" $FreeBSD$ .\" -.Dd February 15, 2000 +.Dd April 16, 2013 .Dt SEM_WAIT 3 .Os .Sh NAME @@ -75,6 +75,14 @@ points to an invalid semaphore. .El .Pp Additionally, +.Fn sem_wait +will fail if: +.Bl -tag -width Er +.Pp +.It Bq Er EINTR +A signal interrupted this function. +.El +Additionally, .Fn sem_trywait will fail if: .Bl -tag -width Er Modified: stable/9/sys/kern/kern_umtx.c ============================================================================== --- stable/9/sys/kern/kern_umtx.c Sun May 12 16:07:23 2013 (r250568) +++ stable/9/sys/kern/kern_umtx.c Sun May 12 16:11:23 2013 (r250569) @@ -2970,7 +2970,8 @@ do_sem_wait(struct thread *td, struct _u error = 0; else { umtxq_remove(uq); - if (error == ERESTART) + /* A relative timeout cannot be restarted. */ + if (error == ERESTART && timeout != NULL) error = EINTR; } umtxq_unlock(&uq->uq_key); From owner-svn-src-all@FreeBSD.ORG Sun May 12 16:18:00 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id E07785F9; Sun, 12 May 2013 16:18:00 +0000 (UTC) (envelope-from jilles@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id D2DEF1C0; Sun, 12 May 2013 16:18:00 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.6/8.14.6) with ESMTP id r4CGI0ox074682; Sun, 12 May 2013 16:18:00 GMT (envelope-from jilles@svn.freebsd.org) Received: (from jilles@localhost) by svn.freebsd.org (8.14.6/8.14.5/Submit) id r4CGI0Dr074681; Sun, 12 May 2013 16:18:00 GMT (envelope-from jilles@svn.freebsd.org) Message-Id: <201305121618.r4CGI0Dr074681@svn.freebsd.org> From: Jilles Tjoelker Date: Sun, 12 May 2013 16:18:00 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org Subject: svn commit: r250570 - stable/9/lib/libc/sys X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 12 May 2013 16:18:01 -0000 Author: jilles Date: Sun May 12 16:18:00 2013 New Revision: 250570 URL: http://svnweb.freebsd.org/changeset/base/250570 Log: MFC r249979: intro(2): Fix some errors in ENFILE and EMFILE descriptions. Modified: stable/9/lib/libc/sys/intro.2 Directory Properties: stable/9/lib/libc/ (props changed) stable/9/lib/libc/sys/ (props changed) Modified: stable/9/lib/libc/sys/intro.2 ============================================================================== --- stable/9/lib/libc/sys/intro.2 Sun May 12 16:11:23 2013 (r250569) +++ stable/9/lib/libc/sys/intro.2 Sun May 12 16:18:00 2013 (r250570) @@ -28,7 +28,7 @@ .\" @(#)intro.2 8.5 (Berkeley) 2/27/95 .\" $FreeBSD$ .\" -.Dd February 27, 1995 +.Dd April 27, 2013 .Dt INTRO 2 .Os .Sh NAME @@ -189,12 +189,13 @@ or a .Xr kill 2 system call). .It Er 23 ENFILE Em "Too many open files in system" . -Maximum number of file descriptors allowable on the system -has been reached and a requests for an open cannot be satisfied +Maximum number of open files allowable on the system +has been reached and requests for an open cannot be satisfied until at least one has been closed. .It Er 24 EMFILE Em "Too many open files" . -(As released, the limit on the number of -open files per process is 64.) +Maximum number of file descriptors allowable in the process +has been reached and requests for an open cannot be satisfied +until at least one has been closed. The .Xr getdtablesize 2 system call will obtain the current limit. From owner-svn-src-all@FreeBSD.ORG Sun May 12 16:20:27 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id EAE4682A; Sun, 12 May 2013 16:20:27 +0000 (UTC) (envelope-from jilles@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id DCA791E6; Sun, 12 May 2013 16:20:27 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.6/8.14.6) with ESMTP id r4CGKRsd075342; Sun, 12 May 2013 16:20:27 GMT (envelope-from jilles@svn.freebsd.org) Received: (from jilles@localhost) by svn.freebsd.org (8.14.6/8.14.5/Submit) id r4CGKRAN075341; Sun, 12 May 2013 16:20:27 GMT (envelope-from jilles@svn.freebsd.org) Message-Id: <201305121620.r4CGKRAN075341@svn.freebsd.org> From: Jilles Tjoelker Date: Sun, 12 May 2013 16:20:27 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org Subject: svn commit: r250571 - stable/9/lib/libc/gen X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 12 May 2013 16:20:28 -0000 Author: jilles Date: Sun May 12 16:20:27 2013 New Revision: 250571 URL: http://svnweb.freebsd.org/changeset/base/250571 Log: MFC r249956: sysconf(3): Correct the description of _SC_OPEN_MAX. Modified: stable/9/lib/libc/gen/sysconf.3 Directory Properties: stable/9/lib/libc/ (props changed) Modified: stable/9/lib/libc/gen/sysconf.3 ============================================================================== --- stable/9/lib/libc/gen/sysconf.3 Sun May 12 16:18:00 2013 (r250570) +++ stable/9/lib/libc/gen/sysconf.3 Sun May 12 16:20:27 2013 (r250571) @@ -28,7 +28,7 @@ .\" @(#)sysconf.3 8.3 (Berkeley) 4/19/94 .\" $FreeBSD$ .\" -.Dd February 13, 2011 +.Dd April 26, 2013 .Dt SYSCONF 3 .Os .Sh NAME @@ -82,7 +82,7 @@ The number of processors configured. .It Li _SC_NPROCESSORS_ONLN The number of processors currently online. .It Li _SC_OPEN_MAX -The maximum number of open files per user id. +One more than the maximum value the system may assign to a new file descriptor. .It Li _SC_PAGESIZE The size of a system page in bytes. .It Li _SC_PAGE_SIZE From owner-svn-src-all@FreeBSD.ORG Sun May 12 16:22:11 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id 5E7379A0; Sun, 12 May 2013 16:22:11 +0000 (UTC) (envelope-from jilles@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id 508CA1F3; Sun, 12 May 2013 16:22:11 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.6/8.14.6) with ESMTP id r4CGMBJY077142; Sun, 12 May 2013 16:22:11 GMT (envelope-from jilles@svn.freebsd.org) Received: (from jilles@localhost) by svn.freebsd.org (8.14.6/8.14.5/Submit) id r4CGMBkK077141; Sun, 12 May 2013 16:22:11 GMT (envelope-from jilles@svn.freebsd.org) Message-Id: <201305121622.r4CGMBkK077141@svn.freebsd.org> From: Jilles Tjoelker Date: Sun, 12 May 2013 16:22:11 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org Subject: svn commit: r250572 - stable/9/lib/libc/sys X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 12 May 2013 16:22:11 -0000 Author: jilles Date: Sun May 12 16:22:10 2013 New Revision: 250572 URL: http://svnweb.freebsd.org/changeset/base/250572 Log: MFC r249859: getdtablesize(2): Describe what this function actually does. getdtablesize() returns the limit on new file descriptors; this says nothing about existing descriptors. Modified: stable/9/lib/libc/sys/getdtablesize.2 Directory Properties: stable/9/lib/libc/ (props changed) stable/9/lib/libc/sys/ (props changed) Modified: stable/9/lib/libc/sys/getdtablesize.2 ============================================================================== --- stable/9/lib/libc/sys/getdtablesize.2 Sun May 12 16:20:27 2013 (r250571) +++ stable/9/lib/libc/sys/getdtablesize.2 Sun May 12 16:22:10 2013 (r250572) @@ -28,12 +28,12 @@ .\" @(#)getdtablesize.2 8.1 (Berkeley) 6/4/93 .\" $FreeBSD$ .\" -.Dd June 4, 1993 +.Dd April 24, 2013 .Dt GETDTABLESIZE 2 .Os .Sh NAME .Nm getdtablesize -.Nd get descriptor table size +.Nd get file descriptor limit .Sh LIBRARY .Lb libc .Sh SYNOPSIS @@ -41,18 +41,20 @@ .Ft int .Fn getdtablesize void .Sh DESCRIPTION -Each process has a fixed size descriptor table, -which is guaranteed to have at least 20 slots. -The entries in -the descriptor table are numbered with small integers starting at 0. The .Fn getdtablesize -system call returns the size of this table. +system call returns the maximum number of file descriptors +that the current process may open. +The maximum file descriptor number that the system may assign +is the return value minus one. +Existing file descriptor numbers may be higher +if the limit was lowered after they were opened. .Sh SEE ALSO .Xr close 2 , +.Xr closefrom 2 , .Xr dup 2 , -.Xr open 2 , -.Xr select 2 +.Xr getrlimit 2 , +.Xr sysconf 2 .Sh HISTORY The .Fn getdtablesize From owner-svn-src-all@FreeBSD.ORG Sun May 12 16:26:20 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id 14B2EB3D; Sun, 12 May 2013 16:26:20 +0000 (UTC) (envelope-from jilles@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id 06EFC20D; Sun, 12 May 2013 16:26:20 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.6/8.14.6) with ESMTP id r4CGQJbZ077901; Sun, 12 May 2013 16:26:19 GMT (envelope-from jilles@svn.freebsd.org) Received: (from jilles@localhost) by svn.freebsd.org (8.14.6/8.14.5/Submit) id r4CGQJmJ077900; Sun, 12 May 2013 16:26:19 GMT (envelope-from jilles@svn.freebsd.org) Message-Id: <201305121626.r4CGQJmJ077900@svn.freebsd.org> From: Jilles Tjoelker Date: Sun, 12 May 2013 16:26:19 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org Subject: svn commit: r250573 - stable/9/lib/libc/sys X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 12 May 2013 16:26:20 -0000 Author: jilles Date: Sun May 12 16:26:19 2013 New Revision: 250573 URL: http://svnweb.freebsd.org/changeset/base/250573 Log: dup(2): Remove incorrect sentence about getdtablesize(). There are no getdtablesize() bounds on the file descriptor to be duplicated; it only has to be open. If the RLIMIT_NOFILE rlimit was decreased after opening the file descriptor, it may be greater than or equal to getdtablesize() but still valid. Modified: stable/9/lib/libc/sys/dup.2 Directory Properties: stable/9/lib/libc/ (props changed) stable/9/lib/libc/sys/ (props changed) Modified: stable/9/lib/libc/sys/dup.2 ============================================================================== --- stable/9/lib/libc/sys/dup.2 Sun May 12 16:22:10 2013 (r250572) +++ stable/9/lib/libc/sys/dup.2 Sun May 12 16:26:19 2013 (r250573) @@ -28,7 +28,7 @@ .\" @(#)dup.2 8.1 (Berkeley) 6/4/93 .\" $FreeBSD$ .\" -.Dd August 14, 2011 +.Dd April 21, 2013 .Dt DUP 2 .Os .Sh NAME @@ -56,9 +56,6 @@ The argument .Fa oldd is a small non-negative integer index in the per-process descriptor table. -The value must be less -than the size of the table, which is returned by -.Xr getdtablesize 2 . The new descriptor returned by the call is the lowest numbered descriptor currently not in use by the process. From owner-svn-src-all@FreeBSD.ORG Sun May 12 16:26:35 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id 90811CA0; Sun, 12 May 2013 16:26:35 +0000 (UTC) (envelope-from markj@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id 73F74211; Sun, 12 May 2013 16:26:35 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.6/8.14.6) with ESMTP id r4CGQZV3077991; Sun, 12 May 2013 16:26:35 GMT (envelope-from markj@svn.freebsd.org) Received: (from markj@localhost) by svn.freebsd.org (8.14.6/8.14.5/Submit) id r4CGQYBB077979; Sun, 12 May 2013 16:26:34 GMT (envelope-from markj@svn.freebsd.org) Message-Id: <201305121626.r4CGQYBB077979@svn.freebsd.org> From: Mark Johnston Date: Sun, 12 May 2013 16:26:34 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r250574 - in head: cddl/contrib/opensolaris/cmd/dtrace cddl/contrib/opensolaris/cmd/dtrace/test/tst/common/buffering cddl/contrib/opensolaris/cmd/dtrace/test/tst/common/pragma cddl/cont... X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 12 May 2013 16:26:35 -0000 Author: markj Date: Sun May 12 16:26:33 2013 New Revision: 250574 URL: http://svnweb.freebsd.org/changeset/base/250574 Log: Bring back part of r249367 by adding DTrace's temporal option, which allows users to guarantee that the output of DTrace scripts will be time-ordered. This option is enabled by adding the line #pragma D option temporal to the beginning of a script, or by adding '-x temporal' to the arguments of dtrace(1). This change fixes a bug in the original port of the temporal option. This bug was causing some assertions to fail, so they had been disabled; in this revision the assertions are working properly and are enabled. The DTrace version number has been bumped from 1.9.0 to 1.9.1 to reflect the language change that's being introduced. This change corresponds to part of illumos-gate commit e5803b76927480: 3021 option for time-ordered output from dtrace(1M) Reviewed by: pfg Obtained from: illumos MFC after: 1 month Added: head/cddl/contrib/opensolaris/cmd/dtrace/test/tst/common/pragma/tst.temporal.ksh - copied unchanged from r250296, vendor/illumos/dist/cmd/dtrace/test/tst/common/pragma/tst.temporal.ksh head/cddl/contrib/opensolaris/cmd/dtrace/test/tst/common/pragma/tst.temporal2.ksh - copied unchanged from r250296, vendor/illumos/dist/cmd/dtrace/test/tst/common/pragma/tst.temporal2.ksh head/cddl/contrib/opensolaris/cmd/dtrace/test/tst/common/pragma/tst.temporal3.d - copied unchanged from r250296, vendor/illumos/dist/cmd/dtrace/test/tst/common/pragma/tst.temporal3.d head/cddl/contrib/opensolaris/lib/libdtrace/common/dt_pq.c - copied unchanged from r250296, vendor/illumos/dist/lib/libdtrace/common/dt_pq.c head/cddl/contrib/opensolaris/lib/libdtrace/common/dt_pq.h - copied unchanged from r250296, vendor/illumos/dist/lib/libdtrace/common/dt_pq.h Modified: head/cddl/contrib/opensolaris/cmd/dtrace/dtrace.c head/cddl/contrib/opensolaris/cmd/dtrace/test/tst/common/buffering/tst.fill1.d head/cddl/contrib/opensolaris/cmd/dtrace/test/tst/common/speculation/err.BufSizeVariations1.d head/cddl/contrib/opensolaris/lib/libdtrace/common/dt_consume.c head/cddl/contrib/opensolaris/lib/libdtrace/common/dt_impl.h head/cddl/contrib/opensolaris/lib/libdtrace/common/dt_open.c head/cddl/contrib/opensolaris/lib/libdtrace/common/dt_options.c head/cddl/lib/libdtrace/Makefile head/sys/cddl/contrib/opensolaris/uts/common/dtrace/dtrace.c head/sys/cddl/contrib/opensolaris/uts/common/sys/dtrace.h head/sys/cddl/contrib/opensolaris/uts/common/sys/dtrace_impl.h head/sys/cddl/dev/dtrace/dtrace_ioctl.c Modified: head/cddl/contrib/opensolaris/cmd/dtrace/dtrace.c ============================================================================== --- head/cddl/contrib/opensolaris/cmd/dtrace/dtrace.c Sun May 12 16:26:19 2013 (r250573) +++ head/cddl/contrib/opensolaris/cmd/dtrace/dtrace.c Sun May 12 16:26:33 2013 (r250574) @@ -23,8 +23,9 @@ * Copyright 2006 Sun Microsystems, Inc. All rights reserved. * Use is subject to license terms. */ - -#pragma ident "%Z%%M% %I% %E% SMI" +/* + * Copyright (c) 2012 by Delphix. All rights reserved. + */ #include #include @@ -1409,6 +1410,7 @@ main(int argc, char *argv[]) (void) dtrace_setopt(g_dtp, "bufsize", "4m"); (void) dtrace_setopt(g_dtp, "aggsize", "4m"); #endif + (void) dtrace_setopt(g_dtp, "temporal", "yes"); /* * If -G is specified, enable -xlink=dynamic and -xunodefs to permit Modified: head/cddl/contrib/opensolaris/cmd/dtrace/test/tst/common/buffering/tst.fill1.d ============================================================================== --- head/cddl/contrib/opensolaris/cmd/dtrace/test/tst/common/buffering/tst.fill1.d Sun May 12 16:26:19 2013 (r250573) +++ head/cddl/contrib/opensolaris/cmd/dtrace/test/tst/common/buffering/tst.fill1.d Sun May 12 16:26:33 2013 (r250574) @@ -23,26 +23,29 @@ * Copyright 2006 Sun Microsystems, Inc. All rights reserved. * Use is subject to license terms. */ - -#pragma ident "%Z%%M% %I% %E% SMI" +/* + * Copyright (c) 2012 by Delphix. All rights reserved. + */ /* * ASSERTION: * Positive test for fill buffer policy. * * SECTION: Buffers and Buffering/fill Policy; - * Buffers and Buffering/Buffer Sizes; + * Buffers and Buffering/Buffer Sizes; * Options and Tunables/bufsize; * Options and Tunables/bufpolicy; * Options and Tunables/statusrate */ /* - * This is a brute-force way of testing fill buffers. We assume that each - * printf() stores 8 bytes. Because each fill buffer is per-CPU, we must - * fill up our buffer in one series of enablings on a single CPU. + * This is a brute-force way of testing fill buffers. We assume that + * each printf() stores 16 bytes (4x 32-bit words for EPID, timestamp + * lo, timestamp hi, and the variable i). Because each fill buffer is + * per-CPU, we must fill up our buffer in one series of enablings on a + * single CPU. */ #pragma D option bufpolicy=fill -#pragma D option bufsize=64 +#pragma D option bufsize=128 #pragma D option statusrate=10ms #pragma D option quiet Copied: head/cddl/contrib/opensolaris/cmd/dtrace/test/tst/common/pragma/tst.temporal.ksh (from r250296, vendor/illumos/dist/cmd/dtrace/test/tst/common/pragma/tst.temporal.ksh) ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ head/cddl/contrib/opensolaris/cmd/dtrace/test/tst/common/pragma/tst.temporal.ksh Sun May 12 16:26:33 2013 (r250574, copy of r250296, vendor/illumos/dist/cmd/dtrace/test/tst/common/pragma/tst.temporal.ksh) @@ -0,0 +1,106 @@ +#!/bin/ksh -p +# +# CDDL HEADER START +# +# This file and its contents are supplied under the terms of the +# Common Development and Distribution License ("CDDL"), version 1.0. +# You may only use this file in accordance with the terms of version +# 1.0 of the CDDL. +# +# A full copy of the text of the CDDL should have accompanied this +# source. A copy of the CDDL is also available via the Internet at +# http://www.illumos.org/license/CDDL. +# +# CDDL HEADER END +# + +# +# Copyright (c) 2012 by Delphix. All rights reserved. +# + +############################################################################ +# ASSERTION: +# temporal option causes output to be sorted +# +# SECTION: Pragma +# +# NOTES: The temporal option has no effect on a single-CPU system, so +# this needs to be run on a multi-CPU system to effectively test the +# temporal option. +# +############################################################################ + +if [ $# != 1 ]; then + echo expected one argument: '<'dtrace-path'>' + exit 2 +fi + +dtrace=$1 +file=/tmp/out.$$ + +rm -f $file + +$dtrace -o $file -c 'sleep 3' -s /dev/stdin < $file.2 + +sort -n $file.2 | diff $file.2 - +status=$? +if [ "$status" -ne 0 ]; then + echo $tst: output is not sorted + exit $status +fi + +head -n 1 $file.2 | grep begin >/dev/null +status=$? +if [ "$status" -ne 0 ]; then + echo $tst: begin probe did not fire + exit $status +fi + +tail -n 2 $file.2 | grep end >/dev/null +status=$? +if [ "$status" -ne 0 ]; then + echo $tst: end probe did not fire + exit $status +fi + +if [ $(tail -n 1 $file.2 | cut -f3 -d ' ') -ne \ + $(wc -l $file.2) ]; then + echo $tst: incorrect number of lines output + exit 1 +fi + +exit $status Copied: head/cddl/contrib/opensolaris/cmd/dtrace/test/tst/common/pragma/tst.temporal2.ksh (from r250296, vendor/illumos/dist/cmd/dtrace/test/tst/common/pragma/tst.temporal2.ksh) ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ head/cddl/contrib/opensolaris/cmd/dtrace/test/tst/common/pragma/tst.temporal2.ksh Sun May 12 16:26:33 2013 (r250574, copy of r250296, vendor/illumos/dist/cmd/dtrace/test/tst/common/pragma/tst.temporal2.ksh) @@ -0,0 +1,102 @@ +#!/bin/ksh -p +# +# CDDL HEADER START +# +# This file and its contents are supplied under the terms of the +# Common Development and Distribution License ("CDDL"), version 1.0. +# You may only use this file in accordance with the terms of version +# 1.0 of the CDDL. +# +# A full copy of the text of the CDDL should have accompanied this +# source. A copy of the CDDL is also available via the Internet at +# http://www.illumos.org/license/CDDL. +# +# CDDL HEADER END +# + +# +# Copyright (c) 2012 by Delphix. All rights reserved. +# + +############################################################################ +# ASSERTION: +# temporal option causes output to be sorted, even when some +# buffers are empty +# +# SECTION: Pragma +# +# NOTES: The temporal option has no effect on a single-CPU system, so +# this needs to be run on a multi-CPU system to effectively test the +# temporal option. +# +############################################################################ + +if [ $# != 1 ]; then + echo expected one argument: '<'dtrace-path'>' + exit 2 +fi + +dtrace=$1 +file=/tmp/out.$$ + +rm -f $file + +$dtrace -o $file -s /dev/stdin < $file.2 + +sort -n $file.2 | diff $file.2 - +status=$? +if [ "$status" -ne 0 ]; then + echo $tst: output is not sorted + exit $status +fi + +exit $status Copied: head/cddl/contrib/opensolaris/cmd/dtrace/test/tst/common/pragma/tst.temporal3.d (from r250296, vendor/illumos/dist/cmd/dtrace/test/tst/common/pragma/tst.temporal3.d) ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ head/cddl/contrib/opensolaris/cmd/dtrace/test/tst/common/pragma/tst.temporal3.d Sun May 12 16:26:33 2013 (r250574, copy of r250296, vendor/illumos/dist/cmd/dtrace/test/tst/common/pragma/tst.temporal3.d) @@ -0,0 +1,48 @@ +/* + * CDDL HEADER START + * + * This file and its contents are supplied under the terms of the + * Common Development and Distribution License ("CDDL"), version 1.0. + * You may only use this file in accordance with the terms of version + * 1.0 of the CDDL. + * + * A full copy of the text of the CDDL should have accompanied this + * source. A copy of the CDDL is also available via the Internet at + * http://www.illumos.org/license/CDDL. + * + * CDDL HEADER END + */ + +/* + * Copyright (c) 2012 by Delphix. All rights reserved. + */ + +/* + * This test excercises the "remnant" handling of the temporal option. + * At the end of one pass of retrieving and printing data from all CPUs, + * some unprocessed data will remain, because its timestamp is after the + * time covered by all CPUs' buffers. This unprocessed data is + * rearranged in a more space-efficient manner. If this is done + * incorrectly, an alignment error may occur. To test this, we use a + * high-frequency probe so that data will be recorded in subsequent + * CPU's buffers after the first CPU's buffer is obtained. The + * combination of data traced here (a 8-byte value and a 4-byte value) + * is effective to cause alignment problems with an incorrect + * implementation. + * + * This test needs to be run on a multi-CPU system to be effective. + */ + +#pragma D option quiet +#pragma D option temporal + +profile-4997 +{ + printf("%u %u", 1ULL, 2); +} + +tick-1 +/i++ == 10/ +{ + exit(0); +} Modified: head/cddl/contrib/opensolaris/cmd/dtrace/test/tst/common/speculation/err.BufSizeVariations1.d ============================================================================== --- head/cddl/contrib/opensolaris/cmd/dtrace/test/tst/common/speculation/err.BufSizeVariations1.d Sun May 12 16:26:19 2013 (r250573) +++ head/cddl/contrib/opensolaris/cmd/dtrace/test/tst/common/speculation/err.BufSizeVariations1.d Sun May 12 16:26:33 2013 (r250574) @@ -24,7 +24,10 @@ * Use is subject to license terms. */ -#pragma ident "%Z%%M% %I% %E% SMI" +/* + * Copyright (c) 2012 by Delphix. All rights reserved. + */ + /* * ASSERTION: @@ -35,17 +38,10 @@ * * NOTES: This test behaves differently depending on the values * assigned to bufsize. - * 1. 0 > bufsize. - * 2. 0 == bufsize. - * 3. 0 < bufsize <= 7 - * 4. 8 <= bufsize <= 31 - * 5. 32 <= bufsize <= 47 - * 6. 48 <= bufsize <= 71 - * 7. 72 <= bufsize */ #pragma D option quiet -#pragma D option bufsize=41 +#pragma D option bufsize=49 BEGIN { Modified: head/cddl/contrib/opensolaris/lib/libdtrace/common/dt_consume.c ============================================================================== --- head/cddl/contrib/opensolaris/lib/libdtrace/common/dt_consume.c Sun May 12 16:26:19 2013 (r250573) +++ head/cddl/contrib/opensolaris/lib/libdtrace/common/dt_consume.c Sun May 12 16:26:33 2013 (r250574) @@ -25,7 +25,7 @@ /* * Copyright (c) 2011, Joyent, Inc. All rights reserved. - * Copyright (c) 2011 by Delphix. All rights reserved. + * Copyright (c) 2012 by Delphix. All rights reserved. */ #include @@ -39,6 +39,7 @@ #include #endif #include +#include #if !defined(sun) #include #endif @@ -443,17 +444,8 @@ dt_flowindent(dtrace_hdl_t *dtp, dtrace_ offs += epd->dtepd_size; do { - if (offs >= buf->dtbd_size) { - /* - * We're at the end -- maybe. If the oldest - * record is non-zero, we need to wrap. - */ - if (buf->dtbd_oldest != 0) { - offs = 0; - } else { - goto out; - } - } + if (offs >= buf->dtbd_size) + goto out; next = *(uint32_t *)((uintptr_t)buf->dtbd_data + offs); @@ -2014,26 +2006,27 @@ dt_setopt(dtrace_hdl_t *dtp, const dtrac } static int -dt_consume_cpu(dtrace_hdl_t *dtp, FILE *fp, int cpu, dtrace_bufdesc_t *buf, +dt_consume_cpu(dtrace_hdl_t *dtp, FILE *fp, int cpu, + dtrace_bufdesc_t *buf, boolean_t just_one, dtrace_consume_probe_f *efunc, dtrace_consume_rec_f *rfunc, void *arg) { dtrace_epid_t id; - size_t offs, start = buf->dtbd_oldest, end = buf->dtbd_size; + size_t offs; int flow = (dtp->dt_options[DTRACEOPT_FLOWINDENT] != DTRACEOPT_UNSET); int quiet = (dtp->dt_options[DTRACEOPT_QUIET] != DTRACEOPT_UNSET); int rval, i, n; - dtrace_epid_t last = DTRACE_EPIDNONE; uint64_t tracememsize = 0; dtrace_probedata_t data; uint64_t drops; - caddr_t addr; + data.dtpda_flow = dtp->dt_flow; + data.dtpda_indent = dtp->dt_indent; + data.dtpda_prefix = dtp->dt_prefix; bzero(&data, sizeof (data)); data.dtpda_handle = dtp; data.dtpda_cpu = cpu; -again: - for (offs = start; offs < end; ) { + for (offs = buf->dtbd_oldest; offs < buf->dtbd_size; ) { dtrace_eprobedesc_t *epd; /* @@ -2068,7 +2061,8 @@ again: } if (flow) - (void) dt_flowindent(dtp, &data, last, buf, offs); + (void) dt_flowindent(dtp, &data, dtp->dt_last_epid, + buf, offs); rval = (*efunc)(&data, arg); @@ -2087,6 +2081,7 @@ again: return (dt_set_errno(dtp, EDT_BADRVAL)); for (i = 0; i < epd->dtepd_nrecs; i++) { + caddr_t addr; dtrace_recdesc_t *rec = &epd->dtepd_rec[i]; dtrace_actkind_t act = rec->dtrd_action; @@ -2458,14 +2453,16 @@ nextrec: rval = (*rfunc)(&data, NULL, arg); nextepid: offs += epd->dtepd_size; - last = id; + dtp->dt_last_epid = id; + if (just_one) { + buf->dtbd_oldest = offs; + break; + } } - if (buf->dtbd_oldest != 0 && start == buf->dtbd_oldest) { - end = buf->dtbd_oldest; - start = 0; - goto again; - } + dtp->dt_flow = data.dtpda_flow; + dtp->dt_indent = data.dtpda_indent; + dtp->dt_prefix = data.dtpda_prefix; if ((drops = buf->dtbd_drops) == 0) return (0); @@ -2478,6 +2475,130 @@ nextepid: return (dt_handle_cpudrop(dtp, cpu, DTRACEDROP_PRINCIPAL, drops)); } +/* + * Reduce memory usage by shrinking the buffer if it's no more than half full. + * Note, we need to preserve the alignment of the data at dtbd_oldest, which is + * only 4-byte aligned. + */ +static void +dt_realloc_buf(dtrace_hdl_t *dtp, dtrace_bufdesc_t *buf, int cursize) +{ + uint64_t used = buf->dtbd_size - buf->dtbd_oldest; + if (used < cursize / 2) { + int misalign = buf->dtbd_oldest & (sizeof (uint64_t) - 1); + char *newdata = dt_alloc(dtp, used + misalign); + if (newdata == NULL) + return; + bzero(newdata, misalign); + bcopy(buf->dtbd_data + buf->dtbd_oldest, + newdata + misalign, used); + dt_free(dtp, buf->dtbd_data); + buf->dtbd_oldest = misalign; + buf->dtbd_size = used + misalign; + buf->dtbd_data = newdata; + } +} + +/* + * If the ring buffer has wrapped, the data is not in order. Rearrange it + * so that it is. Note, we need to preserve the alignment of the data at + * dtbd_oldest, which is only 4-byte aligned. + */ +static int +dt_unring_buf(dtrace_hdl_t *dtp, dtrace_bufdesc_t *buf) +{ + int misalign; + char *newdata, *ndp; + + if (buf->dtbd_oldest == 0) + return (0); + + misalign = buf->dtbd_oldest & (sizeof (uint64_t) - 1); + newdata = ndp = dt_alloc(dtp, buf->dtbd_size + misalign); + + if (newdata == NULL) + return (-1); + + assert(0 == (buf->dtbd_size & (sizeof (uint64_t) - 1))); + + bzero(ndp, misalign); + ndp += misalign; + + bcopy(buf->dtbd_data + buf->dtbd_oldest, ndp, + buf->dtbd_size - buf->dtbd_oldest); + ndp += buf->dtbd_size - buf->dtbd_oldest; + + bcopy(buf->dtbd_data, ndp, buf->dtbd_oldest); + + dt_free(dtp, buf->dtbd_data); + buf->dtbd_oldest = 0; + buf->dtbd_data = newdata; + buf->dtbd_size += misalign; + + return (0); +} + +static void +dt_put_buf(dtrace_hdl_t *dtp, dtrace_bufdesc_t *buf) +{ + dt_free(dtp, buf->dtbd_data); + dt_free(dtp, buf); +} + +/* + * Returns 0 on success, in which case *cbp will be filled in if we retrieved + * data, or NULL if there is no data for this CPU. + * Returns -1 on failure and sets dt_errno. + */ +static int +dt_get_buf(dtrace_hdl_t *dtp, int cpu, dtrace_bufdesc_t **bufp) +{ + dtrace_optval_t size; + dtrace_bufdesc_t *buf = dt_zalloc(dtp, sizeof (*buf)); + int error; + + if (buf == NULL) + return (-1); + + (void) dtrace_getopt(dtp, "bufsize", &size); + buf->dtbd_data = dt_alloc(dtp, size); + if (buf->dtbd_data == NULL) { + dt_free(dtp, buf); + return (-1); + } + buf->dtbd_size = size; + buf->dtbd_cpu = cpu; + +#if defined(sun) + if (dt_ioctl(dtp, DTRACEIOC_BUFSNAP, buf) == -1) { +#else + if (dt_ioctl(dtp, DTRACEIOC_BUFSNAP, &buf) == -1) { +#endif + dt_put_buf(dtp, buf); + /* + * If we failed with ENOENT, it may be because the + * CPU was unconfigured -- this is okay. Any other + * error, however, is unexpected. + */ + if (errno == ENOENT) { + *bufp = NULL; + return (0); + } + + return (dt_set_errno(dtp, errno)); + } + + error = dt_unring_buf(dtp, buf); + if (error != 0) { + dt_put_buf(dtp, buf); + return (error); + } + dt_realloc_buf(dtp, buf, size); + + *bufp = buf; + return (0); +} + typedef struct dt_begin { dtrace_consume_probe_f *dtbgn_probefunc; dtrace_consume_rec_f *dtbgn_recfunc; @@ -2541,7 +2662,7 @@ dt_consume_begin_error(const dtrace_errd } static int -dt_consume_begin(dtrace_hdl_t *dtp, FILE *fp, dtrace_bufdesc_t *buf, +dt_consume_begin(dtrace_hdl_t *dtp, FILE *fp, dtrace_consume_probe_f *pf, dtrace_consume_rec_f *rf, void *arg) { /* @@ -2565,33 +2686,19 @@ dt_consume_begin(dtrace_hdl_t *dtp, FILE * first pass, and that we only process ERROR enablings _not_ induced * by BEGIN enablings in the second pass. */ + dt_begin_t begin; processorid_t cpu = dtp->dt_beganon; - dtrace_bufdesc_t nbuf; -#if !defined(sun) - dtrace_bufdesc_t *pbuf; -#endif int rval, i; static int max_ncpus; - dtrace_optval_t size; + dtrace_bufdesc_t *buf; dtp->dt_beganon = -1; -#if defined(sun) - if (dt_ioctl(dtp, DTRACEIOC_BUFSNAP, buf) == -1) { -#else - if (dt_ioctl(dtp, DTRACEIOC_BUFSNAP, &buf) == -1) { -#endif - /* - * We really don't expect this to fail, but it is at least - * technically possible for this to fail with ENOENT. In this - * case, we just drive on... - */ - if (errno == ENOENT) - return (0); - - return (dt_set_errno(dtp, errno)); - } + if (dt_get_buf(dtp, cpu, &buf) != 0) + return (-1); + if (buf == NULL) + return (0); if (!dtp->dt_stopped || buf->dtbd_cpu != dtp->dt_endedon) { /* @@ -2599,7 +2706,10 @@ dt_consume_begin(dtrace_hdl_t *dtp, FILE * we are, we actually processed any END probes on another * CPU. We can simply consume this buffer and return. */ - return (dt_consume_cpu(dtp, fp, cpu, buf, pf, rf, arg)); + rval = dt_consume_cpu(dtp, fp, cpu, buf, B_FALSE, + pf, rf, arg); + dt_put_buf(dtp, buf); + return (rval); } begin.dtbgn_probefunc = pf; @@ -2616,61 +2726,41 @@ dt_consume_begin(dtrace_hdl_t *dtp, FILE dtp->dt_errhdlr = dt_consume_begin_error; dtp->dt_errarg = &begin; - rval = dt_consume_cpu(dtp, fp, cpu, buf, dt_consume_begin_probe, - dt_consume_begin_record, &begin); + rval = dt_consume_cpu(dtp, fp, cpu, buf, B_FALSE, + dt_consume_begin_probe, dt_consume_begin_record, &begin); dtp->dt_errhdlr = begin.dtbgn_errhdlr; dtp->dt_errarg = begin.dtbgn_errarg; - if (rval != 0) + if (rval != 0) { + dt_put_buf(dtp, buf); return (rval); - - /* - * Now allocate a new buffer. We'll use this to deal with every other - * CPU. - */ - bzero(&nbuf, sizeof (dtrace_bufdesc_t)); - (void) dtrace_getopt(dtp, "bufsize", &size); - if ((nbuf.dtbd_data = malloc(size)) == NULL) - return (dt_set_errno(dtp, EDT_NOMEM)); + } if (max_ncpus == 0) max_ncpus = dt_sysconf(dtp, _SC_CPUID_MAX) + 1; for (i = 0; i < max_ncpus; i++) { - nbuf.dtbd_cpu = i; - + dtrace_bufdesc_t *nbuf; if (i == cpu) continue; -#if defined(sun) - if (dt_ioctl(dtp, DTRACEIOC_BUFSNAP, &nbuf) == -1) { -#else - pbuf = &nbuf; - if (dt_ioctl(dtp, DTRACEIOC_BUFSNAP, &pbuf) == -1) { -#endif - /* - * If we failed with ENOENT, it may be because the - * CPU was unconfigured -- this is okay. Any other - * error, however, is unexpected. - */ - if (errno == ENOENT) - continue; - - free(nbuf.dtbd_data); - - return (dt_set_errno(dtp, errno)); + if (dt_get_buf(dtp, i, &nbuf) != 0) { + dt_put_buf(dtp, buf); + return (-1); } + if (nbuf == NULL) + continue; - if ((rval = dt_consume_cpu(dtp, fp, - i, &nbuf, pf, rf, arg)) != 0) { - free(nbuf.dtbd_data); + rval = dt_consume_cpu(dtp, fp, i, nbuf, B_FALSE, + pf, rf, arg); + dt_put_buf(dtp, nbuf); + if (rval != 0) { + dt_put_buf(dtp, buf); return (rval); } } - free(nbuf.dtbd_data); - /* * Okay -- we're done with the other buffers. Now we want to * reconsume the first buffer -- but this time we're looking for @@ -2685,8 +2775,8 @@ dt_consume_begin(dtrace_hdl_t *dtp, FILE dtp->dt_errhdlr = dt_consume_begin_error; dtp->dt_errarg = &begin; - rval = dt_consume_cpu(dtp, fp, cpu, buf, dt_consume_begin_probe, - dt_consume_begin_record, &begin); + rval = dt_consume_cpu(dtp, fp, cpu, buf, B_FALSE, + dt_consume_begin_probe, dt_consume_begin_record, &begin); dtp->dt_errhdlr = begin.dtbgn_errhdlr; dtp->dt_errarg = begin.dtbgn_errarg; @@ -2694,11 +2784,32 @@ dt_consume_begin(dtrace_hdl_t *dtp, FILE return (rval); } +/* ARGSUSED */ +static uint64_t +dt_buf_oldest(void *elem, void *arg) +{ + dtrace_bufdesc_t *buf = elem; + size_t offs = buf->dtbd_oldest; + + while (offs < buf->dtbd_size) { + dtrace_rechdr_t *dtrh = + /* LINTED - alignment */ + (dtrace_rechdr_t *)(buf->dtbd_data + offs); + if (dtrh->dtrh_epid == DTRACE_EPIDNONE) { + offs += sizeof (dtrace_epid_t); + } else { + return (DTRACE_RECORD_LOAD_TIMESTAMP(dtrh)); + } + } + + /* There are no records left; use the time the buffer was retrieved. */ + return (buf->dtbd_timestamp); +} + int dtrace_consume(dtrace_hdl_t *dtp, FILE *fp, dtrace_consume_probe_f *pf, dtrace_consume_rec_f *rf, void *arg) { - dtrace_bufdesc_t *buf = &dtp->dt_buf; dtrace_optval_t size; static int max_ncpus; int i, rval; @@ -2726,79 +2837,158 @@ dtrace_consume(dtrace_hdl_t *dtp, FILE * if (rf == NULL) rf = (dtrace_consume_rec_f *)dt_nullrec; - if (buf->dtbd_data == NULL) { - (void) dtrace_getopt(dtp, "bufsize", &size); - if ((buf->dtbd_data = malloc(size)) == NULL) - return (dt_set_errno(dtp, EDT_NOMEM)); - - buf->dtbd_size = size; - } - - /* - * If we have just begun, we want to first process the CPU that - * executed the BEGIN probe (if any). - */ - if (dtp->dt_active && dtp->dt_beganon != -1) { - buf->dtbd_cpu = dtp->dt_beganon; - if ((rval = dt_consume_begin(dtp, fp, buf, pf, rf, arg)) != 0) - return (rval); - } - - for (i = 0; i < max_ncpus; i++) { - buf->dtbd_cpu = i; - + if (dtp->dt_options[DTRACEOPT_TEMPORAL] == DTRACEOPT_UNSET) { /* - * If we have stopped, we want to process the CPU on which the - * END probe was processed only _after_ we have processed - * everything else. + * The output will not be in the order it was traced. Rather, + * we will consume all of the data from each CPU's buffer in + * turn. We apply special handling for the records from BEGIN + * and END probes so that they are consumed first and last, + * respectively. + * + * If we have just begun, we want to first process the CPU that + * executed the BEGIN probe (if any). */ - if (dtp->dt_stopped && (i == dtp->dt_endedon)) - continue; + if (dtp->dt_active && dtp->dt_beganon != -1 && + (rval = dt_consume_begin(dtp, fp, pf, rf, arg)) != 0) + return (rval); + + for (i = 0; i < max_ncpus; i++) { + dtrace_bufdesc_t *buf; -#if defined(sun) - if (dt_ioctl(dtp, DTRACEIOC_BUFSNAP, buf) == -1) { -#else - if (dt_ioctl(dtp, DTRACEIOC_BUFSNAP, &buf) == -1) { -#endif /* - * If we failed with ENOENT, it may be because the - * CPU was unconfigured -- this is okay. Any other - * error, however, is unexpected. + * If we have stopped, we want to process the CPU on + * which the END probe was processed only _after_ we + * have processed everything else. */ - if (errno == ENOENT) + if (dtp->dt_stopped && (i == dtp->dt_endedon)) continue; - return (dt_set_errno(dtp, errno)); + if (dt_get_buf(dtp, i, &buf) != 0) + return (-1); + if (buf == NULL) + continue; + + dtp->dt_flow = 0; + dtp->dt_indent = 0; + dtp->dt_prefix = NULL; + rval = dt_consume_cpu(dtp, fp, i, + buf, B_FALSE, pf, rf, arg); + dt_put_buf(dtp, buf); + if (rval != 0) + return (rval); } + if (dtp->dt_stopped) { + dtrace_bufdesc_t *buf; - if ((rval = dt_consume_cpu(dtp, fp, i, buf, pf, rf, arg)) != 0) + if (dt_get_buf(dtp, dtp->dt_endedon, &buf) != 0) + return (-1); + if (buf == NULL) + return (0); + + rval = dt_consume_cpu(dtp, fp, dtp->dt_endedon, + buf, B_FALSE, pf, rf, arg); + dt_put_buf(dtp, buf); return (rval); - } + } + } else { + /* + * The output will be in the order it was traced (or for + * speculations, when it was committed). We retrieve a buffer + * from each CPU and put it into a priority queue, which sorts + * based on the first entry in the buffer. This is sufficient + * because entries within a buffer are already sorted. + * + * We then consume records one at a time, always consuming the + * oldest record, as determined by the priority queue. When + * we reach the end of the time covered by these buffers, + * we need to stop and retrieve more records on the next pass. + * The kernel tells us the time covered by each buffer, in + * dtbd_timestamp. The first buffer's timestamp tells us the + * time covered by all buffers, as subsequently retrieved + * buffers will cover to a more recent time. + */ - if (!dtp->dt_stopped) - return (0); + uint64_t *drops = alloca(max_ncpus * sizeof (uint64_t)); + uint64_t first_timestamp = 0; + uint_t cookie = 0; + dtrace_bufdesc_t *buf; + + bzero(drops, max_ncpus * sizeof (uint64_t)); + + if (dtp->dt_bufq == NULL) { + dtp->dt_bufq = dt_pq_init(dtp, max_ncpus * 2, + dt_buf_oldest, NULL); + if (dtp->dt_bufq == NULL) /* ENOMEM */ + return (-1); + } - buf->dtbd_cpu = dtp->dt_endedon; + /* Retrieve data from each CPU. */ + (void) dtrace_getopt(dtp, "bufsize", &size); + for (i = 0; i < max_ncpus; i++) { + dtrace_bufdesc_t *buf; + + if (dt_get_buf(dtp, i, &buf) != 0) + return (-1); + if (buf != NULL) { + if (first_timestamp == 0) + first_timestamp = buf->dtbd_timestamp; + assert(buf->dtbd_timestamp >= first_timestamp); + + dt_pq_insert(dtp->dt_bufq, buf); + drops[i] = buf->dtbd_drops; + buf->dtbd_drops = 0; + } + } + + /* Consume records. */ + for (;;) { + dtrace_bufdesc_t *buf = dt_pq_pop(dtp->dt_bufq); + uint64_t timestamp; + + if (buf == NULL) + break; + + timestamp = dt_buf_oldest(buf, dtp); + assert(timestamp >= dtp->dt_last_timestamp); + dtp->dt_last_timestamp = timestamp; + + if (timestamp == buf->dtbd_timestamp) { + /* + * We've reached the end of the time covered + * by this buffer. If this is the oldest + * buffer, we must do another pass + * to retrieve more data. + */ + dt_put_buf(dtp, buf); + if (timestamp == first_timestamp && + !dtp->dt_stopped) + break; + continue; + } + + if ((rval = dt_consume_cpu(dtp, fp, + buf->dtbd_cpu, buf, B_TRUE, pf, rf, arg)) != 0) + return (rval); + dt_pq_insert(dtp->dt_bufq, buf); + } + + /* Consume drops. */ + for (i = 0; i < max_ncpus; i++) { + if (drops[i] != 0) { + int error = dt_handle_cpudrop(dtp, i, + DTRACEDROP_PRINCIPAL, drops[i]); + if (error != 0) + return (error); + } + } -#if defined(sun) - if (dt_ioctl(dtp, DTRACEIOC_BUFSNAP, buf) == -1) { -#else - if (dt_ioctl(dtp, DTRACEIOC_BUFSNAP, &buf) == -1) { -#endif /* - * This _really_ shouldn't fail, but it is strictly speaking - * possible for this to return ENOENT if the CPU that called - * the END enabling somehow managed to become unconfigured. - * It's unclear how the user can possibly expect anything - * rational to happen in this case -- the state has been thrown - * out along with the unconfigured CPU -- so we'll just drive - * on... + * Reduce memory usage by re-allocating smaller buffers + * for the "remnants". */ - if (errno == ENOENT) - return (0); - - return (dt_set_errno(dtp, errno)); + while (buf = dt_pq_walk(dtp->dt_bufq, &cookie)) + dt_realloc_buf(dtp, buf, buf->dtbd_size); *** DIFF OUTPUT TRUNCATED AT 1000 LINES *** From owner-svn-src-all@FreeBSD.ORG Sun May 12 16:29:10 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id 0A209E51; Sun, 12 May 2013 16:29:10 +0000 (UTC) (envelope-from markj@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id F083522A; Sun, 12 May 2013 16:29:09 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.6/8.14.6) with ESMTP id r4CGT9L7078492; Sun, 12 May 2013 16:29:09 GMT (envelope-from markj@svn.freebsd.org) Received: (from markj@localhost) by svn.freebsd.org (8.14.6/8.14.5/Submit) id r4CGT9uT078490; Sun, 12 May 2013 16:29:09 GMT (envelope-from markj@svn.freebsd.org) Message-Id: <201305121629.r4CGT9uT078490@svn.freebsd.org> From: Mark Johnston Date: Sun, 12 May 2013 16:29:09 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r250575 - head/cddl/contrib/opensolaris/cmd/dtrace/test/tst/common/pragma X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 12 May 2013 16:29:10 -0000 Author: markj Date: Sun May 12 16:29:09 2013 New Revision: 250575 URL: http://svnweb.freebsd.org/changeset/base/250575 Log: head -n doesn't take negative arguments on FreeBSD, so instead use sed '$d' to remove the last line of a file. Modified: head/cddl/contrib/opensolaris/cmd/dtrace/test/tst/common/pragma/tst.temporal.ksh head/cddl/contrib/opensolaris/cmd/dtrace/test/tst/common/pragma/tst.temporal2.ksh Modified: head/cddl/contrib/opensolaris/cmd/dtrace/test/tst/common/pragma/tst.temporal.ksh ============================================================================== --- head/cddl/contrib/opensolaris/cmd/dtrace/test/tst/common/pragma/tst.temporal.ksh Sun May 12 16:26:33 2013 (r250574) +++ head/cddl/contrib/opensolaris/cmd/dtrace/test/tst/common/pragma/tst.temporal.ksh Sun May 12 16:29:09 2013 (r250575) @@ -73,8 +73,8 @@ if [ "$status" -ne 0 ]; then fi # dtrace outputs a blank line at the end, which will sort to the beginning, -# so use head to remove the blank line. -head -n -1 $file > $file.2 +# so use sed to remove the blank line. +sed '$d' $file > $file.2 sort -n $file.2 | diff $file.2 - status=$? Modified: head/cddl/contrib/opensolaris/cmd/dtrace/test/tst/common/pragma/tst.temporal2.ksh ============================================================================== --- head/cddl/contrib/opensolaris/cmd/dtrace/test/tst/common/pragma/tst.temporal2.ksh Sun May 12 16:26:33 2013 (r250574) +++ head/cddl/contrib/opensolaris/cmd/dtrace/test/tst/common/pragma/tst.temporal2.ksh Sun May 12 16:29:09 2013 (r250575) @@ -89,8 +89,8 @@ if [ "$status" -ne 0 ]; then fi # dtrace outputs a blank line at the end, which will sort to the beginning, -# so use grep to remove the blank line. -head -n -1 $file > $file.2 +# so use sed to remove the blank line. +sed '$d' $file > $file.2 sort -n $file.2 | diff $file.2 - status=$? From owner-svn-src-all@FreeBSD.ORG Sun May 12 16:43:28 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id C7413229; Sun, 12 May 2013 16:43:28 +0000 (UTC) (envelope-from eadler@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id A7C9D280; Sun, 12 May 2013 16:43:28 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.6/8.14.6) with ESMTP id r4CGhSo6084285; Sun, 12 May 2013 16:43:28 GMT (envelope-from eadler@svn.freebsd.org) Received: (from eadler@localhost) by svn.freebsd.org (8.14.6/8.14.5/Submit) id r4CGhQNm084274; Sun, 12 May 2013 16:43:26 GMT (envelope-from eadler@svn.freebsd.org) Message-Id: <201305121643.r4CGhQNm084274@svn.freebsd.org> From: Eitan Adler Date: Sun, 12 May 2013 16:43:26 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r250576 - in head: lib/libc/posix1e share/man/man7 sys/dev/ata sys/dev/uart sys/dev/usb/serial sys/fs/fdescfs sys/mips/mips sys/netgraph/bluetooth/hci sys/ufs/ffs sys/x86/x86 X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 12 May 2013 16:43:28 -0000 Author: eadler Date: Sun May 12 16:43:26 2013 New Revision: 250576 URL: http://svnweb.freebsd.org/changeset/base/250576 Log: Fix several typos PR: kern/176054 Submitted by: Christoph Mallon MFC after: 3 days Modified: head/lib/libc/posix1e/acl_is_trivial_np.3 head/share/man/man7/c99.7 head/sys/dev/ata/ata-lowlevel.c head/sys/dev/uart/uart_core.c head/sys/dev/usb/serial/usb_serial.c head/sys/dev/usb/serial/usb_serial.h head/sys/fs/fdescfs/fdesc_vnops.c head/sys/mips/mips/stack_machdep.c head/sys/netgraph/bluetooth/hci/ng_hci_ulpi.c head/sys/ufs/ffs/ffs_balloc.c head/sys/x86/x86/local_apic.c Modified: head/lib/libc/posix1e/acl_is_trivial_np.3 ============================================================================== --- head/lib/libc/posix1e/acl_is_trivial_np.3 Sun May 12 16:29:09 2013 (r250575) +++ head/lib/libc/posix1e/acl_is_trivial_np.3 Sun May 12 16:43:26 2013 (r250576) @@ -52,7 +52,7 @@ will be set to 1, if the ACL .Fa aclp points to is trivial, or 0 if it's not. .Pp -ACL is trivial if it can be fully expressed as a file mode without loosing +ACL is trivial if it can be fully expressed as a file mode without losing any access rules. For POSIX.1e ACLs, ACL is trivial if it has the three required entries, one for owner, one for owning group, and one for other. Modified: head/share/man/man7/c99.7 ============================================================================== --- head/share/man/man7/c99.7 Sun May 12 16:29:09 2013 (r250575) +++ head/share/man/man7/c99.7 Sun May 12 16:43:26 2013 (r250576) @@ -70,7 +70,7 @@ The elements of this standard library is complicated tasks. In this case the provided system calls of the given operating system can be used. -To not loose the portability by using these system calls, the POSIX +To not lose the portability by using these system calls, the POSIX (Portable Operating System Interface) standard evolved. It describes what functions should be available to keep portability. Note, that POSIX is not a C standard, but an operating system standard Modified: head/sys/dev/ata/ata-lowlevel.c ============================================================================== --- head/sys/dev/ata/ata-lowlevel.c Sun May 12 16:29:09 2013 (r250575) +++ head/sys/dev/ata/ata-lowlevel.c Sun May 12 16:43:26 2013 (r250576) @@ -503,7 +503,7 @@ ata_generic_reset(device_t dev) mask, ostat0, ostat1); /* if nothing showed up there is no need to get any further */ - /* XXX SOS is that too strong?, we just might loose devices here */ + /* XXX SOS is that too strong?, we just might lose devices here */ ch->devices = 0; if (!mask) return; Modified: head/sys/dev/uart/uart_core.c ============================================================================== --- head/sys/dev/uart/uart_core.c Sun May 12 16:29:09 2013 (r250575) +++ head/sys/dev/uart/uart_core.c Sun May 12 16:43:26 2013 (r250576) @@ -137,7 +137,7 @@ uart_intr_break(void *arg) * much of the data we can, but otherwise flush the receiver FIFO to * create some breathing room. The net effect is that we avoid the * overrun condition to happen for the next X characters, where X is - * related to the FIFO size at the cost of loosing data right away. + * related to the FIFO size at the cost of losing data right away. * So, instead of having multiple overrun interrupts in close proximity * to each other and possibly pessimizing UART interrupt latency for * other UARTs in a multiport configuration, we create a longer segment @@ -192,7 +192,7 @@ uart_intr_rxready(void *arg) * Line or modem status change (OOB signalling). * We pass the signals to the software interrupt handler for further * processing. Note that we merge the delta bits, but set the state - * bits. This is to avoid loosing state transitions due to having more + * bits. This is to avoid losing state transitions due to having more * than 1 hardware interrupt between software interrupts. */ static __inline int Modified: head/sys/dev/usb/serial/usb_serial.c ============================================================================== --- head/sys/dev/usb/serial/usb_serial.c Sun May 12 16:29:09 2013 (r250575) +++ head/sys/dev/usb/serial/usb_serial.c Sun May 12 16:43:26 2013 (r250576) @@ -965,7 +965,7 @@ ucom_cfg_line_state(struct usb_proc_msg sc->sc_pls_set = 0; sc->sc_pls_clr = 0; - /* ensure that we don't loose any levels */ + /* ensure that we don't lose any levels */ if (notch_bits & UCOM_LS_DTR) sc->sc_callback->ucom_cfg_set_dtr(sc, (prev_value & UCOM_LS_DTR) ? 1 : 0); Modified: head/sys/dev/usb/serial/usb_serial.h ============================================================================== --- head/sys/dev/usb/serial/usb_serial.h Sun May 12 16:29:09 2013 (r250575) +++ head/sys/dev/usb/serial/usb_serial.h Sun May 12 16:43:26 2013 (r250576) @@ -146,7 +146,7 @@ struct ucom_super_softc { struct ucom_softc { /* - * NOTE: To avoid loosing level change information we use two + * NOTE: To avoid losing level change information we use two * tasks instead of one for all commands. * * Level changes are transitions like: Modified: head/sys/fs/fdescfs/fdesc_vnops.c ============================================================================== --- head/sys/fs/fdescfs/fdesc_vnops.c Sun May 12 16:29:09 2013 (r250575) +++ head/sys/fs/fdescfs/fdesc_vnops.c Sun May 12 16:43:26 2013 (r250576) @@ -333,7 +333,7 @@ fdesc_lookup(ap) * and the root vnode lock will be obtained afterwards (in case * we're looking up the fd of the root vnode), which will be the * opposite lock order. Vhold the root vnode first so we don't - * loose it. + * lose it. */ vhold(dvp); VOP_UNLOCK(dvp, 0); Modified: head/sys/mips/mips/stack_machdep.c ============================================================================== --- head/sys/mips/mips/stack_machdep.c Sun May 12 16:29:09 2013 (r250575) +++ head/sys/mips/mips/stack_machdep.c Sun May 12 16:43:26 2013 (r250576) @@ -148,7 +148,7 @@ stack_save(struct stack *st) u_register_t pc, sp; if (curthread == NULL) - panic("stack_save: curthread == NULL)"); + panic("stack_save: curthread == NULL"); pc = curthread->td_pcb->pcb_regs.pc; sp = curthread->td_pcb->pcb_regs.sp; Modified: head/sys/netgraph/bluetooth/hci/ng_hci_ulpi.c ============================================================================== --- head/sys/netgraph/bluetooth/hci/ng_hci_ulpi.c Sun May 12 16:29:09 2013 (r250575) +++ head/sys/netgraph/bluetooth/hci/ng_hci_ulpi.c Sun May 12 16:43:26 2013 (r250576) @@ -391,7 +391,7 @@ ng_hci_lp_sco_con_req(ng_hci_unit_p unit default: panic( -"%s: %s - Inavalid connection state=%d\n", +"%s: %s - Invalid connection state=%d\n", __func__, NG_NODE_NAME(unit->node), sco_con->state); break; Modified: head/sys/ufs/ffs/ffs_balloc.c ============================================================================== --- head/sys/ufs/ffs/ffs_balloc.c Sun May 12 16:29:09 2013 (r250575) +++ head/sys/ufs/ffs/ffs_balloc.c Sun May 12 16:43:26 2013 (r250576) @@ -1011,7 +1011,7 @@ fail: * We have to sync it at the end so that the soft updates code * does not find any untracked changes. Although this is really * slow, running out of disk space is not expected to be a common - * occurence. The error return from fsync is ignored as we already + * occurrence. The error return from fsync is ignored as we already * have an error to return to the user. * * XXX Still have to journal the free below Modified: head/sys/x86/x86/local_apic.c ============================================================================== --- head/sys/x86/x86/local_apic.c Sun May 12 16:29:09 2013 (r250575) +++ head/sys/x86/x86/local_apic.c Sun May 12 16:43:26 2013 (r250576) @@ -789,7 +789,7 @@ lapic_handle_timer(struct trapframe *fra * Don't do any accounting for the disabled HTT cores, since it * will provide misleading numbers for the userland. * - * No locking is necessary here, since even if we loose the race + * No locking is necessary here, since even if we lose the race * when hlt_cpus_mask changes it is not a big deal, really. * * Don't do that for ULE, since ULE doesn't consider hlt_cpus_mask From owner-svn-src-all@FreeBSD.ORG Sun May 12 16:50:20 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id 2D9AD5F8; Sun, 12 May 2013 16:50:20 +0000 (UTC) (envelope-from alc@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id 205322B6; Sun, 12 May 2013 16:50:20 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.6/8.14.6) with ESMTP id r4CGoJ9q087154; Sun, 12 May 2013 16:50:19 GMT (envelope-from alc@svn.freebsd.org) Received: (from alc@localhost) by svn.freebsd.org (8.14.6/8.14.5/Submit) id r4CGoJL0087149; Sun, 12 May 2013 16:50:19 GMT (envelope-from alc@svn.freebsd.org) Message-Id: <201305121650.r4CGoJL0087149@svn.freebsd.org> From: Alan Cox Date: Sun, 12 May 2013 16:50:19 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r250577 - head/sys/vm X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 12 May 2013 16:50:20 -0000 Author: alc Date: Sun May 12 16:50:18 2013 New Revision: 250577 URL: http://svnweb.freebsd.org/changeset/base/250577 Log: Refactor vm_page_alloc()'s interactions with vm_reserv_alloc_page() and vm_page_insert() so that (1) vm_radix_lookup_le() is never called while the free page queues lock is held and (2) vm_radix_lookup_le() is called at most once. This change reduces the average time that the free page queues lock is held by vm_page_alloc() as well as vm_page_alloc()'s average overall running time. Sponsored by: EMC / Isilon Storage Division Modified: head/sys/vm/vm_page.c head/sys/vm/vm_reserv.c head/sys/vm/vm_reserv.h Modified: head/sys/vm/vm_page.c ============================================================================== --- head/sys/vm/vm_page.c Sun May 12 16:43:26 2013 (r250576) +++ head/sys/vm/vm_page.c Sun May 12 16:50:18 2013 (r250577) @@ -161,6 +161,8 @@ static struct vnode *vm_page_alloc_init( static void vm_page_clear_dirty_mask(vm_page_t m, vm_page_bits_t pagebits); static void vm_page_enqueue(int queue, vm_page_t m); static void vm_page_init_fakepg(void *dummy); +static void vm_page_insert_after(vm_page_t m, vm_object_t object, + vm_pindex_t pindex, vm_page_t mpred); SYSINIT(vm_page, SI_SUB_VM, SI_ORDER_SECOND, vm_page_init_fakepg, NULL); @@ -809,11 +811,44 @@ vm_page_dirty_KBI(vm_page_t m) void vm_page_insert(vm_page_t m, vm_object_t object, vm_pindex_t pindex) { - vm_page_t neighbor; + vm_page_t mpred; VM_OBJECT_ASSERT_WLOCKED(object); - if (m->object != NULL) - panic("vm_page_insert: page already inserted"); + mpred = vm_radix_lookup_le(&object->rtree, pindex); + vm_page_insert_after(m, object, pindex, mpred); +} + +/* + * vm_page_insert_after: + * + * Inserts the page "m" into the specified object at offset "pindex". + * + * The page "mpred" must immediately precede the offset "pindex" within + * the specified object. + * + * The object must be locked. + */ +static void +vm_page_insert_after(vm_page_t m, vm_object_t object, vm_pindex_t pindex, + vm_page_t mpred) +{ + vm_page_t msucc; + + VM_OBJECT_ASSERT_WLOCKED(object); + KASSERT(m->object == NULL, + ("vm_page_insert_after: page already inserted")); + if (mpred != NULL) { + KASSERT(mpred->object == object || + (mpred->flags & PG_SLAB) != 0, + ("vm_page_insert_after: object doesn't contain mpred")); + KASSERT(mpred->pindex < pindex, + ("vm_page_insert_after: mpred doesn't precede pindex")); + msucc = TAILQ_NEXT(mpred, listq); + } else + msucc = TAILQ_FIRST(&object->memq); + if (msucc != NULL) + KASSERT(msucc->pindex > pindex, + ("vm_page_insert_after: msucc doesn't succeed pindex")); /* * Record the object/offset pair in this page @@ -824,18 +859,10 @@ vm_page_insert(vm_page_t m, vm_object_t /* * Now link into the object's ordered list of backed pages. */ - if (object->resident_page_count == 0) { - TAILQ_INSERT_TAIL(&object->memq, m, listq); - } else { - neighbor = vm_radix_lookup_le(&object->rtree, pindex); - if (neighbor != NULL) { - KASSERT(pindex > neighbor->pindex, - ("vm_page_insert: offset %ju less than %ju", - (uintmax_t)pindex, (uintmax_t)neighbor->pindex)); - TAILQ_INSERT_AFTER(&object->memq, neighbor, m, listq); - } else - TAILQ_INSERT_HEAD(&object->memq, m, listq); - } + if (mpred != NULL) + TAILQ_INSERT_AFTER(&object->memq, mpred, m, listq); + else + TAILQ_INSERT_HEAD(&object->memq, m, listq); vm_radix_insert(&object->rtree, m); /* @@ -1179,7 +1206,7 @@ vm_page_alloc(vm_object_t object, vm_pin { struct vnode *vp = NULL; vm_object_t m_object; - vm_page_t m; + vm_page_t m, mpred; int flags, req_class; KASSERT((object != NULL) == ((req & VM_ALLOC_NOOBJ) == 0), @@ -1195,6 +1222,11 @@ vm_page_alloc(vm_object_t object, vm_pin if (curproc == pageproc && req_class != VM_ALLOC_INTERRUPT) req_class = VM_ALLOC_SYSTEM; + if (object != NULL) { + mpred = vm_radix_lookup_le(&object->rtree, pindex); + KASSERT(mpred == NULL || mpred->pindex != pindex, + ("vm_page_alloc: pindex already allocated")); + } mtx_lock(&vm_page_queue_free_mtx); if (cnt.v_free_count + cnt.v_cache_count > cnt.v_free_reserved || (req_class == VM_ALLOC_SYSTEM && @@ -1225,8 +1257,8 @@ vm_page_alloc(vm_object_t object, vm_pin return (NULL); #if VM_NRESERVLEVEL > 0 } else if (object == NULL || (object->flags & (OBJ_COLORED | - OBJ_FICTITIOUS)) != OBJ_COLORED || - (m = vm_reserv_alloc_page(object, pindex)) == NULL) { + OBJ_FICTITIOUS)) != OBJ_COLORED || (m = + vm_reserv_alloc_page(object, pindex, mpred)) == NULL) { #else } else { #endif @@ -1320,7 +1352,7 @@ vm_page_alloc(vm_object_t object, vm_pin if (object->memattr != VM_MEMATTR_DEFAULT && (object->flags & OBJ_FICTITIOUS) == 0) pmap_page_set_memattr(m, object->memattr); - vm_page_insert(m, object, pindex); + vm_page_insert_after(m, object, pindex, mpred); } else m->pindex = pindex; Modified: head/sys/vm/vm_reserv.c ============================================================================== --- head/sys/vm/vm_reserv.c Sun May 12 16:43:26 2013 (r250576) +++ head/sys/vm/vm_reserv.c Sun May 12 16:50:18 2013 (r250577) @@ -476,12 +476,15 @@ found: /* * Allocates a page from an existing or newly-created reservation. * + * The page "mpred" must immediately precede the offset "pindex" within the + * specified object. + * * The object and free page queue must be locked. */ vm_page_t -vm_reserv_alloc_page(vm_object_t object, vm_pindex_t pindex) +vm_reserv_alloc_page(vm_object_t object, vm_pindex_t pindex, vm_page_t mpred) { - vm_page_t m, mpred, msucc; + vm_page_t m, msucc; vm_pindex_t first, leftcap, rightcap; vm_reserv_t rv; @@ -498,10 +501,12 @@ vm_reserv_alloc_page(vm_object_t object, /* * Look for an existing reservation. */ - mpred = vm_radix_lookup_le(&object->rtree, pindex); if (mpred != NULL) { + KASSERT(mpred->object == object || + (mpred->flags & PG_SLAB) != 0, + ("vm_reserv_alloc_page: object doesn't contain mpred")); KASSERT(mpred->pindex < pindex, - ("vm_reserv_alloc_page: pindex already allocated")); + ("vm_reserv_alloc_page: mpred doesn't precede pindex")); rv = vm_reserv_from_page(mpred); if (rv->object == object && vm_reserv_has_pindex(rv, pindex)) goto found; @@ -510,7 +515,7 @@ vm_reserv_alloc_page(vm_object_t object, msucc = TAILQ_FIRST(&object->memq); if (msucc != NULL) { KASSERT(msucc->pindex > pindex, - ("vm_reserv_alloc_page: pindex already allocated")); + ("vm_reserv_alloc_page: msucc doesn't succeed pindex")); rv = vm_reserv_from_page(msucc); if (rv->object == object && vm_reserv_has_pindex(rv, pindex)) goto found; Modified: head/sys/vm/vm_reserv.h ============================================================================== --- head/sys/vm/vm_reserv.h Sun May 12 16:43:26 2013 (r250576) +++ head/sys/vm/vm_reserv.h Sun May 12 16:50:18 2013 (r250577) @@ -48,7 +48,8 @@ vm_page_t vm_reserv_alloc_contig(vm_object_t object, vm_pindex_t pindex, u_long npages, vm_paddr_t low, vm_paddr_t high, u_long alignment, vm_paddr_t boundary); -vm_page_t vm_reserv_alloc_page(vm_object_t object, vm_pindex_t pindex); +vm_page_t vm_reserv_alloc_page(vm_object_t object, vm_pindex_t pindex, + vm_page_t mpred); void vm_reserv_break_all(vm_object_t object); boolean_t vm_reserv_free_page(vm_page_t m); void vm_reserv_init(void); From owner-svn-src-all@FreeBSD.ORG Sun May 12 20:24:46 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id 9E2E0864; Sun, 12 May 2013 20:24:46 +0000 (UTC) (envelope-from mjacob@freebsd.org) Received: from virtual.feral.com (virtual.feral.com [216.224.170.83]) by mx1.freebsd.org (Postfix) with ESMTP id 6A0A2D42; Sun, 12 May 2013 20:24:46 +0000 (UTC) Received: from [192.168.136.3] (76-14-48-84.sf-cable.astound.net [76.14.48.84] (may be forged)) by virtual.feral.com (8.14.4/8.14.4) with ESMTP id r4CKNh0t027075 (version=TLSv1/SSLv3 cipher=DHE-RSA-CAMELLIA256-SHA bits=256 verify=NO); Sun, 12 May 2013 13:23:44 -0700 Message-ID: <518FFA4B.9080505@freebsd.org> Date: Sun, 12 May 2013 13:23:39 -0700 From: Matthew Jacob Organization: FreeBSD User-Agent: Mozilla/5.0 (Windows NT 6.1; WOW64; rv:17.0) Gecko/20130328 Thunderbird/17.0.5 MIME-Version: 1.0 To: Dmitry Morozovsky Subject: Re: svn commit: r250565 - head/etc References: <201305121523.r4CFNxBR055568@svn.freebsd.org> In-Reply-To: Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-4.2.7 (virtual.feral.com [216.224.170.83]); Sun, 12 May 2013 13:23:45 -0700 (PDT) Cc: svn-src-head@freebsd.org, svn-src-all@freebsd.org, src-committers@freebsd.org, Eitan Adler X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list Reply-To: mjacob@freebsd.org List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 12 May 2013 20:24:46 -0000 On 5/12/2013 8:54 AM, Dmitry Morozovsky wrote: > On Sun, 12 May 2013, Eitan Adler wrote: > >> Author: eadler >> Date: Sun May 12 15:23:59 2013 >> New Revision: 250565 >> URL: http://svnweb.freebsd.org/changeset/base/250565 >> >> Log: >> Make newsyslog compress logs with xz instead of bzip2 to save space. > While it may be useful for contemporary x64 machines, where CPU power is not an > issue, I'm afraid it could produce more harm than goodness on old hardware > and/or other architectures like arm. > > +1 From owner-svn-src-all@FreeBSD.ORG Sun May 12 20:44:29 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id 15AC4E2E; Sun, 12 May 2013 20:44:29 +0000 (UTC) (envelope-from jeff@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id 08569DF9; Sun, 12 May 2013 20:44:29 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.6/8.14.6) with ESMTP id r4CKiS9I069115; Sun, 12 May 2013 20:44:28 GMT (envelope-from jeff@svn.freebsd.org) Received: (from jeff@localhost) by svn.freebsd.org (8.14.6/8.14.5/Submit) id r4CKiSeR069114; Sun, 12 May 2013 20:44:28 GMT (envelope-from jeff@svn.freebsd.org) Message-Id: <201305122044.r4CKiSeR069114@svn.freebsd.org> From: Jeff Roberson Date: Sun, 12 May 2013 20:44:28 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r250578 - head/sys/sys X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 12 May 2013 20:44:29 -0000 Author: jeff Date: Sun May 12 20:44:28 2013 New Revision: 250578 URL: http://svnweb.freebsd.org/changeset/base/250578 Log: - pctrie really only requires two byte alignment so that there is a single bit available for a flag in the pointer. However, it felt more correct to enforce natural alignment of the key pointer. Unfortunately on 32bit architectures 64bit integers are not always naturally aligned. Change the assert to enforce only 32bit alignment of the 64bit key for now to fix the build. A more correct fix would be to properly sort the struct buf fields which definitely suffer from bloat due to padding. Modified: head/sys/sys/pctrie.h Modified: head/sys/sys/pctrie.h ============================================================================== --- head/sys/sys/pctrie.h Sun May 12 16:50:18 2013 (r250577) +++ head/sys/sys/pctrie.h Sun May 12 20:44:28 2013 (r250578) @@ -38,7 +38,11 @@ #define PCTRIE_DEFINE(name, type, field, allocfn, freefn) \ \ CTASSERT(sizeof(((struct type *)0)->field) == sizeof(uint64_t)); \ -CTASSERT((__offsetof(struct type, field) & (sizeof(uint64_t) - 1)) == 0); \ +/* \ + * XXX This assert protects flag bits, it does not enforce natural \ + * alignment. 32bit architectures do not naturally align 64bit fields. \ + */ \ +CTASSERT((__offsetof(struct type, field) & (sizeof(uint32_t) - 1)) == 0); \ \ static __inline struct type * \ name##_PCTRIE_VAL2PTR(uint64_t *val) \ From owner-svn-src-all@FreeBSD.ORG Sun May 12 20:51:51 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id ED4511DE; Sun, 12 May 2013 20:51:51 +0000 (UTC) (envelope-from baptiste.daroussin@gmail.com) Received: from mail-we0-x22e.google.com (mail-we0-x22e.google.com [IPv6:2a00:1450:400c:c03::22e]) by mx1.freebsd.org (Postfix) with ESMTP id DBA87E41; Sun, 12 May 2013 20:51:50 +0000 (UTC) Received: by mail-we0-f174.google.com with SMTP id x53so5641316wes.19 for ; Sun, 12 May 2013 13:51:50 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=x-received:sender:date:from:to:cc:subject:message-id:references :mime-version:content-type:content-disposition:in-reply-to :user-agent; bh=zx5WSDKadaI6Kgjib/Yk4k2+yB+Tbg/BCEUpnZFfAUI=; b=dcHjwZlNiNGui5ltrBuiomP72tQ4H4n9xfaugetnFR1mnqLrD/AxQXARUgp8WbzJPB iImhcdVH+Nr1Bz1LMPDfeNTfVArhpqzJOtzxKtkWcctJsIxKO3WTmgad54ZAftuUMAzj T+32CFRwvlgq02PbnLcLcbyCHXfMuEKkvWc01vHmxYWpc0Ft7JxOH51WFAPge48y7tou QijLGlmoLa2JCXqgENlFdJx70Hr+SlSpKeBvAqPkIDBPWTkwX85dwZKtxmcXDK04cZ/T cj82SVCOizzMJ+jvbkV3aXKOnZfq676muZgnE/vWomvfr7w/LLrNxE8rwdfswW3e4X0H iYEg== X-Received: by 10.180.185.44 with SMTP id ez12mr14615011wic.7.1368391909972; Sun, 12 May 2013 13:51:49 -0700 (PDT) Received: from ithaqua.etoilebsd.net (ithaqua.etoilebsd.net. [37.59.37.188]) by mx.google.com with ESMTPSA id dj7sm11714062wib.6.2013.05.12.13.51.48 for (version=TLSv1 cipher=RC4-SHA bits=128/128); Sun, 12 May 2013 13:51:48 -0700 (PDT) Sender: Baptiste Daroussin Date: Sun, 12 May 2013 22:51:46 +0200 From: Baptiste Daroussin To: Matthew Jacob Subject: Re: svn commit: r250565 - head/etc Message-ID: <20130512205146.GZ91136@ithaqua.etoilebsd.net> References: <201305121523.r4CFNxBR055568@svn.freebsd.org> <518FFA4B.9080505@freebsd.org> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="XLRYXLjFvhZHhWey" Content-Disposition: inline In-Reply-To: <518FFA4B.9080505@freebsd.org> User-Agent: Mutt/1.5.21 (2010-09-15) Cc: svn-src-head@freebsd.org, svn-src-all@freebsd.org, src-committers@freebsd.org, Eitan Adler , Dmitry Morozovsky X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 12 May 2013 20:51:52 -0000 --XLRYXLjFvhZHhWey Content-Type: text/plain; charset=us-ascii Content-Disposition: inline On Sun, May 12, 2013 at 01:23:39PM -0700, Matthew Jacob wrote: > On 5/12/2013 8:54 AM, Dmitry Morozovsky wrote: > > On Sun, 12 May 2013, Eitan Adler wrote: > > > >> Author: eadler > >> Date: Sun May 12 15:23:59 2013 > >> New Revision: 250565 > >> URL: http://svnweb.freebsd.org/changeset/base/250565 > >> > >> Log: > >> Make newsyslog compress logs with xz instead of bzip2 to save space. > > While it may be useful for contemporary x64 machines, where CPU power is not an > > issue, I'm afraid it could produce more harm than goodness on old hardware > > and/or other architectures like arm. > > > > > +1 iirc there was a discussion about it a year or 2 ago, where it was stated that most of the time the gain of using xz for newsyslog was insignificant, pretty much no space saved, but the loss in cpu time was significant. Bapt --XLRYXLjFvhZHhWey Content-Type: application/pgp-signature -----BEGIN PGP SIGNATURE----- Version: GnuPG v2.0.19 (FreeBSD) iEYEARECAAYFAlGQAOIACgkQ8kTtMUmk6EzuAACgiULUIAngSv5OyPA0GhP9oaPM rYgAoJ6CWRRBSgNa3OPVTxMOl5pInpXp =11ES -----END PGP SIGNATURE----- --XLRYXLjFvhZHhWey-- From owner-svn-src-all@FreeBSD.ORG Sun May 12 21:10:24 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id CFC1B85D for ; Sun, 12 May 2013 21:10:24 +0000 (UTC) (envelope-from pfg@FreeBSD.org) Received: from nm9-vm6.bullet.mail.gq1.yahoo.com (nm9-vm6.bullet.mail.gq1.yahoo.com [98.136.218.245]) by mx1.freebsd.org (Postfix) with SMTP id 9C09EF61 for ; Sun, 12 May 2013 21:10:23 +0000 (UTC) Received: from [98.137.12.190] by nm9.bullet.mail.gq1.yahoo.com with NNFMP; 12 May 2013 21:03:32 -0000 Received: from [208.71.42.193] by tm11.bullet.mail.gq1.yahoo.com with NNFMP; 12 May 2013 21:03:32 -0000 Received: from [127.0.0.1] by smtp204.mail.gq1.yahoo.com with NNFMP; 12 May 2013 21:03:32 -0000 X-Yahoo-Newman-Id: 28034.35442.bm@smtp204.mail.gq1.yahoo.com X-Yahoo-Newman-Property: ymail-3 X-YMail-OSG: qzxfWXAVM1nTemVIYs0NPnS2BNTqeUMHwpEoBIcsNPYB3w. YHcHnioSJpKJ9ccCSPZOdrlIDXTwC1ZEoyRv9f8DnKUf1VIaMCFhz2ZTNBXT vTxWiiKHOOhXmAr2zGDc0axbb3hCdeoR9O3HJ6.d12uIAQmpA8Ek4CoO2GwR TwpBF70glo2OVqqeMlLuVNL20wI0VDhIF2RjV6lNUIqJACd1gfoVwGRf_Bsw ApxDzlw4L3WRdYDVLUikHB2bgUXG2eYyLQXgBcNnNUY55we7vAJCtQEntaX7 FYWlX.Qw1Xn2sPJ7R.axAlaKfVpindXve9yLX3YbnDnkHVCbW4w35m3uo6Jy DPZNvjCHR2mbzPjyirdqRCCmhizYhMSMp4yO779m0VWtV_N3rTN8lNuqtYNy 8VdSmiv.HXZS4hbM0668oJwFi77oetL_q5Fk3bKM85UuIi0m5fi071eVDCNG ZnyxAE516igBcpW1AI53bbWHaOVZCy1PCNNLGxm_DeM19pDkfKI.anyTUdTs phvDmFRH0EhO2OBH_ZK_y1GRQGDJD8RBsLJTmqLtx2XLEECg12Elytt1pMbb HVfsfFhG7Axl2bbhDyA-- X-Yahoo-SMTP: xcjD0guswBAZaPPIbxpWwLcp9Unf X-Rocket-Received: from [192.168.0.102] (pfg@190.157.126.109 with ) by smtp204.mail.gq1.yahoo.com with SMTP; 12 May 2013 14:03:31 -0700 PDT Message-ID: <5190038F.6000609@FreeBSD.org> Date: Sun, 12 May 2013 16:03:11 -0500 From: Pedro Giffuni User-Agent: Mozilla/5.0 (X11; FreeBSD amd64; rv:17.0) Gecko/20130407 Thunderbird/17.0.5 MIME-Version: 1.0 To: Eitan Adler Subject: Re: svn commit: r250565 - head/etc References: <201305121523.r4CFNxBR055568@svn.freebsd.org> <518FFA4B.9080505@freebsd.org> In-Reply-To: <518FFA4B.9080505@freebsd.org> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit Cc: svn-src-head@freebsd.org, svn-src-all@freebsd.org, src-committers@freebsd.org X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 12 May 2013 21:10:24 -0000 On 05/12/2013 15:23, Matthew Jacob wrote: > On 5/12/2013 8:54 AM, Dmitry Morozovsky wrote: >> On Sun, 12 May 2013, Eitan Adler wrote: >> >>> Author: eadler >>> Date: Sun May 12 15:23:59 2013 >>> New Revision: 250565 >>> URL: http://svnweb.freebsd.org/changeset/base/250565 >>> >>> Log: >>> Make newsyslog compress logs with xz instead of bzip2 to save space. >> While it may be useful for contemporary x64 machines, where CPU power >> is not an >> issue, I'm afraid it could produce more harm than goodness on old >> hardware >> and/or other architectures like arm. >> >> > +1 +1 BTW, there are some nice BSD licensed compression utilities nowadays (snappy, lz4) that make more emphasis on performance without being bad at all with compression. Pedro. From owner-svn-src-all@FreeBSD.ORG Sun May 12 21:14:37 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id A16FDAC8; Sun, 12 May 2013 21:14:37 +0000 (UTC) (envelope-from marck@rinet.ru) Received: from woozle.rinet.ru (woozle.rinet.ru [195.54.192.68]) by mx1.freebsd.org (Postfix) with ESMTP id F2C6FF78; Sun, 12 May 2013 21:14:36 +0000 (UTC) Received: from localhost (localhost [127.0.0.1]) by woozle.rinet.ru (8.14.5/8.14.5) with ESMTP id r4CLEZB6077368; Mon, 13 May 2013 01:14:35 +0400 (MSK) (envelope-from marck@rinet.ru) Date: Mon, 13 May 2013 01:14:35 +0400 (MSK) From: Dmitry Morozovsky To: Baptiste Daroussin Subject: Re: svn commit: r250565 - head/etc In-Reply-To: <20130512205146.GZ91136@ithaqua.etoilebsd.net> Message-ID: References: <201305121523.r4CFNxBR055568@svn.freebsd.org> <518FFA4B.9080505@freebsd.org> <20130512205146.GZ91136@ithaqua.etoilebsd.net> User-Agent: Alpine 2.00 (BSF 1167 2008-08-23) X-NCC-RegID: ru.rinet X-OpenPGP-Key-ID: 6B691B03 MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-4.4.3 (woozle.rinet.ru [0.0.0.0]); Mon, 13 May 2013 01:14:35 +0400 (MSK) Cc: svn-src-head@freebsd.org, svn-src-all@freebsd.org, src-committers@freebsd.org, Eitan Adler , Matthew Jacob X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 12 May 2013 21:14:37 -0000 On Sun, 12 May 2013, Baptiste Daroussin wrote: > > >> Log: > > >> Make newsyslog compress logs with xz instead of bzip2 to save space. > > > While it may be useful for contemporary x64 machines, where CPU power is not an > > > issue, I'm afraid it could produce more harm than goodness on old hardware > > > and/or other architectures like arm. > > > > > > > > +1 > > iirc there was a discussion about it a year or 2 ago, where it was stated that > most of the time the gain of using xz for newsyslog was insignificant, pretty > much no space saved, but the loss in cpu time was significant. I've just prepared quick test to be feeded to ministat, but preliminary results are: on *real* contemporary server hw.model: Intel(R) Xeon(R) CPU X5650 @ 2.67GHz hw.ncpu: 12 amd64 stable/9 ~1.5G maillog on md (and otherwise unloaded machine, LA <.3) is compressed to: method realtm arsize ==================== gzip 45s 183M bzip2 5m32s 115M xz 11m43s 112M all archivers are used without any special switches, just $arch <$log >$log.$suffix I would tend to use xz for distributives (including freebsd-updates or portsnap), where compression process is quite rare, but download size is significant -- but not for logs, backups, or other similar once-packed data... -- Sincerely, D.Marck [DM5020, MCK-RIPE, DM3-RIPN] [ FreeBSD committer: marck@FreeBSD.org ] ------------------------------------------------------------------------ *** Dmitry Morozovsky --- D.Marck --- Wild Woozle --- marck@rinet.ru *** ------------------------------------------------------------------------ From owner-svn-src-all@FreeBSD.ORG Sun May 12 21:24:18 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id C9A44D52; Sun, 12 May 2013 21:24:18 +0000 (UTC) (envelope-from eadler@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id A30E8FD0; Sun, 12 May 2013 21:24:18 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.6/8.14.6) with ESMTP id r4CLOIx4083365; Sun, 12 May 2013 21:24:18 GMT (envelope-from eadler@svn.freebsd.org) Received: (from eadler@localhost) by svn.freebsd.org (8.14.6/8.14.5/Submit) id r4CLOI8v083364; Sun, 12 May 2013 21:24:18 GMT (envelope-from eadler@svn.freebsd.org) Message-Id: <201305122124.r4CLOI8v083364@svn.freebsd.org> From: Eitan Adler Date: Sun, 12 May 2013 21:24:18 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r250579 - head/etc X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 12 May 2013 21:24:18 -0000 Author: eadler Date: Sun May 12 21:24:18 2013 New Revision: 250579 URL: http://svnweb.freebsd.org/changeset/base/250579 Log: Revert r250565 which causes issues for older CPUs PR: conf/178504 Requested by: many Modified: head/etc/newsyslog.conf Modified: head/etc/newsyslog.conf ============================================================================== --- head/etc/newsyslog.conf Sun May 12 20:44:28 2013 (r250578) +++ head/etc/newsyslog.conf Sun May 12 21:24:18 2013 (r250579) @@ -17,23 +17,23 @@ # future, these defaults may change to more conservative ones. # # logfilename [owner:group] mode count size when flags [/pid_file] [sig_num] -/var/log/all.log 600 7 * @T00 X -/var/log/amd.log 644 7 100 * X -/var/log/auth.log 600 7 100 @0101T XC -/var/log/console.log 600 5 100 * X -/var/log/cron 600 3 100 * XC -/var/log/daily.log 640 7 * @T00 XN -/var/log/debug.log 600 7 100 * XC -/var/log/init.log 644 3 100 * X -/var/log/kerberos.log 600 7 100 * X -/var/log/lpd-errs 644 7 100 * XC -/var/log/maillog 640 7 * @T00 XC -/var/log/messages 644 5 100 @0101T XC -/var/log/monthly.log 640 12 * $M1D0 XN -/var/log/pflog 600 3 100 * XB /var/run/pflogd.pid -/var/log/ppp.log root:network 640 3 100 * XC -/var/log/security 600 10 100 * XC +/var/log/all.log 600 7 * @T00 J +/var/log/amd.log 644 7 100 * J +/var/log/auth.log 600 7 100 @0101T JC +/var/log/console.log 600 5 100 * J +/var/log/cron 600 3 100 * JC +/var/log/daily.log 640 7 * @T00 JN +/var/log/debug.log 600 7 100 * JC +/var/log/init.log 644 3 100 * J +/var/log/kerberos.log 600 7 100 * J +/var/log/lpd-errs 644 7 100 * JC +/var/log/maillog 640 7 * @T00 JC +/var/log/messages 644 5 100 @0101T JC +/var/log/monthly.log 640 12 * $M1D0 JN +/var/log/pflog 600 3 100 * JB /var/run/pflogd.pid +/var/log/ppp.log root:network 640 3 100 * JC +/var/log/security 600 10 100 * JC /var/log/sendmail.st 640 10 * 168 BN /var/log/utx.log 644 3 * @01T05 B -/var/log/weekly.log 640 5 * $W6D0 XN -/var/log/xferlog 600 7 100 * XC +/var/log/weekly.log 640 5 * $W6D0 JN +/var/log/xferlog 600 7 100 * JC From owner-svn-src-all@FreeBSD.ORG Sun May 12 21:28:15 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id 90CC3F15 for ; Sun, 12 May 2013 21:28:15 +0000 (UTC) (envelope-from lists@eitanadler.com) Received: from mail-pd0-f175.google.com (mail-pd0-f175.google.com [209.85.192.175]) by mx1.freebsd.org (Postfix) with ESMTP id 6AE7AFFE for ; Sun, 12 May 2013 21:28:15 +0000 (UTC) Received: by mail-pd0-f175.google.com with SMTP id y14so3940997pdi.34 for ; Sun, 12 May 2013 14:28:09 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=eitanadler.com; s=0xdeadbeef; h=x-received:mime-version:sender:in-reply-to:references:from:date :x-google-sender-auth:message-id:subject:to:cc:content-type; bh=q9ngwntsVyr6EiFCToU2M4cvwiNbHVccrcHjAhMTScA=; b=ojjVejZugPKvdfAupEeIrH1oBKF+faa2Iv7ilNJWk1S9L5YR6Gh0/yt9Iv2bsLLmqr YgzThw8Ujn3Y8xdM7cOH9+f748aEqRnSoTgiujwUFs698IHKq1uRwrvxwTMCS/YN11jA cuAd6iTFkz4UznNmRv66emjHwygleMUFRzyBE= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20120113; h=x-received:mime-version:sender:in-reply-to:references:from:date :x-google-sender-auth:message-id:subject:to:cc:content-type :x-gm-message-state; bh=q9ngwntsVyr6EiFCToU2M4cvwiNbHVccrcHjAhMTScA=; b=FDshkIjz8zi4RFuaDdtB1JI/Kg6jqnXuROYYa1vke0e9Hd+FYrjRXlolfXCn/AYyzi N98AieEQmNU73nYIWMu0L5RAHGXfOuQbOjAmPP233ZlG1fSQcJn11wDEhpNAXtclkiEp pW39jLxIkpuEIfN4dQp6s+Bv66mEOz5uvt1hdnaTgIHRJ720xBJ+jD3nXcHUeTPicwyc IRS3M2bqdWFLAZh/TzfgDw1XGT/DkHAHHg3qNcIIc7JLSF1l6GfO0KVYXhcJtuX9Z/5+ t9DIrwoJUUV+6IYcjD0dW+bskGh2qeEuug+PfGVlrSAFBkQ7gFvoYmn2aUswckODa4K7 VeWQ== X-Received: by 10.66.216.198 with SMTP id os6mr26601691pac.145.1368394089363; Sun, 12 May 2013 14:28:09 -0700 (PDT) MIME-Version: 1.0 Sender: lists@eitanadler.com Received: by 10.70.67.130 with HTTP; Sun, 12 May 2013 14:27:39 -0700 (PDT) In-Reply-To: References: <201305121523.r4CFNxBR055568@svn.freebsd.org> From: Eitan Adler Date: Sun, 12 May 2013 17:27:39 -0400 X-Google-Sender-Auth: 0RNj0bsyWm3VFKANIjina1yKorA Message-ID: Subject: Re: svn commit: r250565 - head/etc To: Dmitry Morozovsky Content-Type: text/plain; charset=UTF-8 X-Gm-Message-State: ALoCoQluyIOqk1lfcWkWH4t1KZ66n/5xaC2ebOt8o9YBsP2r0LOEZ4IAA1NsEq+re+e1AhDEN/v1 Cc: svn-src-head@freebsd.org, svn-src-all@freebsd.org, src-committers@freebsd.org X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 12 May 2013 21:28:15 -0000 On 12 May 2013 11:54, Dmitry Morozovsky wrote: > On Sun, 12 May 2013, Eitan Adler wrote: > >> Author: eadler >> Date: Sun May 12 15:23:59 2013 >> New Revision: 250565 >> URL: http://svnweb.freebsd.org/changeset/base/250565 >> >> Log: >> Make newsyslog compress logs with xz instead of bzip2 to save space. > > While it may be useful for contemporary x64 machines, where CPU power is not an > issue, I'm afraid it could produce more harm than goodness on old hardware > and/or other architectures like arm. > > Do you have any estimation chart on different CPUs and architectures? I tend to be of the opinion that defaults can be changed... ... but by request I reverted this change. -- Eitan Adler Source, Ports, Doc committer Bugmeister, Ports Security teams From owner-svn-src-all@FreeBSD.ORG Sun May 12 21:29:04 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id DC0B1153; Sun, 12 May 2013 21:29:04 +0000 (UTC) (envelope-from marck@rinet.ru) Received: from woozle.rinet.ru (woozle.rinet.ru [195.54.192.68]) by mx1.freebsd.org (Postfix) with ESMTP id 6BDAA69; Sun, 12 May 2013 21:29:04 +0000 (UTC) Received: from localhost (localhost [127.0.0.1]) by woozle.rinet.ru (8.14.5/8.14.5) with ESMTP id r4CLT37X077684; Mon, 13 May 2013 01:29:03 +0400 (MSK) (envelope-from marck@rinet.ru) Date: Mon, 13 May 2013 01:29:03 +0400 (MSK) From: Dmitry Morozovsky To: Eitan Adler Subject: Re: svn commit: r250579 - head/etc In-Reply-To: <201305122124.r4CLOI8v083364@svn.freebsd.org> Message-ID: References: <201305122124.r4CLOI8v083364@svn.freebsd.org> User-Agent: Alpine 2.00 (BSF 1167 2008-08-23) X-NCC-RegID: ru.rinet X-OpenPGP-Key-ID: 6B691B03 MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-4.4.3 (woozle.rinet.ru [0.0.0.0]); Mon, 13 May 2013 01:29:03 +0400 (MSK) Cc: svn-src-head@freebsd.org, svn-src-all@freebsd.org, src-committers@freebsd.org X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 12 May 2013 21:29:04 -0000 On Sun, 12 May 2013, Eitan Adler wrote: > Author: eadler > Date: Sun May 12 21:24:18 2013 > New Revision: 250579 > URL: http://svnweb.freebsd.org/changeset/base/250579 > > Log: > Revert r250565 which causes issues for older CPUs > > PR: conf/178504 > Requested by: many Thank you! BTW, isn't it time when we could increase default rotate size from 100 kB to, well, possibly 5M or something? It should fit even into standard md-backed /var on a diskless machine (which I suppose should be grown to somewhat more useful size as well) -- Sincerely, D.Marck [DM5020, MCK-RIPE, DM3-RIPN] [ FreeBSD committer: marck@FreeBSD.org ] ------------------------------------------------------------------------ *** Dmitry Morozovsky --- D.Marck --- Wild Woozle --- marck@rinet.ru *** ------------------------------------------------------------------------ From owner-svn-src-all@FreeBSD.ORG Sun May 12 21:37:30 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id 9F4D3562 for ; Sun, 12 May 2013 21:37:30 +0000 (UTC) (envelope-from mailer-daemon@vniz.net) Received: from mail-la0-x232.google.com (mail-la0-x232.google.com [IPv6:2a00:1450:4010:c03::232]) by mx1.freebsd.org (Postfix) with ESMTP id 27F58D5 for ; Sun, 12 May 2013 21:37:29 +0000 (UTC) Received: by mail-la0-f50.google.com with SMTP id dz20so1625564lab.23 for ; Sun, 12 May 2013 14:37:29 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20120113; h=x-received:message-id:date:from:user-agent:mime-version:to:cc :subject:references:in-reply-to:openpgp:content-type :content-transfer-encoding:x-gm-message-state; bh=CY7ZcbhBVsGw/J6YtP1zTX5hlBRMPCfAQxh69e+5ykg=; b=j2r/YbPXoy1t1tBeEBqIFeJBAHdUjOK6vdUdl46uwCV1Wc/F7zd2c2JgCVBkXpo4AC 945TvkmvTrMNCI41aHLwFE3LJX4MhLWDjBbWNxNDtU/30zFdWNl3v4h8EOLeAqB3w0D7 j/rQ0D+wAs5aNisVaJ+0kkll3cfOdzIkr6cAbIHtnGrbfJ7JEuy7x7BWykwtRSvd2+Y/ +cK2+Co0Jsoh56bVg+4UB/5cv9BRrPIxAOvxIZIZnu45L5bt5v5B4A3zxueRuqSsO1SZ tweKuZdndLMcKiCYiYQ6MYdTPgjhnUZWdKBf2FTZNs1DrL7dICJoqJVaKQOIQzfCM6U8 050A== X-Received: by 10.112.139.4 with SMTP id qu4mr11398211lbb.37.1368394649061; Sun, 12 May 2013 14:37:29 -0700 (PDT) Received: from [192.168.1.2] ([89.169.163.3]) by mx.google.com with ESMTPSA id y3sm4392654lby.12.2013.05.12.14.37.28 for (version=TLSv1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Sun, 12 May 2013 14:37:28 -0700 (PDT) Message-ID: <51900B97.20406@freebsd.org> Date: Mon, 13 May 2013 01:37:27 +0400 From: Andrey Chernov User-Agent: Mozilla/5.0 (Windows NT 6.1; WOW64; rv:17.0) Gecko/20130328 Thunderbird/17.0.5 MIME-Version: 1.0 To: Alan Cox Subject: Re: svn commit: r250577 - head/sys/vm References: <201305121650.r4CGoJL0087149@svn.freebsd.org> In-Reply-To: <201305121650.r4CGoJL0087149@svn.freebsd.org> OpenPGP: id=964474DD Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit X-Gm-Message-State: ALoCoQmVotKWxyomOxSYT2u6HXU/QQp3WViNPMMboLECj9JgRL5sIaUZS/ju0lhUqR0/Agfa9OJ9 Cc: svn-src-head@freebsd.org, svn-src-all@freebsd.org, src-committers@freebsd.org X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 12 May 2013 21:37:30 -0000 On 12.05.2013 20:50, Alan Cox wrote: GNU cc errors related to part of diff below: cc1: warnings being treated as errors ../../../vm/vm_page.c: In function 'vm_page_alloc': ../../../vm/vm_page.c:1209: warning: 'mpred' may be used uninitialized in this function *** [vm_page.o] Error code 1 Formally yes, mpred here can be left unitialized. > @@ -1179,7 +1206,7 @@ vm_page_alloc(vm_object_t object, vm_pin > { > struct vnode *vp = NULL; > vm_object_t m_object; > - vm_page_t m; > + vm_page_t m, mpred; > int flags, req_class; > > KASSERT((object != NULL) == ((req & VM_ALLOC_NOOBJ) == 0), > @@ -1195,6 +1222,11 @@ vm_page_alloc(vm_object_t object, vm_pin > if (curproc == pageproc && req_class != VM_ALLOC_INTERRUPT) > req_class = VM_ALLOC_SYSTEM; > > + if (object != NULL) { > + mpred = vm_radix_lookup_le(&object->rtree, pindex); > + KASSERT(mpred == NULL || mpred->pindex != pindex, > + ("vm_page_alloc: pindex already allocated")); > + } > mtx_lock(&vm_page_queue_free_mtx); > if (cnt.v_free_count + cnt.v_cache_count > cnt.v_free_reserved || > (req_class == VM_ALLOC_SYSTEM && > @@ -1225,8 +1257,8 @@ vm_page_alloc(vm_object_t object, vm_pin > return (NULL); > #if VM_NRESERVLEVEL > 0 > } else if (object == NULL || (object->flags & (OBJ_COLORED | > - OBJ_FICTITIOUS)) != OBJ_COLORED || > - (m = vm_reserv_alloc_page(object, pindex)) == NULL) { > + OBJ_FICTITIOUS)) != OBJ_COLORED || (m = > + vm_reserv_alloc_page(object, pindex, mpred)) == NULL) { > #else > } else { > #endif > @@ -1320,7 +1352,7 @@ vm_page_alloc(vm_object_t object, vm_pin > if (object->memattr != VM_MEMATTR_DEFAULT && > (object->flags & OBJ_FICTITIOUS) == 0) > pmap_page_set_memattr(m, object->memattr); > - vm_page_insert(m, object, pindex); > + vm_page_insert_after(m, object, pindex, mpred); > } else > m->pindex = pindex; -- http://ache.vniz.net/ bitcoin:13fGiNutKNHcVSsgtGQ7bQ5kgUKgEQHn7N From owner-svn-src-all@FreeBSD.ORG Sun May 12 21:37:55 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id CF0076E2; Sun, 12 May 2013 21:37:55 +0000 (UTC) (envelope-from edschouten@gmail.com) Received: from mail-vc0-f182.google.com (mail-vc0-f182.google.com [209.85.220.182]) by mx1.freebsd.org (Postfix) with ESMTP id 46318E0; Sun, 12 May 2013 21:37:55 +0000 (UTC) Received: by mail-vc0-f182.google.com with SMTP id ia10so5019494vcb.27 for ; Sun, 12 May 2013 14:37:48 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:x-received:sender:in-reply-to:references:date :x-google-sender-auth:message-id:subject:from:to:cc:content-type; bh=ziEre14duaKXpeUe5VJWA10lugwdiF94O6/ro5KJkH8=; b=KhdUqpfV7JNWCe4ysq5LGwAkLfISmd2jBFgfsteZjTGmX9+mFAWfvYkwEXMWG3tzHe 7Be0BYtrDRDPwXDhFTBxrWKnFT6nFxHwJYwZ6+4CcY/KVuqvNyP9jnA5JkytPeY0mGvC efIYQMZ3F5kTZD/vBMo8lFO9VpWnknGqpyEsKNCRez6HfvZvGxtfbfWXU8ECzugVOoO2 CMlpemKLgVUQr9ReRpBy+z9p3TcUHyB/Q/q49unWilbzNJY2rt0nbjCsdYhvFhz6NOic aly9dT4hvrNO/UBHfPkKt+k9ij6pvdtvFkVU0MDs/iOmXiPNwHJRMNqoaz9zhCUp+UTO ZWAg== MIME-Version: 1.0 X-Received: by 10.58.220.129 with SMTP id pw1mr16916498vec.32.1368394668837; Sun, 12 May 2013 14:37:48 -0700 (PDT) Sender: edschouten@gmail.com Received: by 10.220.189.133 with HTTP; Sun, 12 May 2013 14:37:48 -0700 (PDT) In-Reply-To: References: <201305121523.r4CFNxBR055568@svn.freebsd.org> Date: Sun, 12 May 2013 23:37:48 +0200 X-Google-Sender-Auth: H4thYNSAT0lBs6mIJjdub5cyB1w Message-ID: Subject: Re: svn commit: r250565 - head/etc From: Ed Schouten To: Dmitry Morozovsky Content-Type: text/plain; charset=UTF-8 Cc: svn-src-head@freebsd.org, svn-src-all@freebsd.org, src-committers@freebsd.org, Eitan Adler X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 12 May 2013 21:37:55 -0000 2013/5/12 Dmitry Morozovsky : > I'm afraid it could produce more harm than goodness on old hardware > and/or other architectures like arm. Any change we make at FreeBSD may or may not cause problems on old hardware and/or other architectures like ARM. It's typically a case of trial and error to see what happens. In fact, I think that for embedded systems, using xz compression would even be better. Many of those systems are often more storage space constrained than CPU constrained (e.g. a 200 MHz wireless device with only 8 MB of flash). I think it's a pity the change has been reverted without bringing any hard data to the table. -- Ed Schouten From owner-svn-src-all@FreeBSD.ORG Sun May 12 21:41:31 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id 4E33A8DB; Sun, 12 May 2013 21:41:31 +0000 (UTC) (envelope-from marck@rinet.ru) Received: from woozle.rinet.ru (woozle.rinet.ru [195.54.192.68]) by mx1.freebsd.org (Postfix) with ESMTP id BCA25107; Sun, 12 May 2013 21:41:30 +0000 (UTC) Received: from localhost (localhost [127.0.0.1]) by woozle.rinet.ru (8.14.5/8.14.5) with ESMTP id r4CLfSTk077864; Mon, 13 May 2013 01:41:28 +0400 (MSK) (envelope-from marck@rinet.ru) Date: Mon, 13 May 2013 01:41:28 +0400 (MSK) From: Dmitry Morozovsky To: Ed Schouten Subject: Re: svn commit: r250565 - head/etc In-Reply-To: Message-ID: References: <201305121523.r4CFNxBR055568@svn.freebsd.org> User-Agent: Alpine 2.00 (BSF 1167 2008-08-23) X-NCC-RegID: ru.rinet X-OpenPGP-Key-ID: 6B691B03 MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-4.4.3 (woozle.rinet.ru [0.0.0.0]); Mon, 13 May 2013 01:41:28 +0400 (MSK) Cc: svn-src-head@freebsd.org, svn-src-all@freebsd.org, src-committers@freebsd.org, Eitan Adler X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 12 May 2013 21:41:31 -0000 Ed, On Sun, 12 May 2013, Ed Schouten wrote: > 2013/5/12 Dmitry Morozovsky : > > I'm afraid it could produce more harm than goodness on old hardware > > and/or other architectures like arm. > > Any change we make at FreeBSD may or may not cause problems on old > hardware and/or other architectures like ARM. It's typically a case of > trial and error to see what happens. > > In fact, I think that for embedded systems, using xz compression would > even be better. Many of those systems are often more storage space > constrained than CPU constrained (e.g. a 200 MHz wireless device with > only 8 MB of flash). > > I think it's a pity the change has been reverted without bringing any > hard data to the table. I would pretty much like more statistics about the issue as well; unfortunately, all I have handy are x86 hardware, and most of embedded-like systems aer amd64 atoms... I think some testing should be done on different platforms before making any kind of decisions. -- Sincerely, D.Marck [DM5020, MCK-RIPE, DM3-RIPN] [ FreeBSD committer: marck@FreeBSD.org ] ------------------------------------------------------------------------ *** Dmitry Morozovsky --- D.Marck --- Wild Woozle --- marck@rinet.ru *** ------------------------------------------------------------------------ From owner-svn-src-all@FreeBSD.ORG Sun May 12 21:48:09 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id 455C5BA4; Sun, 12 May 2013 21:48:09 +0000 (UTC) (envelope-from rmacklem@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id 37D7413B; Sun, 12 May 2013 21:48:09 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.6/8.14.6) with ESMTP id r4CLm9e1090929; Sun, 12 May 2013 21:48:09 GMT (envelope-from rmacklem@svn.freebsd.org) Received: (from rmacklem@localhost) by svn.freebsd.org (8.14.6/8.14.5/Submit) id r4CLm9e9090928; Sun, 12 May 2013 21:48:09 GMT (envelope-from rmacklem@svn.freebsd.org) Message-Id: <201305122148.r4CLm9e9090928@svn.freebsd.org> From: Rick Macklem Date: Sun, 12 May 2013 21:48:09 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r250580 - head/sys/fs/nfsclient X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 12 May 2013 21:48:09 -0000 Author: rmacklem Date: Sun May 12 21:48:08 2013 New Revision: 250580 URL: http://svnweb.freebsd.org/changeset/base/250580 Log: Add support for the eofflag to nfs_readdir() in the new NFS client so that it works under a unionfs mount. Submitted by: Jared Yanovich (slovichon@gmail.com) Reviewed by: kib MFC after: 2 weeks Modified: head/sys/fs/nfsclient/nfs_clvnops.c Modified: head/sys/fs/nfsclient/nfs_clvnops.c ============================================================================== --- head/sys/fs/nfsclient/nfs_clvnops.c Sun May 12 21:24:18 2013 (r250579) +++ head/sys/fs/nfsclient/nfs_clvnops.c Sun May 12 21:48:08 2013 (r250580) @@ -2232,6 +2232,8 @@ nfs_readdir(struct vop_readdir_args *ap) int error = 0; struct vattr vattr; + if (ap->a_eofflag != NULL) + *ap->a_eofflag = 0; if (vp->v_type != VDIR) return(EPERM); @@ -2246,6 +2248,8 @@ nfs_readdir(struct vop_readdir_args *ap) !NFS_TIMESPEC_COMPARE(&np->n_mtime, &vattr.va_mtime)) { mtx_unlock(&np->n_mtx); NFSINCRGLOBAL(newnfsstats.direofcache_hits); + if (ap->a_eofflag != NULL) + *ap->a_eofflag = 1; return (0); } else mtx_unlock(&np->n_mtx); @@ -2258,8 +2262,11 @@ nfs_readdir(struct vop_readdir_args *ap) tresid = uio->uio_resid; error = ncl_bioread(vp, uio, 0, ap->a_cred); - if (!error && uio->uio_resid == tresid) + if (!error && uio->uio_resid == tresid) { NFSINCRGLOBAL(newnfsstats.direofcache_misses); + if (ap->a_eofflag != NULL) + *ap->a_eofflag = 1; + } return (error); } From owner-svn-src-all@FreeBSD.ORG Sun May 12 21:49:14 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id 7427BD34; Sun, 12 May 2013 21:49:14 +0000 (UTC) (envelope-from alc@rice.edu) Received: from pp1.rice.edu (proofpoint1.mail.rice.edu [128.42.201.100]) by mx1.freebsd.org (Postfix) with ESMTP id 4468C14E; Sun, 12 May 2013 21:49:13 +0000 (UTC) Received: from pps.filterd (pp1.rice.edu [127.0.0.1]) by pp1.rice.edu (8.14.5/8.14.5) with SMTP id r4CLHtTE017720; Sun, 12 May 2013 16:49:13 -0500 Received: from mh11.mail.rice.edu (mh11.mail.rice.edu [128.42.199.30]) by pp1.rice.edu with ESMTP id 1c3847mpqa-1; Sun, 12 May 2013 16:49:12 -0500 X-Virus-Scanned: by amavis-2.7.0 at mh11.mail.rice.edu, auth channel Received: from adsl-216-63-78-18.dsl.hstntx.swbell.net (adsl-216-63-78-18.dsl.hstntx.swbell.net [216.63.78.18]) (using TLSv1 with cipher RC4-MD5 (128/128 bits)) (No client certificate requested) (Authenticated sender: alc) by mh11.mail.rice.edu (Postfix) with ESMTPSA id 547A74C01BC; Sun, 12 May 2013 16:49:12 -0500 (CDT) Message-ID: <51900E57.80608@rice.edu> Date: Sun, 12 May 2013 16:49:11 -0500 From: Alan Cox User-Agent: Mozilla/5.0 (X11; FreeBSD i386; rv:17.0) Gecko/20130127 Thunderbird/17.0.2 MIME-Version: 1.0 To: Andrey Chernov Subject: Re: svn commit: r250577 - head/sys/vm References: <201305121650.r4CGoJL0087149@svn.freebsd.org> <51900B97.20406@freebsd.org> In-Reply-To: <51900B97.20406@freebsd.org> Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit Cc: Alan Cox , svn-src-head@freebsd.org, svn-src-all@freebsd.org, src-committers@freebsd.org X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 12 May 2013 21:49:14 -0000 On 05/12/2013 16:37, Andrey Chernov wrote: > On 12.05.2013 20:50, Alan Cox wrote: > > GNU cc errors related to part of diff below: > cc1: warnings being treated as errors > ../../../vm/vm_page.c: In function 'vm_page_alloc': > ../../../vm/vm_page.c:1209: warning: 'mpred' may be used uninitialized > in this function > *** [vm_page.o] Error code 1 > Formally yes, mpred here can be left unitialized. No, it can't. The code amounts to if ("x") mpred = ... ; ... if ("x") use mpred; ... if ("x") use mpred; where "x" is "object != NULL". Moreover, there are no assignments to the variable "object" or aliases by which the variable "object" can be modified over the lifespan of "mpred". So, this is flawed analysis by our antique gcc. >> @@ -1179,7 +1206,7 @@ vm_page_alloc(vm_object_t object, vm_pin >> { >> struct vnode *vp = NULL; >> vm_object_t m_object; >> - vm_page_t m; >> + vm_page_t m, mpred; >> int flags, req_class; >> >> KASSERT((object != NULL) == ((req & VM_ALLOC_NOOBJ) == 0), >> @@ -1195,6 +1222,11 @@ vm_page_alloc(vm_object_t object, vm_pin >> if (curproc == pageproc && req_class != VM_ALLOC_INTERRUPT) >> req_class = VM_ALLOC_SYSTEM; >> >> + if (object != NULL) { >> + mpred = vm_radix_lookup_le(&object->rtree, pindex); >> + KASSERT(mpred == NULL || mpred->pindex != pindex, >> + ("vm_page_alloc: pindex already allocated")); >> + } >> mtx_lock(&vm_page_queue_free_mtx); >> if (cnt.v_free_count + cnt.v_cache_count > cnt.v_free_reserved || >> (req_class == VM_ALLOC_SYSTEM && >> @@ -1225,8 +1257,8 @@ vm_page_alloc(vm_object_t object, vm_pin >> return (NULL); >> #if VM_NRESERVLEVEL > 0 >> } else if (object == NULL || (object->flags & (OBJ_COLORED | >> - OBJ_FICTITIOUS)) != OBJ_COLORED || >> - (m = vm_reserv_alloc_page(object, pindex)) == NULL) { >> + OBJ_FICTITIOUS)) != OBJ_COLORED || (m = >> + vm_reserv_alloc_page(object, pindex, mpred)) == NULL) { >> #else >> } else { >> #endif >> @@ -1320,7 +1352,7 @@ vm_page_alloc(vm_object_t object, vm_pin >> if (object->memattr != VM_MEMATTR_DEFAULT && >> (object->flags & OBJ_FICTITIOUS) == 0) >> pmap_page_set_memattr(m, object->memattr); >> - vm_page_insert(m, object, pindex); >> + vm_page_insert_after(m, object, pindex, mpred); >> } else >> m->pindex = pindex; From owner-svn-src-all@FreeBSD.ORG Sun May 12 22:01:24 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id B795B256; Sun, 12 May 2013 22:01:24 +0000 (UTC) (envelope-from hiren@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id 9A2981CD; Sun, 12 May 2013 22:01:24 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.6/8.14.6) with ESMTP id r4CM1O3H096573; Sun, 12 May 2013 22:01:24 GMT (envelope-from hiren@svn.freebsd.org) Received: (from hiren@localhost) by svn.freebsd.org (8.14.6/8.14.5/Submit) id r4CM1M6j096561; Sun, 12 May 2013 22:01:22 GMT (envelope-from hiren@svn.freebsd.org) Message-Id: <201305122201.r4CM1M6j096561@svn.freebsd.org> From: Hiren Panchasara Date: Sun, 12 May 2013 22:01:22 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org Subject: svn commit: r250581 - in stable/9/sys: dev/hwpmc kern X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 12 May 2013 22:01:24 -0000 Author: hiren Date: Sun May 12 22:01:22 2013 New Revision: 250581 URL: http://svnweb.freebsd.org/changeset/base/250581 Log: MFC: r240475 Remove all the checks on curthread != NULL with the exception of some MD trap checks (eg. printtrap()). Generally this check is not needed anymore, as there is not a legitimate case where curthread != NULL, after pcpu 0 area has been properly initialized. Reviewed by: attilio Approved by: sbruno (mentor) Modified: stable/9/sys/dev/hwpmc/hwpmc_arm.c stable/9/sys/dev/hwpmc/hwpmc_x86.c stable/9/sys/kern/kern_condvar.c stable/9/sys/kern/kern_mutex.c stable/9/sys/kern/kern_rwlock.c stable/9/sys/kern/kern_sx.c stable/9/sys/kern/kern_thread.c stable/9/sys/kern/vfs_subr.c Directory Properties: stable/9/sys/ (props changed) stable/9/sys/dev/ (props changed) Modified: stable/9/sys/dev/hwpmc/hwpmc_arm.c ============================================================================== --- stable/9/sys/dev/hwpmc/hwpmc_arm.c Sun May 12 21:48:08 2013 (r250580) +++ stable/9/sys/dev/hwpmc/hwpmc_arm.c Sun May 12 22:01:22 2013 (r250581) @@ -75,12 +75,10 @@ pmc_save_kernel_callchain(uintptr_t *cc, KASSERT(TRAPF_USERMODE(tf) == 0,("[arm,%d] not a kernel backtrace", __LINE__)); + td = curthread; pc = PMC_TRAPFRAME_TO_PC(tf); *cc++ = pc; - if ((td = curthread) == NULL) - return (1); - if (maxsamples <= 1) return (1); @@ -126,12 +124,10 @@ pmc_save_user_callchain(uintptr_t *cc, i KASSERT(TRAPF_USERMODE(tf), ("[x86,%d] Not a user trap frame tf=%p", __LINE__, (void *) tf)); + td = curthread; pc = PMC_TRAPFRAME_TO_PC(tf); *cc++ = pc; - if ((td = curthread) == NULL) - return (1); - if (maxsamples <= 1) return (1); Modified: stable/9/sys/dev/hwpmc/hwpmc_x86.c ============================================================================== --- stable/9/sys/dev/hwpmc/hwpmc_x86.c Sun May 12 21:48:08 2013 (r250580) +++ stable/9/sys/dev/hwpmc/hwpmc_x86.c Sun May 12 22:01:22 2013 (r250581) @@ -161,6 +161,7 @@ pmc_save_kernel_callchain(uintptr_t *cc, KASSERT(TRAPF_USERMODE(tf) == 0,("[x86,%d] not a kernel backtrace", __LINE__)); + td = curthread; pc = PMC_TRAPFRAME_TO_PC(tf); fp = PMC_TRAPFRAME_TO_FP(tf); sp = PMC_TRAPFRAME_TO_KERNEL_SP(tf); @@ -168,9 +169,6 @@ pmc_save_kernel_callchain(uintptr_t *cc, *cc++ = pc; r = fp + sizeof(uintptr_t); /* points to return address */ - if ((td = curthread) == NULL) - return (1); - if (nframes <= 1) return (1); Modified: stable/9/sys/kern/kern_condvar.c ============================================================================== --- stable/9/sys/kern/kern_condvar.c Sun May 12 21:48:08 2013 (r250580) +++ stable/9/sys/kern/kern_condvar.c Sun May 12 22:01:22 2013 (r250581) @@ -50,7 +50,7 @@ __FBSDID("$FreeBSD$"); * Common sanity checks for cv_wait* functions. */ #define CV_ASSERT(cvp, lock, td) do { \ - KASSERT((td) != NULL, ("%s: curthread NULL", __func__)); \ + KASSERT((td) != NULL, ("%s: td NULL", __func__)); \ KASSERT(TD_IS_RUNNING(td), ("%s: not TDS_RUNNING", __func__)); \ KASSERT((cvp) != NULL, ("%s: cvp NULL", __func__)); \ KASSERT((lock) != NULL, ("%s: lock NULL", __func__)); \ Modified: stable/9/sys/kern/kern_mutex.c ============================================================================== --- stable/9/sys/kern/kern_mutex.c Sun May 12 21:48:08 2013 (r250580) +++ stable/9/sys/kern/kern_mutex.c Sun May 12 22:01:22 2013 (r250581) @@ -199,7 +199,6 @@ _mtx_lock_flags(struct mtx *m, int opts, if (SCHEDULER_STOPPED()) return; - MPASS(curthread != NULL); KASSERT(m->mtx_lock != MTX_DESTROYED, ("mtx_lock() of destroyed mutex @ %s:%d", file, line)); KASSERT(LOCK_CLASS(&m->lock_object) == &lock_class_mtx_sleep, @@ -221,7 +220,6 @@ _mtx_unlock_flags(struct mtx *m, int opt if (SCHEDULER_STOPPED()) return; - MPASS(curthread != NULL); KASSERT(m->mtx_lock != MTX_DESTROYED, ("mtx_unlock() of destroyed mutex @ %s:%d", file, line)); KASSERT(LOCK_CLASS(&m->lock_object) == &lock_class_mtx_sleep, @@ -244,7 +242,6 @@ _mtx_lock_spin_flags(struct mtx *m, int if (SCHEDULER_STOPPED()) return; - MPASS(curthread != NULL); KASSERT(m->mtx_lock != MTX_DESTROYED, ("mtx_lock_spin() of destroyed mutex @ %s:%d", file, line)); KASSERT(LOCK_CLASS(&m->lock_object) == &lock_class_mtx_spin, @@ -268,7 +265,6 @@ _mtx_unlock_spin_flags(struct mtx *m, in if (SCHEDULER_STOPPED()) return; - MPASS(curthread != NULL); KASSERT(m->mtx_lock != MTX_DESTROYED, ("mtx_unlock_spin() of destroyed mutex @ %s:%d", file, line)); KASSERT(LOCK_CLASS(&m->lock_object) == &lock_class_mtx_spin, @@ -299,7 +295,6 @@ _mtx_trylock(struct mtx *m, int opts, co if (SCHEDULER_STOPPED()) return (1); - MPASS(curthread != NULL); KASSERT(m->mtx_lock != MTX_DESTROYED, ("mtx_trylock() of destroyed mutex @ %s:%d", file, line)); KASSERT(LOCK_CLASS(&m->lock_object) == &lock_class_mtx_sleep, Modified: stable/9/sys/kern/kern_rwlock.c ============================================================================== --- stable/9/sys/kern/kern_rwlock.c Sun May 12 21:48:08 2013 (r250580) +++ stable/9/sys/kern/kern_rwlock.c Sun May 12 22:01:22 2013 (r250581) @@ -237,7 +237,6 @@ _rw_wlock(struct rwlock *rw, const char if (SCHEDULER_STOPPED()) return; - MPASS(curthread != NULL); KASSERT(rw->rw_lock != RW_DESTROYED, ("rw_wlock() of destroyed rwlock @ %s:%d", file, line)); WITNESS_CHECKORDER(&rw->lock_object, LOP_NEWORDER | LOP_EXCLUSIVE, file, @@ -282,7 +281,6 @@ _rw_wunlock(struct rwlock *rw, const cha if (SCHEDULER_STOPPED()) return; - MPASS(curthread != NULL); KASSERT(rw->rw_lock != RW_DESTROYED, ("rw_wunlock() of destroyed rwlock @ %s:%d", file, line)); _rw_assert(rw, RA_WLOCKED, file, line); Modified: stable/9/sys/kern/kern_sx.c ============================================================================== --- stable/9/sys/kern/kern_sx.c Sun May 12 21:48:08 2013 (r250580) +++ stable/9/sys/kern/kern_sx.c Sun May 12 22:01:22 2013 (r250581) @@ -246,7 +246,6 @@ _sx_slock(struct sx *sx, int opts, const if (SCHEDULER_STOPPED()) return (0); - MPASS(curthread != NULL); KASSERT(sx->sx_lock != SX_LOCK_DESTROYED, ("sx_slock() of destroyed sx @ %s:%d", file, line)); WITNESS_CHECKORDER(&sx->lock_object, LOP_NEWORDER, file, line, NULL); @@ -293,7 +292,6 @@ _sx_xlock(struct sx *sx, int opts, const if (SCHEDULER_STOPPED()) return (0); - MPASS(curthread != NULL); KASSERT(sx->sx_lock != SX_LOCK_DESTROYED, ("sx_xlock() of destroyed sx @ %s:%d", file, line)); WITNESS_CHECKORDER(&sx->lock_object, LOP_NEWORDER | LOP_EXCLUSIVE, file, @@ -317,7 +315,6 @@ _sx_try_xlock(struct sx *sx, const char if (SCHEDULER_STOPPED()) return (1); - MPASS(curthread != NULL); KASSERT(sx->sx_lock != SX_LOCK_DESTROYED, ("sx_try_xlock() of destroyed sx @ %s:%d", file, line)); @@ -345,7 +342,6 @@ _sx_sunlock(struct sx *sx, const char *f if (SCHEDULER_STOPPED()) return; - MPASS(curthread != NULL); KASSERT(sx->sx_lock != SX_LOCK_DESTROYED, ("sx_sunlock() of destroyed sx @ %s:%d", file, line)); _sx_assert(sx, SA_SLOCKED, file, line); @@ -362,7 +358,6 @@ _sx_xunlock(struct sx *sx, const char *f if (SCHEDULER_STOPPED()) return; - MPASS(curthread != NULL); KASSERT(sx->sx_lock != SX_LOCK_DESTROYED, ("sx_xunlock() of destroyed sx @ %s:%d", file, line)); _sx_assert(sx, SA_XLOCKED, file, line); Modified: stable/9/sys/kern/kern_thread.c ============================================================================== --- stable/9/sys/kern/kern_thread.c Sun May 12 21:48:08 2013 (r250580) +++ stable/9/sys/kern/kern_thread.c Sun May 12 22:01:22 2013 (r250581) @@ -623,7 +623,6 @@ thread_single(int mode) p = td->td_proc; mtx_assert(&Giant, MA_NOTOWNED); PROC_LOCK_ASSERT(p, MA_OWNED); - KASSERT((td != NULL), ("curthread is NULL")); if ((p->p_flag & P_HADTHREADS) == 0) return (0); Modified: stable/9/sys/kern/vfs_subr.c ============================================================================== --- stable/9/sys/kern/vfs_subr.c Sun May 12 21:48:08 2013 (r250580) +++ stable/9/sys/kern/vfs_subr.c Sun May 12 22:01:22 2013 (r250581) @@ -3494,7 +3494,6 @@ vfs_unmountall(void) struct thread *td; int error; - KASSERT(curthread != NULL, ("vfs_unmountall: NULL curthread")); CTR1(KTR_VFS, "%s: unmounting all filesystems", __func__); td = curthread; From owner-svn-src-all@FreeBSD.ORG Sun May 12 22:22:15 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id DFAB0737; Sun, 12 May 2013 22:22:15 +0000 (UTC) (envelope-from joel@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id C1902276; Sun, 12 May 2013 22:22:15 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.6/8.14.6) with ESMTP id r4CMMFeq004317; Sun, 12 May 2013 22:22:15 GMT (envelope-from joel@svn.freebsd.org) Received: (from joel@localhost) by svn.freebsd.org (8.14.6/8.14.5/Submit) id r4CMMCXu004298; Sun, 12 May 2013 22:22:12 GMT (envelope-from joel@svn.freebsd.org) Message-Id: <201305122222.r4CMMCXu004298@svn.freebsd.org> From: Joel Dahl Date: Sun, 12 May 2013 22:22:12 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r250582 - in head: bin/ed lib/libradius lib/libtacplus lib/libusb libexec/bootpd sbin/iscontrol share/man/man5 usr.bin/usbhidctl usr.sbin/bootparamd/bootparamd usr.sbin/freebsd-update u... X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 12 May 2013 22:22:15 -0000 Author: joel (doc committer) Date: Sun May 12 22:22:12 2013 New Revision: 250582 URL: http://svnweb.freebsd.org/changeset/base/250582 Log: mdoc sweep. Modified: head/bin/ed/ed.1 head/lib/libradius/radius.conf.5 head/lib/libtacplus/libtacplus.3 head/lib/libtacplus/tacplus.conf.5 head/lib/libusb/libusb20.3 head/libexec/bootpd/bootptab.5 head/sbin/iscontrol/iscsi.conf.5 head/share/man/man5/freebsd-update.conf.5 head/share/man/man5/mailer.conf.5 head/share/man/man5/portsnap.conf.5 head/usr.bin/usbhidctl/usbhidctl.1 head/usr.sbin/bootparamd/bootparamd/bootparamd.8 head/usr.sbin/freebsd-update/freebsd-update.8 head/usr.sbin/portsnap/portsnap/portsnap.8 head/usr.sbin/wake/wake.8 Modified: head/bin/ed/ed.1 ============================================================================== --- head/bin/ed/ed.1 Sun May 12 22:01:22 2013 (r250581) +++ head/bin/ed/ed.1 Sun May 12 22:22:12 2013 (r250582) @@ -914,9 +914,9 @@ that line. .El .Sh FILES .Bl -tag -width /tmp/ed.* -compact -.It /tmp/ed.* +.It Pa /tmp/ed.* buffer file -.It ed.hup +.It Pa ed.hup the file to which .Nm attempts to write the buffer if the terminal hangs up Modified: head/lib/libradius/radius.conf.5 ============================================================================== --- head/lib/libradius/radius.conf.5 Sun May 12 22:01:22 2013 (r250581) +++ head/lib/libradius/radius.conf.5 Sun May 12 22:22:12 2013 (r250582) @@ -162,7 +162,9 @@ But an alternate pathname may be specifi Since the file contains sensitive information in the form of the shared secrets, it should not be readable except by root. .Sh FILES -.Pa /etc/radius.conf +.Bl -tag -width Pa +.It Pa /etc/radius.conf +.El .Sh EXAMPLES .Bd -literal # A simple entry using all the defaults: Modified: head/lib/libtacplus/libtacplus.3 ============================================================================== --- head/lib/libtacplus/libtacplus.3 Sun May 12 22:01:22 2013 (r250581) +++ head/lib/libtacplus/libtacplus.3 Sun May 12 22:22:12 2013 (r250582) @@ -513,7 +513,9 @@ without recording an error message. .Fn tac_open .El .Sh FILES -.Pa /etc/tacplus.conf +.Bl -tag -width Pa +.It Pa /etc/tacplus.conf +.El .Sh SEE ALSO .Xr tacplus.conf 5 .Rs Modified: head/lib/libtacplus/tacplus.conf.5 ============================================================================== --- head/lib/libtacplus/tacplus.conf.5 Sun May 12 22:01:22 2013 (r250581) +++ head/lib/libtacplus/tacplus.conf.5 Sun May 12 22:22:12 2013 (r250582) @@ -111,7 +111,9 @@ An alternate pathname may be specified i Since the file contains sensitive information in the form of the shared secrets, it should not be readable except by root. .Sh FILES -.Pa /etc/tacplus.conf +.Bl -tag -width Pa +.It Pa /etc/tacplus.conf +.El .Sh EXAMPLES .Bd -literal # A simple entry using all the defaults: Modified: head/lib/libusb/libusb20.3 ============================================================================== --- head/lib/libusb/libusb20.3 Sun May 12 22:01:22 2013 (r250581) +++ head/lib/libusb/libusb20.3 Sun May 12 22:22:12 2013 (r250582) @@ -1049,9 +1049,9 @@ argument. This function does not return NULL. . .Sh FILES -. -. -/dev/usb +.Bl -tag -width Pa +.It Pa /dev/usb +.El .Sh SEE ALSO .Xr usb 4 , .Xr libusb 3 , Modified: head/libexec/bootpd/bootptab.5 ============================================================================== --- head/libexec/bootpd/bootptab.5 Sun May 12 22:01:22 2013 (r250581) +++ head/libexec/bootpd/bootptab.5 Sun May 12 22:22:12 2013 (r250582) @@ -421,7 +421,7 @@ mtoliver:ht=1:ha=00DD00FE1600:tc=.defaul .Ed .Sh FILES .Bl -tag -width /etc/bootptab -compact -.It /etc/bootptab +.It Pa /etc/bootptab .El .Sh "SEE ALSO" .Xr bootpd 8 , Modified: head/sbin/iscontrol/iscsi.conf.5 ============================================================================== --- head/sbin/iscontrol/iscsi.conf.5 Sun May 12 22:01:22 2013 (r250581) +++ head/sbin/iscontrol/iscsi.conf.5 Sun May 12 22:22:12 2013 (r250582) @@ -173,7 +173,9 @@ same as the none counterpart, but to authenticate the target. .El .Sh FILES -.Pa /etc/iscsi.conf +.Bl -tag -width indent +.It Pa /etc/iscsi.conf +.El .Sh EXAMPLES .Bd -literal # Modified: head/share/man/man5/freebsd-update.conf.5 ============================================================================== --- head/share/man/man5/freebsd-update.conf.5 Sun May 12 22:01:22 2013 (r250581) +++ head/share/man/man5/freebsd-update.conf.5 Sun May 12 22:22:12 2013 (r250582) @@ -221,7 +221,7 @@ kernel. .El .Sh FILES .Bl -tag -width "/etc/freebsd-update.conf" -.It /etc/freebsd-update.conf +.It Pa /etc/freebsd-update.conf Default location of the .Cm freebsd-update configuration file. Modified: head/share/man/man5/mailer.conf.5 ============================================================================== --- head/share/man/man5/mailer.conf.5 Sun May 12 22:01:22 2013 (r250581) +++ head/share/man/man5/mailer.conf.5 Sun May 12 22:22:12 2013 (r250582) @@ -83,7 +83,9 @@ The file may also contain comment lines, .Ql # mark in the first column of any line. .Sh FILES -/etc/mail/mailer.conf +.Bl -tag -width Pa +.It Pa /etc/mail/mailer.conf +.El .Sh EXAMPLES This example shows how to set up .Nm Modified: head/share/man/man5/portsnap.conf.5 ============================================================================== --- head/share/man/man5/portsnap.conf.5 Sun May 12 22:01:22 2013 (r250581) +++ head/share/man/man5/portsnap.conf.5 Sun May 12 22:22:12 2013 (r250582) @@ -135,7 +135,7 @@ supported and may cause unexpected resul Any lines not of the above forms will be ignored. .Sh FILES .Bl -tag -width "/etc/portsnap.conf" -.It /etc/portsnap.conf +.It Pa /etc/portsnap.conf Default location of the portsnap configuration file. .El .Sh SEE ALSO Modified: head/usr.bin/usbhidctl/usbhidctl.1 ============================================================================== --- head/usr.bin/usbhidctl/usbhidctl.1 Sun May 12 22:01:22 2013 (r250581) +++ head/usr.bin/usbhidctl/usbhidctl.1 Sun May 12 22:22:12 2013 (r250582) @@ -136,8 +136,10 @@ supports isolating each item by appendin .Sq Cm \&# . character and a decimal item instance number, starting at zero. .Sh FILES -.Pa /usr/share/misc/usb_hid_usages +.Bl -tag -width 30n +.It Pa /usr/share/misc/usb_hid_usages The default HID usage table. +.El .Sh SEE ALSO .Xr usbhid 3 , .Xr uhid 4 , Modified: head/usr.sbin/bootparamd/bootparamd/bootparamd.8 ============================================================================== --- head/usr.sbin/bootparamd/bootparamd/bootparamd.8 Sun May 12 22:01:22 2013 (r250581) +++ head/usr.sbin/bootparamd/bootparamd/bootparamd.8 Sun May 12 22:22:12 2013 (r250582) @@ -48,7 +48,7 @@ The file to use as boot parameter file i .El .Sh FILES .Bl -tag -width /etc/bootparams -compact -.It /etc/bootparams +.It Pa /etc/bootparams default boot parameter file .El .Sh EXAMPLES Modified: head/usr.sbin/freebsd-update/freebsd-update.8 ============================================================================== --- head/usr.sbin/freebsd-update/freebsd-update.8 Sun May 12 22:01:22 2013 (r250581) +++ head/usr.sbin/freebsd-update/freebsd-update.8 Sun May 12 22:22:12 2013 (r250582) @@ -162,11 +162,11 @@ purposes, make sure you boot from a secu .El .Sh FILES .Bl -tag -width "/etc/freebsd-update.conf" -.It /etc/freebsd-update.conf +.It Pa /etc/freebsd-update.conf Default location of the .Nm configuration file. -.It /var/db/freebsd-update/ +.It Pa /var/db/freebsd-update/ Default location where .Nm stores temporary files and downloaded updates. Modified: head/usr.sbin/portsnap/portsnap/portsnap.8 ============================================================================== --- head/usr.sbin/portsnap/portsnap/portsnap.8 Sun May 12 22:01:22 2013 (r250581) +++ head/usr.sbin/portsnap/portsnap/portsnap.8 Sun May 12 22:22:12 2013 (r250582) @@ -247,11 +247,11 @@ may be published, but only in aggregate individual systems. .Sh FILES .Bl -tag -width "/etc/portsnap.conf" -.It /etc/portsnap.conf +.It Pa /etc/portsnap.conf Default location of the portsnap configuration file. -.It /var/db/portsnap +.It Pa /var/db/portsnap Default location where compressed snapshots are stored. -.It /usr/ports +.It Pa /usr/ports Default location where the ports tree is extracted. .El .Sh SEE ALSO Modified: head/usr.sbin/wake/wake.8 ============================================================================== --- head/usr.sbin/wake/wake.8 Sun May 12 22:01:22 2013 (r250581) +++ head/usr.sbin/wake/wake.8 Sun May 12 22:22:12 2013 (r250582) @@ -56,7 +56,7 @@ Link layer addresses can be determined a .Xr ifconfig 8 . .Sh FILES .Bl -tag -width "/etc/ethers" -compact -.It /etc/ethers +.It Pa /etc/ethers Ethernet host name data base. .El .Sh SEE ALSO From owner-svn-src-all@FreeBSD.ORG Mon May 13 00:17:34 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 1033) id 0ED7F90A; Mon, 13 May 2013 00:17:34 +0000 (UTC) Date: Mon, 13 May 2013 00:17:34 +0000 From: Alexey Dokuchaev To: Dmitry Morozovsky Subject: Re: svn commit: r250565 - head/etc Message-ID: <20130513001733.GA32639@FreeBSD.org> References: <201305121523.r4CFNxBR055568@svn.freebsd.org> <518FFA4B.9080505@freebsd.org> <20130512205146.GZ91136@ithaqua.etoilebsd.net> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.5.21 (2010-09-15) Cc: Baptiste Daroussin , src-committers@freebsd.org, Eitan Adler , svn-src-all@freebsd.org, svn-src-head@freebsd.org, Matthew Jacob X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 13 May 2013 00:17:34 -0000 On Mon, May 13, 2013 at 01:14:35AM +0400, Dmitry Morozovsky wrote: > method realtm arsize > ==================== > gzip 45s 183M > bzip2 5m32s 115M > xz 11m43s 112M > > I would tend to use xz for distributives (including freebsd-updates or > portsnap), where compression process is quite rare, but download size is > significant -- but not for logs, backups, or other similar once-packed > data... +1. xz is not part of all our releases, yet people still might be running 6.x for example, and they certainly won't be happy to keep two versions of their newsyslog.conf (otherwise identical) -- just another reason why this change is moot at least. Otherwise I totally agree with Dmitry that xz is not for frequent compressions of small files when it clearly loses to bzip2. ./danfe From owner-svn-src-all@FreeBSD.ORG Mon May 13 00:25:35 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 1033) id A730EC65; Mon, 13 May 2013 00:25:35 +0000 (UTC) Date: Mon, 13 May 2013 00:25:35 +0000 From: Alexey Dokuchaev To: Ed Schouten Subject: Re: svn commit: r250565 - head/etc Message-ID: <20130513002535.GB32639@FreeBSD.org> References: <201305121523.r4CFNxBR055568@svn.freebsd.org> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.5.21 (2010-09-15) Cc: svn-src-head@freebsd.org, svn-src-all@freebsd.org, src-committers@freebsd.org, Eitan Adler , Dmitry Morozovsky X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 13 May 2013 00:25:35 -0000 On Sun, May 12, 2013 at 11:37:48PM +0200, Ed Schouten wrote: > In fact, I think that for embedded systems, using xz compression would > even be better. Many of those systems are often more storage space > constrained than CPU constrained (e.g. a 200 MHz wireless device with > only 8 MB of flash). Speaking of embedded systems, we here at $work said no for xz (for compressing anything from initrd images to custom packages) precisely because it being notoriously slow. Really constrained environments certainly call for specific approaches, but just arbitrarily turning on xz compression on something as general purpose as syslog files is not the best thing to help one save space. If fact, I really doubt there would be any syslog files on filesystem with 8 MB of flash. :-) ./danfe From owner-svn-src-all@FreeBSD.ORG Mon May 13 01:05:13 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id CD30A38D; Mon, 13 May 2013 01:05:13 +0000 (UTC) (envelope-from kozlov@ravenloft.kiev.ua) Received: from ravenloft.kiev.ua (ravenloft.kiev.ua [94.244.131.95]) by mx1.freebsd.org (Postfix) with ESMTP id 8DF39991; Mon, 13 May 2013 01:05:13 +0000 (UTC) Date: Mon, 13 May 2013 04:05:12 +0300 From: Alex Kozlov To: Dmitry Morozovsky Subject: Re: svn commit: r250565 - head/etc Message-ID: <20130513010512.GA38811@ravenloft.kiev.ua> References: <201305121523.r4CFNxBR055568@svn.freebsd.org> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: Cc: svn-src-head@freebsd.org, svn-src-all@freebsd.org, src-committers@freebsd.org X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 13 May 2013 01:05:13 -0000 On Mon, May 13, 2013 at 01:41:28AM +0400, Dmitry Morozovsky wrote: > On Sun, 12 May 2013, Ed Schouten wrote: > > 2013/5/12 Dmitry Morozovsky : > > > I'm afraid it could produce more harm than goodness on old hardware > > > and/or other architectures like arm. > > Any change we make at FreeBSD may or may not cause problems on old > > hardware and/or other architectures like ARM. It's typically a case of > > trial and error to see what happens. > > In fact, I think that for embedded systems, using xz compression would > > even be better. Many of those systems are often more storage space > > constrained than CPU constrained (e.g. a 200 MHz wireless device with > > only 8 MB of flash). > > I think it's a pity the change has been reverted without bringing any > > hard data to the table. I've tested this change on i386/amd64 (Pentium T4400, the slowest I have), arm (Raspberry Pi) and very old mips (mips 24k). The difference in size between bzip2 and xz compressed logs around 20%. The difference in compression speed around 100%. But I believe that it is acceptable trade-of because logs rotation is an infrequent event, default log size make the absolute value of compression time negligible and xz decompresses several times faster than bzip2. Brief test results (compression, 1 thread): cpu xz T4400 1Mb/s rpi 0.8Mb/s mips 24k 0.07Mb/s (bzip2 0.16Mb/s) > I would pretty much like more statistics about the issue as well; > unfortunately, all I have handy are x86 hardware, and most of embedded-like > systems aer amd64 atoms... > > I think some testing should be done on different platforms before making any > kind of decisions. Oh well, let's just wait another 5 years. -- Alex From owner-svn-src-all@FreeBSD.ORG Mon May 13 01:20:32 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id 46E2B725; Mon, 13 May 2013 01:20:32 +0000 (UTC) (envelope-from eadler@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id 389649EF; Mon, 13 May 2013 01:20:32 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.6/8.14.6) with ESMTP id r4D1KVZm064861; Mon, 13 May 2013 01:20:31 GMT (envelope-from eadler@svn.freebsd.org) Received: (from eadler@localhost) by svn.freebsd.org (8.14.6/8.14.5/Submit) id r4D1KVPU064860; Mon, 13 May 2013 01:20:31 GMT (envelope-from eadler@svn.freebsd.org) Message-Id: <201305130120.r4D1KVPU064860@svn.freebsd.org> From: Eitan Adler Date: Mon, 13 May 2013 01:20:31 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org Subject: svn commit: r250583 - stable/9/usr.sbin/mergemaster X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 13 May 2013 01:20:32 -0000 Author: eadler Date: Mon May 13 01:20:31 2013 New Revision: 250583 URL: http://svnweb.freebsd.org/changeset/base/250583 Log: MFC r250463: Permit relative paths with mergemaster -m PR: bin/173929 Modified: stable/9/usr.sbin/mergemaster/mergemaster.sh Directory Properties: stable/9/usr.sbin/mergemaster/ (props changed) Modified: stable/9/usr.sbin/mergemaster/mergemaster.sh ============================================================================== --- stable/9/usr.sbin/mergemaster/mergemaster.sh Sun May 12 22:22:12 2013 (r250582) +++ stable/9/usr.sbin/mergemaster/mergemaster.sh Mon May 13 01:20:31 2013 (r250583) @@ -483,6 +483,7 @@ if [ ! -f ${SOURCEDIR}/Makefile.inc1 -a sleep 3 SOURCEDIR=${SOURCEDIR}/.. fi +SOURCEDIR=$(realpath "$SOURCEDIR") # Setup make to use system files from SOURCEDIR MM_MAKE="make ${ARCHSTRING} -m ${SOURCEDIR}/share/mk" From owner-svn-src-all@FreeBSD.ORG Mon May 13 01:20:37 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id 16DD6726; Mon, 13 May 2013 01:20:37 +0000 (UTC) (envelope-from eadler@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id 08C699F0; Mon, 13 May 2013 01:20:37 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.6/8.14.6) with ESMTP id r4D1KaLx064909; Mon, 13 May 2013 01:20:36 GMT (envelope-from eadler@svn.freebsd.org) Received: (from eadler@localhost) by svn.freebsd.org (8.14.6/8.14.5/Submit) id r4D1Kade064908; Mon, 13 May 2013 01:20:36 GMT (envelope-from eadler@svn.freebsd.org) Message-Id: <201305130120.r4D1Kade064908@svn.freebsd.org> From: Eitan Adler Date: Mon, 13 May 2013 01:20:36 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-8@freebsd.org Subject: svn commit: r250584 - stable/8/usr.sbin/mergemaster X-SVN-Group: stable-8 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 13 May 2013 01:20:37 -0000 Author: eadler Date: Mon May 13 01:20:36 2013 New Revision: 250584 URL: http://svnweb.freebsd.org/changeset/base/250584 Log: MFC r250463: Permit relative paths with mergemaster -m PR: bin/173929 Modified: stable/8/usr.sbin/mergemaster/mergemaster.sh Directory Properties: stable/8/usr.sbin/mergemaster/ (props changed) Modified: stable/8/usr.sbin/mergemaster/mergemaster.sh ============================================================================== --- stable/8/usr.sbin/mergemaster/mergemaster.sh Mon May 13 01:20:31 2013 (r250583) +++ stable/8/usr.sbin/mergemaster/mergemaster.sh Mon May 13 01:20:36 2013 (r250584) @@ -483,6 +483,7 @@ if [ ! -f ${SOURCEDIR}/Makefile.inc1 -a sleep 3 SOURCEDIR=${SOURCEDIR}/.. fi +SOURCEDIR=$(realpath "$SOURCEDIR") # Setup make to use system files from SOURCEDIR MM_MAKE="make ${ARCHSTRING} -m ${SOURCEDIR}/share/mk" From owner-svn-src-all@FreeBSD.ORG Mon May 13 01:26:27 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id EB224A3F; Mon, 13 May 2013 01:26:27 +0000 (UTC) (envelope-from eadler@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id C2E08A19; Mon, 13 May 2013 01:26:27 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.6/8.14.6) with ESMTP id r4D1QRUI067515; Mon, 13 May 2013 01:26:27 GMT (envelope-from eadler@svn.freebsd.org) Received: (from eadler@localhost) by svn.freebsd.org (8.14.6/8.14.5/Submit) id r4D1QRqP067507; Mon, 13 May 2013 01:26:27 GMT (envelope-from eadler@svn.freebsd.org) Message-Id: <201305130126.r4D1QRqP067507@svn.freebsd.org> From: Eitan Adler Date: Mon, 13 May 2013 01:26:27 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org Subject: svn commit: r250585 - stable/9/sbin/iscontrol X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 13 May 2013 01:26:28 -0000 Author: eadler Date: Mon May 13 01:26:26 2013 New Revision: 250585 URL: http://svnweb.freebsd.org/changeset/base/250585 Log: MFC r250303: Remove includes for old versions of FreeBSD. Reviewed by: stass Modified: stable/9/sbin/iscontrol/auth_subr.c stable/9/sbin/iscontrol/fsm.c stable/9/sbin/iscontrol/login.c stable/9/sbin/iscontrol/misc.c Directory Properties: stable/9/sbin/iscontrol/ (props changed) Modified: stable/9/sbin/iscontrol/auth_subr.c ============================================================================== --- stable/9/sbin/iscontrol/auth_subr.c Mon May 13 01:20:36 2013 (r250584) +++ stable/9/sbin/iscontrol/auth_subr.c Mon May 13 01:26:26 2013 (r250585) @@ -40,9 +40,6 @@ __FBSDID("$FreeBSD$"); #include #include #include -#if __FreeBSD_version < 500000 -#include -#endif #include #include #include Modified: stable/9/sbin/iscontrol/fsm.c ============================================================================== --- stable/9/sbin/iscontrol/fsm.c Mon May 13 01:20:36 2013 (r250584) +++ stable/9/sbin/iscontrol/fsm.c Mon May 13 01:26:26 2013 (r250585) @@ -40,9 +40,6 @@ __FBSDID("$FreeBSD$"); #include #include #include -#if __FreeBSD_version < 500000 -#include -#endif #include #include #include Modified: stable/9/sbin/iscontrol/login.c ============================================================================== --- stable/9/sbin/iscontrol/login.c Mon May 13 01:20:36 2013 (r250584) +++ stable/9/sbin/iscontrol/login.c Mon May 13 01:26:26 2013 (r250585) @@ -39,9 +39,6 @@ __FBSDID("$FreeBSD$"); #include #include #include -#if __FreeBSD_version < 500000 -#include -#endif #include #include #include Modified: stable/9/sbin/iscontrol/misc.c ============================================================================== --- stable/9/sbin/iscontrol/misc.c Mon May 13 01:20:36 2013 (r250584) +++ stable/9/sbin/iscontrol/misc.c Mon May 13 01:26:26 2013 (r250585) @@ -40,9 +40,6 @@ __FBSDID("$FreeBSD$"); #include #include #include -#if __FreeBSD_version < 500000 -#include -#endif #include #include #include From owner-svn-src-all@FreeBSD.ORG Mon May 13 01:28:00 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id 526D4BC6; Mon, 13 May 2013 01:28:00 +0000 (UTC) (envelope-from eadler@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id 29F88A2B; Mon, 13 May 2013 01:28:00 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.6/8.14.6) with ESMTP id r4D1S0Ga067820; Mon, 13 May 2013 01:28:00 GMT (envelope-from eadler@svn.freebsd.org) Received: (from eadler@localhost) by svn.freebsd.org (8.14.6/8.14.5/Submit) id r4D1S0B6067819; Mon, 13 May 2013 01:28:00 GMT (envelope-from eadler@svn.freebsd.org) Message-Id: <201305130128.r4D1S0B6067819@svn.freebsd.org> From: Eitan Adler Date: Mon, 13 May 2013 01:28:00 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org Subject: svn commit: r250586 - stable/9/bin/rm X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 13 May 2013 01:28:00 -0000 Author: eadler Date: Mon May 13 01:27:59 2013 New Revision: 250586 URL: http://svnweb.freebsd.org/changeset/base/250586 Log: MFC r249949: Take some improvements from DragonFlyBSD: - add const where appropriate - add static where appropriate - fix a whitespace issues Modified: stable/9/bin/rm/rm.c Directory Properties: stable/9/bin/rm/ (props changed) Modified: stable/9/bin/rm/rm.c ============================================================================== --- stable/9/bin/rm/rm.c Mon May 13 01:26:26 2013 (r250585) +++ stable/9/bin/rm/rm.c Mon May 13 01:27:59 2013 (r250586) @@ -62,15 +62,15 @@ int rflag, Iflag; uid_t uid; volatile sig_atomic_t info; -int check(char *, char *, struct stat *); -int check2(char **); -void checkdot(char **); -void checkslash(char **); -void rm_file(char **); -int rm_overwrite(char *, struct stat *); -void rm_tree(char **); +static int check(const char *, const char *, struct stat *); +static int check2(char **); +static void checkdot(char **); +static void checkslash(char **); +static void rm_file(char **); +static int rm_overwrite(const char *, struct stat *); +static void rm_tree(char **); static void siginfo(int __unused); -void usage(void); +static void usage(void); /* * rm -- @@ -169,7 +169,7 @@ main(int argc, char *argv[]) exit (eval); } -void +static void rm_tree(char **argv) { FTS *fts; @@ -412,7 +412,7 @@ rm_file(char **argv) * have kernel support. */ int -rm_overwrite(char *file, struct stat *sbp) +rm_overwrite(const char *file, struct stat *sbp) { struct stat sb, sb2; struct statfs fsb; @@ -478,8 +478,8 @@ err: eval = 1; } -int -check(char *path, char *name, struct stat *sp) +static int +check(const char *path, const char *name, struct stat *sp) { int ch, first; char modep[15], *flagsp; @@ -490,7 +490,7 @@ check(char *path, char *name, struct sta else { /* * If it's not a symbolic link and it's unwritable and we're - * talking to a terminal, ask. Symbolic links are excluded + * talking to a terminal, ask. Symbolic links are excluded * because their permissions are meaningless. Check stdin_ok * first because we may not have stat'ed the file. */ @@ -523,7 +523,7 @@ check(char *path, char *name, struct sta } #define ISSLASH(a) ((a)[0] == '/' && (a)[1] == '\0') -void +static void checkslash(char **argv) { char **t, **u; @@ -543,7 +543,7 @@ checkslash(char **argv) } } -int +static int check2(char **argv) { struct stat st; @@ -594,7 +594,7 @@ check2(char **argv) } #define ISDOT(a) ((a)[0] == '.' && (!(a)[1] || ((a)[1] == '.' && !(a)[2]))) -void +static void checkdot(char **argv) { char *p, **save, **t; @@ -618,7 +618,7 @@ checkdot(char **argv) } } -void +static void usage(void) { From owner-svn-src-all@FreeBSD.ORG Mon May 13 01:28:09 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id C354DCD9; Mon, 13 May 2013 01:28:09 +0000 (UTC) (envelope-from eadler@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id 9CBA5A2E; Mon, 13 May 2013 01:28:09 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.6/8.14.6) with ESMTP id r4D1S9hQ067901; Mon, 13 May 2013 01:28:09 GMT (envelope-from eadler@svn.freebsd.org) Received: (from eadler@localhost) by svn.freebsd.org (8.14.6/8.14.5/Submit) id r4D1S9Fw067900; Mon, 13 May 2013 01:28:09 GMT (envelope-from eadler@svn.freebsd.org) Message-Id: <201305130128.r4D1S9Fw067900@svn.freebsd.org> From: Eitan Adler Date: Mon, 13 May 2013 01: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 Subject: svn commit: r250587 - stable/8/bin/rm X-SVN-Group: stable-8 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 13 May 2013 01:28:09 -0000 Author: eadler Date: Mon May 13 01:28:09 2013 New Revision: 250587 URL: http://svnweb.freebsd.org/changeset/base/250587 Log: MFC r249949: Take some improvements from DragonFlyBSD: - add const where appropriate - add static where appropriate - fix a whitespace issues Modified: stable/8/bin/rm/rm.c Directory Properties: stable/8/bin/rm/ (props changed) Modified: stable/8/bin/rm/rm.c ============================================================================== --- stable/8/bin/rm/rm.c Mon May 13 01:27:59 2013 (r250586) +++ stable/8/bin/rm/rm.c Mon May 13 01:28:09 2013 (r250587) @@ -62,15 +62,15 @@ int rflag, Iflag; uid_t uid; volatile sig_atomic_t info; -int check(char *, char *, struct stat *); -int check2(char **); -void checkdot(char **); -void checkslash(char **); -void rm_file(char **); -int rm_overwrite(char *, struct stat *); -void rm_tree(char **); +static int check(const char *, const char *, struct stat *); +static int check2(char **); +static void checkdot(char **); +static void checkslash(char **); +static void rm_file(char **); +static int rm_overwrite(const char *, struct stat *); +static void rm_tree(char **); static void siginfo(int __unused); -void usage(void); +static void usage(void); /* * rm -- @@ -169,7 +169,7 @@ main(int argc, char *argv[]) exit (eval); } -void +static void rm_tree(char **argv) { FTS *fts; @@ -412,7 +412,7 @@ rm_file(char **argv) * kernel support. */ int -rm_overwrite(char *file, struct stat *sbp) +rm_overwrite(const char *file, struct stat *sbp) { struct stat sb, sb2; struct statfs fsb; @@ -478,8 +478,8 @@ err: eval = 1; } -int -check(char *path, char *name, struct stat *sp) +static int +check(const char *path, const char *name, struct stat *sp) { int ch, first; char modep[15], *flagsp; @@ -490,7 +490,7 @@ check(char *path, char *name, struct sta else { /* * If it's not a symbolic link and it's unwritable and we're - * talking to a terminal, ask. Symbolic links are excluded + * talking to a terminal, ask. Symbolic links are excluded * because their permissions are meaningless. Check stdin_ok * first because we may not have stat'ed the file. */ @@ -523,7 +523,7 @@ check(char *path, char *name, struct sta } #define ISSLASH(a) ((a)[0] == '/' && (a)[1] == '\0') -void +static void checkslash(char **argv) { char **t, **u; @@ -543,7 +543,7 @@ checkslash(char **argv) } } -int +static int check2(char **argv) { struct stat st; @@ -594,7 +594,7 @@ check2(char **argv) } #define ISDOT(a) ((a)[0] == '.' && (!(a)[1] || ((a)[1] == '.' && !(a)[2]))) -void +static void checkdot(char **argv) { char *p, **save, **t; @@ -618,7 +618,7 @@ checkdot(char **argv) } } -void +static void usage(void) { From owner-svn-src-all@FreeBSD.ORG Mon May 13 01:56:18 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id 14F6E414; Mon, 13 May 2013 01:56:18 +0000 (UTC) (envelope-from jhb@freebsd.org) Received: from bigwig.baldwin.cx (bigwig.baldwin.cx [IPv6:2001:470:1f11:75::1]) by mx1.freebsd.org (Postfix) with ESMTP id DD1C6C19; Mon, 13 May 2013 01:56:17 +0000 (UTC) Received: from ralph.baldwin.cx (pool-173-70-85-244.nwrknj.fios.verizon.net [173.70.85.244]) by bigwig.baldwin.cx (Postfix) with ESMTPSA id 34EECB948; Sun, 12 May 2013 21:56:17 -0400 (EDT) From: John Baldwin To: attilio@freebsd.org Subject: Re: svn commit: r250411 - in head/sys: conf kern sys Date: Sun, 12 May 2013 21:49:13 -0400 User-Agent: KMail/1.13.7 (FreeBSD/9.1-STABLE; KDE/4.8.4; amd64; ; ) References: <201305091628.r49GSI33039873@svn.freebsd.org> <201305101533.26992.jhb@freebsd.org> In-Reply-To: MIME-Version: 1.0 Content-Type: Text/Plain; charset="utf-8" Content-Transfer-Encoding: 7bit Message-Id: <201305122149.13566.jhb@freebsd.org> X-Greylist: Sender succeeded SMTP AUTH, not delayed by milter-greylist-4.2.7 (bigwig.baldwin.cx); Sun, 12 May 2013 21:56:17 -0400 (EDT) Cc: svn-src-head@freebsd.org, svn-src-all@freebsd.org, Marcel Moolenaar , src-committers@freebsd.org, Marcel Moolenaar X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 13 May 2013 01:56:18 -0000 On Saturday, May 11, 2013 10:34:50 AM Attilio Rao wrote: > On Fri, May 10, 2013 at 9:33 PM, John Baldwin wrote: > > On Friday, May 10, 2013 2:51:20 pm Marcel Moolenaar wrote: > >> On May 10, 2013, at 9:11 AM, John Baldwin wrote: > >> > On Friday, May 10, 2013 11:46:54 am Marcel Moolenaar wrote: > >> >>> 2) vnode locks from a local filesystem that report a LOR with a > >> >>> "devfs" > >> >>> > >> >>> vnode. Typical reports are either "ufs" -> "devfs" or in some > >> >>> cases "ufs" -> "devfs" -> "ufs". As with 1), I would much rather > >> >>> tag the offending location than to disable all WITNESS checking on > >> >>> vnode locks. > >> >> > >> >> With more file system types in use, this will get mixed up with the > >> >> other file systems and noise you get is rather severe. It is a big > >> >> problem for us at Juniper. > >> > > >> > Note, it is very specific that the second lock is always "devfs". I > >> > think that points to this being isolated to a few specific places, > >> > not a generic ordering problem. > >> > >> Alas, that's not the case. These LORs are reported between ufs and > >> unionfs, or ufs and isofs, etc. It's not just between something and > >> devfs. > > > > Ugh, I have only seen them with devfs so had presumed them to be more > > localized (and thus more easily targeted). In that case your change > > may be as fine-grained as we can get. I would also like to still keep > > WITNESS checking between vnode locks and other lock types, and > > LK_NOWITNESS would remove that, so between your change and Attilio's > > approach I do prefer yours. > > > >> I'm not sure the only options we have are to ignore the problem > >> or implement a general fix. If we set out to silence witness for > >> the known false positives then it's ok to handle them on a case > >> by case basis. We'll see patterns soon enough and then re-code > >> the solutions in terms of those patterns. If we're lucky we see > >> a single general solution, but if not, then it's fine to have a > >> handful of special case. The worse we can do is not address it > >> at all. > > > > I was assuming that the reversals were far more specific, and knowing > > about other false positives like the dirhash one, I want a generic way > > to do more fine-grained marking of false positives. If there were only > > a few places we would need to mark to fix the reversals you see, then I > > would prefer the suspend/resume approach for your case. However, the > > reversals you are masking sound too widespread to support that. > > The solution to this is what I proposed: pass down a LK_NOWITNESS for > instances where you don't want to check for witness. > This is per lock-call. > You localize the fix to the instance you want to shut down and you > skip witness for every false-positive. > When you commit the LK_NOWITNESS you mention explicitely the reason > why the reported LOR is a false positive so it is also documented on > svn. > > I still don't understand what you are objecting. Marcel objections' > were completely no-sense (Don't want to involve Witness) but at least > I expect some decent one by you. I think the problem is you'd have to tag an awful lot of places to catch all the issues Marcel is reporting. If you want to take all the LORs and tag them instead, go for it. Also, while LK_NOWITESS works fine for lockmgr's API (it already takes a flag argument), having that sort of thing in our other lock APIs is messier (they generally do not have flags). This is why a per-thread flag seemed simpler to me for this as you don't have to change umpteen locking APIs to add a new flags field. -- John Baldwin From owner-svn-src-all@FreeBSD.ORG Mon May 13 05:27:45 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id 21AE9F29; Mon, 13 May 2013 05:27:45 +0000 (UTC) (envelope-from delphij@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id 13B6B6C3; Mon, 13 May 2013 05:27:45 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.6/8.14.6) with ESMTP id r4D5Rj5O053219; Mon, 13 May 2013 05:27:45 GMT (envelope-from delphij@svn.freebsd.org) Received: (from delphij@localhost) by svn.freebsd.org (8.14.6/8.14.5/Submit) id r4D5Rho7053212; Mon, 13 May 2013 05:27:43 GMT (envelope-from delphij@svn.freebsd.org) Message-Id: <201305130527.r4D5Rho7053212@svn.freebsd.org> From: Xin LI Date: Mon, 13 May 2013 05:27:43 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-vendor@freebsd.org Subject: svn commit: r250590 - vendor/less/dist X-SVN-Group: vendor MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 13 May 2013 05:27:45 -0000 Author: delphij Date: Mon May 13 05:27:43 2013 New Revision: 250590 URL: http://svnweb.freebsd.org/changeset/base/250590 Log: Vendor import of less v458. Modified: vendor/less/dist/NEWS vendor/less/dist/README vendor/less/dist/cmdbuf.c vendor/less/dist/help.c vendor/less/dist/less.hlp vendor/less/dist/less.man vendor/less/dist/less.nro vendor/less/dist/lessecho.man vendor/less/dist/lessecho.nro vendor/less/dist/lesskey.man vendor/less/dist/lesskey.nro vendor/less/dist/option.c vendor/less/dist/opttbl.c vendor/less/dist/version.c Modified: vendor/less/dist/NEWS ============================================================================== --- vendor/less/dist/NEWS Mon May 13 04:47:26 2013 (r250589) +++ vendor/less/dist/NEWS Mon May 13 05:27:43 2013 (r250590) @@ -11,9 +11,10 @@ ====================================================================== - Major changes between "less" versions 451 and 456 + Major changes between "less" versions 451 and 458 -* Allow backslash escaping of metacharacters in LESS environment variable. +* Allow backslash escaping of metacharacters in LESS environment variable + after the --use-backslash option. * Don't quit if syntax errors are found in command line options. @@ -25,6 +26,8 @@ * Fix Win32 attribute display bug. +* Fix display bug when using up/down arrow on the command line. + ====================================================================== Major changes between "less" versions 444 and 451 Modified: vendor/less/dist/README ============================================================================== --- vendor/less/dist/README Mon May 13 04:47:26 2013 (r250589) +++ vendor/less/dist/README Mon May 13 05:27:43 2013 (r250590) @@ -1,7 +1,7 @@ - Less, version 456 + Less, version 458 - This is the distribution of less, version 456, released 08 Nov 2012. + This is the distribution of less, version 458, released 04 Apr 2013. This program is part of the GNU project (http://www.gnu.org). This program is free software. You may redistribute it and/or Modified: vendor/less/dist/cmdbuf.c ============================================================================== --- vendor/less/dist/cmdbuf.c Mon May 13 04:47:26 2013 (r250589) +++ vendor/less/dist/cmdbuf.c Mon May 13 05:27:43 2013 (r250590) @@ -727,9 +727,9 @@ cmd_updown(action) s = ml->string; if (s == NULL) s = ""; - strcpy(cmdbuf, s); cmd_home(); clear_eol(); + strcpy(cmdbuf, s); for (cp = cmdbuf; *cp != '\0'; ) cmd_right(); return (CC_OK); Modified: vendor/less/dist/help.c ============================================================================== --- vendor/less/dist/help.c Mon May 13 04:47:26 2013 (r250589) +++ vendor/less/dist/help.c Mon May 13 05:27:43 2013 (r250590) @@ -110,7 +110,7 @@ constant char helpdata[] = { ' ',' ',' ',' ',' ',' ',' ',' ','M','o','s','t',' ','o','p','t','i','o','n','s',' ','m','a','y',' ','b','e',' ','c','h','a','n','g','e','d',' ','e','i','t','h','e','r',' ','o','n',' ','t','h','e',' ','c','o','m','m','a','n','d',' ','l','i','n','e',',','\n', ' ',' ',' ',' ',' ',' ',' ',' ','o','r',' ','f','r','o','m',' ','w','i','t','h','i','n',' ','l','e','s','s',' ','b','y',' ','u','s','i','n','g',' ','t','h','e',' ','-',' ','o','r',' ','-','-',' ','c','o','m','m','a','n','d','.','\n', ' ',' ',' ',' ',' ',' ',' ',' ','O','p','t','i','o','n','s',' ','m','a','y',' ','b','e',' ','g','i','v','e','n',' ','i','n',' ','o','n','e',' ','o','f',' ','t','w','o',' ','f','o','r','m','s',':',' ','e','i','t','h','e','r',' ','a',' ','s','i','n','g','l','e','\n', -' ',' ',' ',' ',' ',' ',' ',' ','c','h','a','r','a','c','t','e','r',' ','p','r','e','c','e','d','e','d',' ','b','y',' ','a',' ','-',',',' ','o','r',' ','a',' ','n','a','m','e',' ','p','r','e','c','e','e','d','e','d',' ','b','y',' ','-','-','.','\n', +' ',' ',' ',' ',' ',' ',' ',' ','c','h','a','r','a','c','t','e','r',' ','p','r','e','c','e','d','e','d',' ','b','y',' ','a',' ','-',',',' ','o','r',' ','a',' ','n','a','m','e',' ','p','r','e','c','e','d','e','d',' ','b','y',' ','-','-','.','\n', '\n', ' ',' ','-','?',' ',' ','.','.','.','.','.','.','.','.',' ',' ','-','-','h','e','l','p','\n', ' ',' ',' ',' ',' ',' ',' ',' ',' ',' ',' ',' ',' ',' ',' ',' ',' ',' ','D','i','s','p','l','a','y',' ','h','e','l','p',' ','(','f','r','o','m',' ','c','o','m','m','a','n','d',' ','l','i','n','e',')','.','\n', Modified: vendor/less/dist/less.hlp ============================================================================== --- vendor/less/dist/less.hlp Mon May 13 04:47:26 2013 (r250589) +++ vendor/less/dist/less.hlp Mon May 13 05:27:43 2013 (r250590) @@ -107,7 +107,7 @@ Most options may be changed either on the command line, or from within less by using the - or -- command. Options may be given in one of two forms: either a single - character preceded by a -, or a name preceeded by --. + character preceded by a -, or a name preceded by --. -? ........ --help Display help (from command line). Modified: vendor/less/dist/less.man ============================================================================== --- vendor/less/dist/less.man Mon May 13 04:47:26 2013 (r250589) +++ vendor/less/dist/less.man Mon May 13 05:27:43 2013 (r250590) @@ -444,58 +444,61 @@ LESS(1) LESS="Dn9.1$Ds4.1" - A dollar sign or backslash may be included literally in an option - string by preceding it with a backslash. + If the --use-backslash option appears earlier in the options, then a + dollar sign or backslash may be included literally in an option string + by preceding it with a backslash. If the --use-backslash option is not + in effect, then backslashes are not treated specially, and there is no + way to include a dollar sign in the option string. -? or --help - This option displays a summary of the commands accepted by less - (the same as the h command). (Depending on how your shell - interprets the question mark, it may be necessary to quote the + This option displays a summary of the commands accepted by less + (the same as the h command). (Depending on how your shell + interprets the question mark, it may be necessary to quote the question mark, thus: "-\?".) -a or --search-skip-screen - By default, forward searches start at the top of the displayed - screen and backwards searches start at the bottom of the dis- - played screen (except for repeated searches invoked by the n or - N commands, which start after or before the "target" line + By default, forward searches start at the top of the displayed + screen and backwards searches start at the bottom of the dis- + played screen (except for repeated searches invoked by the n or + N commands, which start after or before the "target" line respectively; see the -j option for more about the target line). - The -a option causes forward searches to instead start at the - bottom of the screen and backward searches to start at the top + The -a option causes forward searches to instead start at the + bottom of the screen and backward searches to start at the top of the screen, thus skipping all lines displayed on the screen. -A or --SEARCH-SKIP-SCREEN - Causes all forward searches (not just non-repeated searches) to - start just after the target line, and all backward searches to - start just before the target line. Thus, forward searches will + Causes all forward searches (not just non-repeated searches) to + start just after the target line, and all backward searches to + start just before the target line. Thus, forward searches will skip part of the displayed screen (from the first line up to and - including the target line). Similarly backwards searches will + including the target line). Similarly backwards searches will skip the displayed screen from the last line up to and including the target line. This was the default behavior in less versions prior to 441. -bn or --buffers=n - Specifies the amount of buffer space less will use for each - file, in units of kilobytes (1024 bytes). By default 64K of - buffer space is used for each file (unless the file is a pipe; - see the -B option). The -b option specifies instead that n + Specifies the amount of buffer space less will use for each + file, in units of kilobytes (1024 bytes). By default 64K of + buffer space is used for each file (unless the file is a pipe; + see the -B option). The -b option specifies instead that n kilobytes of buffer space should be used for each file. If n is - -1, buffer space is unlimited; that is, the entire file can be + -1, buffer space is unlimited; that is, the entire file can be read into memory. -B or --auto-buffers By default, when data is read from a pipe, buffers are allocated automatically as needed. If a large amount of data is read from - the pipe, this can cause a large amount of memory to be allo- + the pipe, this can cause a large amount of memory to be allo- cated. The -B option disables this automatic allocation of buf- - fers for pipes, so that only 64K (or the amount of space speci- + fers for pipes, so that only 64K (or the amount of space speci- fied by the -b option) is used for the pipe. Warning: use of -B - can result in erroneous display, since only the most recently - viewed part of the piped data is kept in memory; any earlier + can result in erroneous display, since only the most recently + viewed part of the piped data is kept in memory; any earlier data is lost. -c or --clear-screen - Causes full screen repaints to be painted from the top line - down. By default, full screen repaints are done by scrolling + Causes full screen repaints to be painted from the top line + down. By default, full screen repaints are done by scrolling from the bottom of the screen. -C or --CLEAR-SCREEN @@ -503,24 +506,24 @@ LESS(1) -d or --dumb The -d option suppresses the error message normally displayed if - the terminal is dumb; that is, lacks some important capability, + the terminal is dumb; that is, lacks some important capability, such as the ability to clear the screen or scroll backward. The - -d option does not otherwise change the behavior of less on a + -d option does not otherwise change the behavior of less on a dumb terminal. -Dxcolor or --color=xcolor [MS-DOS only] Sets the color of the text displayed. x is a sin- - gle character which selects the type of text whose color is - being set: n=normal, s=standout, d=bold, u=underlined, k=blink. - color is a pair of numbers separated by a period. The first - number selects the foreground color and the second selects the - background color of the text. A single number N is the same as + gle character which selects the type of text whose color is + being set: n=normal, s=standout, d=bold, u=underlined, k=blink. + color is a pair of numbers separated by a period. The first + number selects the foreground color and the second selects the + background color of the text. A single number N is the same as N.M, where M is the normal background color. -e or --quit-at-eof - Causes less to automatically exit the second time it reaches - end-of-file. By default, the only way to exit less is via the + Causes less to automatically exit the second time it reaches + end-of-file. By default, the only way to exit less is via the "q" command. -E or --QUIT-AT-EOF @@ -529,7 +532,7 @@ LESS(1) -f or --force Forces non-regular files to be opened. (A non-regular file is a - directory or a device special file.) Also suppresses the warn- + directory or a device special file.) Also suppresses the warn- ing message when a binary file is opened. By default, less will refuse to open non-regular files. Note that some operating sys- tems will not allow directories to be read, even if -f is set. @@ -539,236 +542,236 @@ LESS(1) played on the first screen. -g or --hilite-search - Normally, less will highlight ALL strings which match the last - search command. The -g option changes this behavior to high- - light only the particular string which was found by the last + Normally, less will highlight ALL strings which match the last + search command. The -g option changes this behavior to high- + light only the particular string which was found by the last search command. This can cause less to run somewhat faster than the default. -G or --HILITE-SEARCH - The -G option suppresses all highlighting of strings found by + The -G option suppresses all highlighting of strings found by search commands. -hn or --max-back-scroll=n - Specifies a maximum number of lines to scroll backward. If it + Specifies a maximum number of lines to scroll backward. If it is necessary to scroll backward more than n lines, the screen is repainted in a forward direction instead. (If the terminal does not have the ability to scroll backward, -h0 is implied.) -i or --ignore-case Causes searches to ignore case; that is, uppercase and lowercase - are considered identical. This option is ignored if any upper- - case letters appear in the search pattern; in other words, if a - pattern contains uppercase letters, then that search does not + are considered identical. This option is ignored if any upper- + case letters appear in the search pattern; in other words, if a + pattern contains uppercase letters, then that search does not ignore case. -I or --IGNORE-CASE - Like -i, but searches ignore case even if the pattern contains + Like -i, but searches ignore case even if the pattern contains uppercase letters. -jn or --jump-target=n - Specifies a line on the screen where the "target" line is to be - positioned. The target line is the line specified by any com- - mand to search for a pattern, jump to a line number, jump to a + Specifies a line on the screen where the "target" line is to be + positioned. The target line is the line specified by any com- + mand to search for a pattern, jump to a line number, jump to a file percentage or jump to a tag. The screen line may be speci- - fied by a number: the top line on the screen is 1, the next is + fied by a number: the top line on the screen is 1, the next is 2, and so on. The number may be negative to specify a line rel- ative to the bottom of the screen: the bottom line on the screen - is -1, the second to the bottom is -2, and so on. Alternately, - the screen line may be specified as a fraction of the height of - the screen, starting with a decimal point: .5 is in the middle - of the screen, .3 is three tenths down from the first line, and - so on. If the line is specified as a fraction, the actual line - number is recalculated if the terminal window is resized, so - that the target line remains at the specified fraction of the - screen height. If any form of the -j option is used, forward - searches begin at the line immediately after the target line, - and backward searches begin at the target line, unless changed - by -a or -A. For example, if "-j4" is used, the target line is - the fourth line on the screen, so forward searches begin at the + is -1, the second to the bottom is -2, and so on. Alternately, + the screen line may be specified as a fraction of the height of + the screen, starting with a decimal point: .5 is in the middle + of the screen, .3 is three tenths down from the first line, and + so on. If the line is specified as a fraction, the actual line + number is recalculated if the terminal window is resized, so + that the target line remains at the specified fraction of the + screen height. If any form of the -j option is used, forward + searches begin at the line immediately after the target line, + and backward searches begin at the target line, unless changed + by -a or -A. For example, if "-j4" is used, the target line is + the fourth line on the screen, so forward searches begin at the fifth line on the screen. -J or --status-column - Displays a status column at the left edge of the screen. The - status column shows the lines that matched the current search. - The status column is also used if the -w or -W option is in + Displays a status column at the left edge of the screen. The + status column shows the lines that matched the current search. + The status column is also used if the -w or -W option is in effect. -kfilename or --lesskey-file=filename - Causes less to open and interpret the named file as a lesskey + Causes less to open and interpret the named file as a lesskey (1) file. Multiple -k options may be specified. If the LESSKEY - or LESSKEY_SYSTEM environment variable is set, or if a lesskey + or LESSKEY_SYSTEM environment variable is set, or if a lesskey file is found in a standard place (see KEY BINDINGS), it is also used as a lesskey file. -K or --quit-on-intr - Causes less to exit immediately (with status 2) when an inter- - rupt character (usually ^C) is typed. Normally, an interrupt + Causes less to exit immediately (with status 2) when an inter- + rupt character (usually ^C) is typed. Normally, an interrupt character causes less to stop whatever it is doing and return to - its command prompt. Note that use of this option makes it + its command prompt. Note that use of this option makes it impossible to return to the command prompt from the "F" command. -L or --no-lessopen - Ignore the LESSOPEN environment variable (see the INPUT PRE- - PROCESSOR section below). This option can be set from within - less, but it will apply only to files opened subsequently, not + Ignore the LESSOPEN environment variable (see the INPUT PRE- + PROCESSOR section below). This option can be set from within + less, but it will apply only to files opened subsequently, not to the file which is currently open. -m or --long-prompt - Causes less to prompt verbosely (like more), with the percent + Causes less to prompt verbosely (like more), with the percent into the file. By default, less prompts with a colon. -M or --LONG-PROMPT Causes less to prompt even more verbosely than more. -n or --line-numbers - Suppresses line numbers. The default (to use line numbers) may - cause less to run more slowly in some cases, especially with a - very large input file. Suppressing line numbers with the -n - option will avoid this problem. Using line numbers means: the + Suppresses line numbers. The default (to use line numbers) may + cause less to run more slowly in some cases, especially with a + very large input file. Suppressing line numbers with the -n + option will avoid this problem. Using line numbers means: the line number will be displayed in the verbose prompt and in the = - command, and the v command will pass the current line number to - the editor (see also the discussion of LESSEDIT in PROMPTS + command, and the v command will pass the current line number to + the editor (see also the discussion of LESSEDIT in PROMPTS below). -N or --LINE-NUMBERS - Causes a line number to be displayed at the beginning of each + Causes a line number to be displayed at the beginning of each line in the display. -ofilename or --log-file=filename - Causes less to copy its input to the named file as it is being + Causes less to copy its input to the named file as it is being viewed. This applies only when the input file is a pipe, not an - ordinary file. If the file already exists, less will ask for + ordinary file. If the file already exists, less will ask for confirmation before overwriting it. -Ofilename or --LOG-FILE=filename The -O option is like -o, but it will overwrite an existing file without asking for confirmation. - If no log file has been specified, the -o and -O options can be - used from within less to specify a log file. Without a file + If no log file has been specified, the -o and -O options can be + used from within less to specify a log file. Without a file name, they will simply report the name of the log file. The "s" command is equivalent to specifying -o from within less. -ppattern or --pattern=pattern - The -p option on the command line is equivalent to specifying - +/pattern; that is, it tells less to start at the first occur- + The -p option on the command line is equivalent to specifying + +/pattern; that is, it tells less to start at the first occur- rence of pattern in the file. -Pprompt or --prompt=prompt - Provides a way to tailor the three prompt styles to your own + Provides a way to tailor the three prompt styles to your own preference. This option would normally be put in the LESS envi- ronment variable, rather than being typed in with each less com- mand. Such an option must either be the last option in the LESS - variable, or be terminated by a dollar sign. -Ps followed by a - string changes the default (short) prompt to that string. -Pm - changes the medium (-m) prompt. -PM changes the long (-M) - prompt. -Ph changes the prompt for the help screen. -P= - changes the message printed by the = command. -Pw changes the - message printed while waiting for data (in the F command). All - prompt strings consist of a sequence of letters and special + variable, or be terminated by a dollar sign. -Ps followed by a + string changes the default (short) prompt to that string. -Pm + changes the medium (-m) prompt. -PM changes the long (-M) + prompt. -Ph changes the prompt for the help screen. -P= + changes the message printed by the = command. -Pw changes the + message printed while waiting for data (in the F command). All + prompt strings consist of a sequence of letters and special escape sequences. See the section on PROMPTS for more details. -q or --quiet or --silent - Causes moderately "quiet" operation: the terminal bell is not + Causes moderately "quiet" operation: the terminal bell is not rung if an attempt is made to scroll past the end of the file or before the beginning of the file. If the terminal has a "visual - bell", it is used instead. The bell will be rung on certain - other errors, such as typing an invalid character. The default + bell", it is used instead. The bell will be rung on certain + other errors, such as typing an invalid character. The default is to ring the terminal bell in all such cases. -Q or --QUIET or --SILENT - Causes totally "quiet" operation: the terminal bell is never + Causes totally "quiet" operation: the terminal bell is never rung. -r or --raw-control-chars Causes "raw" control characters to be displayed. The default is - to display control characters using the caret notation; for + to display control characters using the caret notation; for example, a control-A (octal 001) is displayed as "^A". Warning: when the -r option is used, less cannot keep track of the actual - appearance of the screen (since this depends on how the screen + appearance of the screen (since this depends on how the screen responds to each type of control character). Thus, various dis- - play problems may result, such as long lines being split in the + play problems may result, such as long lines being split in the wrong place. -R or --RAW-CONTROL-CHARS - Like -r, but only ANSI "color" escape sequences are output in + Like -r, but only ANSI "color" escape sequences are output in "raw" form. Unlike -r, the screen appearance is maintained cor- rectly in most cases. ANSI "color" escape sequences are sequences of the form: ESC [ ... m - where the "..." is zero or more color specification characters - For the purpose of keeping track of screen appearance, ANSI - color escape sequences are assumed to not move the cursor. You - can make less think that characters other than "m" can end ANSI - color escape sequences by setting the environment variable + where the "..." is zero or more color specification characters + For the purpose of keeping track of screen appearance, ANSI + color escape sequences are assumed to not move the cursor. You + can make less think that characters other than "m" can end ANSI + color escape sequences by setting the environment variable LESSANSIENDCHARS to the list of characters which can end a color - escape sequence. And you can make less think that characters - other than the standard ones may appear between the ESC and the - m by setting the environment variable LESSANSIMIDCHARS to the + escape sequence. And you can make less think that characters + other than the standard ones may appear between the ESC and the + m by setting the environment variable LESSANSIMIDCHARS to the list of characters which can appear. -s or --squeeze-blank-lines - Causes consecutive blank lines to be squeezed into a single + Causes consecutive blank lines to be squeezed into a single blank line. This is useful when viewing nroff output. -S or --chop-long-lines - Causes lines longer than the screen width to be chopped (trun- + Causes lines longer than the screen width to be chopped (trun- cated) rather than wrapped. That is, the portion of a long line that does not fit in the screen width is not shown. The default - is to wrap long lines; that is, display the remainder on the + is to wrap long lines; that is, display the remainder on the next line. -ttag or --tag=tag The -t option, followed immediately by a TAG, will edit the file - containing that tag. For this to work, tag information must be - available; for example, there may be a file in the current + containing that tag. For this to work, tag information must be + available; for example, there may be a file in the current directory called "tags", which was previously built by ctags (1) or an equivalent command. If the environment variable LESSGLOB- - ALTAGS is set, it is taken to be the name of a command compati- - ble with global (1), and that command is executed to find the + ALTAGS is set, it is taken to be the name of a command compati- + ble with global (1), and that command is executed to find the tag. (See http://www.gnu.org/software/global/global.html). The - -t option may also be specified from within less (using the - - command) as a way of examining a new file. The command ":t" is + -t option may also be specified from within less (using the - + command) as a way of examining a new file. The command ":t" is equivalent to specifying -t from within less. -Ttagsfile or --tag-file=tagsfile Specifies a tags file to be used instead of "tags". -u or --underline-special - Causes backspaces and carriage returns to be treated as print- - able characters; that is, they are sent to the terminal when + Causes backspaces and carriage returns to be treated as print- + able characters; that is, they are sent to the terminal when they appear in the input. -U or --UNDERLINE-SPECIAL - Causes backspaces, tabs and carriage returns to be treated as - control characters; that is, they are handled as specified by + Causes backspaces, tabs and carriage returns to be treated as + control characters; that is, they are handled as specified by the -r option. - By default, if neither -u nor -U is given, backspaces which - appear adjacent to an underscore character are treated spe- - cially: the underlined text is displayed using the terminal's - hardware underlining capability. Also, backspaces which appear - between two identical characters are treated specially: the - overstruck text is printed using the terminal's hardware bold- - face capability. Other backspaces are deleted, along with the + By default, if neither -u nor -U is given, backspaces which + appear adjacent to an underscore character are treated spe- + cially: the underlined text is displayed using the terminal's + hardware underlining capability. Also, backspaces which appear + between two identical characters are treated specially: the + overstruck text is printed using the terminal's hardware bold- + face capability. Other backspaces are deleted, along with the preceding character. Carriage returns immediately followed by a - newline are deleted. Other carriage returns are handled as - specified by the -r option. Text which is overstruck or under- + newline are deleted. Other carriage returns are handled as + specified by the -r option. Text which is overstruck or under- lined can be searched for if neither -u nor -U is in effect. -V or --version Displays the version number of less. -w or --hilite-unread - Temporarily highlights the first "new" line after a forward + Temporarily highlights the first "new" line after a forward movement of a full page. The first "new" line is the line imme- - diately following the line previously at the bottom of the + diately following the line previously at the bottom of the screen. Also highlights the target line after a g or p command. - The highlight is removed at the next command which causes move- - ment. The entire line is highlighted, unless the -J option is + The highlight is removed at the next command which causes move- + ment. The entire line is highlighted, unless the -J option is in effect, in which case only the status column is highlighted. -W or --HILITE-UNREAD @@ -776,48 +779,48 @@ LESS(1) forward movement command larger than one line. -xn,... or --tabs=n,... - Sets tab stops. If only one n is specified, tab stops are set - at multiples of n. If multiple values separated by commas are - specified, tab stops are set at those positions, and then con- - tinue with the same spacing as the last two. For example, - -x9,17 will set tabs at positions 9, 17, 25, 33, etc. The + Sets tab stops. If only one n is specified, tab stops are set + at multiples of n. If multiple values separated by commas are + specified, tab stops are set at those positions, and then con- + tinue with the same spacing as the last two. For example, + -x9,17 will set tabs at positions 9, 17, 25, 33, etc. The default for n is 8. -X or --no-init Disables sending the termcap initialization and deinitialization - strings to the terminal. This is sometimes desirable if the - deinitialization string does something unnecessary, like clear- + strings to the terminal. This is sometimes desirable if the + deinitialization string does something unnecessary, like clear- ing the screen. -yn or --max-forw-scroll=n Specifies a maximum number of lines to scroll forward. If it is - necessary to scroll forward more than n lines, the screen is - repainted instead. The -c or -C option may be used to repaint - from the top of the screen if desired. By default, any forward + necessary to scroll forward more than n lines, the screen is + repainted instead. The -c or -C option may be used to repaint + from the top of the screen if desired. By default, any forward movement causes scrolling. -[z]n or --window=n - Changes the default scrolling window size to n lines. The + Changes the default scrolling window size to n lines. The default is one screenful. The z and w commands can also be used - to change the window size. The "z" may be omitted for compati- + to change the window size. The "z" may be omitted for compati- bility with some versions of more. If the number n is negative, - it indicates n lines less than the current screen size. For + it indicates n lines less than the current screen size. For example, if the screen is 24 lines, -z-4 sets the scrolling win- - dow to 20 lines. If the screen is resized to 40 lines, the + dow to 20 lines. If the screen is resized to 40 lines, the scrolling window automatically changes to 36 lines. -"cc or --quotes=cc - Changes the filename quoting character. This may be necessary - if you are trying to name a file which contains both spaces and - quote characters. Followed by a single character, this changes - the quote character to that character. Filenames containing a + Changes the filename quoting character. This may be necessary + if you are trying to name a file which contains both spaces and + quote characters. Followed by a single character, this changes + the quote character to that character. Filenames containing a space should then be surrounded by that character rather than by - double quotes. Followed by two characters, changes the open - quote to the first character, and the close quote to the second + double quotes. Followed by two characters, changes the open + quote to the first character, and the close quote to the second character. Filenames containing a space should then be preceded - by the open quote character and followed by the close quote - character. Note that even after the quote characters are - changed, this option remains -" (a dash followed by a double + by the open quote character and followed by the close quote + character. Note that even after the quote characters are + changed, this option remains -" (a dash followed by a double quote). -~ or --tilde @@ -827,60 +830,67 @@ LESS(1) -# or --shift Specifies the default number of positions to scroll horizontally - in the RIGHTARROW and LEFTARROW commands. If the number speci- - fied is zero, it sets the default number of positions to one + in the RIGHTARROW and LEFTARROW commands. If the number speci- + fied is zero, it sets the default number of positions to one half of the screen width. Alternately, the number may be speci- - fied as a fraction of the width of the screen, starting with a - decimal point: .5 is half of the screen width, .3 is three - tenths of the screen width, and so on. If the number is speci- - fied as a fraction, the actual number of scroll positions is - recalculated if the terminal window is resized, so that the - actual scroll remains at the specified fraction of the screen + fied as a fraction of the width of the screen, starting with a + decimal point: .5 is half of the screen width, .3 is three + tenths of the screen width, and so on. If the number is speci- + fied as a fraction, the actual number of scroll positions is + recalculated if the terminal window is resized, so that the + actual scroll remains at the specified fraction of the screen width. + --follow-name + Normally, if the input file is renamed while an F command is + executing, less will continue to display the contents of the + original file despite its name change. If --follow-name is + specified, during an F command less will periodically attempt to + reopen the file by name. If the reopen succeeds and the file is + a different file from the original (which means that a new file + has been created with the same name as the original (now + renamed) file), less will display the contents of that new file. + --no-keypad Disables sending the keypad initialization and deinitialization strings to the terminal. This is sometimes useful if the keypad strings make the numeric keypad behave in an undesirable manner. - --follow-name - Normally, if the input file is renamed while an F command is - executing, less will continue to display the contents of the - original file despite its name change. If --follow-name is - specified, during an F command less will periodically attempt to - reopen the file by name. If the reopen succeeds and the file is - a different file from the original (which means that a new file - has been created with the same name as the original (now - renamed) file), less will display the contents of that new file. + --use-backslash + This option changes the interpretations of options which follow + this one. After the --use-backslash option, any backslash in an + option string is removed and the following character is taken + literally. This allows a dollar sign to be included in option + strings. - -- A command line argument of "--" marks the end of option argu- - ments. Any arguments following this are interpreted as file- + -- A command line argument of "--" marks the end of option argu- + ments. Any arguments following this are interpreted as file- names. This can be useful when viewing a file whose name begins with a "-" or "+". - + If a command line option begins with +, the remainder of that - option is taken to be an initial command to less. For example, - +G tells less to start at the end of the file rather than the - beginning, and +/xyz tells it to start at the first occurrence - of "xyz" in the file. As a special case, + acts like + + If a command line option begins with +, the remainder of that + option is taken to be an initial command to less. For example, + +G tells less to start at the end of the file rather than the + beginning, and +/xyz tells it to start at the first occurrence + of "xyz" in the file. As a special case, + acts like +g; that is, it starts the display at the specified line - number (however, see the caveat under the "g" command above). - If the option starts with ++, the initial command applies to - every file being viewed, not just the first one. The + command + number (however, see the caveat under the "g" command above). + If the option starts with ++, the initial command applies to + every file being viewed, not just the first one. The + command described previously may also be used to set (or change) an ini- tial command for every file. LINE EDITING - When entering command line at the bottom of the screen (for example, a + When entering command line at the bottom of the screen (for example, a filename for the :e command, or the pattern for a search command), cer- - tain keys can be used to manipulate the command line. Most commands - have an alternate form in [ brackets ] which can be used if a key does - not exist on a particular keyboard. (Note that the forms beginning - with ESC do not work in some MS-DOS and Windows systems because ESC is - the line erase character.) Any of these special keys may be entered - literally by preceding it with the "literal" character, either ^V or - ^A. A backslash itself may also be entered literally by entering two + tain keys can be used to manipulate the command line. Most commands + have an alternate form in [ brackets ] which can be used if a key does + not exist on a particular keyboard. (Note that the forms beginning + with ESC do not work in some MS-DOS and Windows systems because ESC is + the line erase character.) Any of these special keys may be entered + literally by preceding it with the "literal" character, either ^V or + ^A. A backslash itself may also be entered literally by entering two backslashes. LEFTARROW [ ESC-h ] @@ -890,7 +900,7 @@ LESS(1) Move the cursor one space to the right. ^LEFTARROW [ ESC-b or ESC-LEFTARROW ] - (That is, CONTROL and LEFTARROW simultaneously.) Move the cur- + (That is, CONTROL and LEFTARROW simultaneously.) Move the cur- sor one word to the left. ^RIGHTARROW [ ESC-w or ESC-RIGHTARROW ] @@ -904,48 +914,48 @@ LESS(1) Move the cursor to the end of the line. BACKSPACE - Delete the character to the left of the cursor, or cancel the + Delete the character to the left of the cursor, or cancel the command if the command line is empty. DELETE or [ ESC-x ] Delete the character under the cursor. ^BACKSPACE [ ESC-BACKSPACE ] - (That is, CONTROL and BACKSPACE simultaneously.) Delete the + (That is, CONTROL and BACKSPACE simultaneously.) Delete the word to the left of the cursor. ^DELETE [ ESC-X or ESC-DELETE ] - (That is, CONTROL and DELETE simultaneously.) Delete the word + (That is, CONTROL and DELETE simultaneously.) Delete the word under the cursor. UPARROW [ ESC-k ] - Retrieve the previous command line. If you first enter some - text and then press UPARROW, it will retrieve the previous com- + Retrieve the previous command line. If you first enter some + text and then press UPARROW, it will retrieve the previous com- mand which begins with that text. DOWNARROW [ ESC-j ] - Retrieve the next command line. If you first enter some text - and then press DOWNARROW, it will retrieve the next command + Retrieve the next command line. If you first enter some text + and then press DOWNARROW, it will retrieve the next command which begins with that text. - TAB Complete the partial filename to the left of the cursor. If it - matches more than one filename, the first match is entered into - the command line. Repeated TABs will cycle thru the other + TAB Complete the partial filename to the left of the cursor. If it + matches more than one filename, the first match is entered into + the command line. Repeated TABs will cycle thru the other matching filenames. If the completed filename is a directory, a - "/" is appended to the filename. (On MS-DOS systems, a "\" is - appended.) The environment variable LESSSEPARATOR can be used + "/" is appended to the filename. (On MS-DOS systems, a "\" is + appended.) The environment variable LESSSEPARATOR can be used to specify a different character to append to a directory name. BACKTAB [ ESC-TAB ] Like, TAB, but cycles in the reverse direction thru the matching filenames. - ^L Complete the partial filename to the left of the cursor. If it + ^L Complete the partial filename to the left of the cursor. If it matches more than one filename, all matches are entered into the command line (if they fit). ^U (Unix and OS/2) or ESC (MS-DOS) - Delete the entire command line, or cancel the command if the + Delete the entire command line, or cancel the command if the command line is empty. If you have changed your line-kill char- acter in Unix to something other than ^U, that character is used instead of ^U. @@ -954,72 +964,72 @@ LESS(1) KEY BINDINGS - You may define your own less commands by using the program lesskey (1) - to create a lesskey file. This file specifies a set of command keys - and an action associated with each key. You may also use lesskey to + You may define your own less commands by using the program lesskey (1) + to create a lesskey file. This file specifies a set of command keys + and an action associated with each key. You may also use lesskey to change the line-editing keys (see LINE EDITING), and to set environment - variables. If the environment variable LESSKEY is set, less uses that - as the name of the lesskey file. Otherwise, less looks in a standard - place for the lesskey file: On Unix systems, less looks for a lesskey - file called "$HOME/.less". On MS-DOS and Windows systems, less looks - for a lesskey file called "$HOME/_less", and if it is not found there, + variables. If the environment variable LESSKEY is set, less uses that + as the name of the lesskey file. Otherwise, less looks in a standard + place for the lesskey file: On Unix systems, less looks for a lesskey + file called "$HOME/.less". On MS-DOS and Windows systems, less looks + for a lesskey file called "$HOME/_less", and if it is not found there, then looks for a lesskey file called "_less" in any directory specified - in the PATH environment variable. On OS/2 systems, less looks for a - lesskey file called "$HOME/less.ini", and if it is not found, then - looks for a lesskey file called "less.ini" in any directory specified + in the PATH environment variable. On OS/2 systems, less looks for a + lesskey file called "$HOME/less.ini", and if it is not found, then + looks for a lesskey file called "less.ini" in any directory specified in the INIT environment variable, and if it not found there, then looks - for a lesskey file called "less.ini" in any directory specified in the - PATH environment variable. See the lesskey manual page for more + for a lesskey file called "less.ini" in any directory specified in the + PATH environment variable. See the lesskey manual page for more details. - A system-wide lesskey file may also be set up to provide key bindings. + A system-wide lesskey file may also be set up to provide key bindings. If a key is defined in both a local lesskey file and in the system-wide - file, key bindings in the local file take precedence over those in the - system-wide file. If the environment variable LESSKEY_SYSTEM is set, + file, key bindings in the local file take precedence over those in the + system-wide file. If the environment variable LESSKEY_SYSTEM is set, less uses that as the name of the system-wide lesskey file. Otherwise, - less looks in a standard place for the system-wide lesskey file: On - Unix systems, the system-wide lesskey file is /usr/local/etc/sysless. - (However, if less was built with a different sysconf directory than + less looks in a standard place for the system-wide lesskey file: On + Unix systems, the system-wide lesskey file is /usr/local/etc/sysless. + (However, if less was built with a different sysconf directory than /usr/local/etc, that directory is where the sysless file is found.) On - MS-DOS and Windows systems, the system-wide lesskey file is c:\_sys- + MS-DOS and Windows systems, the system-wide lesskey file is c:\_sys- less. On OS/2 systems, the system-wide lesskey file is c:\sysless.ini. INPUT PREPROCESSOR - You may define an "input preprocessor" for less. Before less opens a + You may define an "input preprocessor" for less. Before less opens a file, it first gives your input preprocessor a chance to modify the way - the contents of the file are displayed. An input preprocessor is sim- - ply an executable program (or shell script), which writes the contents + the contents of the file are displayed. An input preprocessor is sim- + ply an executable program (or shell script), which writes the contents of the file to a different file, called the replacement file. The con- - tents of the replacement file are then displayed in place of the con- - tents of the original file. However, it will appear to the user as if - the original file is opened; that is, less will display the original + tents of the replacement file are then displayed in place of the con- + tents of the original file. However, it will appear to the user as if + the original file is opened; that is, less will display the original filename as the name of the current file. - An input preprocessor receives one command line argument, the original - filename, as entered by the user. It should create the replacement - file, and when finished, print the name of the replacement file to its - standard output. If the input preprocessor does not output a replace- - ment filename, less uses the original file, as normal. The input pre- - processor is not called when viewing standard input. To set up an - input preprocessor, set the LESSOPEN environment variable to a command - line which will invoke your input preprocessor. This command line - should include one occurrence of the string "%s", which will be - replaced by the filename when the input preprocessor command is + An input preprocessor receives one command line argument, the original + filename, as entered by the user. It should create the replacement + file, and when finished, print the name of the replacement file to its + standard output. If the input preprocessor does not output a replace- + ment filename, less uses the original file, as normal. The input pre- + processor is not called when viewing standard input. To set up an + input preprocessor, set the LESSOPEN environment variable to a command + line which will invoke your input preprocessor. This command line + should include one occurrence of the string "%s", which will be + replaced by the filename when the input preprocessor command is invoked. When less closes a file opened in such a way, it will call another pro- - gram, called the input postprocessor, which may perform any desired - clean-up action (such as deleting the replacement file created by + gram, called the input postprocessor, which may perform any desired + clean-up action (such as deleting the replacement file created by LESSOPEN). This program receives two command line arguments, the orig- - inal filename as entered by the user, and the name of the replacement - file. To set up an input postprocessor, set the LESSCLOSE environment - variable to a command line which will invoke your input postprocessor. - It may include two occurrences of the string "%s"; the first is - replaced with the original name of the file and the second with the + inal filename as entered by the user, and the name of the replacement + file. To set up an input postprocessor, set the LESSCLOSE environment + variable to a command line which will invoke your input postprocessor. + It may include two occurrences of the string "%s"; the first is + replaced with the original name of the file and the second with the name of the replacement file, which was output by LESSOPEN. - For example, on many Unix systems, these two scripts will allow you to + For example, on many Unix systems, these two scripts will allow you to keep files in compressed format, but still let less view them directly: lessopen.sh: @@ -1038,25 +1048,25 @@ LESS(1) #! /bin/sh rm $2 - To use these scripts, put them both where they can be executed and set + To use these scripts, put them both where they can be executed and set LESSOPEN="lessopen.sh %s", and LESSCLOSE="lessclose.sh %s %s". More - complex LESSOPEN and LESSCLOSE scripts may be written to accept other + complex LESSOPEN and LESSCLOSE scripts may be written to accept other types of compressed files, and so on. - It is also possible to set up an input preprocessor to pipe the file - data directly to less, rather than putting the data into a replacement + It is also possible to set up an input preprocessor to pipe the file + data directly to less, rather than putting the data into a replacement file. This avoids the need to decompress the entire file before start- ing to view it. An input preprocessor that works this way is called an - input pipe. An input pipe, instead of writing the name of a replace- - ment file on its standard output, writes the entire contents of the - replacement file on its standard output. If the input pipe does not - write any characters on its standard output, then there is no replace- - ment file and less uses the original file, as normal. To use an input - pipe, make the first character in the LESSOPEN environment variable a - vertical bar (|) to signify that the input preprocessor is an input + input pipe. An input pipe, instead of writing the name of a replace- + ment file on its standard output, writes the entire contents of the + replacement file on its standard output. If the input pipe does not + write any characters on its standard output, then there is no replace- + ment file and less uses the original file, as normal. To use an input + pipe, make the first character in the LESSOPEN environment variable a + vertical bar (|) to signify that the input preprocessor is an input pipe. - For example, on many Unix systems, this script will work like the pre- + For example, on many Unix systems, this script will work like the pre- vious example scripts: lesspipe.sh: @@ -1071,30 +1081,30 @@ LESS(1) To use this script, put it where it can be executed and set LESSOPEN="|lesspipe.sh %s". - Note that a preprocessor cannot output an empty file, since that is - interpreted as meaning there is no replacement, and the original file + Note that a preprocessor cannot output an empty file, since that is + interpreted as meaning there is no replacement, and the original file is used. To avoid this, if LESSOPEN starts with two vertical bars, the - exit status of the script becomes meaningful. If the exit status is - zero, the output is considered to be replacement text, even if it - empty. If the exit status is nonzero, any output is ignored and the - original file is used. For compatibility with previous versions of + exit status of the script becomes meaningful. If the exit status is + zero, the output is considered to be replacement text, even if it + empty. If the exit status is nonzero, any output is ignored and the + original file is used. For compatibility with previous versions of less, if LESSOPEN starts with only one vertical bar, the exit status of the preprocessor is ignored. - When an input pipe is used, a LESSCLOSE postprocessor can be used, but + When an input pipe is used, a LESSCLOSE postprocessor can be used, but it is usually not necessary since there is no replacement file to clean - up. In this case, the replacement file name passed to the LESSCLOSE + up. In this case, the replacement file name passed to the LESSCLOSE postprocessor is "-". - For compatibility with previous versions of less, the input preproces- + For compatibility with previous versions of less, the input preproces- sor or pipe is not used if less is viewing standard input. However, if - the first character of LESSOPEN is a dash (-), the input preprocessor - is used on standard input as well as other files. In this case, the - dash is not considered to be part of the preprocessor command. If + the first character of LESSOPEN is a dash (-), the input preprocessor + is used on standard input as well as other files. In this case, the + dash is not considered to be part of the preprocessor command. If standard input is being viewed, the input preprocessor is passed a file - name consisting of a single dash. Similarly, if the first two charac- - ters of LESSOPEN are vertical bar and dash (|-) or two vertical bars - and a dash (||-), the input pipe is used on standard input as well as + name consisting of a single dash. Similarly, if the first two charac- + ters of LESSOPEN are vertical bar and dash (|-) or two vertical bars + and a dash (||-), the input pipe is used on standard input as well as other files. Again, in this case the dash is not considered to be part of the input pipe command. @@ -1106,25 +1116,25 @@ LESS(1) can be displayed directly to the screen. control characters - should not be displayed directly, but are expected to be found + should not be displayed directly, but are expected to be found in ordinary text files (such as backspace and tab). binary characters - should not be displayed directly and are not expected to be + should not be displayed directly and are not expected to be *** DIFF OUTPUT TRUNCATED AT 1000 LINES *** From owner-svn-src-all@FreeBSD.ORG Mon May 13 05:28:27 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id A2C191F2; Mon, 13 May 2013 05:28:27 +0000 (UTC) (envelope-from delphij@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id 7C46E6CD; Mon, 13 May 2013 05:28:27 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.6/8.14.6) with ESMTP id r4D5SRwE053399; Mon, 13 May 2013 05:28:27 GMT (envelope-from delphij@svn.freebsd.org) Received: (from delphij@localhost) by svn.freebsd.org (8.14.6/8.14.5/Submit) id r4D5SRMZ053398; Mon, 13 May 2013 05:28:27 GMT (envelope-from delphij@svn.freebsd.org) Message-Id: <201305130528.r4D5SRMZ053398@svn.freebsd.org> From: Xin LI Date: Mon, 13 May 2013 05:28:27 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-vendor@freebsd.org Subject: svn commit: r250591 - vendor/less/v458 X-SVN-Group: vendor MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 13 May 2013 05:28:27 -0000 Author: delphij Date: Mon May 13 05:28:27 2013 New Revision: 250591 URL: http://svnweb.freebsd.org/changeset/base/250591 Log: Tag less v458. Added: vendor/less/v458/ - copied from r250590, vendor/less/dist/ From owner-svn-src-all@FreeBSD.ORG Mon May 13 06:52:48 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id 91E07F51; Mon, 13 May 2013 06:52:48 +0000 (UTC) (envelope-from delphij@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id 83BA1992; Mon, 13 May 2013 06:52:48 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.6/8.14.6) with ESMTP id r4D6qmh2083315; Mon, 13 May 2013 06:52:48 GMT (envelope-from delphij@svn.freebsd.org) Received: (from delphij@localhost) by svn.freebsd.org (8.14.6/8.14.5/Submit) id r4D6qlhG083304; Mon, 13 May 2013 06:52:47 GMT (envelope-from delphij@svn.freebsd.org) Message-Id: <201305130652.r4D6qlhG083304@svn.freebsd.org> From: Xin LI Date: Mon, 13 May 2013 06:52:47 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r250592 - head/contrib/less X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 13 May 2013 06:52:48 -0000 Author: delphij Date: Mon May 13 06:52:46 2013 New Revision: 250592 URL: http://svnweb.freebsd.org/changeset/base/250592 Log: MFV: less v458. MFC after: 2 weeks Modified: head/contrib/less/NEWS head/contrib/less/README head/contrib/less/cmdbuf.c head/contrib/less/help.c head/contrib/less/less.hlp head/contrib/less/less.man head/contrib/less/less.nro head/contrib/less/lessecho.man head/contrib/less/lessecho.nro head/contrib/less/lesskey.man head/contrib/less/lesskey.nro head/contrib/less/option.c head/contrib/less/opttbl.c head/contrib/less/version.c Directory Properties: head/contrib/less/ (props changed) Modified: head/contrib/less/NEWS ============================================================================== --- head/contrib/less/NEWS Mon May 13 05:28:27 2013 (r250591) +++ head/contrib/less/NEWS Mon May 13 06:52:46 2013 (r250592) @@ -11,9 +11,10 @@ ====================================================================== - Major changes between "less" versions 451 and 456 + Major changes between "less" versions 451 and 458 -* Allow backslash escaping of metacharacters in LESS environment variable. +* Allow backslash escaping of metacharacters in LESS environment variable + after the --use-backslash option. * Don't quit if syntax errors are found in command line options. @@ -25,6 +26,8 @@ * Fix Win32 attribute display bug. +* Fix display bug when using up/down arrow on the command line. + ====================================================================== Major changes between "less" versions 444 and 451 Modified: head/contrib/less/README ============================================================================== --- head/contrib/less/README Mon May 13 05:28:27 2013 (r250591) +++ head/contrib/less/README Mon May 13 06:52:46 2013 (r250592) @@ -7,9 +7,9 @@ ************************************************************************** ************************************************************************** - Less, version 456 + Less, version 458 - This is the distribution of less, version 456, released 08 Nov 2012. + This is the distribution of less, version 458, released 04 Apr 2013. This program is part of the GNU project (http://www.gnu.org). This program is free software. You may redistribute it and/or Modified: head/contrib/less/cmdbuf.c ============================================================================== --- head/contrib/less/cmdbuf.c Mon May 13 05:28:27 2013 (r250591) +++ head/contrib/less/cmdbuf.c Mon May 13 06:52:46 2013 (r250592) @@ -727,9 +727,9 @@ cmd_updown(action) s = ml->string; if (s == NULL) s = ""; - strcpy(cmdbuf, s); cmd_home(); clear_eol(); + strcpy(cmdbuf, s); for (cp = cmdbuf; *cp != '\0'; ) cmd_right(); return (CC_OK); Modified: head/contrib/less/help.c ============================================================================== --- head/contrib/less/help.c Mon May 13 05:28:27 2013 (r250591) +++ head/contrib/less/help.c Mon May 13 06:52:46 2013 (r250592) @@ -110,7 +110,7 @@ constant char helpdata[] = { ' ',' ',' ',' ',' ',' ',' ',' ','M','o','s','t',' ','o','p','t','i','o','n','s',' ','m','a','y',' ','b','e',' ','c','h','a','n','g','e','d',' ','e','i','t','h','e','r',' ','o','n',' ','t','h','e',' ','c','o','m','m','a','n','d',' ','l','i','n','e',',','\n', ' ',' ',' ',' ',' ',' ',' ',' ','o','r',' ','f','r','o','m',' ','w','i','t','h','i','n',' ','l','e','s','s',' ','b','y',' ','u','s','i','n','g',' ','t','h','e',' ','-',' ','o','r',' ','-','-',' ','c','o','m','m','a','n','d','.','\n', ' ',' ',' ',' ',' ',' ',' ',' ','O','p','t','i','o','n','s',' ','m','a','y',' ','b','e',' ','g','i','v','e','n',' ','i','n',' ','o','n','e',' ','o','f',' ','t','w','o',' ','f','o','r','m','s',':',' ','e','i','t','h','e','r',' ','a',' ','s','i','n','g','l','e','\n', -' ',' ',' ',' ',' ',' ',' ',' ','c','h','a','r','a','c','t','e','r',' ','p','r','e','c','e','d','e','d',' ','b','y',' ','a',' ','-',',',' ','o','r',' ','a',' ','n','a','m','e',' ','p','r','e','c','e','e','d','e','d',' ','b','y',' ','-','-','.','\n', +' ',' ',' ',' ',' ',' ',' ',' ','c','h','a','r','a','c','t','e','r',' ','p','r','e','c','e','d','e','d',' ','b','y',' ','a',' ','-',',',' ','o','r',' ','a',' ','n','a','m','e',' ','p','r','e','c','e','d','e','d',' ','b','y',' ','-','-','.','\n', '\n', ' ',' ','-','?',' ',' ','.','.','.','.','.','.','.','.',' ',' ','-','-','h','e','l','p','\n', ' ',' ',' ',' ',' ',' ',' ',' ',' ',' ',' ',' ',' ',' ',' ',' ',' ',' ','D','i','s','p','l','a','y',' ','h','e','l','p',' ','(','f','r','o','m',' ','c','o','m','m','a','n','d',' ','l','i','n','e',')','.','\n', Modified: head/contrib/less/less.hlp ============================================================================== --- head/contrib/less/less.hlp Mon May 13 05:28:27 2013 (r250591) +++ head/contrib/less/less.hlp Mon May 13 06:52:46 2013 (r250592) @@ -107,7 +107,7 @@ Most options may be changed either on the command line, or from within less by using the - or -- command. Options may be given in one of two forms: either a single - character preceded by a -, or a name preceeded by --. + character preceded by a -, or a name preceded by --. -? ........ --help Display help (from command line). Modified: head/contrib/less/less.man ============================================================================== --- head/contrib/less/less.man Mon May 13 05:28:27 2013 (r250591) +++ head/contrib/less/less.man Mon May 13 06:52:46 2013 (r250592) @@ -444,58 +444,61 @@ LESS(1) LESS="Dn9.1$Ds4.1" - A dollar sign or backslash may be included literally in an option - string by preceding it with a backslash. + If the --use-backslash option appears earlier in the options, then a + dollar sign or backslash may be included literally in an option string + by preceding it with a backslash. If the --use-backslash option is not + in effect, then backslashes are not treated specially, and there is no + way to include a dollar sign in the option string. -? or --help - This option displays a summary of the commands accepted by less - (the same as the h command). (Depending on how your shell - interprets the question mark, it may be necessary to quote the + This option displays a summary of the commands accepted by less + (the same as the h command). (Depending on how your shell + interprets the question mark, it may be necessary to quote the question mark, thus: "-\?".) -a or --search-skip-screen - By default, forward searches start at the top of the displayed - screen and backwards searches start at the bottom of the dis- - played screen (except for repeated searches invoked by the n or - N commands, which start after or before the "target" line + By default, forward searches start at the top of the displayed + screen and backwards searches start at the bottom of the dis- + played screen (except for repeated searches invoked by the n or + N commands, which start after or before the "target" line respectively; see the -j option for more about the target line). - The -a option causes forward searches to instead start at the - bottom of the screen and backward searches to start at the top + The -a option causes forward searches to instead start at the + bottom of the screen and backward searches to start at the top of the screen, thus skipping all lines displayed on the screen. -A or --SEARCH-SKIP-SCREEN - Causes all forward searches (not just non-repeated searches) to - start just after the target line, and all backward searches to - start just before the target line. Thus, forward searches will + Causes all forward searches (not just non-repeated searches) to + start just after the target line, and all backward searches to + start just before the target line. Thus, forward searches will skip part of the displayed screen (from the first line up to and - including the target line). Similarly backwards searches will + including the target line). Similarly backwards searches will skip the displayed screen from the last line up to and including the target line. This was the default behavior in less versions prior to 441. -bn or --buffers=n - Specifies the amount of buffer space less will use for each - file, in units of kilobytes (1024 bytes). By default 64K of - buffer space is used for each file (unless the file is a pipe; - see the -B option). The -b option specifies instead that n + Specifies the amount of buffer space less will use for each + file, in units of kilobytes (1024 bytes). By default 64K of + buffer space is used for each file (unless the file is a pipe; + see the -B option). The -b option specifies instead that n kilobytes of buffer space should be used for each file. If n is - -1, buffer space is unlimited; that is, the entire file can be + -1, buffer space is unlimited; that is, the entire file can be read into memory. -B or --auto-buffers By default, when data is read from a pipe, buffers are allocated automatically as needed. If a large amount of data is read from - the pipe, this can cause a large amount of memory to be allo- + the pipe, this can cause a large amount of memory to be allo- cated. The -B option disables this automatic allocation of buf- - fers for pipes, so that only 64K (or the amount of space speci- + fers for pipes, so that only 64K (or the amount of space speci- fied by the -b option) is used for the pipe. Warning: use of -B - can result in erroneous display, since only the most recently - viewed part of the piped data is kept in memory; any earlier + can result in erroneous display, since only the most recently + viewed part of the piped data is kept in memory; any earlier data is lost. -c or --clear-screen - Causes full screen repaints to be painted from the top line - down. By default, full screen repaints are done by scrolling + Causes full screen repaints to be painted from the top line + down. By default, full screen repaints are done by scrolling from the bottom of the screen. -C or --CLEAR-SCREEN @@ -503,24 +506,24 @@ LESS(1) -d or --dumb The -d option suppresses the error message normally displayed if - the terminal is dumb; that is, lacks some important capability, + the terminal is dumb; that is, lacks some important capability, such as the ability to clear the screen or scroll backward. The - -d option does not otherwise change the behavior of less on a + -d option does not otherwise change the behavior of less on a dumb terminal. -Dxcolor or --color=xcolor [MS-DOS only] Sets the color of the text displayed. x is a sin- - gle character which selects the type of text whose color is - being set: n=normal, s=standout, d=bold, u=underlined, k=blink. - color is a pair of numbers separated by a period. The first - number selects the foreground color and the second selects the - background color of the text. A single number N is the same as + gle character which selects the type of text whose color is + being set: n=normal, s=standout, d=bold, u=underlined, k=blink. + color is a pair of numbers separated by a period. The first + number selects the foreground color and the second selects the + background color of the text. A single number N is the same as N.M, where M is the normal background color. -e or --quit-at-eof - Causes less to automatically exit the second time it reaches - end-of-file. By default, the only way to exit less is via the + Causes less to automatically exit the second time it reaches + end-of-file. By default, the only way to exit less is via the "q" command. -E or --QUIT-AT-EOF @@ -529,7 +532,7 @@ LESS(1) -f or --force Forces non-regular files to be opened. (A non-regular file is a - directory or a device special file.) Also suppresses the warn- + directory or a device special file.) Also suppresses the warn- ing message when a binary file is opened. By default, less will refuse to open non-regular files. Note that some operating sys- tems will not allow directories to be read, even if -f is set. @@ -539,236 +542,236 @@ LESS(1) played on the first screen. -g or --hilite-search - Normally, less will highlight ALL strings which match the last - search command. The -g option changes this behavior to high- - light only the particular string which was found by the last + Normally, less will highlight ALL strings which match the last + search command. The -g option changes this behavior to high- + light only the particular string which was found by the last search command. This can cause less to run somewhat faster than the default. -G or --HILITE-SEARCH - The -G option suppresses all highlighting of strings found by + The -G option suppresses all highlighting of strings found by search commands. -hn or --max-back-scroll=n - Specifies a maximum number of lines to scroll backward. If it + Specifies a maximum number of lines to scroll backward. If it is necessary to scroll backward more than n lines, the screen is repainted in a forward direction instead. (If the terminal does not have the ability to scroll backward, -h0 is implied.) -i or --ignore-case Causes searches to ignore case; that is, uppercase and lowercase - are considered identical. This option is ignored if any upper- - case letters appear in the search pattern; in other words, if a - pattern contains uppercase letters, then that search does not + are considered identical. This option is ignored if any upper- + case letters appear in the search pattern; in other words, if a + pattern contains uppercase letters, then that search does not ignore case. -I or --IGNORE-CASE - Like -i, but searches ignore case even if the pattern contains + Like -i, but searches ignore case even if the pattern contains uppercase letters. -jn or --jump-target=n - Specifies a line on the screen where the "target" line is to be - positioned. The target line is the line specified by any com- - mand to search for a pattern, jump to a line number, jump to a + Specifies a line on the screen where the "target" line is to be + positioned. The target line is the line specified by any com- + mand to search for a pattern, jump to a line number, jump to a file percentage or jump to a tag. The screen line may be speci- - fied by a number: the top line on the screen is 1, the next is + fied by a number: the top line on the screen is 1, the next is 2, and so on. The number may be negative to specify a line rel- ative to the bottom of the screen: the bottom line on the screen - is -1, the second to the bottom is -2, and so on. Alternately, - the screen line may be specified as a fraction of the height of - the screen, starting with a decimal point: .5 is in the middle - of the screen, .3 is three tenths down from the first line, and - so on. If the line is specified as a fraction, the actual line - number is recalculated if the terminal window is resized, so - that the target line remains at the specified fraction of the - screen height. If any form of the -j option is used, forward - searches begin at the line immediately after the target line, - and backward searches begin at the target line, unless changed - by -a or -A. For example, if "-j4" is used, the target line is - the fourth line on the screen, so forward searches begin at the + is -1, the second to the bottom is -2, and so on. Alternately, + the screen line may be specified as a fraction of the height of + the screen, starting with a decimal point: .5 is in the middle + of the screen, .3 is three tenths down from the first line, and + so on. If the line is specified as a fraction, the actual line + number is recalculated if the terminal window is resized, so + that the target line remains at the specified fraction of the + screen height. If any form of the -j option is used, forward + searches begin at the line immediately after the target line, + and backward searches begin at the target line, unless changed + by -a or -A. For example, if "-j4" is used, the target line is + the fourth line on the screen, so forward searches begin at the fifth line on the screen. -J or --status-column - Displays a status column at the left edge of the screen. The - status column shows the lines that matched the current search. - The status column is also used if the -w or -W option is in + Displays a status column at the left edge of the screen. The + status column shows the lines that matched the current search. + The status column is also used if the -w or -W option is in effect. -kfilename or --lesskey-file=filename - Causes less to open and interpret the named file as a lesskey + Causes less to open and interpret the named file as a lesskey (1) file. Multiple -k options may be specified. If the LESSKEY - or LESSKEY_SYSTEM environment variable is set, or if a lesskey + or LESSKEY_SYSTEM environment variable is set, or if a lesskey file is found in a standard place (see KEY BINDINGS), it is also used as a lesskey file. -K or --quit-on-intr - Causes less to exit immediately (with status 2) when an inter- - rupt character (usually ^C) is typed. Normally, an interrupt + Causes less to exit immediately (with status 2) when an inter- + rupt character (usually ^C) is typed. Normally, an interrupt character causes less to stop whatever it is doing and return to - its command prompt. Note that use of this option makes it + its command prompt. Note that use of this option makes it impossible to return to the command prompt from the "F" command. -L or --no-lessopen - Ignore the LESSOPEN environment variable (see the INPUT PRE- - PROCESSOR section below). This option can be set from within - less, but it will apply only to files opened subsequently, not + Ignore the LESSOPEN environment variable (see the INPUT PRE- + PROCESSOR section below). This option can be set from within + less, but it will apply only to files opened subsequently, not to the file which is currently open. -m or --long-prompt - Causes less to prompt verbosely (like more), with the percent + Causes less to prompt verbosely (like more), with the percent into the file. By default, less prompts with a colon. -M or --LONG-PROMPT Causes less to prompt even more verbosely than more. -n or --line-numbers - Suppresses line numbers. The default (to use line numbers) may - cause less to run more slowly in some cases, especially with a - very large input file. Suppressing line numbers with the -n - option will avoid this problem. Using line numbers means: the + Suppresses line numbers. The default (to use line numbers) may + cause less to run more slowly in some cases, especially with a + very large input file. Suppressing line numbers with the -n + option will avoid this problem. Using line numbers means: the line number will be displayed in the verbose prompt and in the = - command, and the v command will pass the current line number to - the editor (see also the discussion of LESSEDIT in PROMPTS + command, and the v command will pass the current line number to + the editor (see also the discussion of LESSEDIT in PROMPTS below). -N or --LINE-NUMBERS - Causes a line number to be displayed at the beginning of each + Causes a line number to be displayed at the beginning of each line in the display. -ofilename or --log-file=filename - Causes less to copy its input to the named file as it is being + Causes less to copy its input to the named file as it is being viewed. This applies only when the input file is a pipe, not an - ordinary file. If the file already exists, less will ask for + ordinary file. If the file already exists, less will ask for confirmation before overwriting it. -Ofilename or --LOG-FILE=filename The -O option is like -o, but it will overwrite an existing file without asking for confirmation. - If no log file has been specified, the -o and -O options can be - used from within less to specify a log file. Without a file + If no log file has been specified, the -o and -O options can be + used from within less to specify a log file. Without a file name, they will simply report the name of the log file. The "s" command is equivalent to specifying -o from within less. -ppattern or --pattern=pattern - The -p option on the command line is equivalent to specifying - +/pattern; that is, it tells less to start at the first occur- + The -p option on the command line is equivalent to specifying + +/pattern; that is, it tells less to start at the first occur- rence of pattern in the file. -Pprompt or --prompt=prompt - Provides a way to tailor the three prompt styles to your own + Provides a way to tailor the three prompt styles to your own preference. This option would normally be put in the LESS envi- ronment variable, rather than being typed in with each less com- mand. Such an option must either be the last option in the LESS - variable, or be terminated by a dollar sign. -Ps followed by a - string changes the default (short) prompt to that string. -Pm - changes the medium (-m) prompt. -PM changes the long (-M) - prompt. -Ph changes the prompt for the help screen. -P= - changes the message printed by the = command. -Pw changes the - message printed while waiting for data (in the F command). All - prompt strings consist of a sequence of letters and special + variable, or be terminated by a dollar sign. -Ps followed by a + string changes the default (short) prompt to that string. -Pm + changes the medium (-m) prompt. -PM changes the long (-M) + prompt. -Ph changes the prompt for the help screen. -P= + changes the message printed by the = command. -Pw changes the + message printed while waiting for data (in the F command). All + prompt strings consist of a sequence of letters and special escape sequences. See the section on PROMPTS for more details. -q or --quiet or --silent - Causes moderately "quiet" operation: the terminal bell is not + Causes moderately "quiet" operation: the terminal bell is not rung if an attempt is made to scroll past the end of the file or before the beginning of the file. If the terminal has a "visual - bell", it is used instead. The bell will be rung on certain - other errors, such as typing an invalid character. The default + bell", it is used instead. The bell will be rung on certain + other errors, such as typing an invalid character. The default is to ring the terminal bell in all such cases. -Q or --QUIET or --SILENT - Causes totally "quiet" operation: the terminal bell is never + Causes totally "quiet" operation: the terminal bell is never rung. -r or --raw-control-chars Causes "raw" control characters to be displayed. The default is - to display control characters using the caret notation; for + to display control characters using the caret notation; for example, a control-A (octal 001) is displayed as "^A". Warning: when the -r option is used, less cannot keep track of the actual - appearance of the screen (since this depends on how the screen + appearance of the screen (since this depends on how the screen responds to each type of control character). Thus, various dis- - play problems may result, such as long lines being split in the + play problems may result, such as long lines being split in the wrong place. -R or --RAW-CONTROL-CHARS - Like -r, but only ANSI "color" escape sequences are output in + Like -r, but only ANSI "color" escape sequences are output in "raw" form. Unlike -r, the screen appearance is maintained cor- rectly in most cases. ANSI "color" escape sequences are sequences of the form: ESC [ ... m - where the "..." is zero or more color specification characters - For the purpose of keeping track of screen appearance, ANSI - color escape sequences are assumed to not move the cursor. You - can make less think that characters other than "m" can end ANSI - color escape sequences by setting the environment variable + where the "..." is zero or more color specification characters + For the purpose of keeping track of screen appearance, ANSI + color escape sequences are assumed to not move the cursor. You + can make less think that characters other than "m" can end ANSI + color escape sequences by setting the environment variable LESSANSIENDCHARS to the list of characters which can end a color - escape sequence. And you can make less think that characters - other than the standard ones may appear between the ESC and the - m by setting the environment variable LESSANSIMIDCHARS to the + escape sequence. And you can make less think that characters + other than the standard ones may appear between the ESC and the + m by setting the environment variable LESSANSIMIDCHARS to the list of characters which can appear. -s or --squeeze-blank-lines - Causes consecutive blank lines to be squeezed into a single + Causes consecutive blank lines to be squeezed into a single blank line. This is useful when viewing nroff output. -S or --chop-long-lines - Causes lines longer than the screen width to be chopped (trun- + Causes lines longer than the screen width to be chopped (trun- cated) rather than wrapped. That is, the portion of a long line that does not fit in the screen width is not shown. The default - is to wrap long lines; that is, display the remainder on the + is to wrap long lines; that is, display the remainder on the next line. -ttag or --tag=tag The -t option, followed immediately by a TAG, will edit the file - containing that tag. For this to work, tag information must be - available; for example, there may be a file in the current + containing that tag. For this to work, tag information must be + available; for example, there may be a file in the current directory called "tags", which was previously built by ctags (1) or an equivalent command. If the environment variable LESSGLOB- - ALTAGS is set, it is taken to be the name of a command compati- - ble with global (1), and that command is executed to find the + ALTAGS is set, it is taken to be the name of a command compati- + ble with global (1), and that command is executed to find the tag. (See http://www.gnu.org/software/global/global.html). The - -t option may also be specified from within less (using the - - command) as a way of examining a new file. The command ":t" is + -t option may also be specified from within less (using the - + command) as a way of examining a new file. The command ":t" is equivalent to specifying -t from within less. -Ttagsfile or --tag-file=tagsfile Specifies a tags file to be used instead of "tags". -u or --underline-special - Causes backspaces and carriage returns to be treated as print- - able characters; that is, they are sent to the terminal when + Causes backspaces and carriage returns to be treated as print- + able characters; that is, they are sent to the terminal when they appear in the input. -U or --UNDERLINE-SPECIAL - Causes backspaces, tabs and carriage returns to be treated as - control characters; that is, they are handled as specified by + Causes backspaces, tabs and carriage returns to be treated as + control characters; that is, they are handled as specified by the -r option. - By default, if neither -u nor -U is given, backspaces which - appear adjacent to an underscore character are treated spe- - cially: the underlined text is displayed using the terminal's - hardware underlining capability. Also, backspaces which appear - between two identical characters are treated specially: the - overstruck text is printed using the terminal's hardware bold- - face capability. Other backspaces are deleted, along with the + By default, if neither -u nor -U is given, backspaces which + appear adjacent to an underscore character are treated spe- + cially: the underlined text is displayed using the terminal's + hardware underlining capability. Also, backspaces which appear + between two identical characters are treated specially: the + overstruck text is printed using the terminal's hardware bold- + face capability. Other backspaces are deleted, along with the preceding character. Carriage returns immediately followed by a - newline are deleted. Other carriage returns are handled as - specified by the -r option. Text which is overstruck or under- + newline are deleted. Other carriage returns are handled as + specified by the -r option. Text which is overstruck or under- lined can be searched for if neither -u nor -U is in effect. -V or --version Displays the version number of less. -w or --hilite-unread - Temporarily highlights the first "new" line after a forward + Temporarily highlights the first "new" line after a forward movement of a full page. The first "new" line is the line imme- - diately following the line previously at the bottom of the + diately following the line previously at the bottom of the screen. Also highlights the target line after a g or p command. - The highlight is removed at the next command which causes move- - ment. The entire line is highlighted, unless the -J option is + The highlight is removed at the next command which causes move- + ment. The entire line is highlighted, unless the -J option is in effect, in which case only the status column is highlighted. -W or --HILITE-UNREAD @@ -776,48 +779,48 @@ LESS(1) forward movement command larger than one line. -xn,... or --tabs=n,... - Sets tab stops. If only one n is specified, tab stops are set - at multiples of n. If multiple values separated by commas are - specified, tab stops are set at those positions, and then con- - tinue with the same spacing as the last two. For example, - -x9,17 will set tabs at positions 9, 17, 25, 33, etc. The + Sets tab stops. If only one n is specified, tab stops are set + at multiples of n. If multiple values separated by commas are + specified, tab stops are set at those positions, and then con- + tinue with the same spacing as the last two. For example, + -x9,17 will set tabs at positions 9, 17, 25, 33, etc. The default for n is 8. -X or --no-init Disables sending the termcap initialization and deinitialization - strings to the terminal. This is sometimes desirable if the - deinitialization string does something unnecessary, like clear- + strings to the terminal. This is sometimes desirable if the + deinitialization string does something unnecessary, like clear- ing the screen. -yn or --max-forw-scroll=n Specifies a maximum number of lines to scroll forward. If it is - necessary to scroll forward more than n lines, the screen is - repainted instead. The -c or -C option may be used to repaint - from the top of the screen if desired. By default, any forward + necessary to scroll forward more than n lines, the screen is + repainted instead. The -c or -C option may be used to repaint + from the top of the screen if desired. By default, any forward movement causes scrolling. -[z]n or --window=n - Changes the default scrolling window size to n lines. The + Changes the default scrolling window size to n lines. The default is one screenful. The z and w commands can also be used - to change the window size. The "z" may be omitted for compati- + to change the window size. The "z" may be omitted for compati- bility with some versions of more. If the number n is negative, - it indicates n lines less than the current screen size. For + it indicates n lines less than the current screen size. For example, if the screen is 24 lines, -z-4 sets the scrolling win- - dow to 20 lines. If the screen is resized to 40 lines, the + dow to 20 lines. If the screen is resized to 40 lines, the scrolling window automatically changes to 36 lines. -"cc or --quotes=cc - Changes the filename quoting character. This may be necessary - if you are trying to name a file which contains both spaces and - quote characters. Followed by a single character, this changes - the quote character to that character. Filenames containing a + Changes the filename quoting character. This may be necessary + if you are trying to name a file which contains both spaces and + quote characters. Followed by a single character, this changes + the quote character to that character. Filenames containing a space should then be surrounded by that character rather than by - double quotes. Followed by two characters, changes the open - quote to the first character, and the close quote to the second + double quotes. Followed by two characters, changes the open + quote to the first character, and the close quote to the second character. Filenames containing a space should then be preceded - by the open quote character and followed by the close quote - character. Note that even after the quote characters are - changed, this option remains -" (a dash followed by a double + by the open quote character and followed by the close quote + character. Note that even after the quote characters are + changed, this option remains -" (a dash followed by a double quote). -~ or --tilde @@ -827,60 +830,67 @@ LESS(1) -# or --shift Specifies the default number of positions to scroll horizontally - in the RIGHTARROW and LEFTARROW commands. If the number speci- - fied is zero, it sets the default number of positions to one + in the RIGHTARROW and LEFTARROW commands. If the number speci- + fied is zero, it sets the default number of positions to one half of the screen width. Alternately, the number may be speci- - fied as a fraction of the width of the screen, starting with a - decimal point: .5 is half of the screen width, .3 is three - tenths of the screen width, and so on. If the number is speci- - fied as a fraction, the actual number of scroll positions is - recalculated if the terminal window is resized, so that the - actual scroll remains at the specified fraction of the screen + fied as a fraction of the width of the screen, starting with a + decimal point: .5 is half of the screen width, .3 is three + tenths of the screen width, and so on. If the number is speci- + fied as a fraction, the actual number of scroll positions is + recalculated if the terminal window is resized, so that the + actual scroll remains at the specified fraction of the screen width. + --follow-name + Normally, if the input file is renamed while an F command is + executing, less will continue to display the contents of the + original file despite its name change. If --follow-name is + specified, during an F command less will periodically attempt to + reopen the file by name. If the reopen succeeds and the file is + a different file from the original (which means that a new file + has been created with the same name as the original (now + renamed) file), less will display the contents of that new file. + --no-keypad Disables sending the keypad initialization and deinitialization strings to the terminal. This is sometimes useful if the keypad strings make the numeric keypad behave in an undesirable manner. - --follow-name - Normally, if the input file is renamed while an F command is - executing, less will continue to display the contents of the - original file despite its name change. If --follow-name is - specified, during an F command less will periodically attempt to - reopen the file by name. If the reopen succeeds and the file is - a different file from the original (which means that a new file - has been created with the same name as the original (now - renamed) file), less will display the contents of that new file. + --use-backslash + This option changes the interpretations of options which follow + this one. After the --use-backslash option, any backslash in an + option string is removed and the following character is taken + literally. This allows a dollar sign to be included in option + strings. - -- A command line argument of "--" marks the end of option argu- - ments. Any arguments following this are interpreted as file- + -- A command line argument of "--" marks the end of option argu- + ments. Any arguments following this are interpreted as file- names. This can be useful when viewing a file whose name begins with a "-" or "+". - + If a command line option begins with +, the remainder of that - option is taken to be an initial command to less. For example, - +G tells less to start at the end of the file rather than the - beginning, and +/xyz tells it to start at the first occurrence - of "xyz" in the file. As a special case, + acts like + + If a command line option begins with +, the remainder of that + option is taken to be an initial command to less. For example, + +G tells less to start at the end of the file rather than the + beginning, and +/xyz tells it to start at the first occurrence + of "xyz" in the file. As a special case, + acts like +g; that is, it starts the display at the specified line - number (however, see the caveat under the "g" command above). - If the option starts with ++, the initial command applies to - every file being viewed, not just the first one. The + command + number (however, see the caveat under the "g" command above). + If the option starts with ++, the initial command applies to + every file being viewed, not just the first one. The + command described previously may also be used to set (or change) an ini- tial command for every file. LINE EDITING - When entering command line at the bottom of the screen (for example, a + When entering command line at the bottom of the screen (for example, a filename for the :e command, or the pattern for a search command), cer- - tain keys can be used to manipulate the command line. Most commands - have an alternate form in [ brackets ] which can be used if a key does - not exist on a particular keyboard. (Note that the forms beginning - with ESC do not work in some MS-DOS and Windows systems because ESC is - the line erase character.) Any of these special keys may be entered - literally by preceding it with the "literal" character, either ^V or - ^A. A backslash itself may also be entered literally by entering two + tain keys can be used to manipulate the command line. Most commands + have an alternate form in [ brackets ] which can be used if a key does + not exist on a particular keyboard. (Note that the forms beginning + with ESC do not work in some MS-DOS and Windows systems because ESC is + the line erase character.) Any of these special keys may be entered + literally by preceding it with the "literal" character, either ^V or + ^A. A backslash itself may also be entered literally by entering two backslashes. LEFTARROW [ ESC-h ] @@ -890,7 +900,7 @@ LESS(1) Move the cursor one space to the right. ^LEFTARROW [ ESC-b or ESC-LEFTARROW ] - (That is, CONTROL and LEFTARROW simultaneously.) Move the cur- + (That is, CONTROL and LEFTARROW simultaneously.) Move the cur- sor one word to the left. ^RIGHTARROW [ ESC-w or ESC-RIGHTARROW ] @@ -904,48 +914,48 @@ LESS(1) Move the cursor to the end of the line. BACKSPACE - Delete the character to the left of the cursor, or cancel the + Delete the character to the left of the cursor, or cancel the command if the command line is empty. DELETE or [ ESC-x ] Delete the character under the cursor. ^BACKSPACE [ ESC-BACKSPACE ] - (That is, CONTROL and BACKSPACE simultaneously.) Delete the + (That is, CONTROL and BACKSPACE simultaneously.) Delete the word to the left of the cursor. ^DELETE [ ESC-X or ESC-DELETE ] - (That is, CONTROL and DELETE simultaneously.) Delete the word + (That is, CONTROL and DELETE simultaneously.) Delete the word under the cursor. UPARROW [ ESC-k ] - Retrieve the previous command line. If you first enter some - text and then press UPARROW, it will retrieve the previous com- + Retrieve the previous command line. If you first enter some + text and then press UPARROW, it will retrieve the previous com- mand which begins with that text. DOWNARROW [ ESC-j ] - Retrieve the next command line. If you first enter some text - and then press DOWNARROW, it will retrieve the next command + Retrieve the next command line. If you first enter some text + and then press DOWNARROW, it will retrieve the next command which begins with that text. - TAB Complete the partial filename to the left of the cursor. If it - matches more than one filename, the first match is entered into - the command line. Repeated TABs will cycle thru the other + TAB Complete the partial filename to the left of the cursor. If it + matches more than one filename, the first match is entered into + the command line. Repeated TABs will cycle thru the other matching filenames. If the completed filename is a directory, a - "/" is appended to the filename. (On MS-DOS systems, a "\" is - appended.) The environment variable LESSSEPARATOR can be used + "/" is appended to the filename. (On MS-DOS systems, a "\" is + appended.) The environment variable LESSSEPARATOR can be used to specify a different character to append to a directory name. BACKTAB [ ESC-TAB ] Like, TAB, but cycles in the reverse direction thru the matching filenames. - ^L Complete the partial filename to the left of the cursor. If it + ^L Complete the partial filename to the left of the cursor. If it matches more than one filename, all matches are entered into the command line (if they fit). ^U (Unix and OS/2) or ESC (MS-DOS) - Delete the entire command line, or cancel the command if the + Delete the entire command line, or cancel the command if the command line is empty. If you have changed your line-kill char- acter in Unix to something other than ^U, that character is used instead of ^U. @@ -954,72 +964,72 @@ LESS(1) KEY BINDINGS - You may define your own less commands by using the program lesskey (1) - to create a lesskey file. This file specifies a set of command keys - and an action associated with each key. You may also use lesskey to + You may define your own less commands by using the program lesskey (1) + to create a lesskey file. This file specifies a set of command keys + and an action associated with each key. You may also use lesskey to change the line-editing keys (see LINE EDITING), and to set environment - variables. If the environment variable LESSKEY is set, less uses that - as the name of the lesskey file. Otherwise, less looks in a standard - place for the lesskey file: On Unix systems, less looks for a lesskey - file called "$HOME/.less". On MS-DOS and Windows systems, less looks - for a lesskey file called "$HOME/_less", and if it is not found there, + variables. If the environment variable LESSKEY is set, less uses that + as the name of the lesskey file. Otherwise, less looks in a standard + place for the lesskey file: On Unix systems, less looks for a lesskey + file called "$HOME/.less". On MS-DOS and Windows systems, less looks + for a lesskey file called "$HOME/_less", and if it is not found there, then looks for a lesskey file called "_less" in any directory specified - in the PATH environment variable. On OS/2 systems, less looks for a - lesskey file called "$HOME/less.ini", and if it is not found, then - looks for a lesskey file called "less.ini" in any directory specified + in the PATH environment variable. On OS/2 systems, less looks for a + lesskey file called "$HOME/less.ini", and if it is not found, then + looks for a lesskey file called "less.ini" in any directory specified in the INIT environment variable, and if it not found there, then looks - for a lesskey file called "less.ini" in any directory specified in the - PATH environment variable. See the lesskey manual page for more + for a lesskey file called "less.ini" in any directory specified in the + PATH environment variable. See the lesskey manual page for more details. - A system-wide lesskey file may also be set up to provide key bindings. + A system-wide lesskey file may also be set up to provide key bindings. If a key is defined in both a local lesskey file and in the system-wide - file, key bindings in the local file take precedence over those in the - system-wide file. If the environment variable LESSKEY_SYSTEM is set, + file, key bindings in the local file take precedence over those in the + system-wide file. If the environment variable LESSKEY_SYSTEM is set, less uses that as the name of the system-wide lesskey file. Otherwise, - less looks in a standard place for the system-wide lesskey file: On - Unix systems, the system-wide lesskey file is /usr/local/etc/sysless. - (However, if less was built with a different sysconf directory than + less looks in a standard place for the system-wide lesskey file: On + Unix systems, the system-wide lesskey file is /usr/local/etc/sysless. + (However, if less was built with a different sysconf directory than /usr/local/etc, that directory is where the sysless file is found.) On - MS-DOS and Windows systems, the system-wide lesskey file is c:\_sys- + MS-DOS and Windows systems, the system-wide lesskey file is c:\_sys- less. On OS/2 systems, the system-wide lesskey file is c:\sysless.ini. INPUT PREPROCESSOR - You may define an "input preprocessor" for less. Before less opens a + You may define an "input preprocessor" for less. Before less opens a file, it first gives your input preprocessor a chance to modify the way - the contents of the file are displayed. An input preprocessor is sim- - ply an executable program (or shell script), which writes the contents + the contents of the file are displayed. An input preprocessor is sim- + ply an executable program (or shell script), which writes the contents of the file to a different file, called the replacement file. The con- - tents of the replacement file are then displayed in place of the con- - tents of the original file. However, it will appear to the user as if - the original file is opened; that is, less will display the original + tents of the replacement file are then displayed in place of the con- + tents of the original file. However, it will appear to the user as if + the original file is opened; that is, less will display the original filename as the name of the current file. - An input preprocessor receives one command line argument, the original - filename, as entered by the user. It should create the replacement - file, and when finished, print the name of the replacement file to its - standard output. If the input preprocessor does not output a replace- - ment filename, less uses the original file, as normal. The input pre- - processor is not called when viewing standard input. To set up an - input preprocessor, set the LESSOPEN environment variable to a command - line which will invoke your input preprocessor. This command line - should include one occurrence of the string "%s", which will be - replaced by the filename when the input preprocessor command is + An input preprocessor receives one command line argument, the original + filename, as entered by the user. It should create the replacement + file, and when finished, print the name of the replacement file to its + standard output. If the input preprocessor does not output a replace- + ment filename, less uses the original file, as normal. The input pre- + processor is not called when viewing standard input. To set up an + input preprocessor, set the LESSOPEN environment variable to a command + line which will invoke your input preprocessor. This command line + should include one occurrence of the string "%s", which will be + replaced by the filename when the input preprocessor command is invoked. When less closes a file opened in such a way, it will call another pro- - gram, called the input postprocessor, which may perform any desired - clean-up action (such as deleting the replacement file created by + gram, called the input postprocessor, which may perform any desired + clean-up action (such as deleting the replacement file created by LESSOPEN). This program receives two command line arguments, the orig- - inal filename as entered by the user, and the name of the replacement - file. To set up an input postprocessor, set the LESSCLOSE environment - variable to a command line which will invoke your input postprocessor. - It may include two occurrences of the string "%s"; the first is - replaced with the original name of the file and the second with the + inal filename as entered by the user, and the name of the replacement + file. To set up an input postprocessor, set the LESSCLOSE environment + variable to a command line which will invoke your input postprocessor. + It may include two occurrences of the string "%s"; the first is + replaced with the original name of the file and the second with the name of the replacement file, which was output by LESSOPEN. - For example, on many Unix systems, these two scripts will allow you to + For example, on many Unix systems, these two scripts will allow you to keep files in compressed format, but still let less view them directly: lessopen.sh: @@ -1038,25 +1048,25 @@ LESS(1) #! /bin/sh rm $2 - To use these scripts, put them both where they can be executed and set + To use these scripts, put them both where they can be executed and set LESSOPEN="lessopen.sh %s", and LESSCLOSE="lessclose.sh %s %s". More - complex LESSOPEN and LESSCLOSE scripts may be written to accept other + complex LESSOPEN and LESSCLOSE scripts may be written to accept other types of compressed files, and so on. - It is also possible to set up an input preprocessor to pipe the file - data directly to less, rather than putting the data into a replacement + It is also possible to set up an input preprocessor to pipe the file + data directly to less, rather than putting the data into a replacement file. This avoids the need to decompress the entire file before start- ing to view it. An input preprocessor that works this way is called an - input pipe. An input pipe, instead of writing the name of a replace- - ment file on its standard output, writes the entire contents of the - replacement file on its standard output. If the input pipe does not - write any characters on its standard output, then there is no replace- - ment file and less uses the original file, as normal. To use an input - pipe, make the first character in the LESSOPEN environment variable a - vertical bar (|) to signify that the input preprocessor is an input + input pipe. An input pipe, instead of writing the name of a replace- + ment file on its standard output, writes the entire contents of the + replacement file on its standard output. If the input pipe does not + write any characters on its standard output, then there is no replace- + ment file and less uses the original file, as normal. To use an input + pipe, make the first character in the LESSOPEN environment variable a + vertical bar (|) to signify that the input preprocessor is an input pipe. - For example, on many Unix systems, this script will work like the pre- + For example, on many Unix systems, this script will work like the pre- vious example scripts: lesspipe.sh: @@ -1071,30 +1081,30 @@ LESS(1) To use this script, put it where it can be executed and set LESSOPEN="|lesspipe.sh %s". - Note that a preprocessor cannot output an empty file, since that is - interpreted as meaning there is no replacement, and the original file + Note that a preprocessor cannot output an empty file, since that is + interpreted as meaning there is no replacement, and the original file is used. To avoid this, if LESSOPEN starts with two vertical bars, the - exit status of the script becomes meaningful. If the exit status is - zero, the output is considered to be replacement text, even if it - empty. If the exit status is nonzero, any output is ignored and the - original file is used. For compatibility with previous versions of + exit status of the script becomes meaningful. If the exit status is + zero, the output is considered to be replacement text, even if it + empty. If the exit status is nonzero, any output is ignored and the + original file is used. For compatibility with previous versions of less, if LESSOPEN starts with only one vertical bar, the exit status of the preprocessor is ignored. - When an input pipe is used, a LESSCLOSE postprocessor can be used, but + When an input pipe is used, a LESSCLOSE postprocessor can be used, but it is usually not necessary since there is no replacement file to clean - up. In this case, the replacement file name passed to the LESSCLOSE + up. In this case, the replacement file name passed to the LESSCLOSE postprocessor is "-". - For compatibility with previous versions of less, the input preproces- + For compatibility with previous versions of less, the input preproces- sor or pipe is not used if less is viewing standard input. However, if - the first character of LESSOPEN is a dash (-), the input preprocessor - is used on standard input as well as other files. In this case, the - dash is not considered to be part of the preprocessor command. If + the first character of LESSOPEN is a dash (-), the input preprocessor + is used on standard input as well as other files. In this case, the + dash is not considered to be part of the preprocessor command. If standard input is being viewed, the input preprocessor is passed a file - name consisting of a single dash. Similarly, if the first two charac- - ters of LESSOPEN are vertical bar and dash (|-) or two vertical bars - and a dash (||-), the input pipe is used on standard input as well as + name consisting of a single dash. Similarly, if the first two charac- + ters of LESSOPEN are vertical bar and dash (|-) or two vertical bars + and a dash (||-), the input pipe is used on standard input as well as other files. Again, in this case the dash is not considered to be part of the input pipe command. @@ -1106,25 +1116,25 @@ LESS(1) can be displayed directly to the screen. control characters - should not be displayed directly, but are expected to be found + should not be displayed directly, but are expected to be found in ordinary text files (such as backspace and tab). binary characters *** DIFF OUTPUT TRUNCATED AT 1000 LINES *** From owner-svn-src-all@FreeBSD.ORG Mon May 13 06:53:17 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id 6D369165 for ; Mon, 13 May 2013 06:53:17 +0000 (UTC) (envelope-from peter@wemm.org) Received: from mail-vc0-f178.google.com (mail-vc0-f178.google.com [209.85.220.178]) by mx1.freebsd.org (Postfix) with ESMTP id 2F40A9A7 for ; Mon, 13 May 2013 06:53:16 +0000 (UTC) Received: by mail-vc0-f178.google.com with SMTP id id13so1902542vcb.9 for ; Sun, 12 May 2013 23:53:16 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=wemm.org; s=google; h=mime-version:x-received:in-reply-to:references:date:message-id :subject:from:to:cc:content-type; bh=gBH0JeiCFSBYLMNBVYadiKSnJL3bNbGpizDZMcbYa1A=; b=n7LFosYopL6nSSsBmnPGhWX6PLf1b5AuHoFnnHYb3gTWdJBkqK9tTsgtvNCgR3BoFA 3QM8rSbtc4JssVOE3TPlnjf5l6bRnmQg8yHVbPvNJhqee/KsKib0D7CqhVLxfiJcldhf 6UylnqKSpRykTnFHJy3g0rXLKV6XADS4MewgI= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20120113; h=mime-version:x-received:in-reply-to:references:date:message-id :subject:from:to:cc:content-type:x-gm-message-state; bh=gBH0JeiCFSBYLMNBVYadiKSnJL3bNbGpizDZMcbYa1A=; b=AyBqxN3Ur+gHHb9DD/JLJtUR35Wyl8iRSx70iSt0lw2DPhKMBe3+OvPLZF4IEhr+RX fbalzkiI+kCsj6uoWjtk2FBvuE1MTNDmP7dcmZnl6K3R7TeVaHlWfVo/jNayvoHcRhGO yoLKehLozyYkfLGILt8Q5N4wwuHoLNxhXYOjm2yTDfyiwgoui0xaVIpVdt/NN+GLPF9R 6HDMTx2ZECv3UmgaV0ibs+uMYfGsrltPBOU8UEd9CFcWUKugysL/ez3ORJ6lIQESeaYq p1xkDEnwzwshJ/8+rvqmCqkTyiqtCpsEYkI8R/Owwxf0NGY7FC+v5yTNkMilBlJ1SitC AzAw== MIME-Version: 1.0 X-Received: by 10.58.54.101 with SMTP id i5mr17589481vep.43.1368427996201; Sun, 12 May 2013 23:53:16 -0700 (PDT) Received: by 10.220.197.66 with HTTP; Sun, 12 May 2013 23:53:16 -0700 (PDT) In-Reply-To: <51900E57.80608@rice.edu> References: <201305121650.r4CGoJL0087149@svn.freebsd.org> <51900B97.20406@freebsd.org> <51900E57.80608@rice.edu> Date: Sun, 12 May 2013 23:53:16 -0700 Message-ID: Subject: Re: svn commit: r250577 - head/sys/vm From: Peter Wemm To: Alan Cox Content-Type: text/plain; charset=ISO-8859-1 X-Gm-Message-State: ALoCoQmKNftaHnr4f93aMcal04vdXQucYHJcMocpxHXXvdZER196PEjanery7RZY2kxRp1mn13V9 Cc: Alan Cox , svn-src-head@freebsd.org, svn-src-all@freebsd.org, src-committers@freebsd.org, Andrey Chernov X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 13 May 2013 06:53:17 -0000 On Sun, May 12, 2013 at 2:49 PM, Alan Cox wrote: > On 05/12/2013 16:37, Andrey Chernov wrote: >> On 12.05.2013 20:50, Alan Cox wrote: >> >> GNU cc errors related to part of diff below: >> cc1: warnings being treated as errors >> ../../../vm/vm_page.c: In function 'vm_page_alloc': >> ../../../vm/vm_page.c:1209: warning: 'mpred' may be used uninitialized >> in this function >> *** [vm_page.o] Error code 1 >> Formally yes, mpred here can be left unitialized. > > No, it can't. The code amounts to > > if ("x") > mpred = ... ; > ... > if ("x") > use mpred; > ... > if ("x") > use mpred; > > where "x" is "object != NULL". Moreover, there are no assignments to > the variable "object" or aliases by which the variable "object" can be > modified over the lifespan of "mpred". So, this is flawed analysis by > our antique gcc. Regardless of who's right or wrong, you've broken about half the freebsd.org cluster. It uses a mixture of gcc and clang to catch sillyness like this. -- Peter Wemm - peter@wemm.org; peter@FreeBSD.org; peter@yahoo-inc.com; KI6FJV From owner-svn-src-all@FreeBSD.ORG Mon May 13 07:02:16 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id 7094D536; Mon, 13 May 2013 07:02:16 +0000 (UTC) (envelope-from dim@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id 47D6D9ED; Mon, 13 May 2013 07:02:16 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.6/8.14.6) with ESMTP id r4D72Gxr086998; Mon, 13 May 2013 07:02:16 GMT (envelope-from dim@svn.freebsd.org) Received: (from dim@localhost) by svn.freebsd.org (8.14.6/8.14.5/Submit) id r4D72GbD086997; Mon, 13 May 2013 07:02:16 GMT (envelope-from dim@svn.freebsd.org) Message-Id: <201305130702.r4D72GbD086997@svn.freebsd.org> From: Dimitry Andric Date: Mon, 13 May 2013 07:02:16 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r250593 - head/contrib/llvm/lib/Transforms/Vectorize X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 13 May 2013 07:02:16 -0000 Author: dim Date: Mon May 13 07:02:15 2013 New Revision: 250593 URL: http://svnweb.freebsd.org/changeset/base/250593 Log: Pull in r181286 from upstream llvm trunk: LoopVectorize: getConsecutiveVector must respect signed arithmetic We were passing an i32 to ConstantInt::get where an i64 was needed and we must also pass the sign if we pass negatives numbers. The start index passed to getConsecutiveVector must also be signed. Should fix PR15882. This should fix Firefox crashes some people have been reporting, when it is compiled with -O3. Modified: head/contrib/llvm/lib/Transforms/Vectorize/LoopVectorize.cpp Modified: head/contrib/llvm/lib/Transforms/Vectorize/LoopVectorize.cpp ============================================================================== --- head/contrib/llvm/lib/Transforms/Vectorize/LoopVectorize.cpp Mon May 13 06:52:46 2013 (r250592) +++ head/contrib/llvm/lib/Transforms/Vectorize/LoopVectorize.cpp Mon May 13 07:02:15 2013 (r250593) @@ -214,7 +214,7 @@ private: /// This function adds 0, 1, 2 ... to each vector element, starting at zero. /// If Negate is set then negative numbers are added e.g. (0, -1, -2, ...). /// The sequence starts at StartIndex. - Value *getConsecutiveVector(Value* Val, unsigned StartIdx, bool Negate); + Value *getConsecutiveVector(Value* Val, int StartIdx, bool Negate); /// When we go over instructions in the basic block we rely on previous /// values within the current basic block or on loop invariant values. @@ -771,7 +771,7 @@ Value *InnerLoopVectorizer::getBroadcast return Shuf; } -Value *InnerLoopVectorizer::getConsecutiveVector(Value* Val, unsigned StartIdx, +Value *InnerLoopVectorizer::getConsecutiveVector(Value* Val, int StartIdx, bool Negate) { assert(Val->getType()->isVectorTy() && "Must be a vector"); assert(Val->getType()->getScalarType()->isIntegerTy() && @@ -784,8 +784,8 @@ Value *InnerLoopVectorizer::getConsecuti // Create a vector of consecutive numbers from zero to VF. for (int i = 0; i < VLen; ++i) { - int Idx = Negate ? (-i): i; - Indices.push_back(ConstantInt::get(ITy, StartIdx + Idx)); + int64_t Idx = Negate ? (-i) : i; + Indices.push_back(ConstantInt::get(ITy, StartIdx + Idx, Negate)); } // Add the consecutive indices to the vector value. @@ -1928,7 +1928,8 @@ InnerLoopVectorizer::vectorizeBlockInLoo // After broadcasting the induction variable we need to make the // vector consecutive by adding ... -3, -2, -1, 0. for (unsigned part = 0; part < UF; ++part) - Entry[part] = getConsecutiveVector(Broadcasted, -VF * part, true); + Entry[part] = getConsecutiveVector(Broadcasted, -(int)VF * part, + true); continue; } From owner-svn-src-all@FreeBSD.ORG Mon May 13 07:09:32 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id 58BA17A7; Mon, 13 May 2013 07:09:32 +0000 (UTC) (envelope-from peter@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id 4C46FA36; Mon, 13 May 2013 07:09:32 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.6/8.14.6) with ESMTP id r4D79Wlr088631; Mon, 13 May 2013 07:09:32 GMT (envelope-from peter@svn.freebsd.org) Received: (from peter@localhost) by svn.freebsd.org (8.14.6/8.14.5/Submit) id r4D79WuO088630; Mon, 13 May 2013 07:09:32 GMT (envelope-from peter@svn.freebsd.org) Message-Id: <201305130709.r4D79WuO088630@svn.freebsd.org> From: Peter Wemm Date: Mon, 13 May 2013 07:09:32 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r250594 - head/sys/vm X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 13 May 2013 07:09:32 -0000 Author: peter Date: Mon May 13 07:09:31 2013 New Revision: 250594 URL: http://svnweb.freebsd.org/changeset/base/250594 Log: Bandaid for compiling with gcc, which happens to be the default compiler for a number of platforms still. Modified: head/sys/vm/vm_page.c Modified: head/sys/vm/vm_page.c ============================================================================== --- head/sys/vm/vm_page.c Mon May 13 07:02:15 2013 (r250593) +++ head/sys/vm/vm_page.c Mon May 13 07:09:31 2013 (r250594) @@ -1209,6 +1209,7 @@ vm_page_alloc(vm_object_t object, vm_pin vm_page_t m, mpred; int flags, req_class; + mpred = 0; /* XXX: pacify gcc */ KASSERT((object != NULL) == ((req & VM_ALLOC_NOOBJ) == 0), ("vm_page_alloc: inconsistent object/req")); if (object != NULL) From owner-svn-src-all@FreeBSD.ORG Mon May 13 11:32:20 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id BC6EDBE9; Mon, 13 May 2013 11:32:20 +0000 (UTC) (envelope-from bdrewery@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id AFA1FB49; Mon, 13 May 2013 11:32:20 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.6/8.14.6) with ESMTP id r4DBWKkb085363; Mon, 13 May 2013 11:32:20 GMT (envelope-from bdrewery@svn.freebsd.org) Received: (from bdrewery@localhost) by svn.freebsd.org (8.14.6/8.14.5/Submit) id r4DBWK1h085362; Mon, 13 May 2013 11:32:20 GMT (envelope-from bdrewery@svn.freebsd.org) Message-Id: <201305131132.r4DBWK1h085362@svn.freebsd.org> From: Bryan Drewery Date: Mon, 13 May 2013 11:32:20 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r250595 - head/crypto/openssh X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 13 May 2013 11:32:20 -0000 Author: bdrewery (ports committer) Date: Mon May 13 11:32:20 2013 New Revision: 250595 URL: http://svnweb.freebsd.org/changeset/base/250595 Log: The HPN patch added a new BUG bit for SSH_BUG_LARGEWINDOW and the update to 6.1 added SSH_BUG_DYNAMIC_RPORT with the same value. Fix the HPN SSH_BUG_LARGEWINDOW bit so it is unique. Approved by: des MFC after: 2 weeks Modified: head/crypto/openssh/compat.h Modified: head/crypto/openssh/compat.h ============================================================================== --- head/crypto/openssh/compat.h Mon May 13 07:09:31 2013 (r250594) +++ head/crypto/openssh/compat.h Mon May 13 11:32:20 2013 (r250595) @@ -60,7 +60,7 @@ #define SSH_BUG_RFWD_ADDR 0x02000000 #define SSH_NEW_OPENSSH 0x04000000 #define SSH_BUG_DYNAMIC_RPORT 0x08000000 -#define SSH_BUG_LARGEWINDOW 0x08000000 +#define SSH_BUG_LARGEWINDOW 0x10000000 void enable_compat13(void); void enable_compat20(void); From owner-svn-src-all@FreeBSD.ORG Mon May 13 12:43:04 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id 32E93278; Mon, 13 May 2013 12:43:04 +0000 (UTC) (envelope-from luigi@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id 0AA1AF8A; Mon, 13 May 2013 12:43:04 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.6/8.14.6) with ESMTP id r4DCh3xK010126; Mon, 13 May 2013 12:43:03 GMT (envelope-from luigi@svn.freebsd.org) Received: (from luigi@localhost) by svn.freebsd.org (8.14.6/8.14.5/Submit) id r4DCh3OJ010125; Mon, 13 May 2013 12:43:03 GMT (envelope-from luigi@svn.freebsd.org) Message-Id: <201305131243.r4DCh3OJ010125@svn.freebsd.org> From: Luigi Rizzo Date: Mon, 13 May 2013 12:43:03 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org Subject: svn commit: r250596 - stable/9/release/picobsd/build X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 13 May 2013 12:43:04 -0000 Author: luigi Date: Mon May 13 12:43:03 2013 New Revision: 250596 URL: http://svnweb.freebsd.org/changeset/base/250596 Log: MFC: enable parallel build of toolchain/libraries/headers Modified: stable/9/release/picobsd/build/picobsd Modified: stable/9/release/picobsd/build/picobsd ============================================================================== --- stable/9/release/picobsd/build/picobsd Mon May 13 11:32:20 2013 (r250595) +++ stable/9/release/picobsd/build/picobsd Mon May 13 12:43:03 2013 (r250596) @@ -173,17 +173,10 @@ create_includes_and_libraries2() { # opt if [ -d "$1" ] ; then cd $1 ; ${BINMAKE} ${o_par} $2 # specific target, e.g. ld-elf.so else - MAKEOBJDIRPREFIX=${l_objtree} - export MAKEOBJDIRPREFIX - # export WITH_RESCUE=yes # build crunchide - # ${BINMAKE} ${o_par} _+_= $no toolchain _includes _libraries - ( - # eval export `cd ${SRC}; ${BINMAKE} -f Makefile.inc1 -V BMAKEENV` - eval "export XMAKE=\"`cd ${SRC}; make -f Makefile -V XMAKE`\"" - ${BINMAKE} ${o_par} _+_= $no toolchain - ) + export MAKEOBJDIRPREFIX=${l_objtree} + make ${o_par} $no toolchain + # XXX do we need any of these ? eval export `cd ${SRC}; ${BINMAKE} -f Makefile.inc1 -V WMAKEENV` - ${BINMAKE} ${o_par} _+_= $no _includes _libraries [ ${o_arch} != `uname -m` ] && \ (cd ${l_objtree}; ln -s . ${o_arch}.${o_arch} || true ) fi @@ -440,7 +433,8 @@ do_kernel() { # OK # export CONFIG export WARNS CWARNFLAGS [ "${o_do_modules}" = "yes" ] && export MODULES="" - ${BINMAKE} ${o_par} KERNCONF=${l_kernconf} \ + # kernel build not parallelizable yet + ${BINMAKE} KERNCONF=${l_kernconf} \ -v -f ${PICO_TREE}/build/Makefile.conf ) || \ fail $? missing_kernel } @@ -971,6 +965,7 @@ set_build_parameters() { if [ ${OSVERSION} -ge 500035 ] ; then export MAKEOBJDIRPREFIX=${l_objtree} export TARGET_ARCH=${o_arch} TARGET=${o_arch} + export WITHOUT_CLANG_IS_CC=1 # XXX why change machine_arch ? #-- export MACHINE_ARCH=`uname -m` MACHINE=`uname -m` # export CWARNFLAGS="-Wextra -Wno-sign-compare -Wno-missing-field-initializers" From owner-svn-src-all@FreeBSD.ORG Mon May 13 13:57:06 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id D7425A78; Mon, 13 May 2013 13:57:06 +0000 (UTC) (envelope-from jh@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id C930A76D; Mon, 13 May 2013 13:57:06 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.6/8.14.6) with ESMTP id r4DDv6Zf035414; Mon, 13 May 2013 13:57:06 GMT (envelope-from jh@svn.freebsd.org) Received: (from jh@localhost) by svn.freebsd.org (8.14.6/8.14.5/Submit) id r4DDv6e3035413; Mon, 13 May 2013 13:57:06 GMT (envelope-from jh@svn.freebsd.org) Message-Id: <201305131357.r4DDv6e3035413@svn.freebsd.org> From: Jaakko Heinonen Date: Mon, 13 May 2013 13:57:06 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org Subject: svn commit: r250597 - stable/9/usr.bin/calendar X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 13 May 2013 13:57:06 -0000 Author: jh Date: Mon May 13 13:57:06 2013 New Revision: 250597 URL: http://svnweb.freebsd.org/changeset/base/250597 Log: MFC r249200: Correct the path. PR: 176256 Modified: stable/9/usr.bin/calendar/calendar.1 Directory Properties: stable/9/usr.bin/calendar/ (props changed) Modified: stable/9/usr.bin/calendar/calendar.1 ============================================================================== --- stable/9/usr.bin/calendar/calendar.1 Mon May 13 12:43:03 2013 (r250596) +++ stable/9/usr.bin/calendar/calendar.1 Mon May 13 13:57:06 2013 (r250597) @@ -28,7 +28,7 @@ .\" @(#)calendar.1 8.1 (Berkeley) 6/29/93 .\" $FreeBSD$ .\" -.Dd June 13, 2002 +.Dd April 6, 2013 .Dt CALENDAR 1 .Os .Sh NAME @@ -230,7 +230,7 @@ do not send mail if this file exists. .El .Pp The following default calendar files are provided in -.Pa /usr/share/calendars: +.Pa /usr/share/calendar: .Pp .Bl -tag -width calendar.southafrica -compact .It Pa calendar.all From owner-svn-src-all@FreeBSD.ORG Mon May 13 14:00:24 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id E9BFEC8E; Mon, 13 May 2013 14:00:24 +0000 (UTC) (envelope-from jh@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id DBCBA7A1; Mon, 13 May 2013 14:00:24 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.6/8.14.6) with ESMTP id r4DE0OTX037721; Mon, 13 May 2013 14:00:24 GMT (envelope-from jh@svn.freebsd.org) Received: (from jh@localhost) by svn.freebsd.org (8.14.6/8.14.5/Submit) id r4DE0OWO037720; Mon, 13 May 2013 14:00:24 GMT (envelope-from jh@svn.freebsd.org) Message-Id: <201305131400.r4DE0OWO037720@svn.freebsd.org> From: Jaakko Heinonen Date: Mon, 13 May 2013 14:00:24 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-8@freebsd.org Subject: svn commit: r250598 - stable/8/usr.bin/calendar X-SVN-Group: stable-8 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 13 May 2013 14:00:25 -0000 Author: jh Date: Mon May 13 14:00:24 2013 New Revision: 250598 URL: http://svnweb.freebsd.org/changeset/base/250598 Log: MFC r249200: Correct the path. PR: 176256 Modified: stable/8/usr.bin/calendar/calendar.1 Directory Properties: stable/8/usr.bin/calendar/ (props changed) Modified: stable/8/usr.bin/calendar/calendar.1 ============================================================================== --- stable/8/usr.bin/calendar/calendar.1 Mon May 13 13:57:06 2013 (r250597) +++ stable/8/usr.bin/calendar/calendar.1 Mon May 13 14:00:24 2013 (r250598) @@ -28,7 +28,7 @@ .\" @(#)calendar.1 8.1 (Berkeley) 6/29/93 .\" $FreeBSD$ .\" -.Dd June 13, 2002 +.Dd April 6, 2013 .Dt CALENDAR 1 .Os .Sh NAME @@ -222,7 +222,7 @@ do not send mail if this file exists. .El .Pp The following default calendar files are provided in -.Pa /usr/share/calendars: +.Pa /usr/share/calendar: .Pp .Bl -tag -width calendar.southafrica -compact .It Pa calendar.all From owner-svn-src-all@FreeBSD.ORG Mon May 13 15:00:37 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id 4B72C23C; Mon, 13 May 2013 15:00:37 +0000 (UTC) (envelope-from markj@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id 3DB2CCE4; Mon, 13 May 2013 15:00:37 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.6/8.14.6) with ESMTP id r4DF0bRq059480; Mon, 13 May 2013 15:00:37 GMT (envelope-from markj@svn.freebsd.org) Received: (from markj@localhost) by svn.freebsd.org (8.14.6/8.14.5/Submit) id r4DF0bqZ059479; Mon, 13 May 2013 15:00:37 GMT (envelope-from markj@svn.freebsd.org) Message-Id: <201305131500.r4DF0bqZ059479@svn.freebsd.org> From: Mark Johnston Date: Mon, 13 May 2013 15:00:37 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r250599 - head/usr.sbin/mfiutil X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 13 May 2013 15:00:37 -0000 Author: markj Date: Mon May 13 15:00:36 2013 New Revision: 250599 URL: http://svnweb.freebsd.org/changeset/base/250599 Log: Add a remark to the effect that a manually started relearn will always result in the battery being completely drained, even in transparent learning mode. MFC in: 3 days Sponsored by: Sandvine Inc. Modified: head/usr.sbin/mfiutil/mfiutil.8 Modified: head/usr.sbin/mfiutil/mfiutil.8 ============================================================================== --- head/usr.sbin/mfiutil/mfiutil.8 Mon May 13 14:00:24 2013 (r250598) +++ head/usr.sbin/mfiutil/mfiutil.8 Mon May 13 15:00:36 2013 (r250599) @@ -573,6 +573,10 @@ Updates the flash on the controller with A reboot is required for the new firmware to take effect. .It Cm start learn Start a battery relearn. +Note that this seems to always result in the battery being completely drained, +regardless of the BBU mode. +In particular, the controller write cache will be disabled during the relearn +even if transparent learning mode is enabled. .It Cm bbu Ar setting Ar value Update battery backup unit (BBU) properties related to battery relearning. The following settings are configurable: From owner-svn-src-all@FreeBSD.ORG Mon May 13 15:18:38 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id 120E3C3C; Mon, 13 May 2013 15:18:38 +0000 (UTC) (envelope-from fabient@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id E734AEBC; Mon, 13 May 2013 15:18:37 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.6/8.14.6) with ESMTP id r4DFIbU1065183; Mon, 13 May 2013 15:18:37 GMT (envelope-from fabient@svn.freebsd.org) Received: (from fabient@localhost) by svn.freebsd.org (8.14.6/8.14.5/Submit) id r4DFIaJg065174; Mon, 13 May 2013 15:18:36 GMT (envelope-from fabient@svn.freebsd.org) Message-Id: <201305131518.r4DFIaJg065174@svn.freebsd.org> From: Fabien Thomas Date: Mon, 13 May 2013 15:18:36 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org Subject: svn commit: r250600 - in stable/9: lib/libpmc sys/dev/hwpmc sys/kern sys/sys X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 13 May 2013 15:18:38 -0000 Author: fabient Date: Mon May 13 15:18:36 2013 New Revision: 250600 URL: http://svnweb.freebsd.org/changeset/base/250600 Log: MFC r247329, r247836: Add support for good old 8192Hz profiling clock to software PMC. Add a generic way to call per event allocate / release function. Modified: stable/9/lib/libpmc/pmc.soft.3 stable/9/sys/dev/hwpmc/hwpmc_soft.c stable/9/sys/kern/kern_clock.c stable/9/sys/kern/kern_clocksource.c stable/9/sys/sys/pmckern.h Directory Properties: stable/9/lib/libpmc/ (props changed) stable/9/sys/ (props changed) stable/9/sys/dev/ (props changed) stable/9/sys/sys/ (props changed) Modified: stable/9/lib/libpmc/pmc.soft.3 ============================================================================== --- stable/9/lib/libpmc/pmc.soft.3 Mon May 13 15:00:36 2013 (r250599) +++ stable/9/lib/libpmc/pmc.soft.3 Mon May 13 15:18:36 2013 (r250600) @@ -23,7 +23,7 @@ .\" .\" $FreeBSD$ .\" -.Dd March 28, 2012 +.Dd February 26, 2013 .Os .Dt PMC.SOFT 3 .Sh NAME @@ -61,6 +61,8 @@ The event specifiers supported by softwa Hard clock ticks. .It Li CLOCK.STAT Stat clock ticks. +.It Li CLOCK.PROF +Profiling clock ticks. .It Li LOCK.FAILED Lock acquisition failed. .It Li PAGE_FAULT.ALL Modified: stable/9/sys/dev/hwpmc/hwpmc_soft.c ============================================================================== --- stable/9/sys/dev/hwpmc/hwpmc_soft.c Mon May 13 15:00:36 2013 (r250599) +++ stable/9/sys/dev/hwpmc/hwpmc_soft.c Mon May 13 15:18:36 2013 (r250600) @@ -124,6 +124,9 @@ soft_allocate_pmc(int cpu, int ri, struc if (ps == NULL) return (EINVAL); pmc_soft_ev_release(ps); + /* Module unload is protected by pmc SX lock. */ + if (ps->ps_alloc != NULL) + ps->ps_alloc(); return (0); } @@ -311,6 +314,8 @@ static int soft_release_pmc(int cpu, int ri, struct pmc *pmc) { struct pmc_hw *phw; + enum pmc_event ev; + struct pmc_soft *ps; (void) pmc; @@ -324,9 +329,16 @@ soft_release_pmc(int cpu, int ri, struct KASSERT(phw->phw_pmc == NULL, ("[soft,%d] PHW pmc %p non-NULL", __LINE__, phw->phw_pmc)); - /* - * Nothing to do. - */ + ev = pmc->pm_event; + + /* Check if event is registered. */ + ps = pmc_soft_ev_acquire(ev); + KASSERT(ps != NULL, + ("[soft,%d] unregistered event %d", __LINE__, ev)); + pmc_soft_ev_release(ps); + /* Module unload is protected by pmc SX lock. */ + if (ps->ps_release != NULL) + ps->ps_release(); return (0); } Modified: stable/9/sys/kern/kern_clock.c ============================================================================== --- stable/9/sys/kern/kern_clock.c Mon May 13 15:00:36 2013 (r250599) +++ stable/9/sys/kern/kern_clock.c Mon May 13 15:18:36 2013 (r250600) @@ -78,6 +78,8 @@ __FBSDID("$FreeBSD$"); #include PMC_SOFT_DEFINE( , , clock, hard); PMC_SOFT_DEFINE( , , clock, stat); +PMC_SOFT_DEFINE_EX( , , clock, prof, \ + cpu_startprofclock, cpu_stopprofclock); #endif #ifdef DEVICE_POLLING @@ -817,6 +819,10 @@ profclock_cnt(int cnt, int usermode, uin } } #endif +#ifdef HWPMC_HOOKS + if (td->td_intr_frame != NULL) + PMC_SOFT_CALL_TF( , , clock, prof, td->td_intr_frame); +#endif } /* Modified: stable/9/sys/kern/kern_clocksource.c ============================================================================== --- stable/9/sys/kern/kern_clocksource.c Mon May 13 15:00:36 2013 (r250599) +++ stable/9/sys/kern/kern_clocksource.c Mon May 13 15:18:36 2013 (r250600) @@ -732,12 +732,15 @@ cpu_startprofclock(void) { ET_LOCK(); - if (periodic) { - configtimer(0); - profiling = 1; - configtimer(1); + if (profiling == 0) { + if (periodic) { + configtimer(0); + profiling = 1; + configtimer(1); + } else + profiling = 1; } else - profiling = 1; + profiling++; ET_UNLOCK(); } @@ -749,12 +752,15 @@ cpu_stopprofclock(void) { ET_LOCK(); - if (periodic) { - configtimer(0); + if (profiling == 1) { + if (periodic) { + configtimer(0); + profiling = 0; + configtimer(1); + } else profiling = 0; - configtimer(1); } else - profiling = 0; + profiling--; ET_UNLOCK(); } Modified: stable/9/sys/sys/pmckern.h ============================================================================== --- stable/9/sys/sys/pmckern.h Mon May 13 15:00:36 2013 (r250599) +++ stable/9/sys/sys/pmckern.h Mon May 13 15:18:36 2013 (r250600) @@ -87,9 +87,9 @@ struct pmckern_soft { * Soft PMC. */ -#define PMC_SOFT_DEFINE(prov, mod, func, name) \ +#define PMC_SOFT_DEFINE_EX(prov, mod, func, name, alloc, release) \ struct pmc_soft pmc_##prov##_##mod##_##func##_##name = \ - { 0, { #prov "_" #mod "_" #func "." #name, 0 } }; \ + { 0, alloc, release, { #prov "_" #mod "_" #func "." #name, 0 } }; \ SYSINIT(pmc_##prov##_##mod##_##func##_##name##_init, SI_SUB_KDTRACE, \ SI_ORDER_SECOND + 1, pmc_soft_ev_register, \ &pmc_##prov##_##mod##_##func##_##name ); \ @@ -97,6 +97,9 @@ struct pmckern_soft { SI_SUB_KDTRACE, SI_ORDER_SECOND + 1, pmc_soft_ev_deregister, \ &pmc_##prov##_##mod##_##func##_##name ) +#define PMC_SOFT_DEFINE(prov, mod, func, name) \ + PMC_SOFT_DEFINE_EX(prov, mod, func, name, NULL, NULL) + #define PMC_SOFT_DECLARE(prov, mod, func, name) \ extern struct pmc_soft pmc_##prov##_##mod##_##func##_##name @@ -147,6 +150,8 @@ do { \ struct pmc_soft { int ps_running; + void (*ps_alloc)(void); + void (*ps_release)(void); struct pmc_dyn_event_descr ps_ev; }; From owner-svn-src-all@FreeBSD.ORG Mon May 13 15:40:52 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id 1B9A87C; Mon, 13 May 2013 15:40:52 +0000 (UTC) (envelope-from attilio@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id 0C92616B; Mon, 13 May 2013 15:40:52 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.6/8.14.6) with ESMTP id r4DFeqId074569; Mon, 13 May 2013 15:40:52 GMT (envelope-from attilio@svn.freebsd.org) Received: (from attilio@localhost) by svn.freebsd.org (8.14.6/8.14.5/Submit) id r4DFepou074563; Mon, 13 May 2013 15:40:51 GMT (envelope-from attilio@svn.freebsd.org) Message-Id: <201305131540.r4DFepou074563@svn.freebsd.org> From: Attilio Rao Date: Mon, 13 May 2013 15:40:51 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r250601 - in head/sys: sys vm x86/acpica X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 13 May 2013 15:40:52 -0000 Author: attilio Date: Mon May 13 15:40:51 2013 New Revision: 250601 URL: http://svnweb.freebsd.org/changeset/base/250601 Log: o Add accessor functions to add and remove pages from a specific freelist. o Split the pool of free pages queues really by domain and not rely on definition of VM_RAW_NFREELIST. o For MAXMEMDOM > 1, wrap the RR allocation logic into a specific function that is called when calculating the allocation domain. The RR counter is kept, currently, per-thread. In the future it is expected that such function evolves in a real policy decision referee, based on specific informations retrieved by per-thread and per-vm_object attributes. o Add the concept of "probed domains" under the form of vm_ndomains. It is responsibility for every architecture willing to support multiple memory domains to correctly probe vm_ndomains along with mem_affinity segments attributes. Those two values are supposed to remain always consistent. Please also note that vm_ndomains and td_dom_rr_idx are both int because segments already store domains as int. Ideally u_int would have much more sense. Probabilly this should be cleaned up in the future. o Apply RR domain selection also to vm_phys_zero_pages_idle(). Sponsored by: EMC / Isilon storage division Partly obtained from: jeff Reviewed by: alc Tested by: jeff Modified: head/sys/sys/proc.h head/sys/vm/vm_phys.c head/sys/vm/vm_phys.h head/sys/x86/acpica/srat.c Modified: head/sys/sys/proc.h ============================================================================== --- head/sys/sys/proc.h Mon May 13 15:18:36 2013 (r250600) +++ head/sys/sys/proc.h Mon May 13 15:40:51 2013 (r250601) @@ -274,6 +274,7 @@ struct thread { pid_t td_dbg_forked; /* (c) Child pid for debugger. */ u_int td_vp_reserv; /* (k) Count of reserved vnodes. */ int td_no_sleeping; /* (k) Sleeping disabled count. */ + int td_dom_rr_idx; /* (k) RR Numa domain selection. */ #define td_endzero td_sigmask /* Copied during fork1() or create_thread(). */ Modified: head/sys/vm/vm_phys.c ============================================================================== --- head/sys/vm/vm_phys.c Mon May 13 15:18:36 2013 (r250600) +++ head/sys/vm/vm_phys.c Mon May 13 15:40:51 2013 (r250601) @@ -48,6 +48,9 @@ __FBSDID("$FreeBSD$"); #include #include #include +#if MAXMEMDOM > 1 +#include +#endif #include #include #include @@ -62,13 +65,6 @@ __FBSDID("$FreeBSD$"); #include #include -/* - * VM_FREELIST_DEFAULT is split into MAXMEMDOM lists, one for each - * domain. These extra lists are stored at the end of the regular - * free lists starting with VM_NFREELIST. - */ -#define VM_RAW_NFREELIST (VM_NFREELIST + MAXMEMDOM - 1) - struct vm_freelist { struct pglist pl; int lcnt; @@ -84,6 +80,8 @@ struct vm_phys_seg { struct mem_affinity *mem_affinity; +int vm_ndomains = 1; + static struct vm_phys_seg vm_phys_segs[VM_PHYSSEG_MAX]; static int vm_phys_nsegs; @@ -98,9 +96,7 @@ static struct mtx vm_phys_fictitious_reg MALLOC_DEFINE(M_FICT_PAGES, "", ""); static struct vm_freelist - vm_phys_free_queues[VM_RAW_NFREELIST][VM_NFREEPOOL][VM_NFREEORDER]; -static struct vm_freelist -(*vm_phys_lookup_lists[MAXMEMDOM][VM_RAW_NFREELIST])[VM_NFREEPOOL][VM_NFREEORDER]; + vm_phys_free_queues[MAXMEMDOM][VM_NFREELIST][VM_NFREEPOOL][VM_NFREEORDER]; static int vm_nfreelists = VM_FREELIST_DEFAULT + 1; @@ -116,11 +112,8 @@ static int sysctl_vm_phys_segs(SYSCTL_HA SYSCTL_OID(_vm, OID_AUTO, phys_segs, CTLTYPE_STRING | CTLFLAG_RD, NULL, 0, sysctl_vm_phys_segs, "A", "Phys Seg Info"); -#if MAXMEMDOM > 1 -static int sysctl_vm_phys_lookup_lists(SYSCTL_HANDLER_ARGS); -SYSCTL_OID(_vm, OID_AUTO, phys_lookup_lists, CTLTYPE_STRING | CTLFLAG_RD, - NULL, 0, sysctl_vm_phys_lookup_lists, "A", "Phys Lookup Lists"); -#endif +SYSCTL_INT(_vm, OID_AUTO, ndomains, CTLFLAG_RD, + &vm_ndomains, 0, "Number of physical memory domains available."); static vm_page_t vm_phys_alloc_domain_pages(int domain, int flind, int pool, int order); @@ -131,6 +124,22 @@ static int vm_phys_paddr_to_segind(vm_pa static void vm_phys_split_pages(vm_page_t m, int oind, struct vm_freelist *fl, int order); +static __inline int +vm_rr_selectdomain(void) +{ +#if MAXMEMDOM > 1 + struct thread *td; + + td = curthread; + + td->td_dom_rr_idx++; + td->td_dom_rr_idx %= vm_ndomains; + return (td->td_dom_rr_idx); +#else + return (0); +#endif +} + /* * Outputs the state of the physical memory allocator, specifically, * the amount of physical memory in each free list. @@ -140,31 +149,37 @@ sysctl_vm_phys_free(SYSCTL_HANDLER_ARGS) { struct sbuf sbuf; struct vm_freelist *fl; - int error, flind, oind, pind; + int dom, error, flind, oind, pind; error = sysctl_wire_old_buffer(req, 0); if (error != 0) return (error); - sbuf_new_for_sysctl(&sbuf, NULL, 128, req); - for (flind = 0; flind < vm_nfreelists; flind++) { - sbuf_printf(&sbuf, "\nFREE LIST %d:\n" - "\n ORDER (SIZE) | NUMBER" - "\n ", flind); - for (pind = 0; pind < VM_NFREEPOOL; pind++) - sbuf_printf(&sbuf, " | POOL %d", pind); - sbuf_printf(&sbuf, "\n-- "); - for (pind = 0; pind < VM_NFREEPOOL; pind++) - sbuf_printf(&sbuf, "-- -- "); - sbuf_printf(&sbuf, "--\n"); - for (oind = VM_NFREEORDER - 1; oind >= 0; oind--) { - sbuf_printf(&sbuf, " %2d (%6dK)", oind, - 1 << (PAGE_SHIFT - 10 + oind)); - for (pind = 0; pind < VM_NFREEPOOL; pind++) { - fl = vm_phys_free_queues[flind][pind]; - sbuf_printf(&sbuf, " | %6d", fl[oind].lcnt); + sbuf_new_for_sysctl(&sbuf, NULL, 128 * vm_ndomains, req); + for (dom = 0; dom < vm_ndomains; dom++) { + sbuf_printf(&sbuf,"DOMAIN: %d\n", dom); + for (flind = 0; flind < vm_nfreelists; flind++) { + sbuf_printf(&sbuf, "FREE LIST %d:\n" + "\n ORDER (SIZE) | NUMBER" + "\n ", flind); + for (pind = 0; pind < VM_NFREEPOOL; pind++) + sbuf_printf(&sbuf, " | POOL %d", pind); + sbuf_printf(&sbuf, "\n-- "); + for (pind = 0; pind < VM_NFREEPOOL; pind++) + sbuf_printf(&sbuf, "-- -- "); + sbuf_printf(&sbuf, "--\n"); + for (oind = VM_NFREEORDER - 1; oind >= 0; oind--) { + sbuf_printf(&sbuf, " %2d (%6dK)", oind, + 1 << (PAGE_SHIFT - 10 + oind)); + for (pind = 0; pind < VM_NFREEPOOL; pind++) { + fl = vm_phys_free_queues[dom][flind][pind]; + sbuf_printf(&sbuf, " | %6.6d", + fl[oind].lcnt); + } + sbuf_printf(&sbuf, "\n"); } sbuf_printf(&sbuf, "\n"); } + sbuf_printf(&sbuf, "\n"); } error = sbuf_finish(&sbuf); sbuf_delete(&sbuf); @@ -200,33 +215,27 @@ sysctl_vm_phys_segs(SYSCTL_HANDLER_ARGS) return (error); } -#if MAXMEMDOM > 1 -/* - * Outputs the set of free list lookup lists. - */ -static int -sysctl_vm_phys_lookup_lists(SYSCTL_HANDLER_ARGS) +static void +vm_freelist_add(struct vm_freelist *fl, vm_page_t m, int order, int tail) { - struct sbuf sbuf; - int domain, error, flind, ndomains; - error = sysctl_wire_old_buffer(req, 0); - if (error != 0) - return (error); - sbuf_new_for_sysctl(&sbuf, NULL, 128, req); - ndomains = vm_nfreelists - VM_NFREELIST + 1; - for (domain = 0; domain < ndomains; domain++) { - sbuf_printf(&sbuf, "\nDOMAIN %d:\n\n", domain); - for (flind = 0; flind < vm_nfreelists; flind++) - sbuf_printf(&sbuf, " [%d]:\t%p\n", flind, - vm_phys_lookup_lists[domain][flind]); - } - error = sbuf_finish(&sbuf); - sbuf_delete(&sbuf); - return (error); + m->order = order; + if (tail) + TAILQ_INSERT_TAIL(&fl[order].pl, m, pageq); + else + TAILQ_INSERT_HEAD(&fl[order].pl, m, pageq); + fl[order].lcnt++; } -#endif - + +static void +vm_freelist_rem(struct vm_freelist *fl, vm_page_t m, int order) +{ + + TAILQ_REMOVE(&fl[order].pl, m, pageq); + fl[order].lcnt--; + m->order = VM_NFREEORDER; +} + /* * Create a physical memory segment. */ @@ -246,6 +255,8 @@ _vm_phys_create_seg(vm_paddr_t start, vm #endif KASSERT(vm_phys_nsegs < VM_PHYSSEG_MAX, ("vm_phys_create_seg: increase VM_PHYSSEG_MAX")); + KASSERT(domain < vm_ndomains, + ("vm_phys_create_seg: invalid domain provided")); seg = &vm_phys_segs[vm_phys_nsegs++]; seg->start = start; seg->end = end; @@ -255,14 +266,7 @@ _vm_phys_create_seg(vm_paddr_t start, vm #else seg->first_page = PHYS_TO_VM_PAGE(start); #endif -#if MAXMEMDOM > 1 - if (flind == VM_FREELIST_DEFAULT && domain != 0) { - flind = VM_NFREELIST + (domain - 1); - if (flind >= vm_nfreelists) - vm_nfreelists = flind + 1; - } -#endif - seg->free_queues = &vm_phys_free_queues[flind]; + seg->free_queues = &vm_phys_free_queues[domain][flind]; } static void @@ -301,10 +305,7 @@ void vm_phys_init(void) { struct vm_freelist *fl; - int flind, i, oind, pind; -#if MAXMEMDOM > 1 - int ndomains, j; -#endif + int dom, flind, i, oind, pind; for (i = 0; phys_avail[i + 1] != 0; i += 2) { #ifdef VM_FREELIST_ISADMA @@ -340,45 +341,15 @@ vm_phys_init(void) vm_phys_create_seg(phys_avail[i], phys_avail[i + 1], VM_FREELIST_DEFAULT); } - for (flind = 0; flind < vm_nfreelists; flind++) { - for (pind = 0; pind < VM_NFREEPOOL; pind++) { - fl = vm_phys_free_queues[flind][pind]; - for (oind = 0; oind < VM_NFREEORDER; oind++) - TAILQ_INIT(&fl[oind].pl); + for (dom = 0; dom < vm_ndomains; dom++) { + for (flind = 0; flind < vm_nfreelists; flind++) { + for (pind = 0; pind < VM_NFREEPOOL; pind++) { + fl = vm_phys_free_queues[dom][flind][pind]; + for (oind = 0; oind < VM_NFREEORDER; oind++) + TAILQ_INIT(&fl[oind].pl); + } } } -#if MAXMEMDOM > 1 - /* - * Build a free list lookup list for each domain. All of the - * memory domain lists are inserted at the VM_FREELIST_DEFAULT - * index in a round-robin order starting with the current - * domain. - */ - ndomains = vm_nfreelists - VM_NFREELIST + 1; - for (flind = 0; flind < VM_FREELIST_DEFAULT; flind++) - for (i = 0; i < ndomains; i++) - vm_phys_lookup_lists[i][flind] = - &vm_phys_free_queues[flind]; - for (i = 0; i < ndomains; i++) - for (j = 0; j < ndomains; j++) { - flind = (i + j) % ndomains; - if (flind == 0) - flind = VM_FREELIST_DEFAULT; - else - flind += VM_NFREELIST - 1; - vm_phys_lookup_lists[i][VM_FREELIST_DEFAULT + j] = - &vm_phys_free_queues[flind]; - } - for (flind = VM_FREELIST_DEFAULT + 1; flind < VM_NFREELIST; - flind++) - for (i = 0; i < ndomains; i++) - vm_phys_lookup_lists[i][flind + ndomains - 1] = - &vm_phys_free_queues[flind]; -#else - for (flind = 0; flind < vm_nfreelists; flind++) - vm_phys_lookup_lists[0][flind] = &vm_phys_free_queues[flind]; -#endif - mtx_init(&vm_phys_fictitious_reg_mtx, "vmfctr", NULL, MTX_DEF); } @@ -396,9 +367,7 @@ vm_phys_split_pages(vm_page_t m, int oin KASSERT(m_buddy->order == VM_NFREEORDER, ("vm_phys_split_pages: page %p has unexpected order %d", m_buddy, m_buddy->order)); - m_buddy->order = oind; - TAILQ_INSERT_HEAD(&fl[oind].pl, m_buddy, pageq); - fl[oind].lcnt++; + vm_freelist_add(fl, m_buddy, oind, 0); } } @@ -437,22 +406,21 @@ vm_page_t vm_phys_alloc_pages(int pool, int order) { vm_page_t m; - int domain, flind; + int dom, domain, flind; KASSERT(pool < VM_NFREEPOOL, ("vm_phys_alloc_pages: pool %d is out of range", pool)); KASSERT(order < VM_NFREEORDER, ("vm_phys_alloc_pages: order %d is out of range", order)); -#if MAXMEMDOM > 1 - domain = PCPU_GET(domain); -#else - domain = 0; -#endif - for (flind = 0; flind < vm_nfreelists; flind++) { - m = vm_phys_alloc_domain_pages(domain, flind, pool, order); - if (m != NULL) - return (m); + for (dom = 0; dom < vm_ndomains; dom++) { + domain = vm_rr_selectdomain(); + for (flind = 0; flind < vm_nfreelists; flind++) { + m = vm_phys_alloc_domain_pages(domain, flind, pool, + order); + if (m != NULL) + return (m); + } } return (NULL); } @@ -464,11 +432,8 @@ vm_phys_alloc_pages(int pool, int order) vm_page_t vm_phys_alloc_freelist_pages(int flind, int pool, int order) { -#if MAXMEMDOM > 1 vm_page_t m; - int i, ndomains; -#endif - int domain; + int dom, domain; KASSERT(flind < VM_NFREELIST, ("vm_phys_alloc_freelist_pages: freelist %d is out of range", flind)); @@ -477,30 +442,13 @@ vm_phys_alloc_freelist_pages(int flind, KASSERT(order < VM_NFREEORDER, ("vm_phys_alloc_freelist_pages: order %d is out of range", order)); -#if MAXMEMDOM > 1 - /* - * This routine expects to be called with a VM_FREELIST_* constant. - * On a system with multiple domains we need to adjust the flind - * appropriately. If it is for VM_FREELIST_DEFAULT we need to - * iterate over the per-domain lists. - */ - domain = PCPU_GET(domain); - ndomains = vm_nfreelists - VM_NFREELIST + 1; - if (flind == VM_FREELIST_DEFAULT) { - m = NULL; - for (i = 0; i < ndomains; i++, flind++) { - m = vm_phys_alloc_domain_pages(domain, flind, pool, - order); - if (m != NULL) - break; - } - return (m); - } else if (flind > VM_FREELIST_DEFAULT) - flind += ndomains - 1; -#else - domain = 0; -#endif - return (vm_phys_alloc_domain_pages(domain, flind, pool, order)); + for (dom = 0; dom < vm_ndomains; dom++) { + domain = vm_rr_selectdomain(); + m = vm_phys_alloc_domain_pages(domain, flind, pool, order); + if (m != NULL) + return (m); + } + return (NULL); } static vm_page_t @@ -512,13 +460,11 @@ vm_phys_alloc_domain_pages(int domain, i vm_page_t m; mtx_assert(&vm_page_queue_free_mtx, MA_OWNED); - fl = (*vm_phys_lookup_lists[domain][flind])[pool]; + fl = &vm_phys_free_queues[domain][flind][pool][0]; for (oind = order; oind < VM_NFREEORDER; oind++) { m = TAILQ_FIRST(&fl[oind].pl); if (m != NULL) { - TAILQ_REMOVE(&fl[oind].pl, m, pageq); - fl[oind].lcnt--; - m->order = VM_NFREEORDER; + vm_freelist_rem(fl, m, oind); vm_phys_split_pages(m, oind, fl, order); return (m); } @@ -532,12 +478,10 @@ vm_phys_alloc_domain_pages(int domain, i */ for (oind = VM_NFREEORDER - 1; oind >= order; oind--) { for (pind = 0; pind < VM_NFREEPOOL; pind++) { - alt = (*vm_phys_lookup_lists[domain][flind])[pind]; + alt = &vm_phys_free_queues[domain][flind][pind][0]; m = TAILQ_FIRST(&alt[oind].pl); if (m != NULL) { - TAILQ_REMOVE(&alt[oind].pl, m, pageq); - alt[oind].lcnt--; - m->order = VM_NFREEORDER; + vm_freelist_rem(alt, m, oind); vm_phys_set_pool(pool, m, oind); vm_phys_split_pages(m, oind, fl, order); return (m); @@ -721,9 +665,7 @@ vm_phys_free_pages(vm_page_t m, int orde if (m_buddy->order != order) break; fl = (*seg->free_queues)[m_buddy->pool]; - TAILQ_REMOVE(&fl[order].pl, m_buddy, pageq); - fl[order].lcnt--; - m_buddy->order = VM_NFREEORDER; + vm_freelist_rem(fl, m_buddy, order); if (m_buddy->pool != m->pool) vm_phys_set_pool(m->pool, m_buddy, order); order++; @@ -731,10 +673,8 @@ vm_phys_free_pages(vm_page_t m, int orde m = &seg->first_page[atop(pa - seg->start)]; } while (order < VM_NFREEORDER - 1); } - m->order = order; fl = (*seg->free_queues)[m->pool]; - TAILQ_INSERT_TAIL(&fl[order].pl, m, pageq); - fl[order].lcnt++; + vm_freelist_add(fl, m, order, 1); } /* @@ -839,9 +779,7 @@ vm_phys_unfree_page(vm_page_t m) */ fl = (*seg->free_queues)[m_set->pool]; order = m_set->order; - TAILQ_REMOVE(&fl[order].pl, m_set, pageq); - fl[order].lcnt--; - m_set->order = VM_NFREEORDER; + vm_freelist_rem(fl, m_set, order); while (order > 0) { order--; pa_half = m_set->phys_addr ^ (1 << (PAGE_SHIFT + order)); @@ -851,9 +789,7 @@ vm_phys_unfree_page(vm_page_t m) m_tmp = m_set; m_set = &seg->first_page[atop(pa_half - seg->start)]; } - m_tmp->order = order; - TAILQ_INSERT_HEAD(&fl[order].pl, m_tmp, pageq); - fl[order].lcnt++; + vm_freelist_add(fl, m_tmp, order, 0); } KASSERT(m_set == m, ("vm_phys_unfree_page: fatal inconsistency")); return (TRUE); @@ -865,10 +801,13 @@ vm_phys_unfree_page(vm_page_t m) boolean_t vm_phys_zero_pages_idle(void) { - static struct vm_freelist *fl = vm_phys_free_queues[0][0]; + static struct vm_freelist *fl; static int flind, oind, pind; vm_page_t m, m_tmp; + int domain; + domain = vm_rr_selectdomain(); + fl = vm_phys_free_queues[domain][0][0]; mtx_assert(&vm_page_queue_free_mtx, MA_OWNED); for (;;) { TAILQ_FOREACH_REVERSE(m, &fl[oind].pl, pglist, pageq) { @@ -898,7 +837,7 @@ vm_phys_zero_pages_idle(void) if (flind == vm_nfreelists) flind = 0; } - fl = vm_phys_free_queues[flind][pind]; + fl = vm_phys_free_queues[domain][flind][pind]; } } } @@ -922,14 +861,9 @@ vm_phys_alloc_contig(u_long npages, vm_p vm_paddr_t pa, pa_last, size; vm_page_t m, m_ret; u_long npages_end; - int domain, flind, oind, order, pind; + int dom, domain, flind, oind, order, pind; mtx_assert(&vm_page_queue_free_mtx, MA_OWNED); -#if MAXMEMDOM > 1 - domain = PCPU_GET(domain); -#else - domain = 0; -#endif size = npages << PAGE_SHIFT; KASSERT(size != 0, ("vm_phys_alloc_contig: size must not be 0")); @@ -939,11 +873,13 @@ vm_phys_alloc_contig(u_long npages, vm_p ("vm_phys_alloc_contig: boundary must be a power of 2")); /* Compute the queue that is the best fit for npages. */ for (order = 0; (1 << order) < npages; order++); + dom = 0; +restartdom: + domain = vm_rr_selectdomain(); for (flind = 0; flind < vm_nfreelists; flind++) { for (oind = min(order, VM_NFREEORDER - 1); oind < VM_NFREEORDER; oind++) { for (pind = 0; pind < VM_NFREEPOOL; pind++) { - fl = (*vm_phys_lookup_lists[domain][flind]) - [pind]; + fl = &vm_phys_free_queues[domain][flind][pind][0]; TAILQ_FOREACH(m_ret, &fl[oind].pl, pageq) { /* * A free list may contain physical pages @@ -997,13 +933,13 @@ vm_phys_alloc_contig(u_long npages, vm_p } } } + if (++dom < vm_ndomains) + goto restartdom; return (NULL); done: for (m = m_ret; m < &m_ret[npages]; m = &m[1 << oind]) { fl = (*seg->free_queues)[m->pool]; - TAILQ_REMOVE(&fl[m->order].pl, m, pageq); - fl[m->order].lcnt--; - m->order = VM_NFREEORDER; + vm_freelist_rem(fl, m, m->order); } if (m_ret->pool != VM_FREEPOOL_DEFAULT) vm_phys_set_pool(VM_FREEPOOL_DEFAULT, m_ret, oind); @@ -1023,24 +959,28 @@ done: DB_SHOW_COMMAND(freepages, db_show_freepages) { struct vm_freelist *fl; - int flind, oind, pind; + int flind, oind, pind, dom; - for (flind = 0; flind < vm_nfreelists; flind++) { - db_printf("FREE LIST %d:\n" - "\n ORDER (SIZE) | NUMBER" - "\n ", flind); - for (pind = 0; pind < VM_NFREEPOOL; pind++) - db_printf(" | POOL %d", pind); - db_printf("\n-- "); - for (pind = 0; pind < VM_NFREEPOOL; pind++) - db_printf("-- -- "); - db_printf("--\n"); - for (oind = VM_NFREEORDER - 1; oind >= 0; oind--) { - db_printf(" %2.2d (%6.6dK)", oind, - 1 << (PAGE_SHIFT - 10 + oind)); - for (pind = 0; pind < VM_NFREEPOOL; pind++) { - fl = vm_phys_free_queues[flind][pind]; - db_printf(" | %6.6d", fl[oind].lcnt); + for (dom = 0; dom < vm_ndomains; dom++) { + db_printf("DOMAIN: %d\n", dom); + for (flind = 0; flind < vm_nfreelists; flind++) { + db_printf("FREE LIST %d:\n" + "\n ORDER (SIZE) | NUMBER" + "\n ", flind); + for (pind = 0; pind < VM_NFREEPOOL; pind++) + db_printf(" | POOL %d", pind); + db_printf("\n-- "); + for (pind = 0; pind < VM_NFREEPOOL; pind++) + db_printf("-- -- "); + db_printf("--\n"); + for (oind = VM_NFREEORDER - 1; oind >= 0; oind--) { + db_printf(" %2.2d (%6.6dK)", oind, + 1 << (PAGE_SHIFT - 10 + oind)); + for (pind = 0; pind < VM_NFREEPOOL; pind++) { + fl = vm_phys_free_queues[dom][flind][pind]; + db_printf(" | %6.6d", fl[oind].lcnt); + } + db_printf("\n"); } db_printf("\n"); } Modified: head/sys/vm/vm_phys.h ============================================================================== --- head/sys/vm/vm_phys.h Mon May 13 15:18:36 2013 (r250600) +++ head/sys/vm/vm_phys.h Mon May 13 15:40:51 2013 (r250601) @@ -48,6 +48,7 @@ struct mem_affinity { }; extern struct mem_affinity *mem_affinity; +extern int vm_ndomains; /* * The following functions are only to be used by the virtual memory system. Modified: head/sys/x86/acpica/srat.c ============================================================================== --- head/sys/x86/acpica/srat.c Mon May 13 15:18:36 2013 (r250600) +++ head/sys/x86/acpica/srat.c Mon May 13 15:40:51 2013 (r250601) @@ -244,33 +244,34 @@ static int renumber_domains(void) { int domains[VM_PHYSSEG_MAX]; - int ndomain, i, j, slot; + int i, j, slot; /* Enumerate all the domains. */ - ndomain = 0; + vm_ndomains = 0; for (i = 0; i < num_mem; i++) { /* See if this domain is already known. */ - for (j = 0; j < ndomain; j++) { + for (j = 0; j < vm_ndomains; j++) { if (domains[j] >= mem_info[i].domain) break; } - if (j < ndomain && domains[j] == mem_info[i].domain) + if (j < vm_ndomains && domains[j] == mem_info[i].domain) continue; /* Insert the new domain at slot 'j'. */ slot = j; - for (j = ndomain; j > slot; j--) + for (j = vm_ndomains; j > slot; j--) domains[j] = domains[j - 1]; domains[slot] = mem_info[i].domain; - ndomain++; - if (ndomain > MAXMEMDOM) { + vm_ndomains++; + if (vm_ndomains > MAXMEMDOM) { + vm_ndomains = 1; printf("SRAT: Too many memory domains\n"); return (EFBIG); } } /* Renumber each domain to its index in the sorted 'domains' list. */ - for (i = 0; i < ndomain; i++) { + for (i = 0; i < vm_ndomains; i++) { /* * If the domain is already the right value, no need * to renumber. @@ -286,6 +287,9 @@ renumber_domains(void) if (cpus[j].enabled && cpus[j].domain == domains[i]) cpus[j].domain = i; } + KASSERT(vm_ndomains > 0, + ("renumber_domains: invalid final vm_ndomains setup")); + return (0); } From owner-svn-src-all@FreeBSD.ORG Mon May 13 16:14:07 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id 935456B5 for ; Mon, 13 May 2013 16:14:07 +0000 (UTC) (envelope-from will@firepipe.net) Received: from mail-ie0-x229.google.com (mail-ie0-x229.google.com [IPv6:2607:f8b0:4001:c03::229]) by mx1.freebsd.org (Postfix) with ESMTP id 6509A3F4 for ; Mon, 13 May 2013 16:14:07 +0000 (UTC) Received: by mail-ie0-f169.google.com with SMTP id u16so12734293iet.14 for ; Mon, 13 May 2013 09:14:06 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20120113; h=mime-version:x-received:in-reply-to:references:date:message-id :subject:from:to:cc:content-type:x-gm-message-state; bh=YG/VRwhg4xUOgaqJJ+PA2PUzC6Ovt4Qi//lKGA4G2jo=; b=b44kVKW573PwnbcxY5mGfENw6PAa3OthWWRU3LY2taaNMQaYsFLZIBRO584I1OJYMa FWMlEBrEUhDS2sU+Plm3LyzEfe3rBhomBbtNzUunNE5/B/KrUcw6RWSApDH6sXh1UMWk igS4OnlMLOcyzIF/lbDnu1Q9pU+7edPxlDfZJ44enajWG8K8Wd+27jl3Cs/lxW9i1e5P hN0bZXk4yZnAvWjE2UoGg4qnxDO885ys7sk/ufQLJ4l3N1w+kpWQTk9hZZwsE3ssiaoh +PfNGME3LJBTTcFSKBRZR4WgZvxoeYbc2H+nYriBORwHEAWLL7Sxe6aEi/MM4n8sJe+k 8I1Q== MIME-Version: 1.0 X-Received: by 10.50.103.102 with SMTP id fv6mr10390335igb.6.1368461646591; Mon, 13 May 2013 09:14:06 -0700 (PDT) Received: by 10.231.49.74 with HTTP; Mon, 13 May 2013 09:14:06 -0700 (PDT) In-Reply-To: <201305122149.13566.jhb@freebsd.org> References: <201305091628.r49GSI33039873@svn.freebsd.org> <201305101533.26992.jhb@freebsd.org> <201305122149.13566.jhb@freebsd.org> Date: Mon, 13 May 2013 10:14:06 -0600 Message-ID: Subject: Re: svn commit: r250411 - in head/sys: conf kern sys From: Will Andrews To: John Baldwin X-Gm-Message-State: ALoCoQlNzqvUyVQCK+g2iWDyRs+du/twavZZgJ6XGj0X/yzBn2HehGvH3gOGp7mT/M4GGNaPWgsO Content-Type: text/plain; charset=UTF-8 X-Content-Filtered-By: Mailman/MimeDel 2.1.14 Cc: Marcel Moolenaar , svn-src-all@freebsd.org, Marcel Moolenaar , attilio@freebsd.org, src-committers@freebsd.org, svn-src-head@freebsd.org X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 13 May 2013 16:14:07 -0000 On Sun, May 12, 2013 at 7:49 PM, John Baldwin wrote: > Also, while LK_NOWITESS works fine for lockmgr's API (it already takes a > flag > argument), having that sort of thing in our other lock APIs is messier > (they > generally do not have flags). This is why a per-thread flag seemed > simpler to > me for this as you don't have to change umpteen locking APIs to add a new > flags field. > Another problem is that approach is far too blunt; in most cases false positive LORs are specific to a particular pair of instances of locks. You'd probably still want to receive witness notifications for other LORs. --Will. From owner-svn-src-all@FreeBSD.ORG Mon May 13 16:58:05 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id 41212597 for ; Mon, 13 May 2013 16:58:05 +0000 (UTC) (envelope-from will@firepipe.net) Received: from mail-ie0-x22c.google.com (mail-ie0-x22c.google.com [IPv6:2607:f8b0:4001:c03::22c]) by mx1.freebsd.org (Postfix) with ESMTP id 135398FC for ; Mon, 13 May 2013 16:58:05 +0000 (UTC) Received: by mail-ie0-f172.google.com with SMTP id 16so13039941iea.3 for ; Mon, 13 May 2013 09:58:04 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20120113; h=mime-version:x-received:in-reply-to:references:date:message-id :subject:from:to:cc:content-type:x-gm-message-state; bh=j/euV2TD5CtvzDWR4664HMqKmfZ2ytMuVPpg9CN7+U8=; b=jyDVeyu8GmzaackMqLJB0g5CVOeInYhA/PnpDXQzsIjSQbQTp/s3KRiDtHinCPQIKz RYKpe5FceeWFN+Cr1MF+tEZAkVXgVz696x/ucXaGoSbwsXjpbGX2roXYHgjS9FV+Db+C izUWbHlKyXWSkgQfbKpr/tZ3qHVv1/ylmXjr6nFqhBxLAIu3Pzok4iKwmJC3iEoMMGEB q7/2AgOMkELAqIR9WudqIUxgQhVTIis5Sg3dR4viKdbLIUweptsTtcwvMD/F4xPEVEMK MCr/Zu3XQA/ZLjgz5DOlTVkkO5s/riMCS/SjA9RfzuDGaTbyiQkS6d/fgeSLREzQ87WZ CuDg== MIME-Version: 1.0 X-Received: by 10.50.103.102 with SMTP id fv6mr10528310igb.6.1368464284683; Mon, 13 May 2013 09:58:04 -0700 (PDT) Received: by 10.231.49.74 with HTTP; Mon, 13 May 2013 09:58:04 -0700 (PDT) In-Reply-To: <518F320D.3070304@mu.org> References: <201305091628.r49GSI33039873@svn.freebsd.org> <518F320D.3070304@mu.org> Date: Mon, 13 May 2013 10:58:04 -0600 Message-ID: Subject: Re: svn commit: r250411 - in head/sys: conf kern sys From: Will Andrews To: Alfred Perlstein X-Gm-Message-State: ALoCoQkp8pRlHxLiuWu9r4FjOUNdSXLFx0wMW0w861syjoVt72QQItTXzQQkV6DVkEBnjyEoj5/4 Content-Type: text/plain; charset=UTF-8 X-Content-Filtered-By: Mailman/MimeDel 2.1.14 Cc: Marcel Moolenaar , jhb@freebsd.org, svn-src-all@freebsd.org, alfred@freebsd.org, attilio@freebsd.org, src-committers@freebsd.org, Jeff Roberson , svn-src-head@freebsd.org X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 13 May 2013 16:58:05 -0000 On Sun, May 12, 2013 at 12:09 AM, Alfred Perlstein wrote: > Can we just admit to ourselves that tweaks to debugging macros/printing > and WITNESS are our kernel developer's "bikeshed zone" and get over the > fact that people's needs may diverge and changing non-default behavior in > non-critical paths is not going to be the death of the kernel as we know it? > > I could certainly believe that this sort of thing needs long and thorough > discussion if it wasn't the equivalent of style tweaks to manpages. > > Let's leave the long and lengthy discussions to things that matter such as > standards compliance, ABI, API and really cool performance and stability > stuff. Except that this is *not* the equivalent of style tweaks. I'm not sure how you got that from Jeff's email. False positive LORs results in people ignoring all LORs, including real ones. And that impacts stability. Especially if you are trying to implement performance improvements or fix bugs; in that case, the LORs act as a safeguard against violating existing object relationship assumptions. Having worked on ZFS for a while, I can say that many (if not most) of the LORs reported there that are false positives are because the locks represent objects that are frequently and legitimately related to each other in reverse orders, due to reuse of object types at different points in the overall hierarchy. So, I agree that the biggest issue is that witness's model of comparing strings is insufficient for representing more complex lock relationships. In ZFS, in most cases, the locks are acquired after having already (in debug builds) checked these relationships. It seems appropriate, therefore, that witness should be improved by adding the ability to bless specific object relationships on a per-lock entry basis, so that we continue to be notified about *legitimate* LORs, at every call site and between every pair of object types. It also seems best to add a new API for this purpose, so that it can be used regardless of which lock type is being used, without having to modify all existing lock calls. This does mean that code in FreeBSD would need to independently verify the object relationships, but doing so is, IMHO, a lot easier to improve upon than folding this functionality into existing APIs by adding more arguments. --Will. From owner-svn-src-all@FreeBSD.ORG Mon May 13 18:01:42 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id 2CCCD763; Mon, 13 May 2013 18:01:42 +0000 (UTC) (envelope-from jhb@FreeBSD.org) Received: from bigwig.baldwin.cx (bigwig.baldwin.cx [IPv6:2001:470:1f11:75::1]) by mx1.freebsd.org (Postfix) with ESMTP id 0A498DDD; Mon, 13 May 2013 18:01:42 +0000 (UTC) Received: from dhcp-10-2-212-236.hudson-trading.com (unknown [209.249.190.124]) by bigwig.baldwin.cx (Postfix) with ESMTPSA id 72D89B926; Mon, 13 May 2013 14:01:41 -0400 (EDT) Message-ID: <51912A88.8040609@FreeBSD.org> Date: Mon, 13 May 2013 14:01:44 -0400 From: John Baldwin User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.7; rv:17.0) Gecko/20130328 Thunderbird/17.0.5 MIME-Version: 1.0 To: Attilio Rao Subject: Re: svn commit: r250601 - in head/sys: sys vm x86/acpica References: <201305131540.r4DFepou074563@svn.freebsd.org> In-Reply-To: <201305131540.r4DFepou074563@svn.freebsd.org> Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit X-Greylist: Sender succeeded SMTP AUTH, not delayed by milter-greylist-4.2.7 (bigwig.baldwin.cx); Mon, 13 May 2013 14:01:41 -0400 (EDT) Cc: svn-src-head@freebsd.org, svn-src-all@freebsd.org, src-committers@freebsd.org X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 13 May 2013 18:01:42 -0000 On 5/13/13 11:40 AM, Attilio Rao wrote: > Author: attilio > Date: Mon May 13 15:40:51 2013 > New Revision: 250601 > URL: http://svnweb.freebsd.org/changeset/base/250601 > > Log: > o Add accessor functions to add and remove pages from a specific > freelist. > o Split the pool of free pages queues really by domain and not rely on > definition of VM_RAW_NFREELIST. > o For MAXMEMDOM > 1, wrap the RR allocation logic into a specific > function that is called when calculating the allocation domain. > The RR counter is kept, currently, per-thread. > In the future it is expected that such function evolves in a real > policy decision referee, based on specific informations retrieved by > per-thread and per-vm_object attributes. > o Add the concept of "probed domains" under the form of vm_ndomains. > It is responsibility for every architecture willing to support multiple > memory domains to correctly probe vm_ndomains along with mem_affinity > segments attributes. Those two values are supposed to remain always > consistent. > Please also note that vm_ndomains and td_dom_rr_idx are both int > because segments already store domains as int. Ideally u_int would > have much more sense. Probabilly this should be cleaned up in the > future. > o Apply RR domain selection also to vm_phys_zero_pages_idle(). My other comments aside: to be clear (this log message doesn't make it clear I think): this changes our NUMA allocation policy to be round-robin instead of first touch (which is probably better for the general case). Also, if you want to honor SLIT, you will need to put back something like the lookup lists from before, though in this case it can just be a simple list of domains for each domain. -- John Baldwin From owner-svn-src-all@FreeBSD.ORG Mon May 13 18:13:52 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id 8D3465C8; Mon, 13 May 2013 18:13:52 +0000 (UTC) (envelope-from joel@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id 7C7F4F4A; Mon, 13 May 2013 18:13:52 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.6/8.14.6) with ESMTP id r4DIDqSn028103; Mon, 13 May 2013 18:13:52 GMT (envelope-from joel@svn.freebsd.org) Received: (from joel@localhost) by svn.freebsd.org (8.14.6/8.14.5/Submit) id r4DIDoYD028095; Mon, 13 May 2013 18:13:50 GMT (envelope-from joel@svn.freebsd.org) Message-Id: <201305131813.r4DIDoYD028095@svn.freebsd.org> From: Joel Dahl Date: Mon, 13 May 2013 18:13:50 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r250604 - in head: sbin/ifconfig sbin/routed share/man/man5 share/man/man7 usr.sbin/portsnap/portsnap usr.sbin/pw usr.sbin/uhsoctl X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 13 May 2013 18:13:52 -0000 Author: joel (doc committer) Date: Mon May 13 18:13:50 2013 New Revision: 250604 URL: http://svnweb.freebsd.org/changeset/base/250604 Log: mdoc sweep Modified: head/sbin/ifconfig/ifconfig.8 head/sbin/routed/routed.8 head/share/man/man5/pf.conf.5 head/share/man/man7/firewall.7 head/share/man/man7/hier.7 head/usr.sbin/portsnap/portsnap/portsnap.8 head/usr.sbin/pw/pw.conf.5 head/usr.sbin/uhsoctl/uhsoctl.1 Modified: head/sbin/ifconfig/ifconfig.8 ============================================================================== --- head/sbin/ifconfig/ifconfig.8 Mon May 13 15:51:51 2013 (r250603) +++ head/sbin/ifconfig/ifconfig.8 Mon May 13 18:13:50 2013 (r250604) @@ -1054,7 +1054,9 @@ can be used on a channel are defined by Country/Region codes are specified as a 2-character abbreviation defined by ISO 3166 or using a longer, but possibly ambiguous, spelling; e.g., "ES" and "Spain". -The set of country codes are taken from /etc/regdomain.xml and can also +The set of country codes are taken from +.Pa /etc/regdomain.xml +and can also be viewed with the ``list countries'' request. Note that not all devices support changing the country code from a default setting; typically stored in EEPROM. @@ -1072,7 +1074,9 @@ according to a least-congested criteria. DFS support is mandatory for some 5GHz frequencies in certain locales (e.g., ETSI). By default DFS is enabled according to the regulatory definitions -specified in /etc/regdomain.xml and the current country code, regdomain, +specified in +.Pa /etc/regdomain.xml +and the current country code, regdomain, and channel. Note the underlying device (and driver) must support radar detection for full DFS support to work. @@ -1578,7 +1582,9 @@ for operation. In particular the set of available channels, how the wireless device will operation on the channels, and the maximum transmit power that can be used on a channel are defined by this setting. -Regdomain codes (SKU's) are taken from /etc/regdomain.xml and can also +Regdomain codes (SKU's) are taken from +.Pa /etc/regdomain.xml +and can also be viewed with the ``list countries'' request. Note that not all devices support changing the regdomain from a default setting; typically stored in EEPROM. Modified: head/sbin/routed/routed.8 ============================================================================== --- head/sbin/routed/routed.8 Mon May 13 15:51:51 2013 (r250603) +++ head/sbin/routed/routed.8 Mon May 13 18:13:50 2013 (r250604) @@ -576,7 +576,7 @@ Incoming packets can carry any password be valid within the next 24 hours, or that was valid within the preceding 24 hours. To protect the secrets, the passwd settings are valid only in the -.Em /etc/gateways +.Pa /etc/gateways file and only when that file is readable only by UID 0. .It Cm md5_passwd Ns \&= Ns Ar XXX|KeyID[start|stop] specifies a RIPv2 MD5 password. Modified: head/share/man/man5/pf.conf.5 ============================================================================== --- head/share/man/man5/pf.conf.5 Mon May 13 15:51:51 2013 (r250603) +++ head/share/man/man5/pf.conf.5 Mon May 13 18:13:50 2013 (r250604) @@ -1461,7 +1461,7 @@ and For a list of all the protocol name to number mappings used by .Xr pfctl 8 , see the file -.Em /etc/protocols . +.Pa /etc/protocols . .It Xo .Ar from Aq Ar source .Ar port Aq Ar source Modified: head/share/man/man7/firewall.7 ============================================================================== --- head/share/man/man7/firewall.7 Mon May 13 15:51:51 2013 (r250603) +++ head/share/man/man7/firewall.7 Mon May 13 18:13:50 2013 (r250604) @@ -91,7 +91,7 @@ a firewall in the sample firewall sectio .Sh IPFW KERNEL CONFIGURATION You do not need to create a custom kernel to use the IP firewalling features. If you enable firewalling in your -.Em /etc/rc.conf +.Pa /etc/rc.conf (see below), the ipfw kernel module will be loaded automatically when necessary. However, @@ -103,7 +103,7 @@ option set. If compiled in the kernel, ipfw denies all packets by default, which means that, if you do not load in a permissive ruleset via -.Em /etc/rc.conf , +.Pa /etc/rc.conf , rebooting into your new kernel will take the network offline. This can prevent you from being able to access your system if you are not sitting at the console. Modified: head/share/man/man7/hier.7 ============================================================================== --- head/share/man/man7/hier.7 Mon May 13 15:51:51 2013 (r250603) +++ head/share/man/man7/hier.7 Mon May 13 18:13:50 2013 (r250604) @@ -434,15 +434,31 @@ local executables, libraries, etc. Also used as the default destination for the .Fx ports framework. -Within local/, the general layout sketched out by +Within +.Pa local/ , +the general layout sketched out by .Nm -for /usr +for +.Pa /usr should be used. -Exceptions are the man directory (directly under local/ -rather than under local/share/), ports documentation (in share/doc//), -and /usr/local/etc (mimics /etc). +Exceptions are the +.Pa man +directory +.Po directly under +.Pa local/ +rather than under +.Pa local/share/ Ns Pc , +ports documentation +.Po in +.Pa share/doc// Ns Pc , +and +.Pa /usr/local/etc +.Po mimics +.Pa /etc Ns Pc . .It Pa obj/ -architecture-specific target tree produced by building the /usr/src tree +architecture-specific target tree produced by building the +.Pa /usr/src +tree .It Pa ports/ The .Fx @@ -633,38 +649,48 @@ source code for contributed software .It Pa crypto/ source code for contributed cryptography software .It Pa etc/ -source code for files in /etc +source code for files in +.Pa /etc .It Pa games/ -source code for files in /usr/games +source code for files in +.Pa /usr/games .It Pa gnu/ Utilities covered by the GNU General Public License .It Pa include/ -source code for files in /usr/include +source code for files in +.Pa /usr/include .It Pa kerberos5/ build infrastructure for kerberos version 5 .It Pa lib/ -source code for files in /usr/lib +source code for files in +.Pa /usr/lib .It Pa libexec/ -source code for files in /usr/libexec +source code for files in +.Pa /usr/libexec .It Pa release/ files required to produce a .Fx release .It Pa sbin/ -source code for files in /sbin +source code for files in +.Pa /sbin .It Pa secure/ -build directory for files in /usr/src/crypto +build directory for files in +.Pa /usr/src/crypto .It Pa share/ -source for files in /usr/share +source for files in +.Pa /usr/share .It Pa sys/ kernel source code .It Pa tools/ tools used for maintenance and testing of .Fx .It Pa usr.bin/ -source code for files in /usr/bin +source code for files in +.Pa /usr/bin .It Pa usr.sbin/ -source code for files in /usr/sbin +source code for files in +.Pa /usr/sbin .El .El .It Pa /var/ Modified: head/usr.sbin/portsnap/portsnap/portsnap.8 ============================================================================== --- head/usr.sbin/portsnap/portsnap/portsnap.8 Mon May 13 15:51:51 2013 (r250603) +++ head/usr.sbin/portsnap/portsnap/portsnap.8 Mon May 13 18:13:50 2013 (r250604) @@ -169,7 +169,9 @@ If your clock is set to local time, addi .Pp .Dl 0 3 * * * root /usr/sbin/portsnap cron .Pp -to /etc/crontab is a good way to make sure you always have +to +.Pa /etc/crontab +is a good way to make sure you always have an up-to-date snapshot of the ports tree available which can quickly be extracted into .Pa /usr/ports . Modified: head/usr.sbin/pw/pw.conf.5 ============================================================================== --- head/usr.sbin/pw/pw.conf.5 Mon May 13 15:51:51 2013 (r250603) +++ head/usr.sbin/pw/pw.conf.5 Mon May 13 18:13:50 2013 (r250604) @@ -32,7 +32,7 @@ .Nd format of the pw.conf configuration file .Sh DESCRIPTION The file -.In /etc/pw.conf +.Pa /etc/pw.conf contains configuration data for the .Xr pw 8 utility. Modified: head/usr.sbin/uhsoctl/uhsoctl.1 ============================================================================== --- head/usr.sbin/uhsoctl/uhsoctl.1 Mon May 13 15:51:51 2013 (r250603) +++ head/usr.sbin/uhsoctl/uhsoctl.1 Mon May 13 18:13:50 2013 (r250604) @@ -50,7 +50,7 @@ is a small connection utility for Option N.V. devices that are based on Options packet interface and uses proprietary AT_* calls to establish connections. The utility (tries to) configure both default route and name servers -(/etc/resolv.conf). +.Po Pa /etc/resolv.conf Pc . .Pp By default .Nm @@ -76,8 +76,13 @@ Specify username. .It Fl k Ar password Specify username. .It Fl r Ar path -Path to resolv.conf, default /etc/resolv.conf. -Use /dev/null to disable updating of name servers. +Path to +.Pa resolv.conf , +default +.Pa /etc/resolv.conf . +Use +.Pa /dev/null +to disable updating of name servers. .It Fl f Ar path Explicitly set the serial port to use as controlling terminal. Might be needed if the automatic detection fails. From owner-svn-src-all@FreeBSD.ORG Mon May 13 18:34:33 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id BD9905DE; Mon, 13 May 2013 18:34:33 +0000 (UTC) (envelope-from marcel@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id AF3A9101; Mon, 13 May 2013 18:34:33 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.6/8.14.6) with ESMTP id r4DIYX7I035167; Mon, 13 May 2013 18:34:33 GMT (envelope-from marcel@svn.freebsd.org) Received: (from marcel@localhost) by svn.freebsd.org (8.14.6/8.14.5/Submit) id r4DIYXH7035166; Mon, 13 May 2013 18:34:33 GMT (envelope-from marcel@svn.freebsd.org) Message-Id: <201305131834.r4DIYXH7035166@svn.freebsd.org> From: Marcel Moolenaar Date: Mon, 13 May 2013 18:34:33 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r250605 - head/usr.sbin/makefs X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 13 May 2013 18:34:33 -0000 Author: marcel Date: Mon May 13 18:34:33 2013 New Revision: 250605 URL: http://svnweb.freebsd.org/changeset/base/250605 Log: Set st_nlink in the stat structure within the inode to 1 as well. The cd9660 file system uses that field for the link count and it was 0. This impacts pwd_mkdb(8) as it checks for st_nlink not being 0 as part of closing a race. Modified: head/usr.sbin/makefs/mtree.c Modified: head/usr.sbin/makefs/mtree.c ============================================================================== --- head/usr.sbin/makefs/mtree.c Mon May 13 18:13:50 2013 (r250604) +++ head/usr.sbin/makefs/mtree.c Mon May 13 18:34:33 2013 (r250605) @@ -1050,6 +1050,7 @@ read_mtree(const char *fname, fsnode *no bzero(&mtree_global_inode, sizeof(mtree_global_inode)); mtree_global.inode = &mtree_global_inode; mtree_global_inode.nlink = 1; + mtree_global_inode.st.st_nlink = 1; mtree_global_inode.st.st_atime = mtree_global_inode.st.st_ctime = mtree_global_inode.st.st_mtime = time(NULL); errors = warnings = 0; From owner-svn-src-all@FreeBSD.ORG Mon May 13 18:56:04 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id E0C4AFFC; Mon, 13 May 2013 18:56:04 +0000 (UTC) (envelope-from adrian@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id C1F1B204; Mon, 13 May 2013 18:56:04 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.6/8.14.6) with ESMTP id r4DIu4eS042190; Mon, 13 May 2013 18:56:04 GMT (envelope-from adrian@svn.freebsd.org) Received: (from adrian@localhost) by svn.freebsd.org (8.14.6/8.14.5/Submit) id r4DIu4rM042189; Mon, 13 May 2013 18:56:04 GMT (envelope-from adrian@svn.freebsd.org) Message-Id: <201305131856.r4DIu4rM042189@svn.freebsd.org> From: Adrian Chadd Date: Mon, 13 May 2013 18:56:04 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r250606 - head/sys/dev/ath X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 13 May 2013 18:56:05 -0000 Author: adrian Date: Mon May 13 18:56:04 2013 New Revision: 250606 URL: http://svnweb.freebsd.org/changeset/base/250606 Log: Begin tidying up the reassociation and node sleep/wakeup paths. * Move the node sleep/wake state under the TX lock rather than the node lock. Let's leave the node lock protecting rate control only for now. * When reassociating, various state needs to be cleared. For example, the aggregate session needs to be torn down, including any pending aggregation negotiation and BAR TX waiting. * .. and we need to do a "cleanup" pass since frames in the hardware TX queue need to be transmitted. Modify ath_tx_tid_cleanup() to be called with the TX lock held and push frames into a completion list. This allows for the cleanup to be done atomically for all TIDs in a node rather than grabbing and releasing the TX lock each time. Modified: head/sys/dev/ath/if_ath.c Modified: head/sys/dev/ath/if_ath.c ============================================================================== --- head/sys/dev/ath/if_ath.c Mon May 13 18:34:33 2013 (r250605) +++ head/sys/dev/ath/if_ath.c Mon May 13 18:56:04 2013 (r250606) @@ -3845,8 +3845,11 @@ ath_tx_default_comp(struct ath_softc *sc * XXX TODO: during drain, ensure that the callback is * being called so we get a chance to update the TIM. */ - if (bf->bf_node) + if (bf->bf_node) { + ATH_TX_LOCK(sc); ath_tx_update_tim(sc, bf->bf_node, 0); + ATH_TX_UNLOCK(sc); + } /* * Do any tx complete callback. Note this must @@ -5380,6 +5383,31 @@ ath_newassoc(struct ieee80211_node *ni, (vap->iv_flags & IEEE80211_F_PRIVACY) == 0 && sc->sc_hasclrkey && ni->ni_ucastkey.wk_keyix == IEEE80211_KEYIX_NONE) ath_setup_stationkey(ni); + + /* + * If we're reassociating, make sure that any paused queues + * get unpaused. + * + * Now, we may hvae frames in the hardware queue for this node. + * So if we are reassociating and there are frames in the queue, + * we need to go through the cleanup path to ensure that they're + * marked as non-aggregate. + */ + if (! isnew) { + device_printf(sc->sc_dev, + "%s: %6D: reassoc; is_powersave=%d\n", + __func__, + ni->ni_macaddr, + ":", + an->an_is_powersave); + + /* XXX for now, we can't hold the lock across assoc */ + ath_tx_node_reassoc(sc, an); + + /* XXX for now, we can't hold the lock across wakeup */ + if (an->an_is_powersave) + ath_tx_node_wakeup(sc, an); + } } static int @@ -5959,12 +5987,7 @@ ath_node_set_tim(struct ieee80211_node * struct ath_vap *avp = ATH_VAP(ni->ni_vap); int changed = 0; - ATH_NODE_UNLOCK_ASSERT(an); - - /* - * For now, just track and then update the TIM. - */ - ATH_NODE_LOCK(an); + ATH_TX_LOCK(sc); an->an_stack_psq = enable; /* @@ -5975,7 +5998,7 @@ ath_node_set_tim(struct ieee80211_node * * and AP/IBSS node power save. */ if (avp->av_set_tim == NULL) { - ATH_NODE_UNLOCK(an); + ATH_TX_UNLOCK(sc); return (0); } @@ -5997,13 +6020,13 @@ ath_node_set_tim(struct ieee80211_node * DPRINTF(sc, ATH_DEBUG_NODE_PWRSAVE, "%s: an=%p, enable=%d, tim_set=1, ignoring\n", __func__, an, enable); - ATH_NODE_UNLOCK(an); + ATH_TX_UNLOCK(sc); } else if (enable) { DPRINTF(sc, ATH_DEBUG_NODE_PWRSAVE, "%s: an=%p, enable=%d, enabling TIM\n", __func__, an, enable); an->an_tim_set = 1; - ATH_NODE_UNLOCK(an); + ATH_TX_UNLOCK(sc); changed = avp->av_set_tim(ni, enable); } else if (atomic_load_acq_int(&an->an_swq_depth) == 0) { /* disable */ @@ -6011,7 +6034,7 @@ ath_node_set_tim(struct ieee80211_node * "%s: an=%p, enable=%d, an_swq_depth == 0, disabling\n", __func__, an, enable); an->an_tim_set = 0; - ATH_NODE_UNLOCK(an); + ATH_TX_UNLOCK(sc); changed = avp->av_set_tim(ni, enable); } else if (! an->an_is_powersave) { /* @@ -6021,7 +6044,7 @@ ath_node_set_tim(struct ieee80211_node * "%s: an=%p, enable=%d, an_pwrsave=0, disabling\n", __func__, an, enable); an->an_tim_set = 0; - ATH_NODE_UNLOCK(an); + ATH_TX_UNLOCK(sc); changed = avp->av_set_tim(ni, enable); } else { /* @@ -6029,7 +6052,7 @@ ath_node_set_tim(struct ieee80211_node * * software queue isn't empty, so don't clear the TIM bit * for now. */ - ATH_NODE_UNLOCK(an); + ATH_TX_UNLOCK(sc); DPRINTF(sc, ATH_DEBUG_NODE_PWRSAVE, "%s: enable=%d, an_swq_depth > 0, ignoring\n", __func__, enable); @@ -6094,7 +6117,7 @@ ath_tx_update_tim(struct ath_softc *sc, if (avp->av_set_tim == NULL) return; - ATH_NODE_UNLOCK_ASSERT(an); + ATH_TX_LOCK_ASSERT(sc); if (enable) { /* @@ -6104,7 +6127,6 @@ ath_tx_update_tim(struct ath_softc *sc, if (atomic_load_acq_int(&an->an_swq_depth) == 0) return; - ATH_NODE_LOCK(an); if (an->an_is_powersave && an->an_tim_set == 0 && atomic_load_acq_int(&an->an_swq_depth) != 0) { @@ -6112,10 +6134,7 @@ ath_tx_update_tim(struct ath_softc *sc, "%s: an=%p, swq_depth>0, tim_set=0, set!\n", __func__, an); an->an_tim_set = 1; - ATH_NODE_UNLOCK(an); (void) avp->av_set_tim(ni, 1); - } else { - ATH_NODE_UNLOCK(an); } } else { /* @@ -6124,7 +6143,6 @@ ath_tx_update_tim(struct ath_softc *sc, if (atomic_load_acq_int(&an->an_swq_depth) != 0) return; - ATH_NODE_LOCK(an); if (an->an_is_powersave && an->an_stack_psq == 0 && an->an_tim_set == 1 && @@ -6134,10 +6152,7 @@ ath_tx_update_tim(struct ath_softc *sc, " clear!\n", __func__, an); an->an_tim_set = 0; - ATH_NODE_UNLOCK(an); (void) avp->av_set_tim(ni, 0); - } else { - ATH_NODE_UNLOCK(an); } } #else From owner-svn-src-all@FreeBSD.ORG Mon May 13 18:57:19 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id 49F971FF; Mon, 13 May 2013 18:57:19 +0000 (UTC) (envelope-from adrian@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id 3CD3920B; Mon, 13 May 2013 18:57:19 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.6/8.14.6) with ESMTP id r4DIvJmg042424; Mon, 13 May 2013 18:57:19 GMT (envelope-from adrian@svn.freebsd.org) Received: (from adrian@localhost) by svn.freebsd.org (8.14.6/8.14.5/Submit) id r4DIvJER042423; Mon, 13 May 2013 18:57:19 GMT (envelope-from adrian@svn.freebsd.org) Message-Id: <201305131857.r4DIvJER042423@svn.freebsd.org> From: Adrian Chadd Date: Mon, 13 May 2013 18:57:19 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r250607 - head/sys/dev/ath X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 13 May 2013 18:57:19 -0000 Author: adrian Date: Mon May 13 18:57:18 2013 New Revision: 250607 URL: http://svnweb.freebsd.org/changeset/base/250607 Log: This lock only protects the rate control state for now, mention this. Modified: head/sys/dev/ath/if_athvar.h Modified: head/sys/dev/ath/if_athvar.h ============================================================================== --- head/sys/dev/ath/if_athvar.h Mon May 13 18:56:04 2013 (r250606) +++ head/sys/dev/ath/if_athvar.h Mon May 13 18:57:18 2013 (r250607) @@ -178,7 +178,7 @@ struct ath_node { struct ath_buf *an_ff_buf[WME_NUM_AC]; /* ff staging area */ struct ath_tid an_tid[IEEE80211_TID_SIZE]; /* per-TID state */ char an_name[32]; /* eg "wlan0_a1" */ - struct mtx an_mtx; /* protecting the ath_node state */ + struct mtx an_mtx; /* protecting the rate control state */ uint32_t an_swq_depth; /* how many SWQ packets for this node */ int clrdmask; /* has clrdmask been set */ From owner-svn-src-all@FreeBSD.ORG Mon May 13 19:02:22 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id E330361C; Mon, 13 May 2013 19:02:22 +0000 (UTC) (envelope-from adrian@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id C5ADE25B; Mon, 13 May 2013 19:02:22 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.6/8.14.6) with ESMTP id r4DJ2MXH045127; Mon, 13 May 2013 19:02:22 GMT (envelope-from adrian@svn.freebsd.org) Received: (from adrian@localhost) by svn.freebsd.org (8.14.6/8.14.5/Submit) id r4DJ2MRB045125; Mon, 13 May 2013 19:02:22 GMT (envelope-from adrian@svn.freebsd.org) Message-Id: <201305131902.r4DJ2MRB045125@svn.freebsd.org> From: Adrian Chadd Date: Mon, 13 May 2013 19:02:22 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r250608 - head/sys/dev/ath X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 13 May 2013 19:02:23 -0000 Author: adrian Date: Mon May 13 19:02:22 2013 New Revision: 250608 URL: http://svnweb.freebsd.org/changeset/base/250608 Log: Oops, commit the other half of r250606. Modified: head/sys/dev/ath/if_ath_tx.c head/sys/dev/ath/if_ath_tx.h Modified: head/sys/dev/ath/if_ath_tx.c ============================================================================== --- head/sys/dev/ath/if_ath_tx.c Mon May 13 18:57:18 2013 (r250607) +++ head/sys/dev/ath/if_ath_tx.c Mon May 13 19:02:22 2013 (r250608) @@ -3556,6 +3556,72 @@ ath_tx_tid_drain(struct ath_softc *sc, s } /* + * Reset the TID state. This must be only called once the node has + * had its frames flushed from this TID, to ensure that no other + * pause / unpause logic can kick in. + */ +static void +ath_tx_tid_reset(struct ath_softc *sc, struct ath_tid *tid) +{ + +#if 0 + tid->bar_wait = tid->bar_tx = tid->isfiltered = 0; + tid->paused = tid->sched = tid->addba_tx_pending = 0; + tid->incomp = tid->cleanup_inprogress = 0; +#endif + + /* + * If we have a bar_wait set, we need to unpause the TID + * here. Otherwise once cleanup has finished, the TID won't + * have the right paused counter. + * + * XXX I'm not going through resume here - I don't want the + * node to be rescheuled just yet. This however should be + * methodized! + */ + if (tid->bar_wait) { + if (tid->paused > 0) { + tid->paused --; + } + } + + /* + * XXX same with a currently filtered TID. + * + * Since this is being called during a flush, we assume that + * the filtered frame list is actually empty. + * + * XXX TODO: add in a check to ensure that the filtered queue + * depth is actually 0! + */ + if (tid->isfiltered) { + if (tid->paused > 0) { + tid->paused --; + } + } + + /* + * Clear BAR, filtered frames, scheduled and ADDBA pending. + * The TID may be going through cleanup from the last association + * where things in the BAW are still in the hardware queue. + */ + tid->bar_wait = 0; + tid->bar_tx = 0; + tid->isfiltered = 0; + tid->sched = 0; + tid->addba_tx_pending = 0; + + /* + * XXX TODO: it may just be enough to walk the HWQs and mark + * frames for that node as non-aggregate; or mark the ath_node + * with something that indicates that aggregation is no longer + * occuring. Then we can just toss the BAW complaints and + * do a complete hard reset of state here - no pause, no + * complete counter, etc. + */ +} + +/* * Flush all software queued packets for the given node. * * This occurs when a completion handler frees the last buffer @@ -3582,6 +3648,8 @@ ath_tx_node_flush(struct ath_softc *sc, ath_tx_tid_drain(sc, an, atid, &bf_cq); /* Remove this tid from the list of active tids */ ath_tx_tid_unsched(sc, atid); + /* Reset the per-TID pause, BAR, etc state */ + ath_tx_tid_reset(sc, atid); } ATH_TX_UNLOCK(sc); @@ -3748,19 +3816,18 @@ ath_tx_comp_cleanup_unaggr(struct ath_so * The caller is responsible for pausing the TID. */ static void -ath_tx_tid_cleanup(struct ath_softc *sc, struct ath_node *an, int tid) +ath_tx_tid_cleanup(struct ath_softc *sc, struct ath_node *an, int tid, + ath_bufhead *bf_cq) { struct ath_tid *atid = &an->an_tid[tid]; struct ieee80211_tx_ampdu *tap; struct ath_buf *bf, *bf_next; - ath_bufhead bf_cq; + + ATH_TX_LOCK_ASSERT(sc); DPRINTF(sc, ATH_DEBUG_SW_TX_BAW, "%s: TID %d: called\n", __func__, tid); - TAILQ_INIT(&bf_cq); - ATH_TX_LOCK(sc); - /* * Move the filtered frames to the TX queue, before * we run off and discard/process things. @@ -3795,7 +3862,7 @@ ath_tx_tid_cleanup(struct ath_softc *sc, * Call the default completion handler with "fail" just * so upper levels are suitably notified about this. */ - TAILQ_INSERT_TAIL(&bf_cq, bf, bf_list); + TAILQ_INSERT_TAIL(bf_cq, bf, bf_list); bf = bf_next; continue; } @@ -3840,13 +3907,8 @@ ath_tx_tid_cleanup(struct ath_softc *sc, DPRINTF(sc, ATH_DEBUG_SW_TX_CTRL, "%s: TID %d: cleanup needed: %d packets\n", __func__, tid, atid->incomp); - ATH_TX_UNLOCK(sc); - /* Handle completing frames and fail them */ - while ((bf = TAILQ_FIRST(&bf_cq)) != NULL) { - TAILQ_REMOVE(&bf_cq, bf, bf_list); - ath_tx_default_comp(sc, bf, 1); - } + /* Owner now must free completed frames */ } static struct ath_buf * @@ -5284,6 +5346,8 @@ ath_addba_stop(struct ieee80211_node *ni int tid = tap->txa_tid; struct ath_node *an = ATH_NODE(ni); struct ath_tid *atid = &an->an_tid[tid]; + ath_bufhead bf_cq; + struct ath_buf *bf; DPRINTF(sc, ATH_DEBUG_SW_TX_CTRL, "%s: called\n", __func__); @@ -5312,7 +5376,57 @@ ath_addba_stop(struct ieee80211_node *ni * it'll set the cleanup flag, and it'll be unpaused once * things have been cleaned up. */ - ath_tx_tid_cleanup(sc, an, tid); + TAILQ_INIT(&bf_cq); + ATH_TX_LOCK(sc); + ath_tx_tid_cleanup(sc, an, tid, &bf_cq); + ATH_TX_UNLOCK(sc); + + /* Handle completing frames and fail them */ + while ((bf = TAILQ_FIRST(&bf_cq)) != NULL) { + TAILQ_REMOVE(&bf_cq, bf, bf_list); + ath_tx_default_comp(sc, bf, 1); + } +} + +/* + * Handle a node reassociation. + * + * We may have a bunch of frames queued to the hardware; those need + * to be marked as cleanup. + */ +void +ath_tx_node_reassoc(struct ath_softc *sc, struct ath_node *an) +{ + struct ath_tid *tid; + int i; + ath_bufhead bf_cq; + struct ath_buf *bf; + + TAILQ_INIT(&bf_cq); + + ATH_TX_UNLOCK_ASSERT(sc); + + ATH_TX_LOCK(sc); + for (i = 0; i < IEEE80211_TID_SIZE; i++) { + tid = &an->an_tid[i]; + if (tid->hwq_depth == 0) + continue; + ath_tx_tid_pause(sc, tid); + DPRINTF(sc, ATH_DEBUG_NODE, + "%s: %6D: TID %d: cleaning up TID\n", + __func__, + an->an_node.ni_macaddr, + ":", + i); + ath_tx_tid_cleanup(sc, an, i, &bf_cq); + } + ATH_TX_UNLOCK(sc); + + /* Handle completing frames and fail them */ + while ((bf = TAILQ_FIRST(&bf_cq)) != NULL) { + TAILQ_REMOVE(&bf_cq, bf, bf_list); + ath_tx_default_comp(sc, bf, 1); + } } /* @@ -5406,7 +5520,7 @@ int ath_tx_node_is_asleep(struct ath_softc *sc, struct ath_node *an) { - ATH_NODE_LOCK_ASSERT(an); + ATH_TX_LOCK_ASSERT(sc); return (an->an_is_powersave); } @@ -5436,7 +5550,7 @@ ath_tx_node_sleep(struct ath_softc *sc, struct ath_txq *txq; int tid; - ATH_NODE_UNLOCK_ASSERT(an); + ATH_TX_UNLOCK_ASSERT(sc); /* * It's possible that a parallel call to ath_tx_node_wakeup() @@ -5471,17 +5585,12 @@ ath_tx_node_sleep(struct ath_softc *sc, ath_tx_tid_pause(sc, atid); } - ATH_TX_UNLOCK(sc); - - ATH_NODE_LOCK(an); /* In case of concurrency races from net80211.. */ if (an->an_is_powersave == 1) { - ATH_NODE_UNLOCK(an); device_printf(sc->sc_dev, "%s: an=%p: node was already asleep\n", __func__, an); - ATH_TX_LOCK(sc); for (tid = 0; tid < IEEE80211_TID_SIZE; tid++) { atid = &an->an_tid[tid]; txq = sc->sc_ac2q[atid->ac]; @@ -5495,7 +5604,7 @@ ath_tx_node_sleep(struct ath_softc *sc, /* Mark node as in powersaving */ an->an_is_powersave = 1; - ATH_NODE_UNLOCK(an); + ATH_TX_UNLOCK(sc); } /* @@ -5509,12 +5618,13 @@ ath_tx_node_wakeup(struct ath_softc *sc, struct ath_txq *txq; int tid; - ATH_NODE_UNLOCK_ASSERT(an); - ATH_NODE_LOCK(an); + ATH_TX_UNLOCK_ASSERT(sc); + + ATH_TX_LOCK(sc); /* In case of concurrency races from net80211.. */ if (an->an_is_powersave == 0) { - ATH_NODE_UNLOCK(an); + ATH_TX_UNLOCK(sc); device_printf(sc->sc_dev, "%s: an=%p: node was already awake\n", __func__, an); @@ -5524,9 +5634,6 @@ ath_tx_node_wakeup(struct ath_softc *sc, /* Mark node as awake */ an->an_is_powersave = 0; - ATH_NODE_UNLOCK(an); - - ATH_TX_LOCK(sc); for (tid = 0; tid < IEEE80211_TID_SIZE; tid++) { atid = &an->an_tid[tid]; txq = sc->sc_ac2q[atid->ac]; Modified: head/sys/dev/ath/if_ath_tx.h ============================================================================== --- head/sys/dev/ath/if_ath_tx.h Mon May 13 18:57:18 2013 (r250607) +++ head/sys/dev/ath/if_ath_tx.h Mon May 13 19:02:22 2013 (r250608) @@ -134,6 +134,7 @@ extern void ath_addba_response_timeout(s extern void ath_tx_node_sleep(struct ath_softc *sc, struct ath_node *an); extern void ath_tx_node_wakeup(struct ath_softc *sc, struct ath_node *an); extern int ath_tx_node_is_asleep(struct ath_softc *sc, struct ath_node *an); +extern void ath_tx_node_reassoc(struct ath_softc *sc, struct ath_node *an); /* * Misc debugging stuff From owner-svn-src-all@FreeBSD.ORG Mon May 13 19:03:13 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id A18A27A1; Mon, 13 May 2013 19:03:13 +0000 (UTC) (envelope-from adrian@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id 9404A26B; Mon, 13 May 2013 19:03:13 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.6/8.14.6) with ESMTP id r4DJ3DuL045335; Mon, 13 May 2013 19:03:13 GMT (envelope-from adrian@svn.freebsd.org) Received: (from adrian@localhost) by svn.freebsd.org (8.14.6/8.14.5/Submit) id r4DJ3DHm045333; Mon, 13 May 2013 19:03:13 GMT (envelope-from adrian@svn.freebsd.org) Message-Id: <201305131903.r4DJ3DHm045333@svn.freebsd.org> From: Adrian Chadd Date: Mon, 13 May 2013 19:03:13 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r250609 - head/sys/dev/ath X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 13 May 2013 19:03:13 -0000 Author: adrian Date: Mon May 13 19:03:12 2013 New Revision: 250609 URL: http://svnweb.freebsd.org/changeset/base/250609 Log: Since the node state is 100% back under the TX lock, just kill the use of atomics. I'll re-think this nonsense later. Modified: head/sys/dev/ath/if_ath.c head/sys/dev/ath/if_athvar.h Modified: head/sys/dev/ath/if_ath.c ============================================================================== --- head/sys/dev/ath/if_ath.c Mon May 13 19:02:22 2013 (r250608) +++ head/sys/dev/ath/if_ath.c Mon May 13 19:03:12 2013 (r250609) @@ -6028,7 +6028,7 @@ ath_node_set_tim(struct ieee80211_node * an->an_tim_set = 1; ATH_TX_UNLOCK(sc); changed = avp->av_set_tim(ni, enable); - } else if (atomic_load_acq_int(&an->an_swq_depth) == 0) { + } else if (an->an_swq_depth == 0) { /* disable */ DPRINTF(sc, ATH_DEBUG_NODE_PWRSAVE, "%s: an=%p, enable=%d, an_swq_depth == 0, disabling\n", @@ -6120,16 +6120,9 @@ ath_tx_update_tim(struct ath_softc *sc, ATH_TX_LOCK_ASSERT(sc); if (enable) { - /* - * Don't bother grabbing the lock unless the queue is not - * empty. - */ - if (atomic_load_acq_int(&an->an_swq_depth) == 0) - return; - if (an->an_is_powersave && an->an_tim_set == 0 && - atomic_load_acq_int(&an->an_swq_depth) != 0) { + an->an_swq_depth != 0) { DPRINTF(sc, ATH_DEBUG_NODE_PWRSAVE, "%s: an=%p, swq_depth>0, tim_set=0, set!\n", __func__, an); @@ -6140,13 +6133,13 @@ ath_tx_update_tim(struct ath_softc *sc, /* * Don't bother grabbing the lock unless the queue is empty. */ - if (atomic_load_acq_int(&an->an_swq_depth) != 0) + if (&an->an_swq_depth != 0) return; if (an->an_is_powersave && an->an_stack_psq == 0 && an->an_tim_set == 1 && - atomic_load_acq_int(&an->an_swq_depth) == 0) { + an->an_swq_depth == 0) { DPRINTF(sc, ATH_DEBUG_NODE_PWRSAVE, "%s: an=%p, swq_depth=0, tim_set=1, psq_set=0," " clear!\n", Modified: head/sys/dev/ath/if_athvar.h ============================================================================== --- head/sys/dev/ath/if_athvar.h Mon May 13 19:02:22 2013 (r250608) +++ head/sys/dev/ath/if_athvar.h Mon May 13 19:03:12 2013 (r250609) @@ -415,17 +415,17 @@ struct ath_txq { #define ATH_TID_INSERT_HEAD(_tq, _elm, _field) do { \ TAILQ_INSERT_HEAD(&(_tq)->tid_q, (_elm), _field); \ (_tq)->axq_depth++; \ - atomic_add_rel_32( &((_tq)->an)->an_swq_depth, 1); \ + (_tq)->an->an_swq_depth++; \ } while (0) #define ATH_TID_INSERT_TAIL(_tq, _elm, _field) do { \ TAILQ_INSERT_TAIL(&(_tq)->tid_q, (_elm), _field); \ (_tq)->axq_depth++; \ - atomic_add_rel_32( &((_tq)->an)->an_swq_depth, 1); \ + (_tq)->an->an_swq_depth++; \ } while (0) #define ATH_TID_REMOVE(_tq, _elm, _field) do { \ TAILQ_REMOVE(&(_tq)->tid_q, _elm, _field); \ (_tq)->axq_depth--; \ - atomic_subtract_rel_32( &((_tq)->an)->an_swq_depth, 1); \ + (_tq)->an->an_swq_depth--; \ } while (0) #define ATH_TID_FIRST(_tq) TAILQ_FIRST(&(_tq)->tid_q) #define ATH_TID_LAST(_tq, _field) TAILQ_LAST(&(_tq)->tid_q, _field) @@ -436,17 +436,17 @@ struct ath_txq { #define ATH_TID_FILT_INSERT_HEAD(_tq, _elm, _field) do { \ TAILQ_INSERT_HEAD(&(_tq)->filtq.tid_q, (_elm), _field); \ (_tq)->axq_depth++; \ - atomic_add_rel_32( &((_tq)->an)->an_swq_depth, 1); \ + (_tq)->an->an_swq_depth++; \ } while (0) #define ATH_TID_FILT_INSERT_TAIL(_tq, _elm, _field) do { \ TAILQ_INSERT_TAIL(&(_tq)->filtq.tid_q, (_elm), _field); \ (_tq)->axq_depth++; \ - atomic_add_rel_32( &((_tq)->an)->an_swq_depth, 1); \ + (_tq)->an->an_swq_depth++; \ } while (0) #define ATH_TID_FILT_REMOVE(_tq, _elm, _field) do { \ TAILQ_REMOVE(&(_tq)->filtq.tid_q, _elm, _field); \ (_tq)->axq_depth--; \ - atomic_subtract_rel_32( &((_tq)->an)->an_swq_depth, 1); \ + (_tq)->an->an_swq_depth--; \ } while (0) #define ATH_TID_FILT_FIRST(_tq) TAILQ_FIRST(&(_tq)->filtq.tid_q) #define ATH_TID_FILT_LAST(_tq, _field) TAILQ_LAST(&(_tq)->filtq.tid_q,_field) From owner-svn-src-all@FreeBSD.ORG Mon May 13 19:44:35 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id C9B4584E; Mon, 13 May 2013 19:44:35 +0000 (UTC) (envelope-from jkim@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id BB698686; Mon, 13 May 2013 19:44:35 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.6/8.14.6) with ESMTP id r4DJiZs3059417; Mon, 13 May 2013 19:44:35 GMT (envelope-from jkim@svn.freebsd.org) Received: (from jkim@localhost) by svn.freebsd.org (8.14.6/8.14.5/Submit) id r4DJiZ4Q059416; Mon, 13 May 2013 19:44:35 GMT (envelope-from jkim@svn.freebsd.org) Message-Id: <201305131944.r4DJiZ4Q059416@svn.freebsd.org> From: Jung-uk Kim Date: Mon, 13 May 2013 19:44:35 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org Subject: svn commit: r250610 - stable/9/sys/dev/atkbdc X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 13 May 2013 19:44:35 -0000 Author: jkim Date: Mon May 13 19:44:35 2013 New Revision: 250610 URL: http://svnweb.freebsd.org/changeset/base/250610 Log: MFC: r248479 List TrackPoint device before generic model. Modified: stable/9/sys/dev/atkbdc/psm.c Directory Properties: stable/9/sys/ (props changed) stable/9/sys/dev/ (props changed) Modified: stable/9/sys/dev/atkbdc/psm.c ============================================================================== --- stable/9/sys/dev/atkbdc/psm.c Mon May 13 19:03:12 2013 (r250609) +++ stable/9/sys/dev/atkbdc/psm.c Mon May 13 19:44:35 2013 (r250610) @@ -747,8 +747,8 @@ model_name(int model) { MOUSE_MODEL_4D, "4D Mouse" }, { MOUSE_MODEL_4DPLUS, "4D+ Mouse" }, { MOUSE_MODEL_SYNAPTICS, "Synaptics Touchpad" }, - { MOUSE_MODEL_GENERIC, "Generic PS/2 mouse" }, { MOUSE_MODEL_TRACKPOINT, "IBM/Lenovo TrackPoint" }, + { MOUSE_MODEL_GENERIC, "Generic PS/2 mouse" }, { MOUSE_MODEL_UNKNOWN, "Unknown" }, }; int i; From owner-svn-src-all@FreeBSD.ORG Mon May 13 19:52:35 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id E7FCCD31; Mon, 13 May 2013 19:52:35 +0000 (UTC) (envelope-from adrian@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id C9BC374D; Mon, 13 May 2013 19:52:35 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.6/8.14.6) with ESMTP id r4DJqZgl062625; Mon, 13 May 2013 19:52:35 GMT (envelope-from adrian@svn.freebsd.org) Received: (from adrian@localhost) by svn.freebsd.org (8.14.6/8.14.5/Submit) id r4DJqZD2062623; Mon, 13 May 2013 19:52:35 GMT (envelope-from adrian@svn.freebsd.org) Message-Id: <201305131952.r4DJqZD2062623@svn.freebsd.org> From: Adrian Chadd Date: Mon, 13 May 2013 19:52:35 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r250611 - head/sys/dev/ath X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 13 May 2013 19:52:36 -0000 Author: adrian Date: Mon May 13 19:52:35 2013 New Revision: 250611 URL: http://svnweb.freebsd.org/changeset/base/250611 Log: Improve the debugging output - use the MAC address rather than various pointer values everywhere. Modified: head/sys/dev/ath/if_ath.c head/sys/dev/ath/if_ath_tx.c Modified: head/sys/dev/ath/if_ath.c ============================================================================== --- head/sys/dev/ath/if_ath.c Mon May 13 19:44:35 2013 (r250610) +++ head/sys/dev/ath/if_ath.c Mon May 13 19:52:35 2013 (r250611) @@ -3450,7 +3450,7 @@ ath_node_alloc(struct ieee80211vap *vap, /* XXX setup ath_tid */ ath_tx_tid_init(sc, an); - DPRINTF(sc, ATH_DEBUG_NODE, "%s: an %p\n", __func__, an); + DPRINTF(sc, ATH_DEBUG_NODE, "%s: %6D: an %p\n", __func__, mac, ":", an); return &an->an_node; } @@ -3460,6 +3460,9 @@ ath_node_cleanup(struct ieee80211_node * struct ieee80211com *ic = ni->ni_ic; struct ath_softc *sc = ic->ic_ifp->if_softc; + DPRINTF(sc, ATH_DEBUG_NODE, "%s: %6D: an %p\n", __func__, + ni->ni_macaddr, ":", ATH_NODE(ni)); + /* Cleanup ath_tid, free unused bufs, unlink bufs in TXQ */ ath_tx_node_flush(sc, ATH_NODE(ni)); ath_rate_node_cleanup(sc, ATH_NODE(ni)); @@ -3472,7 +3475,8 @@ ath_node_free(struct ieee80211_node *ni) struct ieee80211com *ic = ni->ni_ic; struct ath_softc *sc = ic->ic_ifp->if_softc; - DPRINTF(sc, ATH_DEBUG_NODE, "%s: ni %p\n", __func__, ni); + DPRINTF(sc, ATH_DEBUG_NODE, "%s: %6D: an %p\n", __func__, + ni->ni_macaddr, ":", ATH_NODE(ni)); mtx_destroy(&ATH_NODE(ni)->an_mtx); sc->sc_node_free(ni); } @@ -5920,11 +5924,13 @@ ath_node_powersave(struct ieee80211_node struct ath_softc *sc = ic->ic_ifp->if_softc; struct ath_vap *avp = ATH_VAP(ni->ni_vap); - ATH_NODE_UNLOCK_ASSERT(an); /* XXX and no TXQ locks should be held here */ - DPRINTF(sc, ATH_DEBUG_NODE_PWRSAVE, "%s: ni=%p, enable=%d\n", - __func__, ni, enable); + DPRINTF(sc, ATH_DEBUG_NODE_PWRSAVE, "%s: %6D: enable=%d\n", + __func__, + ni->ni_macaddr, + ":", + !! enable); /* Suspend or resume software queue handling */ if (enable) @@ -6018,21 +6024,30 @@ ath_node_set_tim(struct ieee80211_node * */ if (enable && an->an_tim_set == 1) { DPRINTF(sc, ATH_DEBUG_NODE_PWRSAVE, - "%s: an=%p, enable=%d, tim_set=1, ignoring\n", - __func__, an, enable); + "%s: %6D: enable=%d, tim_set=1, ignoring\n", + __func__, + ni->ni_macaddr, + ":", + enable); ATH_TX_UNLOCK(sc); } else if (enable) { DPRINTF(sc, ATH_DEBUG_NODE_PWRSAVE, - "%s: an=%p, enable=%d, enabling TIM\n", - __func__, an, enable); + "%s: %6D: enable=%d, enabling TIM\n", + __func__, + ni->ni_macaddr, + ":", + enable); an->an_tim_set = 1; ATH_TX_UNLOCK(sc); changed = avp->av_set_tim(ni, enable); } else if (an->an_swq_depth == 0) { /* disable */ DPRINTF(sc, ATH_DEBUG_NODE_PWRSAVE, - "%s: an=%p, enable=%d, an_swq_depth == 0, disabling\n", - __func__, an, enable); + "%s: %6D: enable=%d, an_swq_depth == 0, disabling\n", + __func__, + ni->ni_macaddr, + ":", + enable); an->an_tim_set = 0; ATH_TX_UNLOCK(sc); changed = avp->av_set_tim(ni, enable); @@ -6041,8 +6056,11 @@ ath_node_set_tim(struct ieee80211_node * * disable regardless; the node isn't in powersave now */ DPRINTF(sc, ATH_DEBUG_NODE_PWRSAVE, - "%s: an=%p, enable=%d, an_pwrsave=0, disabling\n", - __func__, an, enable); + "%s: %6D: enable=%d, an_pwrsave=0, disabling\n", + __func__, + ni->ni_macaddr, + ":", + enable); an->an_tim_set = 0; ATH_TX_UNLOCK(sc); changed = avp->av_set_tim(ni, enable); @@ -6054,8 +6072,11 @@ ath_node_set_tim(struct ieee80211_node * */ ATH_TX_UNLOCK(sc); DPRINTF(sc, ATH_DEBUG_NODE_PWRSAVE, - "%s: enable=%d, an_swq_depth > 0, ignoring\n", - __func__, enable); + "%s: %6D: enable=%d, an_swq_depth > 0, ignoring\n", + __func__, + ni->ni_macaddr, + ":", + enable); changed = 0; } @@ -6124,8 +6145,10 @@ ath_tx_update_tim(struct ath_softc *sc, an->an_tim_set == 0 && an->an_swq_depth != 0) { DPRINTF(sc, ATH_DEBUG_NODE_PWRSAVE, - "%s: an=%p, swq_depth>0, tim_set=0, set!\n", - __func__, an); + "%s: %6D: swq_depth>0, tim_set=0, set!\n", + __func__, + ni->ni_macaddr, + ":"); an->an_tim_set = 1; (void) avp->av_set_tim(ni, 1); } Modified: head/sys/dev/ath/if_ath_tx.c ============================================================================== --- head/sys/dev/ath/if_ath_tx.c Mon May 13 19:44:35 2013 (r250610) +++ head/sys/dev/ath/if_ath_tx.c Mon May 13 19:52:35 2013 (r250611) @@ -3251,13 +3251,19 @@ ath_tx_tid_bar_unsuspend(struct ath_soft ATH_TX_LOCK_ASSERT(sc); DPRINTF(sc, ATH_DEBUG_SW_TX_BAR, - "%s: tid=%p, called\n", + "%s: %6D: tid=%p, called\n", __func__, + tid->an->an_node.ni_macaddr, + ":", tid); if (tid->bar_tx == 0 || tid->bar_wait == 0) { - device_printf(sc->sc_dev, "%s: bar_tx=%d, bar_wait=%d: ?\n", - __func__, tid->bar_tx, tid->bar_wait); + device_printf(sc->sc_dev, + "%s: %6D: bar_tx=%d, bar_wait=%d: ?\n", + __func__, + tid->an->an_node.ni_macaddr, + ":", + tid->bar_tx, tid->bar_wait); } tid->bar_tx = tid->bar_wait = 0; @@ -3278,8 +3284,12 @@ ath_tx_tid_bar_tx_ready(struct ath_softc if (tid->bar_wait == 0 || tid->hwq_depth > 0) return (0); - DPRINTF(sc, ATH_DEBUG_SW_TX_BAR, "%s: tid=%p (%d), bar ready\n", - __func__, tid, tid->tid); + DPRINTF(sc, ATH_DEBUG_SW_TX_BAR, + "%s: %6D: tid=%p (%d), bar ready\n", + __func__, + tid->an->an_node.ni_macaddr, + ":", + tid, tid->tid); return (1); } @@ -3304,8 +3314,10 @@ ath_tx_tid_bar_tx(struct ath_softc *sc, ATH_TX_LOCK_ASSERT(sc); DPRINTF(sc, ATH_DEBUG_SW_TX_BAR, - "%s: tid=%p, called\n", + "%s: %6D: tid=%p, called\n", __func__, + tid->an->an_node.ni_macaddr, + ":", tid); tap = ath_tx_get_tx_tid(tid->an, tid->tid); @@ -3315,8 +3327,10 @@ ath_tx_tid_bar_tx(struct ath_softc *sc, */ if (tid->bar_wait == 0 || tid->bar_tx == 1) { device_printf(sc->sc_dev, - "%s: tid=%p, bar_tx=%d, bar_wait=%d: ?\n", + "%s: %6D: tid=%p, bar_tx=%d, bar_wait=%d: ?\n", __func__, + tid->an->an_node.ni_macaddr, + ":", tid, tid->bar_tx, tid->bar_wait); @@ -3326,8 +3340,10 @@ ath_tx_tid_bar_tx(struct ath_softc *sc, /* Don't do anything if we still have pending frames */ if (tid->hwq_depth > 0) { DPRINTF(sc, ATH_DEBUG_SW_TX_BAR, - "%s: tid=%p, hwq_depth=%d, waiting\n", + "%s: %6D: tid=%p, hwq_depth=%d, waiting\n", __func__, + tid->an->an_node.ni_macaddr, + ":", tid, tid->hwq_depth); return; @@ -3349,8 +3365,10 @@ ath_tx_tid_bar_tx(struct ath_softc *sc, * XXX verify this is _actually_ the valid value to begin at! */ DPRINTF(sc, ATH_DEBUG_SW_TX_BAR, - "%s: tid=%p, new BAW left edge=%d\n", + "%s: %6D: tid=%p, new BAW left edge=%d\n", __func__, + tid->an->an_node.ni_macaddr, + ":", tid, tap->txa_start); @@ -3366,8 +3384,12 @@ ath_tx_tid_bar_tx(struct ath_softc *sc, /* Failure? For now, warn loudly and continue */ ATH_TX_LOCK(sc); - device_printf(sc->sc_dev, "%s: tid=%p, failed to TX BAR, continue!\n", - __func__, tid); + device_printf(sc->sc_dev, + "%s: %6D: tid=%p, failed to TX BAR, continue!\n", + __func__, + tid->an->an_node.ni_macaddr, + ":", + tid); ath_tx_tid_bar_unsuspend(sc, tid); } @@ -3545,10 +3567,15 @@ ath_tx_tid_drain(struct ath_softc *sc, s /* But don't do it for non-QoS TIDs */ if (tap) { -#if 0 +#if 1 DPRINTF(sc, ATH_DEBUG_SW_TX_CTRL, - "%s: node %p: TID %d: sliding BAW left edge to %d\n", - __func__, an, tid->tid, tap->txa_start); + "%s: %6D: node %p: TID %d: sliding BAW left edge to %d\n", + __func__, + ni->ni_macaddr, + ":", + an, + tid->tid, + tap->txa_start); #endif ni->ni_txseqs[tid->tid] = tap->txa_start; tid->baw_tail = tid->baw_head; @@ -3641,6 +3668,18 @@ ath_tx_node_flush(struct ath_softc *sc, &an->an_node); ATH_TX_LOCK(sc); + DPRINTF(sc, ATH_DEBUG_NODE, + "%s: %6D: flush; is_powersave=%d, stack_psq=%d, tim=%d, " + "swq_depth=%d, clrdmask=%d\n", + __func__, + an->an_node.ni_macaddr, + ":", + an->an_is_powersave, + an->an_stack_psq, + an->an_tim_set, + an->an_swq_depth, + an->clrdmask); + for (tid = 0; tid < IEEE80211_TID_SIZE; tid++) { struct ath_tid *atid = &an->an_tid[tid]; @@ -5263,8 +5302,11 @@ ath_addba_request(struct ieee80211_node ATH_TX_UNLOCK(sc); DPRINTF(sc, ATH_DEBUG_SW_TX_CTRL, - "%s: called; dialogtoken=%d, baparamset=%d, batimeout=%d\n", - __func__, dialogtoken, baparamset, batimeout); + "%s: %6D: called; dialogtoken=%d, baparamset=%d, batimeout=%d\n", + __func__, + ni->ni_macaddr, + ":", + dialogtoken, baparamset, batimeout); DPRINTF(sc, ATH_DEBUG_SW_TX_CTRL, "%s: txa_start=%d, ni_txseqs=%d\n", __func__, tap->txa_start, ni->ni_txseqs[tid]); @@ -5304,7 +5346,9 @@ ath_addba_response(struct ieee80211_node int r; DPRINTF(sc, ATH_DEBUG_SW_TX_CTRL, - "%s: called; status=%d, code=%d, batimeout=%d\n", __func__, + "%s: %6D: called; status=%d, code=%d, batimeout=%d\n", __func__, + ni->ni_macaddr, + ":", status, code, batimeout); DPRINTF(sc, ATH_DEBUG_SW_TX_CTRL, @@ -5349,7 +5393,10 @@ ath_addba_stop(struct ieee80211_node *ni ath_bufhead bf_cq; struct ath_buf *bf; - DPRINTF(sc, ATH_DEBUG_SW_TX_CTRL, "%s: called\n", __func__); + DPRINTF(sc, ATH_DEBUG_SW_TX_CTRL, "%s: %6D: called\n", + __func__, + ni->ni_macaddr, + ":"); /* * Pause TID traffic early, so there aren't any races @@ -5450,8 +5497,10 @@ ath_bar_response(struct ieee80211_node * int attempts = tap->txa_attempts; DPRINTF(sc, ATH_DEBUG_SW_TX_BAR, - "%s: called; tap=%p, atid=%p, txa_tid=%d, atid->tid=%d, status=%d, attempts=%d\n", + "%s: %6D: called; tap=%p, atid=%p, txa_tid=%d, atid->tid=%d, status=%d, attempts=%d\n", __func__, + ni->ni_macaddr, + ":", tap, atid, tap->txa_tid, @@ -5498,7 +5547,10 @@ ath_addba_response_timeout(struct ieee80 struct ath_tid *atid = &an->an_tid[tid]; DPRINTF(sc, ATH_DEBUG_SW_TX_CTRL, - "%s: called; resuming\n", __func__); + "%s: %6D: called; resuming\n", + __func__, + ni->ni_macaddr, + ":"); ATH_TX_LOCK(sc); atid->addba_tx_pending = 0; From owner-svn-src-all@FreeBSD.ORG Mon May 13 19:53:20 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id 4A035EA3; Mon, 13 May 2013 19:53:20 +0000 (UTC) (envelope-from hiren@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id 3C310753; Mon, 13 May 2013 19:53:20 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.6/8.14.6) with ESMTP id r4DJrKa4062789; Mon, 13 May 2013 19:53:20 GMT (envelope-from hiren@svn.freebsd.org) Received: (from hiren@localhost) by svn.freebsd.org (8.14.6/8.14.5/Submit) id r4DJrKSx062788; Mon, 13 May 2013 19:53:20 GMT (envelope-from hiren@svn.freebsd.org) Message-Id: <201305131953.r4DJrKSx062788@svn.freebsd.org> From: Hiren Panchasara Date: Mon, 13 May 2013 19:53:20 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r250612 - head/tools/test/hwpmc X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 13 May 2013 19:53:20 -0000 Author: hiren Date: Mon May 13 19:53:19 2013 New Revision: 250612 URL: http://svnweb.freebsd.org/changeset/base/250612 Log: As python3 does not have raw_input(), convert it to input() when we are using python3. PR: 177214 Reviewed by: gnn Approved by: sbruno (mentor) Modified: head/tools/test/hwpmc/pmctest.py Modified: head/tools/test/hwpmc/pmctest.py ============================================================================== --- head/tools/test/hwpmc/pmctest.py Mon May 13 19:52:35 2013 (r250611) +++ head/tools/test/hwpmc/pmctest.py Mon May 13 19:53:19 2013 (r250612) @@ -51,6 +51,10 @@ import sys import subprocess from subprocess import PIPE +# Use input() for Python version 3 +if sys.version_info[0] == 3: + raw_input = input + # A list of strings that are not really counters, just # name tags that are output by pmccontrol -L notcounter = ["IAF", "IAP", "TSC", "UNC", "UCF", "UCP", "SOFT" ] @@ -87,7 +91,7 @@ def main(): print(result) if (options.wait == True): try: - value = input("next?") + value = raw_input("next?") except EOFError: sys.exit() From owner-svn-src-all@FreeBSD.ORG Mon May 13 19:55:27 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id DC28FD4; Mon, 13 May 2013 19:55:27 +0000 (UTC) (envelope-from jimharris@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id CE9BA76C; Mon, 13 May 2013 19:55:27 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.6/8.14.6) with ESMTP id r4DJtRVc063248; Mon, 13 May 2013 19:55:27 GMT (envelope-from jimharris@svn.freebsd.org) Received: (from jimharris@localhost) by svn.freebsd.org (8.14.6/8.14.5/Submit) id r4DJtR8D063247; Mon, 13 May 2013 19:55:27 GMT (envelope-from jimharris@svn.freebsd.org) Message-Id: <201305131955.r4DJtR8D063247@svn.freebsd.org> From: Jim Harris Date: Mon, 13 May 2013 19:55:27 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r250613 - head/sys/netinet X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 13 May 2013 19:55:27 -0000 Author: jimharris Date: Mon May 13 19:55:27 2013 New Revision: 250613 URL: http://svnweb.freebsd.org/changeset/base/250613 Log: Fix typo in net.inet.tcp.minmss sysctl description. MFC after: 3 days Modified: head/sys/netinet/tcp_subr.c Modified: head/sys/netinet/tcp_subr.c ============================================================================== --- head/sys/netinet/tcp_subr.c Mon May 13 19:53:19 2013 (r250612) +++ head/sys/netinet/tcp_subr.c Mon May 13 19:55:27 2013 (r250613) @@ -174,7 +174,7 @@ SYSCTL_VNET_PROC(_net_inet_tcp, TCPCTL_V VNET_DEFINE(int, tcp_minmss) = TCP_MINMSS; SYSCTL_VNET_INT(_net_inet_tcp, OID_AUTO, minmss, CTLFLAG_RW, &VNET_NAME(tcp_minmss), 0, - "Minmum TCP Maximum Segment Size"); + "Minimum TCP Maximum Segment Size"); VNET_DEFINE(int, tcp_do_rfc1323) = 1; SYSCTL_VNET_INT(_net_inet_tcp, TCPCTL_DO_RFC1323, rfc1323, CTLFLAG_RW, From owner-svn-src-all@FreeBSD.ORG Mon May 13 20:00:03 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id E45263B7; Mon, 13 May 2013 20:00:03 +0000 (UTC) (envelope-from np@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id D78CE7A9; Mon, 13 May 2013 20:00:03 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.6/8.14.6) with ESMTP id r4DK03c8065665; Mon, 13 May 2013 20:00:03 GMT (envelope-from np@svn.freebsd.org) Received: (from np@localhost) by svn.freebsd.org (8.14.6/8.14.5/Submit) id r4DK033v065664; Mon, 13 May 2013 20:00:03 GMT (envelope-from np@svn.freebsd.org) Message-Id: <201305132000.r4DK033v065664@svn.freebsd.org> From: Navdeep Parhar Date: Mon, 13 May 2013 20:00:03 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r250614 - head/sys/dev/cxgbe X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 13 May 2013 20:00:04 -0000 Author: np Date: Mon May 13 20:00:03 2013 New Revision: 250614 URL: http://svnweb.freebsd.org/changeset/base/250614 Log: Deal correctly with 40G ports that don't have any transceiver plugged in. Do not claim that they have unknown tranceivers. MFC after: 3 days Modified: head/sys/dev/cxgbe/t4_main.c Modified: head/sys/dev/cxgbe/t4_main.c ============================================================================== --- head/sys/dev/cxgbe/t4_main.c Mon May 13 19:55:27 2013 (r250613) +++ head/sys/dev/cxgbe/t4_main.c Mon May 13 20:00:03 2013 (r250614) @@ -2616,12 +2616,19 @@ build_medialist(struct port_info *pi) ifmedia_add(media, m | IFM_40G_SR4, data, NULL); ifmedia_set(media, m | IFM_40G_SR4); break; + case FW_PORT_MOD_TYPE_TWINAX_PASSIVE: case FW_PORT_MOD_TYPE_TWINAX_ACTIVE: ifmedia_add(media, m | IFM_40G_CR4, data, NULL); ifmedia_set(media, m | IFM_40G_CR4); break; + case FW_PORT_MOD_TYPE_NONE: + m &= ~IFM_FDX; + ifmedia_add(media, m | IFM_NONE, data, NULL); + ifmedia_set(media, m | IFM_NONE); + break; + default: device_printf(pi->dev, "unknown port_type (%d), mod_type (%d)\n", From owner-svn-src-all@FreeBSD.ORG Mon May 13 20:04:00 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id 4230A5DF; Mon, 13 May 2013 20:04:00 +0000 (UTC) (envelope-from jkim@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id 34C167DF; Mon, 13 May 2013 20:04:00 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.6/8.14.6) with ESMTP id r4DK40a9068108; Mon, 13 May 2013 20:04:00 GMT (envelope-from jkim@svn.freebsd.org) Received: (from jkim@localhost) by svn.freebsd.org (8.14.6/8.14.5/Submit) id r4DK40Ud068102; Mon, 13 May 2013 20:04:00 GMT (envelope-from jkim@svn.freebsd.org) Message-Id: <201305132004.r4DK40Ud068102@svn.freebsd.org> From: Jung-uk Kim Date: Mon, 13 May 2013 20:04:00 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r250615 - head/sys/dev/atkbdc X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 13 May 2013 20:04:00 -0000 Author: jkim Date: Mon May 13 20:03:59 2013 New Revision: 250615 URL: http://svnweb.freebsd.org/changeset/base/250615 Log: Remove a bogus re-assignment. MFC after: 3 days Modified: head/sys/dev/atkbdc/psm.c Modified: head/sys/dev/atkbdc/psm.c ============================================================================== --- head/sys/dev/atkbdc/psm.c Mon May 13 20:00:03 2013 (r250614) +++ head/sys/dev/atkbdc/psm.c Mon May 13 20:03:59 2013 (r250615) @@ -4704,8 +4704,6 @@ enable_trackpoint(KBDC kbdc, struct psm_ { int id; - kbdc = sc->kbdc; - if (send_aux_command(kbdc, 0xe1) != PSM_ACK || read_aux_data(kbdc) != 0x01) return (FALSE); From owner-svn-src-all@FreeBSD.ORG Mon May 13 20:14:59 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id 968B98C3; Mon, 13 May 2013 20:14:59 +0000 (UTC) (envelope-from dim@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id 896A5845; Mon, 13 May 2013 20:14:59 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.6/8.14.6) with ESMTP id r4DKExbQ072078; Mon, 13 May 2013 20:14:59 GMT (envelope-from dim@svn.freebsd.org) Received: (from dim@localhost) by svn.freebsd.org (8.14.6/8.14.5/Submit) id r4DKExFq072077; Mon, 13 May 2013 20:14:59 GMT (envelope-from dim@svn.freebsd.org) Message-Id: <201305132014.r4DKExFq072077@svn.freebsd.org> From: Dimitry Andric Date: Mon, 13 May 2013 20:14:59 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r250616 - head/lib/clang/libllvmsupport X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 13 May 2013 20:14:59 -0000 Author: dim Date: Mon May 13 20:14:58 2013 New Revision: 250616 URL: http://svnweb.freebsd.org/changeset/base/250616 Log: Use an ugly hack to get around bootstrapping problems when building clang on head between r239347 and r245428. The former revision introduced CLOCK_PROCESS_CPUTIME_ID as a clock id for the clock_gettime() function and friends, but it was only added in , not in . Any program including would therefore not be able to use CLOCK_PROCESS_CPUTIME_ID, even though the value of _POSIX_CPUTIME indicates its existence. The latter revision synchronized the defines again. Work around this problem by defining the id on the command line for the particular .cpp file that needs it. If the id ever changes value, this hack will need to be updated. Modified: head/lib/clang/libllvmsupport/Makefile Modified: head/lib/clang/libllvmsupport/Makefile ============================================================================== --- head/lib/clang/libllvmsupport/Makefile Mon May 13 20:03:59 2013 (r250615) +++ head/lib/clang/libllvmsupport/Makefile Mon May 13 20:14:58 2013 (r250616) @@ -93,3 +93,8 @@ SRCS+= DataExtractor.cpp \ .endif .include "../clang.lib.mk" + +# Ugly hack to work around CLOCK_PROCESS_CPUTIME_ID not being properly defined +# between r239347 and r245428. +CXXFLAGS.Process.cpp= -DCLOCK_PROCESS_CPUTIME_ID=15 +CXXFLAGS+= ${CXXFLAGS.${.IMPSRC:T}} From owner-svn-src-all@FreeBSD.ORG Mon May 13 20:28:24 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id D6931DD7; Mon, 13 May 2013 20:28:24 +0000 (UTC) (envelope-from asomers@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id C90978B7; Mon, 13 May 2013 20:28:24 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.6/8.14.6) with ESMTP id r4DKSOS3076292; Mon, 13 May 2013 20:28:24 GMT (envelope-from asomers@svn.freebsd.org) Received: (from asomers@localhost) by svn.freebsd.org (8.14.6/8.14.5/Submit) id r4DKSOrL076291; Mon, 13 May 2013 20:28:24 GMT (envelope-from asomers@svn.freebsd.org) Message-Id: <201305132028.r4DKSOrL076291@svn.freebsd.org> From: Alan Somers Date: Mon, 13 May 2013 20:28:24 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r250617 - head/etc/rc.d X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 13 May 2013 20:28:24 -0000 Author: asomers Date: Mon May 13 20:28:24 2013 New Revision: 250617 URL: http://svnweb.freebsd.org/changeset/base/250617 Log: etc/rc.d/syslogd Add netif as a requirement of syslogd to get lo0 up. Currently, this doesn't affect the rc order, because mountcritremote already depends on netif. Reviewed by: eadler Approved by: kenm (mentor) MFC after: 2 weeks Modified: head/etc/rc.d/syslogd Modified: head/etc/rc.d/syslogd ============================================================================== --- head/etc/rc.d/syslogd Mon May 13 20:14:58 2013 (r250616) +++ head/etc/rc.d/syslogd Mon May 13 20:28:24 2013 (r250617) @@ -3,8 +3,10 @@ # $FreeBSD$ # +# netif is required for lo0 because syslogd tries to open a local socket +# # PROVIDE: syslogd -# REQUIRE: mountcritremote FILESYSTEMS newsyslog +# REQUIRE: mountcritremote FILESYSTEMS newsyslog netif # BEFORE: SERVERS . /etc/rc.subr From owner-svn-src-all@FreeBSD.ORG Mon May 13 21:17:28 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id 7ABC0B75; Mon, 13 May 2013 21:17:28 +0000 (UTC) (envelope-from adrian@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id 6A80FACF; Mon, 13 May 2013 21:17:28 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.6/8.14.6) with ESMTP id r4DLHSQg093788; Mon, 13 May 2013 21:17:28 GMT (envelope-from adrian@svn.freebsd.org) Received: (from adrian@localhost) by svn.freebsd.org (8.14.6/8.14.5/Submit) id r4DLHSTl093787; Mon, 13 May 2013 21:17:28 GMT (envelope-from adrian@svn.freebsd.org) Message-Id: <201305132117.r4DLHSTl093787@svn.freebsd.org> From: Adrian Chadd Date: Mon, 13 May 2013 21:17:28 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r250618 - head/sys/dev/ath X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 13 May 2013 21:17:28 -0000 Author: adrian Date: Mon May 13 21:17:27 2013 New Revision: 250618 URL: http://svnweb.freebsd.org/changeset/base/250618 Log: Support sending ATH_ALQ messages with no payload. Modified: head/sys/dev/ath/if_ath_alq.c Modified: head/sys/dev/ath/if_ath_alq.c ============================================================================== --- head/sys/dev/ath/if_ath_alq.c Mon May 13 20:28:24 2013 (r250617) +++ head/sys/dev/ath/if_ath_alq.c Mon May 13 21:17:27 2013 (r250618) @@ -184,9 +184,11 @@ if_ath_alq_post(struct if_ath_alq *alq, /* * Copy the payload _after_ the header field. */ - memcpy(((char *) ap) + sizeof(struct if_ath_alq_hdr), - buf, - len); + if (buf != NULL) { + memcpy(((char *) ap) + sizeof(struct if_ath_alq_hdr), + buf, + len); + } alq_post(alq->sc_alq_alq, ale); } From owner-svn-src-all@FreeBSD.ORG Mon May 13 21:18:01 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id 3163DCEA; Mon, 13 May 2013 21:18:01 +0000 (UTC) (envelope-from adrian@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id 0979DAD9; Mon, 13 May 2013 21:18:01 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.6/8.14.6) with ESMTP id r4DLI0kk093913; Mon, 13 May 2013 21:18:00 GMT (envelope-from adrian@svn.freebsd.org) Received: (from adrian@localhost) by svn.freebsd.org (8.14.6/8.14.5/Submit) id r4DLI0lI093907; Mon, 13 May 2013 21:18:00 GMT (envelope-from adrian@svn.freebsd.org) Message-Id: <201305132118.r4DLI0lI093907@svn.freebsd.org> From: Adrian Chadd Date: Mon, 13 May 2013 21:18:00 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r250619 - head/sys/dev/ath X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 13 May 2013 21:18:01 -0000 Author: adrian Date: Mon May 13 21:18:00 2013 New Revision: 250619 URL: http://svnweb.freebsd.org/changeset/base/250619 Log: Add ALQ beacon debugging. Modified: head/sys/dev/ath/if_ath.c head/sys/dev/ath/if_ath_alq.h head/sys/dev/ath/if_ath_beacon.c Modified: head/sys/dev/ath/if_ath.c ============================================================================== --- head/sys/dev/ath/if_ath.c Mon May 13 21:17:27 2013 (r250618) +++ head/sys/dev/ath/if_ath.c Mon May 13 21:18:00 2013 (r250619) @@ -3058,6 +3058,11 @@ ath_bstuck_proc(void *arg, int pending) if (ath_hal_gethangstate(sc->sc_ah, 0xff, &hangs) && hangs != 0) if_printf(ifp, "bb hang detected (0x%x)\n", hangs); +#ifdef ATH_DEBUG_ALQ + if (if_ath_alq_checkdebug(&sc->sc_alq, ATH_ALQ_STUCK_BEACON)) + if_ath_alq_post(&sc->sc_alq, ATH_ALQ_STUCK_BEACON, 0, NULL); +#endif + if_printf(ifp, "stuck beacon; resetting (bmiss count %u)\n", sc->sc_bmisscount); sc->sc_stats.ast_bstuck++; Modified: head/sys/dev/ath/if_ath_alq.h ============================================================================== --- head/sys/dev/ath/if_ath_alq.h Mon May 13 21:17:27 2013 (r250618) +++ head/sys/dev/ath/if_ath_alq.h Mon May 13 21:18:00 2013 (r250619) @@ -99,6 +99,20 @@ struct if_ath_alq_interrupt { uint32_t intr_syncstate; }; +#define ATH_ALQ_MIB_COUNTERS 11 +struct if_ath_alq_mib_counters { + uint32_t valid; + uint32_t tx_busy; + uint32_t rx_busy; + uint32_t chan_busy; + uint32_t ext_chan_busy; + uint32_t cycle_count; +}; + +#define ATH_ALQ_MISSED_BEACON 12 +#define ATH_ALQ_STUCK_BEACON 13 +#define ATH_ALQ_RESUME_BEACON 14 + /* * These will always be logged, regardless. */ Modified: head/sys/dev/ath/if_ath_beacon.c ============================================================================== --- head/sys/dev/ath/if_ath_beacon.c Mon May 13 21:17:27 2013 (r250618) +++ head/sys/dev/ath/if_ath_beacon.c Mon May 13 21:18:00 2013 (r250619) @@ -399,6 +399,11 @@ ath_beacon_miss(struct ath_softc *sc) hangs); } +#ifdef ATH_DEBUG_ALQ + if (if_ath_alq_checkdebug(&sc->sc_alq, ATH_ALQ_MISSED_BEACON)) + if_ath_alq_post(&sc->sc_alq, ATH_ALQ_MISSED_BEACON, 0, NULL); +#endif + DPRINTF(sc, ATH_DEBUG_BEACON, "%s: valid=%d, txbusy=%u, rxbusy=%u, chanbusy=%u, " "extchanbusy=%u, cyclecount=%u\n", @@ -451,6 +456,10 @@ ath_beacon_proc(void *arg, int pending) "%s: resume beacon xmit after %u misses\n", __func__, sc->sc_bmisscount); sc->sc_bmisscount = 0; +#ifdef ATH_DEBUG_ALQ + if (if_ath_alq_checkdebug(&sc->sc_alq, ATH_ALQ_RESUME_BEACON)) + if_ath_alq_post(&sc->sc_alq, ATH_ALQ_RESUME_BEACON, 0, NULL); +#endif } if (sc->sc_stagbeacons) { /* staggered beacons */ From owner-svn-src-all@FreeBSD.ORG Mon May 13 21:31:44 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id 3CE62390; Mon, 13 May 2013 21:31:44 +0000 (UTC) (envelope-from jkim@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id 2F662B83; Mon, 13 May 2013 21:31:44 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.6/8.14.6) with ESMTP id r4DLViT5099669; Mon, 13 May 2013 21:31:44 GMT (envelope-from jkim@svn.freebsd.org) Received: (from jkim@localhost) by svn.freebsd.org (8.14.6/8.14.5/Submit) id r4DLVirj099668; Mon, 13 May 2013 21:31:44 GMT (envelope-from jkim@svn.freebsd.org) Message-Id: <201305132131.r4DLVirj099668@svn.freebsd.org> From: Jung-uk Kim Date: Mon, 13 May 2013 21:31:44 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-vendor@freebsd.org Subject: svn commit: r250620 - vendor/flex/dist X-SVN-Group: vendor MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 13 May 2013 21:31:44 -0000 Author: jkim Date: Mon May 13 21:31:43 2013 New Revision: 250620 URL: http://svnweb.freebsd.org/changeset/base/250620 Log: Partially revert r250128. http://flex.git.sourceforge.net/git/gitweb.cgi?p=flex/flex;a=commit;h=ec2fdb8 This patch is known to generate a broken scanner. http://sourceforge.net/mailarchive/message.php?msg_id=29909582 Modified: vendor/flex/dist/flex.skl Modified: vendor/flex/dist/flex.skl ============================================================================== --- vendor/flex/dist/flex.skl Mon May 13 21:18:00 2013 (r250619) +++ vendor/flex/dist/flex.skl Mon May 13 21:31:43 2013 (r250620) @@ -1277,6 +1277,8 @@ m4_ifdef( [[M4_YY_NOT_REENTRANT]], ]]) ]]) +%% [7.0] user's declarations go here + m4_ifdef( [[M4_YY_BISON_LVAL]], [[ yylval = yylval_param; @@ -1332,9 +1334,6 @@ m4_ifdef( [[M4_YY_USES_REJECT]], yy_load_buffer_state( M4_YY_CALL_ONLY_ARG ); } - { -%% [7.0] user's declarations go here - while ( 1 ) /* loops until end-of-file is reached */ { %% [8.0] yymore()-related code goes here @@ -1492,7 +1491,6 @@ do_action: /* This label is used only to "fatal flex scanner internal error--no action found" ); } /* end of action switch */ } /* end of scanning one token */ - } /* end of user's declarations */ } /* end of yylex */ %ok-for-header From owner-svn-src-all@FreeBSD.ORG Mon May 13 21:46:08 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id 5B2C7990; Mon, 13 May 2013 21:46:08 +0000 (UTC) (envelope-from ed@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id 4D751CEE; Mon, 13 May 2013 21:46:08 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.6/8.14.6) with ESMTP id r4DLk8vt004009; Mon, 13 May 2013 21:46:08 GMT (envelope-from ed@svn.freebsd.org) Received: (from ed@localhost) by svn.freebsd.org (8.14.6/8.14.5/Submit) id r4DLk8FK004008; Mon, 13 May 2013 21:46:08 GMT (envelope-from ed@svn.freebsd.org) Message-Id: <201305132146.r4DLk8FK004008@svn.freebsd.org> From: Ed Schouten Date: Mon, 13 May 2013 21:46:08 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r250623 - head/sys/sys X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 13 May 2013 21:46:08 -0000 Author: ed Date: Mon May 13 21:46:07 2013 New Revision: 250623 URL: http://svnweb.freebsd.org/changeset/base/250623 Log: Rework the way C11 keywords are defined. Instead of only checking the __STDC_VERSION__, we can also use Clang's __has_extension() to check for features specifically. This allows us to, say, use Clang's native _Static_assert() instead of the typedef hack, making the compiler error messages a lot more readable. Reviewed by: theraven Modified: head/sys/sys/cdefs.h Modified: head/sys/sys/cdefs.h ============================================================================== --- head/sys/sys/cdefs.h Mon May 13 21:44:59 2013 (r250622) +++ head/sys/sys/cdefs.h Mon May 13 21:46:07 2013 (r250623) @@ -36,6 +36,23 @@ #ifndef _SYS_CDEFS_H_ #define _SYS_CDEFS_H_ +/* + * Testing against Clang-specific extensions. + */ + +#ifndef __has_extension +#define __has_extension __has_feature +#endif +#ifndef __has_feature +#define __has_feature(x) 0 +#endif +#ifndef __has_include +#define __has_include(x) 0 +#endif +#ifndef __has_builtin +#define __has_builtin(x) 0 +#endif + #if defined(__cplusplus) #define __BEGIN_DECLS extern "C" { #define __END_DECLS } @@ -232,22 +249,36 @@ /* * Keywords added in C11. */ -#if defined(__cplusplus) && __cplusplus >= 201103L -#define _Alignas(e) alignas(e) -#define _Alignof(e) alignof(e) -#define _Noreturn [[noreturn]] -#define _Static_assert(e, s) static_assert(e, s) -/* FIXME: change this to thread_local when clang in base supports it */ -#define _Thread_local __thread -#elif defined(__STDC_VERSION__) && __STDC_VERSION__ >= 201112L -/* Do nothing. They are language keywords. */ + +#if !defined(__STDC_VERSION__) || __STDC_VERSION__ < 201112L + +#if !__has_extension(c_alignas) +#if (defined(__cplusplus) && __cplusplus >= 201103L) || \ + __has_extension(cxx_alignas) +#define _Alignas(x) alignas(x) #else -/* Not supported. Implement them using our versions. */ +/* XXX: Only emulates _Alignas(constant-expression); not _Alignas(type-name). */ #define _Alignas(x) __aligned(x) +#endif +#endif + +#if defined(__cplusplus) && __cplusplus >= 201103L +#define _Alignof(x) alignof(x) +#else #define _Alignof(x) __alignof(x) +#endif + +#if defined(__cplusplus) && __cplusplus >= 201103L +#define _Noreturn [[noreturn]] +#else #define _Noreturn __dead2 -#define _Thread_local __thread -#ifdef __COUNTER__ +#endif + +#if !__has_extension(c_static_assert) +#if (defined(__cplusplus) && __cplusplus >= 201103L) || \ + __has_extension(cxx_static_assert) +#define _Static_assert(x, y) static_assert(x, y) +#elif defined(__COUNTER__) #define _Static_assert(x, y) __Static_assert(x, __COUNTER__) #define __Static_assert(x, y) ___Static_assert(x, y) #define ___Static_assert(x, y) typedef char __assert_ ## y[(x) ? 1 : -1] @@ -256,6 +287,20 @@ #endif #endif +#if !__has_extension(c_thread_local) +/* XXX: Change this to test against C++11 when clang in base supports it. */ +#if /* (defined(__cplusplus) && __cplusplus >= 201103L) || */ \ + __has_extension(cxx_thread_local) +#define _Thread_local thread_local +#elif defined(lint) +#define _Thread_local +#else +#define _Thread_local __thread +#endif +#endif + +#endif /* __STDC_VERSION__ || __STDC_VERSION__ < 201112L */ + /* * Emulation of C11 _Generic(). Unlike the previously defined C11 * keywords, it is not possible to implement this using exactly the same @@ -682,19 +727,6 @@ #endif #endif -#ifndef __has_extension -#define __has_extension __has_feature -#endif -#ifndef __has_feature -#define __has_feature(x) 0 -#endif -#ifndef __has_include -#define __has_include(x) 0 -#endif -#ifndef __has_builtin -#define __has_builtin(x) 0 -#endif - #if defined(__mips) || defined(__powerpc64__) #define __NO_TLS 1 #endif From owner-svn-src-all@FreeBSD.ORG Mon May 13 21:47:18 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id 4C758B18; Mon, 13 May 2013 21:47:18 +0000 (UTC) (envelope-from ed@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id 23863CFA; Mon, 13 May 2013 21:47:18 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.6/8.14.6) with ESMTP id r4DLlIm1004253; Mon, 13 May 2013 21:47:18 GMT (envelope-from ed@svn.freebsd.org) Received: (from ed@localhost) by svn.freebsd.org (8.14.6/8.14.5/Submit) id r4DLlHBr004251; Mon, 13 May 2013 21:47:17 GMT (envelope-from ed@svn.freebsd.org) Message-Id: <201305132147.r4DLlHBr004251@svn.freebsd.org> From: Ed Schouten Date: Mon, 13 May 2013 21:47:17 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r250624 - in head/sys: amd64/amd64 i386/i386 X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 13 May 2013 21:47:18 -0000 Author: ed Date: Mon May 13 21:47:17 2013 New Revision: 250624 URL: http://svnweb.freebsd.org/changeset/base/250624 Log: Improve readability of static assertions for OFFSET_* macros. Instead of doing all sorts of weird casting of constants to pointer-pointers, simply use the standard C offsetof() macro to obtain the offset of the respective fields in the structures. Modified: head/sys/amd64/amd64/vm_machdep.c head/sys/i386/i386/vm_machdep.c Modified: head/sys/amd64/amd64/vm_machdep.c ============================================================================== --- head/sys/amd64/amd64/vm_machdep.c Mon May 13 21:46:07 2013 (r250623) +++ head/sys/amd64/amd64/vm_machdep.c Mon May 13 21:47:17 2013 (r250624) @@ -90,9 +90,10 @@ static u_int cpu_reset_proxyid; static volatile u_int cpu_reset_proxy_active; #endif -CTASSERT((struct thread **)OFFSETOF_CURTHREAD == - &((struct pcpu *)NULL)->pc_curthread); -CTASSERT((struct pcb **)OFFSETOF_CURPCB == &((struct pcpu *)NULL)->pc_curpcb); +_Static_assert(OFFSETOF_CURTHREAD == offsetof(struct pcpu, pc_curthread), + "OFFSETOF_CURTHREAD does not correspond with offset of pc_curthread."); +_Static_assert(OFFSETOF_CURPCB == offsetof(struct pcpu, pc_curpcb), + "OFFSETOF_CURPCB does not correspond with offset of pc_curpcb."); struct savefpu * get_pcb_user_save_td(struct thread *td) Modified: head/sys/i386/i386/vm_machdep.c ============================================================================== --- head/sys/i386/i386/vm_machdep.c Mon May 13 21:46:07 2013 (r250623) +++ head/sys/i386/i386/vm_machdep.c Mon May 13 21:47:17 2013 (r250624) @@ -106,9 +106,10 @@ __FBSDID("$FreeBSD$"); #define NSFBUFS (512 + maxusers * 16) #endif -CTASSERT((struct thread **)OFFSETOF_CURTHREAD == - &((struct pcpu *)NULL)->pc_curthread); -CTASSERT((struct pcb **)OFFSETOF_CURPCB == &((struct pcpu *)NULL)->pc_curpcb); +_Static_assert(OFFSETOF_CURTHREAD == offsetof(struct pcpu, pc_curthread), + "OFFSETOF_CURTHREAD does not correspond with offset of pc_curthread."); +_Static_assert(OFFSETOF_CURPCB == offsetof(struct pcpu, pc_curpcb), + "OFFSETOF_CURPCB does not correspond with offset of pc_curpcb."); static void cpu_reset_real(void); #ifdef SMP From owner-svn-src-all@FreeBSD.ORG Mon May 13 22:06:46 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id B9458E1; Mon, 13 May 2013 22:06:46 +0000 (UTC) (envelope-from gjb@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id AB472DA3; Mon, 13 May 2013 22:06:46 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.6/8.14.6) with ESMTP id r4DM6kPV011165; Mon, 13 May 2013 22:06:46 GMT (envelope-from gjb@svn.freebsd.org) Received: (from gjb@localhost) by svn.freebsd.org (8.14.6/8.14.5/Submit) id r4DM6k3D011163; Mon, 13 May 2013 22:06:46 GMT (envelope-from gjb@svn.freebsd.org) Message-Id: <201305132206.r4DM6k3D011163@svn.freebsd.org> From: Glen Barber Date: Mon, 13 May 2013 22:06:46 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-release@freebsd.org Subject: svn commit: r250625 - in release/8.4.0: . sys/conf X-SVN-Group: release MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 13 May 2013 22:06:46 -0000 Author: gjb (doc,ports committer) Date: Mon May 13 22:06:46 2013 New Revision: 250625 URL: http://svnweb.freebsd.org/changeset/base/250625 Log: Copy releng/8.4 to release/8.4.0 as part of the 8.4-RELEASE build process. Approved by: re (jpaetzel) Added: release/8.4.0/ - copied from r250624, releng/8.4/ Modified: release/8.4.0/sys/conf/newvers.sh Modified: release/8.4.0/sys/conf/newvers.sh ============================================================================== --- releng/8.4/sys/conf/newvers.sh Mon May 13 21:47:17 2013 (r250624) +++ release/8.4.0/sys/conf/newvers.sh Mon May 13 22:06:46 2013 (r250625) @@ -32,7 +32,7 @@ TYPE="FreeBSD" REVISION="8.4" -BRANCH="RC3" +BRANCH="RELEASE" if [ "X${BRANCH_OVERRIDE}" != "X" ]; then BRANCH=${BRANCH_OVERRIDE} fi From owner-svn-src-all@FreeBSD.ORG Mon May 13 22:16:33 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id 8C6A8547; Mon, 13 May 2013 22:16:33 +0000 (UTC) (envelope-from delphij@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id 7E874E0A; Mon, 13 May 2013 22:16:33 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.6/8.14.6) with ESMTP id r4DMGXah014856; Mon, 13 May 2013 22:16:33 GMT (envelope-from delphij@svn.freebsd.org) Received: (from delphij@localhost) by svn.freebsd.org (8.14.6/8.14.5/Submit) id r4DMGXvn014855; Mon, 13 May 2013 22:16:33 GMT (envelope-from delphij@svn.freebsd.org) Message-Id: <201305132216.r4DMGXvn014855@svn.freebsd.org> From: Xin LI Date: Mon, 13 May 2013 22:16:33 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r250626 - head/rescue/rescue X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 13 May 2013 22:16:33 -0000 Author: delphij Date: Mon May 13 22:16:33 2013 New Revision: 250626 URL: http://svnweb.freebsd.org/changeset/base/250626 Log: Add less to rescue build. On amd64, this increases rescue size by about 130KB or 2.4%. MFC after: 1 month Modified: head/rescue/rescue/Makefile Modified: head/rescue/rescue/Makefile ============================================================================== --- head/rescue/rescue/Makefile Mon May 13 22:06:46 2013 (r250625) +++ head/rescue/rescue/Makefile Mon May 13 22:16:33 2013 (r250626) @@ -184,6 +184,9 @@ CRUNCH_PROGS_usr.bin+= bzip2 CRUNCH_ALIAS_bzip2= bunzip2 bzcat CRUNCH_LIBS+= -lbz2 +CRUNCH_PROGS_usr.bin+= less +CRUNCH_ALIAS_less= more + CRUNCH_PROGS_usr.bin+= xz CRUNCH_ALIAS_xz= unxz lzma unlzma xzcat lzcat CRUNCH_LIBS+= -llzma From owner-svn-src-all@FreeBSD.ORG Mon May 13 22:38:31 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id 7F8D4E33; Mon, 13 May 2013 22:38:31 +0000 (UTC) (envelope-from gjb@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id 71CC0ED8; Mon, 13 May 2013 22:38:31 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.6/8.14.6) with ESMTP id r4DMcV6S021967; Mon, 13 May 2013 22:38:31 GMT (envelope-from gjb@svn.freebsd.org) Received: (from gjb@localhost) by svn.freebsd.org (8.14.6/8.14.5/Submit) id r4DMcVF0021966; Mon, 13 May 2013 22:38:31 GMT (envelope-from gjb@svn.freebsd.org) Message-Id: <201305132238.r4DMcVF0021966@svn.freebsd.org> From: Glen Barber Date: Mon, 13 May 2013 22:38:31 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-releng@freebsd.org Subject: svn commit: r250628 - releng/8.4/sys/conf X-SVN-Group: releng MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 13 May 2013 22:38:31 -0000 Author: gjb (doc,ports committer) Date: Mon May 13 22:38:30 2013 New Revision: 250628 URL: http://svnweb.freebsd.org/changeset/base/250628 Log: Update releng/8.4 branch to -RELEASE status, pending final preparation. Approved by: re (implicit) Modified: releng/8.4/sys/conf/newvers.sh Modified: releng/8.4/sys/conf/newvers.sh ============================================================================== --- releng/8.4/sys/conf/newvers.sh Mon May 13 22:34:55 2013 (r250627) +++ releng/8.4/sys/conf/newvers.sh Mon May 13 22:38:30 2013 (r250628) @@ -32,7 +32,7 @@ TYPE="FreeBSD" REVISION="8.4" -BRANCH="RC3" +BRANCH="RELEASE" if [ "X${BRANCH_OVERRIDE}" != "X" ]; then BRANCH=${BRANCH_OVERRIDE} fi From owner-svn-src-all@FreeBSD.ORG Mon May 13 22:40:11 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id 7933BFAF; Mon, 13 May 2013 22:40:11 +0000 (UTC) (envelope-from gjb@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id 52880EEE; Mon, 13 May 2013 22:40:11 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.6/8.14.6) with ESMTP id r4DMeBBQ022345; Mon, 13 May 2013 22:40:11 GMT (envelope-from gjb@svn.freebsd.org) Received: (from gjb@localhost) by svn.freebsd.org (8.14.6/8.14.5/Submit) id r4DMeBgc022344; Mon, 13 May 2013 22:40:11 GMT (envelope-from gjb@svn.freebsd.org) Message-Id: <201305132240.r4DMeBgc022344@svn.freebsd.org> From: Glen Barber Date: Mon, 13 May 2013 22:40:11 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-release@freebsd.org Subject: svn commit: r250629 - release/8.4.0 X-SVN-Group: release MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 13 May 2013 22:40:11 -0000 Author: gjb (doc,ports committer) Date: Mon May 13 22:40:10 2013 New Revision: 250629 URL: http://svnweb.freebsd.org/changeset/base/250629 Log: Delete incorrect release/8.4.0 tag, which contained differences from releng/8.4 branch. Approved by: re (implicit) Pointed out by: delphij Deleted: release/8.4.0/ From owner-svn-src-all@FreeBSD.ORG Tue May 14 01:56:59 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id C53A1AED for ; Tue, 14 May 2013 01:56:59 +0000 (UTC) (envelope-from lists@eitanadler.com) Received: from mail-pb0-x22f.google.com (mail-pb0-x22f.google.com [IPv6:2607:f8b0:400e:c01::22f]) by mx1.freebsd.org (Postfix) with ESMTP id 9E888813 for ; Tue, 14 May 2013 01:56:59 +0000 (UTC) Received: by mail-pb0-f47.google.com with SMTP id rr4so1639552pbb.6 for ; Mon, 13 May 2013 18:56:59 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=eitanadler.com; s=0xdeadbeef; h=x-received:mime-version:sender:in-reply-to:references:from:date :x-google-sender-auth:message-id:subject:to:cc:content-type; bh=3qT/8M8Z3bNt7iN1GLLJo0RiOOtMDoU5mToNY5h6wLA=; b=QMAb1+FwruM6wgvVNrU7yxQ9eVkCYCWPk5p4CJJUSgt2xUMSv0tyeH9rPbDmfX+HxE JLDmnd908rbUqINSi6KfqA3tLSFsEynzW4hOBcZ1WIforT2y/rn+vCqpvDr1SgM9qIOY EzIF8fPkd0PKdoQdq3qt4gJecRBu9gljeY0d4= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20120113; h=x-received:mime-version:sender:in-reply-to:references:from:date :x-google-sender-auth:message-id:subject:to:cc:content-type :x-gm-message-state; bh=3qT/8M8Z3bNt7iN1GLLJo0RiOOtMDoU5mToNY5h6wLA=; b=dNSUMMs8BoF3KMn17X7a+Jv1wXsae1dqGBx9PGlgyOQ5KVqr1weEzuwm38StQ3Wr7T 3/Nj9QulNaHsJqCMi6UMdnizPRZVafjNqkAGoAMQubfRmnVguxD0J2ymY/hEjca1fh0k DZxb8bT4F8nRsA0h+6ObrnA4kUEUyqEjzk5h24V8Nwh9ScWdaTE7CgKNfe9PBPU4em27 htJULIEDe/ZJ25/kGEyF2UV4tFV4yxkIj9qTV0F/URjslJcoZRTPl1ah6CiprOLCYIM+ 2Bu0DMai9TJ1e9BEln4gGpr9zHBn9Bw6FJ6REzMwSSfGlCFf9isn0XTPlWTApn2JwQ7y 4lXw== X-Received: by 10.68.197.165 with SMTP id iv5mr31119387pbc.213.1368496619422; Mon, 13 May 2013 18:56:59 -0700 (PDT) MIME-Version: 1.0 Sender: lists@eitanadler.com Received: by 10.70.67.130 with HTTP; Mon, 13 May 2013 18:56:29 -0700 (PDT) In-Reply-To: <201305131953.r4DJrKSx062788@svn.freebsd.org> References: <201305131953.r4DJrKSx062788@svn.freebsd.org> From: Eitan Adler Date: Mon, 13 May 2013 21:56:29 -0400 X-Google-Sender-Auth: RmeYifQXEgGGaSouNvMPXtNbdRg Message-ID: Subject: Re: svn commit: r250612 - head/tools/test/hwpmc To: Hiren Panchasara Content-Type: text/plain; charset=UTF-8 X-Gm-Message-State: ALoCoQkJowOF3DMpKYIo3xDVpxLghvYpqYYVvX2zjskKe+PKmtde19qC080diXteBRZ87tvceFP0 Cc: svn-src-head@freebsd.org, svn-src-all@freebsd.org, src-committers@freebsd.org X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 14 May 2013 01:56:59 -0000 On 13 May 2013 15:53, Hiren Panchasara wrote: > Author: hiren > Date: Mon May 13 19:53:19 2013 > New Revision: 250612 > URL: http://svnweb.freebsd.org/changeset/base/250612 > > Log: > As python3 does not have raw_input(), convert it to input() when we > are using python3. Thank you. -- Eitan Adler Source, Ports, Doc committer Bugmeister, Ports Security teams From owner-svn-src-all@FreeBSD.ORG Tue May 14 03:21:23 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id 32E2F789; Tue, 14 May 2013 03:21:23 +0000 (UTC) (envelope-from dteske@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id 22433DB1; Tue, 14 May 2013 03:21:23 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.6/8.14.6) with ESMTP id r4E3LN3h024756; Tue, 14 May 2013 03:21:23 GMT (envelope-from dteske@svn.freebsd.org) Received: (from dteske@localhost) by svn.freebsd.org (8.14.6/8.14.5/Submit) id r4E3LEHH024689; Tue, 14 May 2013 03:21:14 GMT (envelope-from dteske@svn.freebsd.org) Message-Id: <201305140321.r4E3LEHH024689@svn.freebsd.org> From: Devin Teske Date: Tue, 14 May 2013 03:21:14 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r250633 - in head/usr.sbin/bsdconfig: . console diskmgmt docsinstall mouse networking packages password security share startup timezone ttys usermgmt X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 14 May 2013 03:21:23 -0000 Author: dteske Date: Tue May 14 03:21:13 2013 New Revision: 250633 URL: http://svnweb.freebsd.org/changeset/base/250633 Log: Centralize standard getopts arguments, both for convenience and to correct a bug in which certain combinations of arguments produced unexpected results such as `-dX' (now properly produces debugging and X11), `-XS' (now properly produces X11 in secure mode), `-df-' (enables debugging when reading a script from standard-input, etc. Multi-word variations such as `-d -X', `-X -S', `-d -f-', `-d -f -', etc. also work as expected. Also tested were variations in argument order, which are now working as expected. Modified: head/usr.sbin/bsdconfig/bsdconfig head/usr.sbin/bsdconfig/console/console head/usr.sbin/bsdconfig/console/font head/usr.sbin/bsdconfig/console/keymap head/usr.sbin/bsdconfig/console/repeat head/usr.sbin/bsdconfig/console/saver head/usr.sbin/bsdconfig/console/screenmap head/usr.sbin/bsdconfig/console/ttys head/usr.sbin/bsdconfig/diskmgmt/diskmgmt head/usr.sbin/bsdconfig/docsinstall/docsinstall head/usr.sbin/bsdconfig/mouse/disable head/usr.sbin/bsdconfig/mouse/enable head/usr.sbin/bsdconfig/mouse/flags head/usr.sbin/bsdconfig/mouse/mouse head/usr.sbin/bsdconfig/mouse/port head/usr.sbin/bsdconfig/mouse/type head/usr.sbin/bsdconfig/networking/defaultrouter head/usr.sbin/bsdconfig/networking/devices head/usr.sbin/bsdconfig/networking/hostname head/usr.sbin/bsdconfig/networking/nameservers head/usr.sbin/bsdconfig/networking/networking head/usr.sbin/bsdconfig/packages/packages head/usr.sbin/bsdconfig/password/password head/usr.sbin/bsdconfig/security/kern_securelevel head/usr.sbin/bsdconfig/security/security head/usr.sbin/bsdconfig/share/common.subr head/usr.sbin/bsdconfig/share/dialog.subr head/usr.sbin/bsdconfig/startup/misc head/usr.sbin/bsdconfig/startup/rcadd head/usr.sbin/bsdconfig/startup/rcconf head/usr.sbin/bsdconfig/startup/rcdelete head/usr.sbin/bsdconfig/startup/rcedit head/usr.sbin/bsdconfig/startup/rcvar head/usr.sbin/bsdconfig/startup/startup head/usr.sbin/bsdconfig/timezone/timezone head/usr.sbin/bsdconfig/ttys/ttys head/usr.sbin/bsdconfig/usermgmt/groupadd head/usr.sbin/bsdconfig/usermgmt/groupdel head/usr.sbin/bsdconfig/usermgmt/groupedit head/usr.sbin/bsdconfig/usermgmt/useradd head/usr.sbin/bsdconfig/usermgmt/userdel head/usr.sbin/bsdconfig/usermgmt/useredit head/usr.sbin/bsdconfig/usermgmt/usermgmt Modified: head/usr.sbin/bsdconfig/bsdconfig ============================================================================== --- head/usr.sbin/bsdconfig/bsdconfig Tue May 14 01:27:56 2013 (r250632) +++ head/usr.sbin/bsdconfig/bsdconfig Tue May 14 03:21:13 2013 (r250633) @@ -239,7 +239,7 @@ fi # Process command-line arguments # scripts_loaded=0 -while getopts dD:f:hSX flag; do +while getopts f:h$GETOPTS_STDARGS flag; do case "$flag" in f) [ $scripts_loaded -eq 0 ] && f_include $BSDCFG_SHARE/script.subr f_script_load "$OPTARG" Modified: head/usr.sbin/bsdconfig/console/console ============================================================================== --- head/usr.sbin/bsdconfig/console/console Tue May 14 01:27:56 2013 (r250632) +++ head/usr.sbin/bsdconfig/console/console Tue May 14 03:21:13 2013 (r250633) @@ -95,7 +95,7 @@ dialog_menu_main() # # Process command-line arguments # -while getopts dD:hSX flag; do +while getopts h$GETOPTS_STDARGS flag; do case "$flag" in h|\?) f_usage $BSDCFG_LIBE/$APP_DIR/USAGE "PROGRAM_NAME" "$pgm";; esac Modified: head/usr.sbin/bsdconfig/console/font ============================================================================== --- head/usr.sbin/bsdconfig/console/font Tue May 14 01:27:56 2013 (r250632) +++ head/usr.sbin/bsdconfig/console/font Tue May 14 03:21:13 2013 (r250633) @@ -119,7 +119,7 @@ dialog_menu_main() # # Process command-line arguments # -while getopts dD:hSX flag; do +while getopts h$GETOPTS_STDARGS flag; do case "$flag" in h|\?) f_usage $BSDCFG_LIBE/$APP_DIR/USAGE "PROGRAM_NAME" "$pgm";; esac Modified: head/usr.sbin/bsdconfig/console/keymap ============================================================================== --- head/usr.sbin/bsdconfig/console/keymap Tue May 14 01:27:56 2013 (r250632) +++ head/usr.sbin/bsdconfig/console/keymap Tue May 14 03:21:13 2013 (r250633) @@ -217,7 +217,7 @@ dialog_menu_main() # # Process command-line arguments # -while getopts dD:hSX flag; do +while getopts h$GETOPTS_STDARGS flag; do case "$flag" in h|\?) f_usage $BSDCFG_LIBE/$APP_DIR/USAGE "PROGRAM_NAME" "$pgm";; esac Modified: head/usr.sbin/bsdconfig/console/repeat ============================================================================== --- head/usr.sbin/bsdconfig/console/repeat Tue May 14 01:27:56 2013 (r250632) +++ head/usr.sbin/bsdconfig/console/repeat Tue May 14 03:21:13 2013 (r250633) @@ -99,7 +99,7 @@ dialog_menu_main() # # Process command-line arguments # -while getopts dD:hSX flag; do +while getopts h$GETOPTS_STDARGS flag; do case "$flag" in h|\?) f_usage $BSDCFG_LIBE/$APP_DIR/USAGE "PROGRAM_NAME" "$pgm";; esac Modified: head/usr.sbin/bsdconfig/console/saver ============================================================================== --- head/usr.sbin/bsdconfig/console/saver Tue May 14 01:27:56 2013 (r250632) +++ head/usr.sbin/bsdconfig/console/saver Tue May 14 03:21:13 2013 (r250633) @@ -118,7 +118,7 @@ dialog_menu_main() # # Process command-line arguments # -while getopts dD:hSX flag; do +while getopts h$GETOPTS_STDARGS flag; do case "$flag" in h|\?) f_usage $BSDCFG_LIBE/$APP_DIR/USAGE "PROGRAM_NAME" "$pgm";; esac Modified: head/usr.sbin/bsdconfig/console/screenmap ============================================================================== --- head/usr.sbin/bsdconfig/console/screenmap Tue May 14 01:27:56 2013 (r250632) +++ head/usr.sbin/bsdconfig/console/screenmap Tue May 14 03:21:13 2013 (r250633) @@ -103,7 +103,7 @@ dialog_menu_main() # # Process command-line arguments # -while getopts dD:hSX flag; do +while getopts h$GETOPTS_STDARGS flag; do case "$flag" in h|\?) f_usage $BSDCFG_LIBE/$APP_DIR/USAGE "PROGRAM_NAME" "$pgm";; esac Modified: head/usr.sbin/bsdconfig/console/ttys ============================================================================== --- head/usr.sbin/bsdconfig/console/ttys Tue May 14 01:27:56 2013 (r250632) +++ head/usr.sbin/bsdconfig/console/ttys Tue May 14 03:21:13 2013 (r250633) @@ -163,7 +163,7 @@ ttys_set_type() # # Process command-line arguments # -while getopts dD:hSX flag; do +while getopts h$GETOPTS_STDARGS flag; do case "$flag" in h|\?) f_usage $BSDCFG_LIBE/$APP_DIR/USAGE "PROGRAM_NAME" "$pgm";; esac Modified: head/usr.sbin/bsdconfig/diskmgmt/diskmgmt ============================================================================== --- head/usr.sbin/bsdconfig/diskmgmt/diskmgmt Tue May 14 01:27:56 2013 (r250632) +++ head/usr.sbin/bsdconfig/diskmgmt/diskmgmt Tue May 14 03:21:13 2013 (r250633) @@ -56,7 +56,7 @@ X11TERM_OPTS= # # Process command-line arguments # -while getopts dD:hSX flag; do +while getopts h$GETOPTS_STDARGS flag; do case "$flag" in h|\?) f_usage $BSDCFG_LIBE/$APP_DIR/USAGE "PROGRAM_NAME" "$pgm";; esac Modified: head/usr.sbin/bsdconfig/docsinstall/docsinstall ============================================================================== --- head/usr.sbin/bsdconfig/docsinstall/docsinstall Tue May 14 01:27:56 2013 (r250632) +++ head/usr.sbin/bsdconfig/docsinstall/docsinstall Tue May 14 03:21:13 2013 (r250633) @@ -56,7 +56,7 @@ X11TERM_OPTS= # # Process command-line arguments # -while getopts dD:hSX flag; do +while getopts h$GETOPTS_STDARGS flag; do case "$flag" in h|\?) f_usage $BSDCFG_LIBE/$APP_DIR/USAGE "PROGRAM_NAME" "$pgm";; esac Modified: head/usr.sbin/bsdconfig/mouse/disable ============================================================================== --- head/usr.sbin/bsdconfig/mouse/disable Tue May 14 01:27:56 2013 (r250632) +++ head/usr.sbin/bsdconfig/mouse/disable Tue May 14 03:21:13 2013 (r250633) @@ -56,7 +56,7 @@ MOUSED_PIDFILE=/var/run/moused.pid # # Process command-line arguments # -while getopts dD:hSX flag; do +while getopts h$GETOPTS_STDARGS flag; do case "$flag" in h|\?) f_usage $BSDCFG_LIBE/$APP_DIR/USAGE "PROGRAM_NAME" "$pgm";; esac Modified: head/usr.sbin/bsdconfig/mouse/enable ============================================================================== --- head/usr.sbin/bsdconfig/mouse/enable Tue May 14 01:27:56 2013 (r250632) +++ head/usr.sbin/bsdconfig/mouse/enable Tue May 14 03:21:13 2013 (r250633) @@ -56,7 +56,7 @@ MOUSED_PIDFILE=/var/run/moused.pid # # Process command-line arguments # -while getopts dD:hSX flag; do +while getopts h$GETOPTS_STDARGS flag; do case "$flag" in h|\?) f_usage $BSDCFG_LIBE/$APP_DIR/USAGE "PROGRAM_NAME" "$pgm";; esac Modified: head/usr.sbin/bsdconfig/mouse/flags ============================================================================== --- head/usr.sbin/bsdconfig/mouse/flags Tue May 14 01:27:56 2013 (r250632) +++ head/usr.sbin/bsdconfig/mouse/flags Tue May 14 03:21:13 2013 (r250633) @@ -56,7 +56,7 @@ MOUSED_PIDFILE=/var/run/moused.pid # # Process command-line arguments # -while getopts dD:hSX flag; do +while getopts h$GETOPTS_STDARGS flag; do case "$flag" in h|\?) f_usage $BSDCFG_LIBE/$APP_DIR/USAGE "PROGRAM_NAME" "$pgm";; esac Modified: head/usr.sbin/bsdconfig/mouse/mouse ============================================================================== --- head/usr.sbin/bsdconfig/mouse/mouse Tue May 14 01:27:56 2013 (r250632) +++ head/usr.sbin/bsdconfig/mouse/mouse Tue May 14 03:21:13 2013 (r250633) @@ -94,7 +94,7 @@ dialog_menu_main() # # Process command-line arguments # -while getopts dD:hSX flag; do +while getopts h$GETOPTS_STDARGS flag; do case "$flag" in h|\?) f_usage $BSDCFG_LIBE/$APP_DIR/USAGE "PROGRAM_NAME" "$pgm";; esac Modified: head/usr.sbin/bsdconfig/mouse/port ============================================================================== --- head/usr.sbin/bsdconfig/mouse/port Tue May 14 01:27:56 2013 (r250632) +++ head/usr.sbin/bsdconfig/mouse/port Tue May 14 03:21:13 2013 (r250633) @@ -103,7 +103,7 @@ dialog_menu_main() # # Process command-line arguments # -while getopts dD:hSX flag; do +while getopts h$GETOPTS_STDARGS flag; do case "$flag" in h|\?) f_usage $BSDCFG_LIBE/$APP_DIR/USAGE "PROGRAM_NAME" "$pgm";; esac Modified: head/usr.sbin/bsdconfig/mouse/type ============================================================================== --- head/usr.sbin/bsdconfig/mouse/type Tue May 14 01:27:56 2013 (r250632) +++ head/usr.sbin/bsdconfig/mouse/type Tue May 14 03:21:13 2013 (r250633) @@ -111,7 +111,7 @@ dialog_menu_main() # # Process command-line arguments # -while getopts dD:hSX flag; do +while getopts h$GETOPTS_STDARGS flag; do case "$flag" in h|\?) f_usage $BSDCFG_LIBE/$APP_DIR/USAGE "PROGRAM_NAME" "$pgm";; esac Modified: head/usr.sbin/bsdconfig/networking/defaultrouter ============================================================================== --- head/usr.sbin/bsdconfig/networking/defaultrouter Tue May 14 01:27:56 2013 (r250632) +++ head/usr.sbin/bsdconfig/networking/defaultrouter Tue May 14 03:21:13 2013 (r250633) @@ -49,7 +49,7 @@ ipgm=$( f_index_menusel_keyword $BSDCFG_ # # Process command-line arguments # -while getopts dD:hSX flag; do +while getopts h$GETOPTS_STDARGS flag; do case "$flag" in h|\?) f_usage $BSDCFG_LIBE/$APP_DIR/USAGE "PROGRAM_NAME" "$pgm";; esac Modified: head/usr.sbin/bsdconfig/networking/devices ============================================================================== --- head/usr.sbin/bsdconfig/networking/devices Tue May 14 01:27:56 2013 (r250632) +++ head/usr.sbin/bsdconfig/networking/devices Tue May 14 03:21:13 2013 (r250633) @@ -54,7 +54,7 @@ ipgm=$( f_index_menusel_keyword $BSDCFG_ # # Process command-line options # -while getopts dD:hSX flag; do +while getopts h$GETOPTS_STDARGS flag; do case "$flag" in h|\?) f_usage $BSDCFG_LIBE/$APP_DIR/USAGE "PROGRAM_NAME" "$pgm";; esac Modified: head/usr.sbin/bsdconfig/networking/hostname ============================================================================== --- head/usr.sbin/bsdconfig/networking/hostname Tue May 14 01:27:56 2013 (r250632) +++ head/usr.sbin/bsdconfig/networking/hostname Tue May 14 03:21:13 2013 (r250633) @@ -52,7 +52,7 @@ ipgm=$( f_index_menusel_keyword $BSDCFG_ # # Process command-line arguments # -while getopts dD:hSX flag; do +while getopts h$GETOPTS_STDARGS flag; do case "$flag" in h|\?) f_usage $BSDCFG_LIBE/$APP_DIR/USAGE "PROGRAM_NAME" "$pgm";; esac Modified: head/usr.sbin/bsdconfig/networking/nameservers ============================================================================== --- head/usr.sbin/bsdconfig/networking/nameservers Tue May 14 01:27:56 2013 (r250632) +++ head/usr.sbin/bsdconfig/networking/nameservers Tue May 14 03:21:13 2013 (r250633) @@ -52,7 +52,7 @@ ipgm=$( f_index_menusel_keyword $BSDCFG_ # # Process command-line arguments # -while getopts dD:hSX flag; do +while getopts h$GETOPTS_STDARGS flag; do case "$flag" in h|\?) f_usage $BSDCFG_LIBE/$APP_DIR/USAGE "PROGRAM_NAME" "$pgm";; esac Modified: head/usr.sbin/bsdconfig/networking/networking ============================================================================== --- head/usr.sbin/bsdconfig/networking/networking Tue May 14 01:27:56 2013 (r250632) +++ head/usr.sbin/bsdconfig/networking/networking Tue May 14 03:21:13 2013 (r250633) @@ -91,7 +91,7 @@ dialog_menu_main() # # Process command-line arguments # -while getopts dD:hSX flag; do +while getopts h$GETOPTS_STDARGS flag; do case "$flag" in h|\?) f_usage $BSDCFG_LIBE/$APP_DIR/USAGE "PROGRAM_NAME" "$pgm";; esac Modified: head/usr.sbin/bsdconfig/packages/packages ============================================================================== --- head/usr.sbin/bsdconfig/packages/packages Tue May 14 01:27:56 2013 (r250632) +++ head/usr.sbin/bsdconfig/packages/packages Tue May 14 03:21:13 2013 (r250633) @@ -55,7 +55,7 @@ ipgm=$( f_index_menusel_keyword $BSDCFG_ # # Process command-line arguments # -while getopts dD:hSX flag; do +while getopts h$GETOPTS_STDARGS flag; do case "$flag" in h|\?) f_usage $BSDCFG_LIBE/$APP_DIR/USAGE "PROGRAM_NAME" "$pgm";; esac Modified: head/usr.sbin/bsdconfig/password/password ============================================================================== --- head/usr.sbin/bsdconfig/password/password Tue May 14 01:27:56 2013 (r250632) +++ head/usr.sbin/bsdconfig/password/password Tue May 14 03:21:13 2013 (r250633) @@ -55,7 +55,7 @@ USER_ROOT=root # # Process command-line arguments # -while getopts dD:hSX flag; do +while getopts h$GETOPTS_STDARGS flag; do case "$flag" in h|\?) f_usage $BSDCFG_LIBE/$APP_DIR/USAGE "PROGRAM_NAME" "$pgm";; esac Modified: head/usr.sbin/bsdconfig/security/kern_securelevel ============================================================================== --- head/usr.sbin/bsdconfig/security/kern_securelevel Tue May 14 01:27:56 2013 (r250632) +++ head/usr.sbin/bsdconfig/security/kern_securelevel Tue May 14 03:21:13 2013 (r250633) @@ -108,7 +108,7 @@ dialog_menu_main() # # Process command-line arguments # -while getopts dD:hSX flag; do +while getopts h$GETOPTS_STDARGS flag; do case "$flag" in h|\?) f_usage $BSDCFG_LIBE/$APP_DIR/USAGE "PROGRAM_NAME" "$pgm";; esac Modified: head/usr.sbin/bsdconfig/security/security ============================================================================== --- head/usr.sbin/bsdconfig/security/security Tue May 14 01:27:56 2013 (r250632) +++ head/usr.sbin/bsdconfig/security/security Tue May 14 03:21:13 2013 (r250633) @@ -133,7 +133,7 @@ dialog_menu_main() # # Process command-line arguments # -while getopts dD:hSX flag; do +while getopts h$GETOPTS_STDARGS flag; do case "$flag" in h|\?) f_usage $BSDCFG_LIBE/$APP_DIR/USAGE "PROGRAM_NAME" "$pgm";; esac Modified: head/usr.sbin/bsdconfig/share/common.subr ============================================================================== --- head/usr.sbin/bsdconfig/share/common.subr Tue May 14 01:27:56 2013 (r250632) +++ head/usr.sbin/bsdconfig/share/common.subr Tue May 14 03:21:13 2013 (r250633) @@ -67,6 +67,16 @@ export UNAME_R="$(uname -r)" # Release L # : ${DEBUG_SELF_INITIALIZE=1} +# +# Define standard optstring arguments that should be supported by all programs +# using this include (unless DEBUG_SELF_INITIALIZE is set to NULL to prevent +# f_debug_init() from autamatically processing "$@" for the below arguments): +# +# d Sets $debug to 1 +# D: Sets $debugFile to $OPTARG +# +GETOPTS_STDARGS="dD:" + ############################################################ FUNCTIONS # f_dprintf $fmt [ $opts ... ] @@ -102,7 +112,9 @@ f_debug_init() # set -- $ARGV local OPTIND - while getopts dD: flag > /dev/null; do + f_dprintf "f_debug_init: ARGV=[%s] GETOPTS_STDARGS=[%s]" \ + "$ARGV" "$GETOPTS_STDARGS" + while getopts "$GETOPTS_STDARGS" flag > /dev/null; do case "$flag" in d) debug=1;; D) debugFile="$OPTARG";; @@ -110,6 +122,8 @@ f_debug_init() esac done shift $(( $OPTIND - 1 )) + f_dprintf "f_debug_init: debug=[%s] debugFile=[%s]" \ + "$debug" "$debugFile" # # Automagically enable debugging if debugFile is set (and non-NULL) Modified: head/usr.sbin/bsdconfig/share/dialog.subr ============================================================================== --- head/usr.sbin/bsdconfig/share/dialog.subr Tue May 14 01:27:56 2013 (r250632) +++ head/usr.sbin/bsdconfig/share/dialog.subr Tue May 14 03:21:13 2013 (r250633) @@ -1531,24 +1531,36 @@ f_dialog_init() eval exec $DIALOG_TERMINAL_PASSTHRU_FD\>\&1 # + # Add `-S' and `-X' to the list of standard arguments supported by all + # + case "$GETOPTS_STDARGS" in + *SX*) : good ;; # already present + *) GETOPTS_STDARGS="${GETOPTS_STDARGS}SX" + esac + + # # Process stored command-line arguments # - SECURE=$( set -- "$ARGV" - while getopts S flag > /dev/null; do + f_dprintf "f_dialog_init: ARGV=[%s] GETOPTS_STDARGS=[%s]" \ + "$ARGV" "$GETOPTS_STDARGS" + SECURE=$( set -- $ARGV + while getopts "$GETOPTS_STDARGS" flag > /dev/null; do case "$flag" in S) echo 1;; \?) continue;; esac done ) - USE_XDIALOG=$( set -- "$ARGV" - while getopts SX flag > /dev/null; do + USE_XDIALOG=$( set -- $ARGV + while getopts $GETOPTS_STDARGS flag > /dev/null; do case "$flag" in S|X) echo 1;; \?) continue;; esac done ) + f_dprintf "f_dialog_init: SECURE=[%s] USE_XDIALOG=[%s]" \ + "$SECURE" "$USE_XDIALOG" # # Process `-X' command-line option Modified: head/usr.sbin/bsdconfig/startup/misc ============================================================================== --- head/usr.sbin/bsdconfig/startup/misc Tue May 14 01:27:56 2013 (r250632) +++ head/usr.sbin/bsdconfig/startup/misc Tue May 14 03:21:13 2013 (r250633) @@ -319,7 +319,7 @@ dialog_input_value() # # Process command-line arguments # -while getopts dD:hSX flag; do +while getopts h$GETOPTS_STDARGS flag; do case "$flag" in h|\?) f_usage $BSDCFG_LIBE/$APP_DIR/USAGE "PROGRAM_NAME" "$pgm";; esac Modified: head/usr.sbin/bsdconfig/startup/rcadd ============================================================================== --- head/usr.sbin/bsdconfig/startup/rcadd Tue May 14 01:27:56 2013 (r250632) +++ head/usr.sbin/bsdconfig/startup/rcadd Tue May 14 03:21:13 2013 (r250633) @@ -97,7 +97,7 @@ dialog_menu_main() # # Process command-line arguments # -while getopts dD:hSX flag; do +while getopts h$GETOPTS_STDARGS flag; do case "$flag" in h|\?) f_usage $BSDCFG_LIBE/$APP_DIR/USAGE "PROGRAM_NAME" "$pgm";; esac Modified: head/usr.sbin/bsdconfig/startup/rcconf ============================================================================== --- head/usr.sbin/bsdconfig/startup/rcconf Tue May 14 01:27:56 2013 (r250632) +++ head/usr.sbin/bsdconfig/startup/rcconf Tue May 14 03:21:13 2013 (r250633) @@ -201,7 +201,7 @@ dialog_menu_main() # # Process command-line arguments # -while getopts dD:hSX flag; do +while getopts h$GETOPTS_STDARGS flag; do case "$flag" in h|\?) f_usage $BSDCFG_LIBE/$APP_DIR/USAGE "PROGRAM_NAME" "$pgm";; esac Modified: head/usr.sbin/bsdconfig/startup/rcdelete ============================================================================== --- head/usr.sbin/bsdconfig/startup/rcdelete Tue May 14 01:27:56 2013 (r250632) +++ head/usr.sbin/bsdconfig/startup/rcdelete Tue May 14 03:21:13 2013 (r250633) @@ -301,7 +301,7 @@ dialog_menu_confirm_delete() # # Process command-line arguments # -while getopts dD:hSX flag; do +while getopts h$GETOPTS_STDARGS flag; do case "$flag" in h|\?) f_usage $BSDCFG_LIBE/$APP_DIR/USAGE "PROGRAM_NAME" "$pgm";; esac Modified: head/usr.sbin/bsdconfig/startup/rcedit ============================================================================== --- head/usr.sbin/bsdconfig/startup/rcedit Tue May 14 01:27:56 2013 (r250632) +++ head/usr.sbin/bsdconfig/startup/rcedit Tue May 14 03:21:13 2013 (r250633) @@ -49,7 +49,7 @@ ipgm=$( f_index_menusel_keyword $BSDCFG_ # # Process command-line arguments # -while getopts dD:hSX flag; do +while getopts h$GETOPTS_STDARGS flag; do case "$flag" in h|\?) f_usage $BSDCFG_LIBE/$APP_DIR/USAGE "PROGRAM_NAME" "$pgm";; esac Modified: head/usr.sbin/bsdconfig/startup/rcvar ============================================================================== --- head/usr.sbin/bsdconfig/startup/rcvar Tue May 14 01:27:56 2013 (r250632) +++ head/usr.sbin/bsdconfig/startup/rcvar Tue May 14 03:21:13 2013 (r250633) @@ -161,7 +161,7 @@ dialog_menu_main() # # Process command-line arguments # -while getopts dD:hSX flag; do +while getopts h$GETOPTS_STDARGS flag; do case "$flag" in h|\?) f_usage $BSDCFG_LIBE/$APP_DIR/USAGE "PROGRAM_NAME" "$pgm";; esac Modified: head/usr.sbin/bsdconfig/startup/startup ============================================================================== --- head/usr.sbin/bsdconfig/startup/startup Tue May 14 01:27:56 2013 (r250632) +++ head/usr.sbin/bsdconfig/startup/startup Tue May 14 03:21:13 2013 (r250633) @@ -92,7 +92,7 @@ dialog_menu_main() # # Process command-line arguments # -while getopts dD:hSX flag; do +while getopts h$GETOPTS_STDARGS flag; do case "$flag" in h|\?) f_usage $BSDCFG_LIBE/$APP_DIR/USAGE "PROGRAM_NAME" "$pgm";; esac Modified: head/usr.sbin/bsdconfig/timezone/timezone ============================================================================== --- head/usr.sbin/bsdconfig/timezone/timezone Tue May 14 01:27:56 2013 (r250632) +++ head/usr.sbin/bsdconfig/timezone/timezone Tue May 14 03:21:13 2013 (r250633) @@ -117,7 +117,7 @@ dialog_menu_main() # # Process command-line arguments # -while getopts C:dD:ehnrsSvX flag; do +while getopts C:ehnrsv$GETOPTS_STDARGS flag; do case "$flag" in C) CHROOTENV="$OPTARG";; e) TZ_OR_FAIL=1;; Modified: head/usr.sbin/bsdconfig/ttys/ttys ============================================================================== --- head/usr.sbin/bsdconfig/ttys/ttys Tue May 14 01:27:56 2013 (r250632) +++ head/usr.sbin/bsdconfig/ttys/ttys Tue May 14 03:21:13 2013 (r250633) @@ -67,7 +67,7 @@ ETC_TTYS=/etc/ttys # # Process command-line arguments # -while getopts dD:hSX flag; do +while getopts h$GETOPTS_STDARGS flag; do case "$flag" in h|\?) f_usage $BSDCFG_LIBE/$APP_DIR/USAGE "PROGRAM_NAME" "$pgm";; esac Modified: head/usr.sbin/bsdconfig/usermgmt/groupadd ============================================================================== --- head/usr.sbin/bsdconfig/usermgmt/groupadd Tue May 14 01:27:56 2013 (r250632) +++ head/usr.sbin/bsdconfig/usermgmt/groupadd Tue May 14 03:21:13 2013 (r250633) @@ -47,7 +47,7 @@ ipgm=$( f_index_menusel_keyword $BSDCFG_ # # Process command-line arguments # -while getopts dD:hSX flag; do +while getopts h$GETOPTS_STDARGS flag; do case "$flag" in h|\?) f_usage $BSDCFG_LIBE/$APP_DIR/USAGE "PROGRAM_NAME" "$pgm";; esac Modified: head/usr.sbin/bsdconfig/usermgmt/groupdel ============================================================================== --- head/usr.sbin/bsdconfig/usermgmt/groupdel Tue May 14 01:27:56 2013 (r250632) +++ head/usr.sbin/bsdconfig/usermgmt/groupdel Tue May 14 03:21:13 2013 (r250633) @@ -50,7 +50,7 @@ ipgm=$( f_index_menusel_keyword $BSDCFG_ # # Process command-line arguments # -while getopts dD:hSX flag; do +while getopts h$GETOPTS_STDARGS flag; do case "$flag" in h|\?) f_usage $BSDCFG_LIBE/$APP_DIR/USAGE "PROGRAM_NAME" "$pgm";; esac Modified: head/usr.sbin/bsdconfig/usermgmt/groupedit ============================================================================== --- head/usr.sbin/bsdconfig/usermgmt/groupedit Tue May 14 01:27:56 2013 (r250632) +++ head/usr.sbin/bsdconfig/usermgmt/groupedit Tue May 14 03:21:13 2013 (r250633) @@ -50,7 +50,7 @@ ipgm=$( f_index_menusel_keyword $BSDCFG_ # # Process command-line arguments # -while getopts dD:hSX flag; do +while getopts h$GETOPTS_STDARGS flag; do case "$flag" in h|\?) f_usage $BSDCFG_LIBE/$APP_DIR/USAGE "PROGRAM_NAME" "$pgm";; esac Modified: head/usr.sbin/bsdconfig/usermgmt/useradd ============================================================================== --- head/usr.sbin/bsdconfig/usermgmt/useradd Tue May 14 01:27:56 2013 (r250632) +++ head/usr.sbin/bsdconfig/usermgmt/useradd Tue May 14 03:21:13 2013 (r250633) @@ -47,7 +47,7 @@ ipgm=$( f_index_menusel_keyword $BSDCFG_ # # Process command-line arguments # -while getopts dD:hSX flag; do +while getopts h$GETOPTS_STDARGS flag; do case "$flag" in h|\?) f_usage $BSDCFG_LIBE/$APP_DIR/USAGE "PROGRAM_NAME" "$pgm";; esac Modified: head/usr.sbin/bsdconfig/usermgmt/userdel ============================================================================== --- head/usr.sbin/bsdconfig/usermgmt/userdel Tue May 14 01:27:56 2013 (r250632) +++ head/usr.sbin/bsdconfig/usermgmt/userdel Tue May 14 03:21:13 2013 (r250633) @@ -50,7 +50,7 @@ ipgm=$( f_index_menusel_keyword $BSDCFG_ # # Process command-line arguments # -while getopts dD:hSX flag; do +while getopts h$GETOPTS_STDARGS flag; do case "$flag" in h|\?) f_usage $BSDCFG_LIBE/$APP_DIR/USAGE "PROGRAM_NAME" "$pgm";; esac Modified: head/usr.sbin/bsdconfig/usermgmt/useredit ============================================================================== --- head/usr.sbin/bsdconfig/usermgmt/useredit Tue May 14 01:27:56 2013 (r250632) +++ head/usr.sbin/bsdconfig/usermgmt/useredit Tue May 14 03:21:13 2013 (r250633) @@ -50,7 +50,7 @@ ipgm=$( f_index_menusel_keyword $BSDCFG_ # # Process command-line arguments # -while getopts dD:hSX flag; do +while getopts h$GETOPTS_STDARGS flag; do case "$flag" in h|\?) f_usage $BSDCFG_LIBE/$APP_DIR/USAGE "PROGRAM_NAME" "$pgm";; esac Modified: head/usr.sbin/bsdconfig/usermgmt/usermgmt ============================================================================== --- head/usr.sbin/bsdconfig/usermgmt/usermgmt Tue May 14 01:27:56 2013 (r250632) +++ head/usr.sbin/bsdconfig/usermgmt/usermgmt Tue May 14 03:21:13 2013 (r250633) @@ -111,7 +111,7 @@ dialog_menu_main() # # Process command-line arguments # -while getopts dD:hSX flag; do +while getopts h$GETOPTS_STDARGS flag; do case "$flag" in h|\?) f_usage $BSDCFG_LIBE/$APP_DIR/USAGE "PROGRAM_NAME" "$pgm";; esac From owner-svn-src-all@FreeBSD.ORG Tue May 14 09:47:59 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id 9B0D2AFC; Tue, 14 May 2013 09:47:59 +0000 (UTC) (envelope-from gber@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id 7D6A1E54; Tue, 14 May 2013 09:47:59 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.6/8.14.6) with ESMTP id r4E9lx45058245; Tue, 14 May 2013 09:47:59 GMT (envelope-from gber@svn.freebsd.org) Received: (from gber@localhost) by svn.freebsd.org (8.14.6/8.14.5/Submit) id r4E9lxYF058242; Tue, 14 May 2013 09:47:59 GMT (envelope-from gber@svn.freebsd.org) Message-Id: <201305140947.r4E9lxYF058242@svn.freebsd.org> From: Grzegorz Bernacki Date: Tue, 14 May 2013 09:47:59 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r250634 - in head/sys: arm/arm arm/include conf X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 14 May 2013 09:47:59 -0000 Author: gber Date: Tue May 14 09:47:58 2013 New Revision: 250634 URL: http://svnweb.freebsd.org/changeset/base/250634 Log: Port the new PV entry allocator from amd64/i386/mips to armv6/v7. PV entries are now roughly half the size. Instead of using a shared UMA zone for 28 byte pv entries (two 8-byte tailq nodes, a 4 byte pointer, a 4 byte address and 4 byte flags), we allocate a page at a time per process. This provides 252 pv entries per process (actually, per pmap address space) and eliminates one of the 8-byte tailq entries since we now can track per-process pv entries implicitly. The pointer to the pmap can be eliminated by doing address arithmetic to find the metadata on the page headers to find a single pointer shared by all 252 entries. There is an 8-int bitmap for the freelist of those 252 entries. When in serious low memory condition, allocation of another pv_chunk is possible by freeing some pages in pmap_pv_reclaim(). Added pv_entry/pv_chunk related statistics to pmap. pv_entry/pv_chunk statistics can be accessed via sysctl vm.pmap. Ported PTE freelist of KVA allocation and maintenance from i386. Using an idea from Stephan Uphoff, use the empty pte's that correspond to the unused kva in the pv memory block to thread a freelist through. This allows us to free pages that used to be used for pv entry chunks since we can now track holes in the kva memory block. As both ARM pmap.c and pmap-v6.c use the same header and pv_entry, pmap and md_page structures are different, it was needed to separate code designed for ARMv6/7 from the one for other ARMs. Submitted by: Zbigniew Bodek Reviewed by: alc Sponsored by: The FreeBSD Foundation, Semihalf Modified: head/sys/arm/arm/pmap-v6.c head/sys/arm/include/pmap.h head/sys/conf/options.arm Modified: head/sys/arm/arm/pmap-v6.c ============================================================================== --- head/sys/arm/arm/pmap-v6.c Tue May 14 03:21:13 2013 (r250633) +++ head/sys/arm/arm/pmap-v6.c Tue May 14 09:47:58 2013 (r250634) @@ -141,6 +141,7 @@ /* Include header files */ #include "opt_vm.h" +#include "opt_pmap.h" #include __FBSDID("$FreeBSD$"); @@ -158,6 +159,7 @@ __FBSDID("$FreeBSD$"); #include #include #include +#include #include #include @@ -193,6 +195,12 @@ int pmap_debug_level = 0; #define PMAP_INLINE __inline #endif /* PMAP_DEBUG */ +#ifdef PV_STATS +#define PV_STAT(x) do { x ; } while (0) +#else +#define PV_STAT(x) do { } while (0) +#endif + #ifdef ARM_L2_PIPT #define pmap_l2cache_wbinv_range(va, pa, size) cpu_l2cache_wbinv_range((pa), (size)) #define pmap_l2cache_inv_range(va, pa, size) cpu_l2cache_inv_range((pa), (size)) @@ -206,8 +214,11 @@ extern struct pv_addr systempage; /* * Internal function prototypes */ -static void pmap_free_pv_entry (pv_entry_t); -static pv_entry_t pmap_get_pv_entry(void); + +static void pmap_free_pv_chunk(struct pv_chunk *pc); +static void pmap_free_pv_entry(pmap_t pmap, pv_entry_t pv); +static pv_entry_t pmap_get_pv_entry(pmap_t pmap, boolean_t try); +static vm_page_t pmap_pv_reclaim(pmap_t locked_pmap); static void pmap_enter_locked(pmap_t, vm_offset_t, vm_page_t, vm_prot_t, boolean_t, int); @@ -386,13 +397,73 @@ int pmap_needs_pte_sync; #define pmap_is_current(pm) ((pm) == pmap_kernel() || \ curproc->p_vmspace->vm_map.pmap == (pm)) -static uma_zone_t pvzone = NULL; + +/* + * Data for the pv entry allocation mechanism + */ +static TAILQ_HEAD(pch, pv_chunk) pv_chunks = TAILQ_HEAD_INITIALIZER(pv_chunks); +static int pv_entry_count, pv_entry_max, pv_entry_high_water; +static int shpgperproc = PMAP_SHPGPERPROC; + +struct pv_chunk *pv_chunkbase; /* KVA block for pv_chunks */ +int pv_maxchunks; /* How many chunks we have KVA for */ +vm_offset_t pv_vafree; /* Freelist stored in the PTE */ + +static __inline struct pv_chunk * +pv_to_chunk(pv_entry_t pv) +{ + + return ((struct pv_chunk *)((uintptr_t)pv & ~(uintptr_t)PAGE_MASK)); +} + +#define PV_PMAP(pv) (pv_to_chunk(pv)->pc_pmap) + +CTASSERT(sizeof(struct pv_chunk) == PAGE_SIZE); +CTASSERT(_NPCM == 8); +CTASSERT(_NPCPV == 252); + +#define PC_FREE0_6 0xfffffffful /* Free values for index 0 through 6 */ +#define PC_FREE7 0x0ffffffful /* Free values for index 7 */ + +static const uint32_t pc_freemask[_NPCM] = { + PC_FREE0_6, PC_FREE0_6, PC_FREE0_6, + PC_FREE0_6, PC_FREE0_6, PC_FREE0_6, + PC_FREE0_6, PC_FREE7 +}; + +static SYSCTL_NODE(_vm, OID_AUTO, pmap, CTLFLAG_RD, 0, "VM/pmap parameters"); + +SYSCTL_INT(_vm_pmap, OID_AUTO, pv_entry_count, CTLFLAG_RD, &pv_entry_count, 0, + "Current number of pv entries"); + +#ifdef PV_STATS +static int pc_chunk_count, pc_chunk_allocs, pc_chunk_frees, pc_chunk_tryfail; + +SYSCTL_INT(_vm_pmap, OID_AUTO, pc_chunk_count, CTLFLAG_RD, &pc_chunk_count, 0, + "Current number of pv entry chunks"); +SYSCTL_INT(_vm_pmap, OID_AUTO, pc_chunk_allocs, CTLFLAG_RD, &pc_chunk_allocs, 0, + "Current number of pv entry chunks allocated"); +SYSCTL_INT(_vm_pmap, OID_AUTO, pc_chunk_frees, CTLFLAG_RD, &pc_chunk_frees, 0, + "Current number of pv entry chunks frees"); +SYSCTL_INT(_vm_pmap, OID_AUTO, pc_chunk_tryfail, CTLFLAG_RD, &pc_chunk_tryfail, 0, + "Number of times tried to get a chunk page but failed."); + +static long pv_entry_frees, pv_entry_allocs; +static int pv_entry_spare; + +SYSCTL_LONG(_vm_pmap, OID_AUTO, pv_entry_frees, CTLFLAG_RD, &pv_entry_frees, 0, + "Current number of pv entry frees"); +SYSCTL_LONG(_vm_pmap, OID_AUTO, pv_entry_allocs, CTLFLAG_RD, &pv_entry_allocs, 0, + "Current number of pv entry allocs"); +SYSCTL_INT(_vm_pmap, OID_AUTO, pv_entry_spare, CTLFLAG_RD, &pv_entry_spare, 0, + "Current number of spare pv entries"); +#endif + uma_zone_t l2zone; static uma_zone_t l2table_zone; static vm_offset_t pmap_kernel_l2dtable_kva; static vm_offset_t pmap_kernel_l2ptp_kva; static vm_paddr_t pmap_kernel_l2ptp_phys; -static int pv_entry_count=0, pv_entry_max=0, pv_entry_high_water=0; static struct rwlock pvh_global_lock; int l1_mem_types[] = { @@ -846,7 +917,7 @@ pmap_clearbit(struct vm_page *pg, u_int */ TAILQ_FOREACH(pv, &pg->md.pv_list, pv_list) { va = pv->pv_va; - pm = pv->pv_pmap; + pm = PV_PMAP(pv); oflags = pv->pv_flags; pv->pv_flags &= ~maskbits; @@ -923,12 +994,10 @@ pmap_enter_pv(struct vm_page *pg, struct rw_assert(&pvh_global_lock, RA_WLOCKED); PMAP_ASSERT_LOCKED(pm); - pve->pv_pmap = pm; pve->pv_va = va; pve->pv_flags = flags; TAILQ_INSERT_HEAD(&pg->md.pv_list, pve, pv_list); - TAILQ_INSERT_HEAD(&pm->pm_pvlist, pve, pv_plist); pg->md.pvh_attrs |= flags & (PVF_REF | PVF_MOD); if (pve->pv_flags & PVF_WIRED) ++pm->pm_stats.wired_count; @@ -948,7 +1017,7 @@ pmap_find_pv(struct vm_page *pg, pmap_t rw_assert(&pvh_global_lock, RA_WLOCKED); TAILQ_FOREACH(pv, &pg->md.pv_list, pv_list) - if (pm == pv->pv_pmap && va == pv->pv_va) + if (pm == PV_PMAP(pv) && va == pv->pv_va) break; return (pv); } @@ -1014,7 +1083,6 @@ pmap_nuke_pv(struct vm_page *pg, pmap_t PMAP_ASSERT_LOCKED(pm); TAILQ_REMOVE(&pg->md.pv_list, pve, pv_list); - TAILQ_REMOVE(&pm->pm_pvlist, pve, pv_plist); if (pve->pv_flags & PVF_WIRED) --pm->pm_stats.wired_count; @@ -1047,7 +1115,7 @@ pmap_remove_pv(struct vm_page *pg, pmap_ pve = TAILQ_FIRST(&pg->md.pv_list); while (pve) { - if (pve->pv_pmap == pm && pve->pv_va == va) { /* match? */ + if (PV_PMAP(pve) == pm && pve->pv_va == va) { /* match? */ pmap_nuke_pv(pg, pm, pve); break; } @@ -1142,6 +1210,48 @@ pmap_page_init(vm_page_t m) m->md.pv_memattr = VM_MEMATTR_DEFAULT; } +static vm_offset_t +pmap_ptelist_alloc(vm_offset_t *head) +{ + pt_entry_t *pte; + vm_offset_t va; + + va = *head; + if (va == 0) + return (va); /* Out of memory */ + pte = vtopte(va); + *head = *pte; + if ((*head & L2_TYPE_MASK) != L2_TYPE_INV) + panic("%s: va is not L2_TYPE_INV!", __func__); + *pte = 0; + return (va); +} + +static void +pmap_ptelist_free(vm_offset_t *head, vm_offset_t va) +{ + pt_entry_t *pte; + + if ((va & L2_TYPE_MASK) != L2_TYPE_INV) + panic("%s: freeing va that is not L2_TYPE INV!", __func__); + pte = vtopte(va); + *pte = *head; /* virtual! L2_TYPE is L2_TYPE_INV though */ + *head = va; +} + +static void +pmap_ptelist_init(vm_offset_t *head, void *base, int npages) +{ + int i; + vm_offset_t va; + + *head = 0; + for (i = npages - 1; i >= 0; i--) { + va = (vm_offset_t)base + i * PAGE_SIZE; + pmap_ptelist_free(head, va); + } +} + /* * Initialize the pmap module. * Called by vm_init, to initialize any structures that the pmap @@ -1150,7 +1260,6 @@ pmap_page_init(vm_page_t m) void pmap_init(void) { - int shpgperproc = PMAP_SHPGPERPROC; PDEBUG(1, printf("pmap_init: phys_start = %08x\n", PHYSADDR)); @@ -1160,21 +1269,35 @@ pmap_init(void) NULL, NULL, NULL, UMA_ALIGN_PTR, UMA_ZONE_VM | UMA_ZONE_NOFREE); /* - * Initialize the PV entry allocator. + * Initialize the address space for the pv chunks. */ - pvzone = uma_zcreate("PV ENTRY", sizeof (struct pv_entry), NULL, NULL, - NULL, NULL, UMA_ALIGN_PTR, UMA_ZONE_VM | UMA_ZONE_NOFREE); + TUNABLE_INT_FETCH("vm.pmap.shpgperproc", &shpgperproc); pv_entry_max = shpgperproc * maxproc + cnt.v_page_count; - uma_zone_reserve_kva(pvzone, pv_entry_max); + TUNABLE_INT_FETCH("vm.pmap.pv_entries", &pv_entry_max); + pv_entry_max = roundup(pv_entry_max, _NPCPV); pv_entry_high_water = 9 * (pv_entry_max / 10); + pv_maxchunks = MAX(pv_entry_max / _NPCPV, maxproc); + pv_chunkbase = (struct pv_chunk *)kmem_alloc_nofault(kernel_map, + PAGE_SIZE * pv_maxchunks); + + if (pv_chunkbase == NULL) + panic("pmap_init: not enough kvm for pv chunks"); + + pmap_ptelist_init(&pv_vafree, pv_chunkbase, pv_maxchunks); + /* * Now it is safe to enable pv_table recording. */ PDEBUG(1, printf("pmap_init: done!\n")); } +SYSCTL_INT(_vm_pmap, OID_AUTO, pv_entry_max, CTLFLAG_RD, &pv_entry_max, 0, + "Max number of PV entries"); +SYSCTL_INT(_vm_pmap, OID_AUTO, shpgperproc, CTLFLAG_RD, &shpgperproc, 0, + "Page share factor per proc"); + int pmap_fault_fixup(pmap_t pm, vm_offset_t va, vm_prot_t ftype, int user) { @@ -1656,7 +1779,7 @@ pmap_bootstrap(vm_offset_t firstaddr, st PMAP_LOCK_INIT(kernel_pmap); CPU_FILL(&kernel_pmap->pm_active); kernel_pmap->pm_domain = PMAP_DOMAIN_KERNEL; - TAILQ_INIT(&kernel_pmap->pm_pvlist); + TAILQ_INIT(&kernel_pmap->pm_pvchunk); /* * Initialize the global pv list lock. @@ -1924,38 +2047,61 @@ pmap_growkernel(vm_offset_t addr) void pmap_remove_pages(pmap_t pmap) { - struct pv_entry *pv, *npv; - struct l2_bucket *l2b = NULL; - vm_page_t m; - pt_entry_t *pt; - - rw_wlock(&pvh_global_lock); - PMAP_LOCK(pmap); - for (pv = TAILQ_FIRST(&pmap->pm_pvlist); pv; pv = npv) { - if (pv->pv_flags & PVF_WIRED) { - /* Cannot remove wired pages now. */ - npv = TAILQ_NEXT(pv, pv_plist); - continue; + struct pv_entry *pv; + struct l2_bucket *l2b = NULL; + vm_page_t m; + pt_entry_t *pt; + struct pv_chunk *pc, *npc; + uint32_t inuse, bitmask; + int allfree, bit, field, idx; + + rw_wlock(&pvh_global_lock); + PMAP_LOCK(pmap); + + TAILQ_FOREACH_SAFE(pc, &pmap->pm_pvchunk, pc_list, npc) { + allfree = 1; + for (field = 0; field < _NPCM; field++) { + inuse = ~pc->pc_map[field] & pc_freemask[field]; + while (inuse != 0) { + bit = ffs(inuse) - 1; + bitmask = 1ul << bit; + idx = field * sizeof(inuse) * NBBY + bit; + pv = &pc->pc_pventry[idx]; + inuse &= ~bitmask; + if (pv->pv_flags & PVF_WIRED) { + /* Cannot remove wired pages now. */ + allfree = 0; + continue; + } + l2b = pmap_get_l2_bucket(pmap, pv->pv_va); + KASSERT(l2b != NULL, ("No L2 bucket in pmap_remove_pages")); + pt = &l2b->l2b_kva[l2pte_index(pv->pv_va)]; + m = PHYS_TO_VM_PAGE(*pt & L2_ADDR_MASK); + KASSERT((vm_offset_t)m >= KERNBASE, ("Trying to access non-existent page va %x pte %x", pv->pv_va, *pt)); + *pt = 0; + PTE_SYNC(pt); + + /* Mark free */ + PV_STAT(pv_entry_frees++); + PV_STAT(pv_entry_spare++); + pv_entry_count--; + pmap->pm_stats.resident_count--; + pc->pc_map[field] |= bitmask; + pmap_nuke_pv(m, pmap, pv); + pmap_free_l2_bucket(pmap, l2b, 1); + } } - pmap->pm_stats.resident_count--; - l2b = pmap_get_l2_bucket(pmap, pv->pv_va); - KASSERT(l2b != NULL, ("No L2 bucket in pmap_remove_pages")); - pt = &l2b->l2b_kva[l2pte_index(pv->pv_va)]; - m = PHYS_TO_VM_PAGE(*pt & L2_ADDR_MASK); - KASSERT((vm_offset_t)m >= KERNBASE, ("Trying to access non-existent page va %x pte %x", pv->pv_va, *pt)); - *pt = 0; - PTE_SYNC(pt); - npv = TAILQ_NEXT(pv, pv_plist); - pmap_nuke_pv(m, pmap, pv); - if (TAILQ_EMPTY(&m->md.pv_list)) - vm_page_aflag_clear(m, PGA_WRITEABLE); - pmap_free_pv_entry(pv); - pmap_free_l2_bucket(pmap, l2b, 1); + if (allfree) { + TAILQ_REMOVE(&pmap->pm_pvchunk, pc, pc_list); + pmap_free_pv_chunk(pc); + } + } - rw_wunlock(&pvh_global_lock); - cpu_tlb_flushID(); - cpu_cpwait(); - PMAP_UNLOCK(pmap); + + rw_wunlock(&pvh_global_lock); + cpu_tlb_flushID(); + cpu_cpwait(); + PMAP_UNLOCK(pmap); } @@ -2306,6 +2452,7 @@ void pmap_remove_all(vm_page_t m) { pv_entry_t pv; + pmap_t pmap; pt_entry_t *ptep; struct l2_bucket *l2b; boolean_t flush = FALSE; @@ -2320,25 +2467,26 @@ pmap_remove_all(vm_page_t m) rw_wlock(&pvh_global_lock); curpm = vmspace_pmap(curproc->p_vmspace); while ((pv = TAILQ_FIRST(&m->md.pv_list)) != NULL) { - if (flush == FALSE && (pv->pv_pmap == curpm || - pv->pv_pmap == pmap_kernel())) + pmap = PV_PMAP(pv); + if (flush == FALSE && (pmap == curpm || + pmap == pmap_kernel())) flush = TRUE; - PMAP_LOCK(pv->pv_pmap); - l2b = pmap_get_l2_bucket(pv->pv_pmap, pv->pv_va); + PMAP_LOCK(pmap); + l2b = pmap_get_l2_bucket(pmap, pv->pv_va); KASSERT(l2b != NULL, ("No l2 bucket")); ptep = &l2b->l2b_kva[l2pte_index(pv->pv_va)]; if (L2_S_WRITABLE(*ptep)) vm_page_dirty(m); *ptep = 0; - if (pmap_is_current(pv->pv_pmap)) + if (pmap_is_current(pmap)) PTE_SYNC(ptep); - pmap_free_l2_bucket(pv->pv_pmap, l2b, 1); - pv->pv_pmap->pm_stats.resident_count--; + pmap_free_l2_bucket(pmap, l2b, 1); + pmap->pm_stats.resident_count--; flags |= pv->pv_flags; - pmap_nuke_pv(m, pv->pv_pmap, pv); - PMAP_UNLOCK(pv->pv_pmap); - pmap_free_pv_entry(pv); + pmap_nuke_pv(m, pmap, pv); + pmap_free_pv_entry(pmap, pv); + PMAP_UNLOCK(pmap); } m->md.pvh_attrs &= ~(PVF_MOD | PVF_REF); @@ -2694,15 +2842,13 @@ do_l2b_alloc: if ((pve = pmap_remove_pv(opg, pmap, va))) { oflags = pve->pv_flags; - if (m && ((m->oflags & VPO_UNMANAGED))) { - pmap_free_pv_entry(pve); - pve = NULL; - } + if (m && ((m->oflags & VPO_UNMANAGED))) + pmap_free_pv_entry(pmap, pve); } } if ((m && !(m->oflags & VPO_UNMANAGED))) { - if ((!pve) && (pve = pmap_get_pv_entry()) == NULL) + if ((!pve) && (pve = pmap_get_pv_entry(pmap, FALSE)) == NULL) panic("pmap_enter: no pv entries"); KASSERT(va < kmi.clean_sva || va >= kmi.clean_eva, @@ -3024,7 +3170,7 @@ pmap_pinit(pmap_t pmap) CPU_ZERO(&pmap->pm_active); - TAILQ_INIT(&pmap->pm_pvlist); + TAILQ_INIT(&pmap->pm_pvchunk); bzero(&pmap->pm_stats, sizeof pmap->pm_stats); pmap->pm_stats.resident_count = 1; if (vector_page < KERNBASE) { @@ -3040,31 +3186,253 @@ pmap_pinit(pmap_t pmap) * page management routines. ***************************************************/ +/* + * We are in a serious low memory condition. Resort to + * drastic measures to free some pages so we can allocate + * another pv entry chunk. + */ +static vm_page_t +pmap_pv_reclaim(pmap_t locked_pmap) +{ + struct pch newtail; + struct pv_chunk *pc; + struct l2_bucket *l2b = NULL; + pmap_t pmap; + pt_entry_t *pt; + pv_entry_t pv; + vm_offset_t va; + vm_page_t free, m, m_pc; + uint32_t inuse; + int bit, field, freed, idx; + + PMAP_ASSERT_LOCKED(locked_pmap); + pmap = NULL; + free = m_pc = NULL; + TAILQ_INIT(&newtail); + while ((pc = TAILQ_FIRST(&pv_chunks)) != NULL && (pv_vafree == 0 || + free == NULL)) { + TAILQ_REMOVE(&pv_chunks, pc, pc_lru); + if (pmap != pc->pc_pmap) { + if (pmap != NULL) { + cpu_tlb_flushID(); + cpu_cpwait(); + if (pmap != locked_pmap) + PMAP_UNLOCK(pmap); + } + pmap = pc->pc_pmap; + /* Avoid deadlock and lock recursion. */ + if (pmap > locked_pmap) + PMAP_LOCK(pmap); + else if (pmap != locked_pmap && !PMAP_TRYLOCK(pmap)) { + pmap = NULL; + TAILQ_INSERT_TAIL(&newtail, pc, pc_lru); + continue; + } + } + + /* + * Destroy every non-wired, 4 KB page mapping in the chunk. + */ + freed = 0; + for (field = 0; field < _NPCM; field++) { + for (inuse = ~pc->pc_map[field] & pc_freemask[field]; + inuse != 0; inuse &= ~(1UL << bit)) { + bit = ffs(inuse) - 1; + idx = field * sizeof(inuse) * NBBY + bit; + pv = &pc->pc_pventry[idx]; + if (pv->pv_flags & PVF_WIRED) + continue; + + va = pv->pv_va; + l2b = pmap_get_l2_bucket(pmap, va); + KASSERT(l2b != NULL, ("No l2 bucket")); + pt = &l2b->l2b_kva[l2pte_index(va)]; + m = PHYS_TO_VM_PAGE(l2pte_pa(*pt)); + KASSERT((vm_offset_t)m >= KERNBASE, + ("Trying to access non-existent page " + "va %x pte %x in %s", va, *pt)); + *pt = 0; + PTE_SYNC(pt); + pmap_nuke_pv(m, pmap, pv); + pc->pc_map[field] |= 1UL << bit; + freed++; + } + } + + if (freed == 0) { + TAILQ_INSERT_TAIL(&newtail, pc, pc_lru); + continue; + } + /* Every freed mapping is for a 4 KB page. */ + pmap->pm_stats.resident_count -= freed; + PV_STAT(pv_entry_frees += freed); + PV_STAT(pv_entry_spare += freed); + pv_entry_count -= freed; + TAILQ_REMOVE(&pmap->pm_pvchunk, pc, pc_list); + for (field = 0; field < _NPCM; field++) + if (pc->pc_map[field] != pc_freemask[field]) { + TAILQ_INSERT_HEAD(&pmap->pm_pvchunk, pc, + pc_list); + TAILQ_INSERT_TAIL(&newtail, pc, pc_lru); + + /* + * One freed pv entry in locked_pmap is + * sufficient. + */ + if (pmap == locked_pmap) + goto out; + break; + } + if (field == _NPCM) { + PV_STAT(pv_entry_spare -= _NPCPV); + PV_STAT(pc_chunk_count--); + PV_STAT(pc_chunk_frees++); + /* Entire chunk is free; return it. */ + m_pc = PHYS_TO_VM_PAGE(pmap_kextract((vm_offset_t)pc)); + pmap_qremove((vm_offset_t)pc, 1); + pmap_ptelist_free(&pv_vafree, (vm_offset_t)pc); + break; + } + } +out: + TAILQ_CONCAT(&pv_chunks, &newtail, pc_lru); + if (pmap != NULL) { + cpu_tlb_flushID(); + cpu_cpwait(); + if (pmap != locked_pmap) + PMAP_UNLOCK(pmap); + } + return (m_pc); +} +/* + * free the pv_entry back to the free list + */ static void -pmap_free_pv_entry(pv_entry_t pv) +pmap_free_pv_entry(pmap_t pmap, pv_entry_t pv) { + struct pv_chunk *pc; + int bit, field, idx; + + rw_assert(&pvh_global_lock, RA_WLOCKED); + PMAP_ASSERT_LOCKED(pmap); + PV_STAT(pv_entry_frees++); + PV_STAT(pv_entry_spare++); pv_entry_count--; - uma_zfree(pvzone, pv); + pc = pv_to_chunk(pv); + idx = pv - &pc->pc_pventry[0]; + field = idx / (sizeof(u_long) * NBBY); + bit = idx % (sizeof(u_long) * NBBY); + pc->pc_map[field] |= 1ul << bit; + for (idx = 0; idx < _NPCM; idx++) + if (pc->pc_map[idx] != pc_freemask[idx]) { + /* + * 98% of the time, pc is already at the head of the + * list. If it isn't already, move it to the head. + */ + if (__predict_false(TAILQ_FIRST(&pmap->pm_pvchunk) != + pc)) { + TAILQ_REMOVE(&pmap->pm_pvchunk, pc, pc_list); + TAILQ_INSERT_HEAD(&pmap->pm_pvchunk, pc, + pc_list); + } + return; + } + TAILQ_REMOVE(&pmap->pm_pvchunk, pc, pc_list); + pmap_free_pv_chunk(pc); } +static void +pmap_free_pv_chunk(struct pv_chunk *pc) +{ + vm_page_t m; + + TAILQ_REMOVE(&pv_chunks, pc, pc_lru); + PV_STAT(pv_entry_spare -= _NPCPV); + PV_STAT(pc_chunk_count--); + PV_STAT(pc_chunk_frees++); + /* entire chunk is free, return it */ + m = PHYS_TO_VM_PAGE(pmap_kextract((vm_offset_t)pc)); + pmap_qremove((vm_offset_t)pc, 1); + vm_page_unwire(m, 0); + vm_page_free(m); + pmap_ptelist_free(&pv_vafree, (vm_offset_t)pc); + +} -/* - * get a new pv_entry, allocating a block from the system - * when needed. - * the memory allocation is performed bypassing the malloc code - * because of the possibility of allocations at interrupt time. - */ static pv_entry_t -pmap_get_pv_entry(void) +pmap_get_pv_entry(pmap_t pmap, boolean_t try) { - pv_entry_t ret_value; + static const struct timeval printinterval = { 60, 0 }; + static struct timeval lastprint; + struct pv_chunk *pc; + pv_entry_t pv; + vm_page_t m; + int bit, field, idx; + rw_assert(&pvh_global_lock, RA_WLOCKED); + PMAP_ASSERT_LOCKED(pmap); + PV_STAT(pv_entry_allocs++); pv_entry_count++; + if (pv_entry_count > pv_entry_high_water) - pagedaemon_wakeup(); - ret_value = uma_zalloc(pvzone, M_NOWAIT); - return ret_value; + if (ratecheck(&lastprint, &printinterval)) + printf("%s: Approaching the limit on PV entries.\n", + __func__); +retry: + pc = TAILQ_FIRST(&pmap->pm_pvchunk); + if (pc != NULL) { + for (field = 0; field < _NPCM; field++) { + if (pc->pc_map[field]) { + bit = ffs(pc->pc_map[field]) - 1; + break; + } + } + if (field < _NPCM) { + idx = field * sizeof(pc->pc_map[field]) * NBBY + bit; + pv = &pc->pc_pventry[idx]; + pc->pc_map[field] &= ~(1ul << bit); + /* If this was the last item, move it to tail */ + for (field = 0; field < _NPCM; field++) + if (pc->pc_map[field] != 0) { + PV_STAT(pv_entry_spare--); + return (pv); /* not full, return */ + } + TAILQ_REMOVE(&pmap->pm_pvchunk, pc, pc_list); + TAILQ_INSERT_TAIL(&pmap->pm_pvchunk, pc, pc_list); + PV_STAT(pv_entry_spare--); + return (pv); + } + } + /* + * Access to the ptelist "pv_vafree" is synchronized by the pvh + * global lock. If "pv_vafree" is currently non-empty, it will + * remain non-empty until pmap_ptelist_alloc() completes. + */ + if (pv_vafree == 0 || (m = vm_page_alloc(NULL, 0, VM_ALLOC_NORMAL | + VM_ALLOC_NOOBJ | VM_ALLOC_WIRED)) == NULL) { + if (try) { + pv_entry_count--; + PV_STAT(pc_chunk_tryfail++); + return (NULL); + } + m = pmap_pv_reclaim(pmap); + if (m == NULL) + goto retry; + } + PV_STAT(pc_chunk_count++); + PV_STAT(pc_chunk_allocs++); + pc = (struct pv_chunk *)pmap_ptelist_alloc(&pv_vafree); + pmap_qenter((vm_offset_t)pc, &m, 1); + pc->pc_pmap = pmap; + pc->pc_map[0] = pc_freemask[0] & ~1ul; /* preallocated bit 0 */ + for (field = 1; field < _NPCM; field++) + pc->pc_map[field] = pc_freemask[field]; + TAILQ_INSERT_TAIL(&pv_chunks, pc, pc_lru); + pv = &pc->pc_pventry[0]; + TAILQ_INSERT_HEAD(&pmap->pm_pvchunk, pc, pc_list); + PV_STAT(pv_entry_spare += _NPCPV - 1); + return (pv); } /* @@ -3142,7 +3510,7 @@ pmap_remove(pmap_t pm, vm_offset_t sva, if (pve) { is_exec = PV_BEEN_EXECD(pve->pv_flags); is_refd = PV_BEEN_REFD(pve->pv_flags); - pmap_free_pv_entry(pve); + pmap_free_pv_entry(pm, pve); } } @@ -3385,7 +3753,7 @@ pmap_page_exists_quick(pmap_t pmap, vm_p rv = FALSE; rw_wlock(&pvh_global_lock); TAILQ_FOREACH(pv, &m->md.pv_list, pv_list) { - if (pv->pv_pmap == pmap) { + if (PV_PMAP(pv) == pmap) { rv = TRUE; break; } Modified: head/sys/arm/include/pmap.h ============================================================================== --- head/sys/arm/include/pmap.h Tue May 14 03:21:13 2013 (r250633) +++ head/sys/arm/include/pmap.h Tue May 14 09:47:58 2013 (r250634) @@ -116,6 +116,7 @@ struct pv_addr { }; struct pv_entry; +struct pv_chunk; struct md_page { int pvh_attrs; @@ -152,7 +153,11 @@ struct pmap { pd_entry_t *pm_pdir; /* KVA of page directory */ cpuset_t pm_active; /* active on cpus */ struct pmap_statistics pm_stats; /* pmap statictics */ +#if (ARM_MMU_V6 + ARM_MMU_V7) != 0 + TAILQ_HEAD(,pv_chunk) pm_pvchunk; /* list of mappings in pmap */ +#else TAILQ_HEAD(,pv_entry) pm_pvlist; /* list of mappings in pmap */ +#endif }; typedef struct pmap *pmap_t; @@ -180,13 +185,31 @@ extern struct pmap kernel_pmap_store; * mappings of that page. An entry is a pv_entry_t, the list is pv_list. */ typedef struct pv_entry { - pmap_t pv_pmap; /* pmap where mapping lies */ vm_offset_t pv_va; /* virtual address for mapping */ TAILQ_ENTRY(pv_entry) pv_list; - TAILQ_ENTRY(pv_entry) pv_plist; int pv_flags; /* flags (wired, etc...) */ +#if (ARM_MMU_V6 + ARM_MMU_V7) == 0 + pmap_t pv_pmap; /* pmap where mapping lies */ + TAILQ_ENTRY(pv_entry) pv_plist; +#endif } *pv_entry_t; +/* + * pv_entries are allocated in chunks per-process. This avoids the + * need to track per-pmap assignments. + */ +#define _NPCM 8 +#define _NPCPV 252 + +struct pv_chunk { + pmap_t pc_pmap; + TAILQ_ENTRY(pv_chunk) pc_list; + uint32_t pc_map[_NPCM]; /* bitmap; 1 = free */ + uint32_t pc_dummy[3]; /* aligns pv_chunk to 4KB */ + TAILQ_ENTRY(pv_chunk) pc_lru; + struct pv_entry pc_pventry[_NPCPV]; +}; + #ifdef _KERNEL boolean_t pmap_get_pde_pte(pmap_t, vm_offset_t, pd_entry_t **, pt_entry_t **); Modified: head/sys/conf/options.arm ============================================================================== --- head/sys/conf/options.arm Tue May 14 03:21:13 2013 (r250633) +++ head/sys/conf/options.arm Tue May 14 09:47:58 2013 (r250634) @@ -36,6 +36,7 @@ LINUX_BOOT_ABI opt_global.h LOADERRAMADDR opt_global.h NO_EVENTTIMERS opt_timer.h PHYSADDR opt_global.h +PV_STATS opt_pmap.h QEMU_WORKAROUNDS opt_global.h SOC_MV_ARMADAXP opt_global.h SOC_MV_DISCOVERY opt_global.h From owner-svn-src-all@FreeBSD.ORG Tue May 14 20:25:07 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id 8E1EA9C8; Tue, 14 May 2013 20:25:07 +0000 (UTC) (envelope-from hiren@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id 7F93E9DC; Tue, 14 May 2013 20:25:07 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.6/8.14.6) with ESMTP id r4EKP70h081373; Tue, 14 May 2013 20:25:07 GMT (envelope-from hiren@svn.freebsd.org) Received: (from hiren@localhost) by svn.freebsd.org (8.14.6/8.14.5/Submit) id r4EKP7it081372; Tue, 14 May 2013 20:25:07 GMT (envelope-from hiren@svn.freebsd.org) Message-Id: <201305142025.r4EKP7it081372@svn.freebsd.org> From: Hiren Panchasara Date: Tue, 14 May 2013 20:25:07 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r250639 - head/lib/libc/stdlib X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 14 May 2013 20:25:07 -0000 Author: hiren Date: Tue May 14 20:25:07 2013 New Revision: 250639 URL: http://svnweb.freebsd.org/changeset/base/250639 Log: Fix a typo: It should be "strtoll" and not "stroll". PR: 178642 Reported by: Michael Galassi (michaelgalassi@gmail.com) Approved by: sbruno (mentor) MFC after: 1 week Modified: head/lib/libc/stdlib/atol.3 Modified: head/lib/libc/stdlib/atol.3 ============================================================================== --- head/lib/libc/stdlib/atol.3 Tue May 14 19:16:54 2013 (r250638) +++ head/lib/libc/stdlib/atol.3 Tue May 14 20:25:07 2013 (r250639) @@ -32,7 +32,7 @@ .\" @(#)atol.3 8.1 (Berkeley) 6/4/93 .\" $FreeBSD$ .\" -.Dd February 1, 2009 +.Dd May 14, 2013 .Dt ATOL 3 .Os .Sh NAME @@ -88,13 +88,13 @@ and functions are thin wrappers around .Fn strtol and -.Fn stroll +.Fn strtoll respectively, so these functions will affect the value of .Va errno in the same way that the .Fn strtol and -.Fn stroll +.Fn strtoll functions are able to. This behavior of .Fn atol From owner-svn-src-all@FreeBSD.ORG Tue May 14 21:15:37 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id 78D1EB74; Tue, 14 May 2013 21:15:37 +0000 (UTC) (envelope-from brooks@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id 5AA4DDA1; Tue, 14 May 2013 21:15:37 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.6/8.14.6) with ESMTP id r4ELFadG099309; Tue, 14 May 2013 21:15:36 GMT (envelope-from brooks@svn.freebsd.org) Received: (from brooks@localhost) by svn.freebsd.org (8.14.6/8.14.5/Submit) id r4ELFa9c099305; Tue, 14 May 2013 21:15:36 GMT (envelope-from brooks@svn.freebsd.org) Message-Id: <201305142115.r4ELFa9c099305@svn.freebsd.org> From: Brooks Davis Date: Tue, 14 May 2013 21:15:36 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org Subject: svn commit: r250640 - in stable/9: . etc X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 14 May 2013 21:15:37 -0000 Author: brooks Date: Tue May 14 21:15:36 2013 New Revision: 250640 URL: http://svnweb.freebsd.org/changeset/base/250640 Log: MFC r245825,245890,246097,246127,246315: Introduce a new option -DNO_ROOT that allows install and distribution targets to be run without root privilege. Information about ownership, group, flags, and suid bits are stored in the file specified by METALOG which defaults to ${DESTDIR}/METALOG. This file can be used in conjunction with bsdtar or makefs to generate archives or file system images with correct permissions. Sponsored by: DARPA, AFRL Modified: stable/9/Makefile.inc1 (contents, props changed) stable/9/etc/Makefile Directory Properties: stable/9/etc/ (props changed) Modified: stable/9/Makefile.inc1 ============================================================================== --- stable/9/Makefile.inc1 Tue May 14 20:25:07 2013 (r250639) +++ stable/9/Makefile.inc1 Tue May 14 21:15:36 2013 (r250640) @@ -4,6 +4,8 @@ # Make command line options: # -DNO_CLEANDIR run ${MAKE} clean, instead of ${MAKE} cleandir # -DNO_CLEAN do not clean at all +# -DDB_FROM_SRC use the user/group databases in src/etc instead of +# the system database when installing. # -DNO_SHARE do not go into share subdir # -DKERNFAST define NO_KERNEL{CONFIG,CLEAN,DEPEND,OBJ} # -DNO_KERNELCONFIG do not run config in ${MAKE} buildkernel @@ -11,13 +13,14 @@ # -DNO_KERNELDEPEND do not run ${MAKE} depend in ${MAKE} buildkernel # -DNO_KERNELOBJ do not run ${MAKE} obj in ${MAKE} buildkernel # -DNO_PORTSUPDATE do not update ports in ${MAKE} update +# -DNO_ROOT install without using root privilege # -DNO_DOCUPDATE do not update doc in ${MAKE} update -# -DDB_FROM_SRC use the user/group databases in src/etc instead of -# the system database when installing. # -DNO_CTF do not run the DTrace CTF conversion tools on built objects # LOCAL_DIRS="list of dirs" to add additional dirs to the SUBDIR list # LOCAL_MTREE="list of mtree files" to process to allow local directories # to be created before files are installed +# METALOG="path to metadata log" to write permission and ownership +# when NO_ROOT is set. (default: ${DESTDIR}/METALOG) # TARGET="machine" to crossbuild world for a different machine type # TARGET_ARCH= may be required when a TARGET supports multiple endians @@ -174,7 +177,7 @@ OBJTREE= ${MAKEOBJDIRPREFIX}/${TARGET}.$ .endif WORLDTMP= ${OBJTREE}${.CURDIR}/tmp # /usr/games added for fortune which depend on strfile -BPATH= ${WORLDTMP}/legacy/usr/sbin:${WORLDTMP}/legacy/usr/bin:${WORLDTMP}/legacy/usr/games +BPATH= ${WORLDTMP}/legacy/usr/sbin:${WORLDTMP}/legacy/usr/bin:${WORLDTMP}/legacy/usr/games:${WORLDTMP}/legacy/bin XPATH= ${WORLDTMP}/usr/sbin:${WORLDTMP}/usr/bin:${WORLDTMP}/usr/games STRICTTMPPATH= ${BPATH}:${XPATH} TMPPATH= ${STRICTTMPPATH}:${PATH} @@ -353,8 +356,19 @@ IMAKE+= __MAKE_SHELL=${INSTALLTMP}/sh IMAKEENV+= PATH=${TMPPATH}:${INSTALLTMP} .endif .if defined(DB_FROM_SRC) -IMAKE_INSTALL= INSTALL="install -N ${.CURDIR}/etc" -IMAKE_MTREE= MTREE_CMD="nmtree -N ${.CURDIR}/etc" +INSTALLFLAGS+= -N ${.CURDIR}/etc +MTREEFLAGS+= -N ${.CURDIR}/etc +.endif +.if defined(NO_ROOT) +METALOG?= ${DESTDIR}/${DISTDIR}/METALOG +IMAKE+= -DNO_ROOT METALOG=${METALOG} +INSTALL_DDIR= ${DESTDIR}/${DISTDIR} +INSTALLFLAGS+= -U -M ${METALOG} -D ${INSTALL_DDIR:S://:/:g:C:/$::} +MTREEFLAGS+= -W +.endif +.if defined(DB_FROM_SRC) || defined(NO_ROOT) +IMAKE_INSTALL= INSTALL="install ${INSTALLFLAGS}" +IMAKE_MTREE= MTREE_CMD="nmtree ${MTREEFLAGS}" .endif # kernel stage @@ -393,7 +407,7 @@ _worldtmp: rm -f ${OBJTREE}${.CURDIR}/usr.bin/truss/ioctl.c .endif .for _dir in \ - lib usr legacy/usr + lib usr legacy/bin legacy/usr mkdir -p ${WORLDTMP}/${_dir} .endfor mtree -deU -f ${.CURDIR}/etc/mtree/BSD.usr.dist \ @@ -662,7 +676,7 @@ _nmtree_itools= nmtree .endif ITOOLS= [ awk cap_mkdb cat chflags chmod chown \ - date echo egrep find grep ${_install-info} \ + date echo egrep find grep id install ${_install-info} \ ln lockf make mkdir mtree ${_nmtree_itools} mv pwd_mkdb \ rm sed sh sysctl test true uname wc ${_zoneinfo} @@ -685,6 +699,8 @@ EXTRA_DISTRIBUTIONS+= games EXTRA_DISTRIBUTIONS+= lib32 .endif +MTREE_MAGIC?= mtree 2.0 + distributeworld installworld: installcheck installcheck_UGID mkdir -p ${INSTALLTMP} progs=$$(for prog in ${ITOOLS}; do \ @@ -707,6 +723,9 @@ distributeworld installworld: installche done); \ cp $$libs $$progs ${INSTALLTMP} cp -R $${PATH_LOCALE:-"/usr/share/locale"} ${INSTALLTMP}/locale +.if defined(NO_ROOT) + echo "#${MTREE_MAGIC}" > ${METALOG} +.endif .if make(distributeworld) .for dist in ${EXTRA_DISTRIBUTIONS} -mkdir ${DESTDIR}/${DISTDIR}/${dist} @@ -716,10 +735,20 @@ distributeworld installworld: installche -p ${DESTDIR}/${DISTDIR}/${dist}/usr >/dev/null mtree -deU -f ${.CURDIR}/etc/mtree/BSD.include.dist \ -p ${DESTDIR}/${DISTDIR}/${dist}/usr/include >/dev/null +.if defined(NO_ROOT) + ${IMAKEENV} nmtree -C -f ${.CURDIR}/etc/mtree/BSD.root.dist | \ + sed -e 's#^\./#./${dist}/#' >> ${METALOG} + ${IMAKEENV} nmtree -C -f ${.CURDIR}/etc/mtree/BSD.usr.dist | \ + sed -e 's#^\./#./${dist}/usr/#' >> ${METALOG} + ${IMAKEENV} nmtree -C -f ${.CURDIR}/etc/mtree/BSD.include.dist | \ + sed -e 's#^\./#./${dist}/usr/include/#' >> ${METALOG} +.endif .endfor -mkdir ${DESTDIR}/${DISTDIR}/base - ${_+_}cd ${.CURDIR}; ${IMAKE} distrib-dirs \ - LOCAL_MTREE=${LOCAL_MTREE} DESTDIR=${DESTDIR}/${DISTDIR}/base + cd ${.CURDIR}/etc; ${CROSSENV} PATH=${TMPPATH} ${MAKE} \ + METALOG=${METALOG} ${IMAKE_INSTALL} ${IMAKE_MTREE} \ + DISTBASE=/base DESTDIR=${DESTDIR}/${DISTDIR}/base \ + LOCAL_MTREE=${LOCAL_MTREE} distrib-dirs .endif ${_+_}cd ${.CURDIR}; ${IMAKE} re${.TARGET:S/world$//}; \ ${IMAKEENV} rm -rf ${INSTALLTMP} @@ -727,12 +756,30 @@ distributeworld installworld: installche .for dist in ${EXTRA_DISTRIBUTIONS} find ${DESTDIR}/${DISTDIR}/${dist} -empty -delete .endfor +.if defined(NO_ROOT) +.for dist in base ${EXTRA_DISTRIBUTIONS} + @# For each file that exists in this dist, print the corresponding + @# line from the METALOG. This relies on the fact that + @# a line containing only the filename will sort immediatly before + @# the relevant mtree line. + cd ${DESTDIR}/${DISTDIR}; \ + find ./${dist} | sort -u ${METALOG} - | \ + awk 'BEGIN { print "#${MTREE_MAGIC}" } !/ type=/ { file = $$1 } / type=/ { if ($$1 == file) { sub(/^\.\/${dist}\//, "./"); print } }' > \ + ${DESTDIR}/${DISTDIR}/${dist}.meta +.endfor +.endif .endif packageworld: .for dist in base ${EXTRA_DISTRIBUTIONS} +.if defined(NO_ROOT) + ${_+_}cd ${DESTDIR}/${DISTDIR}/${dist}; \ + tar cvJf ${DESTDIR}/${DISTDIR}/${dist}.txz \ + @${DESTDIR}/${DISTDIR}/${dist}.meta +.else ${_+_}cd ${DESTDIR}/${DISTDIR}/${dist}; \ tar cvJf ${DESTDIR}/${DISTDIR}/${dist}.txz . +.endif .endfor # @@ -769,7 +816,7 @@ redistribute: distrib-dirs distribution: cd ${.CURDIR}/etc; ${CROSSENV} PATH=${TMPPATH} ${MAKE} \ - ${IMAKE_INSTALL} ${IMAKE_MTREE} ${.TARGET} + ${IMAKE_INSTALL} ${IMAKE_MTREE} METALOG=${METALOG} ${.TARGET} # # buildkernel and installkernel @@ -1092,6 +1139,10 @@ _nmtree= lib/libnetbsd \ usr.sbin/nmtree .endif +.if ${BOOTSTRAPPING} < 1000027 +_cat= bin/cat +.endif + .if ${BOOTSTRAPPING} >= 900040 && ${BOOTSTRAPPING} < 900041 _awk= usr.bin/awk .endif @@ -1138,6 +1189,7 @@ bootstrap-tools: ${_ar} \ ${_dtc} \ ${_awk} \ + ${_cat} \ usr.bin/lorder \ usr.bin/makewhatis \ ${_mklocale} \ @@ -1263,7 +1315,12 @@ cross-tools: # hierarchy - ensure that all the needed directories are present # hierarchy: +.if defined(NO_ROOT) + cd ${.CURDIR}/etc; ${MAKE} LOCAL_MTREE=${LOCAL_MTREE} \ + -DNO_ROOT METALOG=${METALOG} distrib-dirs +.else cd ${.CURDIR}/etc; ${MAKE} LOCAL_MTREE=${LOCAL_MTREE} distrib-dirs +.endif # # libraries - build all libraries, and install them under ${DESTDIR}. @@ -1651,7 +1708,8 @@ NOFUN=-DNO_FSCHG -DWITHOUT_HTML -DWITHOU XDDIR=${XDEV_ARCH}-freebsd XDTP=/usr/${XDDIR} -CDBENV=MAKEOBJDIRPREFIX=${MAKEOBJDIRPREFIX}/${XDDIR} +CDBENV=MAKEOBJDIRPREFIX=${MAKEOBJDIRPREFIX}/${XDDIR} \ + INSTALL="sh ${.CURDIR}/tools/install.sh" CDENV= ${CDBENV} \ _SHLIBDIRPREFIX=${XDTP} \ TOOLS_PREFIX=${XDTP} Modified: stable/9/etc/Makefile ============================================================================== --- stable/9/etc/Makefile Tue May 14 20:25:07 2013 (r250639) +++ stable/9/etc/Makefile Tue May 14 21:15:36 2013 (r250640) @@ -156,6 +156,9 @@ ETCMAIL=Makefile README mailer.conf acce # Special top level files for FreeBSD FREEBSD=COPYRIGHT +# Sanitize DESTDIR +DESTDIR:= ${DESTDIR:C://*:/:g} + afterinstall: .if ${MK_MAN} != "no" ${_+_}cd ${.CURDIR}/../share/man; ${MAKE} makedb @@ -177,6 +180,10 @@ CAP_MKDB_ENDIAN?= PWD_MKDB_ENDIAN?= .endif +.if defined(NO_ROOT) +METALOG.add?= cat -l >> ${METALOG} +.endif + distribution: .if !defined(DESTDIR) @echo "set DESTDIR before running \"make ${.TARGET}\"" @@ -198,6 +205,14 @@ distribution: .endif pwd_mkdb ${PWD_MKDB_ENDIAN} -i -p -d ${DESTDIR}/etc \ ${DESTDIR}/etc/master.passwd +.if defined(NO_ROOT) + ( \ + echo "./etc/login.conf.db type=file mode=0644 uname=root gname=wheel"; \ + echo "./etc/passwd type=file mode=0644 uname=root gname=wheel"; \ + echo "./etc/pwd.db type=file mode=0644 uname=root gname=wheel"; \ + echo "./etc/spwd.db type=file mode=0600 uname=root gname=wheel"; \ + ) | ${METALOG.add} +.endif .if ${MK_BLUETOOTH} != "no" ${_+_}cd ${.CURDIR}/bluetooth; ${MAKE} install .endif @@ -321,6 +336,21 @@ distrib-dirs: ${MTREES:N/*} -f $$m -p $$d; \ ${MTREE_CMD} -deU ${MTREE_FOLLOWS_SYMLINKS} -f $$m -p $$d; \ done; true +.if defined(NO_ROOT) + @set ${MTREES}; \ + while test $$# -ge 2; do \ + m=${.CURDIR}/$$1; \ + shift; \ + d=$$1; \ + test "$$d" == "/" && d=""; \ + d=${DISTBASE}$$d; \ + shift; \ + ${ECHO} "${MTREE_CMD:N-W} -C -f $$m -K uname,gname | " \ + "sed s#^\.#.$$d# | ${METALOG.add}" ; \ + ${MTREE_CMD:N-W} -C -f $$m -K uname,gname | sed s#^\.#.$$d# | \ + ${METALOG.add} ; \ + done; true +.endif ${INSTALL_SYMLINK} usr/src/sys ${DESTDIR}/sys cd ${DESTDIR}/usr/share/man; \ for mandir in man*; do \ From owner-svn-src-all@FreeBSD.ORG Wed May 15 00:58:46 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id 182DE551; Wed, 15 May 2013 00:58:46 +0000 (UTC) (envelope-from yongari@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id 09EF3A9A; Wed, 15 May 2013 00:58:46 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.6/8.14.6) with ESMTP id r4F0wjsE076627; Wed, 15 May 2013 00:58:45 GMT (envelope-from yongari@svn.freebsd.org) Received: (from yongari@localhost) by svn.freebsd.org (8.14.6/8.14.5/Submit) id r4F0wjcI076626; Wed, 15 May 2013 00:58:45 GMT (envelope-from yongari@svn.freebsd.org) Message-Id: <201305150058.r4F0wjcI076626@svn.freebsd.org> From: Pyun YongHyeon Date: Wed, 15 May 2013 00:58:45 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org Subject: svn commit: r250644 - stable/9/sys/dev/re X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 15 May 2013 00:58:46 -0000 Author: yongari Date: Wed May 15 00:58:45 2013 New Revision: 250644 URL: http://svnweb.freebsd.org/changeset/base/250644 Log: MFC r248227: Disable TX IP header checksum offloading on RL_HWREV_8168CP. The controller generates wrong checksummed frame if the IP packet has IP options. Modified: stable/9/sys/dev/re/if_re.c Directory Properties: stable/9/sys/ (props changed) stable/9/sys/dev/ (props changed) Modified: stable/9/sys/dev/re/if_re.c ============================================================================== --- stable/9/sys/dev/re/if_re.c Tue May 14 21:39:38 2013 (r250643) +++ stable/9/sys/dev/re/if_re.c Wed May 15 00:58:45 2013 (r250644) @@ -1587,7 +1587,8 @@ re_attach(device_t dev) * packet has IP options so disable TX IP checksum offloading. */ if (sc->rl_hwrev->rl_rev == RL_HWREV_8168C || - sc->rl_hwrev->rl_rev == RL_HWREV_8168C_SPIN2) + sc->rl_hwrev->rl_rev == RL_HWREV_8168C_SPIN2 || + sc->rl_hwrev->rl_rev == RL_HWREV_8168CP) ifp->if_hwassist = CSUM_TCP | CSUM_UDP; else ifp->if_hwassist = CSUM_IP | CSUM_TCP | CSUM_UDP; @@ -3415,7 +3416,8 @@ re_ioctl(struct ifnet *ifp, u_long comma if ((ifp->if_capenable & IFCAP_TXCSUM) != 0) { rev = sc->rl_hwrev->rl_rev; if (rev == RL_HWREV_8168C || - rev == RL_HWREV_8168C_SPIN2) + rev == RL_HWREV_8168C_SPIN2 || + rev == RL_HWREV_8168CP) ifp->if_hwassist |= CSUM_TCP | CSUM_UDP; else ifp->if_hwassist |= RE_CSUM_FEATURES; From owner-svn-src-all@FreeBSD.ORG Wed May 15 01:00:41 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id 10F1C6E3; Wed, 15 May 2013 01:00:41 +0000 (UTC) (envelope-from yongari@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id 02075AB4; Wed, 15 May 2013 01:00:41 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.6/8.14.6) with ESMTP id r4F10eKL078772; Wed, 15 May 2013 01:00:40 GMT (envelope-from yongari@svn.freebsd.org) Received: (from yongari@localhost) by svn.freebsd.org (8.14.6/8.14.5/Submit) id r4F10ePQ078771; Wed, 15 May 2013 01:00:40 GMT (envelope-from yongari@svn.freebsd.org) Message-Id: <201305150100.r4F10ePQ078771@svn.freebsd.org> From: Pyun YongHyeon Date: Wed, 15 May 2013 01:00:40 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-8@freebsd.org Subject: svn commit: r250645 - stable/8/sys/dev/re X-SVN-Group: stable-8 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 15 May 2013 01:00:41 -0000 Author: yongari Date: Wed May 15 01:00:40 2013 New Revision: 250645 URL: http://svnweb.freebsd.org/changeset/base/250645 Log: MFC r248227: Disable TX IP header checksum offloading on RL_HWREV_8168CP. The controller generates wrong checksummed frame if the IP packet has IP options. Modified: stable/8/sys/dev/re/if_re.c Directory Properties: stable/8/sys/ (props changed) stable/8/sys/dev/ (props changed) stable/8/sys/dev/re/ (props changed) Modified: stable/8/sys/dev/re/if_re.c ============================================================================== --- stable/8/sys/dev/re/if_re.c Wed May 15 00:58:45 2013 (r250644) +++ stable/8/sys/dev/re/if_re.c Wed May 15 01:00:40 2013 (r250645) @@ -1583,7 +1583,8 @@ re_attach(device_t dev) * packet has IP options so disable TX IP checksum offloading. */ if (sc->rl_hwrev->rl_rev == RL_HWREV_8168C || - sc->rl_hwrev->rl_rev == RL_HWREV_8168C_SPIN2) + sc->rl_hwrev->rl_rev == RL_HWREV_8168C_SPIN2 || + sc->rl_hwrev->rl_rev == RL_HWREV_8168CP) ifp->if_hwassist = CSUM_TCP | CSUM_UDP; else ifp->if_hwassist = CSUM_IP | CSUM_TCP | CSUM_UDP; @@ -3374,7 +3375,8 @@ re_ioctl(struct ifnet *ifp, u_long comma if ((ifp->if_capenable & IFCAP_TXCSUM) != 0) { rev = sc->rl_hwrev->rl_rev; if (rev == RL_HWREV_8168C || - rev == RL_HWREV_8168C_SPIN2) + rev == RL_HWREV_8168C_SPIN2 || + rev == RL_HWREV_8168CP) ifp->if_hwassist |= CSUM_TCP | CSUM_UDP; else ifp->if_hwassist |= RE_CSUM_FEATURES; From owner-svn-src-all@FreeBSD.ORG Wed May 15 01:05:17 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id 0BA7B89C; Wed, 15 May 2013 01:05:17 +0000 (UTC) (envelope-from yongari@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id F1979AE7; Wed, 15 May 2013 01:05:16 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.6/8.14.6) with ESMTP id r4F15GDm079871; Wed, 15 May 2013 01:05:16 GMT (envelope-from yongari@svn.freebsd.org) Received: (from yongari@localhost) by svn.freebsd.org (8.14.6/8.14.5/Submit) id r4F15GvW079869; Wed, 15 May 2013 01:05:16 GMT (envelope-from yongari@svn.freebsd.org) Message-Id: <201305150105.r4F15GvW079869@svn.freebsd.org> From: Pyun YongHyeon Date: Wed, 15 May 2013 01:05:16 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org Subject: svn commit: r250646 - stable/9/sys/dev/sis X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 15 May 2013 01:05:17 -0000 Author: yongari Date: Wed May 15 01:05:16 2013 New Revision: 250646 URL: http://svnweb.freebsd.org/changeset/base/250646 Log: MFC r248456: r119712 introduced SIS_TYPE_83816 but it was not actually set in driver such that checking against the type was always false. To detect NS DP83816, driver should have checked silicon revision register for NS controllers. While here, remove SIS_TYPE_83816 to not make the similar mistake again. Modified: stable/9/sys/dev/sis/if_sis.c stable/9/sys/dev/sis/if_sisreg.h Directory Properties: stable/9/sys/ (props changed) stable/9/sys/dev/ (props changed) Modified: stable/9/sys/dev/sis/if_sis.c ============================================================================== --- stable/9/sys/dev/sis/if_sis.c Wed May 15 01:00:40 2013 (r250645) +++ stable/9/sys/dev/sis/if_sis.c Wed May 15 01:05:16 2013 (r250646) @@ -625,7 +625,7 @@ sis_miibus_statchg(device_t dev) SIS_CLRBIT(sc, SIS_RX_CFG, SIS_RXCFG_RX_TXPKTS); } - if (sc->sis_type == SIS_TYPE_83816) { + if (sc->sis_type == SIS_TYPE_83815 && sc->sis_srr >= NS_SRR_16A) { /* * MPII03.D: Half Duplex Excessive Collisions. * Also page 49 in 83816 manual @@ -1990,7 +1990,7 @@ sis_initl(struct sis_softc *sc) return; } - if (sc->sis_type == SIS_TYPE_83815 || sc->sis_type == SIS_TYPE_83816) { + if (sc->sis_type == SIS_TYPE_83815) { if (sc->sis_manual_pad != 0) sc->sis_flags |= SIS_FLAG_MANUAL_PAD; else Modified: stable/9/sys/dev/sis/if_sisreg.h ============================================================================== --- stable/9/sys/dev/sis/if_sisreg.h Wed May 15 01:00:40 2013 (r250645) +++ stable/9/sys/dev/sis/if_sisreg.h Wed May 15 01:05:16 2013 (r250646) @@ -439,7 +439,6 @@ struct sis_type { #define SIS_TYPE_900 1 #define SIS_TYPE_7016 2 #define SIS_TYPE_83815 3 -#define SIS_TYPE_83816 4 struct sis_txdesc { struct mbuf *tx_m; From owner-svn-src-all@FreeBSD.ORG Wed May 15 01:06:25 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id 028C5A21; Wed, 15 May 2013 01:06:25 +0000 (UTC) (envelope-from yongari@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id E898DAF5; Wed, 15 May 2013 01:06:24 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.6/8.14.6) with ESMTP id r4F16OqY080162; Wed, 15 May 2013 01:06:24 GMT (envelope-from yongari@svn.freebsd.org) Received: (from yongari@localhost) by svn.freebsd.org (8.14.6/8.14.5/Submit) id r4F16OZX080158; Wed, 15 May 2013 01:06:24 GMT (envelope-from yongari@svn.freebsd.org) Message-Id: <201305150106.r4F16OZX080158@svn.freebsd.org> From: Pyun YongHyeon Date: Wed, 15 May 2013 01:06:24 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-8@freebsd.org Subject: svn commit: r250647 - stable/8/sys/dev/sis X-SVN-Group: stable-8 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 15 May 2013 01:06:25 -0000 Author: yongari Date: Wed May 15 01:06:24 2013 New Revision: 250647 URL: http://svnweb.freebsd.org/changeset/base/250647 Log: MFC r248456: r119712 introduced SIS_TYPE_83816 but it was not actually set in driver such that checking against the type was always false. To detect NS DP83816, driver should have checked silicon revision register for NS controllers. While here, remove SIS_TYPE_83816 to not make the similar mistake again. Modified: stable/8/sys/dev/sis/if_sis.c stable/8/sys/dev/sis/if_sisreg.h Directory Properties: stable/8/sys/ (props changed) stable/8/sys/dev/ (props changed) stable/8/sys/dev/sis/ (props changed) Modified: stable/8/sys/dev/sis/if_sis.c ============================================================================== --- stable/8/sys/dev/sis/if_sis.c Wed May 15 01:05:16 2013 (r250646) +++ stable/8/sys/dev/sis/if_sis.c Wed May 15 01:06:24 2013 (r250647) @@ -628,7 +628,7 @@ sis_miibus_statchg(device_t dev) SIS_CLRBIT(sc, SIS_RX_CFG, SIS_RXCFG_RX_TXPKTS); } - if (sc->sis_type == SIS_TYPE_83816) { + if (sc->sis_type == SIS_TYPE_83815 && sc->sis_srr >= NS_SRR_16A) { /* * MPII03.D: Half Duplex Excessive Collisions. * Also page 49 in 83816 manual @@ -1993,7 +1993,7 @@ sis_initl(struct sis_softc *sc) return; } - if (sc->sis_type == SIS_TYPE_83815 || sc->sis_type == SIS_TYPE_83816) { + if (sc->sis_type == SIS_TYPE_83815) { if (sc->sis_manual_pad != 0) sc->sis_flags |= SIS_FLAG_MANUAL_PAD; else Modified: stable/8/sys/dev/sis/if_sisreg.h ============================================================================== --- stable/8/sys/dev/sis/if_sisreg.h Wed May 15 01:05:16 2013 (r250646) +++ stable/8/sys/dev/sis/if_sisreg.h Wed May 15 01:06:24 2013 (r250647) @@ -439,7 +439,6 @@ struct sis_type { #define SIS_TYPE_900 1 #define SIS_TYPE_7016 2 #define SIS_TYPE_83815 3 -#define SIS_TYPE_83816 4 struct sis_txdesc { struct mbuf *tx_m; From owner-svn-src-all@FreeBSD.ORG Wed May 15 01:16:43 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id F0E06C2A; Wed, 15 May 2013 01:16:42 +0000 (UTC) (envelope-from yongari@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id C903FB3E; Wed, 15 May 2013 01:16:42 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.6/8.14.6) with ESMTP id r4F1Ggn3084032; Wed, 15 May 2013 01:16:42 GMT (envelope-from yongari@svn.freebsd.org) Received: (from yongari@localhost) by svn.freebsd.org (8.14.6/8.14.5/Submit) id r4F1GgHv084030; Wed, 15 May 2013 01:16:42 GMT (envelope-from yongari@svn.freebsd.org) Message-Id: <201305150116.r4F1GgHv084030@svn.freebsd.org> From: Pyun YongHyeon Date: Wed, 15 May 2013 01:16:42 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org Subject: svn commit: r250648 - stable/9/sys/dev/mii X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 15 May 2013 01:16:43 -0000 Author: yongari Date: Wed May 15 01:16:41 2013 New Revision: 250648 URL: http://svnweb.freebsd.org/changeset/base/250648 Log: MFC r248542: For RTL8211B or later PHYs, enable crossover detection and auto-correction. This change makes re(4) establish a link with a system using non-crossover UTP cable. Modified: stable/9/sys/dev/mii/rgephy.c stable/9/sys/dev/mii/rgephyreg.h Directory Properties: stable/9/sys/ (props changed) stable/9/sys/dev/ (props changed) Modified: stable/9/sys/dev/mii/rgephy.c ============================================================================== --- stable/9/sys/dev/mii/rgephy.c Wed May 15 01:06:24 2013 (r250647) +++ stable/9/sys/dev/mii/rgephy.c Wed May 15 01:16:41 2013 (r250648) @@ -488,7 +488,7 @@ rgephy_load_dspcode(struct mii_softc *sc static void rgephy_reset(struct mii_softc *sc) { - uint16_t ssr; + uint16_t pcr, ssr; if ((sc->mii_flags & MIIF_PHYPRIV0) == 0 && sc->mii_mpd_rev == 3) { /* RTL8211C(L) */ @@ -499,6 +499,15 @@ rgephy_reset(struct mii_softc *sc) } } + if (sc->mii_mpd_rev >= 2) { + pcr = PHY_READ(sc, RGEPHY_MII_PCR); + if ((pcr & RGEPHY_PCR_MDIX_AUTO) == 0) { + pcr &= ~RGEPHY_PCR_MDI_MASK; + pcr |= RGEPHY_PCR_MDIX_AUTO; + PHY_WRITE(sc, RGEPHY_MII_PCR, pcr); + } + } + mii_phy_reset(sc); DELAY(1000); rgephy_load_dspcode(sc); Modified: stable/9/sys/dev/mii/rgephyreg.h ============================================================================== --- stable/9/sys/dev/mii/rgephyreg.h Wed May 15 01:06:24 2013 (r250647) +++ stable/9/sys/dev/mii/rgephyreg.h Wed May 15 01:16:41 2013 (r250648) @@ -138,6 +138,17 @@ #define RGEPHY_EXTSTS_T_HD_CAP 0x1000 /* 1000base-T HD capable */ /* RTL8211B(L)/RTL8211C(L) */ +#define RGEPHY_MII_PCR 0x10 /* PHY Specific control register */ +#define RGEPHY_PCR_ASSERT_CRS 0x0800 +#define RGEPHY_PCR_FORCE_LINK 0x0400 +#define RGEPHY_PCR_MDI_MASK 0x0060 +#define RGEPHY_PCR_MDIX_AUTO 0x0040 +#define RGEPHY_PCR_MDIX_MANUAL 0x0020 +#define RGEPHY_PCR_MDI_MANUAL 0x0000 +#define RGEPHY_PCR_CLK125_DIS 0x0010 +#define RGEPHY_PCR_JABBER_DIS 0x0001 + +/* RTL8211B(L)/RTL8211C(L) */ #define RGEPHY_MII_SSR 0x11 /* PHY Specific status register */ #define RGEPHY_SSR_S1000 0x8000 /* 1000Mbps */ #define RGEPHY_SSR_S100 0x4000 /* 100Mbps */ From owner-svn-src-all@FreeBSD.ORG Wed May 15 01:18:00 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id 36DC3DB5; Wed, 15 May 2013 01:18:00 +0000 (UTC) (envelope-from yongari@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id 0F4B6B52; Wed, 15 May 2013 01:18:00 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.6/8.14.6) with ESMTP id r4F1Hx3M084296; Wed, 15 May 2013 01:17:59 GMT (envelope-from yongari@svn.freebsd.org) Received: (from yongari@localhost) by svn.freebsd.org (8.14.6/8.14.5/Submit) id r4F1Hxh1084294; Wed, 15 May 2013 01:17:59 GMT (envelope-from yongari@svn.freebsd.org) Message-Id: <201305150117.r4F1Hxh1084294@svn.freebsd.org> From: Pyun YongHyeon Date: Wed, 15 May 2013 01:17:59 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-8@freebsd.org Subject: svn commit: r250649 - stable/8/sys/dev/mii X-SVN-Group: stable-8 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 15 May 2013 01:18:00 -0000 Author: yongari Date: Wed May 15 01:17:59 2013 New Revision: 250649 URL: http://svnweb.freebsd.org/changeset/base/250649 Log: MFC r248542: For RTL8211B or later PHYs, enable crossover detection and auto-correction. This change makes re(4) establish a link with a system using non-crossover UTP cable. Modified: stable/8/sys/dev/mii/rgephy.c stable/8/sys/dev/mii/rgephyreg.h Directory Properties: stable/8/sys/ (props changed) stable/8/sys/dev/ (props changed) stable/8/sys/dev/mii/ (props changed) Modified: stable/8/sys/dev/mii/rgephy.c ============================================================================== --- stable/8/sys/dev/mii/rgephy.c Wed May 15 01:16:41 2013 (r250648) +++ stable/8/sys/dev/mii/rgephy.c Wed May 15 01:17:59 2013 (r250649) @@ -517,7 +517,7 @@ static void rgephy_reset(struct mii_softc *sc) { struct rgephy_softc *rsc; - uint16_t ssr; + uint16_t pcr, ssr; rsc = (struct rgephy_softc *)sc; if ((sc->mii_flags & MIIF_PHYPRIV0) == 0 && rsc->mii_revision == 3) { @@ -529,6 +529,15 @@ rgephy_reset(struct mii_softc *sc) } } + if (rsc->mii_revision >= 2) { + pcr = PHY_READ(sc, RGEPHY_MII_PCR); + if ((pcr & RGEPHY_PCR_MDIX_AUTO) == 0) { + pcr &= ~RGEPHY_PCR_MDI_MASK; + pcr |= RGEPHY_PCR_MDIX_AUTO; + PHY_WRITE(sc, RGEPHY_MII_PCR, pcr); + } + } + mii_phy_reset(sc); DELAY(1000); rgephy_load_dspcode(sc); Modified: stable/8/sys/dev/mii/rgephyreg.h ============================================================================== --- stable/8/sys/dev/mii/rgephyreg.h Wed May 15 01:16:41 2013 (r250648) +++ stable/8/sys/dev/mii/rgephyreg.h Wed May 15 01:17:59 2013 (r250649) @@ -138,6 +138,17 @@ #define RGEPHY_EXTSTS_T_HD_CAP 0x1000 /* 1000base-T HD capable */ /* RTL8211B(L)/RTL8211C(L) */ +#define RGEPHY_MII_PCR 0x10 /* PHY Specific control register */ +#define RGEPHY_PCR_ASSERT_CRS 0x0800 +#define RGEPHY_PCR_FORCE_LINK 0x0400 +#define RGEPHY_PCR_MDI_MASK 0x0060 +#define RGEPHY_PCR_MDIX_AUTO 0x0040 +#define RGEPHY_PCR_MDIX_MANUAL 0x0020 +#define RGEPHY_PCR_MDI_MANUAL 0x0000 +#define RGEPHY_PCR_CLK125_DIS 0x0010 +#define RGEPHY_PCR_JABBER_DIS 0x0001 + +/* RTL8211B(L)/RTL8211C(L) */ #define RGEPHY_MII_SSR 0x11 /* PHY Specific status register */ #define RGEPHY_SSR_S1000 0x8000 /* 1000Mbps */ #define RGEPHY_SSR_S100 0x4000 /* 100Mbps */ From owner-svn-src-all@FreeBSD.ORG Wed May 15 01:21:40 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id E3B07B5; Wed, 15 May 2013 01:21:40 +0000 (UTC) (envelope-from yongari@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id D5B58B6D; Wed, 15 May 2013 01:21:40 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.6/8.14.6) with ESMTP id r4F1Le8l086727; Wed, 15 May 2013 01:21:40 GMT (envelope-from yongari@svn.freebsd.org) Received: (from yongari@localhost) by svn.freebsd.org (8.14.6/8.14.5/Submit) id r4F1Le1k086726; Wed, 15 May 2013 01:21:40 GMT (envelope-from yongari@svn.freebsd.org) Message-Id: <201305150121.r4F1Le1k086726@svn.freebsd.org> From: Pyun YongHyeon Date: Wed, 15 May 2013 01:21:40 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org Subject: svn commit: r250650 - stable/9/sys/dev/bge X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 15 May 2013 01:21:41 -0000 Author: yongari Date: Wed May 15 01:21:40 2013 New Revision: 250650 URL: http://svnweb.freebsd.org/changeset/base/250650 Log: MFC r248993: Fix a typo. Modified: stable/9/sys/dev/bge/if_bge.c Directory Properties: stable/9/sys/ (props changed) stable/9/sys/dev/ (props changed) Modified: stable/9/sys/dev/bge/if_bge.c ============================================================================== --- stable/9/sys/dev/bge/if_bge.c Wed May 15 01:17:59 2013 (r250649) +++ stable/9/sys/dev/bge/if_bge.c Wed May 15 01:21:40 2013 (r250650) @@ -679,7 +679,7 @@ bge_ape_lock_init(struct bge_softc *sc) bit = BGE_APE_LOCK_GRANT_DRIVER0; break; default: - if (sc->bge_func_addr != 0) + if (sc->bge_func_addr == 0) bit = BGE_APE_LOCK_GRANT_DRIVER0; else bit = (1 << sc->bge_func_addr); From owner-svn-src-all@FreeBSD.ORG Wed May 15 01:22:56 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id 69645232; Wed, 15 May 2013 01:22:56 +0000 (UTC) (envelope-from yongari@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id 5BC1DB91; Wed, 15 May 2013 01:22:56 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.6/8.14.6) with ESMTP id r4F1MuI6087058; Wed, 15 May 2013 01:22:56 GMT (envelope-from yongari@svn.freebsd.org) Received: (from yongari@localhost) by svn.freebsd.org (8.14.6/8.14.5/Submit) id r4F1MuVc087057; Wed, 15 May 2013 01:22:56 GMT (envelope-from yongari@svn.freebsd.org) Message-Id: <201305150122.r4F1MuVc087057@svn.freebsd.org> From: Pyun YongHyeon Date: Wed, 15 May 2013 01:22:56 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-8@freebsd.org Subject: svn commit: r250651 - stable/8/sys/dev/bge X-SVN-Group: stable-8 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 15 May 2013 01:22:56 -0000 Author: yongari Date: Wed May 15 01:22:55 2013 New Revision: 250651 URL: http://svnweb.freebsd.org/changeset/base/250651 Log: MFC r248993: Fix a typo. Modified: stable/8/sys/dev/bge/if_bge.c Directory Properties: stable/8/sys/ (props changed) stable/8/sys/dev/ (props changed) stable/8/sys/dev/bge/ (props changed) Modified: stable/8/sys/dev/bge/if_bge.c ============================================================================== --- stable/8/sys/dev/bge/if_bge.c Wed May 15 01:21:40 2013 (r250650) +++ stable/8/sys/dev/bge/if_bge.c Wed May 15 01:22:55 2013 (r250651) @@ -679,7 +679,7 @@ bge_ape_lock_init(struct bge_softc *sc) bit = BGE_APE_LOCK_GRANT_DRIVER0; break; default: - if (sc->bge_func_addr != 0) + if (sc->bge_func_addr == 0) bit = BGE_APE_LOCK_GRANT_DRIVER0; else bit = (1 << sc->bge_func_addr); From owner-svn-src-all@FreeBSD.ORG Wed May 15 01:37:00 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id 704BF7A4; Wed, 15 May 2013 01:37:00 +0000 (UTC) (envelope-from rmacklem@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id 467C9CC6; Wed, 15 May 2013 01:37:00 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.6/8.14.6) with ESMTP id r4F1b01K091462; Wed, 15 May 2013 01:37:00 GMT (envelope-from rmacklem@svn.freebsd.org) Received: (from rmacklem@localhost) by svn.freebsd.org (8.14.6/8.14.5/Submit) id r4F1b0md091461; Wed, 15 May 2013 01:37:00 GMT (envelope-from rmacklem@svn.freebsd.org) Message-Id: <201305150137.r4F1b0md091461@svn.freebsd.org> From: Rick Macklem Date: Wed, 15 May 2013 01:37:00 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org Subject: svn commit: r250652 - stable/9/sys/kgssapi/krb5 X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 15 May 2013 01:37:00 -0000 Author: rmacklem Date: Wed May 15 01:36:59 2013 New Revision: 250652 URL: http://svnweb.freebsd.org/changeset/base/250652 Log: MFC: r250157 Isilon reported that sec=krb5p NFS mounts had a problem when m_len == 0 for the last mbuf of the list with an encrypted message. This patch replaces the KASSERT() with code that handles this case. Modified: stable/9/sys/kgssapi/krb5/krb5_mech.c Directory Properties: stable/9/sys/ (props changed) Modified: stable/9/sys/kgssapi/krb5/krb5_mech.c ============================================================================== --- stable/9/sys/kgssapi/krb5/krb5_mech.c Wed May 15 01:22:55 2013 (r250651) +++ stable/9/sys/kgssapi/krb5/krb5_mech.c Wed May 15 01:36:59 2013 (r250652) @@ -1585,6 +1585,8 @@ m_trim(struct mbuf *m, int len) struct mbuf *n; int off; + if (m == NULL) + return; n = m_getptr(m, len, &off); if (n) { n->m_len = off; @@ -1600,7 +1602,7 @@ krb5_unwrap_old(struct krb5_context *kc, uint8_t sgn_alg[2], uint8_t seal_alg[2]) { OM_uint32 res; - struct mbuf *m, *mlast, *hm, *cm; + struct mbuf *m, *mlast, *hm, *cm, *n; uint8_t *p, dir; size_t mlen, tlen, elen, datalen, padlen; size_t cklen; @@ -1702,9 +1704,25 @@ krb5_unwrap_old(struct krb5_context *kc, /* * Check the trailing pad bytes. + * RFC1964 specifies between 1<->8 bytes, each with a binary value + * equal to the number of bytes. */ - KASSERT(mlast->m_len > 0, ("Unexpected empty mbuf")); - padlen = mlast->m_data[mlast->m_len - 1]; + if (mlast->m_len > 0) + padlen = mlast->m_data[mlast->m_len - 1]; + else { + n = m_getptr(m, tlen + datalen - 1, &i); + /* + * When the position is exactly equal to the # of data bytes + * in the mbuf list, m_getptr() will return the last mbuf in + * the list and an off == m_len for that mbuf, so that case + * needs to be checked as well as a NULL return. + */ + if (n == NULL || n->m_len == i) + return (GSS_S_DEFECTIVE_TOKEN); + padlen = n->m_data[i]; + } + if (padlen < 1 || padlen > 8 || padlen > tlen + datalen) + return (GSS_S_DEFECTIVE_TOKEN); m_copydata(m, tlen + datalen - padlen, padlen, buf); for (i = 0; i < padlen; i++) { if (buf[i] != padlen) { From owner-svn-src-all@FreeBSD.ORG Wed May 15 01:40:16 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id C4B4BA0D; Wed, 15 May 2013 01:40:16 +0000 (UTC) (envelope-from rmacklem@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id B6DA6CDC; Wed, 15 May 2013 01:40:16 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.6/8.14.6) with ESMTP id r4F1eG01093551; Wed, 15 May 2013 01:40:16 GMT (envelope-from rmacklem@svn.freebsd.org) Received: (from rmacklem@localhost) by svn.freebsd.org (8.14.6/8.14.5/Submit) id r4F1eG9R093550; Wed, 15 May 2013 01:40:16 GMT (envelope-from rmacklem@svn.freebsd.org) Message-Id: <201305150140.r4F1eG9R093550@svn.freebsd.org> From: Rick Macklem Date: Wed, 15 May 2013 01:40:16 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org Subject: svn commit: r250653 - stable/9/usr.bin/nfsstat X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 15 May 2013 01:40:16 -0000 Author: rmacklem Date: Wed May 15 01:40:16 2013 New Revision: 250653 URL: http://svnweb.freebsd.org/changeset/base/250653 Log: MFC: r250158 Document that the NFSv4 server statistics are operation counts and not RPC counts. This is a content change. Modified: stable/9/usr.bin/nfsstat/nfsstat.1 Directory Properties: stable/9/usr.bin/nfsstat/ (props changed) Modified: stable/9/usr.bin/nfsstat/nfsstat.1 ============================================================================== --- stable/9/usr.bin/nfsstat/nfsstat.1 Wed May 15 01:36:59 2013 (r250652) +++ stable/9/usr.bin/nfsstat/nfsstat.1 Wed May 15 01:40:16 2013 (r250653) @@ -28,7 +28,7 @@ .\" From: @(#)nfsstat.1 8.1 (Berkeley) 6/6/93 .\" $FreeBSD$ .\" -.Dd November 14, 2012 +.Dd May 1, 2013 .Dt NFSSTAT 1 .Os .Sh NAME @@ -48,6 +48,10 @@ The command displays statistics kept about .Tn NFS client and server activity. +For the NFSv4 server, the statistics are for operations within the Compound +RPCs and not the count of RPCs. +If you wish to compare RPC counts between NFSv3 and NFSv4, you must use +statistics in the client(s). .Pp The options are as follows: .Bl -tag -width indent From owner-svn-src-all@FreeBSD.ORG Wed May 15 01:44:02 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id 719F1BB7; Wed, 15 May 2013 01:44:02 +0000 (UTC) (envelope-from rmacklem@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id 63CC7D00; Wed, 15 May 2013 01:44:02 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.6/8.14.6) with ESMTP id r4F1i2D8094465; Wed, 15 May 2013 01:44:02 GMT (envelope-from rmacklem@svn.freebsd.org) Received: (from rmacklem@localhost) by svn.freebsd.org (8.14.6/8.14.5/Submit) id r4F1i26K094464; Wed, 15 May 2013 01:44:02 GMT (envelope-from rmacklem@svn.freebsd.org) Message-Id: <201305150144.r4F1i26K094464@svn.freebsd.org> From: Rick Macklem Date: Wed, 15 May 2013 01:44:02 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org Subject: svn commit: r250654 - stable/9/usr.sbin/nfsd X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 15 May 2013 01:44:02 -0000 Author: rmacklem Date: Wed May 15 01:44:01 2013 New Revision: 250654 URL: http://svnweb.freebsd.org/changeset/base/250654 Log: MFC: r250162 Document the fact that an NFSv4 mount against a volume on the same host can result in a hung NFS server and is not recommended. This is a content change. Modified: stable/9/usr.sbin/nfsd/nfsv4.4 Directory Properties: stable/9/usr.sbin/nfsd/ (props changed) Modified: stable/9/usr.sbin/nfsd/nfsv4.4 ============================================================================== --- stable/9/usr.sbin/nfsd/nfsv4.4 Wed May 15 01:40:16 2013 (r250653) +++ stable/9/usr.sbin/nfsd/nfsv4.4 Wed May 15 01:44:01 2013 (r250654) @@ -24,7 +24,7 @@ .\" .\" $FreeBSD$ .\" -.Dd December 23, 2012 +.Dd May 1, 2013 .Dt NFSV4 4 .Os .Sh NAME @@ -289,6 +289,13 @@ and daemons at boot time via the ``nfsuserd_flags'' and ``nfscbd_flags'' .Xr rc.conf 5 variables. +.Pp +NFSv4 mount(s) against exported volume(s) on the same host are not recommended, +since this can result in a hung NFS server. +It occurs when an nfsd thread tries to do an NFSv4 VOP_RECLAIM()/Close RPC +as part of acquiring a new vnode. +If all other nfsd threads are blocked waiting for lock(s) held by this nfsd +thread, then there isn't an nfsd thread to service the Close RPC. .Sh FILES .Bl -tag -width /var/db/nfs-stablerestart.bak -compact .It Pa /var/db/nfs-stablerestart From owner-svn-src-all@FreeBSD.ORG Wed May 15 02:12:44 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id B3359250; Wed, 15 May 2013 02:12:44 +0000 (UTC) (envelope-from bright@mu.org) Received: from elvis.mu.org (elvis.mu.org [192.203.228.196]) by mx1.freebsd.org (Postfix) with ESMTP id 397D3DF0; Wed, 15 May 2013 02:12:44 +0000 (UTC) Received: from Alfreds-MacBook-Pro-9.local (OTWAON23-1176242366.sdsl.bell.ca [70.28.8.190]) by elvis.mu.org (Postfix) with ESMTPSA id 2770D1A3D04; Tue, 14 May 2013 19:12:23 -0700 (PDT) Message-ID: <5192EF00.3030700@mu.org> Date: Tue, 14 May 2013 22:12:16 -0400 From: Alfred Perlstein User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.7; rv:17.0) Gecko/20130328 Thunderbird/17.0.5 MIME-Version: 1.0 To: Will Andrews Subject: Re: svn commit: r250411 - in head/sys: conf kern sys References: <201305091628.r49GSI33039873@svn.freebsd.org> <518F320D.3070304@mu.org> In-Reply-To: Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit Cc: Marcel Moolenaar , jhb@freebsd.org, svn-src-all@freebsd.org, alfred@freebsd.org, attilio@freebsd.org, src-committers@freebsd.org, Jeff Roberson , svn-src-head@freebsd.org X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 15 May 2013 02:12:44 -0000 On 5/13/13 12:58 PM, Will Andrews wrote: > On Sun, May 12, 2013 at 12:09 AM, Alfred Perlstein wrote: > >> Can we just admit to ourselves that tweaks to debugging macros/printing >> and WITNESS are our kernel developer's "bikeshed zone" and get over the >> fact that people's needs may diverge and changing non-default behavior in >> non-critical paths is not going to be the death of the kernel as we know it? >> >> I could certainly believe that this sort of thing needs long and thorough >> discussion if it wasn't the equivalent of style tweaks to manpages. >> >> Let's leave the long and lengthy discussions to things that matter such as >> standards compliance, ABI, API and really cool performance and stability >> stuff. > > Except that this is *not* the equivalent of style tweaks. I'm not sure how > you got that from Jeff's email. False positive LORs results in people > ignoring all LORs, including real ones. And that impacts stability. > Especially if you are trying to implement performance improvements or fix > bugs; in that case, the LORs act as a safeguard against violating existing > object relationship assumptions. > > Having worked on ZFS for a while, I can say that many (if not most) of the > LORs reported there that are false positives are because the locks > represent objects that are frequently and legitimately related to each > other in reverse orders, due to reuse of object types at different points > in the overall hierarchy. So, I agree that the biggest issue is that > witness's model of comparing strings is insufficient for representing more > complex lock relationships. > > In ZFS, in most cases, the locks are acquired after having already (in > debug builds) checked these relationships. It seems appropriate, > therefore, that witness should be improved by adding the ability to bless > specific object relationships on a per-lock entry basis, so that we > continue to be notified about *legitimate* LORs, at every call site and > between every pair of object types. > > It also seems best to add a new API for this purpose, so that it can be > used regardless of which lock type is being used, without having to modify > all existing lock calls. This does mean that code in FreeBSD would need to > independently verify the object relationships, but doing so is, IMHO, a lot > easier to improve upon than folding this functionality into existing APIs > by adding more arguments. > > --Will. > Sure WITNESS should be made to a lot of things. One volunteer made it work for a subset of developers without breaking it for the people outside of that subset. Time for the pitchforks and demands that IF YOU TOUCH IT, YOU BETTER FIX IT TO MY LIKING!!! Give me a break already. I highly doubt that Marcel or anyone would object to someone coming forward with this "better way", the problem is that no one will, however they will harp on bikeshedding about it to no end without a problem. Stop blocking, start coding. Start taking a step forward as the gift it is and take time to improve upon it instead of bashing it to pieces. -Alfred From owner-svn-src-all@FreeBSD.ORG Wed May 15 08:38:50 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id BCE8ED33; Wed, 15 May 2013 08:38:50 +0000 (UTC) (envelope-from des@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id ABA268EF; Wed, 15 May 2013 08:38:50 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.6/8.14.6) with ESMTP id r4F8coi3039294; Wed, 15 May 2013 08:38:50 GMT (envelope-from des@svn.freebsd.org) Received: (from des@localhost) by svn.freebsd.org (8.14.6/8.14.5/Submit) id r4F8coQJ039293; Wed, 15 May 2013 08:38:50 GMT (envelope-from des@svn.freebsd.org) Message-Id: <201305150838.r4F8coQJ039293@svn.freebsd.org> From: Dag-Erling Smørgrav Date: Wed, 15 May 2013 08:38:50 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r250657 - head/sys/fs/nfsserver X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 15 May 2013 08:38:50 -0000 Author: des Date: Wed May 15 08:38:49 2013 New Revision: 250657 URL: http://svnweb.freebsd.org/changeset/base/250657 Log: Fix typo in comment. Submitted by: Alex Weber MFC after: 1 week Modified: head/sys/fs/nfsserver/nfs_nfsdport.c Modified: head/sys/fs/nfsserver/nfs_nfsdport.c ============================================================================== --- head/sys/fs/nfsserver/nfs_nfsdport.c Wed May 15 06:13:09 2013 (r250656) +++ head/sys/fs/nfsserver/nfs_nfsdport.c Wed May 15 08:38:49 2013 (r250657) @@ -390,7 +390,7 @@ nfsvno_namei(struct nfsrv_descript *nd, /* * Initialize for scan, set ni_startdir and bump ref on dp again - * becuase lookup() will dereference ni_startdir. + * because lookup() will dereference ni_startdir. */ cnp->cn_thread = p; From owner-svn-src-all@FreeBSD.ORG Wed May 15 13:04:12 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id 5D7307F5; Wed, 15 May 2013 13:04:12 +0000 (UTC) (envelope-from brooks@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id 35D86B19; Wed, 15 May 2013 13:04:12 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.6/8.14.6) with ESMTP id r4FD4BEJ032149; Wed, 15 May 2013 13:04:11 GMT (envelope-from brooks@svn.freebsd.org) Received: (from brooks@localhost) by svn.freebsd.org (8.14.6/8.14.5/Submit) id r4FD4B1i032146; Wed, 15 May 2013 13:04:11 GMT (envelope-from brooks@svn.freebsd.org) Message-Id: <201305151304.r4FD4B1i032146@svn.freebsd.org> From: Brooks Davis Date: Wed, 15 May 2013 13:04:11 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r250658 - in head: share/mk sys/conf tools/build/options X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 15 May 2013 13:04:12 -0000 Author: brooks Date: Wed May 15 13:04:10 2013 New Revision: 250658 URL: http://svnweb.freebsd.org/changeset/base/250658 Log: Add a new option WITHOUT_FORMAT_EXTENSIONS to disable flags related to checking our kernel printf extensions. This is useful to allow compilers without these extensions to build kernels. Sponsored by: DARPA, AFRL Added: head/tools/build/options/WITHOUT_FORMAT_EXTENSIONS (contents, props changed) Modified: head/share/mk/bsd.own.mk head/sys/conf/kern.mk Modified: head/share/mk/bsd.own.mk ============================================================================== --- head/share/mk/bsd.own.mk Wed May 15 08:38:49 2013 (r250657) +++ head/share/mk/bsd.own.mk Wed May 15 13:04:10 2013 (r250658) @@ -268,6 +268,7 @@ __DEFAULT_YES_OPTIONS = \ ED_CRYPTO \ EXAMPLES \ FLOPPY \ + FORMAT_EXTENSIONS \ FORTH \ FP_LIBC \ FREEBSD_UPDATE \ Modified: head/sys/conf/kern.mk ============================================================================== --- head/sys/conf/kern.mk Wed May 15 08:38:49 2013 (r250657) +++ head/sys/conf/kern.mk Wed May 15 13:04:10 2013 (r250658) @@ -5,7 +5,7 @@ # CWARNFLAGS?= -Wall -Wredundant-decls -Wnested-externs -Wstrict-prototypes \ -Wmissing-prototypes -Wpointer-arith -Winline -Wcast-qual \ - -Wundef -Wno-pointer-sign -fformat-extensions \ + -Wundef -Wno-pointer-sign ${FORMAT_EXTENTIONS} \ -Wmissing-include-dirs -fdiagnostics-show-option \ ${CWARNEXTRA} # @@ -29,7 +29,15 @@ NO_WSOMETIMES_UNINITIALIZED= -Wno-error- # enough to error out the whole kernel build. Display them anyway, so there is # some incentive to fix them eventually. CWARNEXTRA?= -Wno-error-tautological-compare -Wno-error-empty-body \ - -Wno-error-parentheses-equality + -Wno-error-parentheses-equality ${NO_WFORMAT} +.endif + +# External compilers may not support our format extensions. Allow them +# to be disabled. WARNING: format checking is disabled in this case. +.if ${MK_FORMAT_EXTENSIONS} == "no" +NO_WFORMAT= -Wno-format +.else +FORMAT_EXTENTIONS= -fformat-extensions .endif # Added: head/tools/build/options/WITHOUT_FORMAT_EXTENSIONS ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ head/tools/build/options/WITHOUT_FORMAT_EXTENSIONS Wed May 15 13:04:10 2013 (r250658) @@ -0,0 +1,5 @@ +.\" $FreeBSD$ +Set to not enable +.Fl fformat-extensions +when compiling the kernel. +Also disables all format checking. From owner-svn-src-all@FreeBSD.ORG Wed May 15 13:42:18 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id 2EC3A382; Wed, 15 May 2013 13:42:18 +0000 (UTC) (envelope-from dim@FreeBSD.org) Received: from tensor.andric.com (tensor.andric.com [IPv6:2001:7b8:3a7:1:2d0:b7ff:fea0:8c26]) by mx1.freebsd.org (Postfix) with ESMTP id E915DE94; Wed, 15 May 2013 13:42:17 +0000 (UTC) Received: from spaceball.andric.com (spaceball.andric.com [IPv6:2001:7b8:3a7:0:204:4bff:fe01:de8a]) (using TLSv1 with cipher DHE-RSA-CAMELLIA256-SHA (256/256 bits)) (No client certificate requested) by tensor.andric.com (Postfix) with ESMTPSA id E69835C44; Wed, 15 May 2013 15:42:13 +0200 (CEST) Message-ID: <519390B6.2060500@FreeBSD.org> Date: Wed, 15 May 2013 15:42:14 +0200 From: Dimitry Andric Organization: The FreeBSD Project User-Agent: Mozilla/5.0 (Windows NT 6.1; WOW64; rv:21.0) Gecko/20100101 Thunderbird/21.0 MIME-Version: 1.0 To: Brooks Davis , src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: Re: svn commit: r250658 - in head: share/mk sys/conf tools/build/options References: <201305151304.r4FD4B1i032146@svn.freebsd.org> In-Reply-To: <201305151304.r4FD4B1i032146@svn.freebsd.org> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 15 May 2013 13:42:18 -0000 On 2013-05-15 15:04, Brooks Davis wrote: > Author: brooks > Date: Wed May 15 13:04:10 2013 > New Revision: 250658 > URL: http://svnweb.freebsd.org/changeset/base/250658 > > Log: > Add a new option WITHOUT_FORMAT_EXTENSIONS to disable flags related to > checking our kernel printf extensions. This is useful to allow > compilers without these extensions to build kernels. As I have written before, please let us consider this to be a band-aid, and aim to remove non-standard printf specifiers from our kernel sources. Otherwise we will lose most of the advantages of format checking... :-( > --- head/share/mk/bsd.own.mk Wed May 15 08:38:49 2013 (r250657) > +++ head/share/mk/bsd.own.mk Wed May 15 13:04:10 2013 (r250658) > @@ -268,6 +268,7 @@ __DEFAULT_YES_OPTIONS = \ > ED_CRYPTO \ > EXAMPLES \ > FLOPPY \ > + FORMAT_EXTENSIONS \ Spelled as 'extensions' here... > Modified: head/sys/conf/kern.mk > ============================================================================== > --- head/sys/conf/kern.mk Wed May 15 08:38:49 2013 (r250657) > +++ head/sys/conf/kern.mk Wed May 15 13:04:10 2013 (r250658) > @@ -5,7 +5,7 @@ > # > CWARNFLAGS?= -Wall -Wredundant-decls -Wnested-externs -Wstrict-prototypes \ > -Wmissing-prototypes -Wpointer-arith -Winline -Wcast-qual \ > - -Wundef -Wno-pointer-sign -fformat-extensions \ > + -Wundef -Wno-pointer-sign ${FORMAT_EXTENTIONS} \ ...but as 'extentions' here... > +# External compilers may not support our format extensions. Allow them > +# to be disabled. WARNING: format checking is disabled in this case. > +.if ${MK_FORMAT_EXTENSIONS} == "no" > +NO_WFORMAT= -Wno-format > +.else > +FORMAT_EXTENTIONS= -fformat-extensions and here. -Dimitry From owner-svn-src-all@FreeBSD.ORG Wed May 15 14:30:04 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id 3506C34A; Wed, 15 May 2013 14:30:04 +0000 (UTC) (envelope-from brooks@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id 1701F219; Wed, 15 May 2013 14:30:04 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.6/8.14.6) with ESMTP id r4FEU3aN061483; Wed, 15 May 2013 14:30:03 GMT (envelope-from brooks@svn.freebsd.org) Received: (from brooks@localhost) by svn.freebsd.org (8.14.6/8.14.5/Submit) id r4FEU31J061480; Wed, 15 May 2013 14:30:03 GMT (envelope-from brooks@svn.freebsd.org) Message-Id: <201305151430.r4FEU31J061480@svn.freebsd.org> From: Brooks Davis Date: Wed, 15 May 2013 14:30:03 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r250659 - in head: . share/mk tools/build/options tools/tools/makeroot X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 15 May 2013 14:30:04 -0000 Author: brooks Date: Wed May 15 14:30:03 2013 New Revision: 250659 URL: http://svnweb.freebsd.org/changeset/base/250659 Log: Add support for an external cross compiler. The cross compiler is specified by passing the XCC, XCXX, and XCPP variables (corresponding to CC, CXX, and CPP) to buildworld/buildkernel. The compiler must be clang or be configured to target the appropriate architecture. To speed build times, if XCC is an absolute path or WITHOUT_CROSS_COMPILER is defined then no cross compiler will be built during the cross-tools stage. Limited documentation of this feature can currently be found at: https://wiki.freebsd.org/ExternalToolchain This functionality should be considered experimental and is subject to change without notice. Sponsored by: DARPA, AFRL Discussed with: imp, sjg Added: head/tools/build/options/WITHOUT_CROSS_COMPILER (contents, props changed) head/tools/tools/makeroot/ Modified: head/Makefile.inc1 head/share/mk/bsd.own.mk Modified: head/Makefile.inc1 ============================================================================== --- head/Makefile.inc1 Wed May 15 13:04:10 2013 (r250658) +++ head/Makefile.inc1 Wed May 15 14:30:03 2013 (r250659) @@ -273,15 +273,67 @@ WMAKEENV= ${CROSSENV} \ .if ${MK_CDDL} == "no" WMAKEENV+= NO_CTF=1 .endif -.if ${CC:T:Mgcc} == "gcc" + +.if defined(CROSS_TOOLCHAIN_PREFIX) +CROSS_COMPILER_PREFIX?=${CROSS_TOOLCHAIN_PREFIX} +CROSS_BINUTILS_PREFIX?=${CROSS_TOOLCHAIN_PREFIX} +.endif +XCOMPILERS= CC CXX CPP +.for COMPILER in ${XCOMPILERS} +.if defined(CROSS_COMPILER_PREFIX) +X${COMPILER}?= ${CROSS_COMPILER_PREFIX}${${COMPILER}} +.else +X${COMPILER}?= ${${COMPILER}} +.endif +.endfor +XBINUTILS= AS AR LD NM OBJDUMP RANLIB STRINGS +.for BINUTIL in ${XBINUTILS} +.if defined(CROSS_BINUTILS_PREFIX) +X${BINUTIL}?= ${CROSS_BINUTILS_PREFIX}${${BINUTIL}} +.else +X${BINUTIL}?= ${${BINUTIL}} +.endif +.endfor +WMAKEENV+= CC="${XCC} ${XFLAGS}" CXX="${XCXX} ${XFLAGS}" \ + CPP="${XCPP} ${XFLAGS}" \ + AS="${XAS}" AR="${XAR}" LD="${XLD}" NM=${XNM} \ + OBJDUMP=${XOBJDUMP} RANLIB=${XRANLIB} STRINGS=${XSTRINGS} + +.if ${XCC:T:Mgcc} == "gcc" WMAKE_COMPILER_TYPE= gcc -.elif ${CC:T:Mclang} == "clang" +.elif ${XCC:T:Mclang} == "clang" WMAKE_COMPILER_TYPE= clang .elif ${MK_CLANG_IS_CC} == "no" WMAKE_COMPILER_TYPE= gcc .else WMAKE_COMPILER_TYPE= clang .endif +IMAKE_COMPILER_TYPE= COMPILER_TYPE=${WMAKE_COMPILER_TYPE} + +.if ${XCC:M/*} +XFLAGS= --sysroot=${WORLDTMP} +.if defined(CROSS_BINUTILS_PREFIX) +# In the case of xdev-build tools, CROSS_BINUTILS_PREFIX won't be a +# directory, but the compiler will look in the right place for it's +# tools so we don't need to tell it where to look. +.if exists(${CROSS_BINUTILS_PREFIX}) +XFLAGS+= -B${CROSS_BINUTILS_PREFIX} +.endif +.else +XFLAGS+= -B${WORLDTMP}/usr/bin +.endif +.if ${TARGET_ARCH} != ${MACHINE_ARCH} && ${WMAKE_COMPILER_TYPE} == "clang" +.if (${TARGET_ARCH} == "arm" || ${TARGET_ARCH} == "armv6") && \ +${MK_ARM_EABI} != "no" +TARGET_ABI= gnueabi +.else +TARGET_ABI= unknown +.endif +TARGET_TRIPLE?= ${TARGET_ARCH:C/amd64/x86_64/}-${TARGET_ABI}-freebsd10.0 +XFLAGS+= -target ${TARGET_TRIPLE} +.endif +.endif + WMAKEENV+= COMPILER_TYPE=${WMAKE_COMPILER_TYPE} WMAKE= ${WMAKEENV} ${MAKE} ${WORLD_FLAGS} -f Makefile.inc1 DESTDIR=${WORLDTMP} @@ -314,6 +366,7 @@ LIB32WMAKEFLAGS= \ LIB32FLAGS= -m32 ${LIB32CPUFLAGS} -DCOMPAT_32BIT \ + --sysroot=${WORLDTMP} \ -isystem ${LIB32TMP}/usr/include/ \ -L${LIB32TMP}/usr/lib32 \ -B${LIB32TMP}/usr/lib32 @@ -329,8 +382,8 @@ LIB32WMAKEENV+= MAKEOBJDIRPREFIX=${OBJTR SHLIBDIR=/usr/lib32 \ COMPILER_TYPE=${WMAKE_COMPILER_TYPE} LIB32WMAKEFLAGS+= \ - CC="${CC} ${LIB32FLAGS}" \ - CXX="${CXX} ${LIB32FLAGS}" \ + CC="${XCC} ${LIB32FLAGS}" \ + CXX="${XCXX} ${LIB32FLAGS}" \ DESTDIR=${LIB32TMP} \ -DCOMPAT_32BIT \ -DLIBRARIES_ONLY \ @@ -346,7 +399,7 @@ LIB32IMAKE= ${LIB32WMAKE:NINSTALL=*:NDES IMAKEENV= ${CROSSENV:N_LDSCRIPTROOT=*} IMAKE= ${IMAKEENV} ${MAKE} -f Makefile.inc1 \ - ${IMAKE_INSTALL} ${IMAKE_MTREE} + ${IMAKE_INSTALL} ${IMAKE_MTREE} ${IMAKE_COMPILER_TYPE} .if empty(.MAKEFLAGS:M-n) IMAKEENV+= PATH=${STRICTTMPPATH}:${INSTALLTMP} \ LD_LIBRARY_PATH=${INSTALLTMP} \ @@ -1279,10 +1332,13 @@ _kgzip= usr.sbin/kgzip .endif .endif -.if ${MK_BINUTILS} != "no" +.if ${XAS:M/*} == "" && ${MK_BINUTILS} != "no" _binutils= gnu/usr.bin/binutils .endif +# If an full path to an external cross compiler is given, don't build +# a cross compiler. +.if ${XCC:M/*} == "" && ${MK_CROSS_COMPILER} != "no" .if ${MK_CLANG} != "no" && (${MK_CLANG_IS_CC} != "no" || ${CC:T:Mclang} == "clang") _clang= usr.bin/clang _clang_libs= lib/clang @@ -1291,6 +1347,7 @@ _clang_libs= lib/clang .if ${MK_GCC} != "no" && (${MK_CLANG_IS_CC} == "no" || ${TARGET} == "pc98") _cc= gnu/usr.bin/cc .endif +.endif cross-tools: .for _tool in \ Modified: head/share/mk/bsd.own.mk ============================================================================== --- head/share/mk/bsd.own.mk Wed May 15 13:04:10 2013 (r250658) +++ head/share/mk/bsd.own.mk Wed May 15 14:30:03 2013 (r250659) @@ -259,6 +259,7 @@ __DEFAULT_YES_OPTIONS = \ CAPSICUM \ CDDL \ CPP \ + CROSS_COMPILER \ CRYPT \ CTM \ CVS \ Added: head/tools/build/options/WITHOUT_CROSS_COMPILER ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ head/tools/build/options/WITHOUT_CROSS_COMPILER Wed May 15 14:30:03 2013 (r250659) @@ -0,0 +1,3 @@ +.\" $FreeBSD$ +Set to not build a cross compiler in the cross-tools stage of +buildworld, buildkernel, etc. From owner-svn-src-all@FreeBSD.ORG Wed May 15 14:35:02 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id D5DE25FB; Wed, 15 May 2013 14:35:02 +0000 (UTC) (envelope-from brooks@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id C7536261; Wed, 15 May 2013 14:35:02 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.6/8.14.6) with ESMTP id r4FEZ2Pc063974; Wed, 15 May 2013 14:35:02 GMT (envelope-from brooks@svn.freebsd.org) Received: (from brooks@localhost) by svn.freebsd.org (8.14.6/8.14.5/Submit) id r4FEZ2JB063973; Wed, 15 May 2013 14:35:02 GMT (envelope-from brooks@svn.freebsd.org) Message-Id: <201305151435.r4FEZ2JB063973@svn.freebsd.org> From: Brooks Davis Date: Wed, 15 May 2013 14:35:02 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r250660 - head/share/man/man5 X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 15 May 2013 14:35:02 -0000 Author: brooks Date: Wed May 15 14:35:02 2013 New Revision: 250660 URL: http://svnweb.freebsd.org/changeset/base/250660 Log: Document WITHOUT_CROSS_COMPILER and WITHOUT_FORMAT_EXTENSIONS. Modified: head/share/man/man5/src.conf.5 Modified: head/share/man/man5/src.conf.5 ============================================================================== --- head/share/man/man5/src.conf.5 Wed May 15 14:30:03 2013 (r250659) +++ head/share/man/man5/src.conf.5 Wed May 15 14:35:02 2013 (r250660) @@ -343,6 +343,10 @@ amd64/amd64, i386/i386 and pc98/i386. .\" from FreeBSD: head/tools/build/options/WITHOUT_CPP 156932 2006-03-21 07:50:50Z ru Set to not build .Xr cpp 1 . +.It Va WITHOUT_CROSS_COMPILER +.\" from FreeBSD: head/tools/build/options/WITHOUT_CROSS_COMPILER 250659 2013-05-15 14:30:03Z brooks +Set to not build a cross compiler in the cross-tools stage of +buildworld, buildkernel, etc. .It Va WITHOUT_CRYPT .\" from FreeBSD: head/tools/build/options/WITHOUT_CRYPT 156932 2006-03-21 07:50:50Z ru Set to not build any crypto code. @@ -433,6 +437,12 @@ amd64/amd64, i386/i386, ia64/ia64, pc98/ .\" from FreeBSD: head/tools/build/options/WITHOUT_FLOPPY 221540 2011-05-06 19:13:03Z ru Set to not build or install programs for operating floppy disk driver. +.It Va WITHOUT_FORMAT_EXTENSIONS +.\" from FreeBSD: head/tools/build/options/WITHOUT_FORMAT_EXTENSIONS 250658 2013-05-15 13:04:10Z brooks +Set to not enable +.Fl fformat-extensions +when compiling the kernel. +Also disables all format checking. .It Va WITHOUT_FORTH .\" from FreeBSD: head/tools/build/options/WITHOUT_FORTH 156932 2006-03-21 07:50:50Z ru Set to build bootloaders without Forth support. From owner-svn-src-all@FreeBSD.ORG Wed May 15 15:03:16 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id 54904BC1; Wed, 15 May 2013 15:03:16 +0000 (UTC) (envelope-from yaneurabeya@gmail.com) Received: from mail-qa0-x22d.google.com (mail-qa0-x22d.google.com [IPv6:2607:f8b0:400d:c00::22d]) by mx1.freebsd.org (Postfix) with ESMTP id D935B401; Wed, 15 May 2013 15:03:15 +0000 (UTC) Received: by mail-qa0-f45.google.com with SMTP id ii15so1028332qab.11 for ; Wed, 15 May 2013 08:03:14 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=x-received:subject:mime-version:content-type:from:in-reply-to:date :cc:content-transfer-encoding:message-id:references:to:x-mailer; bh=0ByhdnP8OBqpWxYPwzYFiLWWL4mnCfK+mDYJHGydCUk=; b=Fzi+VkUt2/VFxABWvH84nYSVEb6XWO6/Bf9UQElwu+45jrz9Zhsegslc4ssVlnKJJp lVDIMN6xpHulimpg0QwtEs0Ic6UMN6nlF/eRKQGAtjMDX4YT13ArhFhvGILCKuhY+6sV BOEBEdReCyyoIavuQNmJ0JSurdAEeukzDLbM9yN/5UmE1W4Ex3MixadHnFZQfWnuEkPh WZIqizd6bzUTMeuZOJkzU/ZgBkHMvB18Ax8lgdJ21YkHg/SpnyfC6hxxi9gkelZqiDUf UoCnzGbDCVd0RKZliEysnBRSBv1Co3kchBVshcYtGK/2BjujAE6KI63J8CoVeWolKA0d zKYA== X-Received: by 10.224.178.72 with SMTP id bl8mr28271882qab.14.1368630194896; Wed, 15 May 2013 08:03:14 -0700 (PDT) Received: from [10.137.210.143] ([137.122.64.60]) by mx.google.com with ESMTPSA id w7sm2832396qej.7.2013.05.15.08.03.13 for (version=TLSv1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Wed, 15 May 2013 08:03:14 -0700 (PDT) Subject: Re: svn commit: r250511 - in head: usr.bin/gcore usr.sbin/bsdinstall/distextract usr.sbin/bsdinstall/distfetch usr.sbin/bsdinstall/partedit Mime-Version: 1.0 (Apple Message framework v1283) Content-Type: text/plain; charset=us-ascii From: Garrett Cooper In-Reply-To: <201305111346.r4BDk6ff005271@svn.freebsd.org> Date: Wed, 15 May 2013 10:03:13 -0500 Content-Transfer-Encoding: 7bit Message-Id: <1497C99B-35A8-4EEB-9000-8A5A3403BF35@gmail.com> References: <201305111346.r4BDk6ff005271@svn.freebsd.org> To: Antoine Brodin X-Mailer: Apple Mail (2.1283) Cc: svn-src-head@freebsd.org, svn-src-all@freebsd.org, src-committers@freebsd.org X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 15 May 2013 15:03:16 -0000 On May 11, 2013, at 8:46 AM, Antoine Brodin wrote: > Author: antoine > Date: Sat May 11 13:46:05 2013 > New Revision: 250511 > URL: http://svnweb.freebsd.org/changeset/base/250511 > > Log: > Add some missing DPADD. Looks like you fixed bin/174046 . Could you please handle the PR? Thanks! -Garrett From owner-svn-src-all@FreeBSD.ORG Wed May 15 15:10:20 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id 418B3E6D; Wed, 15 May 2013 15:10:20 +0000 (UTC) (envelope-from yaneurabeya@gmail.com) Received: from mail-ee0-f53.google.com (mail-ee0-f53.google.com [74.125.83.53]) by mx1.freebsd.org (Postfix) with ESMTP id 50460637; Wed, 15 May 2013 15:10:19 +0000 (UTC) Received: by mail-ee0-f53.google.com with SMTP id c1so833081eek.40 for ; Wed, 15 May 2013 08:10:18 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=x-received:subject:mime-version:content-type:from:in-reply-to:date :cc:content-transfer-encoding:message-id:references:to:x-mailer; bh=Ec8UZ18tIP7+73YGEBQhQJT5vOCM8kg4vIQuFheLdNs=; b=pZOusiE7fX6VqKAYiqbRuMDrFsm0pXyKqqtEQWF2DRoLE6/4QRCLutFuPe5aZjKM6k RwVOdeWYr54qjrM5N18fY3yvzI5ifuoakY6BWksTYYjG1A3IJzpKCq2KotNmEkKe4L+X 9zynAVDzKhWoxzT9jj04E7X9q+42cPIjxmFcJBhcJu9Kbf2tp0WTuLGnLm//mi0+WNIS kTfPbg5/fsh7hE1eF/3kLvVsuv7xhphhxUIJHgii6hDAxj2J/xshmVidE1RAUaf6CaNZ 3DBiOVPyxkMuiUKUxNwHwieEiJSItGQqcYuDn/x28ZsIXUELLjaqGxdmixjfRyHrrKAp GPFQ== X-Received: by 10.15.94.131 with SMTP id bb3mr53156853eeb.20.1368630618231; Wed, 15 May 2013 08:10:18 -0700 (PDT) Received: from [10.137.210.143] ([137.122.64.60]) by mx.google.com with ESMTPSA id bn53sm4551155eeb.7.2013.05.15.08.10.15 for (version=TLSv1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Wed, 15 May 2013 08:10:16 -0700 (PDT) Subject: Re: svn commit: r250659 - in head: . share/mk tools/build/options tools/tools/makeroot Mime-Version: 1.0 (Apple Message framework v1283) Content-Type: text/plain; charset=us-ascii From: Garrett Cooper In-Reply-To: <201305151430.r4FEU31J061480@svn.freebsd.org> Date: Wed, 15 May 2013 10:10:13 -0500 Content-Transfer-Encoding: quoted-printable Message-Id: References: <201305151430.r4FEU31J061480@svn.freebsd.org> To: Brooks Davis X-Mailer: Apple Mail (2.1283) Cc: svn-src-head@freebsd.org, svn-src-all@freebsd.org, src-committers@freebsd.org X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 15 May 2013 15:10:20 -0000 On May 15, 2013, at 9:30 AM, Brooks Davis wrote: > Author: brooks > Date: Wed May 15 14:30:03 2013 > New Revision: 250659 > URL: http://svnweb.freebsd.org/changeset/base/250659 >=20 > Log: > Add support for an external cross compiler. The cross compiler is > specified by passing the XCC, XCXX, and XCPP variables (corresponding = to > CC, CXX, and CPP) to buildworld/buildkernel. The compiler must be = clang > or be configured to target the appropriate architecture. >=20 > To speed build times, if XCC is an absolute path or > WITHOUT_CROSS_COMPILER is defined then no cross compiler will be = built > during the cross-tools stage. >=20 > Limited documentation of this feature can currently be found at: >=20 > https://wiki.freebsd.org/ExternalToolchain >=20 > This functionality should be considered experimental and is subject = to > change without notice. Seems like this code could/should be integrated in with = conf/163778 (in particular the bits that Warner provided to = share/mk/sys.mk that I integrated in my larger patch). Thanks! -Garrett= From owner-svn-src-all@FreeBSD.ORG Wed May 15 17:03:11 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id E62D4C83; Wed, 15 May 2013 17:03:11 +0000 (UTC) (envelope-from davidcs@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id D65E0D33; Wed, 15 May 2013 17:03:11 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.6/8.14.6) with ESMTP id r4FH3BT1015644; Wed, 15 May 2013 17:03:11 GMT (envelope-from davidcs@svn.freebsd.org) Received: (from davidcs@localhost) by svn.freebsd.org (8.14.6/8.14.5/Submit) id r4FH3AWx015630; Wed, 15 May 2013 17:03:10 GMT (envelope-from davidcs@svn.freebsd.org) Message-Id: <201305151703.r4FH3AWx015630@svn.freebsd.org> From: David C Somayajulu Date: Wed, 15 May 2013 17:03:10 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r250661 - in head: share/man/man4 sys/conf sys/dev/qlxgbe sys/modules sys/modules/qlxgbe X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 15 May 2013 17:03:12 -0000 Author: davidcs Date: Wed May 15 17:03:09 2013 New Revision: 250661 URL: http://svnweb.freebsd.org/changeset/base/250661 Log: Add Qlogic 10Gigabit Ethernet & CNA Adapter Driver Version 3.10.10 for QLogic 8300 Series Adapters Submitted by: David C Somayajulu (davidcs@freebsd.org) QLogic Corporation Approved by: George Neville-Neil (gnn@freebsd.org) Added: head/share/man/man4/qlxgbe.4 (contents, props changed) head/sys/dev/qlxgbe/ head/sys/dev/qlxgbe/README.txt (contents, props changed) head/sys/dev/qlxgbe/ql_dbg.c (contents, props changed) head/sys/dev/qlxgbe/ql_dbg.h (contents, props changed) head/sys/dev/qlxgbe/ql_def.h (contents, props changed) head/sys/dev/qlxgbe/ql_glbl.h (contents, props changed) head/sys/dev/qlxgbe/ql_hw.c (contents, props changed) head/sys/dev/qlxgbe/ql_hw.h (contents, props changed) head/sys/dev/qlxgbe/ql_inline.h (contents, props changed) head/sys/dev/qlxgbe/ql_ioctl.c (contents, props changed) head/sys/dev/qlxgbe/ql_ioctl.h (contents, props changed) head/sys/dev/qlxgbe/ql_isr.c (contents, props changed) head/sys/dev/qlxgbe/ql_misc.c (contents, props changed) head/sys/dev/qlxgbe/ql_os.c (contents, props changed) head/sys/dev/qlxgbe/ql_os.h (contents, props changed) head/sys/dev/qlxgbe/ql_reset.c (contents, props changed) head/sys/dev/qlxgbe/ql_tmplt.h (contents, props changed) head/sys/dev/qlxgbe/ql_ver.h (contents, props changed) head/sys/modules/qlxgbe/ head/sys/modules/qlxgbe/Makefile (contents, props changed) Modified: head/share/man/man4/Makefile head/sys/conf/files.amd64 head/sys/modules/Makefile Modified: head/share/man/man4/Makefile ============================================================================== --- head/share/man/man4/Makefile Wed May 15 14:35:02 2013 (r250660) +++ head/share/man/man4/Makefile Wed May 15 17:03:09 2013 (r250661) @@ -371,6 +371,7 @@ MAN= aac.4 \ pty.4 \ puc.4 \ ${_qlxgb.4} \ + ${_qlxgbe.4} \ ral.4 \ random.4 \ rc.4 \ @@ -791,9 +792,11 @@ _if_ntb.4= if_ntb.4 _ntb.4= ntb.4 _ntb_hw.4= ntb_hw.4 _qlxgb.4= qlxgb.4 +_qlxgbe.4= qlxgbe.4 _sfxge.4= sfxge.4 MLINKS+=qlxgb.4 if_qlxgb.4 +MLINKS+=qlxgbe.4 if_qlxgbe.4 MLINKS+=sfxge.4 if_sfxge.4 .endif Added: head/share/man/man4/qlxgbe.4 ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ head/share/man/man4/qlxgbe.4 Wed May 15 17:03:09 2013 (r250661) @@ -0,0 +1,91 @@ +.\"- +.\" Copyright (c) 2013 Qlogic Corportaion +.\" 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. +.\" +.\" $FreeBSD$ +.\" +.Dd April 1, 2013 +.Dt QLXGBE 4 +.Os +.Sh NAME +.Nm qlxgbe +.Nd "QLogic 10 Gigabit Ethernet & CNA Adapter Driver" +.Sh SYNOPSIS +To compile this driver into the kernel, +place the following lines in your +kernel configuration file: +.Bd -ragged -offset indent +.Cd "device qlxgbe" +.Ed +.Pp +To load the driver as a +module at boot time, place the following line in +.Xr loader.conf 5 : +.Bd -literal -offset indent +if_qlxgbe_load="YES" +.Ed +.Sh DESCRIPTION +The +.Nm +driver supports IPv4 checksum offload, +TCP and UDP checksum offload for both IPv4 and IPv6, +Large Segment Offload for both IPv4 and IPv6, +Jumbo frames, VLAN Tag, and +Receive Side scaling. +For further hardware information, see +.Pa http://www.qlogic.com/ . +.Sh HARDWARE +The +.Nm +driver supports 10 Gigabit Ethernet & CNA Adapter based on the following +chipsets: +.Pp +.Bl -bullet -compact +.It +QLogic 8300 series +.El +.Sh SUPPORT +For support questions please contact your QLogic approved reseller or +QLogic Technical Support at +.Pa http://support.qlogic.com , +or by E-mail at +.Aq support@qlogic.com . +.Sh SEE ALSO +.Xr altq 4 , +.Xr arp 4 , +.Xr netintro 4 , +.Xr ng_ether 4 , +.Xr ifconfig 8 +.Sh HISTORY +The +.Nm +device driver first appeared in +.Fx 10.0 . +.Sh AUTHORS +.An -nosplit +The +.Nm +driver was written by +.An David C Somayajulu +at QLogic Corporation. Modified: head/sys/conf/files.amd64 ============================================================================== --- head/sys/conf/files.amd64 Wed May 15 14:35:02 2013 (r250660) +++ head/sys/conf/files.amd64 Wed May 15 17:03:09 2013 (r250661) @@ -232,6 +232,13 @@ dev/qlxgb/qla_ioctl.c optional qlxgb pc dev/qlxgb/qla_isr.c optional qlxgb pci dev/qlxgb/qla_misc.c optional qlxgb pci dev/qlxgb/qla_os.c optional qlxgb pci +dev/qlxgbe/ql_dbg.c optional qlxgbe pci +dev/qlxgbe/ql_hw.c optional qlxgbe pci +dev/qlxgbe/ql_ioctl.c optional qlxgbe pci +dev/qlxgbe/ql_isr.c optional qlxgbe pci +dev/qlxgbe/ql_misc.c optional qlxgbe pci +dev/qlxgbe/ql_os.c optional qlxgbe pci +dev/qlxgbe/ql_reset.c optional qlxgbe pci dev/sfxge/common/efx_bootcfg.c optional sfxge inet pci dev/sfxge/common/efx_ev.c optional sfxge inet pci dev/sfxge/common/efx_filter.c optional sfxge inet pci Added: head/sys/dev/qlxgbe/README.txt ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ head/sys/dev/qlxgbe/README.txt Wed May 15 17:03:09 2013 (r250661) @@ -0,0 +1,102 @@ +# $FreeBSD$ + + README File + QLogic 8300 series Dual Port +10 Gigabit Ethernet & CNA Adapter Driver for FreeBSD 9.x/10.x + + QLogic Corporation. + All rights reserved. + + +Table of Contents +1. Package Contents +2. OS Support +3. Supported Features +4. Using the Driver + 4.1 Installing the driver + 4.2 Removing the driver +5. Driver Parameters +6. Additional Notes +7. Contacting Support + +1. Package Contents + * Documentation + - README (this document) version:1.0 + - Release Notes Version:1.0 + * Driver (if_qlxgbe.ko) + - FreeBSD 9.x/10.x + * Firmware: pre-flashed on QLogic adapter; + +2. OS Support + +The Qlogic 83xx 10Gigabit Ethernet/CNA driver is compatible with the +following OS platforms: + * FreeBSD 9.x/10.x (64-bit) [Intel EM64T, AMD64] + +3. Supported Features +10Gigabit Ethernet NIC/CNA driver supports following features + +* Large Segment Offload over TCP IPV4 +* Large Segment Offload over TCP IPV6 +* Receive Side scaling +* TCP over IPv4 checksum offload +* UDP over IPv4 checksum offload +* IPV4 checksum offload +* TCP over IPv6 checksum offload +* UDP over IPv6 checksum offload +* Jumbo frames +* VLAN Tag + + +4. Using the driver + + 4.1 Installing the driver + + - copy the driver file (if_qlxgbe.ko) into some directory (say qla_driver) + - cd + - kldload -v ./if_qlxgbe.ko + + 4.2 Removing the driver + + - kldunload if_qlxgbe + +5. Parameters to set prior to installing the driver + + - Add the following lines to /etc/sysctl.conf and reboot the machine prior + to installing the driver + + kern.ipc.nmbjumbo9=262144 + net.inet.tcp.recvbuf_max=262144 + net.inet.tcp.recvbuf_inc=16384 + kern.ipc.nmbclusters=1000000 + kern.ipc.maxsockbuf=2097152 + net.inet.tcp.recvspace=131072 + net.inet.tcp.sendbuf_max=262144 + net.inet.tcp.sendspace=65536 + + - If you do not want to reboot the system please run the following commands + + login or su to root + + sysctl kern.ipc.nmbjumbo9=262144 + sysctl net.inet.tcp.recvbuf_max=262144 + sysctl net.inet.tcp.recvbuf_inc=16384 + sysctl kern.ipc.nmbclusters=1000000 + sysctl kern.ipc.maxsockbuf=2097152 + sysctl net.inet.tcp.recvspace=131072 + sysctl net.inet.tcp.sendbuf_max=262144 + sysctl net.inet.tcp.sendspace=65536 + +6. Compile options Makefile if building driver from sources + None + +7. Contacting Support +Please feel free to contact your QLogic approved reseller or QLogic +Technical Support at any phase of integration for assistance. QLogic +Technical Support can be reached by the following methods: +Web: http://support.qlogic.com +E-mail: support@qlogic.com +(c) Copyright 2013-14. All rights reserved worldwide. QLogic, the QLogic +logo, and the Powered by QLogic logo are registered trademarks of +QLogic Corporation. All other brand and product names are trademarks +or registered trademarks of their respective owners. Added: head/sys/dev/qlxgbe/ql_dbg.c ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ head/sys/dev/qlxgbe/ql_dbg.c Wed May 15 17:03:09 2013 (r250661) @@ -0,0 +1,260 @@ +/* + * Copyright (c) 2013-2014 Qlogic Corporation + * 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 COPYRIGHT HOLDERS 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 COPYRIGHT OWNER 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. + */ +/* + * File : ql_dbg.c + * Author : David C Somayajulu, Qlogic Corporation, Aliso Viejo, CA 92656. + */ +#include +__FBSDID("$FreeBSD$"); + +#include "ql_os.h" +#include "ql_hw.h" +#include "ql_def.h" +#include "ql_inline.h" +#include "ql_ver.h" +#include "ql_glbl.h" +#include "ql_dbg.h" + +/* + * Name: ql_dump_buf32 + * Function: dumps a buffer as 32 bit words + */ +void ql_dump_buf32(qla_host_t *ha, const char *msg, void *dbuf32, uint32_t len32) +{ + device_t dev; + uint32_t i = 0; + uint32_t *buf; + + dev = ha->pci_dev; + buf = dbuf32; + + device_printf(dev, "%s: %s dump start\n", __func__, msg); + + while (len32 >= 4) { + device_printf(dev,"0x%08x: 0x%08x 0x%08x 0x%08x 0x%08x\n", + i, buf[0], buf[1], buf[2], buf[3]); + i += 4 * 4; + len32 -= 4; + buf += 4; + } + switch (len32) { + case 1: + device_printf(dev,"0x%08x: 0x%08x\n", i, buf[0]); + break; + case 2: + device_printf(dev,"0x%08x: 0x%08x 0x%08x\n", i, buf[0], buf[1]); + break; + case 3: + device_printf(dev,"0x%08x: 0x%08x 0x%08x 0x%08x\n", + i, buf[0], buf[1], buf[2]); + break; + default: + break; + } + device_printf(dev, "%s: %s dump end\n", __func__, msg); +} + +/* + * Name: ql_dump_buf16 + * Function: dumps a buffer as 16 bit words + */ +void ql_dump_buf16(qla_host_t *ha, const char *msg, void *dbuf16, uint32_t len16) +{ + device_t dev; + uint32_t i = 0; + uint16_t *buf; + + dev = ha->pci_dev; + buf = dbuf16; + + device_printf(dev, "%s: %s dump start\n", __func__, msg); + + while (len16 >= 8) { + device_printf(dev,"0x%08x: 0x%04x 0x%04x 0x%04x 0x%04x" + " 0x%04x 0x%04x 0x%04x 0x%04x\n", i, buf[0], + buf[1], buf[2], buf[3], buf[4], buf[5], buf[6], buf[7]); + i += 16; + len16 -= 8; + buf += 8; + } + switch (len16) { + case 1: + device_printf(dev,"0x%08x: 0x%04x\n", i, buf[0]); + break; + case 2: + device_printf(dev,"0x%08x: 0x%04x 0x%04x\n", i, buf[0], buf[1]); + break; + case 3: + device_printf(dev,"0x%08x: 0x%04x 0x%04x 0x%04x\n", + i, buf[0], buf[1], buf[2]); + break; + case 4: + device_printf(dev,"0x%08x: 0x%04x 0x%04x 0x%04x 0x%04x\n", i, + buf[0], buf[1], buf[2], buf[3]); + break; + case 5: + device_printf(dev,"0x%08x:" + " 0x%04x 0x%04x 0x%04x 0x%04x 0x%04x\n", i, + buf[0], buf[1], buf[2], buf[3], buf[4]); + break; + case 6: + device_printf(dev,"0x%08x:" + " 0x%04x 0x%04x 0x%04x 0x%04x 0x%04x 0x%04x\n", i, + buf[0], buf[1], buf[2], buf[3], buf[4], buf[5]); + break; + case 7: + device_printf(dev,"0x%04x: 0x%04x 0x%04x 0x%04x 0x%04x" + " 0x%04x 0x%04x 0x%04x\n", i, buf[0], buf[1], + buf[2], buf[3], buf[4], buf[5], buf[6]); + break; + default: + break; + } + device_printf(dev, "%s: %s dump end\n", __func__, msg); +} + +/* + * Name: ql_dump_buf8 + * Function: dumps a buffer as bytes + */ +void ql_dump_buf8(qla_host_t *ha, const char *msg, void *dbuf, uint32_t len) +{ + device_t dev; + uint32_t i = 0; + uint8_t *buf; + + dev = ha->pci_dev; + buf = dbuf; + + device_printf(dev, "%s: %s 0x%x dump start\n", __func__, msg, len); + + while (len >= 16) { + device_printf(dev,"0x%08x:" + " %02x %02x %02x %02x %02x %02x %02x %02x" + " %02x %02x %02x %02x %02x %02x %02x %02x\n", i, + buf[0], buf[1], buf[2], buf[3], + buf[4], buf[5], buf[6], buf[7], + buf[8], buf[9], buf[10], buf[11], + buf[12], buf[13], buf[14], buf[15]); + i += 16; + len -= 16; + buf += 16; + } + switch (len) { + case 1: + device_printf(dev,"0x%08x: %02x\n", i, buf[0]); + break; + case 2: + device_printf(dev,"0x%08x: %02x %02x\n", i, buf[0], buf[1]); + break; + case 3: + device_printf(dev,"0x%08x: %02x %02x %02x\n", + i, buf[0], buf[1], buf[2]); + break; + case 4: + device_printf(dev,"0x%08x: %02x %02x %02x %02x\n", i, + buf[0], buf[1], buf[2], buf[3]); + break; + case 5: + device_printf(dev,"0x%08x:" + " %02x %02x %02x %02x %02x\n", i, + buf[0], buf[1], buf[2], buf[3], buf[4]); + break; + case 6: + device_printf(dev,"0x%08x:" + " %02x %02x %02x %02x %02x %02x\n", i, + buf[0], buf[1], buf[2], buf[3], buf[4], buf[5]); + break; + case 7: + device_printf(dev,"0x%08x:" + " %02x %02x %02x %02x %02x %02x %02x\n", i, + buf[0], buf[1], buf[2], buf[3], buf[4], buf[5], buf[6]); + break; + case 8: + device_printf(dev,"0x%08x:" + " %02x %02x %02x %02x %02x %02x %02x %02x\n", i, + buf[0], buf[1], buf[2], buf[3], buf[4], buf[5], buf[6], + buf[7]); + break; + case 9: + device_printf(dev,"0x%08x:" + " %02x %02x %02x %02x %02x %02x %02x %02x" + " %02x\n", i, + buf[0], buf[1], buf[2], buf[3], buf[4], buf[5], buf[6], + buf[7], buf[8]); + break; + case 10: + device_printf(dev,"0x%08x:" + " %02x %02x %02x %02x %02x %02x %02x %02x" + " %02x %02x\n", i, + buf[0], buf[1], buf[2], buf[3], buf[4], buf[5], buf[6], + buf[7], buf[8], buf[9]); + break; + case 11: + device_printf(dev,"0x%08x:" + " %02x %02x %02x %02x %02x %02x %02x %02x" + " %02x %02x %02x\n", i, + buf[0], buf[1], buf[2], buf[3], buf[4], buf[5], buf[6], + buf[7], buf[8], buf[9], buf[10]); + break; + case 12: + device_printf(dev,"0x%08x:" + " %02x %02x %02x %02x %02x %02x %02x %02x" + " %02x %02x %02x %02x\n", i, + buf[0], buf[1], buf[2], buf[3], buf[4], buf[5], buf[6], + buf[7], buf[8], buf[9], buf[10], buf[11]); + break; + case 13: + device_printf(dev,"0x%08x:" + " %02x %02x %02x %02x %02x %02x %02x %02x" + " %02x %02x %02x %02x %02x\n", i, + buf[0], buf[1], buf[2], buf[3], buf[4], buf[5], buf[6], + buf[7], buf[8], buf[9], buf[10], buf[11], buf[12]); + break; + case 14: + device_printf(dev,"0x%08x:" + " %02x %02x %02x %02x %02x %02x %02x %02x" + " %02x %02x %02x %02x %02x %02x\n", i, + buf[0], buf[1], buf[2], buf[3], buf[4], buf[5], buf[6], + buf[7], buf[8], buf[9], buf[10], buf[11], buf[12], + buf[13]); + break; + case 15: + device_printf(dev,"0x%08x:" + " %02x %02x %02x %02x %02x %02x %02x %02x" + " %02x %02x %02x %02x %02x %02x %02x\n", i, + buf[0], buf[1], buf[2], buf[3], buf[4], buf[5], buf[6], + buf[7], buf[8], buf[9], buf[10], buf[11], buf[12], + buf[13], buf[14]); + break; + default: + break; + } + + device_printf(dev, "%s: %s dump end\n", __func__, msg); +} + Added: head/sys/dev/qlxgbe/ql_dbg.h ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ head/sys/dev/qlxgbe/ql_dbg.h Wed May 15 17:03:09 2013 (r250661) @@ -0,0 +1,98 @@ +/* + * Copyright (c) 2013-2014 Qlogic Corporation + * 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 COPYRIGHT HOLDERS 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 COPYRIGHT OWNER 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$ + */ + +/* + * File : ql_dbg.h + * Author : David C Somayajulu, Qlogic Corporation, Aliso Viejo, CA 92656. + */ + +#ifndef _QL_DBG_H_ +#define _QL_DBG_H_ + +extern void ql_dump_buf8(qla_host_t *ha, const char *str, void *dbuf, + uint32_t len); +extern void ql_dump_buf16(qla_host_t *ha, const char *str, void *dbuf, + uint32_t len16); +extern void ql_dump_buf32(qla_host_t *ha, const char *str, void *dbuf, + uint32_t len32); + +#define INJCT_RX_RXB_INVAL 0x00001 +#define INJCT_RX_MP_NULL 0x00002 +#define INJCT_LRO_RXB_INVAL 0x00003 +#define INJCT_LRO_MP_NULL 0x00004 +#define INJCT_NUM_HNDLE_INVALID 0x00005 +#define INJCT_RDWR_INDREG_FAILURE 0x00006 +#define INJCT_RDWR_OFFCHIPMEM_FAILURE 0x00007 +#define INJCT_MBX_CMD_FAILURE 0x00008 +#define INJCT_HEARTBEAT_FAILURE 0x00009 +#define INJCT_TEMPERATURE_FAILURE 0x0000A + +#ifdef QL_DBG + +#define QL_DPRINT1(ha, x) if (ha->dbg_level & 0x0001) device_printf x +#define QL_DPRINT2(ha, x) if (ha->dbg_level & 0x0002) device_printf x +#define QL_DPRINT4(ha, x) if (ha->dbg_level & 0x0004) device_printf x +#define QL_DPRINT8(ha, x) if (ha->dbg_level & 0x0008) device_printf x +#define QL_DPRINT10(ha, x) if (ha->dbg_level & 0x0010) device_printf x +#define QL_DPRINT20(ha, x) if (ha->dbg_level & 0x0020) device_printf x +#define QL_DPRINT40(ha, x) if (ha->dbg_level & 0x0040) device_printf x +#define QL_DPRINT80(ha, x) if (ha->dbg_level & 0x0080) device_printf x + +#define QL_DUMP_BUFFER8(h, s, b, n) if (h->dbg_level & 0x08000000)\ + qla_dump_buf8(h, s, b, n) +#define QL_DUMP_BUFFER16(h, s, b, n) if (h->dbg_level & 0x08000000)\ + qla_dump_buf16(h, s, b, n) +#define QL_DUMP_BUFFER32(h, s, b, n) if (h->dbg_level & 0x08000000)\ + qla_dump_buf32(h, s, b, n) + +#define QL_ASSERT(ha, x, y) if (!x && !ha->err_inject) panic y +#define QL_ERR_INJECT(ha, val) (ha->err_inject == val) + +#else + +#define QL_DPRINT1(ha, x) +#define QL_DPRINT2(ha, x) +#define QL_DPRINT4(ha, x) +#define QL_DPRINT8(ha, x) +#define QL_DPRINT10(ha, x) +#define QL_DPRINT20(ha, x) +#define QL_DPRINT40(ha, x) +#define QL_DPRINT80(ha, x) + +#define QL_DUMP_BUFFER8(h, s, b, n) +#define QL_DUMP_BUFFER16(h, s, b, n) +#define QL_DUMP_BUFFER32(h, s, b, n) + +#define QL_ASSERT(ha, x, y) +#define QL_ERR_INJECT(ha, val) 0 + +#endif + + +#endif /* #ifndef _QL_DBG_H_ */ Added: head/sys/dev/qlxgbe/ql_def.h ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ head/sys/dev/qlxgbe/ql_def.h Wed May 15 17:03:09 2013 (r250661) @@ -0,0 +1,258 @@ +/* + * Copyright (c) 2013-2014 Qlogic Corporation + * 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 COPYRIGHT HOLDERS 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 COPYRIGHT OWNER 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$ + */ + +/* + * File: ql_def.h + * Author : David C Somayajulu, Qlogic Corporation, Aliso Viejo, CA 92656. + */ + +#ifndef _QL_DEF_H_ +#define _QL_DEF_H_ + +#define BIT_0 (0x1 << 0) +#define BIT_1 (0x1 << 1) +#define BIT_2 (0x1 << 2) +#define BIT_3 (0x1 << 3) +#define BIT_4 (0x1 << 4) +#define BIT_5 (0x1 << 5) +#define BIT_6 (0x1 << 6) +#define BIT_7 (0x1 << 7) +#define BIT_8 (0x1 << 8) +#define BIT_9 (0x1 << 9) +#define BIT_10 (0x1 << 10) +#define BIT_11 (0x1 << 11) +#define BIT_12 (0x1 << 12) +#define BIT_13 (0x1 << 13) +#define BIT_14 (0x1 << 14) +#define BIT_15 (0x1 << 15) +#define BIT_16 (0x1 << 16) +#define BIT_17 (0x1 << 17) +#define BIT_18 (0x1 << 18) +#define BIT_19 (0x1 << 19) +#define BIT_20 (0x1 << 20) +#define BIT_21 (0x1 << 21) +#define BIT_22 (0x1 << 22) +#define BIT_23 (0x1 << 23) +#define BIT_24 (0x1 << 24) +#define BIT_25 (0x1 << 25) +#define BIT_26 (0x1 << 26) +#define BIT_27 (0x1 << 27) +#define BIT_28 (0x1 << 28) +#define BIT_29 (0x1 << 29) +#define BIT_30 (0x1 << 30) +#define BIT_31 (0x1 << 31) + +struct qla_rx_buf { + struct mbuf *m_head; + bus_dmamap_t map; + bus_addr_t paddr; + uint32_t handle; + void *next; +}; +typedef struct qla_rx_buf qla_rx_buf_t; + +struct qla_rx_ring { + qla_rx_buf_t rx_buf[NUM_RX_DESCRIPTORS]; +}; +typedef struct qla_rx_ring qla_rx_ring_t; + +struct qla_tx_buf { + struct mbuf *m_head; + bus_dmamap_t map; +}; +typedef struct qla_tx_buf qla_tx_buf_t; + +#define QLA_MAX_SEGMENTS 62 /* maximum # of segs in a sg list */ +#define QLA_MAX_MTU 9000 +#define QLA_STD_FRAME_SIZE 1514 +#define QLA_MAX_TSO_FRAME_SIZE ((64 * 1024 - 1) + 22) + +/* Number of MSIX/MSI Vectors required */ + +struct qla_ivec { + uint32_t sds_idx; + void *ha; + struct resource *irq; + void *handle; + int irq_rid; +}; + +typedef struct qla_ivec qla_ivec_t; + +#define QLA_WATCHDOG_CALLOUT_TICKS 1 + +typedef struct _qla_tx_ring { + qla_tx_buf_t tx_buf[NUM_TX_DESCRIPTORS]; + uint64_t count; +} qla_tx_ring_t; + +/* + * Adapter structure contains the hardware independant information of the + * pci function. + */ +struct qla_host { + volatile struct { + volatile uint32_t + qla_callout_init :1, + qla_watchdog_active :1, + qla_watchdog_exit :1, + qla_watchdog_pause :1, + lro_init :1, + stop_rcv :1, + parent_tag :1, + lock_init :1; + } flags; + + volatile uint32_t qla_watchdog_exited; + volatile uint32_t qla_watchdog_paused; + volatile uint32_t qla_initiate_recovery; + + device_t pci_dev; + + uint16_t watchdog_ticks; + uint8_t pci_func; + uint8_t resvd; + + /* ioctl related */ + struct cdev *ioctl_dev; + + /* register mapping */ + struct resource *pci_reg; + int reg_rid; + struct resource *pci_reg1; + int reg_rid1; + + /* interrupts */ + struct resource *mbx_irq; + void *mbx_handle; + int mbx_irq_rid; + + int msix_count; + + qla_ivec_t irq_vec[MAX_SDS_RINGS]; + + /* parent dma tag */ + bus_dma_tag_t parent_tag; + + /* interface to o.s */ + struct ifnet *ifp; + + struct ifmedia media; + uint16_t max_frame_size; + uint16_t rsrvd0; + int if_flags; + + /* hardware access lock */ + + struct mtx hw_lock; + volatile uint32_t hw_lock_held; + + /* transmit and receive buffers */ + uint32_t txr_idx; /* index of the current tx ring */ + qla_tx_ring_t tx_ring[NUM_TX_RINGS]; + + bus_dma_tag_t tx_tag; + struct task tx_task; + struct taskqueue *tx_tq; + struct callout tx_callout; + struct mtx tx_lock; + + qla_rx_ring_t rx_ring[MAX_RDS_RINGS]; + bus_dma_tag_t rx_tag; + uint32_t std_replenish; + + qla_rx_buf_t *rxb_free; + uint32_t rxb_free_count; + volatile uint32_t posting; + + /* stats */ + uint32_t err_m_getcl; + uint32_t err_m_getjcl; + uint32_t err_tx_dmamap_create; + uint32_t err_tx_dmamap_load; + uint32_t err_tx_defrag; + + uint64_t rx_frames; + uint64_t rx_bytes; + + uint64_t lro_pkt_count; + uint64_t lro_bytes; + + uint64_t ipv4_lro; + uint64_t ipv6_lro; + + uint64_t tx_frames; + uint64_t tx_bytes; + uint64_t tx_tso_frames; + uint64_t hw_vlan_tx_frames; + + uint32_t fw_ver_major; + uint32_t fw_ver_minor; + uint32_t fw_ver_sub; + uint32_t fw_ver_build; + + /* hardware specific */ + qla_hw_t hw; + + /* debug stuff */ + volatile const char *qla_lock; + volatile const char *qla_unlock; + uint32_t dbg_level; + + uint8_t fw_ver_str[32]; + + /* Error Injection Related */ + uint32_t err_inject; + struct task err_task; + struct taskqueue *err_tq; + + /* Peer Device */ + device_t peer_dev; + + volatile uint32_t msg_from_peer; +#define QL_PEER_MSG_RESET 0x01 +#define QL_PEER_MSG_ACK 0x02 + +}; +typedef struct qla_host qla_host_t; + +/* note that align has to be a power of 2 */ +#define QL_ALIGN(size, align) (size + (align - 1)) & ~(align - 1); +#define QL_MIN(x, y) ((x < y) ? x : y) + +#define QL_RUNNING(ifp) \ + ((ifp->if_drv_flags & (IFF_DRV_RUNNING | IFF_DRV_OACTIVE)) == \ + IFF_DRV_RUNNING) + +/* Return 0, if identical, else 1 */ +#define QL_MAC_CMP(mac1, mac2) \ + ((((*(uint32_t *) mac1) == (*(uint32_t *) mac2) && \ + (*(uint16_t *)(mac1 + 4)) == (*(uint16_t *)(mac2 + 4)))) ? 0 : 1) + +#endif /* #ifndef _QL_DEF_H_ */ Added: head/sys/dev/qlxgbe/ql_glbl.h ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ head/sys/dev/qlxgbe/ql_glbl.h Wed May 15 17:03:09 2013 (r250661) @@ -0,0 +1,95 @@ +/* + * Copyright (c) 2013-2014 Qlogic Corporation + * 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 COPYRIGHT HOLDERS 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 COPYRIGHT OWNER 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$ + */ +/* + * File: ql_glbl.h + * Author : David C Somayajulu, Qlogic Corporation, Aliso Viejo, CA 92656. + * Content: Contains prototypes of the exported functions from each file. + */ +#ifndef _QL_GLBL_H_ +#define _QL_GLBL_H_ + +/* + * from ql_isr.c + */ +extern void ql_mbx_isr(void *arg); +extern void ql_isr(void *arg); + +/* + * from ql_os.c + */ +extern int ql_alloc_dmabuf(qla_host_t *ha, qla_dma_t *dma_buf); +extern void ql_free_dmabuf(qla_host_t *ha, qla_dma_t *dma_buf); +extern int ql_get_mbuf(qla_host_t *ha, qla_rx_buf_t *rxb, struct mbuf *nmp); + +/* + * from ql_hw.c + */ +extern int ql_alloc_dma(qla_host_t *ha); +extern void ql_free_dma(qla_host_t *ha); +extern void ql_hw_add_sysctls(qla_host_t *ha); +extern int ql_hw_send(qla_host_t *ha, bus_dma_segment_t *segs, int nsegs, + uint32_t tx_idx, struct mbuf *mp, uint32_t txr_idx); +extern int ql_init_hw_if(qla_host_t *ha); +extern int ql_hw_set_multi(qla_host_t *ha, uint8_t *mta, uint32_t mcnt, + uint32_t add_multi); +extern void ql_del_hw_if(qla_host_t *ha); +extern int ql_set_promisc(qla_host_t *ha); +extern int ql_set_allmulti(qla_host_t *ha); +extern void ql_update_link_state(qla_host_t *ha); +extern void ql_hw_tx_done(qla_host_t *ha); +extern int ql_set_max_mtu(qla_host_t *ha, uint32_t mtu, uint16_t cntxt_id); +extern void ql_hw_stop_rcv(qla_host_t *ha); +extern void ql_get_stats(qla_host_t *ha); +extern void ql_hw_link_status(qla_host_t *ha); +extern int ql_hw_check_health(qla_host_t *ha); +extern void ql_minidump(qla_host_t *ha); + +/* + * from ql_misc.c + */ +extern int ql_init_hw(qla_host_t *ha); +extern int ql_rdwr_indreg32(qla_host_t *ha, uint32_t addr, uint32_t *val, + uint32_t rd); +extern int ql_rd_flash32(qla_host_t *ha, uint32_t addr, uint32_t *data); +extern int ql_rdwr_offchip_mem(qla_host_t *ha, uint64_t addr, + q80_offchip_mem_val_t *val, uint32_t rd); +extern void ql_read_mac_addr(qla_host_t *ha); +extern int ql_erase_flash(qla_host_t *ha, uint32_t off, uint32_t size); +extern int ql_wr_flash_buffer(qla_host_t *ha, uint32_t off, uint32_t size, + void *buf); +extern int ql_stop_sequence(qla_host_t *ha); +extern int ql_start_sequence(qla_host_t *ha, uint16_t index); + +/* + * from ql_ioctl.c + */ +extern int ql_make_cdev(qla_host_t *ha); +extern void ql_del_cdev(qla_host_t *ha); + +#endif /* #ifndef_QL_GLBL_H_ */ Added: head/sys/dev/qlxgbe/ql_hw.c ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ head/sys/dev/qlxgbe/ql_hw.c Wed May 15 17:03:09 2013 (r250661) @@ -0,0 +1,2847 @@ +/* + * Copyright (c) 2013-2014 Qlogic Corporation + * 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 COPYRIGHT HOLDERS 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 COPYRIGHT OWNER 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. + */ + +/* + * File: ql_hw.c + * Author : David C Somayajulu, Qlogic Corporation, Aliso Viejo, CA 92656. + * Content: Contains Hardware dependant functions + */ + +#include +__FBSDID("$FreeBSD$"); + +#include "ql_os.h" *** DIFF OUTPUT TRUNCATED AT 1000 LINES *** From owner-svn-src-all@FreeBSD.ORG Wed May 15 17:26:50 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id 98BE2502; Wed, 15 May 2013 17:26:50 +0000 (UTC) (envelope-from asomers@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id 8B2FBE95; Wed, 15 May 2013 17:26:50 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.6/8.14.6) with ESMTP id r4FHQoRG023489; Wed, 15 May 2013 17:26:50 GMT (envelope-from asomers@svn.freebsd.org) Received: (from asomers@localhost) by svn.freebsd.org (8.14.6/8.14.5/Submit) id r4FHQoSR023488; Wed, 15 May 2013 17:26:50 GMT (envelope-from asomers@svn.freebsd.org) Message-Id: <201305151726.r4FHQoSR023488@svn.freebsd.org> From: Alan Somers Date: Wed, 15 May 2013 17:26:50 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r250662 - head/sbin/camcontrol X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 15 May 2013 17:26:50 -0000 Author: asomers Date: Wed May 15 17:26:50 2013 New Revision: 250662 URL: http://svnweb.freebsd.org/changeset/base/250662 Log: sbin/camcontrol/camcontrol.c If an expander returns 0x00 (no device attached) in the ATTACHED DEVICE field of the SMP DISCOVER response, ignore the value of ATTACHED SAS ADDRESS, because it is invalid. Some expanders zero out the address when the attached device is removed, but others do not. Section 9.4.3.10 of the SAS Protocol Layer 2 revision 04b does not require them to do so. Approved by: ken (mentor) MFC after: 3 weeks Modified: head/sbin/camcontrol/camcontrol.c Modified: head/sbin/camcontrol/camcontrol.c ============================================================================== --- head/sbin/camcontrol/camcontrol.c Wed May 15 17:03:09 2013 (r250661) +++ head/sbin/camcontrol/camcontrol.c Wed May 15 17:26:50 2013 (r250662) @@ -7138,8 +7138,12 @@ smpphylist(struct cam_device *device, in continue; } - item = findsasdevice(&devlist, - scsi_8btou64(disresponse->attached_sas_address)); + if (disresponse->attached_device == SMP_DIS_AD_TYPE_NONE) { + item = NULL; + } else { + item = findsasdevice(&devlist, + scsi_8btou64(disresponse->attached_sas_address)); + } if ((quiet == 0) || (item != NULL)) { From owner-svn-src-all@FreeBSD.ORG Wed May 15 18:33:07 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id 3EC12872; Wed, 15 May 2013 18:33:07 +0000 (UTC) (envelope-from adrian@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id 304F1259; Wed, 15 May 2013 18:33:07 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.6/8.14.6) with ESMTP id r4FIX76I048549; Wed, 15 May 2013 18:33:07 GMT (envelope-from adrian@svn.freebsd.org) Received: (from adrian@localhost) by svn.freebsd.org (8.14.6/8.14.5/Submit) id r4FIX5fM048536; Wed, 15 May 2013 18:33:05 GMT (envelope-from adrian@svn.freebsd.org) Message-Id: <201305151833.r4FIX5fM048536@svn.freebsd.org> From: Adrian Chadd Date: Wed, 15 May 2013 18:33:05 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r250665 - head/sys/dev/ath X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 15 May 2013 18:33:07 -0000 Author: adrian Date: Wed May 15 18:33:05 2013 New Revision: 250665 URL: http://svnweb.freebsd.org/changeset/base/250665 Log: Implement my first cut at "correct" node power-save and PS-POLL support. This implements PS-POLL awareness i nthe * Implement frame "leaking", which allows for a software queue to be scheduled even though it's asleep * Track whether a frame has been leaked or not * Leak out a single non-AMPDU frame when transmitting aggregates * Queue BAR frames if the node is asleep * Direct-dispatch the rest of control and management frames. This allows for things like re-association to occur (which involves sending probe req/resp as well as assoc request/response) when the node is asleep and then tries reassociating. * Limit how many frames can set in the software node queue whilst the node is asleep. net80211 is already buffering frames for us so this is mostly just paranoia. * Add a PS-POLL method which leaks out a frame if there's something in the software queue, else it calls net80211's ps-poll routine. Since the ath PS-POLL routine marks the node as having a single frame to leak, either a software queued frame would leak, OR the next queued frame would leak. The next queued frame could be something from the net80211 power save queue, OR it could be a NULL frame from net80211. TODO: * Don't transmit further BAR frames (eg via a timeout) if the node is currently asleep. Otherwise we may end up exhausting management frames due to the lots of queued BAR frames. I may just undo this bit later on and direct-dispatch BAR frames even if the node is asleep. * It would be nice to burst out a single A-MPDU frame if both ends support this. I may end adding a FreeBSD IE soon to negotiate this power save behaviour. * I should make STAs timeout of power save mode if they've been in power save for more than a handful of seconds. This way cards that get "stuck" in power save mode don't stay there for the "inactivity" timeout in net80211. * Move the queue depth check into the driver layer (ath_start / ath_transmit) rather than doing it in the TX path. * There could be some naughty corner cases with ps-poll leaking. Specifically, if net80211 generates a NULL data frame whilst another transmitter sends a normal data frame out net80211 output / transmit, we need to ensure that the NULL data frame goes out first. This is one of those things that should occur inside the VAP/ic TX lock. Grr, more investigations to do.. Tested: * STA: AR5416, AR9280 * AP: AR5416, AR9280, AR9160 Modified: head/sys/dev/ath/if_ath.c head/sys/dev/ath/if_ath_tx.c head/sys/dev/ath/if_ath_tx.h head/sys/dev/ath/if_ath_tx_ht.c head/sys/dev/ath/if_ath_tx_ht.h head/sys/dev/ath/if_athioctl.h head/sys/dev/ath/if_athvar.h Modified: head/sys/dev/ath/if_ath.c ============================================================================== --- head/sys/dev/ath/if_ath.c Wed May 15 17:44:17 2013 (r250664) +++ head/sys/dev/ath/if_ath.c Wed May 15 18:33:05 2013 (r250665) @@ -125,7 +125,7 @@ __FBSDID("$FreeBSD$"); /* * Only enable this if you're working on PS-POLL support. */ -#undef ATH_SW_PSQ +#define ATH_SW_PSQ /* * ATH_BCBUF determines the number of vap's that can transmit @@ -212,6 +212,7 @@ static void ath_announce(struct ath_soft static void ath_dfs_tasklet(void *, int); static void ath_node_powersave(struct ieee80211_node *, int); static int ath_node_set_tim(struct ieee80211_node *, int); +static void ath_node_recv_pspoll(struct ieee80211_node *, struct mbuf *); #ifdef IEEE80211_SUPPORT_TDMA #include @@ -695,6 +696,11 @@ ath_attach(u_int16_t devid, struct ath_s sc->sc_txq_mcastq_maxdepth = ath_txbuf; /* + * How deep can the node software TX queue get whilst it's asleep. + */ + sc->sc_txq_node_psq_maxdepth = 16; + + /* * Default the maximum queue depth for a given node * to 1/4'th the TX buffers, or 64, whichever * is larger. @@ -1248,6 +1254,9 @@ ath_vap_create(struct ieee80211com *ic, avp->av_set_tim = vap->iv_set_tim; vap->iv_set_tim = ath_node_set_tim; + avp->av_recv_pspoll = vap->iv_recv_pspoll; + vap->iv_recv_pspoll = ath_node_recv_pspoll; + /* Set default parameters */ /* @@ -6169,9 +6178,11 @@ ath_tx_update_tim(struct ath_softc *sc, an->an_tim_set == 1 && an->an_swq_depth == 0) { DPRINTF(sc, ATH_DEBUG_NODE_PWRSAVE, - "%s: an=%p, swq_depth=0, tim_set=1, psq_set=0," + "%s: %6D: swq_depth=0, tim_set=1, psq_set=0," " clear!\n", - __func__, an); + __func__, + ni->ni_macaddr, + ":"); an->an_tim_set = 0; (void) avp->av_set_tim(ni, 0); } @@ -6181,6 +6192,151 @@ ath_tx_update_tim(struct ath_softc *sc, #endif /* ATH_SW_PSQ */ } +/* + * Received a ps-poll frame from net80211. + * + * Here we get a chance to serve out a software-queued frame ourselves + * before we punt it to net80211 to transmit us one itself - either + * because there's traffic in the net80211 psq, or a NULL frame to + * indicate there's nothing else. + */ +static void +ath_node_recv_pspoll(struct ieee80211_node *ni, struct mbuf *m) +{ +#ifdef ATH_SW_PSQ + struct ath_node *an; + struct ath_vap *avp; + struct ieee80211com *ic = ni->ni_ic; + struct ath_softc *sc = ic->ic_ifp->if_softc; + int tid; + + /* Just paranoia */ + if (ni == NULL) + return; + + /* + * Unassociated (temporary node) station. + */ + if (ni->ni_associd == 0) + return; + + /* + * We do have an active node, so let's begin looking into it. + */ + an = ATH_NODE(ni); + avp = ATH_VAP(ni->ni_vap); + + /* + * For now, we just call the original ps-poll method. + * Once we're ready to flip this on: + * + * + Set leak to 1, as no matter what we're going to have + * to send a frame; + * + Check the software queue and if there's something in it, + * schedule the highest TID thas has traffic from this node. + * Then make sure we schedule the software scheduler to + * run so it picks up said frame. + * + * That way whatever happens, we'll at least send _a_ frame + * to the given node. + * + * Again, yes, it's crappy QoS if the node has multiple + * TIDs worth of traffic - but let's get it working first + * before we optimise it. + * + * Also yes, there's definitely latency here - we're not + * direct dispatching to the hardware in this path (and + * we're likely being called from the packet receive path, + * so going back into TX may be a little hairy!) but again + * I'd like to get this working first before optimising + * turn-around time. + */ + + ATH_TX_LOCK(sc); + + /* + * Legacy - we're called and the node isn't asleep. + * Immediately punt. + */ + if (! an->an_is_powersave) { + device_printf(sc->sc_dev, + "%s: %6D: not in powersave?\n", + __func__, + ni->ni_macaddr, + ":"); + ATH_TX_UNLOCK(sc); + avp->av_recv_pspoll(ni, m); + return; + } + + /* + * We're in powersave. + * + * Leak a frame. + */ + an->an_leak_count = 1; + + /* + * Now, if there's no frames in the node, just punt to + * recv_pspoll. + * + * Don't bother checking if the TIM bit is set, we really + * only care if there are any frames here! + */ + if (an->an_swq_depth == 0) { + ATH_TX_UNLOCK(sc); + DPRINTF(sc, ATH_DEBUG_NODE_PWRSAVE, + "%s: %6D: SWQ empty; punting to net80211\n", + __func__, + ni->ni_macaddr, + ":"); + avp->av_recv_pspoll(ni, m); + return; + } + + /* + * Ok, let's schedule the highest TID that has traffic + * and then schedule something. + */ + for (tid = IEEE80211_TID_SIZE - 1; tid >= 0; tid--) { + struct ath_tid *atid = &an->an_tid[tid]; + /* + * No frames? Skip. + */ + if (atid->axq_depth == 0) + continue; + ath_tx_tid_sched(sc, atid); + /* + * XXX we could do a direct call to the TXQ + * scheduler code here to optimise latency + * at the expense of a REALLY deep callstack. + */ + ATH_TX_UNLOCK(sc); + taskqueue_enqueue(sc->sc_tq, &sc->sc_txqtask); + DPRINTF(sc, ATH_DEBUG_NODE_PWRSAVE, + "%s: %6D: leaking frame to TID %d\n", + __func__, + ni->ni_macaddr, + ":", + tid); + return; + } + + ATH_TX_UNLOCK(sc); + + /* + * XXX nothing in the TIDs at this point? Eek. + */ + device_printf(sc->sc_dev, "%s: %6D: TIDs empty, but ath_node showed traffic?!\n", + __func__, + ni->ni_macaddr, + ":"); + avp->av_recv_pspoll(ni, m); +#else + avp->av_recv_pspoll(ni, m); +#endif /* ATH_SW_PSQ */ +} + MODULE_VERSION(if_ath, 1); MODULE_DEPEND(if_ath, wlan, 1, 1, 1); /* 802.11 media layer */ #if defined(IEEE80211_ALQ) || defined(AH_DEBUG_ALQ) Modified: head/sys/dev/ath/if_ath_tx.c ============================================================================== --- head/sys/dev/ath/if_ath_tx.c Wed May 15 17:44:17 2013 (r250664) +++ head/sys/dev/ath/if_ath_tx.c Wed May 15 18:33:05 2013 (r250665) @@ -1401,6 +1401,69 @@ ath_tx_update_clrdmask(struct ath_softc } /* + * Return whether this frame should be software queued or + * direct dispatched. + * + * When doing powersave, BAR frames should be queued but other management + * frames should be directly sent. + * + * When not doing powersave, stick BAR frames into the hardware queue + * so it goes out even though the queue is paused. + * + * For now, management frames are also software queued by default. + */ +static int +ath_tx_should_swq_frame(struct ath_softc *sc, struct ath_node *an, + struct mbuf *m0, int *queue_to_head) +{ + struct ieee80211_node *ni = &an->an_node; + struct ieee80211_frame *wh; + uint8_t type, subtype; + + wh = mtod(m0, struct ieee80211_frame *); + type = wh->i_fc[0] & IEEE80211_FC0_TYPE_MASK; + subtype = wh->i_fc[0] & IEEE80211_FC0_SUBTYPE_MASK; + + (*queue_to_head) = 0; + + /* If it's not in powersave - direct-dispatch BAR */ + if ((ATH_NODE(ni)->an_is_powersave == 0) + && type == IEEE80211_FC0_TYPE_CTL && + subtype == IEEE80211_FC0_SUBTYPE_BAR) { + DPRINTF(sc, ATH_DEBUG_SW_TX, + "%s: BAR: TX'ing direct\n", __func__); + return (0); + } else if ((ATH_NODE(ni)->an_is_powersave == 1) + && type == IEEE80211_FC0_TYPE_CTL && + subtype == IEEE80211_FC0_SUBTYPE_BAR) { + /* BAR TX whilst asleep; queue */ + DPRINTF(sc, ATH_DEBUG_SW_TX, + "%s: swq: TX'ing\n", __func__); + (*queue_to_head) = 1; + return (1); + } else if ((ATH_NODE(ni)->an_is_powersave == 1) + && (type == IEEE80211_FC0_TYPE_MGT || + type == IEEE80211_FC0_TYPE_CTL)) { + /* + * Other control/mgmt frame; bypass software queuing + * for now! + */ + device_printf(sc->sc_dev, + "%s: %6D: Node is asleep; sending mgmt " + "(type=%d, subtype=%d)\n", + __func__, + ni->ni_macaddr, + ":", + type, + subtype); + return (0); + } else { + return (1); + } +} + + +/* * Transmit the given frame to the hardware. * * The frame must already be setup; rate control must already have @@ -1410,6 +1473,10 @@ ath_tx_update_clrdmask(struct ath_softc * it for this long when not doing software aggregation), later on * break this function into "setup_normal" and "xmit_normal". The * lock only needs to be held for the ath_tx_handoff call. + * + * XXX we don't update the leak count here - if we're doing + * direct frame dispatch, we need to be able to do it without + * decrementing the leak count (eg multicast queue frames.) */ static void ath_tx_xmit_normal(struct ath_softc *sc, struct ath_txq *txq, @@ -1786,6 +1853,7 @@ ath_tx_start(struct ath_softc *sc, struc int is_ampdu, is_ampdu_tx, is_ampdu_pending; ieee80211_seq seqno; uint8_t type, subtype; + int queue_to_head; ATH_TX_LOCK_ASSERT(sc); @@ -1826,6 +1894,32 @@ ath_tx_start(struct ath_softc *sc, struc } } + /* + * Enforce how deep the unicast queue can grow. + * + * If the node is in power save then we don't want + * the software queue to grow too deep, or a node may + * end up consuming all of the ath_buf entries. + * + * For now, only do this for DATA frames. + * + * We will want to cap how many management/control + * frames get punted to the software queue so it doesn't + * fill up. But the correct solution isn't yet obvious. + * In any case, this check should at least let frames pass + * that we are direct-dispatching. + * + * XXX TODO: duplicate this to the raw xmit path! + */ + if (type == IEEE80211_FC0_TYPE_DATA && + ATH_NODE(ni)->an_is_powersave && + ATH_NODE(ni)->an_swq_depth > + sc->sc_txq_node_psq_maxdepth) { + sc->sc_stats.ast_tx_node_psq_overflow++; + m_freem(m0); + return (ENOBUFS); + } + /* A-MPDU TX */ is_ampdu_tx = ath_tx_ampdu_running(sc, ATH_NODE(ni), tid); is_ampdu_pending = ath_tx_ampdu_pending(sc, ATH_NODE(ni), tid); @@ -1924,22 +2018,26 @@ ath_tx_start(struct ath_softc *sc, struc * either been TXed successfully or max retries has been * reached.) */ + /* + * Until things are better debugged - if this node is asleep + * and we're sending it a non-BAR frame, direct dispatch it. + * Why? Because we need to figure out what's actually being + * sent - eg, during reassociation/reauthentication after + * the node (last) disappeared whilst asleep, the driver should + * have unpaused/unsleep'ed the node. So until that is + * sorted out, use this workaround. + */ if (txq == &avp->av_mcastq) { DPRINTF(sc, ATH_DEBUG_SW_TX, "%s: bf=%p: mcastq: TX'ing\n", __func__, bf); bf->bf_state.bfs_txflags |= HAL_TXDESC_CLRDMASK; ath_tx_xmit_normal(sc, txq, bf); - } else if (type == IEEE80211_FC0_TYPE_CTL && - subtype == IEEE80211_FC0_SUBTYPE_BAR) { - DPRINTF(sc, ATH_DEBUG_SW_TX, - "%s: BAR: TX'ing direct\n", __func__); + } else if (ath_tx_should_swq_frame(sc, ATH_NODE(ni), m0, + &queue_to_head)) { + ath_tx_swq(sc, ni, txq, queue_to_head, bf); + } else { bf->bf_state.bfs_txflags |= HAL_TXDESC_CLRDMASK; ath_tx_xmit_normal(sc, txq, bf); - } else { - /* add to software queue */ - DPRINTF(sc, ATH_DEBUG_SW_TX, - "%s: bf=%p: swq: TX'ing\n", __func__, bf); - ath_tx_swq(sc, ni, txq, bf); } #else /* @@ -1947,6 +2045,12 @@ ath_tx_start(struct ath_softc *sc, struc * direct-dispatch to the hardware. */ bf->bf_state.bfs_txflags |= HAL_TXDESC_CLRDMASK; + /* + * Update the current leak count if + * we're leaking frames; and set the + * MORE flag as appropriate. + */ + ath_tx_leak_count_update(sc, tid, bf); ath_tx_xmit_normal(sc, txq, bf); #endif done: @@ -1973,6 +2077,8 @@ ath_tx_raw_start(struct ath_softc *sc, s u_int pri; int o_tid = -1; int do_override; + uint8_t type, subtype; + int queue_to_head; ATH_TX_LOCK_ASSERT(sc); @@ -1986,6 +2092,9 @@ ath_tx_raw_start(struct ath_softc *sc, s /* XXX honor IEEE80211_BPF_DATAPAD */ pktlen = m0->m_pkthdr.len - (hdrlen & 3) + IEEE80211_CRC_LEN; + type = wh->i_fc[0] & IEEE80211_FC0_TYPE_MASK; + subtype = wh->i_fc[0] & IEEE80211_FC0_SUBTYPE_MASK; + ATH_KTR(sc, ATH_KTR_TX, 2, "ath_tx_raw_start: ni=%p, bf=%p, raw", ni, bf); @@ -2162,16 +2271,35 @@ ath_tx_raw_start(struct ath_softc *sc, s __func__, do_override); #if 1 + /* + * Put addba frames in the right place in the right TID/HWQ. + */ if (do_override) { bf->bf_state.bfs_txflags |= HAL_TXDESC_CLRDMASK; + /* + * XXX if it's addba frames, should we be leaking + * them out via the frame leak method? + * XXX for now let's not risk it; but we may wish + * to investigate this later. + */ ath_tx_xmit_normal(sc, sc->sc_ac2q[pri], bf); - } else { + } else if (ath_tx_should_swq_frame(sc, ATH_NODE(ni), m0, + &queue_to_head)) { /* Queue to software queue */ - ath_tx_swq(sc, ni, sc->sc_ac2q[pri], bf); + ath_tx_swq(sc, ni, sc->sc_ac2q[pri], queue_to_head, bf); + } else { + bf->bf_state.bfs_txflags |= HAL_TXDESC_CLRDMASK; + ath_tx_xmit_normal(sc, sc->sc_ac2q[pri], bf); } #else /* Direct-dispatch to the hardware */ bf->bf_state.bfs_txflags |= HAL_TXDESC_CLRDMASK; + /* + * Update the current leak count if + * we're leaking frames; and set the + * MORE flag as appropriate. + */ + ath_tx_leak_count_update(sc, tid, bf); ath_tx_xmit_normal(sc, sc->sc_ac2q[pri], bf); #endif return 0; @@ -2603,6 +2731,60 @@ ath_tx_update_baw(struct ath_softc *sc, __func__, tap->txa_start, tap->txa_wnd, tid->baw_head); } +static void +ath_tx_leak_count_update(struct ath_softc *sc, struct ath_tid *tid, + struct ath_buf *bf) +{ + struct ieee80211_frame *wh; + + ATH_TX_LOCK_ASSERT(sc); + + if (tid->an->an_leak_count > 0) { + wh = mtod(bf->bf_m, struct ieee80211_frame *); + + /* + * Update MORE based on the software/net80211 queue states. + */ + if ((tid->an->an_stack_psq > 0) + || (tid->an->an_swq_depth > 0)) + wh->i_fc[1] |= IEEE80211_FC1_MORE_DATA; + else + wh->i_fc[1] &= ~IEEE80211_FC1_MORE_DATA; + + DPRINTF(sc, ATH_DEBUG_NODE_PWRSAVE, + "%s: %6D: leak count = %d, psq=%d, swq=%d, MORE=%d\n", + __func__, + tid->an->an_node.ni_macaddr, + ":", + tid->an->an_leak_count, + tid->an->an_stack_psq, + tid->an->an_swq_depth, + !! (wh->i_fc[1] & IEEE80211_FC1_MORE_DATA)); + + /* + * Re-sync the underlying buffer. + */ + bus_dmamap_sync(sc->sc_dmat, bf->bf_dmamap, + BUS_DMASYNC_PREWRITE); + + tid->an->an_leak_count --; + } +} + +static int +ath_tx_tid_can_tx_or_sched(struct ath_softc *sc, struct ath_tid *tid) +{ + + ATH_TX_LOCK_ASSERT(sc); + + if (tid->an->an_leak_count > 0) { + return (1); + } + if (tid->paused) + return (0); + return (1); +} + /* * Mark the current node/TID as ready to TX. * @@ -2611,14 +2793,19 @@ ath_tx_update_baw(struct ath_softc *sc, * * The TXQ lock must be held. */ -static void +void ath_tx_tid_sched(struct ath_softc *sc, struct ath_tid *tid) { struct ath_txq *txq = sc->sc_ac2q[tid->ac]; ATH_TX_LOCK_ASSERT(sc); - if (tid->paused) + /* + * If we are leaking out a frame to this destination + * for PS-POLL, ensure that we allow scheduling to + * occur. + */ + if (! ath_tx_tid_can_tx_or_sched(sc, tid)) return; /* paused, can't schedule yet */ if (tid->sched) @@ -2626,6 +2813,30 @@ ath_tx_tid_sched(struct ath_softc *sc, s tid->sched = 1; +#if 0 + /* + * If this is a sleeping node we're leaking to, given + * it a higher priority. This is so bad for QoS it hurts. + */ + if (tid->an->an_leak_count) { + TAILQ_INSERT_HEAD(&txq->axq_tidq, tid, axq_qelem); + } else { + TAILQ_INSERT_TAIL(&txq->axq_tidq, tid, axq_qelem); + } +#endif + + /* + * We can't do the above - it'll confuse the TXQ software + * scheduler which will keep checking the _head_ TID + * in the list to see if it has traffic. If we queue + * a TID to the head of the list and it doesn't transmit, + * we'll check it again. + * + * So, get the rest of this leaking frames support working + * and reliable first and _then_ optimise it so they're + * pushed out in front of any other pending software + * queued nodes. + */ TAILQ_INSERT_TAIL(&txq->axq_tidq, tid, axq_qelem); } @@ -2722,7 +2933,7 @@ ath_tx_xmit_aggr(struct ath_softc *sc, s tap = ath_tx_get_tx_tid(an, tid->tid); /* paused? queue */ - if (tid->paused) { + if (! ath_tx_tid_can_tx_or_sched(sc, tid)) { ATH_TID_INSERT_HEAD(tid, bf, bf_list); /* XXX don't sched - we're paused! */ return; @@ -2782,6 +2993,13 @@ ath_tx_xmit_aggr(struct ath_softc *sc, s /* Set completion handler, multi-frame aggregate or not */ bf->bf_comp = ath_tx_aggr_comp; + /* + * Update the current leak count if + * we're leaking frames; and set the + * MORE flag as appropriate. + */ + ath_tx_leak_count_update(sc, tid, bf); + /* Hand off to hardware */ ath_tx_handoff(sc, txq, bf); } @@ -2793,8 +3011,8 @@ ath_tx_xmit_aggr(struct ath_softc *sc, s * relevant software queue. */ void -ath_tx_swq(struct ath_softc *sc, struct ieee80211_node *ni, struct ath_txq *txq, - struct ath_buf *bf) +ath_tx_swq(struct ath_softc *sc, struct ieee80211_node *ni, + struct ath_txq *txq, int queue_to_head, struct ath_buf *bf) { struct ath_node *an = ATH_NODE(ni); struct ieee80211_frame *wh; @@ -2824,11 +3042,21 @@ ath_tx_swq(struct ath_softc *sc, struct * If the hardware queue is busy, queue it. * If the TID is paused or the traffic it outside BAW, software * queue it. + * + * If the node is in power-save and we're leaking a frame, + * leak a single frame. */ - if (atid->paused) { + if (! ath_tx_tid_can_tx_or_sched(sc, atid)) { /* TID is paused, queue */ DPRINTF(sc, ATH_DEBUG_SW_TX, "%s: paused\n", __func__); - ATH_TID_INSERT_TAIL(atid, bf, bf_list); + /* + * If the caller requested that it be sent at a high + * priority, queue it at the head of the list. + */ + if (queue_to_head) + ATH_TID_INSERT_HEAD(atid, bf, bf_list); + else + ATH_TID_INSERT_TAIL(atid, bf, bf_list); } else if (ath_tx_ampdu_pending(sc, an, tid)) { /* AMPDU pending; queue */ DPRINTF(sc, ATH_DEBUG_SW_TX, "%s: pending\n", __func__); @@ -2878,6 +3106,17 @@ ath_tx_swq(struct ath_softc *sc, struct DPRINTF(sc, ATH_DEBUG_SW_TX, "%s: xmit_normal\n", __func__); /* See if clrdmask needs to be set */ ath_tx_update_clrdmask(sc, atid, bf); + + /* + * Update the current leak count if + * we're leaking frames; and set the + * MORE flag as appropriate. + */ + ath_tx_leak_count_update(sc, atid, bf); + + /* + * Dispatch the frame. + */ ath_tx_xmit_normal(sc, txq, bf); } else { /* Busy; queue */ @@ -3646,6 +3885,7 @@ ath_tx_tid_reset(struct ath_softc *sc, s * do a complete hard reset of state here - no pause, no * complete counter, etc. */ + } /* @@ -3670,7 +3910,7 @@ ath_tx_node_flush(struct ath_softc *sc, ATH_TX_LOCK(sc); DPRINTF(sc, ATH_DEBUG_NODE, "%s: %6D: flush; is_powersave=%d, stack_psq=%d, tim=%d, " - "swq_depth=%d, clrdmask=%d\n", + "swq_depth=%d, clrdmask=%d, leak_count=%d\n", __func__, an->an_node.ni_macaddr, ":", @@ -3678,18 +3918,26 @@ ath_tx_node_flush(struct ath_softc *sc, an->an_stack_psq, an->an_tim_set, an->an_swq_depth, - an->clrdmask); + an->clrdmask, + an->an_leak_count); for (tid = 0; tid < IEEE80211_TID_SIZE; tid++) { struct ath_tid *atid = &an->an_tid[tid]; /* Free packets */ ath_tx_tid_drain(sc, an, atid, &bf_cq); + /* Remove this tid from the list of active tids */ ath_tx_tid_unsched(sc, atid); + /* Reset the per-TID pause, BAR, etc state */ ath_tx_tid_reset(sc, atid); } + + /* + * Clear global leak count + */ + an->an_leak_count = 0; ATH_TX_UNLOCK(sc); /* Handle completed frames */ @@ -4860,6 +5108,11 @@ ath_tx_tid_hw_queue_aggr(struct ath_soft DPRINTF(sc, ATH_DEBUG_SW_TX, "%s: tid=%d\n", __func__, tid->tid); ATH_TX_LOCK_ASSERT(sc); + /* + * XXX TODO: If we're called for a queue that we're leaking frames to, + * ensure we only leak one. + */ + tap = ath_tx_get_tx_tid(an, tid->tid); if (tid->tid == IEEE80211_NONQOS_TID) @@ -4877,7 +5130,7 @@ ath_tx_tid_hw_queue_aggr(struct ath_soft * of packet loss; but as its serialised with this code, * it won't "appear" half way through queuing packets. */ - if (tid->paused) + if (! ath_tx_tid_can_tx_or_sched(sc, tid)) break; bf = ATH_TID_FIRST(tid); @@ -5029,6 +5282,14 @@ ath_tx_tid_hw_queue_aggr(struct ath_soft if (bf->bf_state.bfs_tid == IEEE80211_NONQOS_TID) device_printf(sc->sc_dev, "%s: TID=16?\n", __func__); + /* + * Update leak count and frame config if were leaking frames. + * + * XXX TODO: it should update all frames in an aggregate + * correctly! + */ + ath_tx_leak_count_update(sc, tid, bf); + /* Punt to txq */ ath_tx_handoff(sc, txq, bf); @@ -5044,7 +5305,8 @@ ath_tx_tid_hw_queue_aggr(struct ath_soft * XXX locking on txq here? */ if (txq->axq_aggr_depth >= sc->sc_hwq_limit || - status == ATH_AGGR_BAW_CLOSED) + (status == ATH_AGGR_BAW_CLOSED || + status == ATH_AGGR_LEAK_CLOSED)) break; } } @@ -5077,8 +5339,11 @@ ath_tx_tid_hw_queue_norm(struct ath_soft /* * If the upper layers have paused the TID, don't * queue any further packets. + * + * XXX if we are leaking frames, make sure we decrement + * that counter _and_ we continue here. */ - if (tid->paused) + if (! ath_tx_tid_can_tx_or_sched(sc, tid)) break; bf = ATH_TID_FIRST(tid); @@ -5114,6 +5379,13 @@ ath_tx_tid_hw_queue_norm(struct ath_soft ath_tx_rate_fill_rcflags(sc, bf); ath_tx_setds(sc, bf); + /* + * Update the current leak count if + * we're leaking frames; and set the + * MORE flag as appropriate. + */ + ath_tx_leak_count_update(sc, tid, bf); + /* Track outstanding buffer count to hardware */ /* aggregates are "one" buffer */ tid->hwq_depth++; @@ -5161,7 +5433,11 @@ ath_txq_sched(struct ath_softc *sc, stru DPRINTF(sc, ATH_DEBUG_SW_TX, "%s: tid=%d, paused=%d\n", __func__, tid->tid, tid->paused); ath_tx_tid_unsched(sc, tid); - if (tid->paused) { + /* + * This node may be in power-save and we're leaking + * a frame; be careful. + */ + if (! ath_tx_tid_can_tx_or_sched(sc, tid)) { continue; } if (ath_tx_ampdu_running(sc, tid->an, tid->tid)) @@ -5182,6 +5458,11 @@ ath_txq_sched(struct ath_softc *sc, stru * If this was the last entry on the original list, stop. * Otherwise nodes that have been rescheduled onto the end * of the TID FIFO list will just keep being rescheduled. + * + * XXX What should we do about nodes that were paused + * but are pending a leaking frame in response to a ps-poll? + * They'll be put at the front of the list; so they'll + * prematurely trigger this condition! Ew. */ if (tid == last) break; @@ -5433,6 +5714,7 @@ ath_addba_stop(struct ieee80211_node *ni TAILQ_REMOVE(&bf_cq, bf, bf_list); ath_tx_default_comp(sc, bf, 1); } + } /* @@ -5604,33 +5886,19 @@ ath_tx_node_sleep(struct ath_softc *sc, ATH_TX_UNLOCK_ASSERT(sc); - /* - * It's possible that a parallel call to ath_tx_node_wakeup() - * will unpause these queues. - * - * The node lock can't just be grabbed here, as there's places - * in the driver where the node lock is grabbed _within_ a - * TXQ lock. - * So, we do this delicately and unwind state if needed. - * - * + Pause all the queues - * + Grab the node lock - * + If the queue is already asleep, unpause and quit - * + else just mark as asleep. - * - * A parallel sleep() call will just pause and then - * find they're already paused, so undo it. - * - * A parallel wakeup() call will check if asleep is 1 - * and if it's not (ie, it's 0), it'll treat it as already - * being awake. If it's 1, it'll mark it as 0 and then - * unpause everything. - * - * (Talk about a delicate hack.) - */ - /* Suspend all traffic on the node */ ATH_TX_LOCK(sc); + + if (an->an_is_powersave) { + device_printf(sc->sc_dev, + "%s: %6D: node was already asleep!\n", + __func__, + an->an_node.ni_macaddr, + ":"); + ATH_TX_UNLOCK(sc); + return; + } + for (tid = 0; tid < IEEE80211_TID_SIZE; tid++) { atid = &an->an_tid[tid]; txq = sc->sc_ac2q[atid->ac]; @@ -5638,21 +5906,6 @@ ath_tx_node_sleep(struct ath_softc *sc, ath_tx_tid_pause(sc, atid); } - /* In case of concurrency races from net80211.. */ - if (an->an_is_powersave == 1) { - device_printf(sc->sc_dev, - "%s: an=%p: node was already asleep\n", - __func__, an); - for (tid = 0; tid < IEEE80211_TID_SIZE; tid++) { - atid = &an->an_tid[tid]; - txq = sc->sc_ac2q[atid->ac]; - - ath_tx_tid_resume(sc, atid); - } - ATH_TX_UNLOCK(sc); - return; - } - /* Mark node as in powersaving */ an->an_is_powersave = 1; @@ -5674,7 +5927,7 @@ ath_tx_node_wakeup(struct ath_softc *sc, ATH_TX_LOCK(sc); - /* In case of concurrency races from net80211.. */ + /* !? */ if (an->an_is_powersave == 0) { ATH_TX_UNLOCK(sc); device_printf(sc->sc_dev, @@ -5685,6 +5938,10 @@ ath_tx_node_wakeup(struct ath_softc *sc, /* Mark node as awake */ an->an_is_powersave = 0; + /* + * Clear any pending leaked frame requests + */ + an->an_leak_count = 0; for (tid = 0; tid < IEEE80211_TID_SIZE; tid++) { atid = &an->an_tid[tid]; Modified: head/sys/dev/ath/if_ath_tx.h ============================================================================== --- head/sys/dev/ath/if_ath_tx.h Wed May 15 17:44:17 2013 (r250664) +++ head/sys/dev/ath/if_ath_tx.h Wed May 15 18:33:05 2013 (r250665) @@ -98,7 +98,7 @@ extern int ath_raw_xmit(struct ieee80211 /* software queue stuff */ extern void ath_tx_swq(struct ath_softc *sc, struct ieee80211_node *ni, - struct ath_txq *txq, struct ath_buf *bf); + struct ath_txq *txq, int queue_to_head, struct ath_buf *bf); extern void ath_tx_tid_init(struct ath_softc *sc, struct ath_node *an); extern void ath_tx_tid_hw_queue_aggr(struct ath_softc *sc, struct ath_node *an, struct ath_tid *tid); @@ -113,6 +113,7 @@ extern void ath_tx_addto_baw(struct ath_ struct ath_tid *tid, struct ath_buf *bf); extern struct ieee80211_tx_ampdu * ath_tx_get_tx_tid(struct ath_node *an, int tid); +extern void ath_tx_tid_sched(struct ath_softc *sc, struct ath_tid *tid); /* TX addba handling */ extern int ath_addba_request(struct ieee80211_node *ni, @@ -137,6 +138,11 @@ extern int ath_tx_node_is_asleep(struct extern void ath_tx_node_reassoc(struct ath_softc *sc, struct ath_node *an); /* + * Hardware queue stuff + */ +extern void ath_tx_push_pending(struct ath_softc *sc, struct ath_txq *txq); + +/* * Misc debugging stuff */ #ifdef ATH_DEBUG_ALQ Modified: head/sys/dev/ath/if_ath_tx_ht.c ============================================================================== --- head/sys/dev/ath/if_ath_tx_ht.c Wed May 15 17:44:17 2013 (r250664) +++ head/sys/dev/ath/if_ath_tx_ht.c Wed May 15 18:33:05 2013 (r250665) @@ -862,9 +862,14 @@ ath_tx_form_aggr(struct ath_softc *sc, s bf_prev = bf; /* - * XXX TODO: if any sub-frames have RTS/CTS enabled; - * enable it for the entire aggregate. + * If we're leaking frames, just return at this point; + * we've queued a single frame and we don't want to add + * any more. */ + if (tid->an->an_leak_count) { + status = ATH_AGGR_LEAK_CLOSED; + break; + } #if 0 /* Modified: head/sys/dev/ath/if_ath_tx_ht.h ============================================================================== --- head/sys/dev/ath/if_ath_tx_ht.h Wed May 15 17:44:17 2013 (r250664) +++ head/sys/dev/ath/if_ath_tx_ht.h Wed May 15 18:33:05 2013 (r250665) @@ -46,6 +46,7 @@ typedef enum { ATH_AGGR_8K_LIMITED, ATH_AGGR_ERROR, ATH_AGGR_NONAGGR, + ATH_AGGR_LEAK_CLOSED, } ATH_AGGR_STATUS; extern int ath_max_4ms_framelen[4][32]; Modified: head/sys/dev/ath/if_athioctl.h ============================================================================== --- head/sys/dev/ath/if_athioctl.h Wed May 15 17:44:17 2013 (r250664) +++ head/sys/dev/ath/if_athioctl.h Wed May 15 18:33:05 2013 (r250665) @@ -163,9 +163,10 @@ struct ath_stats { u_int32_t ast_tx_mcastq_overflow; /* multicast queue overflow */ u_int32_t ast_rx_keymiss; u_int32_t ast_tx_swfiltered; + u_int32_t ast_tx_node_psq_overflow; u_int32_t ast_rx_stbc; /* RX STBC frame */ u_int32_t ast_tx_nodeq_overflow; /* node sw queue overflow */ - u_int32_t ast_pad[13]; + u_int32_t ast_pad[12]; }; #define SIOCGATHSTATS _IOWR('i', 137, struct ifreq) Modified: head/sys/dev/ath/if_athvar.h ============================================================================== --- head/sys/dev/ath/if_athvar.h Wed May 15 17:44:17 2013 (r250664) +++ head/sys/dev/ath/if_athvar.h Wed May 15 18:33:05 2013 (r250665) @@ -182,6 +182,7 @@ struct ath_node { uint32_t an_swq_depth; /* how many SWQ packets for this node */ int clrdmask; /* has clrdmask been set */ + uint32_t an_leak_count; /* How many frames to leak during pause */ /* variable-length rate control state follows */ }; #define ATH_NODE(ni) ((struct ath_node *)(ni)) @@ -465,6 +466,8 @@ struct ath_vap { void (*av_bmiss)(struct ieee80211vap *); void (*av_node_ps)(struct ieee80211_node *, int); int (*av_set_tim)(struct ieee80211_node *, int); + void (*av_recv_pspoll)(struct ieee80211_node *, + struct mbuf *); }; #define ATH_VAP(vap) ((struct ath_vap *)(vap)) @@ -794,6 +797,8 @@ struct ath_softc { * management/multicast frames; * + multicast frames overwhelming everything (when the * air is sufficiently busy that cabq can't drain.) + * + A node in powersave shouldn't be allowed to exhaust + * all available mbufs; * * These implement: * + data_minfree is the maximum number of free buffers @@ -804,6 +809,7 @@ struct ath_softc { int sc_txq_node_maxdepth; int sc_txq_data_minfree; int sc_txq_mcastq_maxdepth; + int sc_txq_node_psq_maxdepth; /* * Aggregation twiddles From owner-svn-src-all@FreeBSD.ORG Wed May 15 18:38:29 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id 73B15A47; Wed, 15 May 2013 18:38:29 +0000 (UTC) (envelope-from delphij@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id 669C8285; Wed, 15 May 2013 18:38:29 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.6/8.14.6) with ESMTP id r4FIcTsn049598; Wed, 15 May 2013 18:38:29 GMT (envelope-from delphij@svn.freebsd.org) Received: (from delphij@localhost) by svn.freebsd.org (8.14.6/8.14.5/Submit) id r4FIcTMF049597; Wed, 15 May 2013 18:38:29 GMT (envelope-from delphij@svn.freebsd.org) Message-Id: <201305151838.r4FIcTMF049597@svn.freebsd.org> From: Xin LI Date: Wed, 15 May 2013 18:38:29 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r250666 - head/bin/kenv X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 15 May 2013 18:38:29 -0000 Author: delphij Date: Wed May 15 18:38:28 2013 New Revision: 250666 URL: http://svnweb.freebsd.org/changeset/base/250666 Log: Constify parameters, no functional or binary change. Verified with: sha256(1) MFC after: 2 weeks Modified: head/bin/kenv/kenv.c Modified: head/bin/kenv/kenv.c ============================================================================== --- head/bin/kenv/kenv.c Wed May 15 18:33:05 2013 (r250665) +++ head/bin/kenv/kenv.c Wed May 15 18:38:28 2013 (r250666) @@ -37,9 +37,9 @@ __FBSDID("$FreeBSD$"); static void usage(void); static int kdumpenv(void); -static int kgetenv(char *); -static int ksetenv(char *, char *); -static int kunsetenv(char *); +static int kgetenv(const char *); +static int ksetenv(const char *, char *); +static int kunsetenv(const char *); static int hflag = 0; static int Nflag = 0; @@ -170,7 +170,7 @@ kdumpenv(void) } static int -kgetenv(char *env) +kgetenv(const char *env) { char buf[1024]; int ret; @@ -186,7 +186,7 @@ kgetenv(char *env) } static int -ksetenv(char *env, char *val) +ksetenv(const char *env, char *val) { int ret; @@ -197,7 +197,7 @@ ksetenv(char *env, char *val) } static int -kunsetenv(char *env) +kunsetenv(const char *env) { int ret; From owner-svn-src-all@FreeBSD.ORG Wed May 15 18:41:50 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id 96642C17; Wed, 15 May 2013 18:41:50 +0000 (UTC) (envelope-from jh@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id 6F2082A8; Wed, 15 May 2013 18:41:50 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.6/8.14.6) with ESMTP id r4FIfoVJ051895; Wed, 15 May 2013 18:41:50 GMT (envelope-from jh@svn.freebsd.org) Received: (from jh@localhost) by svn.freebsd.org (8.14.6/8.14.5/Submit) id r4FIfnTZ051892; Wed, 15 May 2013 18:41:49 GMT (envelope-from jh@svn.freebsd.org) Message-Id: <201305151841.r4FIfnTZ051892@svn.freebsd.org> From: Jaakko Heinonen Date: Wed, 15 May 2013 18:41:49 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r250667 - in head/contrib/nvi: common include X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 15 May 2013 18:41:50 -0000 Author: jh Date: Wed May 15 18:41:49 2013 New Revision: 250667 URL: http://svnweb.freebsd.org/changeset/base/250667 Log: Rename O_DIRECTORY to O_TMP_DIRECTORY to avoid shadowing the fcntl.h O_DIRECTORY flag. PR: bin/173924 Obtained from: git://repo.or.cz/nvi.git Modified: head/contrib/nvi/common/exf.c head/contrib/nvi/common/options.c head/contrib/nvi/include/options_def.h Modified: head/contrib/nvi/common/exf.c ============================================================================== --- head/contrib/nvi/common/exf.c Wed May 15 18:38:28 2013 (r250666) +++ head/contrib/nvi/common/exf.c Wed May 15 18:41:49 2013 (r250667) @@ -187,10 +187,10 @@ file_init(sp, frp, rcv_name, flags) */ oname = frp->name; if (LF_ISSET(FS_OPENERR) || oname == NULL || !exists) { - if (opts_empty(sp, O_DIRECTORY, 0)) + if (opts_empty(sp, O_TMP_DIRECTORY, 0)) goto err; (void)snprintf(tname, sizeof(tname), - "%s/vi.XXXXXXXXXX", O_STR(sp, O_DIRECTORY)); + "%s/vi.XXXXXXXXXX", O_STR(sp, O_TMP_DIRECTORY)); if ((fd = mkstemp(tname)) == -1) { msgq(sp, M_SYSERR, "237|Unable to create temporary file"); Modified: head/contrib/nvi/common/options.c ============================================================================== --- head/contrib/nvi/common/options.c Wed May 15 18:38:28 2013 (r250666) +++ head/contrib/nvi/common/options.c Wed May 15 18:41:49 2013 (r250667) @@ -64,7 +64,7 @@ OPTLIST const optlist[] = { {"columns", f_columns, OPT_NUM, OPT_NOSAVE}, /* O_COMMENT 4.4BSD */ {"comment", NULL, OPT_0BOOL, 0}, -/* O_DIRECTORY 4BSD */ +/* O_TMP_DIRECTORY 4BSD */ {"directory", NULL, OPT_STR, 0}, /* O_EDCOMPATIBLE 4BSD */ {"edcompatible",NULL, OPT_0BOOL, 0}, @@ -244,7 +244,7 @@ static OABBREV const abbrev[] = { {"aw", O_AUTOWRITE}, /* 4BSD */ {"bf", O_BEAUTIFY}, /* 4BSD */ {"co", O_COLUMNS}, /* 4.4BSD */ - {"dir", O_DIRECTORY}, /* 4BSD */ + {"dir", O_TMP_DIRECTORY}, /* 4BSD */ {"eb", O_ERRORBELLS}, /* 4BSD */ {"ed", O_EDCOMPATIBLE}, /* 4BSD */ {"ex", O_EXRC}, /* System V (undocumented) */ @@ -347,7 +347,7 @@ opts_init(sp, oargs) */ (void)snprintf(b1, sizeof(b1), "directory=%s", (s = getenv("TMPDIR")) == NULL ? _PATH_TMP : s); - OI(O_DIRECTORY, b1); + OI(O_TMP_DIRECTORY, b1); OI(O_ESCAPETIME, "escapetime=6"); OI(O_KEYTIME, "keytime=6"); OI(O_MATCHTIME, "matchtime=7"); Modified: head/contrib/nvi/include/options_def.h ============================================================================== --- head/contrib/nvi/include/options_def.h Wed May 15 18:38:28 2013 (r250666) +++ head/contrib/nvi/include/options_def.h Wed May 15 18:41:49 2013 (r250667) @@ -8,7 +8,7 @@ #define O_CEDIT 7 #define O_COLUMNS 8 #define O_COMMENT 9 -#define O_DIRECTORY 10 +#define O_TMP_DIRECTORY 10 #define O_EDCOMPATIBLE 11 #define O_ESCAPETIME 12 #define O_ERRORBELLS 13 From owner-svn-src-all@FreeBSD.ORG Wed May 15 19:33:54 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id 03707D8E; Wed, 15 May 2013 19:33:54 +0000 (UTC) (envelope-from pluknet@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id EA63474E; Wed, 15 May 2013 19:33:53 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.6/8.14.6) with ESMTP id r4FJXrWd071323; Wed, 15 May 2013 19:33:53 GMT (envelope-from pluknet@svn.freebsd.org) Received: (from pluknet@localhost) by svn.freebsd.org (8.14.6/8.14.5/Submit) id r4FJXrxi071322; Wed, 15 May 2013 19:33:53 GMT (envelope-from pluknet@svn.freebsd.org) Message-Id: <201305151933.r4FJXrxi071322@svn.freebsd.org> From: Sergey Kandaurov Date: Wed, 15 May 2013 19: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 Subject: svn commit: r250671 - stable/9/share/man/man9 X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 15 May 2013 19:33:54 -0000 Author: pluknet Date: Wed May 15 19:33:53 2013 New Revision: 250671 URL: http://svnweb.freebsd.org/changeset/base/250671 Log: MFC r242992: Avoid an ambiguous reference to mtx_lock(9). Modified: stable/9/share/man/man9/mi_switch.9 Directory Properties: stable/9/share/man/man9/ (props changed) Modified: stable/9/share/man/man9/mi_switch.9 ============================================================================== --- stable/9/share/man/man9/mi_switch.9 Wed May 15 19:23:36 2013 (r250670) +++ stable/9/share/man/man9/mi_switch.9 Wed May 15 19:33:53 2013 (r250671) @@ -60,7 +60,7 @@ can be enumerated as follows: .It From within a function such as .Xr cv_wait 9 , -.Xr mtx_lock , +.Xr mtx_lock 9 , or .Xr tsleep 9 when the current thread From owner-svn-src-all@FreeBSD.ORG Wed May 15 19:38:49 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id DF23BF64; Wed, 15 May 2013 19:38:49 +0000 (UTC) (envelope-from pluknet@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id D0CEF791; Wed, 15 May 2013 19:38:49 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.6/8.14.6) with ESMTP id r4FJcnY2072286; Wed, 15 May 2013 19:38:49 GMT (envelope-from pluknet@svn.freebsd.org) Received: (from pluknet@localhost) by svn.freebsd.org (8.14.6/8.14.5/Submit) id r4FJcnKq072285; Wed, 15 May 2013 19:38:49 GMT (envelope-from pluknet@svn.freebsd.org) Message-Id: <201305151938.r4FJcnKq072285@svn.freebsd.org> From: Sergey Kandaurov Date: Wed, 15 May 2013 19:38:49 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-8@freebsd.org Subject: svn commit: r250672 - stable/8/share/man/man9 X-SVN-Group: stable-8 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 15 May 2013 19:38:50 -0000 Author: pluknet Date: Wed May 15 19:38:49 2013 New Revision: 250672 URL: http://svnweb.freebsd.org/changeset/base/250672 Log: MFC r242992: Avoid an ambiguous reference to mtx_lock(9). Modified: stable/8/share/man/man9/mi_switch.9 Directory Properties: stable/8/share/man/man9/ (props changed) Modified: stable/8/share/man/man9/mi_switch.9 ============================================================================== --- stable/8/share/man/man9/mi_switch.9 Wed May 15 19:33:53 2013 (r250671) +++ stable/8/share/man/man9/mi_switch.9 Wed May 15 19:38:49 2013 (r250672) @@ -67,7 +67,7 @@ can be enumerated as follows: .It From within a function such as .Xr cv_wait 9 , -.Xr mtx_lock , +.Xr mtx_lock 9 , or .Xr tsleep 9 when the current thread From owner-svn-src-all@FreeBSD.ORG Wed May 15 19:52:38 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id 6CC49664; Wed, 15 May 2013 19:52:38 +0000 (UTC) (envelope-from pluknet@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id 5EACC834; Wed, 15 May 2013 19:52:38 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.6/8.14.6) with ESMTP id r4FJqcMr078272; Wed, 15 May 2013 19:52:38 GMT (envelope-from pluknet@svn.freebsd.org) Received: (from pluknet@localhost) by svn.freebsd.org (8.14.6/8.14.5/Submit) id r4FJqcAj078271; Wed, 15 May 2013 19:52:38 GMT (envelope-from pluknet@svn.freebsd.org) Message-Id: <201305151952.r4FJqcAj078271@svn.freebsd.org> From: Sergey Kandaurov Date: Wed, 15 May 2013 19:52:38 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-8@freebsd.org Subject: svn commit: r250673 - stable/8/share/man/man9 X-SVN-Group: stable-8 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 15 May 2013 19:52:38 -0000 Author: pluknet Date: Wed May 15 19:52:37 2013 New Revision: 250673 URL: http://svnweb.freebsd.org/changeset/base/250673 Log: MFC r242995: firmware(9) mdoc cleanup. - Lowercase a cross reference to make. - Sort SEE ALSO cross references. Modified: stable/8/share/man/man9/firmware.9 Directory Properties: stable/8/share/man/man9/ (props changed) Modified: stable/8/share/man/man9/firmware.9 ============================================================================== --- stable/8/share/man/man9/firmware.9 Wed May 15 19:38:49 2013 (r250672) +++ stable/8/share/man/man9/firmware.9 Wed May 15 19:52:37 2013 (r250673) @@ -255,11 +255,11 @@ IxNpeMicrocode.dat Note that generating the firmware modules in this way requires the availability of the following tools: .Xr awk , -.Xr Make , +.Xr make , the compiler and the linker. .Sh SEE ALSO -.Xr module 9 , -.Xr kld 4 +.Xr kld 4 , +.Xr module 9 .Pp .Pa /usr/share/examples/kld/firmware .Sh HISTORY From owner-svn-src-all@FreeBSD.ORG Wed May 15 19:53:50 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id 61DB27DA; Wed, 15 May 2013 19:53:50 +0000 (UTC) (envelope-from pluknet@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id 544AE842; Wed, 15 May 2013 19:53:50 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.6/8.14.6) with ESMTP id r4FJroYM078521; Wed, 15 May 2013 19:53:50 GMT (envelope-from pluknet@svn.freebsd.org) Received: (from pluknet@localhost) by svn.freebsd.org (8.14.6/8.14.5/Submit) id r4FJrojU078520; Wed, 15 May 2013 19:53:50 GMT (envelope-from pluknet@svn.freebsd.org) Message-Id: <201305151953.r4FJrojU078520@svn.freebsd.org> From: Sergey Kandaurov Date: Wed, 15 May 2013 19:53:50 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org Subject: svn commit: r250674 - stable/9/share/man/man9 X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 15 May 2013 19:53:50 -0000 Author: pluknet Date: Wed May 15 19:53:49 2013 New Revision: 250674 URL: http://svnweb.freebsd.org/changeset/base/250674 Log: MFC r242995: firmware(9) mdoc cleanup. - Lowercase a cross reference to make. - Sort SEE ALSO cross references. Modified: stable/9/share/man/man9/firmware.9 Directory Properties: stable/9/share/man/man9/ (props changed) Modified: stable/9/share/man/man9/firmware.9 ============================================================================== --- stable/9/share/man/man9/firmware.9 Wed May 15 19:52:37 2013 (r250673) +++ stable/9/share/man/man9/firmware.9 Wed May 15 19:53:49 2013 (r250674) @@ -255,11 +255,11 @@ IxNpeMicrocode.dat Note that generating the firmware modules in this way requires the availability of the following tools: .Xr awk , -.Xr Make , +.Xr make , the compiler and the linker. .Sh SEE ALSO -.Xr module 9 , -.Xr kld 4 +.Xr kld 4 , +.Xr module 9 .Pp .Pa /usr/share/examples/kld/firmware .Sh HISTORY From owner-svn-src-all@FreeBSD.ORG Wed May 15 19:58:12 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id DBE4DA78; Wed, 15 May 2013 19:58:12 +0000 (UTC) (envelope-from jhibbits@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id CCB1E878; Wed, 15 May 2013 19:58:12 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.6/8.14.6) with ESMTP id r4FJwCn0079451; Wed, 15 May 2013 19:58:12 GMT (envelope-from jhibbits@svn.freebsd.org) Received: (from jhibbits@localhost) by svn.freebsd.org (8.14.6/8.14.5/Submit) id r4FJwCh7079450; Wed, 15 May 2013 19:58:12 GMT (envelope-from jhibbits@svn.freebsd.org) Message-Id: <201305151958.r4FJwCh7079450@svn.freebsd.org> From: Justin Hibbits Date: Wed, 15 May 2013 19:58:12 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org Subject: svn commit: r250675 - stable/9/sys/powerpc/aim X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 15 May 2013 19:58:12 -0000 Author: jhibbits Date: Wed May 15 19:58:12 2013 New Revision: 250675 URL: http://svnweb.freebsd.org/changeset/base/250675 Log: MFC r249864,249918 Introduce kernel coredumps to ppc32 AIM. Leeched from the booke code. Modified: stable/9/sys/powerpc/aim/mmu_oea.c Directory Properties: stable/9/sys/ (props changed) Modified: stable/9/sys/powerpc/aim/mmu_oea.c ============================================================================== --- stable/9/sys/powerpc/aim/mmu_oea.c Wed May 15 19:53:49 2013 (r250674) +++ stable/9/sys/powerpc/aim/mmu_oea.c Wed May 15 19:58:12 2013 (r250675) @@ -171,6 +171,11 @@ struct ofw_map { u_int om_mode; }; +extern unsigned char _etext[]; +extern unsigned char _end[]; + +extern int dumpsys_minidump; + /* * Map of physical memory regions. */ @@ -318,6 +323,9 @@ void moea_kenter(mmu_t, vm_offset_t, vm_ void moea_page_set_memattr(mmu_t mmu, vm_page_t m, vm_memattr_t ma); boolean_t moea_dev_direct_mapped(mmu_t, vm_offset_t, vm_size_t); static void moea_sync_icache(mmu_t, pmap_t, vm_offset_t, vm_size_t); +vm_offset_t moea_dumpsys_map(mmu_t mmu, struct pmap_md *md, vm_size_t ofs, + vm_size_t *sz); +struct pmap_md * moea_scan_md(mmu_t mmu, struct pmap_md *prev); static mmu_method_t moea_methods[] = { MMUMETHOD(mmu_change_wiring, moea_change_wiring), @@ -365,6 +373,8 @@ static mmu_method_t moea_methods[] = { MMUMETHOD(mmu_kenter, moea_kenter), MMUMETHOD(mmu_kenter_attr, moea_kenter_attr), MMUMETHOD(mmu_dev_direct_mapped,moea_dev_direct_mapped), + MMUMETHOD(mmu_scan_md, moea_scan_md), + MMUMETHOD(mmu_dumpsys_map, moea_dumpsys_map), { 0, 0 } }; @@ -2515,3 +2525,101 @@ moea_sync_icache(mmu_t mmu, pmap_t pm, v } PMAP_UNLOCK(pm); } + +vm_offset_t +moea_dumpsys_map(mmu_t mmu, struct pmap_md *md, vm_size_t ofs, + vm_size_t *sz) +{ + if (md->md_vaddr == ~0UL) + return (md->md_paddr + ofs); + else + return (md->md_vaddr + ofs); +} + +struct pmap_md * +moea_scan_md(mmu_t mmu, struct pmap_md *prev) +{ + static struct pmap_md md; + struct pvo_entry *pvo; + vm_offset_t va; + + if (dumpsys_minidump) { + md.md_paddr = ~0UL; /* Minidumps use virtual addresses. */ + if (prev == NULL) { + /* 1st: kernel .data and .bss. */ + md.md_index = 1; + md.md_vaddr = trunc_page((uintptr_t)_etext); + md.md_size = round_page((uintptr_t)_end) - md.md_vaddr; + return (&md); + } + switch (prev->md_index) { + case 1: + /* 2nd: msgbuf and tables (see pmap_bootstrap()). */ + md.md_index = 2; + md.md_vaddr = (vm_offset_t)msgbufp->msg_ptr; + md.md_size = round_page(msgbufp->msg_size); + break; + case 2: + /* 3rd: kernel VM. */ + va = prev->md_vaddr + prev->md_size; + /* Find start of next chunk (from va). */ + while (va < virtual_end) { + /* Don't dump the buffer cache. */ + if (va >= kmi.buffer_sva && + va < kmi.buffer_eva) { + va = kmi.buffer_eva; + continue; + } + pvo = moea_pvo_find_va(kernel_pmap, + va & ~ADDR_POFF, NULL); + if (pvo != NULL && + (pvo->pvo_pte.pte.pte_hi & PTE_VALID)) + break; + va += PAGE_SIZE; + } + if (va < virtual_end) { + md.md_vaddr = va; + va += PAGE_SIZE; + /* Find last page in chunk. */ + while (va < virtual_end) { + /* Don't run into the buffer cache. */ + if (va == kmi.buffer_sva) + break; + pvo = moea_pvo_find_va(kernel_pmap, + va & ~ADDR_POFF, NULL); + if (pvo == NULL || + !(pvo->pvo_pte.pte.pte_hi & PTE_VALID)) + break; + va += PAGE_SIZE; + } + md.md_size = va - md.md_vaddr; + break; + } + md.md_index = 3; + /* FALLTHROUGH */ + default: + return (NULL); + } + } else { /* minidumps */ + mem_regions(&pregions, &pregions_sz, + ®ions, ®ions_sz); + + if (prev == NULL) { + /* first physical chunk. */ + md.md_paddr = pregions[0].mr_start; + md.md_size = pregions[0].mr_size; + md.md_vaddr = ~0UL; + md.md_index = 1; + } else if (md.md_index < pregions_sz) { + md.md_paddr = pregions[md.md_index].mr_start; + md.md_size = pregions[md.md_index].mr_size; + md.md_vaddr = ~0UL; + md.md_index++; + } else { + /* There's no next physical chunk. */ + return (NULL); + } + } + + return (&md); +} From owner-svn-src-all@FreeBSD.ORG Wed May 15 20:53:54 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id 2E663342; Wed, 15 May 2013 20:53:54 +0000 (UTC) (envelope-from pfg@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id 20511A82; Wed, 15 May 2013 20:53:54 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.6/8.14.6) with ESMTP id r4FKrrIk099581; Wed, 15 May 2013 20:53:53 GMT (envelope-from pfg@svn.freebsd.org) Received: (from pfg@localhost) by svn.freebsd.org (8.14.6/8.14.5/Submit) id r4FKrrsT099580; Wed, 15 May 2013 20:53:53 GMT (envelope-from pfg@svn.freebsd.org) Message-Id: <201305152053.r4FKrrsT099580@svn.freebsd.org> From: "Pedro F. Giffuni" Date: Wed, 15 May 2013 20:53:53 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org Subject: svn commit: r250676 - stable/9/contrib/gcc X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 15 May 2013 20:53:54 -0000 Author: pfg Date: Wed May 15 20:53:53 2013 New Revision: 250676 URL: http://svnweb.freebsd.org/changeset/base/250676 Log: MFC r250550: Update the gcc43 changelog. The issue solved in r250515 actually originated upstream and was fixed in upstream gcc43 branch in 2006/10/24 (under GPLv2). Register it in the appropriate ChangeLog for reference. Modified: stable/9/contrib/gcc/ChangeLog.gcc43 Directory Properties: stable/9/ (props changed) stable/9/contrib/gcc/ (props changed) Modified: stable/9/contrib/gcc/ChangeLog.gcc43 ============================================================================== --- stable/9/contrib/gcc/ChangeLog.gcc43 Wed May 15 19:58:12 2013 (r250675) +++ stable/9/contrib/gcc/ChangeLog.gcc43 Wed May 15 20:53:53 2013 (r250676) @@ -182,6 +182,10 @@ * doc/invoke.texi: Document -mssse3/-mno-ssse3 switches. +2006-10-22 H.J. Lu + + * config/i386/tmmintrin.h: Remove the duplicated content. + 2006-10-21 Richard Guenther (r117932) PR tree-optimization/3511 From owner-svn-src-all@FreeBSD.ORG Wed May 15 20:59:01 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id 36B004FC; Wed, 15 May 2013 20:59:01 +0000 (UTC) (envelope-from dim@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id 282DDAAC; Wed, 15 May 2013 20:59:01 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.6/8.14.6) with ESMTP id r4FKx13r000641; Wed, 15 May 2013 20:59:01 GMT (envelope-from dim@svn.freebsd.org) Received: (from dim@localhost) by svn.freebsd.org (8.14.6/8.14.5/Submit) id r4FKx1o6000640; Wed, 15 May 2013 20:59:01 GMT (envelope-from dim@svn.freebsd.org) Message-Id: <201305152059.r4FKx1o6000640@svn.freebsd.org> From: Dimitry Andric Date: Wed, 15 May 2013 20:59:01 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org Subject: svn commit: r250677 - in stable: 7/gnu/usr.bin/cc/include 8/gnu/usr.bin/cc/include 9/gnu/usr.bin/cc/include X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 15 May 2013 20:59:01 -0000 Author: dim Date: Wed May 15 20:59:00 2013 New Revision: 250677 URL: http://svnweb.freebsd.org/changeset/base/250677 Log: MFC r250393: When gcc 4.2.0 was imported, the 3DNow intrinsics header was not added to the list of intrinsics headers to install, so belatedly (5 years :) add it. Modified: stable/9/gnu/usr.bin/cc/include/Makefile Directory Properties: stable/9/gnu/usr.bin/cc/include/ (props changed) Changes in other areas also in this revision: Modified: stable/7/gnu/usr.bin/cc/include/Makefile stable/8/gnu/usr.bin/cc/include/Makefile Directory Properties: stable/7/gnu/usr.bin/cc/include/ (props changed) stable/8/gnu/usr.bin/cc/include/ (props changed) Modified: stable/9/gnu/usr.bin/cc/include/Makefile ============================================================================== --- stable/9/gnu/usr.bin/cc/include/Makefile Wed May 15 20:53:53 2013 (r250676) +++ stable/9/gnu/usr.bin/cc/include/Makefile Wed May 15 20:59:00 2013 (r250677) @@ -7,7 +7,8 @@ INCSDIR=${INCLUDEDIR}/gcc/${GCCVER} .PATH: ${GCCDIR}/config/${GCC_CPU} .if ${TARGET_ARCH} == "i386" || ${TARGET_ARCH} == "amd64" -INCS= emmintrin.h mmintrin.h pmmintrin.h tmmintrin.h xmmintrin.h mm_malloc.h +INCS= emmintrin.h mmintrin.h mm3dnow.h pmmintrin.h tmmintrin.h xmmintrin.h \ + mm_malloc.h .elif ${TARGET_ARCH} == "ia64" INCS= ia64intrin.h .elif ${TARGET_ARCH} == "arm" From owner-svn-src-all@FreeBSD.ORG Wed May 15 20:59:01 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id 8CB324FD; Wed, 15 May 2013 20:59:01 +0000 (UTC) (envelope-from dim@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id 7E1A5AAD; Wed, 15 May 2013 20:59:01 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.6/8.14.6) with ESMTP id r4FKx1CX000653; Wed, 15 May 2013 20:59:01 GMT (envelope-from dim@svn.freebsd.org) Received: (from dim@localhost) by svn.freebsd.org (8.14.6/8.14.5/Submit) id r4FKx1tX000652; Wed, 15 May 2013 20:59:01 GMT (envelope-from dim@svn.freebsd.org) Message-Id: <201305152059.r4FKx1tX000652@svn.freebsd.org> From: Dimitry Andric Date: Wed, 15 May 2013 20:59:01 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-8@freebsd.org Subject: svn commit: r250677 - in stable: 7/gnu/usr.bin/cc/include 8/gnu/usr.bin/cc/include 9/gnu/usr.bin/cc/include X-SVN-Group: stable-8 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 15 May 2013 20:59:01 -0000 Author: dim Date: Wed May 15 20:59:00 2013 New Revision: 250677 URL: http://svnweb.freebsd.org/changeset/base/250677 Log: MFC r250393: When gcc 4.2.0 was imported, the 3DNow intrinsics header was not added to the list of intrinsics headers to install, so belatedly (5 years :) add it. Modified: stable/8/gnu/usr.bin/cc/include/Makefile Directory Properties: stable/8/gnu/usr.bin/cc/include/ (props changed) Changes in other areas also in this revision: Modified: stable/7/gnu/usr.bin/cc/include/Makefile stable/9/gnu/usr.bin/cc/include/Makefile Directory Properties: stable/7/gnu/usr.bin/cc/include/ (props changed) stable/9/gnu/usr.bin/cc/include/ (props changed) Modified: stable/8/gnu/usr.bin/cc/include/Makefile ============================================================================== --- stable/8/gnu/usr.bin/cc/include/Makefile Wed May 15 20:53:53 2013 (r250676) +++ stable/8/gnu/usr.bin/cc/include/Makefile Wed May 15 20:59:00 2013 (r250677) @@ -5,7 +5,8 @@ .PATH: ${GCCDIR}/config/${GCC_CPU} .if ${TARGET_ARCH} == "i386" || ${TARGET_ARCH} == "amd64" -INCS= emmintrin.h mmintrin.h pmmintrin.h tmmintrin.h xmmintrin.h mm_malloc.h +INCS= emmintrin.h mmintrin.h mm3dnow.h pmmintrin.h tmmintrin.h xmmintrin.h \ + mm_malloc.h .elif ${TARGET_ARCH} == "ia64" INCS= ia64intrin.h .elif ${TARGET_ARCH} == "arm" From owner-svn-src-all@FreeBSD.ORG Wed May 15 20:59:01 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id E39414FE; Wed, 15 May 2013 20:59:01 +0000 (UTC) (envelope-from dim@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id D4EA9AAE; Wed, 15 May 2013 20:59:01 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.6/8.14.6) with ESMTP id r4FKx1Vt000661; Wed, 15 May 2013 20:59:01 GMT (envelope-from dim@svn.freebsd.org) Received: (from dim@localhost) by svn.freebsd.org (8.14.6/8.14.5/Submit) id r4FKx1cv000660; Wed, 15 May 2013 20:59:01 GMT (envelope-from dim@svn.freebsd.org) Message-Id: <201305152059.r4FKx1cv000660@svn.freebsd.org> From: Dimitry Andric Date: Wed, 15 May 2013 20:59:01 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-7@freebsd.org Subject: svn commit: r250677 - in stable: 7/gnu/usr.bin/cc/include 8/gnu/usr.bin/cc/include 9/gnu/usr.bin/cc/include X-SVN-Group: stable-7 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 15 May 2013 20:59:02 -0000 Author: dim Date: Wed May 15 20:59:00 2013 New Revision: 250677 URL: http://svnweb.freebsd.org/changeset/base/250677 Log: MFC r250393: When gcc 4.2.0 was imported, the 3DNow intrinsics header was not added to the list of intrinsics headers to install, so belatedly (5 years :) add it. Modified: stable/7/gnu/usr.bin/cc/include/Makefile Directory Properties: stable/7/gnu/usr.bin/cc/include/ (props changed) Changes in other areas also in this revision: Modified: stable/8/gnu/usr.bin/cc/include/Makefile stable/9/gnu/usr.bin/cc/include/Makefile Directory Properties: stable/8/gnu/usr.bin/cc/include/ (props changed) stable/9/gnu/usr.bin/cc/include/ (props changed) Modified: stable/7/gnu/usr.bin/cc/include/Makefile ============================================================================== --- stable/7/gnu/usr.bin/cc/include/Makefile Wed May 15 20:53:53 2013 (r250676) +++ stable/7/gnu/usr.bin/cc/include/Makefile Wed May 15 20:59:00 2013 (r250677) @@ -5,7 +5,8 @@ .PATH: ${GCCDIR}/config/${GCC_CPU} .if ${TARGET_ARCH} == "i386" || ${TARGET_ARCH} == "amd64" -INCS= emmintrin.h mmintrin.h pmmintrin.h tmmintrin.h xmmintrin.h mm_malloc.h +INCS= emmintrin.h mmintrin.h mm3dnow.h pmmintrin.h tmmintrin.h xmmintrin.h \ + mm_malloc.h .elif ${TARGET_ARCH} == "ia64" INCS= ia64intrin.h .elif ${TARGET_ARCH} == "arm" From owner-svn-src-all@FreeBSD.ORG Wed May 15 21:02:18 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id AEECEA7F; Wed, 15 May 2013 21:02:18 +0000 (UTC) (envelope-from pluknet@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id A09F0AEA; Wed, 15 May 2013 21:02:18 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.6/8.14.6) with ESMTP id r4FL2IRr003145; Wed, 15 May 2013 21:02:18 GMT (envelope-from pluknet@svn.freebsd.org) Received: (from pluknet@localhost) by svn.freebsd.org (8.14.6/8.14.5/Submit) id r4FL2IEL003144; Wed, 15 May 2013 21:02:18 GMT (envelope-from pluknet@svn.freebsd.org) Message-Id: <201305152102.r4FL2IEL003144@svn.freebsd.org> From: Sergey Kandaurov Date: Wed, 15 May 2013 21:02:18 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org Subject: svn commit: r250678 - stable/9/usr.bin/kdump X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 15 May 2013 21:02:18 -0000 Author: pluknet Date: Wed May 15 21:02:18 2013 New Revision: 250678 URL: http://svnweb.freebsd.org/changeset/base/250678 Log: MFC r246711: o Bring in sync decoding the first nfssvc(2) parameter (flags) with the current definitions location. o Respect numbers in NFSSVC_* (e.g. NFSSVC_V4ROOTEXPORT). Modified: stable/9/usr.bin/kdump/mksubr Directory Properties: stable/9/usr.bin/kdump/ (props changed) Modified: stable/9/usr.bin/kdump/mksubr ============================================================================== --- stable/9/usr.bin/kdump/mksubr Wed May 15 20:59:00 2013 (r250677) +++ stable/9/usr.bin/kdump/mksubr Wed May 15 21:02:18 2013 (r250678) @@ -367,7 +367,7 @@ auto_or_type "thrcreateflagsname" "THR_[ auto_or_type "mlockallname" "MCL_[A-Z]+[[:space:]]+0x[0-9]+" "sys/mman.h" auto_or_type "shmatname" "SHM_[A-Z]+[[:space:]]+[0-9]{6}+" "sys/shm.h" auto_or_type "rforkname" "RF[A-Z]+[[:space:]]+\([0-9]+<<[0-9]+\)" "sys/unistd.h" -auto_or_type "nfssvcname" "NFSSVC_[A-Z]+[[:space:]]+0x[0-9]+" "nfsserver/nfs.h" +auto_or_type "nfssvcname" "NFSSVC_[A-Z0-9]+[[:space:]]+0x[0-9]+" "nfs/nfssvc.h" auto_switch_type "whencename" "SEEK_[A-Z]+[[:space:]]+[0-9]+" "sys/unistd.h" auto_switch_type "rlimitname" "RLIMIT_[A-Z]+[[:space:]]+[0-9]+" "sys/resource.h" From owner-svn-src-all@FreeBSD.ORG Wed May 15 21:05:25 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id C6997C24; Wed, 15 May 2013 21:05:25 +0000 (UTC) (envelope-from pluknet@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id B7D36B08; Wed, 15 May 2013 21:05:25 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.6/8.14.6) with ESMTP id r4FL5PwW003911; Wed, 15 May 2013 21:05:25 GMT (envelope-from pluknet@svn.freebsd.org) Received: (from pluknet@localhost) by svn.freebsd.org (8.14.6/8.14.5/Submit) id r4FL5PYw003910; Wed, 15 May 2013 21:05:25 GMT (envelope-from pluknet@svn.freebsd.org) Message-Id: <201305152105.r4FL5PYw003910@svn.freebsd.org> From: Sergey Kandaurov Date: Wed, 15 May 2013 21:05:25 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-8@freebsd.org Subject: svn commit: r250679 - stable/8/usr.bin/kdump X-SVN-Group: stable-8 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 15 May 2013 21:05:25 -0000 Author: pluknet Date: Wed May 15 21:05:25 2013 New Revision: 250679 URL: http://svnweb.freebsd.org/changeset/base/250679 Log: MFC r246711: o Bring in sync decoding the first nfssvc(2) parameter (flags) with the current definitions location. o Respect numbers in NFSSVC_* (e.g. NFSSVC_V4ROOTEXPORT). Modified: stable/8/usr.bin/kdump/mksubr Directory Properties: stable/8/usr.bin/kdump/ (props changed) Modified: stable/8/usr.bin/kdump/mksubr ============================================================================== --- stable/8/usr.bin/kdump/mksubr Wed May 15 21:02:18 2013 (r250678) +++ stable/8/usr.bin/kdump/mksubr Wed May 15 21:05:25 2013 (r250679) @@ -365,7 +365,7 @@ auto_or_type "thrcreateflagsname" "THR_[ auto_or_type "mlockallname" "MCL_[A-Z]+[[:space:]]+0x[0-9]+" "sys/mman.h" auto_or_type "shmatname" "SHM_[A-Z]+[[:space:]]+[0-9]{6}+" "sys/shm.h" auto_or_type "rforkname" "RF[A-Z]+[[:space:]]+\([0-9]+<<[0-9]+\)" "sys/unistd.h" -auto_or_type "nfssvcname" "NFSSVC_[A-Z]+[[:space:]]+0x[0-9]+" "nfsserver/nfs.h" +auto_or_type "nfssvcname" "NFSSVC_[A-Z0-9]+[[:space:]]+0x[0-9]+" "nfs/nfssvc.h" auto_switch_type "whencename" "SEEK_[A-Z]+[[:space:]]+[0-9]+" "sys/unistd.h" auto_switch_type "rlimitname" "RLIMIT_[A-Z]+[[:space:]]+[0-9]+" "sys/resource.h" From owner-svn-src-all@FreeBSD.ORG Wed May 15 21:16:16 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id C5268113; Wed, 15 May 2013 21:16:16 +0000 (UTC) (envelope-from pluknet@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id B7038BD5; Wed, 15 May 2013 21:16:16 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.6/8.14.6) with ESMTP id r4FLGGLn007875; Wed, 15 May 2013 21:16:16 GMT (envelope-from pluknet@svn.freebsd.org) Received: (from pluknet@localhost) by svn.freebsd.org (8.14.6/8.14.5/Submit) id r4FLGGHR007871; Wed, 15 May 2013 21:16:16 GMT (envelope-from pluknet@svn.freebsd.org) Message-Id: <201305152116.r4FLGGHR007871@svn.freebsd.org> From: Sergey Kandaurov Date: Wed, 15 May 2013 21:16:16 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org Subject: svn commit: r250681 - stable/9/lib/libc/gen X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 15 May 2013 21:16:16 -0000 Author: pluknet Date: Wed May 15 21:16:16 2013 New Revision: 250681 URL: http://svnweb.freebsd.org/changeset/base/250681 Log: MFC r248250-248251: - Add the getcontextx prototype to SYNOPSIS. - Link getcontextx(3) to getcontext(3). Modified: stable/9/lib/libc/gen/Makefile.inc stable/9/lib/libc/gen/getcontext.3 Directory Properties: stable/9/lib/libc/ (props changed) Modified: stable/9/lib/libc/gen/Makefile.inc ============================================================================== --- stable/9/lib/libc/gen/Makefile.inc Wed May 15 21:08:51 2013 (r250680) +++ stable/9/lib/libc/gen/Makefile.inc Wed May 15 21:16:16 2013 (r250681) @@ -120,6 +120,7 @@ MLINKS+=getcap.3 cgetcap.3 getcap.3 cget getcap.3 cgetnum.3 getcap.3 cgetset.3 getcap.3 cgetstr.3 \ getcap.3 cgetustr.3 MLINKS+=getcwd.3 getwd.3 +MLINKS+=getcontext.3 getcontextx.3 MLINKS+=getcontext.3 setcontext.3 MLINKS+=getdomainname.3 setdomainname.3 MLINKS+=getfsent.3 endfsent.3 getfsent.3 getfsfile.3 getfsent.3 getfsspec.3 \ Modified: stable/9/lib/libc/gen/getcontext.3 ============================================================================== --- stable/9/lib/libc/gen/getcontext.3 Wed May 15 21:08:51 2013 (r250680) +++ stable/9/lib/libc/gen/getcontext.3 Wed May 15 21:16:16 2013 (r250681) @@ -35,7 +35,7 @@ .\" .\" $FreeBSD$ .\" -.Dd December 26, 2011 +.Dd March 13, 2013 .Dt GETCONTEXT 3 .Os .Sh NAME @@ -47,6 +47,8 @@ .In ucontext.h .Ft int .Fn getcontext "ucontext_t *ucp" +.Ft ucontext_t * +.Fn getcontextx "void" .Ft int .Fn setcontext "const ucontext_t *ucp" .Sh DESCRIPTION From owner-svn-src-all@FreeBSD.ORG Wed May 15 21:19:06 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id F014737A; Wed, 15 May 2013 21:19:05 +0000 (UTC) (envelope-from pluknet@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id E20FCBF0; Wed, 15 May 2013 21:19:05 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.6/8.14.6) with ESMTP id r4FLJ5fs008486; Wed, 15 May 2013 21:19:05 GMT (envelope-from pluknet@svn.freebsd.org) Received: (from pluknet@localhost) by svn.freebsd.org (8.14.6/8.14.5/Submit) id r4FLJ5V8008484; Wed, 15 May 2013 21:19:05 GMT (envelope-from pluknet@svn.freebsd.org) Message-Id: <201305152119.r4FLJ5V8008484@svn.freebsd.org> From: Sergey Kandaurov Date: Wed, 15 May 2013 21:19:05 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-8@freebsd.org Subject: svn commit: r250682 - stable/8/lib/libc/gen X-SVN-Group: stable-8 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 15 May 2013 21:19:06 -0000 Author: pluknet Date: Wed May 15 21:19:05 2013 New Revision: 250682 URL: http://svnweb.freebsd.org/changeset/base/250682 Log: MFC r248250-248251: - Add the getcontextx prototype to SYNOPSIS. - Link getcontextx(3) to getcontext(3). Modified: stable/8/lib/libc/gen/Makefile.inc stable/8/lib/libc/gen/getcontext.3 Directory Properties: stable/8/lib/libc/ (props changed) Modified: stable/8/lib/libc/gen/Makefile.inc ============================================================================== --- stable/8/lib/libc/gen/Makefile.inc Wed May 15 21:16:16 2013 (r250681) +++ stable/8/lib/libc/gen/Makefile.inc Wed May 15 21:19:05 2013 (r250682) @@ -106,6 +106,7 @@ MLINKS+=getcap.3 cgetcap.3 getcap.3 cget getcap.3 cgetnum.3 getcap.3 cgetset.3 getcap.3 cgetstr.3 \ getcap.3 cgetustr.3 MLINKS+=getcwd.3 getwd.3 +MLINKS+=getcontext.3 getcontextx.3 MLINKS+=getcontext.3 setcontext.3 MLINKS+=getdomainname.3 setdomainname.3 MLINKS+=getfsent.3 endfsent.3 getfsent.3 getfsfile.3 getfsent.3 getfsspec.3 \ Modified: stable/8/lib/libc/gen/getcontext.3 ============================================================================== --- stable/8/lib/libc/gen/getcontext.3 Wed May 15 21:16:16 2013 (r250681) +++ stable/8/lib/libc/gen/getcontext.3 Wed May 15 21:19:05 2013 (r250682) @@ -35,7 +35,7 @@ .\" .\" $FreeBSD$ .\" -.Dd December 26, 2011 +.Dd March 13, 2013 .Dt GETCONTEXT 3 .Os .Sh NAME @@ -47,6 +47,8 @@ .In ucontext.h .Ft int .Fn getcontext "ucontext_t *ucp" +.Ft ucontext_t * +.Fn getcontextx "void" .Ft int .Fn setcontext "const ucontext_t *ucp" .Sh DESCRIPTION From owner-svn-src-all@FreeBSD.ORG Wed May 15 21:35:23 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id 2C55075D; Wed, 15 May 2013 21:35:23 +0000 (UTC) (envelope-from pluknet@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id 01E57D0D; Wed, 15 May 2013 21:35:23 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.6/8.14.6) with ESMTP id r4FLZMr9014779; Wed, 15 May 2013 21:35:22 GMT (envelope-from pluknet@svn.freebsd.org) Received: (from pluknet@localhost) by svn.freebsd.org (8.14.6/8.14.5/Submit) id r4FLZMgu014777; Wed, 15 May 2013 21:35:22 GMT (envelope-from pluknet@svn.freebsd.org) Message-Id: <201305152135.r4FLZMgu014777@svn.freebsd.org> From: Sergey Kandaurov Date: Wed, 15 May 2013 21:35:22 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org Subject: svn commit: r250683 - stable/9/sys/dev/bktr X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 15 May 2013 21:35:23 -0000 Author: pluknet Date: Wed May 15 21:35:22 2013 New Revision: 250683 URL: http://svnweb.freebsd.org/changeset/base/250683 Log: MFC r250088: Pass a format string to kproc_create() [1] and thus fix the build with -DBKTR_NEW_MSP34XX_DRIVER and -Wformat-security. Modified: stable/9/sys/dev/bktr/msp34xx.c Directory Properties: stable/9/sys/ (props changed) stable/9/sys/dev/ (props changed) Modified: stable/9/sys/dev/bktr/msp34xx.c ============================================================================== --- stable/9/sys/dev/bktr/msp34xx.c Wed May 15 21:19:05 2013 (r250682) +++ stable/9/sys/dev/bktr/msp34xx.c Wed May 15 21:35:22 2013 (r250683) @@ -134,7 +134,6 @@ struct msp3400c { /* thread */ struct proc *kthread; - char *threaddesc; int active,restart,rmmod; @@ -1147,12 +1146,6 @@ int msp_attach(bktr_ptr_t bktr) msp->bass = 32768; msp->treble = 32768; msp->input = -1; - msp->threaddesc = malloc(15 * sizeof(char), M_DEVBUF, M_NOWAIT); - if (msp->threaddesc == NULL) { - free(msp, M_DEVBUF); - return ENOMEM; - } - snprintf(msp->threaddesc, 14, "%s_msp34xx_thread", bktr->bktr_xname); for (i = 0; i < DFP_COUNT; i++) msp->dfp_regs[i] = -1; @@ -1163,7 +1156,6 @@ int msp_attach(bktr_ptr_t bktr) if (-1 != rev1) rev2 = msp3400c_read(bktr, I2C_MSP3400C_DFP, 0x1f); if ((-1 == rev1) || (0 == rev1 && 0 == rev2)) { - free(msp->threaddesc, M_DEVBUF); free(msp, M_DEVBUF); bktr->msp3400c_info = NULL; printf("%s: msp3400: error while reading chip version\n", bktr_name(bktr)); @@ -1199,10 +1191,9 @@ int msp_attach(bktr_ptr_t bktr) /* startup control thread */ err = kproc_create(msp->simple ? msp3410d_thread : msp3400c_thread, bktr, &msp->kthread, (RFFDG | RFPROC), 0, - msp->threaddesc); + "%s_msp34xx_thread", bktr->bktr_xname); if (err) { printf("%s: Error returned by kproc_create: %d", bktr_name(bktr), err); - free(msp->threaddesc, M_DEVBUF); free(msp, M_DEVBUF); bktr->msp3400c_info = NULL; return ENXIO; From owner-svn-src-all@FreeBSD.ORG Wed May 15 21:37:09 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id 15F8F975; Wed, 15 May 2013 21:37:09 +0000 (UTC) (envelope-from pluknet@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id DABD8D2B; Wed, 15 May 2013 21:37:08 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.6/8.14.6) with ESMTP id r4FLb8MZ015138; Wed, 15 May 2013 21:37:08 GMT (envelope-from pluknet@svn.freebsd.org) Received: (from pluknet@localhost) by svn.freebsd.org (8.14.6/8.14.5/Submit) id r4FLb8U8015137; Wed, 15 May 2013 21:37:08 GMT (envelope-from pluknet@svn.freebsd.org) Message-Id: <201305152137.r4FLb8U8015137@svn.freebsd.org> From: Sergey Kandaurov Date: Wed, 15 May 2013 21:37:08 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-8@freebsd.org Subject: svn commit: r250684 - stable/8/sys/dev/bktr X-SVN-Group: stable-8 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 15 May 2013 21:37:09 -0000 Author: pluknet Date: Wed May 15 21:37:08 2013 New Revision: 250684 URL: http://svnweb.freebsd.org/changeset/base/250684 Log: MFC r250088: Pass a format string to kproc_create() [1] and thus fix the build with -DBKTR_NEW_MSP34XX_DRIVER and -Wformat-security. PR: kern/175546 Modified: stable/8/sys/dev/bktr/msp34xx.c Directory Properties: stable/8/sys/ (props changed) stable/8/sys/dev/ (props changed) stable/8/sys/dev/bktr/ (props changed) Modified: stable/8/sys/dev/bktr/msp34xx.c ============================================================================== --- stable/8/sys/dev/bktr/msp34xx.c Wed May 15 21:35:22 2013 (r250683) +++ stable/8/sys/dev/bktr/msp34xx.c Wed May 15 21:37:08 2013 (r250684) @@ -134,7 +134,6 @@ struct msp3400c { /* thread */ struct proc *kthread; - char *threaddesc; int active,restart,rmmod; @@ -1147,12 +1146,6 @@ int msp_attach(bktr_ptr_t bktr) msp->bass = 32768; msp->treble = 32768; msp->input = -1; - msp->threaddesc = malloc(15 * sizeof(char), M_DEVBUF, M_NOWAIT); - if (msp->threaddesc == NULL) { - free(msp, M_DEVBUF); - return ENOMEM; - } - snprintf(msp->threaddesc, 14, "%s_msp34xx_thread", bktr->bktr_xname); for (i = 0; i < DFP_COUNT; i++) msp->dfp_regs[i] = -1; @@ -1163,7 +1156,6 @@ int msp_attach(bktr_ptr_t bktr) if (-1 != rev1) rev2 = msp3400c_read(bktr, I2C_MSP3400C_DFP, 0x1f); if ((-1 == rev1) || (0 == rev1 && 0 == rev2)) { - free(msp->threaddesc, M_DEVBUF); free(msp, M_DEVBUF); bktr->msp3400c_info = NULL; printf("%s: msp3400: error while reading chip version\n", bktr_name(bktr)); @@ -1199,10 +1191,9 @@ int msp_attach(bktr_ptr_t bktr) /* startup control thread */ err = kproc_create(msp->simple ? msp3410d_thread : msp3400c_thread, bktr, &msp->kthread, (RFFDG | RFPROC), 0, - msp->threaddesc); + "%s_msp34xx_thread", bktr->bktr_xname); if (err) { printf("%s: Error returned by kproc_create: %d", bktr_name(bktr), err); - free(msp->threaddesc, M_DEVBUF); free(msp, M_DEVBUF); bktr->msp3400c_info = NULL; return ENXIO; From owner-svn-src-all@FreeBSD.ORG Wed May 15 22:56:24 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id E945B639; Wed, 15 May 2013 22:56:24 +0000 (UTC) (envelope-from markj@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id CAFD8FB6; Wed, 15 May 2013 22:56:24 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.6/8.14.6) with ESMTP id r4FMuO3J042396; Wed, 15 May 2013 22:56:24 GMT (envelope-from markj@svn.freebsd.org) Received: (from markj@localhost) by svn.freebsd.org (8.14.6/8.14.5/Submit) id r4FMuOl1042394; Wed, 15 May 2013 22:56:24 GMT (envelope-from markj@svn.freebsd.org) Message-Id: <201305152256.r4FMuOl1042394@svn.freebsd.org> From: Mark Johnston Date: Wed, 15 May 2013 22:56:24 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r250685 - head/cddl/contrib/opensolaris/cmd/dtrace/test/tst/common/ip X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 15 May 2013 22:56:25 -0000 Author: markj Date: Wed May 15 22:56:24 2013 New Revision: 250685 URL: http://svnweb.freebsd.org/changeset/base/250685 Log: Convert a couple of helper scripts used to test the ip provider to work on FreeBSD. In the IPv6 case, try each interface before returning an error; each IPv6-enabled interface will have a link-local address even if the link isn't up. MFC after: 1 week Modified: head/cddl/contrib/opensolaris/cmd/dtrace/test/tst/common/ip/get.ipv4remote.pl head/cddl/contrib/opensolaris/cmd/dtrace/test/tst/common/ip/get.ipv6remote.pl Modified: head/cddl/contrib/opensolaris/cmd/dtrace/test/tst/common/ip/get.ipv4remote.pl ============================================================================== --- head/cddl/contrib/opensolaris/cmd/dtrace/test/tst/common/ip/get.ipv4remote.pl Wed May 15 21:37:08 2013 (r250684) +++ head/cddl/contrib/opensolaris/cmd/dtrace/test/tst/common/ip/get.ipv4remote.pl Wed May 15 22:56:24 2013 (r250685) @@ -73,7 +73,7 @@ die "Could not determine local IP addres # Find the first remote host that responds to an icmp echo, # which isn't a local address. # -open PING, "/sbin/ping -ns $Broadcast{$local} 56 $MAXHOSTS |" or +open PING, "/sbin/ping -n -s 56 -c $MAXHOSTS $Broadcast{$local} |" or die "Couldn't run ping: $!\n"; while () { if (/bytes from (.*): / and not defined $Broadcast{$1}) { Modified: head/cddl/contrib/opensolaris/cmd/dtrace/test/tst/common/ip/get.ipv6remote.pl ============================================================================== --- head/cddl/contrib/opensolaris/cmd/dtrace/test/tst/common/ip/get.ipv6remote.pl Wed May 15 21:37:08 2013 (r250684) +++ head/cddl/contrib/opensolaris/cmd/dtrace/test/tst/common/ip/get.ipv6remote.pl Wed May 15 22:56:24 2013 (r250685) @@ -48,7 +48,9 @@ my $MULTICAST = "FF02::1"; # IPv6 multi # my $local = ""; my $remote = ""; +my $interf = ""; my %Local; +my %Addr; my $up; open IFCONFIG, '/sbin/ifconfig -a inet6 |' or die "Couldn't run ifconfig: $!\n"; @@ -59,27 +61,34 @@ while () { $up = 1 if /^[a-z].*) { - if (/bytes from (.*): / and not defined $Local{$1}) { - $remote = $1; - last; +foreach $interf (split(' ', `ifconfig -l -u inet6`)) { + next if $interf =~ /lo[0-9]+/; + open PING, "/sbin/ping6 -n -s 56 -c $MAXHOSTS $MULTICAST\%$interf |" or next; + while () { + if (/bytes from (.*), / and not defined $Local{$1}) { + $remote = $1; + $local = $Addr{$interf}; + last; + } } } close PING; From owner-svn-src-all@FreeBSD.ORG Thu May 16 00:52:09 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id 12B18696; Thu, 16 May 2013 00:52:09 +0000 (UTC) (envelope-from rmacklem@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id DFB9660E; Thu, 16 May 2013 00:52:08 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.6/8.14.6) with ESMTP id r4G0q805083221; Thu, 16 May 2013 00:52:08 GMT (envelope-from rmacklem@svn.freebsd.org) Received: (from rmacklem@localhost) by svn.freebsd.org (8.14.6/8.14.5/Submit) id r4G0q8EW083220; Thu, 16 May 2013 00:52:08 GMT (envelope-from rmacklem@svn.freebsd.org) Message-Id: <201305160052.r4G0q8EW083220@svn.freebsd.org> From: Rick Macklem Date: Thu, 16 May 2013 00:52:08 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org Subject: svn commit: r250689 - stable/9/usr.sbin/gssd X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 16 May 2013 00:52:09 -0000 Author: rmacklem Date: Thu May 16 00:52:08 2013 New Revision: 250689 URL: http://svnweb.freebsd.org/changeset/base/250689 Log: MFC: r250176 Fix the getpwuid_r() call in the gssd daemon so that it handles the ERANGE error return case. Without this fix, authentication of users for certain system setups could fail unexpectedly. Modified: stable/9/usr.sbin/gssd/gssd.c Directory Properties: stable/9/usr.sbin/gssd/ (props changed) Modified: stable/9/usr.sbin/gssd/gssd.c ============================================================================== --- stable/9/usr.sbin/gssd/gssd.c Thu May 16 00:18:25 2013 (r250688) +++ stable/9/usr.sbin/gssd/gssd.c Thu May 16 00:52:08 2013 (r250689) @@ -37,6 +37,7 @@ __FBSDID("$FreeBSD$"); #include #include #include +#include #ifndef WITHOUT_KERBEROS #include #endif @@ -557,8 +558,11 @@ gssd_pname_to_uid_1_svc(pname_to_uid_arg { gss_name_t name = gssd_find_resource(argp->pname); uid_t uid; - char buf[128]; + char buf[1024], *bufp; struct passwd pwd, *pw; + size_t buflen; + int error; + static size_t buflen_hint = 1024; memset(result, 0, sizeof(*result)); if (name) { @@ -567,7 +571,24 @@ gssd_pname_to_uid_1_svc(pname_to_uid_arg name, argp->mech, &uid); if (result->major_status == GSS_S_COMPLETE) { result->uid = uid; - getpwuid_r(uid, &pwd, buf, sizeof(buf), &pw); + buflen = buflen_hint; + for (;;) { + pw = NULL; + bufp = buf; + if (buflen > sizeof(buf)) + bufp = malloc(buflen); + if (bufp == NULL) + break; + error = getpwuid_r(uid, &pwd, bufp, buflen, + &pw); + if (error != ERANGE) + break; + if (buflen > sizeof(buf)) + free(bufp); + buflen += 1024; + if (buflen > buflen_hint) + buflen_hint = buflen; + } if (pw) { int len = NGRPS; int groups[NGRPS]; @@ -584,6 +605,8 @@ gssd_pname_to_uid_1_svc(pname_to_uid_arg result->gidlist.gidlist_len = 0; result->gidlist.gidlist_val = NULL; } + if (bufp != NULL && buflen > sizeof(buf)) + free(bufp); } } else { result->major_status = GSS_S_BAD_NAME; From owner-svn-src-all@FreeBSD.ORG Thu May 16 00:56:42 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id 7CD5E842; Thu, 16 May 2013 00:56:42 +0000 (UTC) (envelope-from rmacklem@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id 53861630; Thu, 16 May 2013 00:56:42 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.6/8.14.6) with ESMTP id r4G0ugaZ084079; Thu, 16 May 2013 00:56:42 GMT (envelope-from rmacklem@svn.freebsd.org) Received: (from rmacklem@localhost) by svn.freebsd.org (8.14.6/8.14.5/Submit) id r4G0ugQ8084078; Thu, 16 May 2013 00:56:42 GMT (envelope-from rmacklem@svn.freebsd.org) Message-Id: <201305160056.r4G0ugQ8084078@svn.freebsd.org> From: Rick Macklem Date: Thu, 16 May 2013 00:56:42 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org Subject: svn commit: r250690 - stable/9/kerberos5/lib/libgssapi_krb5 X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 16 May 2013 00:56:42 -0000 Author: rmacklem Date: Thu May 16 00:56:41 2013 New Revision: 250690 URL: http://svnweb.freebsd.org/changeset/base/250690 Log: MFC: r250177 Fix the getpwnam_r() call in the pname_to_uid() kerberos library function so that it handles the ERANGE error return case. Without this fix, authentication of users for certain system setups could fail unexpectedly. Modified: stable/9/kerberos5/lib/libgssapi_krb5/pname_to_uid.c Directory Properties: stable/9/kerberos5/lib/libgssapi_krb5/ (props changed) Modified: stable/9/kerberos5/lib/libgssapi_krb5/pname_to_uid.c ============================================================================== --- stable/9/kerberos5/lib/libgssapi_krb5/pname_to_uid.c Thu May 16 00:52:08 2013 (r250689) +++ stable/9/kerberos5/lib/libgssapi_krb5/pname_to_uid.c Thu May 16 00:56:41 2013 (r250690) @@ -26,6 +26,7 @@ */ /* $FreeBSD$ */ +#include #include #include "krb5/gsskrb5_locl.h" @@ -37,8 +38,12 @@ _gsskrb5_pname_to_uid(OM_uint32 *minor_s krb5_context context; krb5_const_principal name = (krb5_const_principal) pname; krb5_error_code kret; - char lname[MAXLOGNAME + 1], buf[128]; + char lname[MAXLOGNAME + 1], buf[1024], *bufp; struct passwd pwd, *pw; + size_t buflen; + int error; + OM_uint32 ret; + static size_t buflen_hint = 1024; GSSAPI_KRB5_INIT (&context); @@ -49,11 +54,30 @@ _gsskrb5_pname_to_uid(OM_uint32 *minor_s } *minor_status = 0; - getpwnam_r(lname, &pwd, buf, sizeof(buf), &pw); + buflen = buflen_hint; + for (;;) { + pw = NULL; + bufp = buf; + if (buflen > sizeof(buf)) + bufp = malloc(buflen); + if (bufp == NULL) + break; + error = getpwnam_r(lname, &pwd, bufp, buflen, &pw); + if (error != ERANGE) + break; + if (buflen > sizeof(buf)) + free(bufp); + buflen += 1024; + if (buflen > buflen_hint) + buflen_hint = buflen; + } if (pw) { *uidp = pw->pw_uid; - return (GSS_S_COMPLETE); + ret = GSS_S_COMPLETE; } else { - return (GSS_S_FAILURE); + ret = GSS_S_FAILURE; } + if (bufp != NULL && buflen > sizeof(buf)) + free(bufp); + return (ret); } From owner-svn-src-all@FreeBSD.ORG Thu May 16 03:01:05 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id 196C4C98; Thu, 16 May 2013 03:01:05 +0000 (UTC) (envelope-from davidxu@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id 0BEF39F5; Thu, 16 May 2013 03:01:05 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.6/8.14.6) with ESMTP id r4G314jg029823; Thu, 16 May 2013 03:01:04 GMT (envelope-from davidxu@svn.freebsd.org) Received: (from davidxu@localhost) by svn.freebsd.org (8.14.6/8.14.5/Submit) id r4G314dK029822; Thu, 16 May 2013 03:01:04 GMT (envelope-from davidxu@svn.freebsd.org) Message-Id: <201305160301.r4G314dK029822@svn.freebsd.org> From: David Xu Date: Thu, 16 May 2013 03:01:04 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r250691 - head/lib/libthr/thread X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 16 May 2013 03:01:05 -0000 Author: davidxu Date: Thu May 16 03:01:04 2013 New Revision: 250691 URL: http://svnweb.freebsd.org/changeset/base/250691 Log: Return one-based key so that user can check if the key is ever allocated in the first place. Initial patch submitted by: phk Modified: head/lib/libthr/thread/thr_spec.c Modified: head/lib/libthr/thread/thr_spec.c ============================================================================== --- head/lib/libthr/thread/thr_spec.c Thu May 16 00:56:41 2013 (r250690) +++ head/lib/libthr/thread/thr_spec.c Thu May 16 03:01:04 2013 (r250691) @@ -70,7 +70,7 @@ _pthread_key_create(pthread_key_t *key, /* Unlock the key table: */ THR_LOCK_RELEASE(curthread, &_keytable_lock); - *key = i; + *key = i + 1; return (0); } @@ -81,9 +81,10 @@ _pthread_key_create(pthread_key_t *key, } int -_pthread_key_delete(pthread_key_t key) +_pthread_key_delete(pthread_key_t userkey) { struct pthread *curthread = _get_curthread(); + int key = userkey - 1; int ret = 0; if ((unsigned int)key < PTHREAD_KEYS_MAX) { @@ -178,9 +179,10 @@ pthread_key_allocate_data(void) } int -_pthread_setspecific(pthread_key_t key, const void *value) +_pthread_setspecific(pthread_key_t userkey, const void *value) { struct pthread *pthread; + pthread_key_t key = userkey - 1; int ret = 0; /* Point to the running thread: */ @@ -209,9 +211,10 @@ _pthread_setspecific(pthread_key_t key, } void * -_pthread_getspecific(pthread_key_t key) +_pthread_getspecific(pthread_key_t userkey) { struct pthread *pthread; + pthread_key_t key = userkey - 1; const void *data; /* Point to the running thread: */ From owner-svn-src-all@FreeBSD.ORG Thu May 16 03:51:00 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id BA5E0543; Thu, 16 May 2013 03:51:00 +0000 (UTC) (envelope-from rpaulo@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id ACF20D05; Thu, 16 May 2013 03:51:00 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.6/8.14.6) with ESMTP id r4G3p0VY047405; Thu, 16 May 2013 03:51:00 GMT (envelope-from rpaulo@svn.freebsd.org) Received: (from rpaulo@localhost) by svn.freebsd.org (8.14.6/8.14.5/Submit) id r4G3p0uu047404; Thu, 16 May 2013 03:51:00 GMT (envelope-from rpaulo@svn.freebsd.org) Message-Id: <201305160351.r4G3p0uu047404@svn.freebsd.org> From: Rui Paulo Date: Thu, 16 May 2013 03:51:00 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r250692 - head/sys/arm/conf X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 16 May 2013 03:51:00 -0000 Author: rpaulo Date: Thu May 16 03:51:00 2013 New Revision: 250692 URL: http://svnweb.freebsd.org/changeset/base/250692 Log: Add a kernel config file for the BeableBone Black SoC. Added: head/sys/arm/conf/BEAGLEBONE-BLACK (contents, props changed) Added: head/sys/arm/conf/BEAGLEBONE-BLACK ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ head/sys/arm/conf/BEAGLEBONE-BLACK Thu May 16 03:51:00 2013 (r250692) @@ -0,0 +1,127 @@ +# BEAGLEBONE-BLACK -- Custom configuration for the BeagleBone Black ARM +# development platform, check out http://www.beagleboard.org/black +# +# For more information on this file, please read the handbook section on +# Kernel Configuration Files: +# +# http://www.FreeBSD.org/doc/en_US.ISO8859-1/books/handbook/kernelconfig-config.html +# +# The handbook is also available locally in /usr/share/doc/handbook +# if you've installed the doc distribution, otherwise always see the +# FreeBSD World Wide Web server (http://www.FreeBSD.org/) for the +# latest information. +# +# An exhaustive list of options and more detailed explanations of the +# device lines is also present in the ../../conf/NOTES and NOTES files. +# If you are in doubt as to the purpose or necessity of a line, check first +# in NOTES. +# +# $FreeBSD$ + +ident BEAGLEBONE-BLACK + +include "../ti/am335x/std.beaglebone" + +makeoptions MODULES_OVERRIDE="" +makeoptions WITHOUT_MODULES="ahc" + +options HZ=100 +options SCHED_4BSD #4BSD scheduler +options INET #InterNETworking +options INET6 #IPv6 communications protocols +options FFS #Berkeley Fast Filesystem +options SOFTUPDATES #Enable FFS soft updates support +options UFS_ACL #Support for access control lists +options UFS_DIRHASH #Improve performance on big directories +options MSDOSFS #MSDOS Filesystem +options CD9660 #ISO 9660 Filesystem +options PROCFS #Process filesystem (requires PSEUDOFS) +options PSEUDOFS #Pseudo-filesystem framework +options TMPFS #Efficient memory filesystem +options COMPAT_43 #Compatible with BSD 4.3 [KEEP THIS!] +options SCSI_DELAY=5000 #Delay (in ms) before probing SCSI +options KTRACE #ktrace(1) support +options SYSVSHM #SYSV-style shared memory +options SYSVMSG #SYSV-style message queues +options SYSVSEM #SYSV-style semaphores +options _KPOSIX_PRIORITY_SCHEDULING #Posix P1003_1B real-time extensions +options KBD_INSTALL_CDEV # install a CDEV entry in /dev +options PREEMPTION +options FREEBSD_BOOT_LOADER + +# Debugging +makeoptions DEBUG=-g #Build kernel with gdb(1) debug symbols +options BREAK_TO_DEBUGGER +#options VERBOSE_SYSINIT #Enable verbose sysinit messages +options KDB +options DDB #Enable the kernel debugger +options INVARIANTS #Enable calls of extra sanity checking +options INVARIANT_SUPPORT #Extra sanity checks of internal structures, required by INVARIANTS +options WITNESS #Enable checks to detect deadlocks and cycles +options WITNESS_SKIPSPIN #Don't run witness on spinlocks for speed +#options DIAGNOSTIC + +# NFS support +options NFSCL +#options NFSD +options NFSLOCKD + +# Uncomment this for NFS root +#options NFS_ROOT #NFS usable as /, requires NFSCL +#options BOOTP_NFSROOT +#options BOOTP_COMPAT +#options BOOTP +#options BOOTP_NFSV3 +#options BOOTP_WIRED_TO=cpsw0 + + +# MMC/SD/SDIO card slot support +device mmc # mmc/sd bus +device mmcsd # mmc/sd flash cards + +# Boot device is 2nd slice on MMC/SD card +options ROOTDEVNAME=\"ufs:mmcsd0s2\" + +# Console and misc +device uart +device uart_ns8250 +device pty +device snp +device md +device random # Entropy device + +# I2C support +device iicbus +device iic +device ti_i2c +device am335x_pmic # AM335x Power Management IC (TPC65217) + +# GPIO +device gpio + +# USB support +device usb +options USB_DEBUG +#options USB_REQ_DEBUG +#options USB_VERBOSE +device musb +device umass +device scbus # SCSI bus (required for SCSI) +device da # Direct Access (disks) + +# Ethernet +device loop +device ether +device mii +device smscphy +device cpsw +device bpf + +# USB ethernet support, requires miibus +device miibus +device axe # ASIX Electronics USB Ethernet + +# Flattened Device Tree +options FDT +options FDT_DTB_STATIC +makeoptions FDT_DTS_FILE=beaglebone-black.dts From owner-svn-src-all@FreeBSD.ORG Thu May 16 05:16:58 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id A9CF7DB7; Thu, 16 May 2013 05:16:58 +0000 (UTC) (envelope-from hiren@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id 81959EE5; Thu, 16 May 2013 05:16:58 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.6/8.14.6) with ESMTP id r4G5GvZR076412; Thu, 16 May 2013 05:16:57 GMT (envelope-from hiren@svn.freebsd.org) Received: (from hiren@localhost) by svn.freebsd.org (8.14.6/8.14.5/Submit) id r4G5Gvv8076406; Thu, 16 May 2013 05:16:57 GMT (envelope-from hiren@svn.freebsd.org) Message-Id: <201305160516.r4G5Gvv8076406@svn.freebsd.org> From: Hiren Panchasara Date: Thu, 16 May 2013 05:16:57 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r250693 - head/contrib/libpcap X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 16 May 2013 05:16:58 -0000 Author: hiren Date: Thu May 16 05:16:56 2013 New Revision: 250693 URL: http://svnweb.freebsd.org/changeset/base/250693 Log: Add tcp header flags ECE and CWR defined in RFC 3168. PR: 140349 Submitted by: Alan Amesbury (earlier version) Reviewed by: delphij Approved by: sbruno (mentor) Modified: head/contrib/libpcap/pcap-filter.manmisc head/contrib/libpcap/pcap-filter.manmisc.in head/contrib/libpcap/scanner.l Modified: head/contrib/libpcap/pcap-filter.manmisc ============================================================================== --- head/contrib/libpcap/pcap-filter.manmisc Thu May 16 03:51:00 2013 (r250692) +++ head/contrib/libpcap/pcap-filter.manmisc Thu May 16 05:16:56 2013 (r250693) @@ -783,7 +783,8 @@ The following ICMP type field values are The following TCP flags field values are available: \fBtcp-fin\fP, \fBtcp-syn\fP, \fBtcp-rst\fP, \fBtcp-push\fP, -\fBtcp-ack\fP, \fBtcp-urg\fP. +\fBtcp-ack\fP, \fBtcp-urg\fP, \fBtcp-ece\fP, +\fBtcp-cwr\fP. .LP Primitives may be combined using: .IP Modified: head/contrib/libpcap/pcap-filter.manmisc.in ============================================================================== --- head/contrib/libpcap/pcap-filter.manmisc.in Thu May 16 03:51:00 2013 (r250692) +++ head/contrib/libpcap/pcap-filter.manmisc.in Thu May 16 05:16:56 2013 (r250693) @@ -783,7 +783,8 @@ The following ICMP type field values are The following TCP flags field values are available: \fBtcp-fin\fP, \fBtcp-syn\fP, \fBtcp-rst\fP, \fBtcp-push\fP, -\fBtcp-ack\fP, \fBtcp-urg\fP. +\fBtcp-ack\fP, \fBtcp-urg\fP, \fBtcp-ece\fP, +\fBtcp-cwr\fP. .LP Primitives may be combined using: .IP Modified: head/contrib/libpcap/scanner.l ============================================================================== --- head/contrib/libpcap/scanner.l Thu May 16 03:51:00 2013 (r250692) +++ head/contrib/libpcap/scanner.l Thu May 16 05:16:56 2013 (r250693) @@ -385,6 +385,8 @@ tcp-rst { yylval.i = 0x04; return NUM; tcp-push { yylval.i = 0x08; return NUM; } tcp-ack { yylval.i = 0x10; return NUM; } tcp-urg { yylval.i = 0x20; return NUM; } +tcp-ece { yylval.i = 0x40; return NUM; } +tcp-cwr { yylval.i = 0x80; return NUM; } [A-Za-z0-9]([-_.A-Za-z0-9]*[.A-Za-z0-9])? { yylval.s = sdup((char *)yytext); return ID; } "\\"[^ !()\n\t]+ { yylval.s = sdup((char *)yytext + 1); return ID; } From owner-svn-src-all@FreeBSD.ORG Thu May 16 05:21:52 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id 2F810F95; Thu, 16 May 2013 05:21:52 +0000 (UTC) (envelope-from yaneurabeya@gmail.com) Received: from mail-ie0-x232.google.com (mail-ie0-x232.google.com [IPv6:2607:f8b0:4001:c03::232]) by mx1.freebsd.org (Postfix) with ESMTP id DB89BF03; Thu, 16 May 2013 05:21:51 +0000 (UTC) Received: by mail-ie0-f178.google.com with SMTP id b11so5707612iee.9 for ; Wed, 15 May 2013 22:21:51 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=x-received:references:mime-version:in-reply-to:content-type :content-transfer-encoding:message-id:cc:x-mailer:from:subject:date :to; bh=BwZ+jFWS2SCtKOxTrqndaHGl/xyh3oY1Zv+PO5xx9Ws=; b=b6yN0o+BWYUJMrhvKCsqUPOajm6t+IU4Cffsrvcntj5V4e4T8nqtTOkVYIe/5vcFfa 6rsDFIAsQA6ZY+Prf2Kp6Sn9gnR5LJKD3uo0e+shl5C0SAeNqM6NUulct4r8Dt8TEjOR sxhgf3il7Vs2ZvApqil+4brxoebXKLhb/2EJMil+kdEoHLpjLL/BKsSjxCPlCcPGY5HS 7eC4cGbgPe4ub7la29pwTp8CxwXvmoyCCu0KWxjd3w5pGFPw6cnLOl4GWt+ek28t/Udo 5ySohj/mLhYCfInHpzDLqEM7/YnUvb+gWzmgi0d4Dzqrlhhs14U6ud2NGaIlEVISJh5X ohcg== X-Received: by 10.43.169.202 with SMTP id nn10mr21704712icc.4.1368681711630; Wed, 15 May 2013 22:21:51 -0700 (PDT) Received: from [172.24.139.26] ([137.122.64.49]) by mx.google.com with ESMTPSA id w8sm1904558igl.9.2013.05.15.22.21.50 for (version=TLSv1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Wed, 15 May 2013 22:21:50 -0700 (PDT) References: <201305160516.r4G5Gvv8076406@svn.freebsd.org> Mime-Version: 1.0 (1.0) In-Reply-To: <201305160516.r4G5Gvv8076406@svn.freebsd.org> Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: quoted-printable Message-Id: <339B2849-9826-4B35-A6BC-9C8382B8A5B1@gmail.com> X-Mailer: iPhone Mail (10B329) From: Garrett Cooper Subject: Re: svn commit: r250693 - head/contrib/libpcap Date: Thu, 16 May 2013 01:21:50 -0400 To: Hiren Panchasara Cc: "svn-src-head@freebsd.org" , "svn-src-all@freebsd.org" , "src-committers@freebsd.org" X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 16 May 2013 05:21:52 -0000 Has this been pushed upstream? Sent from my iPhone On May 16, 2013, at 1:16 AM, Hiren Panchasara wrote: > Author: hiren > Date: Thu May 16 05:16:56 2013 > New Revision: 250693 > URL: http://svnweb.freebsd.org/changeset/base/250693 >=20 > Log: > Add tcp header flags ECE and CWR defined in RFC 3168. >=20 > PR: 140349 > Submitted by: Alan Amesbury (earlier version) > Reviewed by: delphij > Approved by: sbruno (mentor) >=20 > Modified: > head/contrib/libpcap/pcap-filter.manmisc > head/contrib/libpcap/pcap-filter.manmisc.in > head/contrib/libpcap/scanner.l >=20 > Modified: head/contrib/libpcap/pcap-filter.manmisc > =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D > --- head/contrib/libpcap/pcap-filter.manmisc Thu May 16 03:51:00 2013 = (r250692) > +++ head/contrib/libpcap/pcap-filter.manmisc Thu May 16 05:16:56 2013 = (r250693) > @@ -783,7 +783,8 @@ The following ICMP type field values are >=20 > The following TCP flags field values are available: \fBtcp-fin\fP, > \fBtcp-syn\fP, \fBtcp-rst\fP, \fBtcp-push\fP, > -\fBtcp-ack\fP, \fBtcp-urg\fP. > +\fBtcp-ack\fP, \fBtcp-urg\fP, \fBtcp-ece\fP, > +\fBtcp-cwr\fP. > .LP > Primitives may be combined using: > .IP >=20 > Modified: head/contrib/libpcap/pcap-filter.manmisc.in > =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D > --- head/contrib/libpcap/pcap-filter.manmisc.in Thu May 16 03:51:00 201= 3 (r250692) > +++ head/contrib/libpcap/pcap-filter.manmisc.in Thu May 16 05:16:56 201= 3 (r250693) > @@ -783,7 +783,8 @@ The following ICMP type field values are >=20 > The following TCP flags field values are available: \fBtcp-fin\fP, > \fBtcp-syn\fP, \fBtcp-rst\fP, \fBtcp-push\fP, > -\fBtcp-ack\fP, \fBtcp-urg\fP. > +\fBtcp-ack\fP, \fBtcp-urg\fP, \fBtcp-ece\fP, > +\fBtcp-cwr\fP. > .LP > Primitives may be combined using: > .IP >=20 > Modified: head/contrib/libpcap/scanner.l > =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D > --- head/contrib/libpcap/scanner.l Thu May 16 03:51:00 2013 (r250692= ) > +++ head/contrib/libpcap/scanner.l Thu May 16 05:16:56 2013 (r250693= ) > @@ -385,6 +385,8 @@ tcp-rst { yylval.i =3D 0x04; return NUM; > tcp-push { yylval.i =3D 0x08; return NUM; } > tcp-ack { yylval.i =3D 0x10; return NUM; } > tcp-urg { yylval.i =3D 0x20; return NUM; } > +tcp-ece { yylval.i =3D 0x40; return NUM; } > +tcp-cwr { yylval.i =3D 0x80; return NUM; } > [A-Za-z0-9]([-_.A-Za-z0-9]*[.A-Za-z0-9])? { > yylval.s =3D sdup((char *)yytext); return ID; } > "\\"[^ !()\n\t]+ { yylval.s =3D sdup((char *)yytext + 1); return ID; } > _______________________________________________ > svn-src-head@freebsd.org mailing list > http://lists.freebsd.org/mailman/listinfo/svn-src-head > To unsubscribe, send any mail to "svn-src-head-unsubscribe@freebsd.org" From owner-svn-src-all@FreeBSD.ORG Thu May 16 05:26:02 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id 5AED31C0; Thu, 16 May 2013 05:26:02 +0000 (UTC) (envelope-from hiren.panchasara@gmail.com) Received: from mail-ea0-x22b.google.com (mail-ea0-x22b.google.com [IPv6:2a00:1450:4013:c01::22b]) by mx1.freebsd.org (Postfix) with ESMTP id 9452EF1D; Thu, 16 May 2013 05:26:01 +0000 (UTC) Received: by mail-ea0-f171.google.com with SMTP id b15so1467610eae.30 for ; Wed, 15 May 2013 22:26:00 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:x-received:sender:in-reply-to:references:date :x-google-sender-auth:message-id:subject:from:to:cc:content-type; bh=MjvFeCUb+ikLRr9ZWFV0kYZywrrDJrn8hpJFSh/n8jw=; b=CVuJ8AUM5tdlcihJKBFkyaqeUG6tWOeh2HvUTQrW6AiRW5EFJ2iihtGGz1DST0S0ND f4AE7GZ0Qv5SR74h+xKz9lGIii66GBQGLMXZ7l9pDEaqc8aN2NKUipvwYbB3TN0wY/wv 8gWWkcd9d417krX04OecDa1Trp5zxzkaGyfHcrhO/zY4EYpDiyyL9qpyKAEXEDzpB8jK 2+MHlAOz7eDKaStLOR0ebsMInXGwiFe3ytv9xFtkg2oi6BwO8UGzbHhIPAkOVoAlAX5M gfAXSV0ldCdsbEaKsfif/j/o0Dq9BiG7/4eLz6M+1RgNF+8O1ZMhjtW8HyWKFZgHxP6h z6zA== MIME-Version: 1.0 X-Received: by 10.15.94.78 with SMTP id ba54mr14060496eeb.36.1368681960656; Wed, 15 May 2013 22:26:00 -0700 (PDT) Sender: hiren.panchasara@gmail.com Received: by 10.14.130.66 with HTTP; Wed, 15 May 2013 22:26:00 -0700 (PDT) In-Reply-To: <339B2849-9826-4B35-A6BC-9C8382B8A5B1@gmail.com> References: <201305160516.r4G5Gvv8076406@svn.freebsd.org> <339B2849-9826-4B35-A6BC-9C8382B8A5B1@gmail.com> Date: Wed, 15 May 2013 22:26:00 -0700 X-Google-Sender-Auth: -yDsrK4DD_0MPrTV-tu96LssVfk Message-ID: Subject: Re: svn commit: r250693 - head/contrib/libpcap From: hiren panchasara To: Garrett Cooper Content-Type: text/plain; charset=UTF-8 Cc: "svn-src-head@freebsd.org" , "svn-src-all@freebsd.org" , "src-committers@freebsd.org" X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 16 May 2013 05:26:02 -0000 On Wed, May 15, 2013 at 10:21 PM, Garrett Cooper wrote: > Has this been pushed upstream? Yes. (by delphij) cheers, Hiren > > Sent from my iPhone > > On May 16, 2013, at 1:16 AM, Hiren Panchasara wrote: > >> Author: hiren >> Date: Thu May 16 05:16:56 2013 >> New Revision: 250693 >> URL: http://svnweb.freebsd.org/changeset/base/250693 >> >> Log: >> Add tcp header flags ECE and CWR defined in RFC 3168. >> >> PR: 140349 >> Submitted by: Alan Amesbury (earlier version) >> Reviewed by: delphij >> Approved by: sbruno (mentor) >> >> Modified: >> head/contrib/libpcap/pcap-filter.manmisc >> head/contrib/libpcap/pcap-filter.manmisc.in >> head/contrib/libpcap/scanner.l >> >> Modified: head/contrib/libpcap/pcap-filter.manmisc >> ============================================================================== >> --- head/contrib/libpcap/pcap-filter.manmisc Thu May 16 03:51:00 2013 (r250692) >> +++ head/contrib/libpcap/pcap-filter.manmisc Thu May 16 05:16:56 2013 (r250693) >> @@ -783,7 +783,8 @@ The following ICMP type field values are >> >> The following TCP flags field values are available: \fBtcp-fin\fP, >> \fBtcp-syn\fP, \fBtcp-rst\fP, \fBtcp-push\fP, >> -\fBtcp-ack\fP, \fBtcp-urg\fP. >> +\fBtcp-ack\fP, \fBtcp-urg\fP, \fBtcp-ece\fP, >> +\fBtcp-cwr\fP. >> .LP >> Primitives may be combined using: >> .IP >> >> Modified: head/contrib/libpcap/pcap-filter.manmisc.in >> ============================================================================== >> --- head/contrib/libpcap/pcap-filter.manmisc.in Thu May 16 03:51:00 2013 (r250692) >> +++ head/contrib/libpcap/pcap-filter.manmisc.in Thu May 16 05:16:56 2013 (r250693) >> @@ -783,7 +783,8 @@ The following ICMP type field values are >> >> The following TCP flags field values are available: \fBtcp-fin\fP, >> \fBtcp-syn\fP, \fBtcp-rst\fP, \fBtcp-push\fP, >> -\fBtcp-ack\fP, \fBtcp-urg\fP. >> +\fBtcp-ack\fP, \fBtcp-urg\fP, \fBtcp-ece\fP, >> +\fBtcp-cwr\fP. >> .LP >> Primitives may be combined using: >> .IP >> >> Modified: head/contrib/libpcap/scanner.l >> ============================================================================== >> --- head/contrib/libpcap/scanner.l Thu May 16 03:51:00 2013 (r250692) >> +++ head/contrib/libpcap/scanner.l Thu May 16 05:16:56 2013 (r250693) >> @@ -385,6 +385,8 @@ tcp-rst { yylval.i = 0x04; return NUM; >> tcp-push { yylval.i = 0x08; return NUM; } >> tcp-ack { yylval.i = 0x10; return NUM; } >> tcp-urg { yylval.i = 0x20; return NUM; } >> +tcp-ece { yylval.i = 0x40; return NUM; } >> +tcp-cwr { yylval.i = 0x80; return NUM; } >> [A-Za-z0-9]([-_.A-Za-z0-9]*[.A-Za-z0-9])? { >> yylval.s = sdup((char *)yytext); return ID; } >> "\\"[^ !()\n\t]+ { yylval.s = sdup((char *)yytext + 1); return ID; } >> _______________________________________________ >> svn-src-head@freebsd.org mailing list >> http://lists.freebsd.org/mailman/listinfo/svn-src-head >> To unsubscribe, send any mail to "svn-src-head-unsubscribe@freebsd.org" From owner-svn-src-all@FreeBSD.ORG Thu May 16 06:19:30 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id AD85F9D2; Thu, 16 May 2013 06:19:30 +0000 (UTC) (envelope-from kib@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id 9EF21AE; Thu, 16 May 2013 06:19:30 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.6/8.14.6) with ESMTP id r4G6JUMJ097657; Thu, 16 May 2013 06:19:30 GMT (envelope-from kib@svn.freebsd.org) Received: (from kib@localhost) by svn.freebsd.org (8.14.6/8.14.5/Submit) id r4G6JTGe097655; Thu, 16 May 2013 06:19:29 GMT (envelope-from kib@svn.freebsd.org) Message-Id: <201305160619.r4G6JTGe097655@svn.freebsd.org> From: Konstantin Belousov Date: Thu, 16 May 2013 06:19:29 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org Subject: svn commit: r250694 - stable/9/sys/fs/msdosfs X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 16 May 2013 06:19:30 -0000 Author: kib Date: Thu May 16 06:19:29 2013 New Revision: 250694 URL: http://svnweb.freebsd.org/changeset/base/250694 Log: MFC r250193: Do a sync of the devvp vnode for the mount, which buffers, among other things, contain FAT blocks. This makes fsync(2) for msdosfs more correct by syncing the metadata needed to read the synced data. Modified: stable/9/sys/fs/msdosfs/msdosfs_denode.c stable/9/sys/fs/msdosfs/msdosfs_vnops.c Directory Properties: stable/9/sys/ (props changed) stable/9/sys/fs/ (props changed) Modified: stable/9/sys/fs/msdosfs/msdosfs_denode.c ============================================================================== --- stable/9/sys/fs/msdosfs/msdosfs_denode.c Thu May 16 05:16:56 2013 (r250693) +++ stable/9/sys/fs/msdosfs/msdosfs_denode.c Thu May 16 06:19:29 2013 (r250694) @@ -294,16 +294,20 @@ deupdat(dep, waitfor) struct denode *dep; int waitfor; { - int error; + struct direntry dir; + struct timespec ts; struct buf *bp; struct direntry *dirp; - struct timespec ts; + int error; - if (DETOV(dep)->v_mount->mnt_flag & MNT_RDONLY) + if (DETOV(dep)->v_mount->mnt_flag & MNT_RDONLY) { + dep->de_flag &= ~(DE_UPDATE | DE_CREATE | DE_ACCESS | + DE_MODIFIED); return (0); + } getnanotime(&ts); DETIMES(dep, &ts, &ts, &ts); - if ((dep->de_flag & DE_MODIFIED) == 0) + if ((dep->de_flag & DE_MODIFIED) == 0 && waitfor == 0) return (0); dep->de_flag &= ~DE_MODIFIED; if (dep->de_Attributes & ATTR_DIRECTORY) @@ -313,13 +317,23 @@ deupdat(dep, waitfor) error = readde(dep, &bp, &dirp); if (error) return (error); - DE_EXTERNALIZE(dirp, dep); + DE_EXTERNALIZE(&dir, dep); + if (bcmp(dirp, &dir, sizeof(dir)) == 0) { + if (waitfor == 0 || (bp->b_flags & B_DELWRI) == 0) { + brelse(bp); + return (0); + } + } else + *dirp = dir; + if ((DETOV(dep)->v_mount->mnt_flag & MNT_NOCLUSTERW) == 0) + bp->b_flags |= B_CLUSTEROK; if (waitfor) - return (bwrite(bp)); - else { + error = bwrite(bp); + else if (vm_page_count_severe() || buf_dirty_count_severe()) + bawrite(bp); + else bdwrite(bp); - return (0); - } + return (error); } /* Modified: stable/9/sys/fs/msdosfs/msdosfs_vnops.c ============================================================================== --- stable/9/sys/fs/msdosfs/msdosfs_vnops.c Thu May 16 05:16:56 2013 (r250693) +++ stable/9/sys/fs/msdosfs/msdosfs_vnops.c Thu May 16 06:19:29 2013 (r250694) @@ -850,9 +850,6 @@ errexit: /* * Flush the blocks of a file to disk. - * - * This function is worthless for vnodes that represent directories. Maybe we - * could just do a sync if they try an fsync on a directory file. */ static int msdosfs_fsync(ap) @@ -863,9 +860,35 @@ msdosfs_fsync(ap) struct thread *a_td; } */ *ap; { + struct vnode *devvp; + int allerror, error; vop_stdfsync(ap); - return (deupdat(VTODE(ap->a_vp), ap->a_waitfor == MNT_WAIT)); + + /* + * If the syncing request comes from fsync(2), sync the entire + * FAT and any other metadata that happens to be on devvp. We + * need this mainly for the FAT. We write the FAT sloppily, and + * syncing it all now is the best we can easily do to get all + * directory entries associated with the file (not just the file) + * fully synced. The other metadata includes critical metadata + * for all directory entries, but only in the MNT_ASYNC case. We + * will soon sync all metadata in the file's directory entry. + * Non-critical metadata for associated directory entries only + * gets synced accidentally, as in most file systems. + */ + if (ap->a_waitfor == MNT_WAIT) { + devvp = VTODE(ap->a_vp)->de_pmp->pm_devvp; + vn_lock(devvp, LK_EXCLUSIVE | LK_RETRY); + allerror = VOP_FSYNC(devvp, MNT_WAIT, ap->a_td); + VOP_UNLOCK(devvp, 0); + } else + allerror = 0; + + error = deupdat(VTODE(ap->a_vp), ap->a_waitfor == MNT_WAIT); + if (allerror == 0) + allerror = error; + return (allerror); } static int From owner-svn-src-all@FreeBSD.ORG Thu May 16 09:02:20 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id 89BB8C33 for ; Thu, 16 May 2013 09:02:20 +0000 (UTC) (envelope-from tim@kientzle.com) Received: from mail-ie0-x232.google.com (mail-ie0-x232.google.com [IPv6:2607:f8b0:4001:c03::232]) by mx1.freebsd.org (Postfix) with ESMTP id 5993990D for ; Thu, 16 May 2013 09:02:20 +0000 (UTC) Received: by mail-ie0-f178.google.com with SMTP id b11so5827220iee.37 for ; Thu, 16 May 2013 02:02:20 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20120113; h=x-received:sender:subject:mime-version:content-type:from :in-reply-to:date:cc:message-id:references:to:x-mailer :x-gm-message-state; bh=HU7SLwPWSqA4qHjD4wZHVS1cd87TFlQHsucjeEXxaY4=; b=eHGWlYo4j7AQgfrwDzXZXLEbvhnJmHRGUpVmQ+0TsAJDXx6onuXrCICJEsrtfD9sf5 9wQAI5/q2fvAKq6WLGp8ZECujPwBbwV7MP5Wft1Qjy0xsOKUj2jKHC18e65WRvpykrxZ 8Ige2LuclnBIZQQTC1x0eDyF3YJ3LSXUcjxFfFaVhfgsI0sJAV177Pfa1Aw+jTCERUWi PsvJ7NiqtbnTAOgGS+Qo6vSYHmkC9XeODiRSVwlsSqWeWiQDH5MhvFhVa5RxeHyLKu1X Mr/2TVjZ6F3p/eRNw4LDCeqpVyr2AnJ/hOsOSetbiA2u9D6LchoyBPt2t0zXBwFoaPyX qFrA== X-Received: by 10.50.118.37 with SMTP id kj5mr8405174igb.70.1368694940060; Thu, 16 May 2013 02:02:20 -0700 (PDT) Received: from [172.24.137.243] ([137.122.64.8]) by mx.google.com with ESMTPSA id q3sm2699398igw.0.2013.05.16.02.02.18 for (version=TLSv1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Thu, 16 May 2013 02:02:19 -0700 (PDT) Sender: Tim Kientzle Subject: Re: svn commit: r250692 - head/sys/arm/conf Mime-Version: 1.0 (Apple Message framework v1283) Content-Type: multipart/signed; boundary="Apple-Mail=_77D43C90-74EB-4D16-B3E4-32CEEC032C28"; protocol="application/pgp-signature"; micalg=pgp-sha1 From: Tim Kientzle In-Reply-To: <201305160351.r4G3p0uu047404@svn.freebsd.org> Date: Thu, 16 May 2013 05:02:16 -0400 Message-Id: <30BAC0E1-9E8F-4FA4-A31E-C2AFAFDBCB95@freebsd.org> References: <201305160351.r4G3p0uu047404@svn.freebsd.org> To: Rui Paulo X-Mailer: Apple Mail (2.1283) X-Gm-Message-State: ALoCoQkn61+W5cZFpn08olCZY5UG79jMJA0TvGzvHGimTSXYxNIGLGUNZCkaKshyeeYgbMGV/NM3 Cc: svn-src-head@FreeBSD.org, svn-src-all@FreeBSD.org, src-committers@FreeBSD.org X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 16 May 2013 09:02:20 -0000 --Apple-Mail=_77D43C90-74EB-4D16-B3E4-32CEEC032C28 Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset=windows-1252 I don't object, but I'm not sure why we need this. I'd rather see a comment in the BEAGLEBONE config indicating that it can be used with beaglebone-black.dts. Generally, I want us to move away from compiled-in DTBs. The BEAGLEBONE config works just fine on either one and it's what I plan to continue using going forward. Part of the boot loader's job is to load the correct DTB. The images built by Crochet today already do this and produce images that boot on either old or new BeagleBone using the BEAGLEBONE config. U-Boot already has logic to detect the board, load the correct DTB, and the same BEAGLEBONE kernel then runs just fine. Here are the U-Boot patches if you'd like to do this as well: = https://github.com/kientzle/crochet-freebsd/tree/master/board/BeagleBone/f= iles (There's also a copy of the compiled U-Boot and associated files at: http://people.freebsd.org/~kientzle/beaglebone-and-black-bootfiles.tgz Moving forward, I'd like to see us generally consolidate ARM kernel configurations. I have some (still very experimental) ideas for combining the RPi and BeagleBone kernels into a single kernel, but with my limited time, that will be a fairly long-term project. If anyone's at BSDCan who would like to talk about it=85. I'll be at the "Beyond BuildWorld" session on Thursday=85. ;-) Yes, this is certainly useful for people net booting the BeagleBone Black for developing kernel drivers, but I'm not sure why we would bother having it checked-in. Tim On May 15, 2013, at 11:51 PM, Rui Paulo wrote: > Author: rpaulo > Date: Thu May 16 03:51:00 2013 > New Revision: 250692 > URL: http://svnweb.freebsd.org/changeset/base/250692 >=20 > Log: > Add a kernel config file for the BeableBone Black SoC. >=20 > +options FDT > +options FDT_DTB_STATIC > +makeoptions FDT_DTS_FILE=3Dbeaglebone-black.dts --Apple-Mail=_77D43C90-74EB-4D16-B3E4-32CEEC032C28 Content-Transfer-Encoding: 7bit Content-Disposition: attachment; filename=signature.asc Content-Type: application/pgp-signature; name=signature.asc Content-Description: Message signed with OpenPGP using GPGMail -----BEGIN PGP SIGNATURE----- Version: GnuPG/MacGPG2 v2.0.18 (Darwin) iQEcBAEBAgAGBQJRlKCZAAoJEGMNyGo0rfFBsIUIAJwK1ZNeCxHo4vy7+bgx9B2N q+7L5N1NvQArNcdIA1OVv5Z3NebTFqo+qmvUCCHRAkJXWOY3/kTNHStwUb4E3k8Z 3sy1X6N5oxkuBp2IVa/rSAXnXFfk2EkQSohBLFRe7NdoAZ3d6Beo/SLVC5g54T5t /YPH56bzyvP8ueKL6aokObmXQGNIB7SGinxV94iYRroN861EqTB9VttvFjAgxXgJ 93hsX4XcDMZTPxlahFwbT7FZEZid7ejApDGJLH1Q2AIHtZlQuYLBVKi54Rl6cWLZ 1Q/YiO/n9QKx7IFizK5FfA2hVUaCmye+S/aaekLbXe7OQkZzz4qBl27JTDsjUYo= =RBcG -----END PGP SIGNATURE----- --Apple-Mail=_77D43C90-74EB-4D16-B3E4-32CEEC032C28-- From owner-svn-src-all@FreeBSD.ORG Thu May 16 09:43:05 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id 3BC806C6; Thu, 16 May 2013 09:43:05 +0000 (UTC) (envelope-from gber@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id 2E125A95; Thu, 16 May 2013 09:43:05 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.6/8.14.6) with ESMTP id r4G9h5Md069737; Thu, 16 May 2013 09:43:05 GMT (envelope-from gber@svn.freebsd.org) Received: (from gber@localhost) by svn.freebsd.org (8.14.6/8.14.5/Submit) id r4G9h5UE069736; Thu, 16 May 2013 09:43:05 GMT (envelope-from gber@svn.freebsd.org) Message-Id: <201305160943.r4G9h5UE069736@svn.freebsd.org> From: Grzegorz Bernacki Date: Thu, 16 May 2013 09:43:05 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r250695 - head/sys/arm/arm X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 16 May 2013 09:43:05 -0000 Author: gber Date: Thu May 16 09:43:04 2013 New Revision: 250695 URL: http://svnweb.freebsd.org/changeset/base/250695 Log: Fix L2 cache write-back invalidate for Sheeva core. Submitted by: Michal Dubiel Obtained from: Netasq, Semihalf Modified: head/sys/arm/arm/cpufunc_asm_sheeva.S Modified: head/sys/arm/arm/cpufunc_asm_sheeva.S ============================================================================== --- head/sys/arm/arm/cpufunc_asm_sheeva.S Thu May 16 06:19:29 2013 (r250694) +++ head/sys/arm/arm/cpufunc_asm_sheeva.S Thu May 16 09:43:04 2013 (r250695) @@ -377,9 +377,17 @@ ENTRY(sheeva_l2cache_wb_range) END(sheeva_l2cache_wb_range) ENTRY(sheeva_l2cache_wbinv_all) + /* Disable irqs */ + mrs r1, cpsr + orr r2, r1, #I32_bit | F32_bit + msr cpsr_c, r2 + mov r0, #0 mcr p15, 1, r0, c15, c9, 0 /* Clean L2 */ mcr p15, 1, r0, c15, c11, 0 /* Invalidate L2 */ + + msr cpsr_c, r1 /* Reenable irqs */ + mcr p15, 0, r0, c7, c10, 4 /* drain the write buffer */ RET END(sheeva_l2cache_wbinv_all) From owner-svn-src-all@FreeBSD.ORG Thu May 16 10:32:02 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id B58E1A35; Thu, 16 May 2013 10:32:02 +0000 (UTC) (envelope-from kib@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id A76BDD11; Thu, 16 May 2013 10:32:02 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.6/8.14.6) with ESMTP id r4GAW2RR088013; Thu, 16 May 2013 10:32:02 GMT (envelope-from kib@svn.freebsd.org) Received: (from kib@localhost) by svn.freebsd.org (8.14.6/8.14.5/Submit) id r4GAW2Q8088010; Thu, 16 May 2013 10:32:02 GMT (envelope-from kib@svn.freebsd.org) Message-Id: <201305161032.r4GAW2Q8088010@svn.freebsd.org> From: Konstantin Belousov Date: Thu, 16 May 2013 10:32:02 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-8@freebsd.org Subject: svn commit: r250696 - stable/8/sys/fs/msdosfs X-SVN-Group: stable-8 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 16 May 2013 10:32:02 -0000 Author: kib Date: Thu May 16 10:32:01 2013 New Revision: 250696 URL: http://svnweb.freebsd.org/changeset/base/250696 Log: MFC r250193: Do a sync of the devvp vnode for the mount, which buffers, among other things, contain FAT blocks. This makes fsync(2) for msdosfs more correct by syncing the metadata needed to read the synced data. Modified: stable/8/sys/fs/msdosfs/msdosfs_denode.c stable/8/sys/fs/msdosfs/msdosfs_vnops.c Directory Properties: stable/8/sys/ (props changed) stable/8/sys/fs/ (props changed) Modified: stable/8/sys/fs/msdosfs/msdosfs_denode.c ============================================================================== --- stable/8/sys/fs/msdosfs/msdosfs_denode.c Thu May 16 09:43:04 2013 (r250695) +++ stable/8/sys/fs/msdosfs/msdosfs_denode.c Thu May 16 10:32:01 2013 (r250696) @@ -294,16 +294,20 @@ deupdat(dep, waitfor) struct denode *dep; int waitfor; { - int error; + struct direntry dir; + struct timespec ts; struct buf *bp; struct direntry *dirp; - struct timespec ts; + int error; - if (DETOV(dep)->v_mount->mnt_flag & MNT_RDONLY) + if (DETOV(dep)->v_mount->mnt_flag & MNT_RDONLY) { + dep->de_flag &= ~(DE_UPDATE | DE_CREATE | DE_ACCESS | + DE_MODIFIED); return (0); + } getnanotime(&ts); DETIMES(dep, &ts, &ts, &ts); - if ((dep->de_flag & DE_MODIFIED) == 0) + if ((dep->de_flag & DE_MODIFIED) == 0 && waitfor == 0) return (0); dep->de_flag &= ~DE_MODIFIED; if (dep->de_Attributes & ATTR_DIRECTORY) @@ -313,13 +317,23 @@ deupdat(dep, waitfor) error = readde(dep, &bp, &dirp); if (error) return (error); - DE_EXTERNALIZE(dirp, dep); + DE_EXTERNALIZE(&dir, dep); + if (bcmp(dirp, &dir, sizeof(dir)) == 0) { + if (waitfor == 0 || (bp->b_flags & B_DELWRI) == 0) { + brelse(bp); + return (0); + } + } else + *dirp = dir; + if ((DETOV(dep)->v_mount->mnt_flag & MNT_NOCLUSTERW) == 0) + bp->b_flags |= B_CLUSTEROK; if (waitfor) - return (bwrite(bp)); - else { + error = bwrite(bp); + else if (vm_page_count_severe() || buf_dirty_count_severe()) + bawrite(bp); + else bdwrite(bp); - return (0); - } + return (error); } /* Modified: stable/8/sys/fs/msdosfs/msdosfs_vnops.c ============================================================================== --- stable/8/sys/fs/msdosfs/msdosfs_vnops.c Thu May 16 09:43:04 2013 (r250695) +++ stable/8/sys/fs/msdosfs/msdosfs_vnops.c Thu May 16 10:32:01 2013 (r250696) @@ -851,9 +851,6 @@ errexit: /* * Flush the blocks of a file to disk. - * - * This function is worthless for vnodes that represent directories. Maybe we - * could just do a sync if they try an fsync on a directory file. */ static int msdosfs_fsync(ap) @@ -864,9 +861,35 @@ msdosfs_fsync(ap) struct thread *a_td; } */ *ap; { + struct vnode *devvp; + int allerror, error; vop_stdfsync(ap); - return (deupdat(VTODE(ap->a_vp), ap->a_waitfor == MNT_WAIT)); + + /* + * If the syncing request comes from fsync(2), sync the entire + * FAT and any other metadata that happens to be on devvp. We + * need this mainly for the FAT. We write the FAT sloppily, and + * syncing it all now is the best we can easily do to get all + * directory entries associated with the file (not just the file) + * fully synced. The other metadata includes critical metadata + * for all directory entries, but only in the MNT_ASYNC case. We + * will soon sync all metadata in the file's directory entry. + * Non-critical metadata for associated directory entries only + * gets synced accidentally, as in most file systems. + */ + if (ap->a_waitfor == MNT_WAIT) { + devvp = VTODE(ap->a_vp)->de_pmp->pm_devvp; + vn_lock(devvp, LK_EXCLUSIVE | LK_RETRY); + allerror = VOP_FSYNC(devvp, MNT_WAIT, ap->a_td); + VOP_UNLOCK(devvp, 0); + } else + allerror = 0; + + error = deupdat(VTODE(ap->a_vp), ap->a_waitfor == MNT_WAIT); + if (allerror == 0) + allerror = error; + return (allerror); } static int From owner-svn-src-all@FreeBSD.ORG Thu May 16 13:07:03 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id 5AE716DB; Thu, 16 May 2013 13:07:03 +0000 (UTC) (envelope-from kib@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id 4DF74680; Thu, 16 May 2013 13:07:03 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.6/8.14.6) with ESMTP id r4GD7311041105; Thu, 16 May 2013 13:07:03 GMT (envelope-from kib@svn.freebsd.org) Received: (from kib@localhost) by svn.freebsd.org (8.14.6/8.14.5/Submit) id r4GD722j041103; Thu, 16 May 2013 13:07:02 GMT (envelope-from kib@svn.freebsd.org) Message-Id: <201305161307.r4GD722j041103@svn.freebsd.org> From: Konstantin Belousov Date: Thu, 16 May 2013 13:07:02 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r250697 - in head/sys/dev: cxgb cxgbe X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 16 May 2013 13:07:03 -0000 Author: kib Date: Thu May 16 13:07:02 2013 New Revision: 250697 URL: http://svnweb.freebsd.org/changeset/base/250697 Log: Add dependencies on the firmware, which allows the loading of the cxgb and cxgbe modules. Reviewed and approved by: np MFC after: 1 week Modified: head/sys/dev/cxgb/cxgb_main.c head/sys/dev/cxgbe/t4_main.c Modified: head/sys/dev/cxgb/cxgb_main.c ============================================================================== --- head/sys/dev/cxgb/cxgb_main.c Thu May 16 10:32:01 2013 (r250696) +++ head/sys/dev/cxgb/cxgb_main.c Thu May 16 13:07:02 2013 (r250697) @@ -149,6 +149,7 @@ static devclass_t cxgb_controller_devcla DRIVER_MODULE(cxgbc, pci, cxgb_controller_driver, cxgb_controller_devclass, cxgbc_mod_event, 0); MODULE_VERSION(cxgbc, 1); +MODULE_DEPEND(cxgbc, firmware, 1, 1, 1); /* * Attachment glue for the ports. Attachment is done directly to the Modified: head/sys/dev/cxgbe/t4_main.c ============================================================================== --- head/sys/dev/cxgbe/t4_main.c Thu May 16 10:32:01 2013 (r250696) +++ head/sys/dev/cxgbe/t4_main.c Thu May 16 13:07:02 2013 (r250697) @@ -7132,9 +7132,11 @@ static devclass_t cxgbe_devclass, cxl_de DRIVER_MODULE(t4nex, pci, t4_driver, t4_devclass, mod_event, 0); MODULE_VERSION(t4nex, 1); +MODULE_DEPEND(t4nex, firmware, 1, 1, 1); DRIVER_MODULE(t5nex, pci, t5_driver, t5_devclass, mod_event, 0); MODULE_VERSION(t5nex, 1); +MODULE_DEPEND(t5nex, firmware, 1, 1, 1); DRIVER_MODULE(cxgbe, t4nex, cxgbe_driver, cxgbe_devclass, 0, 0); MODULE_VERSION(cxgbe, 1); From owner-svn-src-all@FreeBSD.ORG Thu May 16 14:38:13 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id 38D62B26; Thu, 16 May 2013 14:38:13 +0000 (UTC) (envelope-from brooks@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id 294C1BDA; Thu, 16 May 2013 14:38:13 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.6/8.14.6) with ESMTP id r4GEcDc5073761; Thu, 16 May 2013 14:38:13 GMT (envelope-from brooks@svn.freebsd.org) Received: (from brooks@localhost) by svn.freebsd.org (8.14.6/8.14.5/Submit) id r4GEcCR4073758; Thu, 16 May 2013 14:38:12 GMT (envelope-from brooks@svn.freebsd.org) Message-Id: <201305161438.r4GEcCR4073758@svn.freebsd.org> From: Brooks Davis Date: Thu, 16 May 2013 14:38:12 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r250698 - head/tools/tools/makeroot X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 16 May 2013 14:38:13 -0000 Author: brooks Date: Thu May 16 14:38:12 2013 New Revision: 250698 URL: http://svnweb.freebsd.org/changeset/base/250698 Log: Add a sample script to create filesystem images from an installed tree created by installworld+distribution with the -DNO_ROOT option. Added: head/tools/tools/makeroot/Makefile (contents, props changed) head/tools/tools/makeroot/makeroot.8 (contents, props changed) head/tools/tools/makeroot/makeroot.sh (contents, props changed) Added: head/tools/tools/makeroot/Makefile ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ head/tools/tools/makeroot/Makefile Thu May 16 14:38:12 2013 (r250698) @@ -0,0 +1,8 @@ +# $FreeBSD$ + +SCRIPTS= makeroot.sh +MAN= makeroot.8 + +BINDIR?= /usr/sbin + +.include Added: head/tools/tools/makeroot/makeroot.8 ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ head/tools/tools/makeroot/makeroot.8 Thu May 16 14:38:12 2013 (r250698) @@ -0,0 +1,124 @@ +.\"- +.\" Copyright (c) 2013 SRI International +.\" All rights reserved. +.\" +.\" This software was developed by SRI International and the University of +.\" Cambridge Computer Laboratory under DARPA/AFRL contract (FA8750-10-C-0237) +.\" ("CTSRD"), as part of the DARPA CRASH research programme. +.\" +.\" 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. +.\" +.\" $FreeBSD$ +.Dd May 16, 2013 +.Dt MAKEROOT 8 +.Os +.Sh NAME +.Nm makeroot +.Nd Tool to create root filesystem images given a tree containing a manifest +.Sh SYNOPSIS +.Nm +.Op Fl d +.Op Fl B Ar byte-order +.Op Fl e Ar extras-manifest +.Op Fl f Ar filelist +.Op Fl k Ar keydir Op Fl K Ar user +.Op Fl p Ar master.passwd Op Fl g Ar group +.Op Fl s Ar size +.Ar image-file +.Ar rootdir +.Sh DESCRIPTION +The +.Nm +script creates a UFS filesystem image into +.Ar imagefile . +By default, +all filesystem objects listed in the +METALOG file contained in the +.Pa Ar rootdir +directory will be placed in the root of the UFS image +.Ar image-file . +will be placed in the root of the UFS image +.Ar image-file . +.Pp +Images can be customized with a number of different flags. +.Bl -tag -compact -width indent +.It Fl B Ar byte-order +Set the byte order of the image to +.Ar byte-order . +This argument is passed directly to +.Xr makefs 8 . +.It Fl d +Enable debugging output. +.It Fl e Ar manifest +Extra files listed in the +.Xr nmtree 8 +format +.Ar manifest +file are added to the filesystem image. +If no contents= tag is specified or a contents= tag is relative then +files are found relative to the basename of the full path of the +manifest. +If a contents= tag is provided and it is an absolute path then the file +will be from that path. +.It Fl f Ar filelist +Constrain set of filesystem objects included from +.Ar rootdir +to those listed (one per line) in the +.Ar filelist +plus any required directories. +.It Fl k Ar keydir Op Fl K Ar user +Create a .ssh/authorized_keys file from a collection of public key files +stored in +.Ar keydir +and install it in the home directory of +.Ar user . +If no +.F K +argument is supplied then the files will be installed in the root user's +directory. +.It Fl p Ar master.passwd Op Fl g Ar group +Install an alternate +.Ar master.passwd +file and optionally an alternative +.Ar group +file. +.It Fl s Ar size +Set the size of the image to +.Ar size . +The +.Fl s +argument is passed directly to +.Xr makefs 8 . +.El +.Sh EXAMPLES +.Dl $ makeroot.sh -k keys -K ctsrd -p extras/etc/master.passwd -g extras/etc/group -e extras/mdroot.mtree -e demo/demo.mtree -e extras/ctsrd.mtree -s 26112k -f demo.files cheribsd-demo.img /path/to/dist +.Sh SEE ALSO +.Xr mtree 5 , +.Xr makefs 8 , +.Xr nmtree 8 +.Sh AUTHORS +This software and this manual page were developed by SRI International +and the University of Cambridge Computer Laboratory under DARPA/AFRL +contract +.Pq FA8750-10-C-0237 +.Pq Do CTSRD Dc , +as part of the DARPA CRASH research programme. Added: head/tools/tools/makeroot/makeroot.sh ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ head/tools/tools/makeroot/makeroot.sh Thu May 16 14:38:12 2013 (r250698) @@ -0,0 +1,236 @@ +#!/bin/sh -e +#- +# Copyright (c) 2012-2013 SRI International +# Copyright (c) 2012 Robert N. M. Watson +# All rights reserved. +# +# This software was developed by SRI International and the University of +# Cambridge Computer Laboratory under DARPA/AFRL contract (FA8750-10-C-0237) +# ("CTSRD"), as part of the DARPA CRASH research programme. +# +# 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. +# +# $FreeBSD$ + +usage() +{ + cat <&2 +usage: makeroot.sh [-B byte-order] [-d] [-e ] [-f ] + [-k [-K ]] + [-p [-g ]] [-s ] + +EOF + exit 1 +} + +warn() +{ + echo `basename $0` "$@" 1>&2 +} + +err() +{ + ret=$1 + shift + warn "$@" + exit $ret +} + +atexit() +{ + if [ -z "${DEBUG}" ]; then + rm -rf ${tmpdir} + else + warn "temp directory left at ${tmpdir}" + fi +} + +DEBUG= +# Allow duplice manifest entries when not file list is given because the +# FreeBSD METALOG still includes it. +DUPFLAG=-D +EXTRAS= +FILELIST= +GROUP= +KEYDIR= +KEYUSERS= +PASSWD= + +while getopts "Bde:f:g:K:k:p:s:" opt; do + case "$opt" in + B) BFLAG="-B ${OPTARG}" ;; + d) DEBUG=1 ;; + e) EXTRAS="${EXTRAS} ${OPTARG}" ;; + f) FILELIST="${OPTARG}"; DUPFLAG= ;; + g) GROUP="${OPTARG}" ;; + K) KEYUSERS="${KEYUSERS} ${OPTARG}" ;; + k) KEYDIR="${OPTARG}" ;; + p) PASSWD="${OPTARG}" ;; + s) SIZE="${OPTARG}" ;; + *) usage ;; + esac +done +shift $(($OPTIND - 1)) + +if [ $# -ne 2 ]; then + usage; +fi + +IMGFILE=$(realpath $(dirname $1))/$(basename $1) +BSDROOT=$2 + +DBDIR=${BSDROOT}/etc + +if [ ! -r ${BSDROOT}/METALOG ]; then + err 1 "${BSDROOT} does not contain a METALOG" +fi + +if [ -n "${GROUP}" -a -z "${PASSWD}" ]; then + warn "-g requires -p" + usage +fi + +if [ -n "${KEYUSERS}" -a -z "${KEYDIR}" ]; then + warn "-K requires -k" + usage +fi +if [ -n "${KEYDIR}" -a -z "${KEYUSERS}" ]; then + KEYUSERS=root +fi + +tmpdir=`mktemp -d /tmp/makeroot.XXXXX` +if [ -z "${tmpdir}" -o ! -d "${tmpdir}" ]; then + err 1 "failed to create tmpdir" +fi +trap atexit EXIT + +manifest=${tmpdir}/manifest + +echo "#mtree 2.0" > ${manifest} + +if [ -n "${PASSWD}" ]; then + cp ${PASSWD} ${tmpdir}/master.passwd + pwd_mkdb -d ${tmpdir} -p ${tmpdir}/master.passwd + if [ -z "${GROUP}" ]; then + cp ${DBDIR}/group ${tmpdir} + else + cp ${GROUP} ${tmpdir} + fi + + cat <> ${tmpdir}/passwd.mtree +./etc/group type=file uname=root gname=wheel mode=0644 contents=${tmpdir}/group +./etc/master.passwd type=file uname=root gname=wheel mode=0600 contents=${tmpdir}/master.passwd +./etc/passwd type=file mode=0644 uname=root gname=wheel contents=${tmpdir}/passwd +./etc/pwd.db type=file mode=0644 uname=root gname=wheel contents=${tmpdir}/pwd.db +./etc/spwd.db type=file mode=0600 uname=root gname=wheel contents=${tmpdir}/spwd.db +EOF + EXTRAS="${EXTRAS} ${tmpdir}/passwd.mtree" + + DBDIR=${tmpdir} +fi + +if [ -n "${FILELIST}" ]; then + # build manifest from root manifest and FILELIST + (echo .; grep -v ^# ${FILELIST} | while read path; do + # Print each included path and all its sub-paths with a ./ + # prepended. The "sort -u" will then discard all the + # duplicate directory entries. This ensures that we + # extract the permissions for each unlisted directory + # from the METALOG. + path="/${path}" + while [ -n "${path}" ]; do + echo ".${path}" + path="${path%/*}" + done + done) | sort -u ${BSDROOT}/METALOG - | \ + awk ' + !/ type=/ { file = $1 } + / type=/ { if ($1 == file) {print} }' >> ${manifest} +else + # Start with all the files in BSDROOT/METALOG except those in + # one of the EXTRAS manifests. + grep -h type=file ${EXTRAS} | cut -d' ' -f1 | \ + sort -u ${BSDROOT}/METALOG - | awk ' + !/ type=/ { file = $1 } + / type=/ { if ($1 != file) {print} }' >> ${manifest} +fi + +# For each extras file, add contents kyes relative to the directory the +# manifest lives in for each file line that does not have one. Adjust +# contents keys relative to ./ to be relative to the same directory. +for eman in ${EXTRAS}; do + if [ ! -f ${eman} ]; then + err 1 "${eman} is not a regular file" + fi + extradir=`realpath ${eman}`; extradir=`dirname ${extradir}` + + awk '{ + if ($0 !~ /type=file/) { + print + } else { + if ($0 !~ /contents=/) { + printf ("%s contents=%s\n", $0, $1) + } else { + print + } + } + }' ${eman} | \ + sed -e "s|contents=\./|contents=${extradir}/|" >> ${manifest} +done + +# /etc/rcorder.start allows the startup order to be stable even if +# not all startup scripts are installed. In theory it should be +# unnecessicary, but dependencies in rc.d appear to be under recorded. +# This is a hack local to beri/cheribsd. +# +echo /etc/rc.d/FIRST > ${tmpdir}/rcorder.start +rcorder -s nostart ${BSDROOT}/etc/rc.d/* | sed -e "s:^${BSDROOT}::" | \ + grep -v LAST | grep -v FIRST >> \ + ${tmpdir}/rcorder.start +echo /etc/rc.d/LAST >> ${tmpdir}/rcorder.start +echo "./etc/rcorder.start type=file mode=644 uname=root gname=wheel" \ + "contents=${tmpdir}/rcorder.start" >> ${manifest} + +# Add all public keys in KEYDIR to roots' authorized_keys file. +if [ -n "${KEYDIR}" ]; then + cat ${KEYDIR}/*.pub > ${tmpdir}/authorized_keys + if [ ! -s ${tmpdir}/authorized_keys ]; then + err 1 "no keys found in ${KEYDIR}" + fi + for user in ${KEYUSERS}; do + userdir=`awk -F: "{if (\\\$1 == \"${user}\") {print \\\$9; exit} }" ${DBDIR}/master.passwd` + gid=`awk -F: "{if (\\\$1 == \"${user}\") {print \\\$4; exit} }" ${DBDIR}/master.passwd` + group=`awk -F: "{if (\\\$3 == \"${gid}\") {print \\\$1; exit} }" ${DBDIR}/group` + if [ -z "${userdir}" ]; then + err 1 "${user}: not found in ${DBDIR}/master.passwd" + fi + echo ".${userdir}/.ssh type=dir mode=700 uname=${user} gname=${group}" >> ${manifest} + echo ".${userdir}/.ssh/authorized_keys type=file mode=600 uname=${user} gname=${group} contents=${tmpdir}/authorized_keys" >> ${manifest} + done +fi + +if [ -n "${SIZE}" ]; then +SIZEFLAG="-s ${SIZE}" +fi + +cd ${BSDROOT}; makefs ${DUPFLAG} -N ${DBDIR} ${SIZEFLAG} ${BFLAG} \ + -t ffs -f 256 ${IMGFILE} ${manifest} From owner-svn-src-all@FreeBSD.ORG Thu May 16 15:28:38 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id C83DA5F4; Thu, 16 May 2013 15:28:38 +0000 (UTC) (envelope-from sjg@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id BAB94E60; Thu, 16 May 2013 15:28:38 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.6/8.14.6) with ESMTP id r4GFSc8d094464; Thu, 16 May 2013 15:28:38 GMT (envelope-from sjg@svn.freebsd.org) Received: (from sjg@localhost) by svn.freebsd.org (8.14.6/8.14.5/Submit) id r4GFSc5t094460; Thu, 16 May 2013 15:28:38 GMT (envelope-from sjg@svn.freebsd.org) Message-Id: <201305161528.r4GFSc5t094460@svn.freebsd.org> From: "Simon J. Gerraty" Date: Thu, 16 May 2013 15:28:38 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r250699 - in head: share/mk usr.bin/make X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 16 May 2013 15:28:38 -0000 Author: sjg Date: Thu May 16 15:28:38 2013 New Revision: 250699 URL: http://svnweb.freebsd.org/changeset/base/250699 Log: Build bmake by default. If someone explicitly builds usr.bin/make while MK_BMAKE==yes, install it as 'fmake'. Reviewed by: brooks Modified: head/share/mk/bsd.own.mk head/usr.bin/make/Makefile Modified: head/share/mk/bsd.own.mk ============================================================================== --- head/share/mk/bsd.own.mk Thu May 16 14:38:12 2013 (r250698) +++ head/share/mk/bsd.own.mk Thu May 16 15:28:38 2013 (r250699) @@ -251,6 +251,7 @@ __DEFAULT_YES_OPTIONS = \ BIND_UTILS \ BINUTILS \ BLUETOOTH \ + BMAKE \ BOOT \ BSD_CPIO \ BSNMP \ @@ -360,7 +361,6 @@ __DEFAULT_NO_OPTIONS = \ BIND_LIBS \ BIND_SIGCHASE \ BIND_XML \ - BMAKE \ BSDCONFIG \ BSD_GREP \ CLANG_EXTRAS \ Modified: head/usr.bin/make/Makefile ============================================================================== --- head/usr.bin/make/Makefile Thu May 16 14:38:12 2013 (r250698) +++ head/usr.bin/make/Makefile Thu May 16 15:28:38 2013 (r250699) @@ -111,4 +111,11 @@ CFLAGS+= -DDEFSHELLNAME=\"${MAKE_SHELL}\ .error "MAKE_SHELL must be set to one of \"csh\", \"sh\" or \"ksh\"." .endif +.if ${MK_BMAKE} != "no" +# if we are here we don't want this called 'make' +PROG= fmake +fmake.1: make.1 + cp ${.ALLSRC} ${.TARGET} +.endif + .include From owner-svn-src-all@FreeBSD.ORG Thu May 16 16:20:19 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id 5F9B125D; Thu, 16 May 2013 16:20:19 +0000 (UTC) (envelope-from julian@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id 41FE617C; Thu, 16 May 2013 16:20:19 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.6/8.14.6) with ESMTP id r4GGKIT0012305; Thu, 16 May 2013 16:20:18 GMT (envelope-from julian@svn.freebsd.org) Received: (from julian@localhost) by svn.freebsd.org (8.14.6/8.14.5/Submit) id r4GGKIFI012296; Thu, 16 May 2013 16:20:18 GMT (envelope-from julian@svn.freebsd.org) Message-Id: <201305161620.r4GGKIFI012296@svn.freebsd.org> From: Julian Elischer Date: Thu, 16 May 2013 16:20:18 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r250700 - in head/sys: conf net netinet6 sys X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 16 May 2013 16:20:19 -0000 Author: julian Date: Thu May 16 16:20:17 2013 New Revision: 250700 URL: http://svnweb.freebsd.org/changeset/base/250700 Log: Finally change the mbuf to have its own fib field instead of stealing 4 flag bits. This was supposed to happen in 8.0, and again in 2012.. MFC after: never Modified: head/sys/conf/NOTES head/sys/net/route.c head/sys/netinet6/ip6_output.c head/sys/sys/mbuf.h Modified: head/sys/conf/NOTES ============================================================================== --- head/sys/conf/NOTES Thu May 16 15:28:38 2013 (r250699) +++ head/sys/conf/NOTES Thu May 16 16:20:17 2013 (r250700) @@ -571,7 +571,8 @@ options HWPMC_HOOKS # Other necessary options INET #Internet communications protocols options INET6 #IPv6 communications protocols -options ROUTETABLES=2 # max 16. 1 is back compatible. +options ROUTETABLES=2 # allocated fibs up to 65536. default is 1. + # but that would be a bad idea as they are large. options TCP_OFFLOAD # TCP offload support. Modified: head/sys/net/route.c ============================================================================== --- head/sys/net/route.c Thu May 16 15:28:38 2013 (r250699) +++ head/sys/net/route.c Thu May 16 16:20:17 2013 (r250700) @@ -68,8 +68,7 @@ #include -/* We use 4 bits in the mbuf flags, thus we are limited to 16 FIBS. */ -#define RT_MAXFIBS 16 +#define RT_MAXFIBS UINT16_MAX /* Kernel config default option. */ #ifdef ROUTETABLES @@ -86,17 +85,10 @@ #define RT_NUMFIBS 1 #endif +/* This is read-only.. */ u_int rt_numfibs = RT_NUMFIBS; SYSCTL_UINT(_net, OID_AUTO, fibs, CTLFLAG_RD, &rt_numfibs, 0, ""); -/* - * Allow the boot code to allow LESS than RT_MAXFIBS to be used. - * We can't do more because storage is statically allocated for now. - * (for compatibility reasons.. this will change. When this changes, code should - * be refactored to protocol independent parts and protocol dependent parts, - * probably hanging of domain(9) specific storage to not need the full - * fib * af RNH allocation etc. but allow tuning the number of tables per - * address family). - */ +/* and this can be set too big but will be fixed before it is used */ TUNABLE_INT("net.fibs", &rt_numfibs); /* Modified: head/sys/netinet6/ip6_output.c ============================================================================== --- head/sys/netinet6/ip6_output.c Thu May 16 15:28:38 2013 (r250699) +++ head/sys/netinet6/ip6_output.c Thu May 16 16:20:17 2013 (r250700) @@ -1126,7 +1126,7 @@ passout: IP6STAT_INC(ip6s_odropped); goto sendorfree; } - m->m_flags = m0->m_flags & M_COPYFLAGS; /* incl. FIB */ + m->m_flags = m0->m_flags & M_COPYFLAGS; *mnext = m; mnext = &m->m_nextpkt; m->m_data += max_linkhdr; @@ -1152,6 +1152,7 @@ passout: } m_cat(m, m_frgpart); m->m_pkthdr.len = len + hlen + sizeof(*ip6f); + m->m_pkthdr.fibnum = m0->m_pkthdr.fibnum; m->m_pkthdr.rcvif = NULL; ip6f->ip6f_reserved = 0; ip6f->ip6f_ident = id; Modified: head/sys/sys/mbuf.h ============================================================================== --- head/sys/sys/mbuf.h Thu May 16 15:28:38 2013 (r250699) +++ head/sys/sys/mbuf.h Thu May 16 16:20:17 2013 (r250700) @@ -129,6 +129,8 @@ struct pkthdr { u_int16_t vt_vtag; /* Ethernet 802.1p+q vlan tag */ u_int16_t vt_nrecs; /* # of IGMPv3 records in this chain */ } PH_vt; + u_int16_t fibnum; /* this packet should use this fib */ + u_int16_t pad2; /* align to 32 bits */ SLIST_HEAD(packet_tags, m_tag) tags; /* list of packet tags */ }; #define ether_vtag PH_vt.vt_vtag @@ -171,6 +173,7 @@ struct mbuf { #define m_type m_hdr.mh_type #define m_flags m_hdr.mh_flags #define m_nextpkt m_hdr.mh_nextpkt +#define m_fibnum m_hdr.mh_nextpkt #define m_act m_nextpkt #define m_pkthdr M_dat.MH.MH_pkthdr #define m_ext M_dat.MH.MH_dat.MH_ext @@ -205,12 +208,6 @@ struct mbuf { #define M_FLOWID 0x00400000 /* deprecated: flowid is valid */ #define M_HASHTYPEBITS 0x0F000000 /* mask of bits holding flowid hash type */ -/* - * For RELENG_{6,7} steal these flags for limited multiple routing table - * support. In RELENG_8 and beyond, use just one flag and a tag. - */ -#define M_FIB 0xF0000000 /* steal some bits to store fib number. */ - #define M_NOTIFICATION M_PROTO5 /* SCTP notification */ /* @@ -258,7 +255,7 @@ struct mbuf { */ #define M_COPYFLAGS \ (M_PKTHDR|M_EOR|M_RDONLY|M_PROTOFLAGS|M_SKIP_FIREWALL|M_BCAST|M_MCAST|\ - M_FRAG|M_FIRSTFRAG|M_LASTFRAG|M_VLANTAG|M_PROMISC|M_FIB|M_HASHTYPEBITS) + M_FRAG|M_FIRSTFRAG|M_LASTFRAG|M_VLANTAG|M_PROMISC|M_HASHTYPEBITS) /* * External buffer types: identify ext_buf type. @@ -1010,17 +1007,18 @@ m_tag_find(struct mbuf *m, int type, str m_tag_locate(m, MTAG_ABI_COMPAT, type, start)); } -/* XXX temporary FIB methods probably eventually use tags.*/ -#define M_FIBSHIFT 28 -#define M_FIBMASK 0x0F - -/* get the fib from an mbuf and if it is not set, return the default */ -#define M_GETFIB(_m) \ - ((((_m)->m_flags & M_FIB) >> M_FIBSHIFT) & M_FIBMASK) +static int inline +rt_m_getfib(struct mbuf *m) +{ + KASSERT(m->m_flags & M_EXT , ("attempt to set FIB on non header mbuf")); + return (m->m_pkthdr.fibnum); +} + +#define M_GETFIB(_m) rt_m_getfib(_m) #define M_SETFIB(_m, _fib) do { \ - _m->m_flags &= ~M_FIB; \ - _m->m_flags |= (((_fib) << M_FIBSHIFT) & M_FIB); \ + KASSERT((_m)->m_flags & M_EXT, ("No FIB on non header mbuf")); \ + ((_m)->m_pkthdr.fibnum) = (_fib); \ } while (0) #endif /* _KERNEL */ From owner-svn-src-all@FreeBSD.ORG Thu May 16 16:46:03 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id 2FE4A69F; Thu, 16 May 2013 16:46:03 +0000 (UTC) (envelope-from dteske@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id 225F82B1; Thu, 16 May 2013 16:46:03 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.6/8.14.6) with ESMTP id r4GGk3tE021565; Thu, 16 May 2013 16:46:03 GMT (envelope-from dteske@svn.freebsd.org) Received: (from dteske@localhost) by svn.freebsd.org (8.14.6/8.14.5/Submit) id r4GGk3em021564; Thu, 16 May 2013 16:46:03 GMT (envelope-from dteske@svn.freebsd.org) Message-Id: <201305161646.r4GGk3em021564@svn.freebsd.org> From: Devin Teske Date: Thu, 16 May 2013 16:46:02 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r250701 - head/usr.sbin/bsdconfig/share X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 16 May 2013 16:46:03 -0000 Author: dteske Date: Thu May 16 16:46:02 2013 New Revision: 250701 URL: http://svnweb.freebsd.org/changeset/base/250701 Log: Add a handy function for truncating variables to a specific byte-length. It should be noted that newlines are both preserved and included in said byte- count. If you want to truncate single-line values without regard to line termination, there's always f_substr() which already exists herein. Modified: head/usr.sbin/bsdconfig/share/strings.subr Modified: head/usr.sbin/bsdconfig/share/strings.subr ============================================================================== --- head/usr.sbin/bsdconfig/share/strings.subr Thu May 16 16:20:17 2013 (r250700) +++ head/usr.sbin/bsdconfig/share/strings.subr Thu May 16 16:46:02 2013 (r250701) @@ -51,6 +51,26 @@ f_substr() echo "$string" | awk "{ print substr(\$0, $start, $len) }" } +# f_snprintf $var_to_set $size $format ... +# +# Similar to snprintf(3), write at most $size number of bytes into $var_to_set +# using printf(1) syntax (`$format ...'). The value of $var_to_set is NULL +# unless at-least one byte is stored from the output. +# +f_snprintf() +{ + local __var_to_set="$1" __size="$2" + shift 2 # var_to_set/size + eval "$__var_to_set"=\$\( printf \"\$@\" \| awk -v max=\"\$__size\" \'' + { + len = length($0) + max -= len + print substr($0,0,(max > 0 ? len : max + len)) + if ( max < 0 ) exit + max-- + }'\' \) +} + # f_longest_line_length # # Simple wrapper to an awk(1) script to print the length of the longest line of From owner-svn-src-all@FreeBSD.ORG Thu May 16 16:51:53 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id 4F235961; Thu, 16 May 2013 16:51:53 +0000 (UTC) (envelope-from dteske@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id 4103131F; Thu, 16 May 2013 16:51:53 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.6/8.14.6) with ESMTP id r4GGprEW024154; Thu, 16 May 2013 16:51:53 GMT (envelope-from dteske@svn.freebsd.org) Received: (from dteske@localhost) by svn.freebsd.org (8.14.6/8.14.5/Submit) id r4GGprED024153; Thu, 16 May 2013 16:51:53 GMT (envelope-from dteske@svn.freebsd.org) Message-Id: <201305161651.r4GGprED024153@svn.freebsd.org> From: Devin Teske Date: Thu, 16 May 2013 16:51:53 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r250702 - head/usr.sbin/bsdconfig/share X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 16 May 2013 16:51:53 -0000 Author: dteske Date: Thu May 16 16:51:52 2013 New Revision: 250702 URL: http://svnweb.freebsd.org/changeset/base/250702 Log: Fix a typo in a comment. Modified: head/usr.sbin/bsdconfig/share/strings.subr Modified: head/usr.sbin/bsdconfig/share/strings.subr ============================================================================== --- head/usr.sbin/bsdconfig/share/strings.subr Thu May 16 16:46:02 2013 (r250701) +++ head/usr.sbin/bsdconfig/share/strings.subr Thu May 16 16:51:52 2013 (r250702) @@ -204,7 +204,7 @@ f_uridecode() # f_replaceall $string $find $replace [$var_to_set] # -# Replace all occurrences of $find in $sting with $replace. If $var_to_set is +# Replace all occurrences of $find in $string with $replace. If $var_to_set is # either missing or NULL, the variable name is produced on standard out for # capturing in a sub-shell (which is less recommended due to performance # degradation). From owner-svn-src-all@FreeBSD.ORG Thu May 16 17:45:01 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id BB46D4C1; Thu, 16 May 2013 17:45:01 +0000 (UTC) (envelope-from adrian@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id AD3EA7D6; Thu, 16 May 2013 17:45:01 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.6/8.14.6) with ESMTP id r4GHj1fj042320; Thu, 16 May 2013 17:45:01 GMT (envelope-from adrian@svn.freebsd.org) Received: (from adrian@localhost) by svn.freebsd.org (8.14.6/8.14.5/Submit) id r4GHj1fm042318; Thu, 16 May 2013 17:45:01 GMT (envelope-from adrian@svn.freebsd.org) Message-Id: <201305161745.r4GHj1fm042318@svn.freebsd.org> From: Adrian Chadd Date: Thu, 16 May 2013 17:45:01 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r250703 - head/sys/dev/ath X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 16 May 2013 17:45:01 -0000 Author: adrian Date: Thu May 16 17:45:01 2013 New Revision: 250703 URL: http://svnweb.freebsd.org/changeset/base/250703 Log: Dump out the holding buffer descriptor contents and addresses stopping DMA. Modified: head/sys/dev/ath/if_ath.c Modified: head/sys/dev/ath/if_ath.c ============================================================================== --- head/sys/dev/ath/if_ath.c Thu May 16 16:51:52 2013 (r250702) +++ head/sys/dev/ath/if_ath.c Thu May 16 17:45:01 2013 (r250703) @@ -4602,15 +4602,25 @@ ath_tx_stopdma(struct ath_softc *sc, str struct ath_hal *ah = sc->sc_ah; DPRINTF(sc, ATH_DEBUG_RESET, - "%s: tx queue [%u] %p, active=%d, hwpending=%d, flags 0x%08x, link %p\n", + "%s: tx queue [%u] %p, active=%d, hwpending=%d, flags 0x%08x, " + "link %p, holdingbf=%p\n", __func__, txq->axq_qnum, (caddr_t)(uintptr_t) ath_hal_gettxbuf(ah, txq->axq_qnum), (int) (!! ath_hal_txqenabled(ah, txq->axq_qnum)), (int) ath_hal_numtxpending(ah, txq->axq_qnum), txq->axq_flags, - txq->axq_link); + txq->axq_link, + txq->axq_holdingbf); + (void) ath_hal_stoptxdma(ah, txq->axq_qnum); + +#ifdef ATH_DEBUG + if ((sc->sc_debug & ATH_DEBUG_RESET) + && (txq->axq_holdingbf != NULL)) { + ath_printtxbuf(sc, txq->axq_holdingbf, txq->axq_qnum, 0, 0); + } +#endif } int From owner-svn-src-all@FreeBSD.ORG Thu May 16 17:46:32 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id D0990660; Thu, 16 May 2013 17:46:32 +0000 (UTC) (envelope-from adrian@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id C27F17F2; Thu, 16 May 2013 17:46:32 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.6/8.14.6) with ESMTP id r4GHkWps042619; Thu, 16 May 2013 17:46:32 GMT (envelope-from adrian@svn.freebsd.org) Received: (from adrian@localhost) by svn.freebsd.org (8.14.6/8.14.5/Submit) id r4GHkW5L042618; Thu, 16 May 2013 17:46:32 GMT (envelope-from adrian@svn.freebsd.org) Message-Id: <201305161746.r4GHkW5L042618@svn.freebsd.org> From: Adrian Chadd Date: Thu, 16 May 2013 17:46:32 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r250704 - head/sys/dev/ath X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 16 May 2013 17:46:32 -0000 Author: adrian Date: Thu May 16 17:46:32 2013 New Revision: 250704 URL: http://svnweb.freebsd.org/changeset/base/250704 Log: Limit the number of software queued frames when doing non-aggregation. This should prevent the TX queue being filled with non-aggregate frames, causing starvation and non-fair queue behaviour. Modified: head/sys/dev/ath/if_ath_tx.c Modified: head/sys/dev/ath/if_ath_tx.c ============================================================================== --- head/sys/dev/ath/if_ath_tx.c Thu May 16 17:45:01 2013 (r250703) +++ head/sys/dev/ath/if_ath_tx.c Thu May 16 17:46:32 2013 (r250704) @@ -5449,8 +5449,12 @@ ath_txq_sched(struct ath_softc *sc, stru if (tid->axq_depth != 0) ath_tx_tid_sched(sc, tid); - /* Give the software queue time to aggregate more packets */ - if (txq->axq_aggr_depth >= sc->sc_hwq_limit) { + /* + * Give the software queue time to aggregate more + * packets. If we aren't running aggregation then + * we should still limit the hardware queue depth. + */ + if (txq->axq_depth >= sc->sc_hwq_limit) { break; } From owner-svn-src-all@FreeBSD.ORG Thu May 16 17:53:12 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id D193C9C5; Thu, 16 May 2013 17:53:12 +0000 (UTC) (envelope-from adrian@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id C2FEA84F; Thu, 16 May 2013 17:53:12 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.6/8.14.6) with ESMTP id r4GHrCkm045358; Thu, 16 May 2013 17:53:12 GMT (envelope-from adrian@svn.freebsd.org) Received: (from adrian@localhost) by svn.freebsd.org (8.14.6/8.14.5/Submit) id r4GHrCpZ045357; Thu, 16 May 2013 17:53:12 GMT (envelope-from adrian@svn.freebsd.org) Message-Id: <201305161753.r4GHrCpZ045357@svn.freebsd.org> From: Adrian Chadd Date: Thu, 16 May 2013 17:53:12 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r250705 - head/sys/dev/ath X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 16 May 2013 17:53:12 -0000 Author: adrian Date: Thu May 16 17:53:12 2013 New Revision: 250705 URL: http://svnweb.freebsd.org/changeset/base/250705 Log: Tidy up the debugging - don't bother printing out TID pointers; now that we are printing out the MAC address in these fields, just printing out the TID is enough. Modified: head/sys/dev/ath/if_ath_tx.c Modified: head/sys/dev/ath/if_ath_tx.c ============================================================================== --- head/sys/dev/ath/if_ath_tx.c Thu May 16 17:46:32 2013 (r250704) +++ head/sys/dev/ath/if_ath_tx.c Thu May 16 17:53:12 2013 (r250705) @@ -3456,9 +3456,9 @@ ath_tx_tid_bar_suspend(struct ath_softc ATH_TX_LOCK_ASSERT(sc); DPRINTF(sc, ATH_DEBUG_SW_TX_BAR, - "%s: tid=%p, bar_wait=%d, bar_tx=%d, called\n", + "%s: tid=%d, bar_wait=%d, bar_tx=%d, called\n", __func__, - tid, + tid->tid, tid->bar_wait, tid->bar_tx); @@ -3490,19 +3490,21 @@ ath_tx_tid_bar_unsuspend(struct ath_soft ATH_TX_LOCK_ASSERT(sc); DPRINTF(sc, ATH_DEBUG_SW_TX_BAR, - "%s: %6D: tid=%p, called\n", + "%s: %6D: TID=%d, called\n", __func__, tid->an->an_node.ni_macaddr, ":", - tid); + tid->tid); if (tid->bar_tx == 0 || tid->bar_wait == 0) { device_printf(sc->sc_dev, - "%s: %6D: bar_tx=%d, bar_wait=%d: ?\n", + "%s: %6D: TID=%d, bar_tx=%d, bar_wait=%d: ?\n", __func__, tid->an->an_node.ni_macaddr, ":", - tid->bar_tx, tid->bar_wait); + tid->tid, + tid->bar_tx, + tid->bar_wait); } tid->bar_tx = tid->bar_wait = 0; @@ -3524,11 +3526,11 @@ ath_tx_tid_bar_tx_ready(struct ath_softc return (0); DPRINTF(sc, ATH_DEBUG_SW_TX_BAR, - "%s: %6D: tid=%p (%d), bar ready\n", + "%s: %6D: TID=%d, bar ready\n", __func__, tid->an->an_node.ni_macaddr, ":", - tid, tid->tid); + tid->tid); return (1); } @@ -3553,11 +3555,11 @@ ath_tx_tid_bar_tx(struct ath_softc *sc, ATH_TX_LOCK_ASSERT(sc); DPRINTF(sc, ATH_DEBUG_SW_TX_BAR, - "%s: %6D: tid=%p, called\n", + "%s: %6D: TID=%d, called\n", __func__, tid->an->an_node.ni_macaddr, ":", - tid); + tid->tid); tap = ath_tx_get_tx_tid(tid->an, tid->tid); @@ -3566,11 +3568,11 @@ ath_tx_tid_bar_tx(struct ath_softc *sc, */ if (tid->bar_wait == 0 || tid->bar_tx == 1) { device_printf(sc->sc_dev, - "%s: %6D: tid=%p, bar_tx=%d, bar_wait=%d: ?\n", + "%s: %6D: TID=%d, bar_tx=%d, bar_wait=%d: ?\n", __func__, tid->an->an_node.ni_macaddr, ":", - tid, + tid->tid, tid->bar_tx, tid->bar_wait); return; @@ -3579,11 +3581,11 @@ ath_tx_tid_bar_tx(struct ath_softc *sc, /* Don't do anything if we still have pending frames */ if (tid->hwq_depth > 0) { DPRINTF(sc, ATH_DEBUG_SW_TX_BAR, - "%s: %6D: tid=%p, hwq_depth=%d, waiting\n", + "%s: %6D: TID=%d, hwq_depth=%d, waiting\n", __func__, tid->an->an_node.ni_macaddr, ":", - tid, + tid->tid, tid->hwq_depth); return; } @@ -3604,11 +3606,11 @@ ath_tx_tid_bar_tx(struct ath_softc *sc, * XXX verify this is _actually_ the valid value to begin at! */ DPRINTF(sc, ATH_DEBUG_SW_TX_BAR, - "%s: %6D: tid=%p, new BAW left edge=%d\n", + "%s: %6D: TID=%d, new BAW left edge=%d\n", __func__, tid->an->an_node.ni_macaddr, ":", - tid, + tid->tid, tap->txa_start); /* Try sending the BAR frame */ @@ -3624,11 +3626,11 @@ ath_tx_tid_bar_tx(struct ath_softc *sc, /* Failure? For now, warn loudly and continue */ ATH_TX_LOCK(sc); device_printf(sc->sc_dev, - "%s: %6D: tid=%p, failed to TX BAR, continue!\n", + "%s: %6D: TID=%d, failed to TX BAR, continue!\n", __func__, tid->an->an_node.ni_macaddr, ":", - tid); + tid->tid); ath_tx_tid_bar_unsuspend(sc, tid); } @@ -5783,12 +5785,10 @@ ath_bar_response(struct ieee80211_node * int attempts = tap->txa_attempts; DPRINTF(sc, ATH_DEBUG_SW_TX_BAR, - "%s: %6D: called; tap=%p, atid=%p, txa_tid=%d, atid->tid=%d, status=%d, attempts=%d\n", + "%s: %6D: called; txa_tid=%d, atid->tid=%d, status=%d, attempts=%d\n", __func__, ni->ni_macaddr, ":", - tap, - atid, tap->txa_tid, atid->tid, status, @@ -5833,10 +5833,11 @@ ath_addba_response_timeout(struct ieee80 struct ath_tid *atid = &an->an_tid[tid]; DPRINTF(sc, ATH_DEBUG_SW_TX_CTRL, - "%s: %6D: called; resuming\n", + "%s: %6D: TID=%d, called; resuming\n", __func__, ni->ni_macaddr, - ":"); + ":", + tid); ATH_TX_LOCK(sc); atid->addba_tx_pending = 0; From owner-svn-src-all@FreeBSD.ORG Thu May 16 18:06:43 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id 2B02AD0F; Thu, 16 May 2013 18:06:43 +0000 (UTC) (envelope-from bjkfbsd@gmail.com) Received: from mail-qe0-f44.google.com (mail-qe0-f44.google.com [209.85.128.44]) by mx1.freebsd.org (Postfix) with ESMTP id B143A8E1; Thu, 16 May 2013 18:06:42 +0000 (UTC) Received: by mail-qe0-f44.google.com with SMTP id s14so2121586qeb.17 for ; Thu, 16 May 2013 11:06:41 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:x-received:in-reply-to:references:date:message-id :subject:from:to:cc:content-type; bh=2NvMXdFg/EG0TzDOQck4DsUx03WKsGuRhwG+e3dzquM=; b=kbRrj3HmSRCC04pMPRIYkXmB037JEA7tpTtQjxuN9qfGizH5Si1jOMLC9JJCx5eqSY GVTdkxsO5MsjEPocwx+R/VVaJFpDzp/XJi8kWSvSkQElA/LG6Eg56VUoNLaR7gLLGXOt gYK6JfnmLrV8ZWcIDRnV+Y5tVZv38O2IIGU2IER3w/8A58O33H/wkITHJHYW4FbIcJf0 ycgbV+a4V8Mnq9V8GSq/s83DkRG+vsZcK6UmCGlDAbtAOL42T++QDviJuf7us5+1EjrA eliYtS5Mz/qo3owWnHPKQZmEEsALXVvkJEuPpPUI2vdcCccllh171lFswmTSY36JD4oq /VCA== MIME-Version: 1.0 X-Received: by 10.229.67.197 with SMTP id s5mr1111181qci.72.1368727601743; Thu, 16 May 2013 11:06:41 -0700 (PDT) Received: by 10.49.3.193 with HTTP; Thu, 16 May 2013 11:06:41 -0700 (PDT) In-Reply-To: <201305161620.r4GGKIFI012296@svn.freebsd.org> References: <201305161620.r4GGKIFI012296@svn.freebsd.org> Date: Thu, 16 May 2013 14:06:41 -0400 Message-ID: Subject: Re: svn commit: r250700 - in head/sys: conf net netinet6 sys From: Benjamin Kaduk To: Julian Elischer Content-Type: text/plain; charset=ISO-8859-1 X-Content-Filtered-By: Mailman/MimeDel 2.1.14 Cc: "svn-src-head@freebsd.org" , "svn-src-all@freebsd.org" , "src-committers@freebsd.org" X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 16 May 2013 18:06:43 -0000 On Thu, May 16, 2013 at 12:20 PM, Julian Elischer wrote: > Author: julian > Date: Thu May 16 16:20:17 2013 > New Revision: 250700 > URL: http://svnweb.freebsd.org/changeset/base/250700 > > Log: > Finally change the mbuf to have its own fib field instead of stealing > 4 flag bits. This was supposed to happen in 8.0, and again in 2012.. > Are you planning to update the text of setfib.2 describing the old limit? -Ben From owner-svn-src-all@FreeBSD.ORG Thu May 16 18:13:11 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id 4F78DF5A; Thu, 16 May 2013 18:13:11 +0000 (UTC) (envelope-from jh@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id 423B3936; Thu, 16 May 2013 18:13:11 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.6/8.14.6) with ESMTP id r4GIDBwA052710; Thu, 16 May 2013 18:13:11 GMT (envelope-from jh@svn.freebsd.org) Received: (from jh@localhost) by svn.freebsd.org (8.14.6/8.14.5/Submit) id r4GIDBwq052709; Thu, 16 May 2013 18:13:11 GMT (envelope-from jh@svn.freebsd.org) Message-Id: <201305161813.r4GIDBwq052709@svn.freebsd.org> From: Jaakko Heinonen Date: Thu, 16 May 2013 18:13:11 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r250706 - head/sys/kern X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 16 May 2013 18:13:11 -0000 Author: jh Date: Thu May 16 18:13:10 2013 New Revision: 250706 URL: http://svnweb.freebsd.org/changeset/base/250706 Log: A library function shall not set errno to 0. Reviewed by: mdf Modified: head/sys/kern/subr_sbuf.c Modified: head/sys/kern/subr_sbuf.c ============================================================================== --- head/sys/kern/subr_sbuf.c Thu May 16 17:53:12 2013 (r250705) +++ head/sys/kern/subr_sbuf.c Thu May 16 18:13:10 2013 (r250706) @@ -706,9 +706,10 @@ sbuf_finish(struct sbuf *s) #ifdef _KERNEL return (s->s_error); #else - errno = s->s_error; - if (s->s_error) + if (s->s_error != 0) { + errno = s->s_error; return (-1); + } return (0); #endif } From owner-svn-src-all@FreeBSD.ORG Thu May 16 18:37:14 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id B02567A8; Thu, 16 May 2013 18:37:14 +0000 (UTC) (envelope-from brooks@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id 8728DA28; Thu, 16 May 2013 18:37:14 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.6/8.14.6) with ESMTP id r4GIbEml060621; Thu, 16 May 2013 18:37:14 GMT (envelope-from brooks@svn.freebsd.org) Received: (from brooks@localhost) by svn.freebsd.org (8.14.6/8.14.5/Submit) id r4GIbESa060620; Thu, 16 May 2013 18:37:14 GMT (envelope-from brooks@svn.freebsd.org) Message-Id: <201305161837.r4GIbESa060620@svn.freebsd.org> From: Brooks Davis Date: Thu, 16 May 2013 18:37:14 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r250707 - head X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 16 May 2013 18:37:14 -0000 Author: brooks Date: Thu May 16 18:37:14 2013 New Revision: 250707 URL: http://svnweb.freebsd.org/changeset/base/250707 Log: Implement NO_ROOT support for distributekernel and packagekernel. Modified: head/Makefile.inc1 Modified: head/Makefile.inc1 ============================================================================== --- head/Makefile.inc1 Thu May 16 18:13:10 2013 (r250706) +++ head/Makefile.inc1 Thu May 16 18:37:14 2013 (r250707) @@ -1023,25 +1023,50 @@ distributekernel distributekernel.debug: @echo "ERROR: No kernel \"${KERNCONF}\" to install."; \ false .endif + mkdir -p ${DESTDIR}/${DISTDIR} +.if defined(NO_ROOT) + echo "#${MTREE_MAGIC}" > ${DESTDIR}/${DISTDIR}/kernel.premeta +.endif cd ${KRNLOBJDIR}/${INSTALLKERNEL}; \ - ${CROSSENV} PATH=${TMPPATH} ${MAKE} KERNEL=${INSTKERNNAME} \ - DESTDIR=${DESTDIR}/${DISTDIR}/kernel \ + ${IMAKEENV} ${IMAKE_INSTALL:S/METALOG/kernel.premeta/} \ + ${IMAKE_MTREE} PATH=${TMPPATH} ${MAKE} KERNEL=${INSTKERNNAME} \ + DESTDIR=${INSTALL_DDIR:S://:/:g:C:/$::}/kernel \ ${.TARGET:S/distributekernel/install/} + sed -e 's|^./kernel|.|' ${DESTDIR}/${DISTDIR}/kernel.premeta > \ + ${DESTDIR}/${DISTDIR}/kernel.meta .for _kernel in ${BUILDKERNELS:S/${INSTALLKERNEL}//} +.if defined(NO_ROOT) + echo "#${MTREE_MAGIC}" > ${DESTDIR}/${DISTDIR}/kernel.${_kernel}.premeta +.endif cd ${KRNLOBJDIR}/${_kernel}; \ - ${CROSSENV} PATH=${TMPPATH} ${MAKE} \ + ${IMAKEENV} ${IMAKE_INSTALL:S/METALOG/kernel.${_kernel}.premeta/} \ + ${IMAKE_MTREE} PATH=${TMPPATH} ${MAKE} \ KERNEL=${INSTKERNNAME}.${_kernel} \ - DESTDIR=${DESTDIR}/${DISTDIR}/kernel.${_kernel} \ + DESTDIR=${INSTALL_DDIR:S://:/:g:C:/$::}/kernel.${_kernel} \ ${.TARGET:S/distributekernel/install/} + sed -e 's|^./kernel|.|' \ + ${DESTDIR}/${DISTDIR}/kernel.${_kernel}.premeta > \ + ${DESTDIR}/${DISTDIR}/kernel.${_kernel}.meta .endfor packagekernel: +.if defined(NO_ROOT) + cd ${DESTDIR}/${DISTDIR}/kernel; \ + tar cvJf ${DESTDIR}/${DISTDIR}/kernel.txz \ + @${DESTDIR}/${DISTDIR}/kernel.meta +.for _kernel in ${BUILDKERNELS:S/${INSTALLKERNEL}//} + cd ${DESTDIR}/${DISTDIR}/kernel.${_kernel}; \ + tar cvJf ${DESTDIR}/${DISTDIR}/kernel.${_kernel}.txz \ + @${DESTDIR}/${DISTDIR}/kernel.${_kernel}.meta +.endfor +.else cd ${DESTDIR}/${DISTDIR}/kernel; \ tar cvJf ${DESTDIR}/${DISTDIR}/kernel.txz . .for _kernel in ${BUILDKERNELS:S/${INSTALLKERNEL}//} cd ${DESTDIR}/${DISTDIR}/kernel.${_kernel}; \ tar cvJf ${DESTDIR}/${DISTDIR}/kernel.${_kernel}.txz . .endfor +.endif # # doxygen From owner-svn-src-all@FreeBSD.ORG Thu May 16 19:19:10 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id D9372F0B; Thu, 16 May 2013 19:19:10 +0000 (UTC) (envelope-from edschouten@gmail.com) Received: from mail-ve0-x235.google.com (mail-ve0-x235.google.com [IPv6:2607:f8b0:400c:c01::235]) by mx1.freebsd.org (Postfix) with ESMTP id 67F7EBEF; Thu, 16 May 2013 19:19:10 +0000 (UTC) Received: by mail-ve0-f181.google.com with SMTP id pb11so3235997veb.40 for ; Thu, 16 May 2013 12:19:09 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:x-received:sender:in-reply-to:references:date :x-google-sender-auth:message-id:subject:from:to:cc:content-type; bh=h4ztKMRC0yyguOXijymL1z/WDZJTxqPO3um/qU0rwxQ=; b=Yt8zuMseMdZWr+lP+rfR2aLeMSz7HvFRgC+TEJ3qA2uD2TOgk7c8IFKZ8Gs0UIZLTc JwDcLXVNQf7Eo5JzPLYf9BX0NiXXEwY/+oh/yAyZ65KnEnXkPkUvPSb3k8ppr7mGnonS m5ctgVhl5le6H52r8R1CDT+gi7CNYX3MaOIjbQKQmnEq2abZKGc2Wg2unMmPXJ9THMTz qoh2mgYEyEbe6ZeGD2luCWIZJHBpURAJZ30ZX9tx0QJFy3wD7wrxcuIuIVO4oKzwNOd2 21o7TouJLoVhlsD4j5g6cjwQUQo+usX4WM39r5ck9MZVoN7jl8Ur6rvepwru4SvyoZoQ ws6w== MIME-Version: 1.0 X-Received: by 10.52.175.71 with SMTP id by7mr24157435vdc.85.1368731949827; Thu, 16 May 2013 12:19:09 -0700 (PDT) Sender: edschouten@gmail.com Received: by 10.220.72.7 with HTTP; Thu, 16 May 2013 12:19:09 -0700 (PDT) In-Reply-To: <201305161620.r4GGKIFI012296@svn.freebsd.org> References: <201305161620.r4GGKIFI012296@svn.freebsd.org> Date: Thu, 16 May 2013 21:19:09 +0200 X-Google-Sender-Auth: 3YXeCrAcw80jzufA89WqTEFFDEM Message-ID: Subject: Re: svn commit: r250700 - in head/sys: conf net netinet6 sys From: Ed Schouten To: Julian Elischer Content-Type: text/plain; charset=UTF-8 Cc: svn-src-head@freebsd.org, svn-src-all@freebsd.org, src-committers@freebsd.org X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 16 May 2013 19:19:10 -0000 Hey Julian, 2013/5/16 Julian Elischer : > #define M_SETFIB(_m, _fib) do { \ > - _m->m_flags &= ~M_FIB; \ > - _m->m_flags |= (((_fib) << M_FIBSHIFT) & M_FIB); \ > + KASSERT((_m)->m_flags & M_EXT, ("No FIB on non header mbuf")); \ > + ((_m)->m_pkthdr.fibnum) = (_fib); \ > } while (0) This KASSERT triggers on my box at home. Sorry, but busy right now, so I can't spend too much time debugging this. Right after getting a DHCPACK on bootup, the box panics. Copied by hand: panic: No FIB on non header mbuf .. db> bt kassert_panic() rt_newaddrmsg_fib() rtinit1() in_scrubprefix() in_control() ifioctl() kern_ioctl() sys_ioctl() amd64_syscall() Xfast_syscall() -- Ed Schouten From owner-svn-src-all@FreeBSD.ORG Thu May 16 19:39:12 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id 5DD8D355; Thu, 16 May 2013 19:39:12 +0000 (UTC) (envelope-from mckusick@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id 4F56FD03; Thu, 16 May 2013 19:39:12 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.6/8.14.6) with ESMTP id r4GJdCPT081630; Thu, 16 May 2013 19:39:12 GMT (envelope-from mckusick@svn.freebsd.org) Received: (from mckusick@localhost) by svn.freebsd.org (8.14.6/8.14.5/Submit) id r4GJdC4E081629; Thu, 16 May 2013 19:39:12 GMT (envelope-from mckusick@svn.freebsd.org) Message-Id: <201305161939.r4GJdC4E081629@svn.freebsd.org> From: Kirk McKusick Date: Thu, 16 May 2013 19:39:12 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r250708 - head/sbin/dumpfs X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 16 May 2013 19:39:12 -0000 Author: mckusick Date: Thu May 16 19:39:11 2013 New Revision: 250708 URL: http://svnweb.freebsd.org/changeset/base/250708 Log: Clean up trailing whitespace. Submitted by: Andy Kosela MFC after: 1 week Modified: head/sbin/dumpfs/dumpfs.c Modified: head/sbin/dumpfs/dumpfs.c ============================================================================== --- head/sbin/dumpfs/dumpfs.c Thu May 16 18:37:14 2013 (r250707) +++ head/sbin/dumpfs/dumpfs.c Thu May 16 19:39:11 2013 (r250708) @@ -197,15 +197,15 @@ dumpfs(const char *name) "maxbsize", afs.fs_maxbsize, afs.fs_maxbpg, afs.fs_maxcontig, afs.fs_contigsumsize); printf("nbfree\t%jd\tndir\t%jd\tnifree\t%jd\tnffree\t%jd\n", - (intmax_t)afs.fs_cstotal.cs_nbfree, + (intmax_t)afs.fs_cstotal.cs_nbfree, (intmax_t)afs.fs_cstotal.cs_ndir, - (intmax_t)afs.fs_cstotal.cs_nifree, + (intmax_t)afs.fs_cstotal.cs_nifree, (intmax_t)afs.fs_cstotal.cs_nffree); printf("bpg\t%d\tfpg\t%d\tipg\t%d\tunrefs\t%jd\n", afs.fs_fpg / afs.fs_frag, afs.fs_fpg, afs.fs_ipg, (intmax_t)afs.fs_unrefs); printf("nindir\t%d\tinopb\t%d\tmaxfilesize\t%ju\n", - afs.fs_nindir, afs.fs_inopb, + afs.fs_nindir, afs.fs_inopb, (uintmax_t)afs.fs_maxfilesize); printf("sbsize\t%d\tcgsize\t%d\tcsaddr\t%jd\tcssize\t%d\n", afs.fs_sbsize, afs.fs_cgsize, (intmax_t)afs.fs_csaddr, From owner-svn-src-all@FreeBSD.ORG Thu May 16 19:44:52 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id 062F4633; Thu, 16 May 2013 19:44:52 +0000 (UTC) (envelope-from imp@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id EB68ED46; Thu, 16 May 2013 19:44:51 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.6/8.14.6) with ESMTP id r4GJipZe084344; Thu, 16 May 2013 19:44:51 GMT (envelope-from imp@svn.freebsd.org) Received: (from imp@localhost) by svn.freebsd.org (8.14.6/8.14.5/Submit) id r4GJipxH084343; Thu, 16 May 2013 19:44:51 GMT (envelope-from imp@svn.freebsd.org) Message-Id: <201305161944.r4GJipxH084343@svn.freebsd.org> From: Warner Losh Date: Thu, 16 May 2013 19:44:51 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r250709 - head/sys/dev/mmc X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 16 May 2013 19:44:52 -0000 Author: imp Date: Thu May 16 19:44:51 2013 New Revision: 250709 URL: http://svnweb.freebsd.org/changeset/base/250709 Log: When reporting the user readable size, round up. Several SD cards not only use SI units, but also are a couple of percent short. If you need to know the exact size, diskinfo will return exact results. Modified: head/sys/dev/mmc/mmcsd.c Modified: head/sys/dev/mmc/mmcsd.c ============================================================================== --- head/sys/dev/mmc/mmcsd.c Thu May 16 19:39:11 2013 (r250708) +++ head/sys/dev/mmc/mmcsd.c Thu May 16 19:44:51 2013 (r250709) @@ -162,6 +162,7 @@ mmcsd_attach(device_t dev) d->d_stripesize = mmc_get_erase_sector(dev) * d->d_sectorsize; d->d_unit = device_get_unit(dev); d->d_flags = DISKFLAG_CANDELETE; + d->d_delmaxsize = mmc_get_erase_sector(dev) * d->d_sectorsize * 1; /* conservative */ /* * Display in most natural units. There's no cards < 1MB. The SD * standard goes to 2GiB due to its reliance on FAT, but the data @@ -170,13 +171,14 @@ mmcsd_attach(device_t dev) * data format supports up to 2TiB however. 2048GB isn't too ugly, so * we note it in passing here and don't add the code to print * TB). Since these cards are sold in terms of MB and GB not MiB and - * GiB, report them like that. + * GiB, report them like that. We also round to the nearest unit, since + * many cards are a few percent short, even of the power of 10 size. */ - mb = d->d_mediasize / 1000000; + mb = (d->d_mediasize + 1000000 / 2 - 1) / 1000000; unit = 'M'; if (mb >= 1000) { unit = 'G'; - mb /= 1000; + mb = (mb + 1000 / 2 - 1) / 1000; } /* * Report the clock speed of the underlying hardware, which might be From owner-svn-src-all@FreeBSD.ORG Thu May 16 20:07:09 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id C9392D1A; Thu, 16 May 2013 20:07:09 +0000 (UTC) (envelope-from mckusick@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id A1BEFE3C; Thu, 16 May 2013 20:07:09 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.6/8.14.6) with ESMTP id r4GK79e6092125; Thu, 16 May 2013 20:07:09 GMT (envelope-from mckusick@svn.freebsd.org) Received: (from mckusick@localhost) by svn.freebsd.org (8.14.6/8.14.5/Submit) id r4GK79bm092123; Thu, 16 May 2013 20:07:09 GMT (envelope-from mckusick@svn.freebsd.org) Message-Id: <201305162007.r4GK79bm092123@svn.freebsd.org> From: Kirk McKusick Date: Thu, 16 May 2013 20:07:09 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r250710 - head/sbin/dumpfs X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 16 May 2013 20:07:09 -0000 Author: mckusick Date: Thu May 16 20:07:08 2013 New Revision: 250710 URL: http://svnweb.freebsd.org/changeset/base/250710 Log: When running the -m option to generate a newfs(8) command suitable for recreating the filesystem, check for and output the -i, -k, and -l options if appropriate. Note the remaining deficiencies of the -m option in the dumpfs(8) manual page. Specifically that newfs(8) options -E, -R, -S, and -T options are not handled and that -p is not useful so is omitted. Also document that newfs(8) options -n and -r are neither checked for nor output but should be. The -r flag is needed if the filesystem uses gjournal(8). PR: bin/163992 Reported by: Dieter Submitted by: Andy Kosela MFC after: 1 week Modified: head/sbin/dumpfs/dumpfs.8 head/sbin/dumpfs/dumpfs.c Modified: head/sbin/dumpfs/dumpfs.8 ============================================================================== --- head/sbin/dumpfs/dumpfs.8 Thu May 16 19:44:51 2013 (r250709) +++ head/sbin/dumpfs/dumpfs.8 Thu May 16 20:07:08 2013 (r250710) @@ -28,7 +28,7 @@ .\" @(#)dumpfs.8 8.1 (Berkeley) 6/5/93 .\" $FreeBSD$ .\" -.Dd Jul 14, 2011 +.Dd May 16, 2013 .Dt DUMPFS 8 .Os .Sh NAME @@ -76,6 +76,27 @@ is specified, a .Xr newfs 8 command is printed that can be used to generate a new file system with equivalent settings. +Please note that +.Xr newfs 8 +options +.Fl E , +.Fl R , +.Fl S , +and +.Fl T +are not handled and +.Fl p +is not useful in this case so is omitted. +.Xr Newfs 8 +options +.Fl n +and +.Fl r +are neither checked for nor output but should be. +The +.Fl r +flag is needed if the filesystem uses +.Xr gjournal 8 . .Sh SEE ALSO .Xr disktab 5 , .Xr fs 5 , Modified: head/sbin/dumpfs/dumpfs.c ============================================================================== --- head/sbin/dumpfs/dumpfs.c Thu May 16 19:44:51 2013 (r250709) +++ head/sbin/dumpfs/dumpfs.c Thu May 16 20:07:08 2013 (r250710) @@ -417,12 +417,15 @@ marshal(const char *name) printf("-f %d ", fs->fs_fsize); printf("-g %d ", fs->fs_avgfilesize); printf("-h %d ", fs->fs_avgfpdir); - /* -i is dumb */ + printf("-i %jd ", fragroundup(fs, lblktosize(fs, fragstoblks(fs, + fs->fs_fpg)) / fs->fs_ipg)); if (fs->fs_flags & FS_SUJ) printf("-j "); if (fs->fs_flags & FS_GJOURNAL) printf("-J "); - /* -k..l unimplemented */ + printf("-k %jd ", fs->fs_metaspace); + if (fs->fs_flags & FS_MULTILABEL) + printf("-l "); printf("-m %d ", fs->fs_minfree); /* -n unimplemented */ printf("-o "); From owner-svn-src-all@FreeBSD.ORG Thu May 16 20:27:30 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id D271159F; Thu, 16 May 2013 20:27:30 +0000 (UTC) (envelope-from eadler@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id C3F29F01; Thu, 16 May 2013 20:27:30 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.6/8.14.6) with ESMTP id r4GKRUEY099682; Thu, 16 May 2013 20:27:30 GMT (envelope-from eadler@svn.freebsd.org) Received: (from eadler@localhost) by svn.freebsd.org (8.14.6/8.14.5/Submit) id r4GKRUEx099681; Thu, 16 May 2013 20:27:30 GMT (envelope-from eadler@svn.freebsd.org) Message-Id: <201305162027.r4GKRUEx099681@svn.freebsd.org> From: Eitan Adler Date: Thu, 16 May 2013 20:27:30 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-8@freebsd.org Subject: svn commit: r250711 - stable/8/share/syscons/fonts X-SVN-Group: stable-8 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 16 May 2013 20:27:30 -0000 Author: eadler Date: Thu May 16 20:27:30 2013 New Revision: 250711 URL: http://svnweb.freebsd.org/changeset/base/250711 Log: MFC r250553: Add the letter 'x' to the font iso05-8x16.fnt PR: 169797 Modified: stable/8/share/syscons/fonts/iso04-wide-8x16.fnt Directory Properties: stable/8/share/ (props changed) stable/8/share/syscons/ (props changed) Modified: stable/8/share/syscons/fonts/iso04-wide-8x16.fnt ============================================================================== --- stable/8/share/syscons/fonts/iso04-wide-8x16.fnt Thu May 16 20:07:08 2013 (r250710) +++ stable/8/share/syscons/fonts/iso04-wide-8x16.fnt Thu May 16 20:27:30 2013 (r250711) @@ -42,7 +42,7 @@ MS'@``.!@8&!F9FQX;&9FY@`````X&!@8&!@8&!@ MP\/#``````````#<9F9F9F9F9@``````````?,;&QL;&QGP``````````-YC M8V-C8V-^8/````````![QL;&QL;&?@8/````````WG-C8&!@8/`````````` M`'S&P'` Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id DF6025A0; Thu, 16 May 2013 20:27:30 +0000 (UTC) (envelope-from eadler@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id D0A74F02; Thu, 16 May 2013 20:27:30 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.6/8.14.6) with ESMTP id r4GKRUcP099684; Thu, 16 May 2013 20:27:30 GMT (envelope-from eadler@svn.freebsd.org) Received: (from eadler@localhost) by svn.freebsd.org (8.14.6/8.14.5/Submit) id r4GKRUwG099683; Thu, 16 May 2013 20:27:30 GMT (envelope-from eadler@svn.freebsd.org) Message-Id: <201305162027.r4GKRUwG099683@svn.freebsd.org> From: Eitan Adler Date: Thu, 16 May 2013 20:27:30 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org Subject: svn commit: r250712 - stable/9/share/syscons/fonts X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 16 May 2013 20:27:31 -0000 Author: eadler Date: Thu May 16 20:27:30 2013 New Revision: 250712 URL: http://svnweb.freebsd.org/changeset/base/250712 Log: MFC r250553: Add the letter 'x' to the font iso05-8x16.fnt PR: 169797 Modified: stable/9/share/syscons/fonts/iso04-wide-8x16.fnt Directory Properties: stable/9/share/ (props changed) stable/9/share/syscons/ (props changed) Modified: stable/9/share/syscons/fonts/iso04-wide-8x16.fnt ============================================================================== --- stable/9/share/syscons/fonts/iso04-wide-8x16.fnt Thu May 16 20:27:30 2013 (r250711) +++ stable/9/share/syscons/fonts/iso04-wide-8x16.fnt Thu May 16 20:27:30 2013 (r250712) @@ -42,7 +42,7 @@ MS'@``.!@8&!F9FQX;&9FY@`````X&!@8&!@8&!@ MP\/#``````````#<9F9F9F9F9@``````````?,;&QL;&QGP``````````-YC M8V-C8V-^8/````````![QL;&QL;&?@8/````````WG-C8&!@8/`````````` M`'S&P'` Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id 7F54DAF3; Thu, 16 May 2013 20:32:10 +0000 (UTC) (envelope-from eadler@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id 71571F40; Thu, 16 May 2013 20:32:10 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.6/8.14.6) with ESMTP id r4GKWAcQ002436; Thu, 16 May 2013 20:32:10 GMT (envelope-from eadler@svn.freebsd.org) Received: (from eadler@localhost) by svn.freebsd.org (8.14.6/8.14.5/Submit) id r4GKWAsx002435; Thu, 16 May 2013 20:32:10 GMT (envelope-from eadler@svn.freebsd.org) Message-Id: <201305162032.r4GKWAsx002435@svn.freebsd.org> From: Eitan Adler Date: Thu, 16 May 2013 20:32:10 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org Subject: svn commit: r250713 - stable/9/share/syscons/fonts X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 16 May 2013 20:32:10 -0000 Author: eadler Date: Thu May 16 20:32:09 2013 New Revision: 250713 URL: http://svnweb.freebsd.org/changeset/base/250713 Log: MFC r250459: Add the letter 'q' to the font iso05-8x16.fnt PR: 72585 PR: 169797 Modified: stable/9/share/syscons/fonts/iso05-8x16.fnt Directory Properties: stable/9/share/ (props changed) stable/9/share/syscons/ (props changed) Modified: stable/9/share/syscons/fonts/iso05-8x16.fnt ============================================================================== --- stable/9/share/syscons/fonts/iso05-8x16.fnt Thu May 16 20:27:30 2013 (r250712) +++ stable/9/share/syscons/fonts/iso05-8x16.fnt Thu May 16 20:32:09 2013 (r250713) @@ -40,7 +40,7 @@ M`'S&_L#`QGP````````X;&1@\&!@8&#P``````` M`.!@8&QV9F9F9N8````````8&``X&!@8&!@\````````!@8`#@8&!@8&!F9F M/````.!@8&9L>'AL9N8````````X&!@8&!@8&!@\````````````[/[6UM;6 MQ@```````````-QF9F9F9F8```````````!\QL;&QL9\````````````W&9F -M9F9F?&!@\`````````````````````````````#<=F9@8&#P```````````` +M9F9F?&!@\````````';,S,S,S'P,#!X```````#<=F9@8&#P```````````` M?,9@.`S&?````````!`P,/PP,#`P-AP```````````#,S,S,S,QV```````` M````9F9F9F8\&````````````,;&UM;6_FP```````````#&;#@X.&S&```` M````````QL;&QL;&?@8,^````````/[,&#!@QOX````````.&!@8 Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id 0B530C61; Thu, 16 May 2013 20:32:29 +0000 (UTC) (envelope-from eadler@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id F16C8F44; Thu, 16 May 2013 20:32:28 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.6/8.14.6) with ESMTP id r4GKWSFZ002613; Thu, 16 May 2013 20:32:28 GMT (envelope-from eadler@svn.freebsd.org) Received: (from eadler@localhost) by svn.freebsd.org (8.14.6/8.14.5/Submit) id r4GKWScQ002612; Thu, 16 May 2013 20:32:28 GMT (envelope-from eadler@svn.freebsd.org) Message-Id: <201305162032.r4GKWScQ002612@svn.freebsd.org> From: Eitan Adler Date: Thu, 16 May 2013 20:32:28 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-8@freebsd.org Subject: svn commit: r250714 - stable/8/share/syscons/fonts X-SVN-Group: stable-8 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 16 May 2013 20:32:29 -0000 Author: eadler Date: Thu May 16 20:32:28 2013 New Revision: 250714 URL: http://svnweb.freebsd.org/changeset/base/250714 Log: MFC r250459: Add the letter 'q' to the font iso05-8x16.fnt PR: 72585 PR: 169797 Modified: stable/8/share/syscons/fonts/iso05-8x16.fnt Directory Properties: stable/8/share/ (props changed) stable/8/share/syscons/ (props changed) Modified: stable/8/share/syscons/fonts/iso05-8x16.fnt ============================================================================== --- stable/8/share/syscons/fonts/iso05-8x16.fnt Thu May 16 20:32:09 2013 (r250713) +++ stable/8/share/syscons/fonts/iso05-8x16.fnt Thu May 16 20:32:28 2013 (r250714) @@ -40,7 +40,7 @@ M`'S&_L#`QGP````````X;&1@\&!@8&#P``````` M`.!@8&QV9F9F9N8````````8&``X&!@8&!@\````````!@8`#@8&!@8&!F9F M/````.!@8&9L>'AL9N8````````X&!@8&!@8&!@\````````````[/[6UM;6 MQ@```````````-QF9F9F9F8```````````!\QL;&QL9\````````````W&9F -M9F9F?&!@\`````````````````````````````#<=F9@8&#P```````````` +M9F9F?&!@\````````';,S,S,S'P,#!X```````#<=F9@8&#P```````````` M?,9@.`S&?````````!`P,/PP,#`P-AP```````````#,S,S,S,QV```````` M````9F9F9F8\&````````````,;&UM;6_FP```````````#&;#@X.&S&```` M````````QL;&QL;&?@8,^````````/[,&#!@QOX````````.&!@8 Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id C355CED3; Thu, 16 May 2013 20:34:21 +0000 (UTC) (envelope-from jilles@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id B5074F5E; Thu, 16 May 2013 20:34:21 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.6/8.14.6) with ESMTP id r4GKYLJW003075; Thu, 16 May 2013 20:34:21 GMT (envelope-from jilles@svn.freebsd.org) Received: (from jilles@localhost) by svn.freebsd.org (8.14.6/8.14.5/Submit) id r4GKYLXC003073; Thu, 16 May 2013 20:34:21 GMT (envelope-from jilles@svn.freebsd.org) Message-Id: <201305162034.r4GKYLXC003073@svn.freebsd.org> From: Jilles Tjoelker Date: Thu, 16 May 2013 20:34:21 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org Subject: svn commit: r250715 - stable/9/lib/libc/gen X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 16 May 2013 20:34:21 -0000 Author: jilles Date: Thu May 16 20:34:21 2013 New Revision: 250715 URL: http://svnweb.freebsd.org/changeset/base/250715 Log: MFC r250412: posix_spawn_file_actions_addopen(3): Correct error for bad file descriptor. As per POSIX.1-2008, posix_spawn_file_actions_add* return [EBADF] if a file descriptor is negative, not [EINVAL]. The bug was only in the manual page; the code is correct. Modified: stable/9/lib/libc/gen/posix_spawn_file_actions_addopen.3 Directory Properties: stable/9/lib/libc/ (props changed) Modified: stable/9/lib/libc/gen/posix_spawn_file_actions_addopen.3 ============================================================================== --- stable/9/lib/libc/gen/posix_spawn_file_actions_addopen.3 Thu May 16 20:32:28 2013 (r250714) +++ stable/9/lib/libc/gen/posix_spawn_file_actions_addopen.3 Thu May 16 20:34:21 2013 (r250715) @@ -34,7 +34,7 @@ .\" .\" $FreeBSD$ .\" -.Dd March 24, 2008 +.Dd May 9, 2013 .Dt POSIX_SPAWN_FILE_ACTIONS_ADDOPEN 3 .Os .Sh NAME @@ -145,7 +145,7 @@ otherwise, an error number is returned t These functions fail if: .Bl -tag -width Er -.It Bq Er EINVAL +.It Bq Er EBADF The value specified by .Fa fildes or From owner-svn-src-all@FreeBSD.ORG Thu May 16 20:35:54 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id 1B68FFF; Thu, 16 May 2013 20:35:54 +0000 (UTC) (envelope-from jilles@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id 0DBB9F7A; Thu, 16 May 2013 20:35:54 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.6/8.14.6) with ESMTP id r4GKZrU8003391; Thu, 16 May 2013 20:35:53 GMT (envelope-from jilles@svn.freebsd.org) Received: (from jilles@localhost) by svn.freebsd.org (8.14.6/8.14.5/Submit) id r4GKZrJv003390; Thu, 16 May 2013 20:35:53 GMT (envelope-from jilles@svn.freebsd.org) Message-Id: <201305162035.r4GKZrJv003390@svn.freebsd.org> From: Jilles Tjoelker Date: Thu, 16 May 2013 20:35:53 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org Subject: svn commit: r250716 - stable/9/lib/libc/gen X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 16 May 2013 20:35:54 -0000 Author: jilles Date: Thu May 16 20:35:53 2013 New Revision: 250716 URL: http://svnweb.freebsd.org/changeset/base/250716 Log: MFC 250421: posix_spawn_file_actions_adddup2(3): Document difference with dup2(). The ability to clear a file descriptor's close-on-exec flag via posix_spawn_file_actions_adddup2() is in fact proposed in Austin Group issue #411. Modified: stable/9/lib/libc/gen/posix_spawn_file_actions_addopen.3 Directory Properties: stable/9/lib/libc/ (props changed) Modified: stable/9/lib/libc/gen/posix_spawn_file_actions_addopen.3 ============================================================================== --- stable/9/lib/libc/gen/posix_spawn_file_actions_addopen.3 Thu May 16 20:34:21 2013 (r250715) +++ stable/9/lib/libc/gen/posix_spawn_file_actions_addopen.3 Thu May 16 20:35:53 2013 (r250716) @@ -123,7 +123,19 @@ to be duplicated as dup2(fildes, newfildes) .Ed .Pp -had been called) when a new process is spawned using this file actions object. +had been called) when a new process is spawned using this file actions object, +except that the +.Dv FD_CLOEXEC +flag for +.Fa newfildes +is cleared even if +.Fa fildes +is equal to +.Fa newfildes . +The difference from +.Fn dup2 +is useful for passing a particular file descriptor +to a particular child process. .Pp The .Fn posix_spawn_file_actions_addclose @@ -169,7 +181,16 @@ The and .Fn posix_spawn_file_actions_addclose functions conform to -.St -p1003.1-2001 . +.St -p1003.1-2001 , +with the exception of the behavior of +.Fn posix_spawn_file_actions_adddup2 +if +.Fa fildes +is equal to +.Fa newfildes +(clearing +.Dv FD_CLOEXEC ) . +A future update of the Standard is expected to require this behavior, .Sh HISTORY The .Fn posix_spawn_file_actions_addopen , From owner-svn-src-all@FreeBSD.ORG Thu May 16 20:55:21 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id 9C75E2F7; Thu, 16 May 2013 20:55:21 +0000 (UTC) (envelope-from joel@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id 8DEF51B1; Thu, 16 May 2013 20:55:21 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.6/8.14.6) with ESMTP id r4GKtLcg010104; Thu, 16 May 2013 20:55:21 GMT (envelope-from joel@svn.freebsd.org) Received: (from joel@localhost) by svn.freebsd.org (8.14.6/8.14.5/Submit) id r4GKtLpn010103; Thu, 16 May 2013 20:55:21 GMT (envelope-from joel@svn.freebsd.org) Message-Id: <201305162055.r4GKtLpn010103@svn.freebsd.org> From: Joel Dahl Date: Thu, 16 May 2013 20:55:20 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r250717 - head/tools/tools/makeroot X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 16 May 2013 20:55:21 -0000 Author: joel (doc committer) Date: Thu May 16 20:55:20 2013 New Revision: 250717 URL: http://svnweb.freebsd.org/changeset/base/250717 Log: Minor mdoc improvements. Modified: head/tools/tools/makeroot/makeroot.8 Modified: head/tools/tools/makeroot/makeroot.8 ============================================================================== --- head/tools/tools/makeroot/makeroot.8 Thu May 16 20:35:53 2013 (r250716) +++ head/tools/tools/makeroot/makeroot.8 Thu May 16 20:55:20 2013 (r250717) @@ -59,8 +59,8 @@ directory will be placed in the root of will be placed in the root of the UFS image .Ar image-file . .Pp -Images can be customized with a number of different flags. -.Bl -tag -compact -width indent +Images can be customized with a number of different flags: +.Bl -tag -width indent .It Fl B Ar byte-order Set the byte order of the image to .Ar byte-order . @@ -92,7 +92,7 @@ stored in and install it in the home directory of .Ar user . If no -.F K +.Fl K argument is supplied then the files will be installed in the root user's directory. .It Fl p Ar master.passwd Op Fl g Ar group From owner-svn-src-all@FreeBSD.ORG Thu May 16 21:04:57 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id 6F318316; Thu, 16 May 2013 21:04:57 +0000 (UTC) (envelope-from delphij@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id 6215A307; Thu, 16 May 2013 21:04:57 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.6/8.14.6) with ESMTP id r4GL4vF2013721; Thu, 16 May 2013 21:04:57 GMT (envelope-from delphij@svn.freebsd.org) Received: (from delphij@localhost) by svn.freebsd.org (8.14.6/8.14.5/Submit) id r4GL4v5S013720; Thu, 16 May 2013 21:04:57 GMT (envelope-from delphij@svn.freebsd.org) Message-Id: <201305162104.r4GL4v5S013720@svn.freebsd.org> From: Xin LI Date: Thu, 16 May 2013 21:04:57 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r250718 - head/sbin/tunefs X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 16 May 2013 21:04:57 -0000 Author: delphij Date: Thu May 16 21:04:56 2013 New Revision: 250718 URL: http://svnweb.freebsd.org/changeset/base/250718 Log: Constify string pointers. Verified with: sha256(1) MFC after: 2 weeks Modified: head/sbin/tunefs/tunefs.c Modified: head/sbin/tunefs/tunefs.c ============================================================================== --- head/sbin/tunefs/tunefs.c Thu May 16 20:55:20 2013 (r250717) +++ head/sbin/tunefs/tunefs.c Thu May 16 21:04:56 2013 (r250718) @@ -84,8 +84,8 @@ static void sbdirty(void); int main(int argc, char *argv[]) { - char *avalue, *jvalue, *Jvalue, *Lvalue, *lvalue, *Nvalue, *nvalue; - char *tvalue; + const char *avalue, *jvalue, *Jvalue, *Lvalue, *lvalue, *Nvalue, *nvalue; + const char *tvalue; const char *special, *on; const char *name; int active; @@ -711,7 +711,7 @@ journal_findfile(void) } static void -dir_clear_block(char *block, off_t off) +dir_clear_block(const char *block, off_t off) { struct direct *dp; From owner-svn-src-all@FreeBSD.ORG Thu May 16 21:16:16 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id 9CD253BE; Thu, 16 May 2013 21:16:16 +0000 (UTC) (envelope-from julian@freebsd.org) Received: from vps1.elischer.org (vps1.elischer.org [204.109.63.16]) by mx1.freebsd.org (Postfix) with ESMTP id 72E0165B; Thu, 16 May 2013 21:16:16 +0000 (UTC) Received: from Julian-MBP3.local ([137.122.64.21]) (authenticated bits=0) by vps1.elischer.org (8.14.5/8.14.5) with ESMTP id r4GLGAAL019920 (version=TLSv1/SSLv3 cipher=DHE-RSA-CAMELLIA256-SHA bits=256 verify=NO); Thu, 16 May 2013 14:16:11 -0700 (PDT) (envelope-from julian@freebsd.org) Message-ID: <51954C96.3060409@freebsd.org> Date: Thu, 16 May 2013 17:16:06 -0400 From: Julian Elischer User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.8; rv:17.0) Gecko/20130509 Thunderbird/17.0.6 MIME-Version: 1.0 To: Ed Schouten Subject: Re: svn commit: r250700 - in head/sys: conf net netinet6 sys References: <201305161620.r4GGKIFI012296@svn.freebsd.org> In-Reply-To: Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit Cc: svn-src-head@freebsd.org, svn-src-all@freebsd.org, src-committers@freebsd.org X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 16 May 2013 21:16:16 -0000 On 5/16/13 3:19 PM, Ed Schouten wrote: > Hey Julian, > > 2013/5/16 Julian Elischer : >> #define M_SETFIB(_m, _fib) do { \ >> - _m->m_flags &= ~M_FIB; \ >> - _m->m_flags |= (((_fib) << M_FIBSHIFT) & M_FIB); \ >> + KASSERT((_m)->m_flags & M_EXT, ("No FIB on non header mbuf")); \ >> + ((_m)->m_pkthdr.fibnum) = (_fib); \ >> } while (0) > This KASSERT triggers on my box at home. Sorry, but busy right now, so > I can't spend too much time debugging this. Right after getting a > DHCPACK on bootup, the box panics. Copied by hand: thanks My face is red because while this indicates a bug in someone else's code, I should have caught it myself.. but guess what? I accidentally turned off invariants.. duh! I will track down the errant code and fix.. Julian > > panic: No FIB on non header mbuf > .. > db> bt > kassert_panic() > rt_newaddrmsg_fib() > rtinit1() > in_scrubprefix() > in_control() > ifioctl() > kern_ioctl() > sys_ioctl() > amd64_syscall() > Xfast_syscall() > > -- > Ed Schouten > From owner-svn-src-all@FreeBSD.ORG Thu May 16 21:26:47 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id 29ED5462; Thu, 16 May 2013 21:26:47 +0000 (UTC) (envelope-from sjg@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id 1C6BD7F4; Thu, 16 May 2013 21:26:47 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.6/8.14.6) with ESMTP id r4GLQkvj021292; Thu, 16 May 2013 21:26:47 GMT (envelope-from sjg@svn.freebsd.org) Received: (from sjg@localhost) by svn.freebsd.org (8.14.6/8.14.5/Submit) id r4GLQk8Q021290; Thu, 16 May 2013 21:26:46 GMT (envelope-from sjg@svn.freebsd.org) Message-Id: <201305162126.r4GLQk8Q021290@svn.freebsd.org> From: "Simon J. Gerraty" Date: Thu, 16 May 2013 21:26:46 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r250719 - in head: . usr.bin/make X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 16 May 2013 21:26:47 -0000 Author: sjg Date: Thu May 16 21:26:46 2013 New Revision: 250719 URL: http://svnweb.freebsd.org/changeset/base/250719 Log: Reverse the sense of the test wrt bmake, and guard against MK_BMAKE not being defined. Modified: head/Makefile head/usr.bin/make/Makefile Modified: head/Makefile ============================================================================== --- head/Makefile Thu May 16 21:04:56 2013 (r250718) +++ head/Makefile Thu May 16 21:26:46 2013 (r250719) @@ -281,7 +281,7 @@ kernel: buildkernel installkernel # upgrade_checks: .if !defined(.PARSEDIR) -.if defined(WITH_BMAKE) +.if !defined(WITHOUT_BMAKE) (cd ${.CURDIR} && ${MAKE} bmake) .else @if ! (cd ${.CURDIR}/tools/build/make_check && \ Modified: head/usr.bin/make/Makefile ============================================================================== --- head/usr.bin/make/Makefile Thu May 16 21:04:56 2013 (r250718) +++ head/usr.bin/make/Makefile Thu May 16 21:26:46 2013 (r250719) @@ -111,7 +111,7 @@ CFLAGS+= -DDEFSHELLNAME=\"${MAKE_SHELL}\ .error "MAKE_SHELL must be set to one of \"csh\", \"sh\" or \"ksh\"." .endif -.if ${MK_BMAKE} != "no" +.if defined(MK_BMAKE) && ${MK_BMAKE} != "no" # if we are here we don't want this called 'make' PROG= fmake fmake.1: make.1 From owner-svn-src-all@FreeBSD.ORG Thu May 16 21:27:48 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id 1DE985E3; Thu, 16 May 2013 21:27:48 +0000 (UTC) (envelope-from julian@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id 10835803; Thu, 16 May 2013 21:27:48 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.6/8.14.6) with ESMTP id r4GLRlGS021495; Thu, 16 May 2013 21:27:47 GMT (envelope-from julian@svn.freebsd.org) Received: (from julian@localhost) by svn.freebsd.org (8.14.6/8.14.5/Submit) id r4GLRlX4021494; Thu, 16 May 2013 21:27:47 GMT (envelope-from julian@svn.freebsd.org) Message-Id: <201305162127.r4GLRlX4021494@svn.freebsd.org> From: Julian Elischer Date: Thu, 16 May 2013 21:27:47 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r250720 - head/sys/sys X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 16 May 2013 21:27:48 -0000 Author: julian Date: Thu May 16 21:27:47 2013 New Revision: 250720 URL: http://svnweb.freebsd.org/changeset/base/250720 Log: Fix cut-n-paste error. Modified: head/sys/sys/mbuf.h Modified: head/sys/sys/mbuf.h ============================================================================== --- head/sys/sys/mbuf.h Thu May 16 21:26:46 2013 (r250719) +++ head/sys/sys/mbuf.h Thu May 16 21:27:47 2013 (r250720) @@ -1010,14 +1010,14 @@ m_tag_find(struct mbuf *m, int type, str static int inline rt_m_getfib(struct mbuf *m) { - KASSERT(m->m_flags & M_EXT , ("attempt to set FIB on non header mbuf")); + KASSERT(m->m_flags & M_PKTHDR , ("Attempt to get FIB from non header mbuf.")); return (m->m_pkthdr.fibnum); } #define M_GETFIB(_m) rt_m_getfib(_m) #define M_SETFIB(_m, _fib) do { \ - KASSERT((_m)->m_flags & M_EXT, ("No FIB on non header mbuf")); \ + KASSERT((_m)->m_flags & M_PKTHDR, ("Attempt to set FIB on non header mbuf.")); \ ((_m)->m_pkthdr.fibnum) = (_fib); \ } while (0) From owner-svn-src-all@FreeBSD.ORG Thu May 16 21:29:52 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id CF246783; Thu, 16 May 2013 21:29:52 +0000 (UTC) (envelope-from julian@freebsd.org) Received: from vps1.elischer.org (vps1.elischer.org [204.109.63.16]) by mx1.freebsd.org (Postfix) with ESMTP id A598E818; Thu, 16 May 2013 21:29:52 +0000 (UTC) Received: from Julian-MBP3.local ([137.122.64.21]) (authenticated bits=0) by vps1.elischer.org (8.14.5/8.14.5) with ESMTP id r4GLTn4q020032 (version=TLSv1/SSLv3 cipher=DHE-RSA-CAMELLIA256-SHA bits=256 verify=NO); Thu, 16 May 2013 14:29:49 -0700 (PDT) (envelope-from julian@freebsd.org) Message-ID: <51954FC8.7040502@freebsd.org> Date: Thu, 16 May 2013 17:29:44 -0400 From: Julian Elischer User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.8; rv:17.0) Gecko/20130509 Thunderbird/17.0.6 MIME-Version: 1.0 To: Julian Elischer Subject: Re: svn commit: r250700 - in head/sys: conf net netinet6 sys References: <201305161620.r4GGKIFI012296@svn.freebsd.org> <51954C96.3060409@freebsd.org> In-Reply-To: <51954C96.3060409@freebsd.org> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit Cc: svn-src-head@freebsd.org, Ed Schouten , svn-src-all@freebsd.org, src-committers@freebsd.org X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 16 May 2013 21:29:52 -0000 On 5/16/13 5:16 PM, Julian Elischer wrote: > On 5/16/13 3:19 PM, Ed Schouten wrote: >> Hey Julian, >> >> 2013/5/16 Julian Elischer : >>> #define M_SETFIB(_m, _fib) do >>> { \ >>> - _m->m_flags &= >>> ~M_FIB; \ >>> - _m->m_flags |= (((_fib) << M_FIBSHIFT) & M_FIB); \ >>> + KASSERT((_m)->m_flags & M_EXT, ("No FIB on non header >>> mbuf")); \ >>> + ((_m)->m_pkthdr.fibnum) = >>> (_fib); \ >>> } while (0) >> This KASSERT triggers on my box at home. Sorry, but busy right now, so >> I can't spend too much time debugging this. Right after getting a >> DHCPACK on bootup, the box panics. Copied by hand: > > thanks > My face is red because while this indicates a bug in someone else's > code, I should > have caught it myself.. but guess what? I accidentally turned off > invariants.. duh! > > I will track down the errant code and fix.. red face.... note the cut-n-paste error above.. M_EXT should be M_PKTHDR see correcting commit > > Julian > > \ > > From owner-svn-src-all@FreeBSD.ORG Thu May 16 21:59:45 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id 90CD95CF; Thu, 16 May 2013 21:59:45 +0000 (UTC) (envelope-from edschouten@gmail.com) Received: from mail-vb0-x22e.google.com (mail-vb0-x22e.google.com [IPv6:2607:f8b0:400c:c02::22e]) by mx1.freebsd.org (Postfix) with ESMTP id 1E50DBE3; Thu, 16 May 2013 21:59:45 +0000 (UTC) Received: by mail-vb0-f46.google.com with SMTP id 10so1766297vbe.5 for ; Thu, 16 May 2013 14:59:44 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:x-received:sender:in-reply-to:references:date :x-google-sender-auth:message-id:subject:from:to:cc:content-type; bh=y+/uRqTcvV40CN8sG9q29lI2wMaCTxDodIMH/Em6pI0=; b=CM3umPVsrY36BCjltq5BUqvXXZJrxwnOnHHHWhqucxfX6mw1+k0j9aR2a6jysHQO6N vgRe5F58F5A+/tE+1GzEWczvTO7RlLhKi4cCCF2lxcJOSzfWXdtGk7v+Y/tLRMX+UesN qAZF8sYjkAG/8q3VFf/QRZamGShhpblYjo7vR8ecOQW1BEV/nkgXwVRMLT2Gws3gC8/8 KLDzQAHzmxwtNdK6EOSSd5fjQ1DOr9SjkLmzq2bJekPoBKR5o08GMbLHqA4bV/bALAJP tsq+6X03LgnldCLVLZPSVL10zZt5LAkqFQ6eiCe65737/G/mreRfsWZgBULA4r/KTvo2 T2xw== MIME-Version: 1.0 X-Received: by 10.52.175.71 with SMTP id by7mr24336153vdc.85.1368741584593; Thu, 16 May 2013 14:59:44 -0700 (PDT) Sender: edschouten@gmail.com Received: by 10.220.72.7 with HTTP; Thu, 16 May 2013 14:59:44 -0700 (PDT) In-Reply-To: <51954FC8.7040502@freebsd.org> References: <201305161620.r4GGKIFI012296@svn.freebsd.org> <51954C96.3060409@freebsd.org> <51954FC8.7040502@freebsd.org> Date: Thu, 16 May 2013 23:59:44 +0200 X-Google-Sender-Auth: oN_u6zk3vesGli-9ZN4rm5j7N_g Message-ID: Subject: Re: svn commit: r250700 - in head/sys: conf net netinet6 sys From: Ed Schouten To: Julian Elischer Content-Type: text/plain; charset=UTF-8 Cc: svn-src-head@freebsd.org, svn-src-all@freebsd.org, src-committers@freebsd.org X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 16 May 2013 21:59:45 -0000 2013/5/16 Julian Elischer : > see correcting commit Thanks for fixing it so quickly! -- Ed Schouten From owner-svn-src-all@FreeBSD.ORG Thu May 16 22:24:36 2013 Return-Path: Delivered-To: svn-src-all@FreeBSD.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id 3C45D4C3; Thu, 16 May 2013 22:24:36 +0000 (UTC) (envelope-from andreast@FreeBSD.org) Received: from smtp.fgznet.ch (mail.fgznet.ch [81.92.96.47]) by mx1.freebsd.org (Postfix) with ESMTP id C7899FEB; Thu, 16 May 2013 22:24:35 +0000 (UTC) Received: from deuterium.andreas.nets (dhclient-91-190-14-19.flashcable.ch [91.190.14.19]) by smtp.fgznet.ch (8.13.8/8.13.8/Submit_SMTPAUTH) with ESMTP id r4GM61MW085773; Fri, 17 May 2013 00:06:05 +0200 (CEST) (envelope-from andreast@FreeBSD.org) Message-ID: <51955849.4020503@FreeBSD.org> Date: Fri, 17 May 2013 00:06:01 +0200 From: Andreas Tobler User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.8; rv:17.0) Gecko/20130509 Thunderbird/17.0.6 MIME-Version: 1.0 To: Brooks Davis Subject: Re: svn commit: r250659 - in head: . share/mk tools/build/options tools/tools/makeroot References: <201305151430.r4FEU31J061480@svn.freebsd.org> In-Reply-To: <201305151430.r4FEU31J061480@svn.freebsd.org> Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit X-Scanned-By: MIMEDefang 2.64 on 81.92.96.47 Cc: svn-src-head@FreeBSD.org, svn-src-all@FreeBSD.org, src-committers@FreeBSD.org X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 16 May 2013 22:24:36 -0000 On 15.05.13 16:30, Brooks Davis wrote: > Author: brooks > Date: Wed May 15 14:30:03 2013 > New Revision: 250659 > URL: http://svnweb.freebsd.org/changeset/base/250659 > > Log: > Add support for an external cross compiler. The cross compiler is > specified by passing the XCC, XCXX, and XCPP variables (corresponding to > CC, CXX, and CPP) to buildworld/buildkernel. The compiler must be clang > or be configured to target the appropriate architecture. > > To speed build times, if XCC is an absolute path or > WITHOUT_CROSS_COMPILER is defined then no cross compiler will be built > during the cross-tools stage. > > Limited documentation of this feature can currently be found at: > > https://wiki.freebsd.org/ExternalToolchain > > This functionality should be considered experimental and is subject to > change without notice. > > Sponsored by: DARPA, AFRL > Discussed with: imp, sjg I had to revert this commit to be able to build world and kernel with WITHOUT_CLANG_IS_CC in /etc/src.conf It did not find the headers (like math.h) when building the 32-bit part on amd64. Andreas From owner-svn-src-all@FreeBSD.ORG Thu May 16 22:25:17 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id D5936645; Thu, 16 May 2013 22:25:17 +0000 (UTC) (envelope-from delphij@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id AE28AFFA; Thu, 16 May 2013 22:25:17 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.6/8.14.6) with ESMTP id r4GMPHtt041844; Thu, 16 May 2013 22:25:17 GMT (envelope-from delphij@svn.freebsd.org) Received: (from delphij@localhost) by svn.freebsd.org (8.14.6/8.14.5/Submit) id r4GMPHsu041843; Thu, 16 May 2013 22:25:17 GMT (envelope-from delphij@svn.freebsd.org) Message-Id: <201305162225.r4GMPHsu041843@svn.freebsd.org> From: Xin LI Date: Thu, 16 May 2013 22:25:17 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r250721 - head/usr.bin/bmake X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 16 May 2013 22:25:17 -0000 Author: delphij Date: Thu May 16 22:25:17 2013 New Revision: 250721 URL: http://svnweb.freebsd.org/changeset/base/250721 Log: Similar to r250719: guard against MK_BMAKE not being defined. Modified: head/usr.bin/bmake/Makefile.inc Modified: head/usr.bin/bmake/Makefile.inc ============================================================================== --- head/usr.bin/bmake/Makefile.inc Thu May 16 21:27:47 2013 (r250720) +++ head/usr.bin/bmake/Makefile.inc Thu May 16 22:25:17 2013 (r250721) @@ -7,7 +7,7 @@ .export SRCTOP .endif -.if ${MK_BMAKE} != "no" +.if defined(MK_BMAKE) && ${MK_BMAKE} != "no" PROG= make .endif From owner-svn-src-all@FreeBSD.ORG Thu May 16 22:35:34 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id 5F3E3647; Thu, 16 May 2013 22:35:34 +0000 (UTC) (envelope-from delphij@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id 52211194; Thu, 16 May 2013 22:35:34 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.6/8.14.6) with ESMTP id r4GMZYmg045284; Thu, 16 May 2013 22:35:34 GMT (envelope-from delphij@svn.freebsd.org) Received: (from delphij@localhost) by svn.freebsd.org (8.14.6/8.14.5/Submit) id r4GMZYaO045283; Thu, 16 May 2013 22:35:34 GMT (envelope-from delphij@svn.freebsd.org) Message-Id: <201305162235.r4GMZYaO045283@svn.freebsd.org> From: Xin LI Date: Thu, 16 May 2013 22:35:34 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r250722 - head/usr.bin/bmake X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 16 May 2013 22:35:34 -0000 Author: delphij Date: Thu May 16 22:35:33 2013 New Revision: 250722 URL: http://svnweb.freebsd.org/changeset/base/250722 Log: guard against MK_SHARED_TOOLCHAIN not being defined. Modified: head/usr.bin/bmake/Makefile.inc Modified: head/usr.bin/bmake/Makefile.inc ============================================================================== --- head/usr.bin/bmake/Makefile.inc Thu May 16 22:25:17 2013 (r250721) +++ head/usr.bin/bmake/Makefile.inc Thu May 16 22:35:33 2013 (r250722) @@ -11,7 +11,7 @@ PROG= make .endif -.if ${MK_SHARED_TOOLCHAIN} == "no" +.if !defined(MK_SHARED_TOOLCHAIN) || ${MK_SHARED_TOOLCHAIN} == "no" NO_SHARED?= YES .endif From owner-svn-src-all@FreeBSD.ORG Thu May 16 23:16:29 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id E1A785B1; Thu, 16 May 2013 23:16:29 +0000 (UTC) (envelope-from jkim@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id D30FD390; Thu, 16 May 2013 23:16:29 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.6/8.14.6) with ESMTP id r4GNGTqJ059815; Thu, 16 May 2013 23:16:29 GMT (envelope-from jkim@svn.freebsd.org) Received: (from jkim@localhost) by svn.freebsd.org (8.14.6/8.14.5/Submit) id r4GNGT8P059813; Thu, 16 May 2013 23:16:29 GMT (envelope-from jkim@svn.freebsd.org) Message-Id: <201305162316.r4GNGT8P059813@svn.freebsd.org> From: Jung-uk Kim Date: Thu, 16 May 2013 23:16:29 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-vendor@freebsd.org Subject: svn commit: r250723 - in vendor/libregex/dist: . gnu posix X-SVN-Group: vendor MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 16 May 2013 23:16:30 -0000 Author: jkim Date: Thu May 16 23:16:29 2013 New Revision: 250723 URL: http://svnweb.freebsd.org/changeset/base/250723 Log: Flatten GNU libregex vendor area. Added: vendor/libregex/dist/posix/ - copied from r250722, vendor/libregex/dist/gnu/lib/libregex/posix/ vendor/libregex/dist/regcomp.c - copied unchanged from r250722, vendor/libregex/dist/gnu/lib/libregex/regcomp.c vendor/libregex/dist/regex.c - copied unchanged from r250722, vendor/libregex/dist/gnu/lib/libregex/regex.c vendor/libregex/dist/regex.h - copied unchanged from r250722, vendor/libregex/dist/gnu/lib/libregex/regex.h vendor/libregex/dist/regex_internal.c - copied unchanged from r250722, vendor/libregex/dist/gnu/lib/libregex/regex_internal.c vendor/libregex/dist/regex_internal.h - copied unchanged from r250722, vendor/libregex/dist/gnu/lib/libregex/regex_internal.h vendor/libregex/dist/regexec.c - copied unchanged from r250722, vendor/libregex/dist/gnu/lib/libregex/regexec.c Deleted: vendor/libregex/dist/gnu/ Copied: vendor/libregex/dist/regcomp.c (from r250722, vendor/libregex/dist/gnu/lib/libregex/regcomp.c) ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ vendor/libregex/dist/regcomp.c Thu May 16 23:16:29 2013 (r250723, copy of r250722, vendor/libregex/dist/gnu/lib/libregex/regcomp.c) @@ -0,0 +1,3924 @@ +/* Extended regular expression matching and search library. + Copyright (C) 2002, 2003, 2004, 2005 Free Software Foundation, Inc. + This file is part of the GNU C Library. + Contributed by Isamu Hasegawa . + + The GNU C Library is free software; you can redistribute it and/or + modify it under the terms of the GNU Lesser General Public + License as published by the Free Software Foundation; either + version 2.1 of the License, or (at your option) any later version. + + The GNU C Library is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + Lesser General Public License for more details. + + You should have received a copy of the GNU Lesser General Public + License along with the GNU C Library; if not, write to the Free + Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA + 02111-1307 USA. */ + +static reg_errcode_t re_compile_internal (regex_t *preg, const char * pattern, + int length, reg_syntax_t syntax); +static void re_compile_fastmap_iter (regex_t *bufp, + const re_dfastate_t *init_state, + char *fastmap); +static reg_errcode_t init_dfa (re_dfa_t *dfa, int pat_len); +static void init_word_char (re_dfa_t *dfa); +#ifdef RE_ENABLE_I18N +static void free_charset (re_charset_t *cset); +#endif /* RE_ENABLE_I18N */ +static void free_workarea_compile (regex_t *preg); +static reg_errcode_t create_initial_state (re_dfa_t *dfa); +#ifdef RE_ENABLE_I18N +static void optimize_utf8 (re_dfa_t *dfa); +#endif +static reg_errcode_t analyze (regex_t *preg); +static reg_errcode_t create_initial_state (re_dfa_t *dfa); +static reg_errcode_t preorder (bin_tree_t *root, + reg_errcode_t (fn (void *, bin_tree_t *)), + void *extra); +static reg_errcode_t postorder (bin_tree_t *root, + reg_errcode_t (fn (void *, bin_tree_t *)), + void *extra); +static reg_errcode_t optimize_subexps (void *extra, bin_tree_t *node); +static reg_errcode_t lower_subexps (void *extra, bin_tree_t *node); +static bin_tree_t *lower_subexp (reg_errcode_t *err, regex_t *preg, + bin_tree_t *node); +static reg_errcode_t calc_first (void *extra, bin_tree_t *node); +static reg_errcode_t calc_next (void *extra, bin_tree_t *node); +static reg_errcode_t link_nfa_nodes (void *extra, bin_tree_t *node); +static reg_errcode_t duplicate_node_closure (re_dfa_t *dfa, int top_org_node, + int top_clone_node, int root_node, + unsigned int constraint); +static reg_errcode_t duplicate_node (int *new_idx, re_dfa_t *dfa, int org_idx, + unsigned int constraint); +static int search_duplicated_node (re_dfa_t *dfa, int org_node, + unsigned int constraint); +static reg_errcode_t calc_eclosure (re_dfa_t *dfa); +static reg_errcode_t calc_eclosure_iter (re_node_set *new_set, re_dfa_t *dfa, + int node, int root); +static reg_errcode_t calc_inveclosure (re_dfa_t *dfa); +static int fetch_number (re_string_t *input, re_token_t *token, + reg_syntax_t syntax); +static void fetch_token (re_token_t *result, re_string_t *input, + reg_syntax_t syntax); +static int peek_token (re_token_t *token, re_string_t *input, + reg_syntax_t syntax); +static int peek_token_bracket (re_token_t *token, re_string_t *input, + reg_syntax_t syntax); +static bin_tree_t *parse (re_string_t *regexp, regex_t *preg, + reg_syntax_t syntax, reg_errcode_t *err); +static bin_tree_t *parse_reg_exp (re_string_t *regexp, regex_t *preg, + re_token_t *token, reg_syntax_t syntax, + int nest, reg_errcode_t *err); +static bin_tree_t *parse_branch (re_string_t *regexp, regex_t *preg, + re_token_t *token, reg_syntax_t syntax, + int nest, reg_errcode_t *err); +static bin_tree_t *parse_expression (re_string_t *regexp, regex_t *preg, + re_token_t *token, reg_syntax_t syntax, + int nest, reg_errcode_t *err); +static bin_tree_t *parse_sub_exp (re_string_t *regexp, regex_t *preg, + re_token_t *token, reg_syntax_t syntax, + int nest, reg_errcode_t *err); +static bin_tree_t *parse_dup_op (bin_tree_t *dup_elem, re_string_t *regexp, + re_dfa_t *dfa, re_token_t *token, + reg_syntax_t syntax, reg_errcode_t *err); +static bin_tree_t *parse_bracket_exp (re_string_t *regexp, re_dfa_t *dfa, + re_token_t *token, reg_syntax_t syntax, + reg_errcode_t *err); +static reg_errcode_t parse_bracket_element (bracket_elem_t *elem, + re_string_t *regexp, + re_token_t *token, int token_len, + re_dfa_t *dfa, + reg_syntax_t syntax, + int accept_hyphen); +static reg_errcode_t parse_bracket_symbol (bracket_elem_t *elem, + re_string_t *regexp, + re_token_t *token); +#ifndef _LIBC +# ifdef RE_ENABLE_I18N +static reg_errcode_t build_range_exp (re_bitset_ptr_t sbcset, + re_charset_t *mbcset, int *range_alloc, + bracket_elem_t *start_elem, + bracket_elem_t *end_elem); +static reg_errcode_t build_collating_symbol (re_bitset_ptr_t sbcset, + re_charset_t *mbcset, + int *coll_sym_alloc, + const unsigned char *name); +# else /* not RE_ENABLE_I18N */ +static reg_errcode_t build_range_exp (re_bitset_ptr_t sbcset, + bracket_elem_t *start_elem, + bracket_elem_t *end_elem); +static reg_errcode_t build_collating_symbol (re_bitset_ptr_t sbcset, + const unsigned char *name); +# endif /* not RE_ENABLE_I18N */ +#endif /* not _LIBC */ +#ifdef RE_ENABLE_I18N +static reg_errcode_t build_equiv_class (re_bitset_ptr_t sbcset, + re_charset_t *mbcset, + int *equiv_class_alloc, + const unsigned char *name); +static reg_errcode_t build_charclass (unsigned RE_TRANSLATE_TYPE trans, + re_bitset_ptr_t sbcset, + re_charset_t *mbcset, + int *char_class_alloc, + const unsigned char *class_name, + reg_syntax_t syntax); +#else /* not RE_ENABLE_I18N */ +static reg_errcode_t build_equiv_class (re_bitset_ptr_t sbcset, + const unsigned char *name); +static reg_errcode_t build_charclass (unsigned RE_TRANSLATE_TYPE trans, + re_bitset_ptr_t sbcset, + const unsigned char *class_name, + reg_syntax_t syntax); +#endif /* not RE_ENABLE_I18N */ +static bin_tree_t *build_charclass_op (re_dfa_t *dfa, + unsigned RE_TRANSLATE_TYPE trans, + const unsigned char *class_name, + const unsigned char *extra, + int non_match, reg_errcode_t *err); +static bin_tree_t *create_tree (re_dfa_t *dfa, + bin_tree_t *left, bin_tree_t *right, + re_token_type_t type); +static bin_tree_t *create_token_tree (re_dfa_t *dfa, + bin_tree_t *left, bin_tree_t *right, + const re_token_t *token); +static bin_tree_t *duplicate_tree (const bin_tree_t *src, re_dfa_t *dfa); +static void free_token (re_token_t *node); +static reg_errcode_t free_tree (void *extra, bin_tree_t *node); +static reg_errcode_t mark_opt_subexp (void *extra, bin_tree_t *node); + +/* This table gives an error message for each of the error codes listed + in regex.h. Obviously the order here has to be same as there. + POSIX doesn't require that we do anything for REG_NOERROR, + but why not be nice? */ + +const char __re_error_msgid[] attribute_hidden = + { +#define REG_NOERROR_IDX 0 + gettext_noop ("Success") /* REG_NOERROR */ + "\0" +#define REG_NOMATCH_IDX (REG_NOERROR_IDX + sizeof "Success") + gettext_noop ("No match") /* REG_NOMATCH */ + "\0" +#define REG_BADPAT_IDX (REG_NOMATCH_IDX + sizeof "No match") + gettext_noop ("Invalid regular expression") /* REG_BADPAT */ + "\0" +#define REG_ECOLLATE_IDX (REG_BADPAT_IDX + sizeof "Invalid regular expression") + gettext_noop ("Invalid collation character") /* REG_ECOLLATE */ + "\0" +#define REG_ECTYPE_IDX (REG_ECOLLATE_IDX + sizeof "Invalid collation character") + gettext_noop ("Invalid character class name") /* REG_ECTYPE */ + "\0" +#define REG_EESCAPE_IDX (REG_ECTYPE_IDX + sizeof "Invalid character class name") + gettext_noop ("Trailing backslash") /* REG_EESCAPE */ + "\0" +#define REG_ESUBREG_IDX (REG_EESCAPE_IDX + sizeof "Trailing backslash") + gettext_noop ("Invalid back reference") /* REG_ESUBREG */ + "\0" +#define REG_EBRACK_IDX (REG_ESUBREG_IDX + sizeof "Invalid back reference") + gettext_noop ("Unmatched [ or [^") /* REG_EBRACK */ + "\0" +#define REG_EPAREN_IDX (REG_EBRACK_IDX + sizeof "Unmatched [ or [^") + gettext_noop ("Unmatched ( or \\(") /* REG_EPAREN */ + "\0" +#define REG_EBRACE_IDX (REG_EPAREN_IDX + sizeof "Unmatched ( or \\(") + gettext_noop ("Unmatched \\{") /* REG_EBRACE */ + "\0" +#define REG_BADBR_IDX (REG_EBRACE_IDX + sizeof "Unmatched \\{") + gettext_noop ("Invalid content of \\{\\}") /* REG_BADBR */ + "\0" +#define REG_ERANGE_IDX (REG_BADBR_IDX + sizeof "Invalid content of \\{\\}") + gettext_noop ("Invalid range end") /* REG_ERANGE */ + "\0" +#define REG_ESPACE_IDX (REG_ERANGE_IDX + sizeof "Invalid range end") + gettext_noop ("Memory exhausted") /* REG_ESPACE */ + "\0" +#define REG_BADRPT_IDX (REG_ESPACE_IDX + sizeof "Memory exhausted") + gettext_noop ("Invalid preceding regular expression") /* REG_BADRPT */ + "\0" +#define REG_EEND_IDX (REG_BADRPT_IDX + sizeof "Invalid preceding regular expression") + gettext_noop ("Premature end of regular expression") /* REG_EEND */ + "\0" +#define REG_ESIZE_IDX (REG_EEND_IDX + sizeof "Premature end of regular expression") + gettext_noop ("Regular expression too big") /* REG_ESIZE */ + "\0" +#define REG_ERPAREN_IDX (REG_ESIZE_IDX + sizeof "Regular expression too big") + gettext_noop ("Unmatched ) or \\)") /* REG_ERPAREN */ + }; + +const size_t __re_error_msgid_idx[] attribute_hidden = + { + REG_NOERROR_IDX, + REG_NOMATCH_IDX, + REG_BADPAT_IDX, + REG_ECOLLATE_IDX, + REG_ECTYPE_IDX, + REG_EESCAPE_IDX, + REG_ESUBREG_IDX, + REG_EBRACK_IDX, + REG_EPAREN_IDX, + REG_EBRACE_IDX, + REG_BADBR_IDX, + REG_ERANGE_IDX, + REG_ESPACE_IDX, + REG_BADRPT_IDX, + REG_EEND_IDX, + REG_ESIZE_IDX, + REG_ERPAREN_IDX + }; + +/* Entry points for GNU code. */ + +/* re_compile_pattern is the GNU regular expression compiler: it + compiles PATTERN (of length LENGTH) and puts the result in BUFP. + Returns 0 if the pattern was valid, otherwise an error string. + + Assumes the `allocated' (and perhaps `buffer') and `translate' fields + are set in BUFP on entry. */ + +const char * +re_compile_pattern (pattern, length, bufp) + const char *pattern; + size_t length; + struct re_pattern_buffer *bufp; +{ + reg_errcode_t ret; + + /* And GNU code determines whether or not to get register information + by passing null for the REGS argument to re_match, etc., not by + setting no_sub, unless RE_NO_SUB is set. */ + bufp->no_sub = !!(re_syntax_options & RE_NO_SUB); + + /* Match anchors at newline. */ + bufp->newline_anchor = 1; + + ret = re_compile_internal (bufp, pattern, length, re_syntax_options); + + if (!ret) + return NULL; + return gettext (__re_error_msgid + __re_error_msgid_idx[(int) ret]); +} +#ifdef _LIBC +weak_alias (__re_compile_pattern, re_compile_pattern) +#endif + +/* Set by `re_set_syntax' to the current regexp syntax to recognize. Can + also be assigned to arbitrarily: each pattern buffer stores its own + syntax, so it can be changed between regex compilations. */ +/* This has no initializer because initialized variables in Emacs + become read-only after dumping. */ +reg_syntax_t re_syntax_options; + + +/* Specify the precise syntax of regexps for compilation. This provides + for compatibility for various utilities which historically have + different, incompatible syntaxes. + + The argument SYNTAX is a bit mask comprised of the various bits + defined in regex.h. We return the old syntax. */ + +reg_syntax_t +re_set_syntax (syntax) + reg_syntax_t syntax; +{ + reg_syntax_t ret = re_syntax_options; + + re_syntax_options = syntax; + return ret; +} +#ifdef _LIBC +weak_alias (__re_set_syntax, re_set_syntax) +#endif + +int +re_compile_fastmap (bufp) + struct re_pattern_buffer *bufp; +{ + re_dfa_t *dfa = (re_dfa_t *) bufp->buffer; + char *fastmap = bufp->fastmap; + + memset (fastmap, '\0', sizeof (char) * SBC_MAX); + re_compile_fastmap_iter (bufp, dfa->init_state, fastmap); + if (dfa->init_state != dfa->init_state_word) + re_compile_fastmap_iter (bufp, dfa->init_state_word, fastmap); + if (dfa->init_state != dfa->init_state_nl) + re_compile_fastmap_iter (bufp, dfa->init_state_nl, fastmap); + if (dfa->init_state != dfa->init_state_begbuf) + re_compile_fastmap_iter (bufp, dfa->init_state_begbuf, fastmap); + bufp->fastmap_accurate = 1; + return 0; +} +#ifdef _LIBC +weak_alias (__re_compile_fastmap, re_compile_fastmap) +#endif + +static inline void +__attribute ((always_inline)) +re_set_fastmap (char *fastmap, int icase, int ch) +{ + fastmap[ch] = 1; + if (icase) + fastmap[tolower (ch)] = 1; +} + +/* Helper function for re_compile_fastmap. + Compile fastmap for the initial_state INIT_STATE. */ + +static void +re_compile_fastmap_iter (bufp, init_state, fastmap) + regex_t *bufp; + const re_dfastate_t *init_state; + char *fastmap; +{ + re_dfa_t *dfa = (re_dfa_t *) bufp->buffer; + int node_cnt; + int icase = (dfa->mb_cur_max == 1 && (bufp->syntax & RE_ICASE)); + for (node_cnt = 0; node_cnt < init_state->nodes.nelem; ++node_cnt) + { + int node = init_state->nodes.elems[node_cnt]; + re_token_type_t type = dfa->nodes[node].type; + + if (type == CHARACTER) + { + re_set_fastmap (fastmap, icase, dfa->nodes[node].opr.c); +#ifdef RE_ENABLE_I18N + if ((bufp->syntax & RE_ICASE) && dfa->mb_cur_max > 1) + { + unsigned char *buf = alloca (dfa->mb_cur_max), *p; + wchar_t wc; + mbstate_t state; + + p = buf; + *p++ = dfa->nodes[node].opr.c; + while (++node < dfa->nodes_len + && dfa->nodes[node].type == CHARACTER + && dfa->nodes[node].mb_partial) + *p++ = dfa->nodes[node].opr.c; + memset (&state, 0, sizeof (state)); + if (mbrtowc (&wc, (const char *) buf, p - buf, + &state) == p - buf + && (__wcrtomb ((char *) buf, towlower (wc), &state) + != (size_t) -1)) + re_set_fastmap (fastmap, 0, buf[0]); + } +#endif + } + else if (type == SIMPLE_BRACKET) + { + int i, j, ch; + for (i = 0, ch = 0; i < BITSET_UINTS; ++i) + for (j = 0; j < UINT_BITS; ++j, ++ch) + if (dfa->nodes[node].opr.sbcset[i] & (1 << j)) + re_set_fastmap (fastmap, icase, ch); + } +#ifdef RE_ENABLE_I18N + else if (type == COMPLEX_BRACKET) + { + int i; + re_charset_t *cset = dfa->nodes[node].opr.mbcset; + if (cset->non_match || cset->ncoll_syms || cset->nequiv_classes + || cset->nranges || cset->nchar_classes) + { +# ifdef _LIBC + if (_NL_CURRENT_WORD (LC_COLLATE, _NL_COLLATE_NRULES) != 0) + { + /* In this case we want to catch the bytes which are + the first byte of any collation elements. + e.g. In da_DK, we want to catch 'a' since "aa" + is a valid collation element, and don't catch + 'b' since 'b' is the only collation element + which starts from 'b'. */ + int j, ch; + const int32_t *table = (const int32_t *) + _NL_CURRENT (LC_COLLATE, _NL_COLLATE_TABLEMB); + for (i = 0, ch = 0; i < BITSET_UINTS; ++i) + for (j = 0; j < UINT_BITS; ++j, ++ch) + if (table[ch] < 0) + re_set_fastmap (fastmap, icase, ch); + } +# else + if (dfa->mb_cur_max > 1) + for (i = 0; i < SBC_MAX; ++i) + if (__btowc (i) == WEOF) + re_set_fastmap (fastmap, icase, i); +# endif /* not _LIBC */ + } + for (i = 0; i < cset->nmbchars; ++i) + { + char buf[256]; + mbstate_t state; + memset (&state, '\0', sizeof (state)); + if (__wcrtomb (buf, cset->mbchars[i], &state) != (size_t) -1) + re_set_fastmap (fastmap, icase, *(unsigned char *) buf); + if ((bufp->syntax & RE_ICASE) && dfa->mb_cur_max > 1) + { + if (__wcrtomb (buf, towlower (cset->mbchars[i]), &state) + != (size_t) -1) + re_set_fastmap (fastmap, 0, *(unsigned char *) buf); + } + } + } +#endif /* RE_ENABLE_I18N */ + else if (type == OP_PERIOD +#ifdef RE_ENABLE_I18N + || type == OP_UTF8_PERIOD +#endif /* RE_ENABLE_I18N */ + || type == END_OF_RE) + { + memset (fastmap, '\1', sizeof (char) * SBC_MAX); + if (type == END_OF_RE) + bufp->can_be_null = 1; + return; + } + } +} + +/* Entry point for POSIX code. */ +/* regcomp takes a regular expression as a string and compiles it. + + PREG is a regex_t *. We do not expect any fields to be initialized, + since POSIX says we shouldn't. Thus, we set + + `buffer' to the compiled pattern; + `used' to the length of the compiled pattern; + `syntax' to RE_SYNTAX_POSIX_EXTENDED if the + REG_EXTENDED bit in CFLAGS is set; otherwise, to + RE_SYNTAX_POSIX_BASIC; + `newline_anchor' to REG_NEWLINE being set in CFLAGS; + `fastmap' to an allocated space for the fastmap; + `fastmap_accurate' to zero; + `re_nsub' to the number of subexpressions in PATTERN. + + PATTERN is the address of the pattern string. + + CFLAGS is a series of bits which affect compilation. + + If REG_EXTENDED is set, we use POSIX extended syntax; otherwise, we + use POSIX basic syntax. + + If REG_NEWLINE is set, then . and [^...] don't match newline. + Also, regexec will try a match beginning after every newline. + + If REG_ICASE is set, then we considers upper- and lowercase + versions of letters to be equivalent when matching. + + If REG_NOSUB is set, then when PREG is passed to regexec, that + routine will report only success or failure, and nothing about the + registers. + + It returns 0 if it succeeds, nonzero if it doesn't. (See regex.h for + the return codes and their meanings.) */ + +int +regcomp (preg, pattern, cflags) + regex_t *__restrict preg; + const char *__restrict pattern; + int cflags; +{ + reg_errcode_t ret; + reg_syntax_t syntax = ((cflags & REG_EXTENDED) ? RE_SYNTAX_POSIX_EXTENDED + : RE_SYNTAX_POSIX_BASIC); + + preg->buffer = NULL; + preg->allocated = 0; + preg->used = 0; + + /* Try to allocate space for the fastmap. */ + preg->fastmap = re_malloc (char, SBC_MAX); + if (BE (preg->fastmap == NULL, 0)) + return REG_ESPACE; + + syntax |= (cflags & REG_ICASE) ? RE_ICASE : 0; + + /* If REG_NEWLINE is set, newlines are treated differently. */ + if (cflags & REG_NEWLINE) + { /* REG_NEWLINE implies neither . nor [^...] match newline. */ + syntax &= ~RE_DOT_NEWLINE; + syntax |= RE_HAT_LISTS_NOT_NEWLINE; + /* It also changes the matching behavior. */ + preg->newline_anchor = 1; + } + else + preg->newline_anchor = 0; + preg->no_sub = !!(cflags & REG_NOSUB); + preg->translate = NULL; + + ret = re_compile_internal (preg, pattern, strlen (pattern), syntax); + + /* POSIX doesn't distinguish between an unmatched open-group and an + unmatched close-group: both are REG_EPAREN. */ + if (ret == REG_ERPAREN) + ret = REG_EPAREN; + + /* We have already checked preg->fastmap != NULL. */ + if (BE (ret == REG_NOERROR, 1)) + /* Compute the fastmap now, since regexec cannot modify the pattern + buffer. This function never fails in this implementation. */ + (void) re_compile_fastmap (preg); + else + { + /* Some error occurred while compiling the expression. */ + re_free (preg->fastmap); + preg->fastmap = NULL; + } + + return (int) ret; +} +#ifdef _LIBC +weak_alias (__regcomp, regcomp) +#endif + +/* Returns a message corresponding to an error code, ERRCODE, returned + from either regcomp or regexec. We don't use PREG here. */ + +size_t +regerror (errcode, preg, errbuf, errbuf_size) + int errcode; + const regex_t *preg; + char *errbuf; + size_t errbuf_size; +{ + const char *msg; + size_t msg_size; + + if (BE (errcode < 0 + || errcode >= (int) (sizeof (__re_error_msgid_idx) + / sizeof (__re_error_msgid_idx[0])), 0)) + /* Only error codes returned by the rest of the code should be passed + to this routine. If we are given anything else, or if other regex + code generates an invalid error code, then the program has a bug. + Dump core so we can fix it. */ + abort (); + + msg = gettext (__re_error_msgid + __re_error_msgid_idx[errcode]); + + msg_size = strlen (msg) + 1; /* Includes the null. */ + + if (BE (errbuf_size != 0, 1)) + { + if (BE (msg_size > errbuf_size, 0)) + { +#if defined HAVE_MEMPCPY || defined _LIBC + *((char *) __mempcpy (errbuf, msg, errbuf_size - 1)) = '\0'; +#else + memcpy (errbuf, msg, errbuf_size - 1); + errbuf[errbuf_size - 1] = 0; +#endif + } + else + memcpy (errbuf, msg, msg_size); + } + + return msg_size; +} +#ifdef _LIBC +weak_alias (__regerror, regerror) +#endif + + +#ifdef RE_ENABLE_I18N +/* This static array is used for the map to single-byte characters when + UTF-8 is used. Otherwise we would allocate memory just to initialize + it the same all the time. UTF-8 is the preferred encoding so this is + a worthwhile optimization. */ +static const bitset utf8_sb_map = +{ + /* Set the first 128 bits. */ +# if UINT_MAX == 0xffffffff + 0xffffffff, 0xffffffff, 0xffffffff, 0xffffffff +# else +# error "Add case for new unsigned int size" +# endif +}; +#endif + + +static void +free_dfa_content (re_dfa_t *dfa) +{ + int i, j; + + if (dfa->nodes) + for (i = 0; i < dfa->nodes_len; ++i) + free_token (dfa->nodes + i); + re_free (dfa->nexts); + for (i = 0; i < dfa->nodes_len; ++i) + { + if (dfa->eclosures != NULL) + re_node_set_free (dfa->eclosures + i); + if (dfa->inveclosures != NULL) + re_node_set_free (dfa->inveclosures + i); + if (dfa->edests != NULL) + re_node_set_free (dfa->edests + i); + } + re_free (dfa->edests); + re_free (dfa->eclosures); + re_free (dfa->inveclosures); + re_free (dfa->nodes); + + if (dfa->state_table) + for (i = 0; i <= dfa->state_hash_mask; ++i) + { + struct re_state_table_entry *entry = dfa->state_table + i; + for (j = 0; j < entry->num; ++j) + { + re_dfastate_t *state = entry->array[j]; + free_state (state); + } + re_free (entry->array); + } + re_free (dfa->state_table); +#ifdef RE_ENABLE_I18N + if (dfa->sb_char != utf8_sb_map) + re_free (dfa->sb_char); +#endif + re_free (dfa->subexp_map); +#ifdef DEBUG + re_free (dfa->re_str); +#endif + + re_free (dfa); +} + + +/* Free dynamically allocated space used by PREG. */ + +void +regfree (preg) + regex_t *preg; +{ + re_dfa_t *dfa = (re_dfa_t *) preg->buffer; + if (BE (dfa != NULL, 1)) + free_dfa_content (dfa); + preg->buffer = NULL; + preg->allocated = 0; + + re_free (preg->fastmap); + preg->fastmap = NULL; + + re_free (preg->translate); + preg->translate = NULL; +} +#ifdef _LIBC +weak_alias (__regfree, regfree) +#endif + +/* Entry points compatible with 4.2 BSD regex library. We don't define + them unless specifically requested. */ + +#if defined _REGEX_RE_COMP || defined _LIBC + +/* BSD has one and only one pattern buffer. */ +static struct re_pattern_buffer re_comp_buf; + +char * +# ifdef _LIBC +/* Make these definitions weak in libc, so POSIX programs can redefine + these names if they don't use our functions, and still use + regcomp/regexec above without link errors. */ +weak_function +# endif +re_comp (s) + const char *s; +{ + reg_errcode_t ret; + char *fastmap; + + if (!s) + { + if (!re_comp_buf.buffer) + return gettext ("No previous regular expression"); + return 0; + } + + if (re_comp_buf.buffer) + { + fastmap = re_comp_buf.fastmap; + re_comp_buf.fastmap = NULL; + __regfree (&re_comp_buf); + memset (&re_comp_buf, '\0', sizeof (re_comp_buf)); + re_comp_buf.fastmap = fastmap; + } + + if (re_comp_buf.fastmap == NULL) + { + re_comp_buf.fastmap = (char *) malloc (SBC_MAX); + if (re_comp_buf.fastmap == NULL) + return (char *) gettext (__re_error_msgid + + __re_error_msgid_idx[(int) REG_ESPACE]); + } + + /* Since `re_exec' always passes NULL for the `regs' argument, we + don't need to initialize the pattern buffer fields which affect it. */ + + /* Match anchors at newlines. */ + re_comp_buf.newline_anchor = 1; + + ret = re_compile_internal (&re_comp_buf, s, strlen (s), re_syntax_options); + + if (!ret) + return NULL; + + /* Yes, we're discarding `const' here if !HAVE_LIBINTL. */ + return (char *) gettext (__re_error_msgid + __re_error_msgid_idx[(int) ret]); +} + +#ifdef _LIBC +libc_freeres_fn (free_mem) +{ + __regfree (&re_comp_buf); +} +#endif + +#endif /* _REGEX_RE_COMP */ + +/* Internal entry point. + Compile the regular expression PATTERN, whose length is LENGTH. + SYNTAX indicate regular expression's syntax. */ + +static reg_errcode_t +re_compile_internal (preg, pattern, length, syntax) + regex_t *preg; + const char * pattern; + int length; + reg_syntax_t syntax; +{ + reg_errcode_t err = REG_NOERROR; + re_dfa_t *dfa; + re_string_t regexp; + + /* Initialize the pattern buffer. */ + preg->fastmap_accurate = 0; + preg->syntax = syntax; + preg->not_bol = preg->not_eol = 0; + preg->used = 0; + preg->re_nsub = 0; + preg->can_be_null = 0; + preg->regs_allocated = REGS_UNALLOCATED; + + /* Initialize the dfa. */ + dfa = (re_dfa_t *) preg->buffer; + if (BE (preg->allocated < sizeof (re_dfa_t), 0)) + { + /* If zero allocated, but buffer is non-null, try to realloc + enough space. This loses if buffer's address is bogus, but + that is the user's responsibility. If ->buffer is NULL this + is a simple allocation. */ + dfa = re_realloc (preg->buffer, re_dfa_t, 1); + if (dfa == NULL) + return REG_ESPACE; + preg->allocated = sizeof (re_dfa_t); + preg->buffer = (unsigned char *) dfa; + } + preg->used = sizeof (re_dfa_t); + + err = init_dfa (dfa, length); + if (BE (err != REG_NOERROR, 0)) + { + free_dfa_content (dfa); + preg->buffer = NULL; + preg->allocated = 0; + return err; + } +#ifdef DEBUG + dfa->re_str = re_malloc (char, length + 1); + strncpy (dfa->re_str, pattern, length + 1); +#endif + + err = re_string_construct (®exp, pattern, length, preg->translate, + syntax & RE_ICASE, dfa); + if (BE (err != REG_NOERROR, 0)) + { + re_compile_internal_free_return: + free_workarea_compile (preg); + re_string_destruct (®exp); + free_dfa_content (dfa); + preg->buffer = NULL; + preg->allocated = 0; + return err; + } + + /* Parse the regular expression, and build a structure tree. */ + preg->re_nsub = 0; + dfa->str_tree = parse (®exp, preg, syntax, &err); + if (BE (dfa->str_tree == NULL, 0)) + goto re_compile_internal_free_return; + + /* Analyze the tree and create the nfa. */ + err = analyze (preg); + if (BE (err != REG_NOERROR, 0)) + goto re_compile_internal_free_return; + +#ifdef RE_ENABLE_I18N + /* If possible, do searching in single byte encoding to speed things up. */ + if (dfa->is_utf8 && !(syntax & RE_ICASE) && preg->translate == NULL) + optimize_utf8 (dfa); +#endif + + /* Then create the initial state of the dfa. */ + err = create_initial_state (dfa); + + /* Release work areas. */ + free_workarea_compile (preg); + re_string_destruct (®exp); + + if (BE (err != REG_NOERROR, 0)) + { + free_dfa_content (dfa); + preg->buffer = NULL; + preg->allocated = 0; + } + + return err; +} + +/* Initialize DFA. We use the length of the regular expression PAT_LEN + as the initial length of some arrays. */ + +static reg_errcode_t +init_dfa (dfa, pat_len) + re_dfa_t *dfa; + int pat_len; +{ + int table_size; +#ifndef _LIBC + char *codeset_name; +#endif + + memset (dfa, '\0', sizeof (re_dfa_t)); + + /* Force allocation of str_tree_storage the first time. */ + dfa->str_tree_storage_idx = BIN_TREE_STORAGE_SIZE; + + dfa->nodes_alloc = pat_len + 1; + dfa->nodes = re_malloc (re_token_t, dfa->nodes_alloc); + + dfa->states_alloc = pat_len + 1; + + /* table_size = 2 ^ ceil(log pat_len) */ + for (table_size = 1; table_size > 0; table_size <<= 1) + if (table_size > pat_len) + break; + + dfa->state_table = calloc (sizeof (struct re_state_table_entry), table_size); + dfa->state_hash_mask = table_size - 1; + + dfa->mb_cur_max = MB_CUR_MAX; +#ifdef _LIBC + if (dfa->mb_cur_max == 6 + && strcmp (_NL_CURRENT (LC_CTYPE, _NL_CTYPE_CODESET_NAME), "UTF-8") == 0) + dfa->is_utf8 = 1; + dfa->map_notascii = (_NL_CURRENT_WORD (LC_CTYPE, _NL_CTYPE_MAP_TO_NONASCII) + != 0); +#else +# ifdef HAVE_LANGINFO_CODESET + codeset_name = nl_langinfo (CODESET); +# else + codeset_name = getenv ("LC_ALL"); + if (codeset_name == NULL || codeset_name[0] == '\0') + codeset_name = getenv ("LC_CTYPE"); + if (codeset_name == NULL || codeset_name[0] == '\0') + codeset_name = getenv ("LANG"); + if (codeset_name == NULL) + codeset_name = ""; + else if (strchr (codeset_name, '.') != NULL) + codeset_name = strchr (codeset_name, '.') + 1; +# endif + + if (strcasecmp (codeset_name, "UTF-8") == 0 + || strcasecmp (codeset_name, "UTF8") == 0) + dfa->is_utf8 = 1; + + /* We check exhaustively in the loop below if this charset is a + superset of ASCII. */ + dfa->map_notascii = 0; +#endif + +#ifdef RE_ENABLE_I18N + if (dfa->mb_cur_max > 1) + { + if (dfa->is_utf8) + dfa->sb_char = (re_bitset_ptr_t) utf8_sb_map; + else + { + int i, j, ch; + + dfa->sb_char = (re_bitset_ptr_t) calloc (sizeof (bitset), 1); + if (BE (dfa->sb_char == NULL, 0)) + return REG_ESPACE; + + /* Clear all bits by, then set those corresponding to single + byte chars. */ + bitset_empty (dfa->sb_char); + + for (i = 0, ch = 0; i < BITSET_UINTS; ++i) + for (j = 0; j < UINT_BITS; ++j, ++ch) + { + wchar_t wch = __btowc (ch); + if (wch != WEOF) + dfa->sb_char[i] |= 1 << j; +# ifndef _LIBC + if (isascii (ch) && wch != (wchar_t) ch) + dfa->map_notascii = 1; +# endif + } + } + } +#endif + + if (BE (dfa->nodes == NULL || dfa->state_table == NULL, 0)) + return REG_ESPACE; + return REG_NOERROR; +} + +/* Initialize WORD_CHAR table, which indicate which character is + "word". In this case "word" means that it is the word construction + character used by some operators like "\<", "\>", etc. */ + +static void +init_word_char (dfa) + re_dfa_t *dfa; +{ + int i, j, ch; + dfa->word_ops_used = 1; + for (i = 0, ch = 0; i < BITSET_UINTS; ++i) + for (j = 0; j < UINT_BITS; ++j, ++ch) + if (isalnum (ch) || ch == '_') + dfa->word_char[i] |= 1 << j; +} + +/* Free the work area which are only used while compiling. */ + +static void +free_workarea_compile (preg) + regex_t *preg; +{ + re_dfa_t *dfa = (re_dfa_t *) preg->buffer; + bin_tree_storage_t *storage, *next; + for (storage = dfa->str_tree_storage; storage; storage = next) + { + next = storage->next; + re_free (storage); + } + dfa->str_tree_storage = NULL; + dfa->str_tree_storage_idx = BIN_TREE_STORAGE_SIZE; + dfa->str_tree = NULL; + re_free (dfa->org_indices); + dfa->org_indices = NULL; +} + +/* Create initial states for all contexts. */ + +static reg_errcode_t +create_initial_state (dfa) + re_dfa_t *dfa; +{ + int first, i; + reg_errcode_t err; + re_node_set init_nodes; + + /* Initial states have the epsilon closure of the node which is + the first node of the regular expression. */ + first = dfa->str_tree->first->node_idx; + dfa->init_node = first; + err = re_node_set_init_copy (&init_nodes, dfa->eclosures + first); + if (BE (err != REG_NOERROR, 0)) + return err; + + /* The back-references which are in initial states can epsilon transit, + since in this case all of the subexpressions can be null. + Then we add epsilon closures of the nodes which are the next nodes of + the back-references. */ + if (dfa->nbackref > 0) + for (i = 0; i < init_nodes.nelem; ++i) + { + int node_idx = init_nodes.elems[i]; *** DIFF OUTPUT TRUNCATED AT 1000 LINES *** From owner-svn-src-all@FreeBSD.ORG Thu May 16 23:23:38 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id 2A40F7FF; Thu, 16 May 2013 23:23:38 +0000 (UTC) (envelope-from jkim@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id 1BA583FA; Thu, 16 May 2013 23:23:38 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.6/8.14.6) with ESMTP id r4GNNcc3062681; Thu, 16 May 2013 23:23:38 GMT (envelope-from jkim@svn.freebsd.org) Received: (from jkim@localhost) by svn.freebsd.org (8.14.6/8.14.5/Submit) id r4GNNcMF062679; Thu, 16 May 2013 23:23:38 GMT (envelope-from jkim@svn.freebsd.org) Message-Id: <201305162323.r4GNNcMF062679@svn.freebsd.org> From: Jung-uk Kim Date: Thu, 16 May 2013 23:23:38 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-vendor@freebsd.org Subject: svn commit: r250724 - in vendor/libregex/dist: . posix X-SVN-Group: vendor MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 16 May 2013 23:23:38 -0000 Author: jkim Date: Thu May 16 23:23:37 2013 New Revision: 250724 URL: http://svnweb.freebsd.org/changeset/base/250724 Log: Import libregex from GNU libc 2.17. Replaced: vendor/libregex/dist/regex.h (contents, props changed) - copied, changed from r250723, vendor/libregex/dist/posix/regex.h Deleted: vendor/libregex/dist/posix/ Modified: vendor/libregex/dist/regcomp.c (contents, props changed) vendor/libregex/dist/regex.c (contents, props changed) vendor/libregex/dist/regex_internal.c (contents, props changed) vendor/libregex/dist/regex_internal.h (contents, props changed) vendor/libregex/dist/regexec.c (contents, props changed) Modified: vendor/libregex/dist/regcomp.c ============================================================================== --- vendor/libregex/dist/regcomp.c Thu May 16 23:16:29 2013 (r250723) +++ vendor/libregex/dist/regcomp.c Thu May 16 23:23:37 2013 (r250724) @@ -1,5 +1,5 @@ /* Extended regular expression matching and search library. - Copyright (C) 2002, 2003, 2004, 2005 Free Software Foundation, Inc. + Copyright (C) 2002-2007,2009,2010,2011,2012 Free Software Foundation, Inc. This file is part of the GNU C Library. Contributed by Isamu Hasegawa . @@ -14,17 +14,15 @@ Lesser General Public License for more details. You should have received a copy of the GNU Lesser General Public - License along with the GNU C Library; if not, write to the Free - Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA - 02111-1307 USA. */ + License along with the GNU C Library; if not, see + . */ static reg_errcode_t re_compile_internal (regex_t *preg, const char * pattern, - int length, reg_syntax_t syntax); + size_t length, reg_syntax_t syntax); static void re_compile_fastmap_iter (regex_t *bufp, const re_dfastate_t *init_state, char *fastmap); -static reg_errcode_t init_dfa (re_dfa_t *dfa, int pat_len); -static void init_word_char (re_dfa_t *dfa); +static reg_errcode_t init_dfa (re_dfa_t *dfa, size_t pat_len); #ifdef RE_ENABLE_I18N static void free_charset (re_charset_t *cset); #endif /* RE_ENABLE_I18N */ @@ -34,7 +32,6 @@ static reg_errcode_t create_initial_stat static void optimize_utf8 (re_dfa_t *dfa); #endif static reg_errcode_t analyze (regex_t *preg); -static reg_errcode_t create_initial_state (re_dfa_t *dfa); static reg_errcode_t preorder (bin_tree_t *root, reg_errcode_t (fn (void *, bin_tree_t *)), void *extra); @@ -48,12 +45,8 @@ static bin_tree_t *lower_subexp (reg_err static reg_errcode_t calc_first (void *extra, bin_tree_t *node); static reg_errcode_t calc_next (void *extra, bin_tree_t *node); static reg_errcode_t link_nfa_nodes (void *extra, bin_tree_t *node); -static reg_errcode_t duplicate_node_closure (re_dfa_t *dfa, int top_org_node, - int top_clone_node, int root_node, - unsigned int constraint); -static reg_errcode_t duplicate_node (int *new_idx, re_dfa_t *dfa, int org_idx, - unsigned int constraint); -static int search_duplicated_node (re_dfa_t *dfa, int org_node, +static int duplicate_node (re_dfa_t *dfa, int org_idx, unsigned int constraint); +static int search_duplicated_node (const re_dfa_t *dfa, int org_node, unsigned int constraint); static reg_errcode_t calc_eclosure (re_dfa_t *dfa); static reg_errcode_t calc_eclosure_iter (re_node_set *new_set, re_dfa_t *dfa, @@ -61,12 +54,8 @@ static reg_errcode_t calc_eclosure_iter static reg_errcode_t calc_inveclosure (re_dfa_t *dfa); static int fetch_number (re_string_t *input, re_token_t *token, reg_syntax_t syntax); -static void fetch_token (re_token_t *result, re_string_t *input, - reg_syntax_t syntax); static int peek_token (re_token_t *token, re_string_t *input, - reg_syntax_t syntax); -static int peek_token_bracket (re_token_t *token, re_string_t *input, - reg_syntax_t syntax); + reg_syntax_t syntax) internal_function; static bin_tree_t *parse (re_string_t *regexp, regex_t *preg, reg_syntax_t syntax, reg_errcode_t *err); static bin_tree_t *parse_reg_exp (re_string_t *regexp, regex_t *preg, @@ -96,45 +85,27 @@ static reg_errcode_t parse_bracket_eleme static reg_errcode_t parse_bracket_symbol (bracket_elem_t *elem, re_string_t *regexp, re_token_t *token); -#ifndef _LIBC -# ifdef RE_ENABLE_I18N -static reg_errcode_t build_range_exp (re_bitset_ptr_t sbcset, - re_charset_t *mbcset, int *range_alloc, - bracket_elem_t *start_elem, - bracket_elem_t *end_elem); -static reg_errcode_t build_collating_symbol (re_bitset_ptr_t sbcset, - re_charset_t *mbcset, - int *coll_sym_alloc, - const unsigned char *name); -# else /* not RE_ENABLE_I18N */ -static reg_errcode_t build_range_exp (re_bitset_ptr_t sbcset, - bracket_elem_t *start_elem, - bracket_elem_t *end_elem); -static reg_errcode_t build_collating_symbol (re_bitset_ptr_t sbcset, - const unsigned char *name); -# endif /* not RE_ENABLE_I18N */ -#endif /* not _LIBC */ #ifdef RE_ENABLE_I18N -static reg_errcode_t build_equiv_class (re_bitset_ptr_t sbcset, +static reg_errcode_t build_equiv_class (bitset_t sbcset, re_charset_t *mbcset, int *equiv_class_alloc, const unsigned char *name); -static reg_errcode_t build_charclass (unsigned RE_TRANSLATE_TYPE trans, - re_bitset_ptr_t sbcset, +static reg_errcode_t build_charclass (RE_TRANSLATE_TYPE trans, + bitset_t sbcset, re_charset_t *mbcset, int *char_class_alloc, const unsigned char *class_name, reg_syntax_t syntax); #else /* not RE_ENABLE_I18N */ -static reg_errcode_t build_equiv_class (re_bitset_ptr_t sbcset, +static reg_errcode_t build_equiv_class (bitset_t sbcset, const unsigned char *name); -static reg_errcode_t build_charclass (unsigned RE_TRANSLATE_TYPE trans, - re_bitset_ptr_t sbcset, +static reg_errcode_t build_charclass (RE_TRANSLATE_TYPE trans, + bitset_t sbcset, const unsigned char *class_name, reg_syntax_t syntax); #endif /* not RE_ENABLE_I18N */ static bin_tree_t *build_charclass_op (re_dfa_t *dfa, - unsigned RE_TRANSLATE_TYPE trans, + RE_TRANSLATE_TYPE trans, const unsigned char *class_name, const unsigned char *extra, int non_match, reg_errcode_t *err); @@ -327,10 +298,8 @@ re_set_fastmap (char *fastmap, int icase Compile fastmap for the initial_state INIT_STATE. */ static void -re_compile_fastmap_iter (bufp, init_state, fastmap) - regex_t *bufp; - const re_dfastate_t *init_state; - char *fastmap; +re_compile_fastmap_iter (regex_t *bufp, const re_dfastate_t *init_state, + char *fastmap) { re_dfa_t *dfa = (re_dfa_t *) bufp->buffer; int node_cnt; @@ -356,9 +325,9 @@ re_compile_fastmap_iter (bufp, init_stat && dfa->nodes[node].type == CHARACTER && dfa->nodes[node].mb_partial) *p++ = dfa->nodes[node].opr.c; - memset (&state, 0, sizeof (state)); - if (mbrtowc (&wc, (const char *) buf, p - buf, - &state) == p - buf + memset (&state, '\0', sizeof (state)); + if (__mbrtowc (&wc, (const char *) buf, p - buf, + &state) == p - buf && (__wcrtomb ((char *) buf, towlower (wc), &state) != (size_t) -1)) re_set_fastmap (fastmap, 0, buf[0]); @@ -367,56 +336,78 @@ re_compile_fastmap_iter (bufp, init_stat } else if (type == SIMPLE_BRACKET) { - int i, j, ch; - for (i = 0, ch = 0; i < BITSET_UINTS; ++i) - for (j = 0; j < UINT_BITS; ++j, ++ch) - if (dfa->nodes[node].opr.sbcset[i] & (1 << j)) - re_set_fastmap (fastmap, icase, ch); + int i, ch; + for (i = 0, ch = 0; i < BITSET_WORDS; ++i) + { + int j; + bitset_word_t w = dfa->nodes[node].opr.sbcset[i]; + for (j = 0; j < BITSET_WORD_BITS; ++j, ++ch) + if (w & ((bitset_word_t) 1 << j)) + re_set_fastmap (fastmap, icase, ch); + } } #ifdef RE_ENABLE_I18N else if (type == COMPLEX_BRACKET) { - int i; re_charset_t *cset = dfa->nodes[node].opr.mbcset; - if (cset->non_match || cset->ncoll_syms || cset->nequiv_classes - || cset->nranges || cset->nchar_classes) - { + int i; + # ifdef _LIBC - if (_NL_CURRENT_WORD (LC_COLLATE, _NL_COLLATE_NRULES) != 0) + /* See if we have to try all bytes which start multiple collation + elements. + e.g. In da_DK, we want to catch 'a' since "aa" is a valid + collation element, and don't catch 'b' since 'b' is + the only collation element which starts from 'b' (and + it is caught by SIMPLE_BRACKET). */ + if (_NL_CURRENT_WORD (LC_COLLATE, _NL_COLLATE_NRULES) != 0 + && (cset->ncoll_syms || cset->nranges)) { - /* In this case we want to catch the bytes which are - the first byte of any collation elements. - e.g. In da_DK, we want to catch 'a' since "aa" - is a valid collation element, and don't catch - 'b' since 'b' is the only collation element - which starts from 'b'. */ - int j, ch; const int32_t *table = (const int32_t *) _NL_CURRENT (LC_COLLATE, _NL_COLLATE_TABLEMB); - for (i = 0, ch = 0; i < BITSET_UINTS; ++i) - for (j = 0; j < UINT_BITS; ++j, ++ch) - if (table[ch] < 0) - re_set_fastmap (fastmap, icase, ch); + for (i = 0; i < SBC_MAX; ++i) + if (table[i] < 0) + re_set_fastmap (fastmap, icase, i); } -# else - if (dfa->mb_cur_max > 1) - for (i = 0; i < SBC_MAX; ++i) - if (__btowc (i) == WEOF) - re_set_fastmap (fastmap, icase, i); -# endif /* not _LIBC */ +# endif /* _LIBC */ + + /* See if we have to start the match at all multibyte characters, + i.e. where we would not find an invalid sequence. This only + applies to multibyte character sets; for single byte character + sets, the SIMPLE_BRACKET again suffices. */ + if (dfa->mb_cur_max > 1 + && (cset->nchar_classes || cset->non_match || cset->nranges +# ifdef _LIBC + || cset->nequiv_classes +# endif /* _LIBC */ + )) + { + unsigned char c = 0; + do + { + mbstate_t mbs; + memset (&mbs, 0, sizeof (mbs)); + if (__mbrtowc (NULL, (char *) &c, 1, &mbs) == (size_t) -2) + re_set_fastmap (fastmap, false, (int) c); + } + while (++c != 0); } - for (i = 0; i < cset->nmbchars; ++i) + + else { - char buf[256]; - mbstate_t state; - memset (&state, '\0', sizeof (state)); - if (__wcrtomb (buf, cset->mbchars[i], &state) != (size_t) -1) - re_set_fastmap (fastmap, icase, *(unsigned char *) buf); - if ((bufp->syntax & RE_ICASE) && dfa->mb_cur_max > 1) + /* ... Else catch all bytes which can start the mbchars. */ + for (i = 0; i < cset->nmbchars; ++i) { - if (__wcrtomb (buf, towlower (cset->mbchars[i]), &state) - != (size_t) -1) - re_set_fastmap (fastmap, 0, *(unsigned char *) buf); + char buf[256]; + mbstate_t state; + memset (&state, '\0', sizeof (state)); + if (__wcrtomb (buf, cset->mbchars[i], &state) != (size_t) -1) + re_set_fastmap (fastmap, icase, *(unsigned char *) buf); + if ((bufp->syntax & RE_ICASE) && dfa->mb_cur_max > 1) + { + if (__wcrtomb (buf, towlower (cset->mbchars[i]), &state) + != (size_t) -1) + re_set_fastmap (fastmap, false, *(unsigned char *) buf); + } } } } @@ -536,8 +527,8 @@ weak_alias (__regcomp, regcomp) size_t regerror (errcode, preg, errbuf, errbuf_size) int errcode; - const regex_t *preg; - char *errbuf; + const regex_t *__restrict preg; + char *__restrict errbuf; size_t errbuf_size; { const char *msg; @@ -583,14 +574,10 @@ weak_alias (__regerror, regerror) UTF-8 is used. Otherwise we would allocate memory just to initialize it the same all the time. UTF-8 is the preferred encoding so this is a worthwhile optimization. */ -static const bitset utf8_sb_map = +static const bitset_t utf8_sb_map = { /* Set the first 128 bits. */ -# if UINT_MAX == 0xffffffff - 0xffffffff, 0xffffffff, 0xffffffff, 0xffffffff -# else -# error "Add case for new unsigned int size" -# endif + [0 ... 0x80 / BITSET_WORD_BITS - 1] = BITSET_WORD_MAX }; #endif @@ -627,7 +614,7 @@ free_dfa_content (re_dfa_t *dfa) re_dfastate_t *state = entry->array[j]; free_state (state); } - re_free (entry->array); + re_free (entry->array); } re_free (dfa->state_table); #ifdef RE_ENABLE_I18N @@ -739,11 +726,8 @@ libc_freeres_fn (free_mem) SYNTAX indicate regular expression's syntax. */ static reg_errcode_t -re_compile_internal (preg, pattern, length, syntax) - regex_t *preg; - const char * pattern; - int length; - reg_syntax_t syntax; +re_compile_internal (regex_t *preg, const char * pattern, size_t length, + reg_syntax_t syntax) { reg_errcode_t err = REG_NOERROR; re_dfa_t *dfa; @@ -783,10 +767,13 @@ re_compile_internal (preg, pattern, leng return err; } #ifdef DEBUG + /* Note: length+1 will not overflow since it is checked in init_dfa. */ dfa->re_str = re_malloc (char, length + 1); strncpy (dfa->re_str, pattern, length + 1); #endif + __libc_lock_init (dfa->lock); + err = re_string_construct (®exp, pattern, length, preg->translate, syntax & RE_ICASE, dfa); if (BE (err != REG_NOERROR, 0)) @@ -838,11 +825,9 @@ re_compile_internal (preg, pattern, leng as the initial length of some arrays. */ static reg_errcode_t -init_dfa (dfa, pat_len) - re_dfa_t *dfa; - int pat_len; +init_dfa (re_dfa_t *dfa, size_t pat_len) { - int table_size; + unsigned int table_size; #ifndef _LIBC char *codeset_name; #endif @@ -852,13 +837,15 @@ init_dfa (dfa, pat_len) /* Force allocation of str_tree_storage the first time. */ dfa->str_tree_storage_idx = BIN_TREE_STORAGE_SIZE; + /* Avoid overflows. */ + if (pat_len == SIZE_MAX) + return REG_ESPACE; + dfa->nodes_alloc = pat_len + 1; dfa->nodes = re_malloc (re_token_t, dfa->nodes_alloc); - dfa->states_alloc = pat_len + 1; - /* table_size = 2 ^ ceil(log pat_len) */ - for (table_size = 1; table_size > 0; table_size <<= 1) + for (table_size = 1; ; table_size <<= 1) if (table_size > pat_len) break; @@ -905,22 +892,19 @@ init_dfa (dfa, pat_len) { int i, j, ch; - dfa->sb_char = (re_bitset_ptr_t) calloc (sizeof (bitset), 1); + dfa->sb_char = (re_bitset_ptr_t) calloc (sizeof (bitset_t), 1); if (BE (dfa->sb_char == NULL, 0)) return REG_ESPACE; - /* Clear all bits by, then set those corresponding to single - byte chars. */ - bitset_empty (dfa->sb_char); - - for (i = 0, ch = 0; i < BITSET_UINTS; ++i) - for (j = 0; j < UINT_BITS; ++j, ++ch) + /* Set the bits corresponding to single byte chars. */ + for (i = 0, ch = 0; i < BITSET_WORDS; ++i) + for (j = 0; j < BITSET_WORD_BITS; ++j, ++ch) { - wchar_t wch = __btowc (ch); + wint_t wch = __btowc (ch); if (wch != WEOF) - dfa->sb_char[i] |= 1 << j; + dfa->sb_char[i] |= (bitset_word_t) 1 << j; # ifndef _LIBC - if (isascii (ch) && wch != (wchar_t) ch) + if (isascii (ch) && wch != ch) dfa->map_notascii = 1; # endif } @@ -938,22 +922,53 @@ init_dfa (dfa, pat_len) character used by some operators like "\<", "\>", etc. */ static void -init_word_char (dfa) - re_dfa_t *dfa; +internal_function +init_word_char (re_dfa_t *dfa) { - int i, j, ch; dfa->word_ops_used = 1; - for (i = 0, ch = 0; i < BITSET_UINTS; ++i) - for (j = 0; j < UINT_BITS; ++j, ++ch) + int i = 0; + int ch = 0; + if (BE (dfa->map_notascii == 0, 1)) + { + if (sizeof (dfa->word_char[0]) == 8) + { + /* The extra temporaries here avoid "implicitly truncated" + warnings in the case when this is dead code, i.e. 32-bit. */ + const uint64_t wc0 = UINT64_C (0x03ff000000000000); + const uint64_t wc1 = UINT64_C (0x07fffffe87fffffe); + dfa->word_char[0] = wc0; + dfa->word_char[1] = wc1; + i = 2; + } + else if (sizeof (dfa->word_char[0]) == 4) + { + dfa->word_char[0] = UINT32_C (0x00000000); + dfa->word_char[1] = UINT32_C (0x03ff0000); + dfa->word_char[2] = UINT32_C (0x87fffffe); + dfa->word_char[3] = UINT32_C (0x07fffffe); + i = 4; + } + else + abort (); + ch = 128; + + if (BE (dfa->is_utf8, 1)) + { + memset (&dfa->word_char[i], '\0', (SBC_MAX - ch) / 8); + return; + } + } + + for (; i < BITSET_WORDS; ++i) + for (int j = 0; j < BITSET_WORD_BITS; ++j, ++ch) if (isalnum (ch) || ch == '_') - dfa->word_char[i] |= 1 << j; + dfa->word_char[i] |= (bitset_word_t) 1 << j; } /* Free the work area which are only used while compiling. */ static void -free_workarea_compile (preg) - regex_t *preg; +free_workarea_compile (regex_t *preg) { re_dfa_t *dfa = (re_dfa_t *) preg->buffer; bin_tree_storage_t *storage, *next; @@ -972,8 +987,7 @@ free_workarea_compile (preg) /* Create initial states for all contexts. */ static reg_errcode_t -create_initial_state (dfa) - re_dfa_t *dfa; +create_initial_state (re_dfa_t *dfa) { int first, i; reg_errcode_t err; @@ -1016,7 +1030,11 @@ create_initial_state (dfa) int dest_idx = dfa->edests[node_idx].elems[0]; if (!re_node_set_contains (&init_nodes, dest_idx)) { - re_node_set_merge (&init_nodes, dfa->eclosures + dest_idx); + reg_errcode_t err = re_node_set_merge (&init_nodes, + dfa->eclosures + + dest_idx); + if (err != REG_NOERROR) + return err; i = 0; } } @@ -1055,8 +1073,7 @@ create_initial_state (dfa) DFA nodes where needed. */ static void -optimize_utf8 (dfa) - re_dfa_t *dfa; +optimize_utf8 (re_dfa_t *dfa) { int node, i, mb_chars = 0, has_period = 0; @@ -1068,7 +1085,7 @@ optimize_utf8 (dfa) mb_chars = 1; break; case ANCHOR: - switch (dfa->nodes[node].opr.idx) + switch (dfa->nodes[node].opr.ctx_type) { case LINE_FIRST: case LINE_LAST: @@ -1076,13 +1093,15 @@ optimize_utf8 (dfa) case BUF_LAST: break; default: - /* Word anchors etc. cannot be handled. */ + /* Word anchors etc. cannot be handled. It's okay to test + opr.ctx_type since constraints (for all DFA nodes) are + created by ORing one or more opr.ctx_type values. */ return; } break; case OP_PERIOD: - has_period = 1; - break; + has_period = 1; + break; case OP_BACK_REF: case OP_ALT: case END_OF_RE: @@ -1093,8 +1112,9 @@ optimize_utf8 (dfa) case COMPLEX_BRACKET: return; case SIMPLE_BRACKET: - /* Just double check. */ - for (i = 0x80 / UINT_BITS; i < BITSET_UINTS; ++i) + /* Just double check. The non-ASCII range starts at 0x80. */ + assert (0x80 % BITSET_WORD_BITS == 0); + for (i = 0x80 / BITSET_WORD_BITS; i < BITSET_WORDS; ++i) if (dfa->nodes[node].opr.sbcset[i]) return; break; @@ -1123,8 +1143,7 @@ optimize_utf8 (dfa) "eclosure", and "inveclosure". */ static reg_errcode_t -analyze (preg) - regex_t *preg; +analyze (regex_t *preg) { re_dfa_t *dfa = (re_dfa_t *) preg->buffer; reg_errcode_t ret; @@ -1176,7 +1195,7 @@ analyze (preg) { dfa->inveclosures = re_malloc (re_node_set, dfa->nodes_len); if (BE (dfa->inveclosures == NULL, 0)) - return REG_ESPACE; + return REG_ESPACE; ret = calc_inveclosure (dfa); } @@ -1187,10 +1206,8 @@ analyze (preg) implement parse tree visits. Instead, we use parent pointers and some hairy code in these two functions. */ static reg_errcode_t -postorder (root, fn, extra) - bin_tree_t *root; - reg_errcode_t (fn (void *, bin_tree_t *)); - void *extra; +postorder (bin_tree_t *root, reg_errcode_t (fn (void *, bin_tree_t *)), + void *extra) { bin_tree_t *node, *prev; @@ -1200,16 +1217,16 @@ postorder (root, fn, extra) if that's the only child). */ while (node->left || node->right) if (node->left) - node = node->left; - else - node = node->right; + node = node->left; + else + node = node->right; do { reg_errcode_t err = fn (extra, node); if (BE (err != REG_NOERROR, 0)) return err; - if (node->parent == NULL) + if (node->parent == NULL) return REG_NOERROR; prev = node; node = node->parent; @@ -1221,10 +1238,8 @@ postorder (root, fn, extra) } static reg_errcode_t -preorder (root, fn, extra) - bin_tree_t *root; - reg_errcode_t (fn (void *, bin_tree_t *)); - void *extra; +preorder (bin_tree_t *root, reg_errcode_t (fn (void *, bin_tree_t *)), + void *extra) { bin_tree_t *node; @@ -1245,7 +1260,7 @@ preorder (root, fn, extra) prev = node; node = node->parent; if (!node) - return REG_NOERROR; + return REG_NOERROR; } node = node->right; } @@ -1256,9 +1271,7 @@ preorder (root, fn, extra) re_search_internal to map the inner one's opr.idx to this one's. Adjust backreferences as well. Requires a preorder visit. */ static reg_errcode_t -optimize_subexps (extra, node) - void *extra; - bin_tree_t *node; +optimize_subexps (void *extra, bin_tree_t *node) { re_dfa_t *dfa = (re_dfa_t *) extra; @@ -1270,17 +1283,17 @@ optimize_subexps (extra, node) } else if (node->token.type == SUBEXP - && node->left && node->left->token.type == SUBEXP) + && node->left && node->left->token.type == SUBEXP) { int other_idx = node->left->token.opr.idx; node->left = node->left->left; if (node->left) - node->left->parent = node; + node->left->parent = node; dfa->subexp_map[other_idx] = dfa->subexp_map[node->token.opr.idx]; - if (other_idx < 8 * sizeof (dfa->used_bkref_map)) - dfa->used_bkref_map &= ~(1 << other_idx); + if (other_idx < BITSET_WORD_BITS) + dfa->used_bkref_map &= ~((bitset_word_t) 1 << other_idx); } return REG_NOERROR; @@ -1289,9 +1302,7 @@ optimize_subexps (extra, node) /* Lowering pass: Turn each SUBEXP node into the appropriate concatenation of OP_OPEN_SUBEXP, the body of the SUBEXP (if any) and OP_CLOSE_SUBEXP. */ static reg_errcode_t -lower_subexps (extra, node) - void *extra; - bin_tree_t *node; +lower_subexps (void *extra, bin_tree_t *node) { regex_t *preg = (regex_t *) extra; reg_errcode_t err = REG_NOERROR; @@ -1313,10 +1324,7 @@ lower_subexps (extra, node) } static bin_tree_t * -lower_subexp (err, preg, node) - reg_errcode_t *err; - regex_t *preg; - bin_tree_t *node; +lower_subexp (reg_errcode_t *err, regex_t *preg, bin_tree_t *node) { re_dfa_t *dfa = (re_dfa_t *) preg->buffer; bin_tree_t *body = node->left; @@ -1328,8 +1336,9 @@ lower_subexp (err, preg, node) very common, so we do not lose much. An example that triggers this case is the sed "script" /\(\)/x. */ && node->left != NULL - && (node->token.opr.idx >= 8 * sizeof (dfa->used_bkref_map) - || !(dfa->used_bkref_map & (1 << node->token.opr.idx)))) + && (node->token.opr.idx >= BITSET_WORD_BITS + || !(dfa->used_bkref_map + & ((bitset_word_t) 1 << node->token.opr.idx)))) return node->left; /* Convert the SUBEXP node to the concatenation of an @@ -1352,9 +1361,7 @@ lower_subexp (err, preg, node) /* Pass 1 in building the NFA: compute FIRST and create unlinked automaton nodes. Requires a postorder visit. */ static reg_errcode_t -calc_first (extra, node) - void *extra; - bin_tree_t *node; +calc_first (void *extra, bin_tree_t *node) { re_dfa_t *dfa = (re_dfa_t *) extra; if (node->token.type == CONCAT) @@ -1367,16 +1374,16 @@ calc_first (extra, node) node->first = node; node->node_idx = re_dfa_add_node (dfa, node->token); if (BE (node->node_idx == -1, 0)) - return REG_ESPACE; + return REG_ESPACE; + if (node->token.type == ANCHOR) + dfa->nodes[node->node_idx].constraint = node->token.opr.ctx_type; } return REG_NOERROR; } /* Pass 2: compute NEXT on the tree. Preorder visit. */ static reg_errcode_t -calc_next (extra, node) - void *extra; - bin_tree_t *node; +calc_next (void *extra, bin_tree_t *node) { switch (node->token.type) { @@ -1391,7 +1398,7 @@ calc_next (extra, node) if (node->left) node->left->next = node->next; if (node->right) - node->right->next = node->next; + node->right->next = node->next; break; } return REG_NOERROR; @@ -1399,9 +1406,7 @@ calc_next (extra, node) /* Pass 3: link all DFA nodes to their NEXT node (any order will do). */ static reg_errcode_t -link_nfa_nodes (extra, node) - void *extra; - bin_tree_t *node; +link_nfa_nodes (void *extra, bin_tree_t *node) { re_dfa_t *dfa = (re_dfa_t *) extra; int idx = node->node_idx; @@ -1444,7 +1449,7 @@ link_nfa_nodes (extra, node) case OP_BACK_REF: dfa->nexts[idx] = node->next->node_idx; if (node->token.type == OP_BACK_REF) - re_node_set_init_1 (dfa->edests + idx, dfa->nexts[idx]); + err = re_node_set_init_1 (dfa->edests + idx, dfa->nexts[idx]); break; default: @@ -1461,13 +1466,10 @@ link_nfa_nodes (extra, node) to their own constraint. */ static reg_errcode_t -duplicate_node_closure (dfa, top_org_node, top_clone_node, root_node, - init_constraint) - re_dfa_t *dfa; - int top_org_node, top_clone_node, root_node; - unsigned int init_constraint; +internal_function +duplicate_node_closure (re_dfa_t *dfa, int top_org_node, int top_clone_node, + int root_node, unsigned int init_constraint) { - reg_errcode_t err; int org_node, clone_node, ret; unsigned int constraint = init_constraint; for (org_node = top_org_node, clone_node = top_clone_node;;) @@ -1481,9 +1483,9 @@ duplicate_node_closure (dfa, top_org_nod edests of the back reference. */ org_dest = dfa->nexts[org_node]; re_node_set_empty (dfa->edests + clone_node); - err = duplicate_node (&clone_dest, dfa, org_dest, constraint); - if (BE (err != REG_NOERROR, 0)) - return err; + clone_dest = duplicate_node (dfa, org_dest, constraint); + if (BE (clone_dest == -1, 0)) + return REG_ESPACE; dfa->nexts[clone_node] = dfa->nexts[org_node]; ret = re_node_set_insert (dfa->edests + clone_node, clone_dest); if (BE (ret < 0, 0)) @@ -1503,25 +1505,20 @@ duplicate_node_closure (dfa, top_org_nod destination. */ org_dest = dfa->edests[org_node].elems[0]; re_node_set_empty (dfa->edests + clone_node); - if (dfa->nodes[org_node].type == ANCHOR) + /* If the node is root_node itself, it means the epsilon clsoure + has a loop. Then tie it to the destination of the root_node. */ + if (org_node == root_node && clone_node != org_node) { - /* In case of the node has another constraint, append it. */ - if (org_node == root_node && clone_node != org_node) - { - /* ...but if the node is root_node itself, it means the - epsilon closure have a loop, then tie it to the - destination of the root_node. */ - ret = re_node_set_insert (dfa->edests + clone_node, - org_dest); - if (BE (ret < 0, 0)) - return REG_ESPACE; - break; - } - constraint |= dfa->nodes[org_node].opr.ctx_type; + ret = re_node_set_insert (dfa->edests + clone_node, org_dest); + if (BE (ret < 0, 0)) + return REG_ESPACE; + break; } - err = duplicate_node (&clone_dest, dfa, org_dest, constraint); - if (BE (err != REG_NOERROR, 0)) - return err; + /* In case of the node has another constraint, add it. */ + constraint |= dfa->nodes[org_node].constraint; + clone_dest = duplicate_node (dfa, org_dest, constraint); + if (BE (clone_dest == -1, 0)) + return REG_ESPACE; ret = re_node_set_insert (dfa->edests + clone_node, clone_dest); if (BE (ret < 0, 0)) return REG_ESPACE; @@ -1536,10 +1533,11 @@ duplicate_node_closure (dfa, top_org_nod clone_dest = search_duplicated_node (dfa, org_dest, constraint); if (clone_dest == -1) { - /* There are no such a duplicated node, create a new one. */ - err = duplicate_node (&clone_dest, dfa, org_dest, constraint); - if (BE (err != REG_NOERROR, 0)) - return err; + /* There is no such duplicated node, create a new one. */ + reg_errcode_t err; + clone_dest = duplicate_node (dfa, org_dest, constraint); + if (BE (clone_dest == -1, 0)) + return REG_ESPACE; ret = re_node_set_insert (dfa->edests + clone_node, clone_dest); if (BE (ret < 0, 0)) return REG_ESPACE; @@ -1550,7 +1548,7 @@ duplicate_node_closure (dfa, top_org_nod } else { - /* There are a duplicated node which satisfy the constraint, + /* There is a duplicated node which satisfies the constraint, use it to avoid infinite loop. */ ret = re_node_set_insert (dfa->edests + clone_node, clone_dest); if (BE (ret < 0, 0)) @@ -1558,9 +1556,9 @@ duplicate_node_closure (dfa, top_org_nod } org_dest = dfa->edests[org_node].elems[1]; - err = duplicate_node (&clone_dest, dfa, org_dest, constraint); - if (BE (err != REG_NOERROR, 0)) - return err; + clone_dest = duplicate_node (dfa, org_dest, constraint); + if (BE (clone_dest == -1, 0)) + return REG_ESPACE; ret = re_node_set_insert (dfa->edests + clone_node, clone_dest); if (BE (ret < 0, 0)) return REG_ESPACE; @@ -1575,10 +1573,8 @@ duplicate_node_closure (dfa, top_org_nod satisfies the constraint CONSTRAINT. */ static int -search_duplicated_node (dfa, org_node, constraint) - re_dfa_t *dfa; - int org_node; - unsigned int constraint; +search_duplicated_node (const re_dfa_t *dfa, int org_node, + unsigned int constraint) { int idx; for (idx = dfa->nodes_len - 1; dfa->nodes[idx].duplicated && idx > 0; --idx) @@ -1591,32 +1587,27 @@ search_duplicated_node (dfa, org_node, c } /* Duplicate the node whose index is ORG_IDX and set the constraint CONSTRAINT. - The new index will be stored in NEW_IDX and return REG_NOERROR if succeeded, - otherwise return the error code. */ + Return the index of the new node, or -1 if insufficient storage is + available. */ -static reg_errcode_t -duplicate_node (new_idx, dfa, org_idx, constraint) - re_dfa_t *dfa; - int *new_idx, org_idx; - unsigned int constraint; +static int +duplicate_node (re_dfa_t *dfa, int org_idx, unsigned int constraint) { int dup_idx = re_dfa_add_node (dfa, dfa->nodes[org_idx]); - if (BE (dup_idx == -1, 0)) - return REG_ESPACE; - dfa->nodes[dup_idx].constraint = constraint; - if (dfa->nodes[org_idx].type == ANCHOR) - dfa->nodes[dup_idx].constraint |= dfa->nodes[org_idx].opr.ctx_type; - dfa->nodes[dup_idx].duplicated = 1; - - /* Store the index of the original node. */ - dfa->org_indices[dup_idx] = org_idx; - *new_idx = dup_idx; - return REG_NOERROR; + if (BE (dup_idx != -1, 1)) + { + dfa->nodes[dup_idx].constraint = constraint; + dfa->nodes[dup_idx].constraint |= dfa->nodes[org_idx].constraint; + dfa->nodes[dup_idx].duplicated = 1; + + /* Store the index of the original node. */ + dfa->org_indices[dup_idx] = org_idx; + } + return dup_idx; } static reg_errcode_t -calc_inveclosure (dfa) - re_dfa_t *dfa; +calc_inveclosure (re_dfa_t *dfa) { int src, idx, ret; for (idx = 0; idx < dfa->nodes_len; ++idx) @@ -1639,8 +1630,7 @@ calc_inveclosure (dfa) /* Calculate "eclosure" for all the node in DFA. */ static reg_errcode_t -calc_eclosure (dfa) - re_dfa_t *dfa; +calc_eclosure (re_dfa_t *dfa) { int node_idx, incomplete; #ifdef DEBUG @@ -1684,16 +1674,13 @@ calc_eclosure (dfa) /* Calculate epsilon closure of NODE. */ static reg_errcode_t -calc_eclosure_iter (new_set, dfa, node, root) - re_node_set *new_set; - re_dfa_t *dfa; - int node, root; +calc_eclosure_iter (re_node_set *new_set, re_dfa_t *dfa, int node, int root) { reg_errcode_t err; - unsigned int constraint; - int i, incomplete; + int i; re_node_set eclosure; - incomplete = 0; + int ret; + int incomplete = 0; err = re_node_set_alloc (&eclosure, dfa->edests[node].nelem + 1); if (BE (err != REG_NOERROR, 0)) return err; @@ -1702,17 +1689,14 @@ calc_eclosure_iter (new_set, dfa, node, We reference this value to avoid infinite loop. */ dfa->eclosures[node].nelem = -1; - constraint = ((dfa->nodes[node].type == ANCHOR) - ? dfa->nodes[node].opr.ctx_type : 0); - /* If the current node has constraints, duplicate all nodes. - Since they must inherit the constraints. */ - if (constraint + /* If the current node has constraints, duplicate all nodes + since they must inherit the constraints. */ + if (dfa->nodes[node].constraint && dfa->edests[node].nelem && !dfa->nodes[dfa->edests[node].elems[0]].duplicated) { - int org_node, cur_node; - org_node = cur_node = node; - err = duplicate_node_closure (dfa, node, node, node, constraint); + err = duplicate_node_closure (dfa, node, node, node, + dfa->nodes[node].constraint); if (BE (err != REG_NOERROR, 0)) return err; } @@ -1741,7 +1725,9 @@ calc_eclosure_iter (new_set, dfa, node, else eclosure_elem = dfa->eclosures[edest]; /* Merge the epsilon closure of `edest'. */ - re_node_set_merge (&eclosure, &eclosure_elem); + err = re_node_set_merge (&eclosure, &eclosure_elem); + if (BE (err != REG_NOERROR, 0)) + return err; /* If the epsilon closure of `edest' is incomplete, the epsilon closure of this node is also incomplete. */ if (dfa->eclosures[edest].nelem == 0) @@ -1751,8 +1737,10 @@ calc_eclosure_iter (new_set, dfa, node, } } - /* Epsilon closures include itself. */ - re_node_set_insert (&eclosure, node); + /* An epsilon closure includes itself. */ + ret = re_node_set_insert (&eclosure, node); + if (BE (ret < 0, 0)) + return REG_ESPACE; if (incomplete && !root) dfa->eclosures[node].nelem = 0; else @@ -1767,10 +1755,8 @@ calc_eclosure_iter (new_set, dfa, node, We must not use this function inside bracket expressions. */ static void -fetch_token (result, input, syntax) - re_token_t *result; - re_string_t *input; - reg_syntax_t syntax; +internal_function +fetch_token (re_token_t *result, re_string_t *input, reg_syntax_t syntax) { re_string_skip_bytes (input, peek_token (result, input, syntax)); } @@ -1779,10 +1765,8 @@ fetch_token (result, input, syntax) We must not use this function inside bracket expressions. */ static int -peek_token (token, input, syntax) - re_token_t *token; - re_string_t *input; - reg_syntax_t syntax; +internal_function +peek_token (re_token_t *token, re_string_t *input, reg_syntax_t syntax) { unsigned char c; *** DIFF OUTPUT TRUNCATED AT 1000 LINES *** From owner-svn-src-all@FreeBSD.ORG Thu May 16 23:25:12 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id 7799E9CB; Thu, 16 May 2013 23:25:12 +0000 (UTC) (envelope-from jkim@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id 516235E4; Thu, 16 May 2013 23:25:12 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.6/8.14.6) with ESMTP id r4GNPCpb063011; Thu, 16 May 2013 23:25:12 GMT (envelope-from jkim@svn.freebsd.org) Received: (from jkim@localhost) by svn.freebsd.org (8.14.6/8.14.5/Submit) id r4GNPCFB063010; Thu, 16 May 2013 23:25:12 GMT (envelope-from jkim@svn.freebsd.org) Message-Id: <201305162325.r4GNPCFB063010@svn.freebsd.org> From: Jung-uk Kim Date: Thu, 16 May 2013 23:25:12 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-vendor@freebsd.org Subject: svn commit: r250725 - vendor/libregex/glibc-2.17 X-SVN-Group: vendor MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 16 May 2013 23:25:12 -0000 Author: jkim Date: Thu May 16 23:25:11 2013 New Revision: 250725 URL: http://svnweb.freebsd.org/changeset/base/250725 Log: Tag libregex from GNU libc 2.17. Added: vendor/libregex/glibc-2.17/ - copied from r250724, vendor/libregex/dist/ From owner-svn-src-all@FreeBSD.ORG Thu May 16 23:30:12 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id 69D3FBB0; Thu, 16 May 2013 23:30:12 +0000 (UTC) (envelope-from jkim@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id 5C90661B; Thu, 16 May 2013 23:30:12 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.6/8.14.6) with ESMTP id r4GNUB3R063940; Thu, 16 May 2013 23:30:11 GMT (envelope-from jkim@svn.freebsd.org) Received: (from jkim@localhost) by svn.freebsd.org (8.14.6/8.14.5/Submit) id r4GNUBLc063939; Thu, 16 May 2013 23:30:11 GMT (envelope-from jkim@svn.freebsd.org) Message-Id: <201305162330.r4GNUBLc063939@svn.freebsd.org> From: Jung-uk Kim Date: Thu, 16 May 2013 23:30:11 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-vendor@freebsd.org Subject: svn commit: r250726 - vendor/libregex X-SVN-Group: vendor MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 16 May 2013 23:30:12 -0000 Author: jkim Date: Thu May 16 23:30:11 2013 New Revision: 250726 URL: http://svnweb.freebsd.org/changeset/base/250726 Log: Add a script to extract libregex from GNU libc. Added: vendor/libregex/libgnuregex_prep.sh (contents, props changed) Added: vendor/libregex/libgnuregex_prep.sh ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ vendor/libregex/libgnuregex_prep.sh Thu May 16 23:30:11 2013 (r250726) @@ -0,0 +1,42 @@ +#!/bin/sh +# $FreeBSD$ + +DISTVERS=2.17 +DISTNAME=glibc-${DISTVERS} +DISTURL=http://ftp.gnu.org/gnu/libc/ +DISTSUFX=.tar.xz +DISTFILE=${DISTNAME}${DISTSUFX} +REGEXDIR=${DISTNAME}/posix +REGEXNAME=libgnuregex-${DISTVERS} +REGEXFILES=" \ + regcomp.c \ + regex.c \ + regex.h \ + regex_internal.c \ + regex_internal.h \ + regexec.c \ +" + +echo -n "Downloading ${DISTNAME}..." +fetch -q ${DISTURL}${DISTFILE} +echo " Done." + +echo -n "Extracting ${DISTNAME}..." +tar -x -f ${DISTFILE} ${REGEXDIR} +echo " Done." + +echo -n "Creating ${REGEXNAME}..." +tar -c -J --uid 0 --gid 0 -f ${REGEXNAME}${DISTSUFX} -C ${DISTNAME}/posix \ + -s "|^|${REGEXNAME}/|" ${REGEXFILES} +echo " Done." + +echo -n "Cleaning up..." +rm -fr ${DISTFILE} ${DISTNAME} +echo " Done." + +echo +echo "GNU libc is repackaged as ${REGEXNAME}${DISTSUFX}." +echo "Please follow vendor import guide of the Handbook." +echo + +exit 0 From owner-svn-src-all@FreeBSD.ORG Fri May 17 00:14:36 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id E80EE58E; Fri, 17 May 2013 00:14:36 +0000 (UTC) (envelope-from eadler@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id DA147861; Fri, 17 May 2013 00:14:36 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.6/8.14.6) with ESMTP id r4H0Ea8S080510; Fri, 17 May 2013 00:14:36 GMT (envelope-from eadler@svn.freebsd.org) Received: (from eadler@localhost) by svn.freebsd.org (8.14.6/8.14.5/Submit) id r4H0EaxZ080509; Fri, 17 May 2013 00:14:36 GMT (envelope-from eadler@svn.freebsd.org) Message-Id: <201305170014.r4H0EaxZ080509@svn.freebsd.org> From: Eitan Adler Date: Fri, 17 May 2013 00:14:36 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org Subject: svn commit: r250727 - stable/9/usr.sbin/wpa/wpa_supplicant X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 17 May 2013 00:14:37 -0000 Author: eadler Date: Fri May 17 00:14:36 2013 New Revision: 250727 URL: http://svnweb.freebsd.org/changeset/base/250727 Log: MFC r250528: Teach wpa_supplicant to properly compute wireless signal strength. PR: bin/170631 Modified: stable/9/usr.sbin/wpa/wpa_supplicant/driver_freebsd.c Directory Properties: stable/9/usr.sbin/wpa/ (props changed) stable/9/usr.sbin/wpa/wpa_supplicant/ (props changed) Modified: stable/9/usr.sbin/wpa/wpa_supplicant/driver_freebsd.c ============================================================================== --- stable/9/usr.sbin/wpa/wpa_supplicant/driver_freebsd.c Thu May 16 23:30:11 2013 (r250726) +++ stable/9/usr.sbin/wpa/wpa_supplicant/driver_freebsd.c Fri May 17 00:14:36 2013 (r250727) @@ -693,6 +693,11 @@ wpa_driver_bsd_add_scan_entry(struct wpa result->caps = sr->isr_capinfo; result->qual = sr->isr_rssi; result->noise = sr->isr_noise; + /* + * the rssi value reported by the kernel is in 0.5dB steps relative to + * the reported noise floor. see ieee80211_node.h for details. + */ + result->level = sr->isr_rssi / 2 + sr->isr_noise; pos = (u8 *)(result + 1); From owner-svn-src-all@FreeBSD.ORG Fri May 17 00:40:47 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id 15E33A87; Fri, 17 May 2013 00:40:47 +0000 (UTC) (envelope-from eadler@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id 07E63922; Fri, 17 May 2013 00:40:47 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.6/8.14.6) with ESMTP id r4H0ektn090035; Fri, 17 May 2013 00:40:46 GMT (envelope-from eadler@svn.freebsd.org) Received: (from eadler@localhost) by svn.freebsd.org (8.14.6/8.14.5/Submit) id r4H0ek9A090034; Fri, 17 May 2013 00:40:46 GMT (envelope-from eadler@svn.freebsd.org) Message-Id: <201305170040.r4H0ek9A090034@svn.freebsd.org> From: Eitan Adler Date: Fri, 17 May 2013 00:40:46 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org Subject: svn commit: r250729 - stable/9/usr.sbin/vidcontrol X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 17 May 2013 00:40:47 -0000 Author: eadler Date: Fri May 17 00:40:46 2013 New Revision: 250729 URL: http://svnweb.freebsd.org/changeset/base/250729 Log: MFC r250509: The M_VESA_MODE_MAX is latest valid mode - not the first invalid. Permit its use in vidcontrol -i PR: bin/119483 Modified: stable/9/usr.sbin/vidcontrol/vidcontrol.c Directory Properties: stable/9/usr.sbin/vidcontrol/ (props changed) Modified: stable/9/usr.sbin/vidcontrol/vidcontrol.c ============================================================================== --- stable/9/usr.sbin/vidcontrol/vidcontrol.c Fri May 17 00:26:56 2013 (r250728) +++ stable/9/usr.sbin/vidcontrol/vidcontrol.c Fri May 17 00:40:46 2013 (r250729) @@ -961,7 +961,7 @@ show_mode_info(void) printf("---------------------------------------" "---------------------------------------\n"); - for (mode = 0; mode < M_VESA_MODE_MAX; ++mode) { + for (mode = 0; mode <= M_VESA_MODE_MAX; ++mode) { _info.vi_mode = mode; if (ioctl(0, CONS_MODEINFO, &_info)) continue; From owner-svn-src-all@FreeBSD.ORG Fri May 17 00:40:49 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id 6B5AEA88; Fri, 17 May 2013 00:40:49 +0000 (UTC) (envelope-from eadler@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id 5E3A0923; Fri, 17 May 2013 00:40:49 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.6/8.14.6) with ESMTP id r4H0enkr090072; Fri, 17 May 2013 00:40:49 GMT (envelope-from eadler@svn.freebsd.org) Received: (from eadler@localhost) by svn.freebsd.org (8.14.6/8.14.5/Submit) id r4H0enqK090071; Fri, 17 May 2013 00:40:49 GMT (envelope-from eadler@svn.freebsd.org) Message-Id: <201305170040.r4H0enqK090071@svn.freebsd.org> From: Eitan Adler Date: Fri, 17 May 2013 00:40:49 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-8@freebsd.org Subject: svn commit: r250730 - stable/8/usr.sbin/vidcontrol X-SVN-Group: stable-8 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 17 May 2013 00:40:49 -0000 Author: eadler Date: Fri May 17 00:40:48 2013 New Revision: 250730 URL: http://svnweb.freebsd.org/changeset/base/250730 Log: MFC r250509: The M_VESA_MODE_MAX is latest valid mode - not the first invalid. Permit its use in vidcontrol -i PR: bin/119483 Modified: stable/8/usr.sbin/vidcontrol/vidcontrol.c Modified: stable/8/usr.sbin/vidcontrol/vidcontrol.c ============================================================================== --- stable/8/usr.sbin/vidcontrol/vidcontrol.c Fri May 17 00:40:46 2013 (r250729) +++ stable/8/usr.sbin/vidcontrol/vidcontrol.c Fri May 17 00:40:48 2013 (r250730) @@ -961,7 +961,7 @@ show_mode_info(void) printf("---------------------------------------" "---------------------------------------\n"); - for (mode = 0; mode < M_VESA_MODE_MAX; ++mode) { + for (mode = 0; mode <= M_VESA_MODE_MAX; ++mode) { _info.vi_mode = mode; if (ioctl(0, CONS_MODEINFO, &_info)) continue; From owner-svn-src-all@FreeBSD.ORG Fri May 17 01:49:17 2013 Return-Path: Delivered-To: svn-src-all@FreeBSD.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id 3931AB3F; Fri, 17 May 2013 01:49:17 +0000 (UTC) (envelope-from rpaulo@FreeBSD.org) Received: from felyko.com (felyko.com [174.136.100.2]) by mx1.freebsd.org (Postfix) with ESMTP id 24D44BD7; Fri, 17 May 2013 01:49:16 +0000 (UTC) Received: from [IPv6:2601:9:4d00:42:4d40:fa57:7618:2b24] (unknown [IPv6:2601:9:4d00:42:4d40:fa57:7618:2b24]) (using TLSv1 with cipher AES128-SHA (128/128 bits)) (No client certificate requested) by felyko.com (Postfix) with ESMTPSA id 611B33984A; Fri, 17 May 2013 01:49:06 -0700 (PDT) Content-Type: text/plain; charset=windows-1252 Mime-Version: 1.0 (Mac OS X Mail 6.3 \(1503\)) Subject: Re: svn commit: r250692 - head/sys/arm/conf From: Rui Paulo In-Reply-To: <30BAC0E1-9E8F-4FA4-A31E-C2AFAFDBCB95@freebsd.org> Date: Thu, 16 May 2013 18:49:07 -0700 Content-Transfer-Encoding: quoted-printable Message-Id: References: <201305160351.r4G3p0uu047404@svn.freebsd.org> <30BAC0E1-9E8F-4FA4-A31E-C2AFAFDBCB95@freebsd.org> To: Tim Kientzle X-Mailer: Apple Mail (2.1503) Cc: svn-src-head@FreeBSD.org, svn-src-all@FreeBSD.org, src-committers@FreeBSD.org X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 17 May 2013 01:49:17 -0000 On 2013/05/16, at 2:02, Tim Kientzle wrote: > I don't object, but I'm not sure why we need this. >=20 > I'd rather see a comment in the BEAGLEBONE > config indicating that it can be used with > beaglebone-black.dts. >=20 > Generally, I want us to move away from compiled-in > DTBs. The BEAGLEBONE config works just fine on either > one and it's what I plan to continue using going forward. >=20 > Part of the boot loader's job is to load the correct DTB. > The images built by Crochet today already do this > and produce images that boot on either old or new > BeagleBone using the BEAGLEBONE config. >=20 > U-Boot already has logic to detect the board, > load the correct DTB, and the same BEAGLEBONE > kernel then runs just fine. Here are the U-Boot > patches if you'd like to do this as well: >=20 > = https://github.com/kientzle/crochet-freebsd/tree/master/board/BeagleBone/f= iles >=20 > (There's also a copy of the compiled U-Boot and > associated files at: >=20 > http://people.freebsd.org/~kientzle/beaglebone-and-black-bootfiles.tgz >=20 > Moving forward, I'd like to see us generally consolidate ARM > kernel configurations. I have some (still very experimental) > ideas for combining the RPi and BeagleBone kernels > into a single kernel, but with my limited time, that will > be a fairly long-term project. If anyone's at BSDCan > who would like to talk about it=85. I'll be at the > "Beyond BuildWorld" session on Thursday=85. ;-) >=20 > Yes, this is certainly useful for people net booting > the BeagleBone Black for developing kernel drivers, > but I'm not sure why we would bother having it > checked-in. I understand your point, but what about drivers that only apply to the = BeagleBone Black, such as a driver for HDMI? Wouldn't that require a = separate kernel config file or are we expecting to use only kernel = modules? Regards, -- Rui Paulo From owner-svn-src-all@FreeBSD.ORG Fri May 17 02:03:33 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 1033) id 775A2FCA; Fri, 17 May 2013 02:03:33 +0000 (UTC) Date: Fri, 17 May 2013 02:03:33 +0000 From: Alexey Dokuchaev To: Eitan Adler Subject: Re: svn commit: r250727 - stable/9/usr.sbin/wpa/wpa_supplicant Message-ID: <20130517020333.GA7012@FreeBSD.org> References: <201305170014.r4H0EaxZ080509@svn.freebsd.org> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <201305170014.r4H0EaxZ080509@svn.freebsd.org> User-Agent: Mutt/1.5.21 (2010-09-15) Cc: svn-src-stable@freebsd.org, svn-src-all@freebsd.org, src-committers@freebsd.org, svn-src-stable-9@freebsd.org X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 17 May 2013 02:03:33 -0000 On Fri, May 17, 2013 at 12:14:36AM +0000, Eitan Adler wrote: > New Revision: 250727 > URL: http://svnweb.freebsd.org/changeset/base/250727 > > Log: > MFC r250528: > Teach wpa_supplicant to properly compute wireless signal strength. If this applicable to stable/8? If yes, can it be MFC'ed? ./danfe From owner-svn-src-all@FreeBSD.ORG Fri May 17 03:14:56 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id 122ECB6D; Fri, 17 May 2013 03:14:56 +0000 (UTC) (envelope-from gad@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id 042C8CD; Fri, 17 May 2013 03:14:56 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.6/8.14.6) with ESMTP id r4H3EtId045121; Fri, 17 May 2013 03:14:55 GMT (envelope-from gad@svn.freebsd.org) Received: (from gad@localhost) by svn.freebsd.org (8.14.6/8.14.5/Submit) id r4H3Et8a045120; Fri, 17 May 2013 03:14:55 GMT (envelope-from gad@svn.freebsd.org) Message-Id: <201305170314.r4H3Et8a045120@svn.freebsd.org> From: Garance A Drosehn Date: Fri, 17 May 2013 03:14:55 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r250731 - head X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 17 May 2013 03:14:56 -0000 Author: gad Date: Fri May 17 03:14:55 2013 New Revision: 250731 URL: http://svnweb.freebsd.org/changeset/base/250731 Log: Drop any connection to newsyslog. I haven't worked on it for quite some time. Note that I do want to keep the pre-commit review for usr.sbin/lpr. I am actively working on some updates for that. Modified: head/MAINTAINERS Modified: head/MAINTAINERS ============================================================================== --- head/MAINTAINERS Fri May 17 00:40:48 2013 (r250730) +++ head/MAINTAINERS Fri May 17 03:14:55 2013 (r250731) @@ -63,7 +63,6 @@ procfs des Pre-commit review requested. linprocfs des Pre-commit review requested. lpr gad Pre-commit review requested, particularly for lpd/recvjob.c and lpd/printjob.c. -newsyslog(8) gad Heads-up appreciated. I'm going thru the PR's for it. nvi peter Try not to break it. libz peter Try not to break it. groff ru Recommends pre-commit review. From owner-svn-src-all@FreeBSD.ORG Fri May 17 03:52:21 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id 106292DE; Fri, 17 May 2013 03:52:21 +0000 (UTC) (envelope-from grog@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id DCC732AA; Fri, 17 May 2013 03:52:20 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.6/8.14.6) with ESMTP id r4H3qKjk058237; Fri, 17 May 2013 03:52:20 GMT (envelope-from grog@svn.freebsd.org) Received: (from grog@localhost) by svn.freebsd.org (8.14.6/8.14.5/Submit) id r4H3qKRd058236; Fri, 17 May 2013 03:52:20 GMT (envelope-from grog@svn.freebsd.org) Message-Id: <201305170352.r4H3qKRd058236@svn.freebsd.org> From: Greg Lehey Date: Fri, 17 May 2013 03:52:20 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r250732 - head/bin/df X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 17 May 2013 03:52:21 -0000 Author: grog Date: Fri May 17 03:52:20 2013 New Revision: 250732 URL: http://svnweb.freebsd.org/changeset/base/250732 Log: Complete revision 243104. Modified: head/bin/df/df.1 Modified: head/bin/df/df.1 ============================================================================== --- head/bin/df/df.1 Fri May 17 03:14:55 2013 (r250731) +++ head/bin/df/df.1 Fri May 17 03:52:20 2013 (r250732) @@ -196,7 +196,9 @@ If the value is outside, it will be set .Xr localeconv 3 , .Xr fstab 5 , .Xr mount 8 , -.Xr quot 8 . +.Xr pstat 8 , +.Xr quot 8 , +.Xr swapinfo 8 . .Sh STANDARDS With the exception of most options, the From owner-svn-src-all@FreeBSD.ORG Fri May 17 03:55:04 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id 7D41049A; Fri, 17 May 2013 03:55:04 +0000 (UTC) (envelope-from grog@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id 601B02CC; Fri, 17 May 2013 03:55:04 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.6/8.14.6) with ESMTP id r4H3t42G058788; Fri, 17 May 2013 03:55:04 GMT (envelope-from grog@svn.freebsd.org) Received: (from grog@localhost) by svn.freebsd.org (8.14.6/8.14.5/Submit) id r4H3t4rX058785; Fri, 17 May 2013 03:55:04 GMT (envelope-from grog@svn.freebsd.org) Message-Id: <201305170355.r4H3t4rX058785@svn.freebsd.org> From: Greg Lehey Date: Fri, 17 May 2013 03:55:04 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org Subject: svn commit: r250733 - stable/9/bin/df X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 17 May 2013 03:55:04 -0000 Author: grog Date: Fri May 17 03:55:03 2013 New Revision: 250733 URL: http://svnweb.freebsd.org/changeset/base/250733 Log: MFC revisions 243049,243129,244134,245871,245912,249698,249924 Modified: stable/9/bin/df/df.1 stable/9/bin/df/df.c Directory Properties: stable/9/bin/df/ (props changed) Modified: stable/9/bin/df/df.1 ============================================================================== --- stable/9/bin/df/df.1 Fri May 17 03:52:20 2013 (r250732) +++ stable/9/bin/df/df.1 Fri May 17 03:55:03 2013 (r250733) @@ -29,7 +29,7 @@ .\" @(#)df.1 8.3 (Berkeley) 5/8/95 .\" $FreeBSD$ .\" -.Dd March 3, 2012 +.Dd January 24, 2013 .Dt DF 1 .Os .Sh NAME @@ -39,6 +39,7 @@ .Nm .Op Fl b | g | H | h | k | m | P .Op Fl acilnT +.Op Fl \&, .Op Fl t Ar type .Op Ar file | filesystem ... .Sh DESCRIPTION @@ -50,7 +51,8 @@ displays statistics about the amount of or on the file system of which .Ar file is a part. -Values are displayed in 512-byte per block counts. +By default block counts are displayed with an assumed block size of +512 bytes. If neither a file or a file system operand is specified, statistics for all mounted file systems are displayed (subject to the @@ -65,48 +67,54 @@ Show all mount points, including those t flag. This is implied for file systems specified on the command line. .It Fl b -Use 512-byte blocks rather than the default. -Note that -this overrides the +Explicitly use 512 byte blocks, overriding any .Ev BLOCKSIZE specification from the environment. +This is the same as the +.Fl P +option. +The +.Fl k +option overrides this option. .It Fl c Display a grand total. .It Fl g -Use 1073741824-byte (1-Gbyte) blocks rather than the default. -Note that -this overrides the +Use 1073741824 byte (1 Gibibyte) blocks rather than the default. +This overrides any .Ev BLOCKSIZE specification from the environment. .It Fl H .Dq Human-readable output. -Use unit suffixes: Byte, Kilobyte, Megabyte, -Gigabyte, Terabyte and Petabyte in order to reduce the number of -digits to four or fewer using base 10 for sizes. +Use unit suffixes: Byte, Kibibyte, Mebibyte, Gibibyte, Tebibyte and +Pebibyte (based on powers of 1024) in order to reduce the number of +digits to four or fewer. .It Fl h .Dq Human-readable output. Use unit suffixes: Byte, Kilobyte, Megabyte, -Gigabyte, Terabyte and Petabyte in order to reduce the number of -digits to four or fewer using base 2 for sizes. -Inodes statistics, if enabled with -.Fl i , -are always printed in base 10. +Gigabyte, Terabyte and Petabyte (based on powers of 1000) in order to +reduce the number of +digits to four or fewer. .It Fl i -Include statistics on the number of free inodes. +Include statistics on the number of free and used inodes. +In conjunction with the +.Fl h +or +.Fl H +options, the number of inodes is scaled by powers of 1000. .It Fl k -Use 1024-byte (1-Kbyte) blocks rather than the default. -Note that -this overrides the +Use 1024 byte (1 Kibibyte) blocks rather than the default. +This overrides the +.Fl P +option and any .Ev BLOCKSIZE specification from the environment. .It Fl l Only display information about locally-mounted file systems. .It Fl m -Use 1048576-byte (1-Mbyte) blocks rather than the default. -Note that -this overrides the +Use 1048576 byte (1 Mebibyte) blocks rather than the default. +This overrides any .Ev BLOCKSIZE specification from the environment. .It Fl n @@ -119,10 +127,15 @@ When this option is specified, will not request new statistics from the file systems, but will respond with the possibly stale statistics that were previously obtained. .It Fl P -Use POSIX compliant output of 512-byte blocks rather than the default. -Note that this overrides the +Explicitly use 512 byte blocks, overriding any .Ev BLOCKSIZE specification from the environment. +This is the same as the +.Fl b +option. +The +.Fl k +option overrides this option. .It Fl t Only print out statistics for file systems of the specified types. More than one type may be specified in a comma separated list. @@ -148,13 +161,29 @@ command can be used to find out the type that are available on the system. .It Fl T Include file system type. +.It Fl , +(Comma) Print sizes grouped and separated by thousands using the +non-monetary separator returned by +.Xr localeconv 3 , +typically a comma or period. +If no locale is set, or the locale does not have a non-monetary separator, this +option has no effect. .El .Sh ENVIRONMENT .Bl -tag -width BLOCKSIZE .It Ev BLOCKSIZE -If the environment variable -.Ev BLOCKSIZE -is set, the block counts will be displayed in units of that size block. +Specifies the units in which to report block counts. +This uses +.Xr getbsize 3 , +which allows units of bytes or numbers scaled with the letters +.Em k +(for multiples of 1024 bytes), +.Em m +(for multiples of 1048576 bytes) or +.Em g +(for gibibytes). +The allowed range is 512 bytes to 1 GB. +If the value is outside, it will be set to the appropriate limit. .El .Sh SEE ALSO .Xr lsvfs 1 , @@ -164,10 +193,23 @@ is set, the block counts will be display .Xr fstatfs 2 , .Xr getfsstat 2 , .Xr statfs 2 , +.Xr getbsize 3 , .Xr getmntinfo 3 , +.Xr localeconv 3 , .Xr fstab 5 , .Xr mount 8 , -.Xr quot 8 +.Xr quot 8 . +.Sh STANDARDS +With the exception of most options, +the +.Nm +utility conforms to +.St -p1003.1-2004 , +which defines only the +.Fl k , P +and +.Fl t +options. .Sh HISTORY A .Nm @@ -180,3 +222,13 @@ flag is ignored if a file or file system Also, if a mount point is not accessible by the user, it is possible that the file system information could be stale. +.Pp +The +.Fl b +and +.Fl P +options are identical. +The former comes from the BSD tradition, and the latter is required +for +.St -p1003.1-2004 +conformity. Modified: stable/9/bin/df/df.c ============================================================================== --- stable/9/bin/df/df.c Fri May 17 03:52:20 2013 (r250732) +++ stable/9/bin/df/df.c Fri May 17 03:55:03 2013 (r250733) @@ -53,6 +53,7 @@ __FBSDID("$FreeBSD$"); #include #include #include +#include #include #include #include @@ -95,6 +96,7 @@ imax(int a, int b) } static int aflag = 0, cflag, hflag, iflag, kflag, lflag = 0, nflag, Tflag; +static int thousands; static struct ufs_args mdev; int @@ -111,12 +113,13 @@ main(int argc, char *argv[]) int ch, rv; fstype = "ufs"; - + (void)setlocale(LC_ALL, ""); + memset(&maxwidths, 0, sizeof(maxwidths)); memset(&totalbuf, 0, sizeof(totalbuf)); totalbuf.f_bsize = DEV_BSIZE; strlcpy(totalbuf.f_mntfromname, "total", MNAMELEN); vfslist = NULL; - while ((ch = getopt(argc, argv, "abcgHhiklmnPt:T")) != -1) + while ((ch = getopt(argc, argv, "abcgHhiklmnPt:T,")) != -1) switch (ch) { case 'a': aflag = 1; @@ -180,6 +183,9 @@ main(int argc, char *argv[]) case 'T': Tflag = 1; break; + case ',': + thousands = 1; + break; case '?': default: usage(); @@ -195,7 +201,7 @@ main(int argc, char *argv[]) } else { /* just the filesystems specified on the command line */ mntbuf = malloc(argc * sizeof(*mntbuf)); - if (mntbuf == 0) + if (mntbuf == NULL) err(1, "malloc()"); mntsize = 0; /* continued in for loop below */ @@ -204,13 +210,13 @@ main(int argc, char *argv[]) /* iterate through specified filesystems */ for (; *argv; argv++) { if (stat(*argv, &stbuf) < 0) { - if ((mntpt = getmntpt(*argv)) == 0) { + if ((mntpt = getmntpt(*argv)) == NULL) { warn("%s", *argv); rv = 1; continue; } } else if (S_ISCHR(stbuf.st_mode)) { - if ((mntpt = getmntpt(*argv)) == 0) { + if ((mntpt = getmntpt(*argv)) == NULL) { mdev.fspec = *argv; mntpath = strdup("/tmp/df.XXXXXX"); if (mntpath == NULL) { @@ -277,7 +283,7 @@ main(int argc, char *argv[]) mntbuf[mntsize++] = statfsbuf; } - bzero(&maxwidths, sizeof(maxwidths)); + memset(&maxwidths, 0, sizeof(maxwidths)); for (i = 0; i < mntsize; i++) { if (aflag || (mntbuf[i].f_flags & MNT_IGNORE) == 0) { update_maxwidths(&maxwidths, &mntbuf[i]); @@ -304,7 +310,7 @@ getmntpt(const char *name) if (!strcmp(mntbuf[i].f_mntfromname, name)) return (mntbuf[i].f_mntonname); } - return (0); + return (NULL); } /* @@ -388,16 +394,11 @@ prthumanvalinode(int64_t bytes) /* * Convert statfs returned file system size into BLOCKSIZE units. - * Attempts to avoid overflow for large file systems. */ static intmax_t fsbtoblk(int64_t num, uint64_t fsbs, u_long bs) { - - if (fsbs != 0 && fsbs < bs) - return (num / (intmax_t)(bs / fsbs)); - else - return (num * (intmax_t)(fsbs / bs)); + return (num * (intmax_t) fsbs / (int64_t) bs); } /* @@ -410,10 +411,18 @@ prtstat(struct statfs *sfsp, struct maxw static int headerlen, timesthrough = 0; static const char *header; int64_t used, availblks, inodes; + const char *format; if (++timesthrough == 1) { mwp->mntfrom = imax(mwp->mntfrom, (int)strlen("Filesystem")); mwp->fstype = imax(mwp->fstype, (int)strlen("Type")); + if (thousands) { /* make space for commas */ + mwp->total += (mwp->total - 1) / 3; + mwp->used += (mwp->used - 1) / 3; + mwp->avail += (mwp->avail - 1) / 3; + mwp->iused += (mwp->iused - 1) / 3; + mwp->ifree += (mwp->ifree - 1) / 3; + } if (hflag) { header = " Size"; mwp->total = mwp->used = mwp->avail = @@ -428,7 +437,7 @@ prtstat(struct statfs *sfsp, struct maxw (void)printf("%-*s", mwp->mntfrom, "Filesystem"); if (Tflag) (void)printf(" %-*s", mwp->fstype, "Type"); - (void)printf(" %-*s %*s %*s Capacity", mwp->total, header, + (void)printf(" %*s %*s %*s Capacity", mwp->total, header, mwp->used, "Used", mwp->avail, "Avail"); if (iflag) { mwp->iused = imax(hflag ? 0 : mwp->iused, @@ -440,6 +449,12 @@ prtstat(struct statfs *sfsp, struct maxw } (void)printf(" Mounted on\n"); } + /* Check for 0 block size. Can this happen? */ + if (sfsp->f_bsize == 0) { + warnx ("File system %s does not have a block size, assuming 512.", + sfsp->f_mntonname); + sfsp->f_bsize = 512; + } (void)printf("%-*s", mwp->mntfrom, sfsp->f_mntfromname); if (Tflag) (void)printf(" %-*s", mwp->fstype, sfsp->f_fstypename); @@ -448,7 +463,11 @@ prtstat(struct statfs *sfsp, struct maxw if (hflag) { prthuman(sfsp, used); } else { - (void)printf(" %*jd %*jd %*jd", + if (thousands) + format = " %*j'd %*j'd %*j'd"; + else + format = " %*jd %*jd %*jd"; + (void)printf(format, mwp->total, fsbtoblk(sfsp->f_blocks, sfsp->f_bsize, blocksize), mwp->used, fsbtoblk(used, sfsp->f_bsize, blocksize), @@ -465,7 +484,11 @@ prtstat(struct statfs *sfsp, struct maxw prthumanvalinode(used); prthumanvalinode(sfsp->f_ffree); } else { - (void)printf(" %*jd %*jd", mwp->iused, (intmax_t)used, + if (thousands) + format = " %*j'd %*j'd"; + else + format = " %*jd %*jd"; + (void)printf(format, mwp->iused, (intmax_t)used, mwp->ifree, (intmax_t)sfsp->f_ffree); } (void)printf(" %4.0f%% ", inodes == 0 ? 100.0 : @@ -542,7 +565,8 @@ usage(void) { (void)fprintf(stderr, -"usage: df [-b | -g | -H | -h | -k | -m | -P] [-acilnT] [-t type] [file | filesystem ...]\n"); +"usage: df [-b | -g | -H | -h | -k | -m | -P] [-acilnT] [-t type] [-,]\n" +" [file | filesystem ...]\n"); exit(EX_USAGE); } From owner-svn-src-all@FreeBSD.ORG Fri May 17 04:09:05 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id 5E33C7FD; Fri, 17 May 2013 04:09:05 +0000 (UTC) (envelope-from hiren@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id 4DE32364; Fri, 17 May 2013 04:09:05 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.6/8.14.6) with ESMTP id r4H495E0063276; Fri, 17 May 2013 04:09:05 GMT (envelope-from hiren@svn.freebsd.org) Received: (from hiren@localhost) by svn.freebsd.org (8.14.6/8.14.5/Submit) id r4H495sj063275; Fri, 17 May 2013 04:09:05 GMT (envelope-from hiren@svn.freebsd.org) Message-Id: <201305170409.r4H495sj063275@svn.freebsd.org> From: Hiren Panchasara Date: Fri, 17 May 2013 04:09:05 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org Subject: svn commit: r250734 - stable/9/sys/x86/cpufreq X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 17 May 2013 04:09:05 -0000 Author: hiren Date: Fri May 17 04:09:04 2013 New Revision: 250734 URL: http://svnweb.freebsd.org/changeset/base/250734 Log: MFC: r250487 Adding a detach method to p4tcc driver. PR: 118739 Submitted by: Dan Lukes (earlier version) Reviewed by: jhb Approved by: sbruno (mentor) Modified: stable/9/sys/x86/cpufreq/p4tcc.c Directory Properties: stable/9/ (props changed) stable/9/sys/ (props changed) Modified: stable/9/sys/x86/cpufreq/p4tcc.c ============================================================================== --- stable/9/sys/x86/cpufreq/p4tcc.c Fri May 17 03:55:03 2013 (r250733) +++ stable/9/sys/x86/cpufreq/p4tcc.c Fri May 17 04:09:04 2013 (r250734) @@ -73,6 +73,7 @@ static int p4tcc_features(driver_t *driv static void p4tcc_identify(driver_t *driver, device_t parent); static int p4tcc_probe(device_t dev); static int p4tcc_attach(device_t dev); +static int p4tcc_detach(device_t dev); static int p4tcc_settings(device_t dev, struct cf_setting *sets, int *count); static int p4tcc_set(device_t dev, const struct cf_setting *set); @@ -84,6 +85,7 @@ static device_method_t p4tcc_methods[] = DEVMETHOD(device_identify, p4tcc_identify), DEVMETHOD(device_probe, p4tcc_probe), DEVMETHOD(device_attach, p4tcc_attach), + DEVMETHOD(device_detach, p4tcc_detach), /* cpufreq interface */ DEVMETHOD(cpufreq_drv_set, p4tcc_set), @@ -213,6 +215,24 @@ p4tcc_attach(device_t dev) } static int +p4tcc_detach(device_t dev) +{ + struct cf_setting set; + int error; + + error = cpufreq_unregister(dev); + if (error) + return (error); + + /* + * Before we finish detach, switch to Automatic mode. + */ + set.freq = 10000; + p4tcc_set(dev, &set); + return(0); +} + +static int p4tcc_settings(device_t dev, struct cf_setting *sets, int *count) { struct p4tcc_softc *sc; From owner-svn-src-all@FreeBSD.ORG Fri May 17 05:16:31 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id AE927E4; Fri, 17 May 2013 05:16:31 +0000 (UTC) (envelope-from adrian@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id 38A81758; Fri, 17 May 2013 05:16:31 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.6/8.14.6) with ESMTP id r4H5GUbL087663; Fri, 17 May 2013 05:16:30 GMT (envelope-from adrian@svn.freebsd.org) Received: (from adrian@localhost) by svn.freebsd.org (8.14.6/8.14.5/Submit) id r4H5GUOH087662; Fri, 17 May 2013 05:16:30 GMT (envelope-from adrian@svn.freebsd.org) Message-Id: <201305170516.r4H5GUOH087662@svn.freebsd.org> From: Adrian Chadd Date: Fri, 17 May 2013 05:16:30 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r250735 - head/sys/dev/ath X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 17 May 2013 05:16:31 -0000 Author: adrian Date: Fri May 17 05:16:30 2013 New Revision: 250735 URL: http://svnweb.freebsd.org/changeset/base/250735 Log: Add some more debugging printf()s to complain if the ath_buf tx queue doesn't match the actual hardware queue this frame is queued to. I'm trying to ensure that the holding buffers are actually being queued to the same TX queue as the holding buffer that they end up on. I'm pretty sure this is all correct so if this complains, it'll be due to some kind of subtle broken-ness that needs fixing. This is only done for legacy hardware, not EDMA hardware. Tested: * AR5416 STA mode, very lightly Modified: head/sys/dev/ath/if_ath_tx.c Modified: head/sys/dev/ath/if_ath_tx.c ============================================================================== --- head/sys/dev/ath/if_ath_tx.c Fri May 17 04:09:04 2013 (r250734) +++ head/sys/dev/ath/if_ath_tx.c Fri May 17 05:16:30 2013 (r250735) @@ -703,6 +703,19 @@ ath_tx_handoff_mcast(struct ath_softc *s KASSERT((bf->bf_flags & ATH_BUF_BUSY) == 0, ("%s: busy status 0x%x", __func__, bf->bf_flags)); + /* + * Ensure that the tx queue is the cabq, so things get + * mapped correctly. + */ + if (bf->bf_state.bfs_tx_queue != sc->sc_cabq->axq_qnum) { + device_printf(sc->sc_dev, + "%s: bf=%p, bfs_tx_queue=%d, axq_qnum=%d\n", + __func__, + bf, + bf->bf_state.bfs_tx_queue, + txq->axq_qnum); + } + ATH_TXQ_LOCK(txq); if (ATH_TXQ_LAST(txq, axq_q_s) != NULL) { struct ath_buf *bf_last = ATH_TXQ_LAST(txq, axq_q_s); @@ -900,6 +913,16 @@ ath_tx_handoff_hw(struct ath_softc *sc, } #endif /* IEEE80211_SUPPORT_TDMA */ + + if (bf->bf_state.bfs_tx_queue != txq->axq_qnum) { + device_printf(sc->sc_dev, + "%s: bf=%p, bfs_tx_queue=%d, axq_qnum=%d\n", + __func__, + bf, + bf->bf_state.bfs_tx_queue, + txq->axq_qnum); + } + if (bf->bf_state.bfs_aggr) txq->axq_aggr_depth++; ath_hal_gettxdesclinkptr(ah, bf->bf_lastds, &txq->axq_link); From owner-svn-src-all@FreeBSD.ORG Fri May 17 05:45:10 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 1033) id 13DA94C0; Fri, 17 May 2013 05:45:10 +0000 (UTC) Date: Fri, 17 May 2013 05:45:10 +0000 From: Alexey Dokuchaev To: Hiren Panchasara Subject: Re: svn commit: r250734 - stable/9/sys/x86/cpufreq Message-ID: <20130517054509.GA52849@FreeBSD.org> References: <201305170409.r4H495sj063275@svn.freebsd.org> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <201305170409.r4H495sj063275@svn.freebsd.org> User-Agent: Mutt/1.5.21 (2010-09-15) Cc: svn-src-stable@freebsd.org, svn-src-all@freebsd.org, src-committers@freebsd.org, svn-src-stable-9@freebsd.org X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 17 May 2013 05:45:10 -0000 On Fri, May 17, 2013 at 04:09:05AM +0000, Hiren Panchasara wrote: > New Revision: 250734 > URL: http://svnweb.freebsd.org/changeset/base/250734 > > Log: > MFC: r250487 > > Adding a detach method to p4tcc driver. Would it also benefit stable/8? If yes, could it be MFC'ed? ./danfe From owner-svn-src-all@FreeBSD.ORG Fri May 17 07:24:17 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id C53FBDDD; Fri, 17 May 2013 07:24:17 +0000 (UTC) (envelope-from gprspb@mail.ru) Received: from fallback3.mail.ru (fallback3.mail.ru [94.100.176.58]) by mx1.freebsd.org (Postfix) with ESMTP id 7BA82A73; Fri, 17 May 2013 07:24:17 +0000 (UTC) Received: from smtp3.mail.ru (smtp3.mail.ru [94.100.176.131]) by fallback3.mail.ru (mPOP.Fallback_MX) with ESMTP id 7EE15E335054; Fri, 17 May 2013 11:24:15 +0400 (MSK) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=mail.ru; s=mail2; h=In-Reply-To:Content-Type:MIME-Version:References:Message-ID:Subject:Cc:To:From:Date; bh=2qcGhaY2hP3NZ244aWnyvSA/4ppPzgvDdePGzHh8V1E=; b=gK8rBT4NSBXKXE7YFeSw93d8qhSBwhBXvIT99nuD6MW5QaW3h4vVYnG3QmDObHwuGhCfrhwHIzta8icCNuXt/Kj3Db2elA6zRVXMKwgXgFmAHD8qx2PT9Op29Xn2mVqG/Xub2qL2k4TQhUoMapQj1zofxBONyjmB5vaFP1AvXb0=; Received: from [93.185.182.46] (port=50718 helo=gpr.nnz-home.ru) by smtp3.mail.ru with esmtpa (envelope-from ) id 1UdF1M-0003tp-5b; Fri, 17 May 2013 11:24:08 +0400 Received: from gpr by gpr.nnz-home.ru with local (Exim 4.80.1 (FreeBSD)) (envelope-from ) id 1UdF10-0000Io-Dm; Fri, 17 May 2013 11:23:46 +0400 Date: Fri, 17 May 2013 11:23:46 +0400 From: Gennady Proskurin To: Julian Elischer Subject: Re: svn commit: r250700 - in head/sys: conf net netinet6 sys Message-ID: <20130517072346.GA1063@gpr.nnz-home.ru> References: <201305161620.r4GGKIFI012296@svn.freebsd.org> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <201305161620.r4GGKIFI012296@svn.freebsd.org> User-Agent: Mutt/1.5.21 (2010-09-15) X-Spam: Not detected X-Mras: Ok Cc: svn-src-head@freebsd.org, svn-src-all@freebsd.org, src-committers@freebsd.org X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 17 May 2013 07:24:17 -0000 On Thu, May 16, 2013 at 04:20:18PM +0000, Julian Elischer wrote: > +#define m_fibnum m_hdr.mh_nextpkt Are you sure this is correct? Shouldn't it be something like M_dat.MH.MH_pkthdr.fibnum or m_pkthdr.fibnum ? From owner-svn-src-all@FreeBSD.ORG Fri May 17 07:37:30 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id 77471169; Fri, 17 May 2013 07:37:30 +0000 (UTC) (envelope-from glebius@FreeBSD.org) Received: from cell.glebius.int.ru (glebius.int.ru [81.19.69.10]) by mx1.freebsd.org (Postfix) with ESMTP id 06EE0ACA; Fri, 17 May 2013 07:37:29 +0000 (UTC) Received: from cell.glebius.int.ru (localhost [127.0.0.1]) by cell.glebius.int.ru (8.14.6/8.14.6) with ESMTP id r4H7bMVF044716; Fri, 17 May 2013 11:37:22 +0400 (MSK) (envelope-from glebius@FreeBSD.org) Received: (from glebius@localhost) by cell.glebius.int.ru (8.14.6/8.14.6/Submit) id r4H7bM8u044715; Fri, 17 May 2013 11:37:22 +0400 (MSK) (envelope-from glebius@FreeBSD.org) X-Authentication-Warning: cell.glebius.int.ru: glebius set sender to glebius@FreeBSD.org using -f Date: Fri, 17 May 2013 11:37:21 +0400 From: Gleb Smirnoff To: Julian Elischer Subject: Re: svn commit: r250700 - in head/sys: conf net netinet6 sys Message-ID: <20130517073721.GX17164@FreeBSD.org> References: <201305161620.r4GGKIFI012296@svn.freebsd.org> MIME-Version: 1.0 Content-Type: text/plain; charset=koi8-r Content-Disposition: inline In-Reply-To: <201305161620.r4GGKIFI012296@svn.freebsd.org> User-Agent: Mutt/1.5.21 (2010-09-15) Cc: svn-src-head@freebsd.org, svn-src-all@freebsd.org, src-committers@freebsd.org X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 17 May 2013 07:37:30 -0000 On Thu, May 16, 2013 at 04:20:18PM +0000, Julian Elischer wrote: J> Modified: head/sys/sys/mbuf.h J> ============================================================================== J> --- head/sys/sys/mbuf.h Thu May 16 15:28:38 2013 (r250699) J> +++ head/sys/sys/mbuf.h Thu May 16 16:20:17 2013 (r250700) J> @@ -129,6 +129,8 @@ struct pkthdr { J> u_int16_t vt_vtag; /* Ethernet 802.1p+q vlan tag */ J> u_int16_t vt_nrecs; /* # of IGMPv3 records in this chain */ J> } PH_vt; J> + u_int16_t fibnum; /* this packet should use this fib */ J> + u_int16_t pad2; /* align to 32 bits */ J> SLIST_HEAD(packet_tags, m_tag) tags; /* list of packet tags */ J> }; J> #define ether_vtag PH_vt.vt_vtag J> @@ -171,6 +173,7 @@ struct mbuf { J> #define m_type m_hdr.mh_type J> #define m_flags m_hdr.mh_flags J> #define m_nextpkt m_hdr.mh_nextpkt J> +#define m_fibnum m_hdr.mh_nextpkt J> #define m_act m_nextpkt J> #define m_pkthdr M_dat.MH.MH_pkthdr J> #define m_ext M_dat.MH.MH_dat.MH_ext The define definitely looks incorrect. J> +static int inline J> +rt_m_getfib(struct mbuf *m) J> +{ J> + KASSERT(m->m_flags & M_EXT , ("attempt to set FIB on non header mbuf")); J> + return (m->m_pkthdr.fibnum); J> +} The KASSERT looks incorrect. Text doesn't match the test. IMO, text is correct, but the test is not. J> #define M_SETFIB(_m, _fib) do { \ J> - _m->m_flags &= ~M_FIB; \ J> - _m->m_flags |= (((_fib) << M_FIBSHIFT) & M_FIB); \ J> + KASSERT((_m)->m_flags & M_EXT, ("No FIB on non header mbuf")); \ J> + ((_m)->m_pkthdr.fibnum) = (_fib); \ J> } while (0) Same for this KASSERT. IMO, any change to struct mbuf should be announced and posted for review prior to committing. -- Totus tuus, Glebius. From owner-svn-src-all@FreeBSD.ORG Fri May 17 07:38:15 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id 2D6702E9; Fri, 17 May 2013 07:38:15 +0000 (UTC) (envelope-from glebius@FreeBSD.org) Received: from cell.glebius.int.ru (glebius.int.ru [81.19.69.10]) by mx1.freebsd.org (Postfix) with ESMTP id 95BA9AD2; Fri, 17 May 2013 07:38:14 +0000 (UTC) Received: from cell.glebius.int.ru (localhost [127.0.0.1]) by cell.glebius.int.ru (8.14.6/8.14.6) with ESMTP id r4H7cDsd044734; Fri, 17 May 2013 11:38:13 +0400 (MSK) (envelope-from glebius@FreeBSD.org) Received: (from glebius@localhost) by cell.glebius.int.ru (8.14.6/8.14.6/Submit) id r4H7cDdM044733; Fri, 17 May 2013 11:38:13 +0400 (MSK) (envelope-from glebius@FreeBSD.org) X-Authentication-Warning: cell.glebius.int.ru: glebius set sender to glebius@FreeBSD.org using -f Date: Fri, 17 May 2013 11:38:13 +0400 From: Gleb Smirnoff To: Julian Elischer Subject: Re: svn commit: r250700 - in head/sys: conf net netinet6 sys Message-ID: <20130517073813.GY17164@FreeBSD.org> References: <201305161620.r4GGKIFI012296@svn.freebsd.org> <20130517073721.GX17164@FreeBSD.org> MIME-Version: 1.0 Content-Type: text/plain; charset=koi8-r Content-Disposition: inline In-Reply-To: <20130517073721.GX17164@FreeBSD.org> User-Agent: Mutt/1.5.21 (2010-09-15) Cc: svn-src-head@freebsd.org, svn-src-all@freebsd.org, src-committers@freebsd.org X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 17 May 2013 07:38:15 -0000 Sorry, I am slowpoke. Everything had already been noticed by other reviewers. On Fri, May 17, 2013 at 11:37:21AM +0400, Gleb Smirnoff wrote: T> On Thu, May 16, 2013 at 04:20:18PM +0000, Julian Elischer wrote: T> J> Modified: head/sys/sys/mbuf.h T> J> ============================================================================== T> J> --- head/sys/sys/mbuf.h Thu May 16 15:28:38 2013 (r250699) T> J> +++ head/sys/sys/mbuf.h Thu May 16 16:20:17 2013 (r250700) T> J> @@ -129,6 +129,8 @@ struct pkthdr { T> J> u_int16_t vt_vtag; /* Ethernet 802.1p+q vlan tag */ T> J> u_int16_t vt_nrecs; /* # of IGMPv3 records in this chain */ T> J> } PH_vt; T> J> + u_int16_t fibnum; /* this packet should use this fib */ T> J> + u_int16_t pad2; /* align to 32 bits */ T> J> SLIST_HEAD(packet_tags, m_tag) tags; /* list of packet tags */ T> J> }; T> J> #define ether_vtag PH_vt.vt_vtag T> J> @@ -171,6 +173,7 @@ struct mbuf { T> J> #define m_type m_hdr.mh_type T> J> #define m_flags m_hdr.mh_flags T> J> #define m_nextpkt m_hdr.mh_nextpkt T> J> +#define m_fibnum m_hdr.mh_nextpkt T> J> #define m_act m_nextpkt T> J> #define m_pkthdr M_dat.MH.MH_pkthdr T> J> #define m_ext M_dat.MH.MH_dat.MH_ext T> T> The define definitely looks incorrect. T> T> J> +static int inline T> J> +rt_m_getfib(struct mbuf *m) T> J> +{ T> J> + KASSERT(m->m_flags & M_EXT , ("attempt to set FIB on non header mbuf")); T> J> + return (m->m_pkthdr.fibnum); T> J> +} T> T> The KASSERT looks incorrect. Text doesn't match the test. IMO, text is T> correct, but the test is not. T> T> J> #define M_SETFIB(_m, _fib) do { \ T> J> - _m->m_flags &= ~M_FIB; \ T> J> - _m->m_flags |= (((_fib) << M_FIBSHIFT) & M_FIB); \ T> J> + KASSERT((_m)->m_flags & M_EXT, ("No FIB on non header mbuf")); \ T> J> + ((_m)->m_pkthdr.fibnum) = (_fib); \ T> J> } while (0) T> T> Same for this KASSERT. T> T> IMO, any change to struct mbuf should be announced and posted for review T> prior to committing. T> T> -- T> Totus tuus, Glebius. -- Totus tuus, Glebius. From owner-svn-src-all@FreeBSD.ORG Fri May 17 08:48:17 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id B245F483; Fri, 17 May 2013 08:48:17 +0000 (UTC) (envelope-from des@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id A4919DEB; Fri, 17 May 2013 08:48:17 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.6/8.14.6) with ESMTP id r4H8mHjX061020; Fri, 17 May 2013 08:48:17 GMT (envelope-from des@svn.freebsd.org) Received: (from des@localhost) by svn.freebsd.org (8.14.6/8.14.5/Submit) id r4H8mHOb061018; Fri, 17 May 2013 08:48:17 GMT (envelope-from des@svn.freebsd.org) Message-Id: <201305170848.r4H8mHOb061018@svn.freebsd.org> From: Dag-Erling Smørgrav Date: Fri, 17 May 2013 08:48:17 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r250736 - head/usr.sbin/jls X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 17 May 2013 08:48:17 -0000 Author: des Date: Fri May 17 08:48:16 2013 New Revision: 250736 URL: http://svnweb.freebsd.org/changeset/base/250736 Log: Add a -N option that prints the jail name rather than its number. MFC after: 3 weeks Modified: head/usr.sbin/jls/jls.8 head/usr.sbin/jls/jls.c Modified: head/usr.sbin/jls/jls.8 ============================================================================== --- head/usr.sbin/jls/jls.8 Fri May 17 05:16:30 2013 (r250735) +++ head/usr.sbin/jls/jls.8 Fri May 17 08:48:16 2013 (r250736) @@ -25,7 +25,7 @@ .\" .\" $FreeBSD$ .\" -.Dd July 8, 2009 +.Dd July 20, 2012 .Dt JLS 8 .Os .Sh NAME @@ -33,7 +33,7 @@ .Nd "list jails" .Sh SYNOPSIS .Nm -.Op Fl dhnqsv +.Op Fl dhNnqsv .Op Fl j Ar jail .Op Ar parameter ... .Sh DESCRIPTION @@ -71,6 +71,10 @@ Print a header line containing the param If no parameters are given on the command line, .Va all is assumed. +.It Fl N +In the standard display mode, print each jail's name instead of its +numeric ID. +If the jail does not have a name, the numeric ID is printed instead. .It Fl n Print parameters in .Dq name=value Modified: head/usr.sbin/jls/jls.c ============================================================================== --- head/usr.sbin/jls/jls.c Fri May 17 05:16:30 2013 (r250735) +++ head/usr.sbin/jls/jls.c Fri May 17 08:48:16 2013 (r250736) @@ -55,6 +55,7 @@ __FBSDID("$FreeBSD$"); #define PRINT_QUOTED 0x08 #define PRINT_SKIP 0x10 #define PRINT_VERBOSE 0x20 +#define PRINT_JAIL_NAME 0x40 static struct jailparam *params; static int *param_parent; @@ -82,7 +83,7 @@ main(int argc, char **argv) jname = NULL; pflags = jflags = jid = 0; - while ((c = getopt(argc, argv, "adj:hnqsv")) >= 0) + while ((c = getopt(argc, argv, "adj:hNnqsv")) >= 0) switch (c) { case 'a': case 'd': @@ -99,6 +100,9 @@ main(int argc, char **argv) pflags = (pflags & ~(PRINT_SKIP | PRINT_VERBOSE)) | PRINT_HEADER; break; + case 'N': + pflags |= PRINT_JAIL_NAME; + break; case 'n': pflags = (pflags & ~PRINT_VERBOSE) | PRINT_NAMEVAL; break; @@ -115,7 +119,7 @@ main(int argc, char **argv) PRINT_VERBOSE; break; default: - errx(1, "usage: jls [-dhnqv] [-j jail] [param ...]"); + errx(1, "usage: jls [-dhNnqv] [-j jail] [param ...]"); } #ifdef INET6 @@ -149,7 +153,10 @@ main(int argc, char **argv) #endif } else { pflags |= PRINT_DEFAULT; - add_param("jid", NULL, (size_t)0, NULL, JP_USER); + if (pflags & PRINT_JAIL_NAME) + add_param("name", NULL, (size_t)0, NULL, JP_USER); + else + add_param("jid", NULL, (size_t)0, NULL, JP_USER); #ifdef INET if (ip4_ok) add_param("ip4.addr", NULL, (size_t)0, NULL, @@ -192,8 +199,12 @@ main(int argc, char **argv) " CPUSetID\n" " IP Address(es)\n"); else if (pflags & PRINT_DEFAULT) - printf(" JID IP Address " - "Hostname Path\n"); + if (pflags & PRINT_JAIL_NAME) + printf(" JID IP Address " + "Hostname Path\n"); + else + printf(" JID IP Address " + "Hostname Path\n"); else if (pflags & PRINT_HEADER) { for (i = spc = 0; i < nparams; i++) if (params[i].jp_flags & JP_USER) { @@ -397,9 +408,12 @@ print_jail(int pflags, int jflags) n++; } #endif - } else if (pflags & PRINT_DEFAULT) - printf("%6d %-15.15s %-29.29s %.74s\n", - *(int *)params[0].jp_value, + } else if (pflags & PRINT_DEFAULT) { + if (pflags & PRINT_JAIL_NAME) + printf(" %-15s ", (char *)params[0].jp_value); + else + printf("%6d ", *(int *)params[0].jp_value); + printf("%-15.15s %-29.29s %.74s\n", #ifdef INET (!ip4_ok || params[1].jp_valuelen == 0) ? "-" : inet_ntoa(*(struct in_addr *)params[1].jp_value), @@ -410,7 +424,7 @@ print_jail(int pflags, int jflags) (char *)params[1].jp_value, (char *)params[2].jp_value); #endif - else { + } else { param_values = alloca(nparams * sizeof(*param_values)); for (i = 0; i < nparams; i++) { if (!(params[i].jp_flags & JP_USER)) From owner-svn-src-all@FreeBSD.ORG Fri May 17 08:55:29 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id 1789B79D; Fri, 17 May 2013 08:55:29 +0000 (UTC) (envelope-from des@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id 087DBE2A; Fri, 17 May 2013 08:55:29 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.6/8.14.6) with ESMTP id r4H8tSEC063927; Fri, 17 May 2013 08:55:28 GMT (envelope-from des@svn.freebsd.org) Received: (from des@localhost) by svn.freebsd.org (8.14.6/8.14.5/Submit) id r4H8tQj4063908; Fri, 17 May 2013 08:55:26 GMT (envelope-from des@svn.freebsd.org) Message-Id: <201305170855.r4H8tQj4063908@svn.freebsd.org> From: Dag-Erling Smørgrav Date: Fri, 17 May 2013 08:55:26 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-vendor@freebsd.org Subject: svn commit: r250737 - in vendor-crypto/openssh/dist: . contrib contrib/caldera contrib/redhat contrib/suse openbsd-compat X-SVN-Group: vendor-crypto MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 17 May 2013 08:55:29 -0000 Author: des Date: Fri May 17 08:55:26 2013 New Revision: 250737 URL: http://svnweb.freebsd.org/changeset/base/250737 Log: Vendor import of OpenSSH 6.2p2. Modified: vendor-crypto/openssh/dist/ChangeLog vendor-crypto/openssh/dist/README vendor-crypto/openssh/dist/contrib/caldera/openssh.spec vendor-crypto/openssh/dist/contrib/redhat/openssh.spec vendor-crypto/openssh/dist/contrib/ssh-copy-id vendor-crypto/openssh/dist/contrib/suse/openssh.spec vendor-crypto/openssh/dist/krl.c vendor-crypto/openssh/dist/openbsd-compat/bsd-cygwin_util.c vendor-crypto/openssh/dist/openbsd-compat/bsd-cygwin_util.h vendor-crypto/openssh/dist/packet.c vendor-crypto/openssh/dist/sshconnect.c vendor-crypto/openssh/dist/version.h Modified: vendor-crypto/openssh/dist/ChangeLog ============================================================================== --- vendor-crypto/openssh/dist/ChangeLog Fri May 17 08:48:16 2013 (r250736) +++ vendor-crypto/openssh/dist/ChangeLog Fri May 17 08:55:26 2013 (r250737) @@ -1,3 +1,45 @@ +20130516 + - (djm) [contrib/ssh-copy-id] Fix bug that could cause "rm *" to be + executed if mktemp failed; bz#2105 ok dtucker@ + - (djm) Release 6.2p2 + +20130510 + - (djm) OpenBSD CVS Cherrypick + - djm@cvs.openbsd.org 2013/04/11 02:27:50 + [packet.c] + quiet disconnect notifications on the server from error() back to logit() + if it is a normal client closure; bz#2057 ok+feedback dtucker@ + - (djm) [version.h contrib/caldera/openssh.spec contrib/redhat/openssh.spec] + [contrib/suse/openssh.spec] Crank version numbers for release. + - (djm) [README] Update release notes URL + +20130404 + - (dtucker) OpenBSD CVS Sync + - dtucker@cvs.openbsd.org 2013/02/17 23:16:57 + [readconf.c ssh.c readconf.h sshconnect2.c] + Keep track of which IndentityFile options were manually supplied and which + were default options, and don't warn if the latter are missing. + ok markus@ + - dtucker@cvs.openbsd.org 2013/02/19 02:12:47 + [krl.c] + Remove bogus include. ok djm + - dtucker@cvs.openbsd.org 2013/02/22 04:45:09 + [ssh.c readconf.c readconf.h] + Don't complain if IdentityFiles specified in system-wide configs are + missing. ok djm, deraadt. + - markus@cvs.openbsd.org 2013/02/22 19:13:56 + [sshconnect.c] + support ProxyCommand=- (stdin/out already point to the proxy); ok djm@ + - djm@cvs.openbsd.org 2013/02/22 22:09:01 + [ssh.c] + Allow IdenityFile=none; ok markus deraadt (and dtucker for an earlier + version) + +20130401 + - (dtucker) [openbsd-compat/bsd-cygwin_util.{c,h}] Don't include windows.h + to avoid conflicting definitions of __int64, adding the required bits. + Patch from Corinna Vinschen. + 20120322 - (djm) [contrib/ssh-copy-id contrib/ssh-copy-id.1] Updated to Phil Hands' greatly revised version. Modified: vendor-crypto/openssh/dist/README ============================================================================== --- vendor-crypto/openssh/dist/README Fri May 17 08:48:16 2013 (r250736) +++ vendor-crypto/openssh/dist/README Fri May 17 08:55:26 2013 (r250737) @@ -1,4 +1,4 @@ -See http://www.openssh.com/txt/release-6.2 for the release notes. +See http://www.openssh.com/txt/release-6.2p2 for the release notes. - A Japanese translation of this document and of the OpenSSH FAQ is - available at http://www.unixuser.org/~haruyama/security/openssh/index.html @@ -62,4 +62,4 @@ References - [6] http://www.openbsd.org/cgi-bin/man.cgi?query=style&sektion=9 [7] http://www.openssh.com/faq.html -$Id: README,v 1.82 2013/02/26 23:48:19 djm Exp $ +$Id: README,v 1.82.2.1 2013/05/10 06:12:54 djm Exp $ Modified: vendor-crypto/openssh/dist/contrib/caldera/openssh.spec ============================================================================== --- vendor-crypto/openssh/dist/contrib/caldera/openssh.spec Fri May 17 08:48:16 2013 (r250736) +++ vendor-crypto/openssh/dist/contrib/caldera/openssh.spec Fri May 17 08:55:26 2013 (r250737) @@ -16,7 +16,7 @@ #old cvs stuff. please update before use. may be deprecated. %define use_stable 1 -%define version 6.2p1 +%define version 6.2p2 %if %{use_stable} %define cvs %{nil} %define release 1 @@ -363,4 +363,4 @@ fi * Mon Jan 01 1998 ... Template Version: 1.31 -$Id: openssh.spec,v 1.79 2013/02/26 23:48:20 djm Exp $ +$Id: openssh.spec,v 1.79.2.1 2013/05/10 06:02:21 djm Exp $ Modified: vendor-crypto/openssh/dist/contrib/redhat/openssh.spec ============================================================================== --- vendor-crypto/openssh/dist/contrib/redhat/openssh.spec Fri May 17 08:48:16 2013 (r250736) +++ vendor-crypto/openssh/dist/contrib/redhat/openssh.spec Fri May 17 08:55:26 2013 (r250737) @@ -1,4 +1,4 @@ -%define ver 6.2p1 +%define ver 6.2p2 %define rel 1 # OpenSSH privilege separation requires a user & group ID Modified: vendor-crypto/openssh/dist/contrib/ssh-copy-id ============================================================================== --- vendor-crypto/openssh/dist/contrib/ssh-copy-id Fri May 17 08:48:16 2013 (r250736) +++ vendor-crypto/openssh/dist/contrib/ssh-copy-id Fri May 17 08:55:26 2013 (r250737) @@ -165,6 +165,9 @@ done eval set -- "$SAVEARGS" +if [ $# == 0 ] ; then + usage +fi if [ $# != 1 ] ; then printf '%s: ERROR: Too many arguments. Expecting a target hostname, got: %s\n\n' "$0" "$SAVEARGS" >&2 usage @@ -196,7 +199,11 @@ populate_new_ids() { umask 0177 local L_TMP_ID_FILE=$(mktemp ~/.ssh/ssh-copy-id_id.XXXXXXXXXX) - trap "rm -f $L_TMP_ID_FILE*" EXIT TERM INT QUIT + if test $? -ne 0 || test "x$L_TMP_ID_FILE" = "x" ; then + echo "mktemp failed" 1>&2 + exit 1 + fi + trap "rm -f $L_TMP_ID_FILE ${L_TMP_ID_FILE}.pub" EXIT TERM INT QUIT printf '%s: INFO: attempting to log in with the new key(s), to filter out any that are already installed\n' "$0" >&2 NEW_IDS=$( eval $GET_ID | { Modified: vendor-crypto/openssh/dist/contrib/suse/openssh.spec ============================================================================== --- vendor-crypto/openssh/dist/contrib/suse/openssh.spec Fri May 17 08:48:16 2013 (r250736) +++ vendor-crypto/openssh/dist/contrib/suse/openssh.spec Fri May 17 08:55:26 2013 (r250737) @@ -13,7 +13,7 @@ Summary: OpenSSH, a free Secure Shell (SSH) protocol implementation Name: openssh -Version: 6.2p1 +Version: 6.2p2 URL: http://www.openssh.com/ Release: 1 Source0: openssh-%{version}.tar.gz Modified: vendor-crypto/openssh/dist/krl.c ============================================================================== --- vendor-crypto/openssh/dist/krl.c Fri May 17 08:48:16 2013 (r250736) +++ vendor-crypto/openssh/dist/krl.c Fri May 17 08:55:26 2013 (r250737) @@ -14,7 +14,7 @@ * OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. */ -/* $OpenBSD: krl.c,v 1.9 2013/01/27 10:06:12 djm Exp $ */ +/* $OpenBSD: krl.c,v 1.10 2013/02/19 02:12:47 dtucker Exp $ */ #include "includes.h" Modified: vendor-crypto/openssh/dist/openbsd-compat/bsd-cygwin_util.c ============================================================================== --- vendor-crypto/openssh/dist/openbsd-compat/bsd-cygwin_util.c Fri May 17 08:48:16 2013 (r250736) +++ vendor-crypto/openssh/dist/openbsd-compat/bsd-cygwin_util.c Fri May 17 08:55:26 2013 (r250737) @@ -1,5 +1,5 @@ /* - * Copyright (c) 2000, 2001, 2011 Corinna Vinschen + * Copyright (c) 2000, 2001, 2011, 2013 Corinna Vinschen * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions @@ -27,20 +27,15 @@ * binary mode on Windows systems. */ +#define NO_BINARY_OPEN /* Avoid redefining open to binary_open for this file */ #include "includes.h" #ifdef HAVE_CYGWIN -#if defined(open) && open == binary_open -# undef open -#endif - #include - #include -#include +#include #include -#include #include "xmalloc.h" Modified: vendor-crypto/openssh/dist/openbsd-compat/bsd-cygwin_util.h ============================================================================== --- vendor-crypto/openssh/dist/openbsd-compat/bsd-cygwin_util.h Fri May 17 08:48:16 2013 (r250736) +++ vendor-crypto/openssh/dist/openbsd-compat/bsd-cygwin_util.h Fri May 17 08:55:26 2013 (r250737) @@ -1,7 +1,7 @@ -/* $Id: bsd-cygwin_util.h,v 1.15 2012/08/28 09:57:19 dtucker Exp $ */ +/* $Id: bsd-cygwin_util.h,v 1.15.4.1 2013/04/04 23:53:31 dtucker Exp $ */ /* - * Copyright (c) 2000, 2001, 2011 Corinna Vinschen + * Copyright (c) 2000, 2001, 2011, 2013 Corinna Vinschen * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions @@ -36,24 +36,21 @@ #undef ERROR -#define WIN32_LEAN_AND_MEAN +/* Avoid including windows headers. */ +typedef void *HANDLE; +#define INVALID_HANDLE_VALUE ((HANDLE) -1) -#include #include #include -/* Make sure _WIN32 isn't defined later in the code, otherwise headers from - other packages might get the wrong idea about the target system. */ -#ifdef _WIN32 -#undef _WIN32 -#endif - int binary_open(const char *, int , ...); int check_ntsec(const char *); char **fetch_windows_environment(void); void free_windows_environment(char **); +#ifndef NO_BINARY_OPEN #define open binary_open +#endif #endif /* HAVE_CYGWIN */ Modified: vendor-crypto/openssh/dist/packet.c ============================================================================== --- vendor-crypto/openssh/dist/packet.c Fri May 17 08:48:16 2013 (r250736) +++ vendor-crypto/openssh/dist/packet.c Fri May 17 08:55:26 2013 (r250737) @@ -1,4 +1,4 @@ -/* $OpenBSD: packet.c,v 1.181 2013/02/10 23:35:24 djm Exp $ */ +/* $OpenBSD: packet.c,v 1.182 2013/04/11 02:27:50 djm Exp $ */ /* * Author: Tatu Ylonen * Copyright (c) 1995 Tatu Ylonen , Espoo, Finland @@ -1463,7 +1463,7 @@ packet_read_poll_seqnr(u_int32_t *seqnr_ /* Ignore normal client exit notifications */ do_log2(active_state->server_side && reason == SSH2_DISCONNECT_BY_APPLICATION ? - SYSLOG_LEVEL_DEBUG1 : SYSLOG_LEVEL_ERROR, + SYSLOG_LEVEL_INFO : SYSLOG_LEVEL_ERROR, "Received disconnect from %s: %u: %.400s", get_remote_ipaddr(), reason, msg); xfree(msg); Modified: vendor-crypto/openssh/dist/sshconnect.c ============================================================================== --- vendor-crypto/openssh/dist/sshconnect.c Fri May 17 08:48:16 2013 (r250736) +++ vendor-crypto/openssh/dist/sshconnect.c Fri May 17 08:55:26 2013 (r250737) @@ -1,4 +1,4 @@ -/* $OpenBSD: sshconnect.c,v 1.236 2012/09/14 16:51:34 markus Exp $ */ +/* $OpenBSD: sshconnect.c,v 1.237 2013/02/22 19:13:56 markus Exp $ */ /* * Author: Tatu Ylonen * Copyright (c) 1995 Tatu Ylonen , Espoo, Finland @@ -89,6 +89,13 @@ ssh_proxy_connect(const char *host, u_sh pid_t pid; char *shell, strport[NI_MAXSERV]; + if (!strcmp(proxy_command, "-")) { + packet_set_connection(STDIN_FILENO, STDOUT_FILENO); + packet_set_timeout(options.server_alive_interval, + options.server_alive_count_max); + return 0; + } + if ((shell = getenv("SHELL")) == NULL || *shell == '\0') shell = _PATH_BSHELL; Modified: vendor-crypto/openssh/dist/version.h ============================================================================== --- vendor-crypto/openssh/dist/version.h Fri May 17 08:48:16 2013 (r250736) +++ vendor-crypto/openssh/dist/version.h Fri May 17 08:55:26 2013 (r250737) @@ -2,5 +2,5 @@ #define SSH_VERSION "OpenSSH_6.2" -#define SSH_PORTABLE "p1" +#define SSH_PORTABLE "p2" #define SSH_RELEASE SSH_VERSION SSH_PORTABLE From owner-svn-src-all@FreeBSD.ORG Fri May 17 08:57:10 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id 1ADC3907; Fri, 17 May 2013 08:57:10 +0000 (UTC) (envelope-from des@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id E694DE36; Fri, 17 May 2013 08:57:09 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.6/8.14.6) with ESMTP id r4H8v99N064249; Fri, 17 May 2013 08:57:09 GMT (envelope-from des@svn.freebsd.org) Received: (from des@localhost) by svn.freebsd.org (8.14.6/8.14.5/Submit) id r4H8v9pk064248; Fri, 17 May 2013 08:57:09 GMT (envelope-from des@svn.freebsd.org) Message-Id: <201305170857.r4H8v9pk064248@svn.freebsd.org> From: Dag-Erling Smørgrav Date: Fri, 17 May 2013 08:57:09 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-vendor@freebsd.org Subject: svn commit: r250738 - vendor-crypto/openssh/6.2p2 X-SVN-Group: vendor-crypto MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 17 May 2013 08:57:10 -0000 Author: des Date: Fri May 17 08:57:09 2013 New Revision: 250738 URL: http://svnweb.freebsd.org/changeset/base/250738 Log: Tag OpenSSH 6.2p2 Added: vendor-crypto/openssh/6.2p2/ - copied from r250737, vendor-crypto/openssh/dist/ From owner-svn-src-all@FreeBSD.ORG Fri May 17 09:12:36 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id 37099C9F; Fri, 17 May 2013 09:12:36 +0000 (UTC) (envelope-from des@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id 18E7EEE1; Fri, 17 May 2013 09:12:36 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.6/8.14.6) with ESMTP id r4H9CZII070771; Fri, 17 May 2013 09:12:35 GMT (envelope-from des@svn.freebsd.org) Received: (from des@localhost) by svn.freebsd.org (8.14.6/8.14.5/Submit) id r4H9CXfk070751; Fri, 17 May 2013 09:12:33 GMT (envelope-from des@svn.freebsd.org) Message-Id: <201305170912.r4H9CXfk070751@svn.freebsd.org> From: Dag-Erling Smørgrav Date: Fri, 17 May 2013 09:12:33 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r250739 - in head/crypto/openssh: . openbsd-compat X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 17 May 2013 09:12:36 -0000 Author: des Date: Fri May 17 09:12:33 2013 New Revision: 250739 URL: http://svnweb.freebsd.org/changeset/base/250739 Log: Upgrade to OpenSSH 6.2p2. Mostly a no-op since I had already patched the issues that affected us. Modified: head/crypto/openssh/ChangeLog head/crypto/openssh/README head/crypto/openssh/krl.c head/crypto/openssh/openbsd-compat/bsd-cygwin_util.c head/crypto/openssh/openbsd-compat/bsd-cygwin_util.h head/crypto/openssh/packet.c head/crypto/openssh/ssh_config head/crypto/openssh/ssh_config.5 head/crypto/openssh/sshconnect.c head/crypto/openssh/sshd_config head/crypto/openssh/sshd_config.5 head/crypto/openssh/version.h Directory Properties: head/crypto/openssh/ (props changed) Modified: head/crypto/openssh/ChangeLog ============================================================================== --- head/crypto/openssh/ChangeLog Fri May 17 08:57:09 2013 (r250738) +++ head/crypto/openssh/ChangeLog Fri May 17 09:12:33 2013 (r250739) @@ -1,3 +1,39 @@ +20130510 + - (djm) OpenBSD CVS Cherrypick + - djm@cvs.openbsd.org 2013/04/11 02:27:50 + [packet.c] + quiet disconnect notifications on the server from error() back to logit() + if it is a normal client closure; bz#2057 ok+feedback dtucker@ + - (djm) [version.h contrib/caldera/openssh.spec contrib/redhat/openssh.spec] + [contrib/suse/openssh.spec] Crank version numbers for release. + +20130404 + - (dtucker) OpenBSD CVS Sync + - dtucker@cvs.openbsd.org 2013/02/17 23:16:57 + [readconf.c ssh.c readconf.h sshconnect2.c] + Keep track of which IndentityFile options were manually supplied and which + were default options, and don't warn if the latter are missing. + ok markus@ + - dtucker@cvs.openbsd.org 2013/02/19 02:12:47 + [krl.c] + Remove bogus include. ok djm + - dtucker@cvs.openbsd.org 2013/02/22 04:45:09 + [ssh.c readconf.c readconf.h] + Don't complain if IdentityFiles specified in system-wide configs are + missing. ok djm, deraadt. + - markus@cvs.openbsd.org 2013/02/22 19:13:56 + [sshconnect.c] + support ProxyCommand=- (stdin/out already point to the proxy); ok djm@ + - djm@cvs.openbsd.org 2013/02/22 22:09:01 + [ssh.c] + Allow IdenityFile=none; ok markus deraadt (and dtucker for an earlier + version) + +20130401 + - (dtucker) [openbsd-compat/bsd-cygwin_util.{c,h}] Don't include windows.h + to avoid conflicting definitions of __int64, adding the required bits. + Patch from Corinna Vinschen. + 20120322 - (djm) [contrib/ssh-copy-id contrib/ssh-copy-id.1] Updated to Phil Hands' greatly revised version. Modified: head/crypto/openssh/README ============================================================================== --- head/crypto/openssh/README Fri May 17 08:57:09 2013 (r250738) +++ head/crypto/openssh/README Fri May 17 09:12:33 2013 (r250739) @@ -1,4 +1,4 @@ -See http://www.openssh.com/txt/release-6.2 for the release notes. +See http://www.openssh.com/txt/release-6.2p2 for the release notes. - A Japanese translation of this document and of the OpenSSH FAQ is - available at http://www.unixuser.org/~haruyama/security/openssh/index.html @@ -62,4 +62,4 @@ References - [6] http://www.openbsd.org/cgi-bin/man.cgi?query=style&sektion=9 [7] http://www.openssh.com/faq.html -$Id: README,v 1.82 2013/02/26 23:48:19 djm Exp $ +$Id: README,v 1.82.2.1 2013/05/10 06:12:54 djm Exp $ Modified: head/crypto/openssh/krl.c ============================================================================== --- head/crypto/openssh/krl.c Fri May 17 08:57:09 2013 (r250738) +++ head/crypto/openssh/krl.c Fri May 17 09:12:33 2013 (r250739) @@ -14,7 +14,7 @@ * OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. */ -/* $OpenBSD: krl.c,v 1.9 2013/01/27 10:06:12 djm Exp $ */ +/* $OpenBSD: krl.c,v 1.10 2013/02/19 02:12:47 dtucker Exp $ */ #include "includes.h" Modified: head/crypto/openssh/openbsd-compat/bsd-cygwin_util.c ============================================================================== --- head/crypto/openssh/openbsd-compat/bsd-cygwin_util.c Fri May 17 08:57:09 2013 (r250738) +++ head/crypto/openssh/openbsd-compat/bsd-cygwin_util.c Fri May 17 09:12:33 2013 (r250739) @@ -1,5 +1,5 @@ /* - * Copyright (c) 2000, 2001, 2011 Corinna Vinschen + * Copyright (c) 2000, 2001, 2011, 2013 Corinna Vinschen * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions @@ -27,20 +27,15 @@ * binary mode on Windows systems. */ +#define NO_BINARY_OPEN /* Avoid redefining open to binary_open for this file */ #include "includes.h" #ifdef HAVE_CYGWIN -#if defined(open) && open == binary_open -# undef open -#endif - #include - #include -#include +#include #include -#include #include "xmalloc.h" Modified: head/crypto/openssh/openbsd-compat/bsd-cygwin_util.h ============================================================================== --- head/crypto/openssh/openbsd-compat/bsd-cygwin_util.h Fri May 17 08:57:09 2013 (r250738) +++ head/crypto/openssh/openbsd-compat/bsd-cygwin_util.h Fri May 17 09:12:33 2013 (r250739) @@ -1,7 +1,7 @@ -/* $Id: bsd-cygwin_util.h,v 1.15 2012/08/28 09:57:19 dtucker Exp $ */ +/* $Id: bsd-cygwin_util.h,v 1.15.4.1 2013/04/04 23:53:31 dtucker Exp $ */ /* - * Copyright (c) 2000, 2001, 2011 Corinna Vinschen + * Copyright (c) 2000, 2001, 2011, 2013 Corinna Vinschen * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions @@ -36,24 +36,21 @@ #undef ERROR -#define WIN32_LEAN_AND_MEAN +/* Avoid including windows headers. */ +typedef void *HANDLE; +#define INVALID_HANDLE_VALUE ((HANDLE) -1) -#include #include #include -/* Make sure _WIN32 isn't defined later in the code, otherwise headers from - other packages might get the wrong idea about the target system. */ -#ifdef _WIN32 -#undef _WIN32 -#endif - int binary_open(const char *, int , ...); int check_ntsec(const char *); char **fetch_windows_environment(void); void free_windows_environment(char **); +#ifndef NO_BINARY_OPEN #define open binary_open +#endif #endif /* HAVE_CYGWIN */ Modified: head/crypto/openssh/packet.c ============================================================================== --- head/crypto/openssh/packet.c Fri May 17 08:57:09 2013 (r250738) +++ head/crypto/openssh/packet.c Fri May 17 09:12:33 2013 (r250739) @@ -1,5 +1,5 @@ /* $OpenBSD: packet.c,v 1.181 2013/02/10 23:35:24 djm Exp $ */ -/* $FreeBSD$ */ +/* $OpenBSD: packet.c,v 1.182 2013/04/11 02:27:50 djm Exp $ */ /* * Author: Tatu Ylonen * Copyright (c) 1995 Tatu Ylonen , Espoo, Finland @@ -1468,7 +1468,7 @@ packet_read_poll_seqnr(u_int32_t *seqnr_ /* Ignore normal client exit notifications */ do_log2(active_state->server_side && reason == SSH2_DISCONNECT_BY_APPLICATION ? - SYSLOG_LEVEL_DEBUG1 : SYSLOG_LEVEL_ERROR, + SYSLOG_LEVEL_INFO : SYSLOG_LEVEL_ERROR, "Received disconnect from %s: %u: %.400s", get_remote_ipaddr(), reason, msg); xfree(msg); Modified: head/crypto/openssh/ssh_config ============================================================================== --- head/crypto/openssh/ssh_config Fri May 17 08:57:09 2013 (r250738) +++ head/crypto/openssh/ssh_config Fri May 17 09:12:33 2013 (r250739) @@ -46,4 +46,4 @@ # PermitLocalCommand no # VisualHostKey no # ProxyCommand ssh -q -W %h:%p gateway.example.com -# VersionAddendum FreeBSD-20130322 +# VersionAddendum FreeBSD-20130515 Modified: head/crypto/openssh/ssh_config.5 ============================================================================== --- head/crypto/openssh/ssh_config.5 Fri May 17 08:57:09 2013 (r250738) +++ head/crypto/openssh/ssh_config.5 Fri May 17 09:12:33 2013 (r250739) @@ -1230,7 +1230,7 @@ in Specifies a string to append to the regular version string to identify OS- or site-specific modifications. The default is -.Dq FreeBSD-20130322 . +.Dq FreeBSD-20130515 . .It Cm VisualHostKey If this flag is set to .Dq yes , Modified: head/crypto/openssh/sshconnect.c ============================================================================== --- head/crypto/openssh/sshconnect.c Fri May 17 08:57:09 2013 (r250738) +++ head/crypto/openssh/sshconnect.c Fri May 17 09:12:33 2013 (r250739) @@ -1,5 +1,5 @@ /* $OpenBSD: sshconnect.c,v 1.236 2012/09/14 16:51:34 markus Exp $ */ -/* $FreeBSD$ */ +/* $OpenBSD: sshconnect.c,v 1.237 2013/02/22 19:13:56 markus Exp $ */ /* * Author: Tatu Ylonen * Copyright (c) 1995 Tatu Ylonen , Espoo, Finland @@ -90,6 +90,13 @@ ssh_proxy_connect(const char *host, u_sh pid_t pid; char *shell, strport[NI_MAXSERV]; + if (!strcmp(proxy_command, "-")) { + packet_set_connection(STDIN_FILENO, STDOUT_FILENO); + packet_set_timeout(options.server_alive_interval, + options.server_alive_count_max); + return 0; + } + if ((shell = getenv("SHELL")) == NULL || *shell == '\0') shell = _PATH_BSHELL; Modified: head/crypto/openssh/sshd_config ============================================================================== --- head/crypto/openssh/sshd_config Fri May 17 08:57:09 2013 (r250738) +++ head/crypto/openssh/sshd_config Fri May 17 09:12:33 2013 (r250739) @@ -115,7 +115,7 @@ #MaxStartups 10:30:100 #PermitTunnel no #ChrootDirectory none -#VersionAddendum FreeBSD-20130322 +#VersionAddendum FreeBSD-20130515 # no default banner path #Banner none Modified: head/crypto/openssh/sshd_config.5 ============================================================================== --- head/crypto/openssh/sshd_config.5 Fri May 17 08:57:09 2013 (r250738) +++ head/crypto/openssh/sshd_config.5 Fri May 17 09:12:33 2013 (r250739) @@ -1180,7 +1180,7 @@ restrictions. Optionally specifies additional text to append to the SSH protocol banner sent by the server upon connection. The default is -.Dq FreeBSD-20130322 . +.Dq FreeBSD-20130515 . .It Cm X11DisplayOffset Specifies the first display number available for .Xr sshd 8 Ns 's Modified: head/crypto/openssh/version.h ============================================================================== --- head/crypto/openssh/version.h Fri May 17 08:57:09 2013 (r250738) +++ head/crypto/openssh/version.h Fri May 17 09:12:33 2013 (r250739) @@ -3,8 +3,8 @@ #define SSH_VERSION "OpenSSH_6.2" -#define SSH_PORTABLE "p1" +#define SSH_PORTABLE "p2" #define SSH_RELEASE SSH_VERSION SSH_PORTABLE -#define SSH_VERSION_FREEBSD "FreeBSD-20130322" +#define SSH_VERSION_FREEBSD "FreeBSD-20130515" #define SSH_VERSION_HPN "_hpn13v11" From owner-svn-src-all@FreeBSD.ORG Fri May 17 12:45:47 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id 88A5D86C for ; Fri, 17 May 2013 12:45:47 +0000 (UTC) (envelope-from tim@kientzle.com) Received: from mail-ie0-x230.google.com (mail-ie0-x230.google.com [IPv6:2607:f8b0:4001:c03::230]) by mx1.freebsd.org (Postfix) with ESMTP id 566C9A54 for ; Fri, 17 May 2013 12:45:47 +0000 (UTC) Received: by mail-ie0-f176.google.com with SMTP id at1so9062920iec.21 for ; Fri, 17 May 2013 05:45:47 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20120113; h=x-received:sender:subject:mime-version:content-type:from :in-reply-to:date:cc:content-transfer-encoding:message-id:references :to:x-mailer:x-gm-message-state; bh=QbUB8QyG/khgVE+y5jjB5uApVz0IkcEpjrgvyXr/XOg=; b=K88BpPoOIqIlIrIGfS18QOETzL2t4FInfIn4DMfcPyusr9tj+HIrzdhsGmj7XpAIdb kzscZQbP60RmF1xCMw5qudnfzYJRM7mcqQwyhgDq/F8vikdIL36Qrx9EasI3YmYN9AFg n3PAdfkkujNXKozkA6/U4iWk2h/QjPcV5T9obEOVKWeyuoUX1mbDdabwuXnqEStncGfX tVEAnNpGTy7UpYpkN1F5uATMJ8NtJwT00A2nGBpu2j4b3lgZNtyPdV/Am6oDC9qv+qmj MeHw/PEqYNqLLHxEQI2gMJxJ7/AG7TACkUZxaFuUsNGRBJjQU+x/cdQpfAdGuQ6jC7eK K8qg== X-Received: by 10.50.11.229 with SMTP id t5mr12750658igb.65.1368794746763; Fri, 17 May 2013 05:45:46 -0700 (PDT) Received: from [172.24.137.243] ([137.122.64.8]) by mx.google.com with ESMTPSA id o10sm9403977igh.2.2013.05.17.05.45.45 for (version=TLSv1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Fri, 17 May 2013 05:45:46 -0700 (PDT) Sender: Tim Kientzle Subject: Re: svn commit: r250692 - head/sys/arm/conf Mime-Version: 1.0 (Apple Message framework v1283) Content-Type: text/plain; charset=windows-1252 From: Tim Kientzle In-Reply-To: Date: Fri, 17 May 2013 08:45:44 -0400 Content-Transfer-Encoding: quoted-printable Message-Id: <6C1AD894-149B-4E08-90DB-2BC3899A4CE8@FreeBSD.org> References: <201305160351.r4G3p0uu047404@svn.freebsd.org> <30BAC0E1-9E8F-4FA4-A31E-C2AFAFDBCB95@freebsd.org> To: Rui Paulo X-Mailer: Apple Mail (2.1283) X-Gm-Message-State: ALoCoQmZZPggcjGu5im2YrpoTbmQaFaVI8KSBZKcTRMiijpYfrUoeYAHhwRbj/1FGoHMlxV7/24q Cc: svn-src-head@FreeBSD.org, svn-src-all@FreeBSD.org, src-committers@FreeBSD.org X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 17 May 2013 12:45:47 -0000 On May 16, 2013, at 9:49 PM, Rui Paulo wrote: > On 2013/05/16, at 2:02, Tim Kientzle wrote: >=20 >> I don't object, but I'm not sure why we need this. >>=20 >> I'd rather see a comment in the BEAGLEBONE >> config indicating that it can be used with >> beaglebone-black.dts. >>=20 >> Generally, I want us to move away from compiled-in >> DTBs. The BEAGLEBONE config works just fine on either >> one and it's what I plan to continue using going forward. >>=20 >> Part of the boot loader's job is to load the correct DTB. >> The images built by Crochet today already do this >> and produce images that boot on either old or new >> BeagleBone using the BEAGLEBONE config. >>=20 >> U-Boot already has logic to detect the board, >> load the correct DTB, and the same BEAGLEBONE >> kernel then runs just fine. Here are the U-Boot >> patches if you'd like to do this as well: >>=20 >> = https://github.com/kientzle/crochet-freebsd/tree/master/board/BeagleBone/f= iles >>=20 >> (There's also a copy of the compiled U-Boot and >> associated files at: >>=20 >> = http://people.freebsd.org/~kientzle/beaglebone-and-black-bootfiles.tgz >>=20 >> Moving forward, I'd like to see us generally consolidate ARM >> kernel configurations. I have some (still very experimental) >> ideas for combining the RPi and BeagleBone kernels >> into a single kernel, but with my limited time, that will >> be a fairly long-term project. If anyone's at BSDCan >> who would like to talk about it=85. I'll be at the >> "Beyond BuildWorld" session on Thursday=85. ;-) >>=20 >> Yes, this is certainly useful for people net booting >> the BeagleBone Black for developing kernel drivers, >> but I'm not sure why we would bother having it >> checked-in. >=20 >=20 > I understand your point, but what about drivers that only apply to the = BeagleBone Black, such as a driver for HDMI? Wouldn't that require a = separate kernel config file or are we expecting to use only kernel = modules? Such a driver should be in the BeagleBone kernel config but will only get turned on (by the FDT) on appropriate boards. Yes, people who need small kernels for various reasons will definitely need to hand-tune their kernel configs to leave out drivers they don't want (such as an HDMI driver on a BeagleBone white). But that doesn't mean we need separate kernel configs in the tree for every possible combination of hardware. That's what FDT is for. The proliferation of kernel configs is getting to be a headache. * "make universe" has to build all kernels, so we're better off with fewer bulkier kernel configs. * To more rapidly support new systems, we want to be able to mix-and-match existing drivers. Right now, drivers originally developed for different SoCs don't even compile together, so we can't effectively leverage existing code. There's a *lot* of cut-and-paste copying of code in our ARM tree right now. I have some ideas about how to unify some of the ARMv6 kernels and I'm hoping to start gradually working on that over the next few months. Ideally, I'd like to have a handful of "GENERIC" kernel configs in the tree, each supporting a range of SoCs. This will give us confidence that large sets of drivers do all compile and play reasonably well together. It will also make it feasible for people working on generic driver infrastructure to get some real traction on things like generic irq routing and pinmux support. (Brooks has some interesting ideas about IRQ routing and Warner has talked about better ways to do pinmux mapping.) It's easy for folks to trim configs if they need to do so for particular applications. Tim From owner-svn-src-all@FreeBSD.ORG Fri May 17 14:04:32 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id 10B30E68; Fri, 17 May 2013 14:04:32 +0000 (UTC) (envelope-from kib@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id 036B2E81; Fri, 17 May 2013 14:04:32 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.6/8.14.6) with ESMTP id r4HE4VxD072613; Fri, 17 May 2013 14:04:31 GMT (envelope-from kib@svn.freebsd.org) Received: (from kib@localhost) by svn.freebsd.org (8.14.6/8.14.5/Submit) id r4HE4VXf072612; Fri, 17 May 2013 14:04:31 GMT (envelope-from kib@svn.freebsd.org) Message-Id: <201305171404.r4HE4VXf072612@svn.freebsd.org> From: Konstantin Belousov Date: Fri, 17 May 2013 14:04:31 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r250740 - head/sys/dev/pci X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 17 May 2013 14:04:32 -0000 Author: kib Date: Fri May 17 14:04:31 2013 New Revision: 250740 URL: http://svnweb.freebsd.org/changeset/base/250740 Log: Add new capability types encodings from HyperTransport I/O Link Specification revisions 3.00 and 3.10. Submitted by: Dmitry Luhtionov MFC after: 1 week Modified: head/sys/dev/pci/pcireg.h Modified: head/sys/dev/pci/pcireg.h ============================================================================== --- head/sys/dev/pci/pcireg.h Fri May 17 09:12:33 2013 (r250739) +++ head/sys/dev/pci/pcireg.h Fri May 17 14:04:31 2013 (r250740) @@ -622,6 +622,10 @@ #define PCIM_HTCAP_VCSET 0xb800 /* 10111 */ #define PCIM_HTCAP_RETRY_MODE 0xc000 /* 11000 */ #define PCIM_HTCAP_X86_ENCODING 0xc800 /* 11001 */ +#define PCIM_HTCAP_GEN3 0xd000 /* 11010 */ +#define PCIM_HTCAP_FLE 0xd800 /* 11011 */ +#define PCIM_HTCAP_PM 0xe000 /* 11100 */ +#define PCIM_HTCAP_HIGH_NODE_COUNT 0xe800 /* 11101 */ /* HT MSI Mapping Capability definitions. */ #define PCIM_HTCMD_MSI_ENABLE 0x0001 From owner-svn-src-all@FreeBSD.ORG Fri May 17 14:05:32 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id 459BCFE8; Fri, 17 May 2013 14:05:32 +0000 (UTC) (envelope-from kib@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id 387A6E8A; Fri, 17 May 2013 14:05:32 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.6/8.14.6) with ESMTP id r4HE5Wj9072885; Fri, 17 May 2013 14:05:32 GMT (envelope-from kib@svn.freebsd.org) Received: (from kib@localhost) by svn.freebsd.org (8.14.6/8.14.5/Submit) id r4HE5W1R072884; Fri, 17 May 2013 14:05:32 GMT (envelope-from kib@svn.freebsd.org) Message-Id: <201305171405.r4HE5W1R072884@svn.freebsd.org> From: Konstantin Belousov Date: Fri, 17 May 2013 14:05:32 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r250741 - head/usr.sbin/pciconf X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 17 May 2013 14:05:32 -0000 Author: kib Date: Fri May 17 14:05:31 2013 New Revision: 250741 URL: http://svnweb.freebsd.org/changeset/base/250741 Log: Decode new HT 3.00 and 3.10 capabilities. Submitted by: Dmitry Luhtionov MFC after: 1 week Modified: head/usr.sbin/pciconf/cap.c Modified: head/usr.sbin/pciconf/cap.c ============================================================================== --- head/usr.sbin/pciconf/cap.c Fri May 17 14:04:31 2013 (r250740) +++ head/usr.sbin/pciconf/cap.c Fri May 17 14:05:31 2013 (r250741) @@ -276,6 +276,18 @@ cap_ht(int fd, struct pci_conf *p, uint8 case PCIM_HTCAP_X86_ENCODING: printf("X86 encoding"); break; + case PCIM_HTCAP_GEN3: + printf("Gen3"); + break; + case PCIM_HTCAP_FLE: + printf("function-level extension"); + break; + case PCIM_HTCAP_PM: + printf("power management"); + break; + case PCIM_HTCAP_HIGH_NODE_COUNT: + printf("high node count"); + break; default: printf("unknown %02x", command); break; From owner-svn-src-all@FreeBSD.ORG Fri May 17 14:44:41 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id 16564227; Fri, 17 May 2013 14:44:41 +0000 (UTC) (envelope-from adrian.chadd@gmail.com) Received: from mail-wi0-x22f.google.com (mail-wi0-x22f.google.com [IPv6:2a00:1450:400c:c05::22f]) by mx1.freebsd.org (Postfix) with ESMTP id 064A4FA; Fri, 17 May 2013 14:44:39 +0000 (UTC) Received: by mail-wi0-f175.google.com with SMTP id hn14so515318wib.8 for ; Fri, 17 May 2013 07:44:38 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:x-received:sender:in-reply-to:references:date :x-google-sender-auth:message-id:subject:from:to:cc:content-type :content-transfer-encoding; bh=UhcAbtNlZx4zjROh8oGNzQFMyw4ZZkuNoKuBEwO2+GU=; b=eJq0x1Rrz0xzmZ/nwA8blW5IqDH9x5GoPEszPmzqNDUKpwWfRddTqSzqTd4RN+uMFN zpyPPCPw05IUzBzB0J3qmJ6D8QN7N9QUPH8A2EKWe5Bw5FiVhjpJweu10yDJTbnQIKX1 xTvrswMWdZxltxk0BYwez2g4Cj4xS0FUYjxSQtCLHp7/A3zGvIQuRtXXc3JCK/BeyEqR phOjbFib7Jmr54XEQ3+c8M4Pz2d2Bu9o9k1MITx34lilY/61had4nL+bBvZYI2JySwn0 LOCYv5QMLwvVvkiloZSG+4bNdKIkCk5XpUQi11UHUwho8qJOXBOm0Jvm71Gm/D79xws8 10Aw== MIME-Version: 1.0 X-Received: by 10.181.13.169 with SMTP id ez9mr17748446wid.8.1368801467765; Fri, 17 May 2013 07:37:47 -0700 (PDT) Sender: adrian.chadd@gmail.com Received: by 10.217.58.138 with HTTP; Fri, 17 May 2013 07:37:47 -0700 (PDT) In-Reply-To: <6C1AD894-149B-4E08-90DB-2BC3899A4CE8@FreeBSD.org> References: <201305160351.r4G3p0uu047404@svn.freebsd.org> <30BAC0E1-9E8F-4FA4-A31E-C2AFAFDBCB95@freebsd.org> <6C1AD894-149B-4E08-90DB-2BC3899A4CE8@FreeBSD.org> Date: Fri, 17 May 2013 07:37:47 -0700 X-Google-Sender-Auth: 336nueMKCX-B2FDY8HgnQA_AGQc Message-ID: Subject: Re: svn commit: r250692 - head/sys/arm/conf From: Adrian Chadd To: Tim Kientzle Content-Type: text/plain; charset=windows-1252 Content-Transfer-Encoding: quoted-printable Cc: svn-src-head@freebsd.org, svn-src-all@freebsd.org, src-committers@freebsd.org, Rui Paulo X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 17 May 2013 14:44:41 -0000 .. if there were only a way we could glue together different elf binaries into some kind of "archive" that let people load a set of modules as part of a kernel. We could call it initrd (ew) or something. adrian On 17 May 2013 05:45, Tim Kientzle wrote: > > On May 16, 2013, at 9:49 PM, Rui Paulo wrote: > >> On 2013/05/16, at 2:02, Tim Kientzle wrote: >> >>> I don't object, but I'm not sure why we need this. >>> >>> I'd rather see a comment in the BEAGLEBONE >>> config indicating that it can be used with >>> beaglebone-black.dts. >>> >>> Generally, I want us to move away from compiled-in >>> DTBs. The BEAGLEBONE config works just fine on either >>> one and it's what I plan to continue using going forward. >>> >>> Part of the boot loader's job is to load the correct DTB. >>> The images built by Crochet today already do this >>> and produce images that boot on either old or new >>> BeagleBone using the BEAGLEBONE config. >>> >>> U-Boot already has logic to detect the board, >>> load the correct DTB, and the same BEAGLEBONE >>> kernel then runs just fine. Here are the U-Boot >>> patches if you'd like to do this as well: >>> >>> https://github.com/kientzle/crochet-freebsd/tree/master/board/BeagleBon= e/files >>> >>> (There's also a copy of the compiled U-Boot and >>> associated files at: >>> >>> http://people.freebsd.org/~kientzle/beaglebone-and-black-bootfiles.tgz >>> >>> Moving forward, I'd like to see us generally consolidate ARM >>> kernel configurations. I have some (still very experimental) >>> ideas for combining the RPi and BeagleBone kernels >>> into a single kernel, but with my limited time, that will >>> be a fairly long-term project. If anyone's at BSDCan >>> who would like to talk about it=85. I'll be at the >>> "Beyond BuildWorld" session on Thursday=85. ;-) >>> >>> Yes, this is certainly useful for people net booting >>> the BeagleBone Black for developing kernel drivers, >>> but I'm not sure why we would bother having it >>> checked-in. >> >> >> I understand your point, but what about drivers that only apply to the B= eagleBone Black, such as a driver for HDMI? Wouldn't that require a separat= e kernel config file or are we expecting to use only kernel modules? > > Such a driver should be in the BeagleBone kernel config > but will only get turned on (by the FDT) on appropriate > boards. > > Yes, people who need small kernels for various reasons > will definitely need to hand-tune their kernel configs > to leave out drivers they don't want (such as an HDMI > driver on a BeagleBone white). But that doesn't mean > we need separate kernel configs in the tree for every > possible combination of hardware. That's what FDT is for. > > The proliferation of kernel configs is getting to be > a headache. > * "make universe" has to build all kernels, so we're > better off with fewer bulkier kernel configs. > * To more rapidly support new systems, we want to > be able to mix-and-match existing drivers. Right now, > drivers originally developed for different SoCs don't > even compile together, so we can't effectively leverage > existing code. There's a *lot* of cut-and-paste copying > of code in our ARM tree right now. I have some ideas > about how to unify some of the ARMv6 kernels and I'm > hoping to start gradually working on that over the next > few months. > > Ideally, I'd like to have a handful of "GENERIC" kernel > configs in the tree, each supporting a range of SoCs. > This will give us confidence that large sets of drivers > do all compile and play reasonably well together. It > will also make it feasible for people working on generic > driver infrastructure to get some real traction on things > like generic irq routing and pinmux support. (Brooks has > some interesting ideas about IRQ routing and Warner > has talked about better ways to do pinmux mapping.) > > It's easy for folks to trim configs if they need to do so > for particular applications. > > Tim > From owner-svn-src-all@FreeBSD.ORG Fri May 17 14:57:58 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id BBF765A0 for ; Fri, 17 May 2013 14:57:58 +0000 (UTC) (envelope-from andre@freebsd.org) Received: from c00l3r.networx.ch (c00l3r.networx.ch [62.48.2.2]) by mx1.freebsd.org (Postfix) with ESMTP id 17EE3182 for ; Fri, 17 May 2013 14:57:57 +0000 (UTC) Received: (qmail 11249 invoked from network); 17 May 2013 15:58:24 -0000 Received: from c00l3r.networx.ch (HELO [127.0.0.1]) ([62.48.2.2]) (envelope-sender ) by c00l3r.networx.ch (qmail-ldap-1.03) with SMTP for ; 17 May 2013 15:58:24 -0000 Message-ID: <51964568.2000609@freebsd.org> Date: Fri, 17 May 2013 16:57:44 +0200 From: Andre Oppermann User-Agent: Mozilla/5.0 (Windows NT 6.1; WOW64; rv:17.0) Gecko/20130509 Thunderbird/17.0.6 MIME-Version: 1.0 To: Brooks Davis Subject: Re: svn commit: r250658 - in head: share/mk sys/conf tools/build/options References: <201305151304.r4FD4B1i032146@svn.freebsd.org> In-Reply-To: <201305151304.r4FD4B1i032146@svn.freebsd.org> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit Cc: svn-src-head@freebsd.org, svn-src-all@freebsd.org, src-committers@freebsd.org X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 17 May 2013 14:57:58 -0000 On 15.05.2013 15:04, Brooks Davis wrote: > Author: brooks > Date: Wed May 15 13:04:10 2013 > New Revision: 250658 > URL: http://svnweb.freebsd.org/changeset/base/250658 > > Log: > Add a new option WITHOUT_FORMAT_EXTENSIONS to disable flags related to > checking our kernel printf extensions. This is useful to allow > compilers without these extensions to build kernels. > > Sponsored by: DARPA, AFRL This breaks "make depend" at least on amd64: "../../../conf/kern.mk", line 37: Malformed conditional (${MK_FORMAT_EXTENSIONS} == "no") "../../../conf/kern.mk", line 39: if-less else "../../../conf/kern.mk", line 41: if-less endif make: fatal errors encountered -- cannot continue -- Andre > Added: > head/tools/build/options/WITHOUT_FORMAT_EXTENSIONS (contents, props changed) > Modified: > head/share/mk/bsd.own.mk > head/sys/conf/kern.mk > > Modified: head/share/mk/bsd.own.mk > ============================================================================== > --- head/share/mk/bsd.own.mk Wed May 15 08:38:49 2013 (r250657) > +++ head/share/mk/bsd.own.mk Wed May 15 13:04:10 2013 (r250658) > @@ -268,6 +268,7 @@ __DEFAULT_YES_OPTIONS = \ > ED_CRYPTO \ > EXAMPLES \ > FLOPPY \ > + FORMAT_EXTENSIONS \ > FORTH \ > FP_LIBC \ > FREEBSD_UPDATE \ > > Modified: head/sys/conf/kern.mk > ============================================================================== > --- head/sys/conf/kern.mk Wed May 15 08:38:49 2013 (r250657) > +++ head/sys/conf/kern.mk Wed May 15 13:04:10 2013 (r250658) > @@ -5,7 +5,7 @@ > # > CWARNFLAGS?= -Wall -Wredundant-decls -Wnested-externs -Wstrict-prototypes \ > -Wmissing-prototypes -Wpointer-arith -Winline -Wcast-qual \ > - -Wundef -Wno-pointer-sign -fformat-extensions \ > + -Wundef -Wno-pointer-sign ${FORMAT_EXTENTIONS} \ > -Wmissing-include-dirs -fdiagnostics-show-option \ > ${CWARNEXTRA} > # > @@ -29,7 +29,15 @@ NO_WSOMETIMES_UNINITIALIZED= -Wno-error- > # enough to error out the whole kernel build. Display them anyway, so there is > # some incentive to fix them eventually. > CWARNEXTRA?= -Wno-error-tautological-compare -Wno-error-empty-body \ > - -Wno-error-parentheses-equality > + -Wno-error-parentheses-equality ${NO_WFORMAT} > +.endif > + > +# External compilers may not support our format extensions. Allow them > +# to be disabled. WARNING: format checking is disabled in this case. > +.if ${MK_FORMAT_EXTENSIONS} == "no" > +NO_WFORMAT= -Wno-format > +.else > +FORMAT_EXTENTIONS= -fformat-extensions > .endif > > # > > Added: head/tools/build/options/WITHOUT_FORMAT_EXTENSIONS > ============================================================================== > --- /dev/null 00:00:00 1970 (empty, because file is newly added) > +++ head/tools/build/options/WITHOUT_FORMAT_EXTENSIONS Wed May 15 13:04:10 2013 (r250658) > @@ -0,0 +1,5 @@ > +.\" $FreeBSD$ > +Set to not enable > +.Fl fformat-extensions > +when compiling the kernel. > +Also disables all format checking. > > From owner-svn-src-all@FreeBSD.ORG Fri May 17 15:20:46 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id 81F1E8B3; Fri, 17 May 2013 15:20:46 +0000 (UTC) (envelope-from rpaulo@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id 73086238; Fri, 17 May 2013 15:20:46 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.6/8.14.6) with ESMTP id r4HFKkrw098488; Fri, 17 May 2013 15:20:46 GMT (envelope-from rpaulo@svn.freebsd.org) Received: (from rpaulo@localhost) by svn.freebsd.org (8.14.6/8.14.5/Submit) id r4HFKkCa098487; Fri, 17 May 2013 15:20:46 GMT (envelope-from rpaulo@svn.freebsd.org) Message-Id: <201305171520.r4HFKkCa098487@svn.freebsd.org> From: Rui Paulo Date: Fri, 17 May 2013 15:20:46 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r250742 - head/sys/arm/conf X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 17 May 2013 15:20:46 -0000 Author: rpaulo Date: Fri May 17 15:20:45 2013 New Revision: 250742 URL: http://svnweb.freebsd.org/changeset/base/250742 Log: Revert r250692. We'll use 1 kernel config file for the BeagleBone models. Deleted: head/sys/arm/conf/BEAGLEBONE-BLACK Modified: head/sys/arm/conf/BEAGLEBONE Modified: head/sys/arm/conf/BEAGLEBONE ============================================================================== --- head/sys/arm/conf/BEAGLEBONE Fri May 17 14:05:31 2013 (r250741) +++ head/sys/arm/conf/BEAGLEBONE Fri May 17 15:20:45 2013 (r250742) @@ -1,5 +1,7 @@ # BEAGLEBONE -- Custom configuration for the BeagleBone ARM development -# platform, check out http://www.beagleboard.org/bone +# platforms, check out http://www.beagleboard.org/bone and +# http://www.beagleboard.org/black. This kernel config file is used for the +# original BeagleBone and the BeagleBone Black. # # For more information on this file, please read the handbook section on # Kernel Configuration Files: From owner-svn-src-all@FreeBSD.ORG Fri May 17 15:22:11 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id B62FFA34; Fri, 17 May 2013 15:22:11 +0000 (UTC) (envelope-from yaneurabeya@gmail.com) Received: from mail-ie0-x22e.google.com (mail-ie0-x22e.google.com [IPv6:2607:f8b0:4001:c03::22e]) by mx1.freebsd.org (Postfix) with ESMTP id 6292E242; Fri, 17 May 2013 15:22:11 +0000 (UTC) Received: by mail-ie0-f174.google.com with SMTP id 10so9239490ied.5 for ; Fri, 17 May 2013 08:22:11 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=x-received:subject:mime-version:content-type:from:in-reply-to:date :cc:content-transfer-encoding:message-id:references:to:x-mailer; bh=Zqp6MXBLbPvTixWbx3vvHIza+ezfxDJmhAxSKtT4E1M=; b=wYxBYXL/8oybqdmt/64/yygloSbj2v2uTWbyeq8KIJTpEAGNWIbix6AobVeytYkpuC Y0yc1bkxYGuqDgfn06qUBVuuDKWlo/SHcHGBUx5q5SZIpI3Esfw0FXqak9X/2MS5hQaN NVka1WfG7iWkuSrSYIBL+KWot84uKt2RrFMCoLa6D+tnIdr5agUY4Zh5KTRqrfL9cszB QLCovBZZgyyNLt5thlU0bwaGu0rOnmlWuxq+fY1jMDxrJWK6djj2PZwgcpcGxPcdgFaL ZdDKot8gM7rfazw/Lu7BwTtsd8+bYvA9Cj9CGjWQkGZTpx1KoLlz5uvtap70uuSu1jLL 85WQ== X-Received: by 10.43.158.3 with SMTP id ls3mr26429693icc.55.1368804131008; Fri, 17 May 2013 08:22:11 -0700 (PDT) Received: from [10.69.210.170] ([137.122.64.19]) by mx.google.com with ESMTPSA id d4sm10013669igc.3.2013.05.17.08.22.09 for (version=TLSv1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Fri, 17 May 2013 08:22:10 -0700 (PDT) Subject: Re: svn commit: r250658 - in head: share/mk sys/conf tools/build/options Mime-Version: 1.0 (Apple Message framework v1283) Content-Type: text/plain; charset=us-ascii From: Garrett Cooper In-Reply-To: <51964568.2000609@freebsd.org> Date: Fri, 17 May 2013 11:22:07 -0400 Content-Transfer-Encoding: quoted-printable Message-Id: References: <201305151304.r4FD4B1i032146@svn.freebsd.org> <51964568.2000609@freebsd.org> To: Andre Oppermann X-Mailer: Apple Mail (2.1283) Cc: svn-src-head@freebsd.org, svn-src-all@freebsd.org, Brooks Davis , src-committers@freebsd.org X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 17 May 2013 15:22:11 -0000 On May 17, 2013, at 10:57 AM, Andre Oppermann wrote: > On 15.05.2013 15:04, Brooks Davis wrote: >> Author: brooks >> Date: Wed May 15 13:04:10 2013 >> New Revision: 250658 >> URL: http://svnweb.freebsd.org/changeset/base/250658 >>=20 >> Log: >> Add a new option WITHOUT_FORMAT_EXTENSIONS to disable flags related = to >> checking our kernel printf extensions. This is useful to allow >> compilers without these extensions to build kernels. >>=20 >> Sponsored by: DARPA, AFRL >=20 > This breaks "make depend" at least on amd64: >=20 > "../../../conf/kern.mk", line 37: Malformed conditional = (${MK_FORMAT_EXTENSIONS} =3D=3D "no") > "../../../conf/kern.mk", line 39: if-less else > "../../../conf/kern.mk", line 41: if-less endif > make: fatal errors encountered -- cannot continue cd /usr/src (cd share/mk; make install) cd sys; make depend ? -Garrett= From owner-svn-src-all@FreeBSD.ORG Fri May 17 17:16:30 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id 05109D23; Fri, 17 May 2013 17:16:30 +0000 (UTC) (envelope-from hiren@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id EBCA0BFD; Fri, 17 May 2013 17:16:29 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.6/8.14.6) with ESMTP id r4HHGT3E039570; Fri, 17 May 2013 17:16:29 GMT (envelope-from hiren@svn.freebsd.org) Received: (from hiren@localhost) by svn.freebsd.org (8.14.6/8.14.5/Submit) id r4HHGTci039569; Fri, 17 May 2013 17:16:29 GMT (envelope-from hiren@svn.freebsd.org) Message-Id: <201305171716.r4HHGTci039569@svn.freebsd.org> From: Hiren Panchasara Date: Fri, 17 May 2013 17:16:29 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-8@freebsd.org Subject: svn commit: r250743 - stable/8/sys/x86/cpufreq X-SVN-Group: stable-8 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 17 May 2013 17:16:30 -0000 Author: hiren Date: Fri May 17 17:16:29 2013 New Revision: 250743 URL: http://svnweb.freebsd.org/changeset/base/250743 Log: MFC: r250487 Adding a detach method to p4tcc driver. PR: 118739 Submitted by: Dan Lukes (earlier version) Reviewed by: jhb Approved by: sbruno (mentor) Modified: stable/8/sys/x86/cpufreq/p4tcc.c Directory Properties: stable/8/ (props changed) stable/8/sys/ (props changed) stable/8/sys/x86/ (props changed) Modified: stable/8/sys/x86/cpufreq/p4tcc.c ============================================================================== --- stable/8/sys/x86/cpufreq/p4tcc.c Fri May 17 15:20:45 2013 (r250742) +++ stable/8/sys/x86/cpufreq/p4tcc.c Fri May 17 17:16:29 2013 (r250743) @@ -73,6 +73,7 @@ static int p4tcc_features(driver_t *driv static void p4tcc_identify(driver_t *driver, device_t parent); static int p4tcc_probe(device_t dev); static int p4tcc_attach(device_t dev); +static int p4tcc_detach(device_t dev); static int p4tcc_settings(device_t dev, struct cf_setting *sets, int *count); static int p4tcc_set(device_t dev, const struct cf_setting *set); @@ -84,6 +85,7 @@ static device_method_t p4tcc_methods[] = DEVMETHOD(device_identify, p4tcc_identify), DEVMETHOD(device_probe, p4tcc_probe), DEVMETHOD(device_attach, p4tcc_attach), + DEVMETHOD(device_detach, p4tcc_detach), /* cpufreq interface */ DEVMETHOD(cpufreq_drv_set, p4tcc_set), @@ -213,6 +215,24 @@ p4tcc_attach(device_t dev) } static int +p4tcc_detach(device_t dev) +{ + struct cf_setting set; + int error; + + error = cpufreq_unregister(dev); + if (error) + return (error); + + /* + * Before we finish detach, switch to Automatic mode. + */ + set.freq = 10000; + p4tcc_set(dev, &set); + return(0); +} + +static int p4tcc_settings(device_t dev, struct cf_setting *sets, int *count) { struct p4tcc_softc *sc; From owner-svn-src-all@FreeBSD.ORG Fri May 17 17:19:26 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id 91C06EB4; Fri, 17 May 2013 17:19:26 +0000 (UTC) (envelope-from hiren.panchasara@gmail.com) Received: from mail-ea0-x22d.google.com (mail-ea0-x22d.google.com [IPv6:2a00:1450:4013:c01::22d]) by mx1.freebsd.org (Postfix) with ESMTP id 7A132C1F; Fri, 17 May 2013 17:19:25 +0000 (UTC) Received: by mail-ea0-f173.google.com with SMTP id n15so2598293ead.18 for ; Fri, 17 May 2013 10:19:24 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:x-received:sender:in-reply-to:references:date :x-google-sender-auth:message-id:subject:from:to:cc:content-type; bh=Q83HzlgMuYNWMBfJ1FLKoxxJSsXEhn9AEjT+YfB5CNs=; b=wGQkIXfVyalflKGeih52ZB2uxyZf245GGEzaobhMnxEzl5c0rDHkvSsTFn0jRCOI43 NaF15Uz57OYciWGrvuDHCYMvIC5m8SNm4ixaBhQaX1zHlP32r//MLiAJXXYUe11cCKdw IvBI36r1NILT87swSInEniydoByWfkHBO+VWW4YDxe1gu47HqcxzEpDXVaLh4DO6gDuT PP4ei+2i5LbdRe2Q8CVNSErN/f34EI4ZRtGhn0L+wPQ7+MO/Pt4AXPoF1tICVdZ1Biam yMg/9kH6JctoUZsxl94TgTfPrFYB5HcVqqppIwpebz6bgfoD0Fg9es1IhA5JUKokeUK5 MFuQ== MIME-Version: 1.0 X-Received: by 10.15.94.131 with SMTP id bb3mr80198102eeb.20.1368811164542; Fri, 17 May 2013 10:19:24 -0700 (PDT) Sender: hiren.panchasara@gmail.com Received: by 10.14.130.66 with HTTP; Fri, 17 May 2013 10:19:24 -0700 (PDT) In-Reply-To: <20130517054509.GA52849@FreeBSD.org> References: <201305170409.r4H495sj063275@svn.freebsd.org> <20130517054509.GA52849@FreeBSD.org> Date: Fri, 17 May 2013 10:19:24 -0700 X-Google-Sender-Auth: NTJUwOJjhfk0CFUO8MMe-ahlYm4 Message-ID: Subject: Re: svn commit: r250734 - stable/9/sys/x86/cpufreq From: hiren panchasara To: Alexey Dokuchaev Content-Type: text/plain; charset=UTF-8 Cc: svn-src-stable@freebsd.org, svn-src-all , src-committers , svn-src-stable-9@freebsd.org X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 17 May 2013 17:19:26 -0000 On Thu, May 16, 2013 at 10:45 PM, Alexey Dokuchaev wrote: > On Fri, May 17, 2013 at 04:09:05AM +0000, Hiren Panchasara wrote: >> New Revision: 250734 >> URL: http://svnweb.freebsd.org/changeset/base/250734 >> >> Log: >> MFC: r250487 >> >> Adding a detach method to p4tcc driver. > > Would it also benefit stable/8? If yes, could it be MFC'ed? Committed: r250743 Cheers, Hiren > > ./danfe From owner-svn-src-all@FreeBSD.ORG Fri May 17 17:45:01 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id 258685F8; Fri, 17 May 2013 17:45:01 +0000 (UTC) (envelope-from zec@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id 15F8ED63; Fri, 17 May 2013 17:45:01 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.6/8.14.6) with ESMTP id r4HHj0pG049623; Fri, 17 May 2013 17:45:00 GMT (envelope-from zec@svn.freebsd.org) Received: (from zec@localhost) by svn.freebsd.org (8.14.6/8.14.5/Submit) id r4HHj040049622; Fri, 17 May 2013 17:45:00 GMT (envelope-from zec@svn.freebsd.org) Message-Id: <201305171745.r4HHj040049622@svn.freebsd.org> From: Marko Zec Date: Fri, 17 May 2013 17:45:00 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org Subject: svn commit: r250744 - stable/9/sys/netinet X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 17 May 2013 17:45:01 -0000 Author: zec Date: Fri May 17 17:45:00 2013 New Revision: 250744 URL: http://svnweb.freebsd.org/changeset/base/250744 Log: MFC 233601: Permit tcpdrop in VNET jails. Modified: stable/9/sys/netinet/tcp_subr.c Directory Properties: stable/9/sys/ (props changed) Modified: stable/9/sys/netinet/tcp_subr.c ============================================================================== --- stable/9/sys/netinet/tcp_subr.c Fri May 17 17:16:29 2013 (r250743) +++ stable/9/sys/netinet/tcp_subr.c Fri May 17 17:45:00 2013 (r250744) @@ -2192,7 +2192,7 @@ sysctl_drop(SYSCTL_HANDLER_ARGS) return (error); } -SYSCTL_PROC(_net_inet_tcp, TCPCTL_DROP, drop, +SYSCTL_VNET_PROC(_net_inet_tcp, TCPCTL_DROP, drop, CTLTYPE_STRUCT|CTLFLAG_WR|CTLFLAG_SKIP, NULL, 0, sysctl_drop, "", "Drop TCP connection"); From owner-svn-src-all@FreeBSD.ORG Fri May 17 18:18:21 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id 8B0DCF1A; Fri, 17 May 2013 18:18:21 +0000 (UTC) (envelope-from tijl@freebsd.org) Received: from mailrelay012.isp.belgacom.be (mailrelay012.isp.belgacom.be [195.238.6.179]) by mx1.freebsd.org (Postfix) with ESMTP id B199FEAE; Fri, 17 May 2013 18:18:20 +0000 (UTC) X-Belgacom-Dynamic: yes X-IronPort-Anti-Spam-Filtered: true X-IronPort-Anti-Spam-Result: AmMGAPJzllFbsXMH/2dsb2JhbABagwgwgzu+E34XdIIfAQEFI1YQCxQECRYLAgIJAwIBAgEnHgYNAQcBAYgMCKtbkXqPEBEHgkGBEwOPe4ErhzuQF4MROg Received: from 7.115-177-91.adsl-dyn.isp.belgacom.be (HELO kalimero.tijl.coosemans.org) ([91.177.115.7]) by relay.skynet.be with ESMTP; 17 May 2013 20:18:12 +0200 Received: from kalimero.tijl.coosemans.org (kalimero.tijl.coosemans.org [127.0.0.1]) by kalimero.tijl.coosemans.org (8.14.7/8.14.7) with ESMTP id r4HIIBsS064912; Fri, 17 May 2013 20:18:11 +0200 (CEST) (envelope-from tijl@FreeBSD.org) Message-ID: <5196745E.7040905@FreeBSD.org> Date: Fri, 17 May 2013 20:18:06 +0200 From: Tijl Coosemans User-Agent: Mozilla/5.0 (X11; FreeBSD i386; rv:17.0) Gecko/20130408 Thunderbird/17.0.5 MIME-Version: 1.0 To: "Simon J. Gerraty" Subject: Re: svn commit: r250699 - in head: share/mk usr.bin/make References: <201305161528.r4GFSc5t094460@svn.freebsd.org> In-Reply-To: <201305161528.r4GFSc5t094460@svn.freebsd.org> X-Enigmail-Version: 1.5.1 Content-Type: multipart/signed; micalg=pgp-sha256; protocol="application/pgp-signature"; boundary="----enig2GLTIXILGWXODBDDFRHIL" Cc: svn-src-head@freebsd.org, svn-src-all@freebsd.org, src-committers@freebsd.org X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 17 May 2013 18:18:21 -0000 This is an OpenPGP/MIME signed message (RFC 4880 and 3156) ------enig2GLTIXILGWXODBDDFRHIL Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable On 2013-05-16 17:28, Simon J. Gerraty wrote: > Author: sjg > Date: Thu May 16 15:28:38 2013 > New Revision: 250699 > URL: http://svnweb.freebsd.org/changeset/base/250699 >=20 > Log: > Build bmake by default. For me /usr/src is a symlink to /some/path and now if I build from /usr/src some parts end up in /usr/obj/usr/src and other parts in /usr/obj/some/path. It used to be the latter. /usr/ports is a symlink too: % cd /usr/ports/www/firefox % pwd /usr/home/tijl/freebsd/ports/head/www/firefox % make -V .CURDIR /usr/ports/www/firefox % cd /usr/home/tijl/freebsd/ports/head/www/firefox % pwd /usr/home/tijl/freebsd/ports/head/www/firefox % make -V .CURDIR /home/tijl/freebsd/ports/head/www/firefox So it seems to change /usr/home back into /home too. This breaks ports-mgmt/portconf because it adds the following to /etc/make.conf but .CURDIR never matches the real path. =2Eif !empty(.CURDIR:M/usr/home/tijl/freebsd/ports*) && exists(/usr/local= /libexec/portconf) =2E.. =2Eendif ------enig2GLTIXILGWXODBDDFRHIL Content-Type: application/pgp-signature; name="signature.asc" Content-Description: OpenPGP digital signature Content-Disposition: attachment; filename="signature.asc" -----BEGIN PGP SIGNATURE----- Version: GnuPG v2.0.20 (FreeBSD) iF4EAREIAAYFAlGWdGIACgkQfoCS2CCgtiuYtAD/XAg29vUQxDVof+ydCyP3AF17 OBVtZMQoX7mJ0R/BYcAA/ioE5iVpqGEb8Wi8OtOtH+d7CV7bLyXi8b8KZWEva45c =ojMG -----END PGP SIGNATURE----- ------enig2GLTIXILGWXODBDDFRHIL-- From owner-svn-src-all@FreeBSD.ORG Fri May 17 18:23:36 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 1033) id 07326145; Fri, 17 May 2013 18:23:36 +0000 (UTC) Date: Fri, 17 May 2013 18:23:36 +0000 From: Alexey Dokuchaev To: hiren panchasara Subject: Re: svn commit: r250734 - stable/9/sys/x86/cpufreq Message-ID: <20130517182335.GA19683@FreeBSD.org> References: <201305170409.r4H495sj063275@svn.freebsd.org> <20130517054509.GA52849@FreeBSD.org> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.5.21 (2010-09-15) Cc: svn-src-stable@freebsd.org, svn-src-all , src-committers , svn-src-stable-9@freebsd.org X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 17 May 2013 18:23:36 -0000 On Fri, May 17, 2013 at 10:19:24AM -0700, hiren panchasara wrote: > On Thu, May 16, 2013 at 10:45 PM, Alexey Dokuchaev wrote: > > On Fri, May 17, 2013 at 04:09:05AM +0000, Hiren Panchasara wrote: > >> New Revision: 250734 > >> URL: http://svnweb.freebsd.org/changeset/base/250734 > >> > >> Log: > >> MFC: r250487 > >> > >> Adding a detach method to p4tcc driver. > > > > Would it also benefit stable/8? If yes, could it be MFC'ed? > > Committed: r250743 Seen it, thanks! ./danfe From owner-svn-src-all@FreeBSD.ORG Fri May 17 18:49:43 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id B84DE850; Fri, 17 May 2013 18:49:43 +0000 (UTC) (envelope-from alc@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id ABCAFFA1; Fri, 17 May 2013 18:49:43 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.6/8.14.6) with ESMTP id r4HInhjM072529; Fri, 17 May 2013 18:49:43 GMT (envelope-from alc@svn.freebsd.org) Received: (from alc@localhost) by svn.freebsd.org (8.14.6/8.14.5/Submit) id r4HInhUR072528; Fri, 17 May 2013 18:49:43 GMT (envelope-from alc@svn.freebsd.org) Message-Id: <201305171849.r4HInhUR072528@svn.freebsd.org> From: Alan Cox Date: Fri, 17 May 2013 18:49:43 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r250745 - head/sys/vm X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 17 May 2013 18:49:43 -0000 Author: alc Date: Fri May 17 18:49:43 2013 New Revision: 250745 URL: http://svnweb.freebsd.org/changeset/base/250745 Log: Relax the object locking assertion in vm_page_lookup(). Now that a radix tree is used to maintain the object's collection of resident pages, vm_page_lookup() no longer needs an exclusive lock. Reviewed by: attilio Sponsored by: EMC / Isilon Storage Division Modified: head/sys/vm/vm_page.c Modified: head/sys/vm/vm_page.c ============================================================================== --- head/sys/vm/vm_page.c Fri May 17 17:45:00 2013 (r250744) +++ head/sys/vm/vm_page.c Fri May 17 18:49:43 2013 (r250745) @@ -942,7 +942,7 @@ vm_page_t vm_page_lookup(vm_object_t object, vm_pindex_t pindex) { - VM_OBJECT_ASSERT_WLOCKED(object); + VM_OBJECT_ASSERT_LOCKED(object); return (vm_radix_lookup(&object->rtree, pindex)); } From owner-svn-src-all@FreeBSD.ORG Fri May 17 18:53:35 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id 952E8A59; Fri, 17 May 2013 18:53:35 +0000 (UTC) (envelope-from gabor@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id 84412FBE; Fri, 17 May 2013 18:53:35 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.6/8.14.6) with ESMTP id r4HIrZu5074925; Fri, 17 May 2013 18:53:35 GMT (envelope-from gabor@svn.freebsd.org) Received: (from gabor@localhost) by svn.freebsd.org (8.14.6/8.14.5/Submit) id r4HIrTOb074886; Fri, 17 May 2013 18:53:29 GMT (envelope-from gabor@svn.freebsd.org) Message-Id: <201305171853.r4HIrTOb074886@svn.freebsd.org> From: Gabor Kovesdan Date: Fri, 17 May 2013 18:53:29 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r250746 - in head/release/doc: de_DE.ISO8859-1/early-adopter de_DE.ISO8859-1/errata de_DE.ISO8859-1/hardware/alpha de_DE.ISO8859-1/hardware/common de_DE.ISO8859-1/hardware/i386 de_DE.IS... X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 17 May 2013 18:53:35 -0000 Author: gabor Date: Fri May 17 18:53:29 2013 New Revision: 250746 URL: http://svnweb.freebsd.org/changeset/base/250746 Log: - Update the release notes to DocBook 4.5 XML to build with the updated documentation tree Added: head/release/doc/ja_JP.eucJP/share/xml/catalog.xml - copied, changed from r250633, head/release/doc/ja_JP.eucJP/share/xml/catalog head/release/doc/ru_RU.KOI8-R/share/xml/catalog.xml - copied, changed from r250633, head/release/doc/ru_RU.KOI8-R/share/xml/catalog head/release/doc/share/xml/catalog.xml - copied, changed from r250633, head/release/doc/share/xml/catalog Modified: head/release/doc/de_DE.ISO8859-1/early-adopter/article.xml head/release/doc/de_DE.ISO8859-1/errata/article.xml head/release/doc/de_DE.ISO8859-1/hardware/alpha/article.xml head/release/doc/de_DE.ISO8859-1/hardware/alpha/proc-alpha.xml head/release/doc/de_DE.ISO8859-1/hardware/common/dev.xml head/release/doc/de_DE.ISO8859-1/hardware/i386/article.xml head/release/doc/de_DE.ISO8859-1/hardware/ia64/article.xml head/release/doc/de_DE.ISO8859-1/hardware/pc98/article.xml head/release/doc/de_DE.ISO8859-1/hardware/sparc64/article.xml head/release/doc/de_DE.ISO8859-1/installation/alpha/article.xml head/release/doc/de_DE.ISO8859-1/installation/i386/article.xml head/release/doc/de_DE.ISO8859-1/installation/ia64/article.xml head/release/doc/de_DE.ISO8859-1/installation/pc98/article.xml head/release/doc/de_DE.ISO8859-1/installation/sparc64/article.xml head/release/doc/de_DE.ISO8859-1/readme/article.xml head/release/doc/de_DE.ISO8859-1/relnotes/alpha/article.xml head/release/doc/de_DE.ISO8859-1/relnotes/common/new.xml head/release/doc/de_DE.ISO8859-1/relnotes/i386/article.xml head/release/doc/de_DE.ISO8859-1/relnotes/ia64/article.xml head/release/doc/de_DE.ISO8859-1/relnotes/pc98/article.xml head/release/doc/de_DE.ISO8859-1/relnotes/sparc64/article.xml head/release/doc/en_US.ISO8859-1/Makefile head/release/doc/en_US.ISO8859-1/errata/article.xml head/release/doc/en_US.ISO8859-1/hardware/article.xml head/release/doc/en_US.ISO8859-1/readme/article.xml head/release/doc/en_US.ISO8859-1/relnotes/article.xml head/release/doc/fr_FR.ISO8859-1/early-adopter/article.xml head/release/doc/fr_FR.ISO8859-1/errata/article.xml head/release/doc/fr_FR.ISO8859-1/hardware/alpha/article.xml head/release/doc/fr_FR.ISO8859-1/hardware/alpha/proc-alpha.xml head/release/doc/fr_FR.ISO8859-1/hardware/common/dev.xml head/release/doc/fr_FR.ISO8859-1/hardware/i386/article.xml head/release/doc/fr_FR.ISO8859-1/hardware/i386/proc-i386.xml head/release/doc/fr_FR.ISO8859-1/hardware/ia64/article.xml head/release/doc/fr_FR.ISO8859-1/hardware/pc98/article.xml head/release/doc/fr_FR.ISO8859-1/hardware/pc98/proc-pc98.xml head/release/doc/fr_FR.ISO8859-1/hardware/sparc64/article.xml head/release/doc/fr_FR.ISO8859-1/hardware/sparc64/proc-sparc64.xml head/release/doc/fr_FR.ISO8859-1/installation/alpha/article.xml head/release/doc/fr_FR.ISO8859-1/installation/common/install.xml head/release/doc/fr_FR.ISO8859-1/installation/common/layout.xml head/release/doc/fr_FR.ISO8859-1/installation/i386/article.xml head/release/doc/fr_FR.ISO8859-1/installation/pc98/article.xml head/release/doc/fr_FR.ISO8859-1/installation/sparc64/article.xml head/release/doc/fr_FR.ISO8859-1/relnotes/alpha/article.xml head/release/doc/fr_FR.ISO8859-1/relnotes/common/new.xml head/release/doc/fr_FR.ISO8859-1/relnotes/i386/article.xml head/release/doc/ja_JP.eucJP/errata/article.xml (contents, props changed) head/release/doc/ja_JP.eucJP/hardware/alpha/article.xml head/release/doc/ja_JP.eucJP/hardware/amd64/article.xml head/release/doc/ja_JP.eucJP/hardware/amd64/proc-amd64.xml (contents, props changed) head/release/doc/ja_JP.eucJP/hardware/common/artheader.xml head/release/doc/ja_JP.eucJP/hardware/common/dev.xml head/release/doc/ja_JP.eucJP/hardware/common/intro.xml (contents, props changed) head/release/doc/ja_JP.eucJP/hardware/i386/article.xml head/release/doc/ja_JP.eucJP/hardware/i386/proc-i386.xml (contents, props changed) head/release/doc/ja_JP.eucJP/hardware/ia64/article.xml head/release/doc/ja_JP.eucJP/hardware/ia64/proc-ia64.xml (contents, props changed) head/release/doc/ja_JP.eucJP/hardware/pc98/article.xml head/release/doc/ja_JP.eucJP/hardware/pc98/proc-pc98.xml (contents, props changed) head/release/doc/ja_JP.eucJP/hardware/sparc64/article.xml head/release/doc/ja_JP.eucJP/hardware/sparc64/proc-sparc64.xml head/release/doc/ja_JP.eucJP/relnotes/alpha/article.xml head/release/doc/ja_JP.eucJP/relnotes/amd64/article.xml head/release/doc/ja_JP.eucJP/relnotes/common/new.xml head/release/doc/ja_JP.eucJP/relnotes/common/relnotes.ent head/release/doc/ja_JP.eucJP/relnotes/i386/article.xml head/release/doc/ja_JP.eucJP/relnotes/ia64/article.xml head/release/doc/ja_JP.eucJP/relnotes/pc98/article.xml head/release/doc/ja_JP.eucJP/relnotes/sparc64/article.xml head/release/doc/ja_JP.eucJP/share/xml/dev-auto-ja.xml (contents, props changed) head/release/doc/ru_RU.KOI8-R/errata/article.xml (contents, props changed) head/release/doc/ru_RU.KOI8-R/hardware/alpha/article.xml head/release/doc/ru_RU.KOI8-R/hardware/amd64/article.xml head/release/doc/ru_RU.KOI8-R/hardware/amd64/proc-amd64.xml head/release/doc/ru_RU.KOI8-R/hardware/common/artheader.xml head/release/doc/ru_RU.KOI8-R/hardware/common/dev.xml head/release/doc/ru_RU.KOI8-R/hardware/common/intro.xml head/release/doc/ru_RU.KOI8-R/hardware/i386/article.xml head/release/doc/ru_RU.KOI8-R/hardware/i386/proc-i386.xml head/release/doc/ru_RU.KOI8-R/hardware/ia64/article.xml head/release/doc/ru_RU.KOI8-R/hardware/ia64/proc-ia64.xml head/release/doc/ru_RU.KOI8-R/hardware/pc98/article.xml head/release/doc/ru_RU.KOI8-R/hardware/pc98/proc-pc98.xml head/release/doc/ru_RU.KOI8-R/hardware/sparc64/article.xml head/release/doc/ru_RU.KOI8-R/hardware/sparc64/proc-sparc64.xml head/release/doc/ru_RU.KOI8-R/installation/alpha/article.xml head/release/doc/ru_RU.KOI8-R/installation/amd64/article.xml head/release/doc/ru_RU.KOI8-R/installation/common/abstract.xml head/release/doc/ru_RU.KOI8-R/installation/common/artheader.xml head/release/doc/ru_RU.KOI8-R/installation/common/install.xml head/release/doc/ru_RU.KOI8-R/installation/common/layout.xml head/release/doc/ru_RU.KOI8-R/installation/common/trouble.xml head/release/doc/ru_RU.KOI8-R/installation/common/upgrade.xml head/release/doc/ru_RU.KOI8-R/installation/i386/article.xml head/release/doc/ru_RU.KOI8-R/installation/ia64/article.xml head/release/doc/ru_RU.KOI8-R/installation/pc98/article.xml head/release/doc/ru_RU.KOI8-R/installation/sparc64/article.xml head/release/doc/ru_RU.KOI8-R/readme/article.xml head/release/doc/ru_RU.KOI8-R/relnotes/alpha/article.xml head/release/doc/ru_RU.KOI8-R/relnotes/amd64/article.xml head/release/doc/ru_RU.KOI8-R/relnotes/common/new.xml head/release/doc/ru_RU.KOI8-R/relnotes/i386/article.xml head/release/doc/ru_RU.KOI8-R/relnotes/ia64/article.xml head/release/doc/ru_RU.KOI8-R/relnotes/pc98/article.xml head/release/doc/ru_RU.KOI8-R/relnotes/sparc64/article.xml head/release/doc/ru_RU.KOI8-R/share/xml/dev-auto-ru.xml head/release/doc/share/mk/doc.relnotes.mk head/release/doc/share/xml/Makefile head/release/doc/share/xml/release.ent head/release/doc/zh_CN.GB2312/errata/article.xml head/release/doc/zh_CN.GB2312/hardware/article.xml head/release/doc/zh_CN.GB2312/readme/article.xml head/release/doc/zh_CN.GB2312/relnotes/article.xml Modified: head/release/doc/de_DE.ISO8859-1/early-adopter/article.xml ============================================================================== --- head/release/doc/de_DE.ISO8859-1/early-adopter/article.xml Fri May 17 18:49:43 2013 (r250745) +++ head/release/doc/de_DE.ISO8859-1/early-adopter/article.xml Fri May 17 18:53:29 2013 (r250746) @@ -1,9 +1,8 @@ - - -%entities; - -%release; + + + %release; X"> X"> Modified: head/release/doc/de_DE.ISO8859-1/errata/article.xml ============================================================================== --- head/release/doc/de_DE.ISO8859-1/errata/article.xml Fri May 17 18:49:43 2013 (r250745) +++ head/release/doc/de_DE.ISO8859-1/errata/article.xml Fri May 17 18:53:29 2013 (r250746) @@ -1,9 +1,8 @@ - - -%entities; - -%release; + + + %release; ]> Modified: head/release/doc/de_DE.ISO8859-1/hardware/alpha/proc-alpha.xml ============================================================================== --- head/release/doc/de_DE.ISO8859-1/hardware/alpha/proc-alpha.xml Fri May 17 18:49:43 2013 (r250745) +++ head/release/doc/de_DE.ISO8859-1/hardware/alpha/proc-alpha.xml Fri May 17 18:53:29 2013 (r250746) @@ -1,3 +1,4 @@ + Modified: head/release/doc/de_DE.ISO8859-1/hardware/ia64/article.xml ============================================================================== --- head/release/doc/de_DE.ISO8859-1/hardware/ia64/article.xml Fri May 17 18:49:43 2013 (r250745) +++ head/release/doc/de_DE.ISO8859-1/hardware/ia64/article.xml Fri May 17 18:53:29 2013 (r250746) @@ -1,10 +1,9 @@ - - -%entities; - -%release; - %sections + + + %release; + %sections; Modified: head/release/doc/de_DE.ISO8859-1/hardware/pc98/article.xml ============================================================================== --- head/release/doc/de_DE.ISO8859-1/hardware/pc98/article.xml Fri May 17 18:49:43 2013 (r250745) +++ head/release/doc/de_DE.ISO8859-1/hardware/pc98/article.xml Fri May 17 18:53:29 2013 (r250746) @@ -1,10 +1,9 @@ - - -%entities; - -%release; - %sections + + + %release; + %sections; Modified: head/release/doc/de_DE.ISO8859-1/hardware/sparc64/article.xml ============================================================================== --- head/release/doc/de_DE.ISO8859-1/hardware/sparc64/article.xml Fri May 17 18:49:43 2013 (r250745) +++ head/release/doc/de_DE.ISO8859-1/hardware/sparc64/article.xml Fri May 17 18:53:29 2013 (r250746) @@ -1,10 +1,9 @@ - - -%entities; - -%release; - %sections + + + %release; + %sections; Modified: head/release/doc/de_DE.ISO8859-1/installation/alpha/article.xml ============================================================================== --- head/release/doc/de_DE.ISO8859-1/installation/alpha/article.xml Fri May 17 18:49:43 2013 (r250745) +++ head/release/doc/de_DE.ISO8859-1/installation/alpha/article.xml Fri May 17 18:53:29 2013 (r250746) @@ -1,9 +1,8 @@ - - -%entities; - -%release; + + + %release; %sections; Modified: head/release/doc/de_DE.ISO8859-1/installation/i386/article.xml ============================================================================== --- head/release/doc/de_DE.ISO8859-1/installation/i386/article.xml Fri May 17 18:49:43 2013 (r250745) +++ head/release/doc/de_DE.ISO8859-1/installation/i386/article.xml Fri May 17 18:53:29 2013 (r250746) @@ -1,9 +1,8 @@ - - -%entities; - -%release; + + + %release; %sections; Modified: head/release/doc/de_DE.ISO8859-1/installation/ia64/article.xml ============================================================================== --- head/release/doc/de_DE.ISO8859-1/installation/ia64/article.xml Fri May 17 18:49:43 2013 (r250745) +++ head/release/doc/de_DE.ISO8859-1/installation/ia64/article.xml Fri May 17 18:53:29 2013 (r250746) @@ -1,9 +1,8 @@ - - -%entities; - -%release; + + + %release; %sections; Modified: head/release/doc/de_DE.ISO8859-1/installation/pc98/article.xml ============================================================================== --- head/release/doc/de_DE.ISO8859-1/installation/pc98/article.xml Fri May 17 18:49:43 2013 (r250745) +++ head/release/doc/de_DE.ISO8859-1/installation/pc98/article.xml Fri May 17 18:53:29 2013 (r250746) @@ -1,9 +1,8 @@ - - -%entities; - -%release; + + + %release; %sections; Modified: head/release/doc/de_DE.ISO8859-1/installation/sparc64/article.xml ============================================================================== --- head/release/doc/de_DE.ISO8859-1/installation/sparc64/article.xml Fri May 17 18:49:43 2013 (r250745) +++ head/release/doc/de_DE.ISO8859-1/installation/sparc64/article.xml Fri May 17 18:53:29 2013 (r250746) @@ -1,10 +1,8 @@ - - -%entities; - - -%release; + + + %release; %sections; Modified: head/release/doc/de_DE.ISO8859-1/readme/article.xml ============================================================================== --- head/release/doc/de_DE.ISO8859-1/readme/article.xml Fri May 17 18:49:43 2013 (r250745) +++ head/release/doc/de_DE.ISO8859-1/readme/article.xml Fri May 17 18:53:29 2013 (r250746) @@ -1,9 +1,8 @@ - - -%entities; - -%release; + + + %release; ]> Modified: head/release/doc/de_DE.ISO8859-1/relnotes/common/new.xml ============================================================================== --- head/release/doc/de_DE.ISO8859-1/relnotes/common/new.xml Fri May 17 18:49:43 2013 (r250745) +++ head/release/doc/de_DE.ISO8859-1/relnotes/common/new.xml Fri May 17 18:53:29 2013 (r250746) @@ -34,13 +34,8 @@ Die Release Notes für &os; &release.current; enthalten eine Übersicht über - - Dieses Dokument enthält die Liste aller Sicherheitshinweise, die seit der letzten Version herausgegeben wurden, sowie eine Übersicht über die wichtigsten Änderungen am @@ -59,9 +54,7 @@ Sie Hinweise für die Aktualisierung Ihres &os;-Systems. -Die &release.type; Distribution, für die diese Release + Die &release.type; Distribution, für die diese Release Notes gültig sind, markiert einen Punkt im Entwicklungszweig &release.branch; zwischen &release.prev; und der zukünftigen Version &release.next;. Sie können einige fertige @@ -69,11 +62,7 @@ entstanden sind, auf finden. -]]> - -Diese Distribution von &os; &release.current; ist eine + Diese Distribution von &os; &release.current; ist eine &release.type; Distribution. Sie können Sie von und allen seinen Mirrors erhalten. Weitere Informationen, wie Sie diese (oder andere) &release.type; @@ -84,8 +73,6 @@ url="http://www.FreeBSD.org/doc/de_DE.ISO8859-1/books/handbook/">FreeBSD Handbuchs. -]]> - Anwender, die noch keine Erfahrung mit einer &release.branch; Version eines &os; &release.type; haben, sollten auf jeden Fall die Hinweise für die ersten Anwender von &os; @@ -111,21 +98,12 @@ Neuerungen In diesem Artikel finden Sie - - Die Einträge umfassen alle Sicherheitshinweise, die nach Modified: head/release/doc/de_DE.ISO8859-1/relnotes/i386/article.xml ============================================================================== --- head/release/doc/de_DE.ISO8859-1/relnotes/i386/article.xml Fri May 17 18:49:43 2013 (r250745) +++ head/release/doc/de_DE.ISO8859-1/relnotes/i386/article.xml Fri May 17 18:53:29 2013 (r250746) @@ -1,9 +1,8 @@ - - -%entities; - -%release; + + + %release; %sections; Modified: head/release/doc/de_DE.ISO8859-1/relnotes/ia64/article.xml ============================================================================== --- head/release/doc/de_DE.ISO8859-1/relnotes/ia64/article.xml Fri May 17 18:49:43 2013 (r250745) +++ head/release/doc/de_DE.ISO8859-1/relnotes/ia64/article.xml Fri May 17 18:53:29 2013 (r250746) @@ -1,9 +1,8 @@ - - -%entities; - -%release; + + + %release; %sections; Modified: head/release/doc/de_DE.ISO8859-1/relnotes/pc98/article.xml ============================================================================== --- head/release/doc/de_DE.ISO8859-1/relnotes/pc98/article.xml Fri May 17 18:49:43 2013 (r250745) +++ head/release/doc/de_DE.ISO8859-1/relnotes/pc98/article.xml Fri May 17 18:53:29 2013 (r250746) @@ -1,9 +1,8 @@ - - -%entities; - -%release; + + + %release; %sections; Modified: head/release/doc/de_DE.ISO8859-1/relnotes/sparc64/article.xml ============================================================================== --- head/release/doc/de_DE.ISO8859-1/relnotes/sparc64/article.xml Fri May 17 18:49:43 2013 (r250745) +++ head/release/doc/de_DE.ISO8859-1/relnotes/sparc64/article.xml Fri May 17 18:53:29 2013 (r250746) @@ -1,9 +1,8 @@ - - -%entities; - -%release; + + + %release; %sections; Modified: head/release/doc/en_US.ISO8859-1/Makefile ============================================================================== --- head/release/doc/en_US.ISO8859-1/Makefile Fri May 17 18:49:43 2013 (r250745) +++ head/release/doc/en_US.ISO8859-1/Makefile Fri May 17 18:53:29 2013 (r250746) @@ -9,5 +9,8 @@ SUBDIR+= errata COMPAT_SYMLINK = en +LANGCODE=en_US.ISO8859-1 +_LANGCODE=en_US.ISO8859-1 + .include "${RELN_ROOT}/share/mk/doc.relnotes.mk" .include "${DOC_PREFIX}/share/mk/doc.project.mk" Modified: head/release/doc/en_US.ISO8859-1/errata/article.xml ============================================================================== --- head/release/doc/en_US.ISO8859-1/errata/article.xml Fri May 17 18:49:43 2013 (r250745) +++ head/release/doc/en_US.ISO8859-1/errata/article.xml Fri May 17 18:53:29 2013 (r250746) @@ -1,20 +1,8 @@ - - -%entities; - - + + %release; - - -]]> - -]]> - -]]> ]> - - - + + + %release; ]>
@@ -64,30 +57,20 @@ It also provides some notes on upgrading from previous versions of &os;. -The &release.type; distribution to which these release notes + The &release.type; distribution to which these release notes apply represents the latest point along the &release.branch; development branch since &release.branch; was created. Information regarding pre-built, binary &release.type; distributions along this branch can be found at . -]]> - -The &release.type; distribution to which these release notes + The &release.type; distribution to which these release notes apply represents a point along the &release.branch; development branch between &release.prev; and the future &release.next;. Information regarding pre-built, binary &release.type; distributions along this branch can be found at . -]]> - -This distribution of &os; &release.current; is a + This distribution of &os; &release.current; is a &release.type; distribution. It can be found at or any of its mirrors. More information on obtaining this (or other) &release.type; @@ -97,8 +80,6 @@ url="&url.books.handbook;/">&os; Handbook. -]]> - All users are encouraged to consult the release errata before installing &os;. The errata document is updated with late-breaking information discovered late in the @@ -494,11 +475,11 @@ the tzdata2008h release to the tzdata2009m release. - The stdtime part of libc, &man.zdump.8 and &man.zic.8 + The stdtime part of libc, &man.zdump.8; and &man.zic.8; have been updated from the tzcode2004a release to the tzcode2009h release. - If you have upgraded from source or via the &man.freebsd-update.8, - then please run &man.tzsetup.8 to install a new /etc/localtime. + If you have upgraded from source or via the &man.freebsd-update.8;, + then please run &man.tzsetup.8; to install a new /etc/localtime. WPA Supplicant has been Modified: head/release/doc/fr_FR.ISO8859-1/early-adopter/article.xml ============================================================================== --- head/release/doc/fr_FR.ISO8859-1/early-adopter/article.xml Fri May 17 18:49:43 2013 (r250745) +++ head/release/doc/fr_FR.ISO8859-1/early-adopter/article.xml Fri May 17 18:53:29 2013 (r250746) @@ -1,9 +1,8 @@ - - -%entities; - -%release; + + + %release; X"> X"> Modified: head/release/doc/fr_FR.ISO8859-1/errata/article.xml ============================================================================== --- head/release/doc/fr_FR.ISO8859-1/errata/article.xml Fri May 17 18:49:43 2013 (r250745) +++ head/release/doc/fr_FR.ISO8859-1/errata/article.xml Fri May 17 18:53:29 2013 (r250746) @@ -1,9 +1,8 @@ - - -%entities; - -%release; + + + %release; ]>