svn commit: r263293 - head/share/man/man4

2014-03-17 Thread Hans Petter Selasky
Author: hselasky
Date: Tue Mar 18 06:52:11 2014
New Revision: 263293
URL: http://svnweb.freebsd.org/changeset/base/263293

Log:
  Add missing umoscom manual page.
  
  Suggested by: Sascha Wildner 
  MFC after:1 week

Added:
  head/share/man/man4/umoscom.4   (contents, props changed)
Modified:
  head/share/man/man4/Makefile

Modified: head/share/man/man4/Makefile
==
--- head/share/man/man4/MakefileTue Mar 18 06:43:21 2014
(r263292)
+++ head/share/man/man4/MakefileTue Mar 18 06:52:11 2014
(r263293)
@@ -525,6 +525,7 @@ MAN=aac.4 \
umcs.4 \
umct.4 \
umodem.4 \
+   umoscom.4 \
ums.4 \
unix.4 \
upgt.4 \

Added: head/share/man/man4/umoscom.4
==
--- /dev/null   00:00:00 1970   (empty, because file is newly added)
+++ head/share/man/man4/umoscom.4   Tue Mar 18 06:52:11 2014
(r263293)
@@ -0,0 +1,66 @@
+.\"
+.\" Copyright (c) 2014 Hans Petter Selasky
+.\" 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 NETBSD FOUNDATION, INC. 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 FOUNDATION 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 March 18, 2014
+.Dt UMOSCOM 4
+.Os
+.Sh NAME
+.Nm umoscom
+.Nd USB support for serial adapters based on chips made by MOSCHIP
+.Sh SYNOPSIS
+To compile this driver into the kernel,
+place the following lines in your
+kernel configuration file:
+.Bd -ragged -offset indent
+.Cd "device usb"
+.Cd "device ucom"
+.Cd "device umoscom"
+.Ed
+.Pp
+Alternatively, to load the driver as a
+module at boot time, place the following line in
+.Xr loader.conf 5 :
+.Bd -literal -offset indent
+umoscom_load="YES"
+.Ed
+.Sh DESCRIPTION
+The
+.Nm
+driver provides support for various serial adapters based on chips from 
MOSCHIP.
+.Pp
+The device is accessed through the
+.Xr ucom 4
+driver which makes it behave like a
+.Xr tty 4 .
+.Sh SEE ALSO
+.Xr tty 4 ,
+.Xr ucom 4 ,
+.Xr usb 4
+.Sh HISTORY
+The
+.Nm
+driver appeared in OpenBSD and was ported to FreeBSD.
___
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-unsubscr...@freebsd.org"


svn commit: r263292 - head/share/man/man4

2014-03-17 Thread Hans Petter Selasky
Author: hselasky
Date: Tue Mar 18 06:43:21 2014
New Revision: 263292
URL: http://svnweb.freebsd.org/changeset/base/263292

Log:
  Correctly name USB template manual page and install it by default.
  
  Suggested by: Sascha Wildner 
  MFC after:1 week

Added:
  head/share/man/man4/usb_template.4
 - copied unchanged from r263291, head/share/man/man4/usb2_template.4
Deleted:
  head/share/man/man4/usb2_template.4
Modified:
  head/share/man/man4/Makefile

Modified: head/share/man/man4/Makefile
==
--- head/share/man/man4/MakefileTue Mar 18 06:41:17 2014
(r263291)
+++ head/share/man/man4/MakefileTue Mar 18 06:43:21 2014
(r263292)
@@ -536,6 +536,7 @@ MAN=aac.4 \
urtwn.4 \
urtwnfw.4 \
usb.4 \
+   usb_template.4 \
usb_quirk.4 \
uslcom.4 \
utopia.4 \

Copied: head/share/man/man4/usb_template.4 (from r263291, 
head/share/man/man4/usb2_template.4)
==
--- /dev/null   00:00:00 1970   (empty, because file is newly added)
+++ head/share/man/man4/usb_template.4  Tue Mar 18 06:43:21 2014
(r263292, copy of r263291, head/share/man/man4/usb2_template.4)
@@ -0,0 +1,83 @@
+.\" $FreeBSD$
+.\"
+.\" Copyright (c) 2008 Hans Petter Selasky. 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.
+.\"
+.Dd March 18, 2014
+.Dt USB_TEMPLATE 4
+.Os
+.
+.Sh NAME
+.
+.
+.Nm usb_template
+.
+.Nd "USB templates"
+.
+.
+.Sh SYNOPSIS
+To compile this module into the kernel, place the following line in
+your kernel configuration file:
+.Bd -ragged -offset indent
+.Cd "device usb_template"
+.Ed
+.Pp
+To load the module at boot time, place the following line in
+.Xr loader.conf 5 :
+.Bd -literal -offset indent
+usb_template_load="YES"
+.Ed
+.
+.Sh DESCRIPTION
+The
+.Nm
+module implements various USB templates that are needed when
+programming an USB device side driver.
+.
+A USB template consists of an USB device descriptor, one or more USB
+configuration descriptors, one or more USB interface descriptors, one
+or more USB endpoint descriptors, USB strings and additional USB
+descriptors.
+.
+The USB template module currently has templates for USB Mass Storage,
+USB CDC Ethernet and Message Transfer Protocol.
+.
+USB templates are currently selected using the "hw.usb.template"
+sysctl.
+.
+The "hw.usb.template" value can be changed at any time, but will not
+have any effect until the USB device has been re-enumerated.
+.
+.
+.
+.Sh SEE ALSO
+.Xr usb 4
+.Sh STANDARDS
+The
+.Nm
+module complies to the USB 1.0, 2.0 and 3.0 standard.
+.Sh HISTORY
+The
+.Nm
+module was written by
+.An Hans Petter Selasky Aq hsela...@freebsd.org .
___
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-unsubscr...@freebsd.org"


svn commit: r263291 - head/share/man/man4

2014-03-17 Thread Hans Petter Selasky
Author: hselasky
Date: Tue Mar 18 06:41:17 2014
New Revision: 263291
URL: http://svnweb.freebsd.org/changeset/base/263291

Log:
  Update USB template manual page.
  
  MFC after:1 week

Modified:
  head/share/man/man4/usb2_template.4

Modified: head/share/man/man4/usb2_template.4
==
--- head/share/man/man4/usb2_template.4 Tue Mar 18 02:49:28 2014
(r263290)
+++ head/share/man/man4/usb2_template.4 Tue Mar 18 06:41:17 2014
(r263291)
@@ -23,14 +23,14 @@
 .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
 .\" SUCH DAMAGE.
 .\"
-.Dd September 21, 2008
-.Dt USB2_TEMPLATE 4
+.Dd March 18, 2014
+.Dt USB_TEMPLATE 4
 .Os
 .
 .Sh NAME
 .
 .
-.Nm usb2_template
+.Nm usb_template
 .
 .Nd "USB templates"
 .
@@ -39,13 +39,13 @@
 To compile this module into the kernel, place the following line in
 your kernel configuration file:
 .Bd -ragged -offset indent
-.Cd "device usb2_template"
+.Cd "device usb_template"
 .Ed
 .Pp
 To load the module at boot time, place the following line in
 .Xr loader.conf 5 :
 .Bd -literal -offset indent
-usb2_template_load="YES"
+usb_template_load="YES"
 .Ed
 .
 .Sh DESCRIPTION
@@ -62,21 +62,20 @@ descriptors.
 The USB template module currently has templates for USB Mass Storage,
 USB CDC Ethernet and Message Transfer Protocol.
 .
-USB templates are currently selected using the "hw.usb2.template"
+USB templates are currently selected using the "hw.usb.template"
 sysctl.
 .
-The "hw.usb2.template" value can be changed at any time, but will not
+The "hw.usb.template" value can be changed at any time, but will not
 have any effect until the USB device has been re-enumerated.
 .
 .
 .
 .Sh SEE ALSO
-.Xr usb2_controller 4
-.Xr usb2_core 4
+.Xr usb 4
 .Sh STANDARDS
 The
 .Nm
-module complies with the USB 2.0 standard.
+module complies to the USB 1.0, 2.0 and 3.0 standard.
 .Sh HISTORY
 The
 .Nm
___
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-unsubscr...@freebsd.org"


svn commit: r263290 - head/sys/amd64/vmm

2014-03-17 Thread Neel Natu
Author: neel
Date: Tue Mar 18 02:49:28 2014
New Revision: 263290
URL: http://svnweb.freebsd.org/changeset/base/263290

Log:
  When a vcpu is deactivated it must also unblock any rendezvous that may be
  blocked on it.
  
  This is done by issuing a wakeup after clearing the 'vcpuid' from 
'active_cpus'.
  Also, use CPU_CLR_ATOMIC() to guarantee visibility of the updated 
'active_cpus'
  across all host cpus.

Modified:
  head/sys/amd64/vmm/vmm.c

Modified: head/sys/amd64/vmm/vmm.c
==
--- head/sys/amd64/vmm/vmm.cTue Mar 18 01:40:25 2014(r263289)
+++ head/sys/amd64/vmm/vmm.cTue Mar 18 02:49:28 2014(r263290)
@@ -130,7 +130,7 @@ struct vm {
 * An active vcpu is one that has been started implicitly (BSP) or
 * explicitly (AP) by sending it a startup ipi.
 */
-   cpuset_tactive_cpus;
+   volatile cpuset_t active_cpus;
 
struct mtx  rendezvous_mtx;
cpuset_trendezvous_req_cpus;
@@ -969,8 +969,12 @@ vm_handle_rendezvous(struct vm *vm, int 
 
mtx_lock(&vm->rendezvous_mtx);
while (vm->rendezvous_func != NULL) {
+   /* 'rendezvous_req_cpus' must be a subset of 'active_cpus' */
+   CPU_AND(&vm->rendezvous_req_cpus, &vm->active_cpus);
+
if (vcpuid != -1 &&
-   CPU_ISSET(vcpuid, &vm->rendezvous_req_cpus)) {
+   CPU_ISSET(vcpuid, &vm->rendezvous_req_cpus) &&
+   !CPU_ISSET(vcpuid, &vm->rendezvous_done_cpus)) {
VCPU_CTR0(vm, vcpuid, "Calling rendezvous func");
(*vm->rendezvous_func)(vm, vcpuid, vm->rendezvous_arg);
CPU_SET(vcpuid, &vm->rendezvous_done_cpus);
@@ -997,9 +1001,10 @@ vm_handle_hlt(struct vm *vm, int vcpuid,
 {
struct vm_exit *vmexit;
struct vcpu *vcpu;
-   int t, timo;
+   int t, timo, spindown;
 
vcpu = &vm->vcpu[vcpuid];
+   spindown = 0;
 
vcpu_lock(vcpu);
 
@@ -1026,17 +1031,25 @@ vm_handle_hlt(struct vm *vm, int vcpuid,
 * Spindown the vcpu if the apic is disabled and it
 * had entered the halted state.
 */
-   *retu = true;
-   vmexit = vm_exitinfo(vm, vcpuid);
-   vmexit->exitcode = VM_EXITCODE_SPINDOWN_CPU;
-   vm_deactivate_cpu(vm, vcpuid);
-   VCPU_CTR0(vm, vcpuid, "spinning down cpu");
+   spindown = 1;
}
vcpu_require_state_locked(vcpu, VCPU_FROZEN);
vmm_stat_incr(vm, vcpuid, VCPU_IDLE_TICKS, ticks - t);
}
vcpu_unlock(vcpu);
 
+   /*
+* Since 'vm_deactivate_cpu()' grabs a sleep mutex we must call it
+* outside the confines of the vcpu spinlock.
+*/
+   if (spindown) {
+   *retu = true;
+   vmexit = vm_exitinfo(vm, vcpuid);
+   vmexit->exitcode = VM_EXITCODE_SPINDOWN_CPU;
+   vm_deactivate_cpu(vm, vcpuid);
+   VCPU_CTR0(vm, vcpuid, "spinning down cpu");
+   }
+
return (0);
 }
 
@@ -1541,16 +1554,37 @@ void
 vm_activate_cpu(struct vm *vm, int vcpuid)
 {
 
-   if (vcpuid >= 0 && vcpuid < VM_MAXCPU)
-   CPU_SET(vcpuid, &vm->active_cpus);
+   KASSERT(vcpuid >= 0 && vcpuid < VM_MAXCPU,
+   ("vm_activate_cpu: invalid vcpuid %d", vcpuid));
+   KASSERT(!CPU_ISSET(vcpuid, &vm->active_cpus),
+   ("vm_activate_cpu: vcpuid %d is already active", vcpuid));
+
+   VCPU_CTR0(vm, vcpuid, "activated");
+   CPU_SET_ATOMIC(vcpuid, &vm->active_cpus);
 }
 
 static void
 vm_deactivate_cpu(struct vm *vm, int vcpuid)
 {
 
-   if (vcpuid >= 0 && vcpuid < VM_MAXCPU)
-   CPU_CLR(vcpuid, &vm->active_cpus);
+   KASSERT(vcpuid >= 0 && vcpuid < VM_MAXCPU,
+   ("vm_deactivate_cpu: invalid vcpuid %d", vcpuid));
+   KASSERT(CPU_ISSET(vcpuid, &vm->active_cpus),
+   ("vm_deactivate_cpu: vcpuid %d is not active", vcpuid));
+
+   VCPU_CTR0(vm, vcpuid, "deactivated");
+   CPU_CLR_ATOMIC(vcpuid, &vm->active_cpus);
+
+   /*
+* If a vcpu rendezvous is in progress then it could be blocked
+* on 'vcpuid' - unblock it before disappearing forever.
+*/
+   mtx_lock(&vm->rendezvous_mtx);
+   if (vm->rendezvous_func != NULL) {
+   VCPU_CTR0(vm, vcpuid, "unblock rendezvous after deactivation");
+   wakeup(&vm->rendezvous_func);
+   }
+   mtx_unlock(&vm->rendezvous_mtx);
 }
 
 cpuset_t
___
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-unsubscr...@freebsd.org"


svn commit: r263289 - in head: contrib/file contrib/pf/pflogd contrib/tnftp contrib/vis lib/libedit share/man/man9 sys/compat/svr4 sys/dev/esp sys/dev/le sys/dev/usb/serial sys/mips/cavium sys/mips...

2014-03-17 Thread Ed Maste
Author: emaste
Date: Tue Mar 18 01:40:25 2014
New Revision: 263289
URL: http://svnweb.freebsd.org/changeset/base/263289

Log:
  Update NetBSD Foundation copyrights to 2-clause BSD
  
  The NetBSD Foundation states "Third parties are encouraged to change the
  license on any files which have a 4-clause license contributed to the
  NetBSD Foundation to a 2-clause license."
  
  This change removes clauses 3 and 4 from copyright / license blocks that
  list The NetBSD Foundation as the only copyright holder.
  
  Sponsored by: The FreeBSD Foundation

Modified:
  head/contrib/file/mygetopt.h
  head/contrib/pf/pflogd/pidfile.c
  head/contrib/tnftp/COPYING
  head/contrib/vis/extern.h
  head/lib/libedit/chartype.h
  head/share/man/man9/bus_dma.9
  head/share/man/man9/bus_space.9
  head/sys/compat/svr4/svr4_fuser.h
  head/sys/compat/svr4/svr4_ipc.c
  head/sys/compat/svr4/svr4_resource.c
  head/sys/compat/svr4/svr4_resource.h
  head/sys/dev/esp/ncr53c9xvar.h
  head/sys/dev/le/am7990.c
  head/sys/dev/le/am79900.c
  head/sys/dev/le/am79900reg.h
  head/sys/dev/le/am7990reg.h
  head/sys/dev/le/if_le_isa.c
  head/sys/dev/le/if_le_pci.c
  head/sys/dev/le/lance.c
  head/sys/dev/le/lancereg.h
  head/sys/dev/usb/serial/ubsa.c
  head/sys/dev/usb/serial/ubser.c
  head/sys/dev/usb/serial/uchcom.c
  head/sys/dev/usb/serial/ufoma.c
  head/sys/dev/usb/serial/umodem.c
  head/sys/dev/usb/serial/uplcom.c
  head/sys/dev/usb/serial/usb_serial.c
  head/sys/dev/usb/serial/usb_serial.h
  head/sys/mips/cavium/octopci_bus_space.c
  head/sys/mips/include/bus.h
  head/sys/mips/mips/bus_space_fdt.c
  head/sys/mips/mips/bus_space_generic.c
  head/sys/mips/mips/gdb_machdep.c
  head/sys/powerpc/aim/mmu_oea.c
  head/sys/powerpc/aim/mmu_oea64.c
  head/sys/powerpc/aim/moea64_native.c
  head/sys/powerpc/include/bat.h
  head/sys/powerpc/include/bus.h
  head/sys/sys/bus_dma.h
  head/sys/tools/miidevs2h.awk
  head/sys/tools/pccarddevs2h.awk
  head/sys/x86/include/bus.h

Modified: head/contrib/file/mygetopt.h
==
--- head/contrib/file/mygetopt.hTue Mar 18 01:17:08 2014
(r263288)
+++ head/contrib/file/mygetopt.hTue Mar 18 01:40:25 2014
(r263289)
@@ -15,13 +15,6 @@
  * 2. Redistributions in binary form must reproduce the above copyright
  *notice, this list of conditions and the following disclaimer in the
  *documentation and/or other materials provided with the distribution.
- * 3. All advertising materials mentioning features or use of this software
- *must display the following acknowledgement:
- *This product includes software developed by the NetBSD
- *Foundation, Inc. and its contributors.
- * 4. Neither the name of The NetBSD Foundation nor the names of its
- *contributors may be used to endorse or promote products derived
- *from this software without specific prior written permission.
  *
  * THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND CONTRIBUTORS
  * ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED

Modified: head/contrib/pf/pflogd/pidfile.c
==
--- head/contrib/pf/pflogd/pidfile.cTue Mar 18 01:17:08 2014
(r263288)
+++ head/contrib/pf/pflogd/pidfile.cTue Mar 18 01:40:25 2014
(r263289)
@@ -17,13 +17,6 @@
  * 2. Redistributions in binary form must reproduce the above copyright
  *notice, this list of conditions and the following disclaimer in the
  *documentation and/or other materials provided with the distribution.
- * 3. All advertising materials mentioning features or use of this software
- *must display the following acknowledgement:
- *This product includes software developed by the NetBSD
- *Foundation, Inc. and its contributors.
- * 4. Neither the name of The NetBSD Foundation nor the names of its
- *contributors may be used to endorse or promote products derived
- *from this software without specific prior written permission.
  *
  * THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND CONTRIBUTORS
  * ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED

Modified: head/contrib/tnftp/COPYING
==
--- head/contrib/tnftp/COPYING  Tue Mar 18 01:17:08 2014(r263288)
+++ head/contrib/tnftp/COPYING  Tue Mar 18 01:40:25 2014(r263289)
@@ -14,13 +14,6 @@ are met:
 2. Redistributions in binary form must reproduce the above copyright
notice, this list of conditions and the following disclaimer in the
documentation and/or other materials provided with the distribution.
-3. All advertising materials mentioning features or use of this software
-   must display the following acknowledgement:
-   This product includes software developed by the NetBSD
-   Foundation, Inc. and its contributors.
-4. Neithe

svn commit: r263288 - head/tools/tools/nanobsd

2014-03-17 Thread Bryan Drewery
Author: bdrewery
Date: Tue Mar 18 01:17:08 2014
New Revision: 263288
URL: http://svnweb.freebsd.org/changeset/base/263288

Log:
  Remove comment meant for removal in r263287
  
  X-MFC-with:   263287

Modified:
  head/tools/tools/nanobsd/nanobsd.sh

Modified: head/tools/tools/nanobsd/nanobsd.sh
==
--- head/tools/tools/nanobsd/nanobsd.sh Tue Mar 18 01:14:49 2014
(r263287)
+++ head/tools/tools/nanobsd/nanobsd.sh Tue Mar 18 01:17:08 2014
(r263288)
@@ -809,7 +809,6 @@ cust_pkgng () (
'env ASSUME_ALWAYS_YES=YES /usr/sbin/pkg info | 
/usr/bin/wc -l'`
 
# Attempt to install more packages
-   # limitations.
chroot ${NANO_WORLDDIR} sh -c \
'ls Pkg/*txz | xargs env ASSUME_ALWAYS_YES=YES 
/usr/sbin/pkg add ' || true
 
___
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-unsubscr...@freebsd.org"


svn commit: r263287 - head/tools/tools/nanobsd

2014-03-17 Thread Bryan Drewery
Author: bdrewery
Date: Tue Mar 18 01:14:49 2014
New Revision: 263287
URL: http://svnweb.freebsd.org/changeset/base/263287

Log:
  'pkg(8) add' has no internal restriction on number of packages.
  
  Submitted by: tj
  MFC after:1 week

Modified:
  head/tools/tools/nanobsd/nanobsd.sh

Modified: head/tools/tools/nanobsd/nanobsd.sh
==
--- head/tools/tools/nanobsd/nanobsd.sh Tue Mar 18 01:00:14 2014
(r263286)
+++ head/tools/tools/nanobsd/nanobsd.sh Tue Mar 18 01:14:49 2014
(r263287)
@@ -809,10 +809,9 @@ cust_pkgng () (
'env ASSUME_ALWAYS_YES=YES /usr/sbin/pkg info | 
/usr/bin/wc -l'`
 
# Attempt to install more packages
-   # ...but no more than 200 at a time due to (XXX still the 
case?) pkg_add's internal
# limitations.
chroot ${NANO_WORLDDIR} sh -c \
-   'ls Pkg/*txz | xargs -n 200 env ASSUME_ALWAYS_YES=YES 
/usr/sbin/pkg add ' || true
+   'ls Pkg/*txz | xargs env ASSUME_ALWAYS_YES=YES 
/usr/sbin/pkg add ' || true
 
# See what that got us
now=`chroot ${NANO_WORLDDIR} sh -c \
___
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-unsubscr...@freebsd.org"


svn commit: r263280 - head/sys/amd64/vmm

2014-03-17 Thread Neel Natu
Author: neel
Date: Mon Mar 17 23:30:38 2014
New Revision: 263280
URL: http://svnweb.freebsd.org/changeset/base/263280

Log:
  Notify vcpus participating in the rendezvous of the pending event to ensure
  that they execute the rendezvous function as soon as possible.

Modified:
  head/sys/amd64/vmm/vmm.c

Modified: head/sys/amd64/vmm/vmm.c
==
--- head/sys/amd64/vmm/vmm.cMon Mar 17 23:21:31 2014(r263279)
+++ head/sys/amd64/vmm/vmm.cMon Mar 17 23:30:38 2014(r263280)
@@ -1657,6 +1657,8 @@ void
 vm_smp_rendezvous(struct vm *vm, int vcpuid, cpuset_t dest,
 vm_rendezvous_func_t func, void *arg)
 {
+   int i;
+
/*
 * Enforce that this function is called without any locks
 */
@@ -1687,6 +1689,15 @@ restart:
vm_set_rendezvous_func(vm, func);
mtx_unlock(&vm->rendezvous_mtx);
 
+   /*
+* Wake up any sleeping vcpus and trigger a VM-exit in any running
+* vcpus so they handle the rendezvous as soon as possible.
+*/
+   for (i = 0; i < VM_MAXCPU; i++) {
+   if (CPU_ISSET(i, &dest))
+   vcpu_notify_event(vm, i, false);
+   }
+
vm_handle_rendezvous(vm, vcpuid);
 }
 
___
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-unsubscr...@freebsd.org"


svn commit: r263279 - head/sys/mips/atheros

2014-03-17 Thread Adrian Chadd
Author: adrian
Date: Mon Mar 17 23:21:31 2014
New Revision: 263279
URL: http://svnweb.freebsd.org/changeset/base/263279

Log:
  Implement apb_print_child().
  
  Tested:
  
  * AR9344, Atheros DB120 Reference board

Modified:
  head/sys/mips/atheros/apb.c

Modified: head/sys/mips/atheros/apb.c
==
--- head/sys/mips/atheros/apb.c Mon Mar 17 22:37:17 2014(r263278)
+++ head/sys/mips/atheros/apb.c Mon Mar 17 23:21:31 2014(r263279)
@@ -57,6 +57,8 @@ __FBSDID("$FreeBSD$");
 #define dprintf(x, arg...)
 #endif  /* APB_DEBUG */
 
+#defineDEVTOAPB(dev)   ((struct apb_ivar *) device_get_ivars(dev))
+
 static int apb_activate_resource(device_t, device_t, int, int,
struct resource *);
 static device_tapb_add_child(device_t, u_int, const char *, int);
@@ -477,6 +479,37 @@ apb_get_resource_list(device_t dev, devi
return (&(ivar->resources));
 }
 
+static int
+apb_print_all_resources(device_t dev)
+{
+   struct apb_ivar *ndev = DEVTOAPB(dev);
+   struct resource_list *rl = &ndev->resources;
+   int retval = 0;
+
+   if (STAILQ_FIRST(rl))
+   retval += printf(" at");
+
+   retval += resource_list_print_type(rl, "mem", SYS_RES_MEMORY, "%#lx");
+   retval += resource_list_print_type(rl, "irq", SYS_RES_IRQ, "%ld");
+
+   return (retval);
+}
+
+static int
+apb_print_child(device_t bus, device_t child)
+{
+   int retval = 0;
+
+   retval += bus_print_child_header(bus, child);
+   retval += apb_print_all_resources(child);
+   if (device_get_flags(child))
+   retval += printf(" flags %#x", device_get_flags(child));
+   retval += printf(" on %s\n", device_get_nameunit(bus));
+
+   return (retval);
+}
+
+
 static device_method_t apb_methods[] = {
DEVMETHOD(bus_activate_resource,apb_activate_resource),
DEVMETHOD(bus_add_child,apb_add_child),
@@ -491,6 +524,7 @@ static device_method_t apb_methods[] = {
DEVMETHOD(device_probe, apb_probe),
DEVMETHOD(bus_get_resource, bus_generic_rl_get_resource),
DEVMETHOD(bus_set_resource, bus_generic_rl_set_resource),
+   DEVMETHOD(bus_print_child,  apb_print_child),
 
DEVMETHOD_END
 };
___
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-unsubscr...@freebsd.org"


svn commit: r263278 - head/sys/dev/nvme

2014-03-17 Thread Jim Harris
Author: jimharris
Date: Mon Mar 17 22:37:17 2014
New Revision: 263278
URL: http://svnweb.freebsd.org/changeset/base/263278

Log:
  nvme:  NVMe specification dictates 4-byte alignment for PRPs (not 8).
  
  Sponsored by: Intel
  MFC after:3 days

Modified:
  head/sys/dev/nvme/nvme_qpair.c

Modified: head/sys/dev/nvme/nvme_qpair.c
==
--- head/sys/dev/nvme/nvme_qpair.c  Mon Mar 17 22:36:04 2014
(r263277)
+++ head/sys/dev/nvme/nvme_qpair.c  Mon Mar 17 22:37:17 2014
(r263278)
@@ -498,8 +498,9 @@ nvme_qpair_construct(struct nvme_qpair *
 
mtx_init(&qpair->lock, "nvme qpair lock", NULL, MTX_DEF);
 
+   /* Note: NVMe PRP format is restricted to 4-byte alignment. */
bus_dma_tag_create(bus_get_dma_tag(ctrlr->dev),
-   sizeof(uint64_t), PAGE_SIZE, BUS_SPACE_MAXADDR,
+   4, PAGE_SIZE, BUS_SPACE_MAXADDR,
BUS_SPACE_MAXADDR, NULL, NULL, NVME_MAX_XFER_SIZE,
(NVME_MAX_XFER_SIZE/PAGE_SIZE)+1, PAGE_SIZE, 0,
NULL, NULL, &qpair->dma_tag);
___
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-unsubscr...@freebsd.org"


svn commit: r263277 - head/sys/dev/nvme

2014-03-17 Thread Jim Harris
Author: jimharris
Date: Mon Mar 17 22:36:04 2014
New Revision: 263277
URL: http://svnweb.freebsd.org/changeset/base/263277

Log:
  nvme: Remove the software progress marker SET_FEATURE command during
  controller initialization.
  
  The spec says OS drivers should send this command after controller
  initialization completes successfully, but other NVMe OS drivers are
  not sending this command.  This change will therefore reduce differences
  between the FreeBSD and other OS drivers.
  
  Sponsored by: Intel
  MFC after:3 days

Modified:
  head/sys/dev/nvme/nvme_ctrlr.c

Modified: head/sys/dev/nvme/nvme_ctrlr.c
==
--- head/sys/dev/nvme/nvme_ctrlr.c  Mon Mar 17 22:32:54 2014
(r263276)
+++ head/sys/dev/nvme/nvme_ctrlr.c  Mon Mar 17 22:36:04 2014
(r263277)
@@ -842,16 +842,6 @@ nvme_ctrlr_start(void *ctrlr_arg)
 
for (i = 0; i < ctrlr->num_io_queues; i++)
nvme_io_qpair_enable(&ctrlr->ioq[i]);
-
-   /*
-* Clear software progress marker to 0, to indicate to pre-boot
-*  software that OS driver load was successful.
-*
-* Chatham does not support this feature.
-*/
-   if (pci_get_devid(ctrlr->dev) != CHATHAM_PCI_ID)
-   nvme_ctrlr_cmd_set_feature(ctrlr,
-   NVME_FEAT_SOFTWARE_PROGRESS_MARKER, 0, NULL, 0, NULL, NULL);
 }
 
 void
___
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-unsubscr...@freebsd.org"


svn commit: r263276 - head/sys/dev/isci/scil

2014-03-17 Thread Jim Harris
Author: jimharris
Date: Mon Mar 17 22:32:54 2014
New Revision: 263276
URL: http://svnweb.freebsd.org/changeset/base/263276

Log:
  Base the max number of SG elements on MAXPHYS.
  
  Sponsored by: Intel
  Discussed with:   scottl, emax
  MFC after:3 days

Modified:
  head/sys/dev/isci/scil/sati_util.h
  head/sys/dev/isci/scil/sci_controller_constants.h
  head/sys/dev/isci/scil/sci_util.h
  head/sys/dev/isci/scil/scic_sds_request.h

Modified: head/sys/dev/isci/scil/sati_util.h
==
--- head/sys/dev/isci/scil/sati_util.h  Mon Mar 17 22:30:54 2014
(r263275)
+++ head/sys/dev/isci/scil/sati_util.h  Mon Mar 17 22:32:54 2014
(r263276)
@@ -62,6 +62,8 @@
  *structure data, fill in sense data, etc.
  */
 
+#include 
+
 #include 
 #include 
 
@@ -144,15 +146,6 @@
 #define ATA_MICROCODE_OFFSET_DOWNLOAD0x03
 #define ATA_MICROCODE_DOWNLOAD_SAVE  0x07
 
-#ifndef MIN
-#define MIN(x,y) ((x) < (y) ? (x) : (y))
-#endif
-
-#ifndef MAX
-#define MAX(x,y) ((x) > (y) ? (x) : (y))
-#endif
-
-
 void sati_ata_non_data_command(
void* ata_io,
SATI_TRANSLATOR_SEQUENCE_T  * sequence

Modified: head/sys/dev/isci/scil/sci_controller_constants.h
==
--- head/sys/dev/isci/scil/sci_controller_constants.h   Mon Mar 17 22:30:54 
2014(r263275)
+++ head/sys/dev/isci/scil/sci_controller_constants.h   Mon Mar 17 22:32:54 
2014(r263276)
@@ -54,6 +54,8 @@
 #ifndef _SCI_CONTROLLER_CONSTANTS_H_
 #define _SCI_CONTROLLER_CONSTANTS_H_
 
+#include 
+
 /**
  * @file
  *
@@ -148,8 +150,13 @@ extern "C" {
 /**
  * This constant defines the maximum number of Scatter-Gather Elements
  * to be used by any SCI component.
+ *
+ * Note: number of elements must be an even number, since descriptors
+ * posted to hardware always contain pairs of elements (with second
+ * element set to zeroes if not needed).
  */
-#define SCI_MAX_SCATTER_GATHER_ELEMENTS 130
+#define __MAXPHYS_ELEMENTS ((MAXPHYS / PAGE_SIZE) + 1)
+#define SCI_MAX_SCATTER_GATHER_ELEMENTS  ((__MAXPHYS_ELEMENTS + 1) & ~0x1)
 #endif
 
 #ifndef SCI_MIN_SCATTER_GATHER_ELEMENTS

Modified: head/sys/dev/isci/scil/sci_util.h
==
--- head/sys/dev/isci/scil/sci_util.h   Mon Mar 17 22:30:54 2014
(r263275)
+++ head/sys/dev/isci/scil/sci_util.h   Mon Mar 17 22:32:54 2014
(r263276)
@@ -54,20 +54,14 @@
 #ifndef _SCI_UTIL_H_
 #define _SCI_UTIL_H_
 
+#include 
+
 #include 
 
 #ifndef ARRAY_SIZE
 #define ARRAY_SIZE(x) (sizeof(x) / sizeof((x)[0]))
 #endif
 
-#ifndef MIN
-#define MIN(x,y) ((x) < (y) ? (x) : (y))
-#endif
-
-#ifndef MAX
-#define MAX(x,y) ((x) > (y) ? (x) : (y))
-#endif
-
 /**
  * Normal byte swap macro
  */

Modified: head/sys/dev/isci/scil/scic_sds_request.h
==
--- head/sys/dev/isci/scil/scic_sds_request.h   Mon Mar 17 22:30:54 2014
(r263275)
+++ head/sys/dev/isci/scil/scic_sds_request.h   Mon Mar 17 22:32:54 2014
(r263276)
@@ -65,6 +65,8 @@
 extern "C" {
 #endif // __cplusplus
 
+#include 
+
 #include 
 
 #include 
@@ -331,7 +333,6 @@ extern SCIC_SDS_IO_REQUEST_STATE_HANDLER
 #define scic_sds_request_get_task_context(request) \
((request)->task_context_buffer)
 
-#define CACHE_LINE_SIZE (64)
 #define scic_sds_request_align_task_context_buffer(address) \
((SCU_TASK_CONTEXT_T *)( \
(((POINTER_UINT)(address)) + (CACHE_LINE_SIZE - 1)) \
___
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-unsubscr...@freebsd.org"


svn commit: r263275 - head/sys/dev/isci/scil

2014-03-17 Thread Jim Harris
Author: jimharris
Date: Mon Mar 17 22:30:54 2014
New Revision: 263275
URL: http://svnweb.freebsd.org/changeset/base/263275

Log:
  isci: Ensure ATA passthrough commands with RETURN_RESPONSE bit set
  translate their response.
  
  Sponsored by: Intel
  Discussed with:   scottl
  MFC after:3 days

Modified:
  head/sys/dev/isci/scil/sati_passthrough.c

Modified: head/sys/dev/isci/scil/sati_passthrough.c
==
--- head/sys/dev/isci/scil/sati_passthrough.c   Mon Mar 17 21:45:08 2014
(r263274)
+++ head/sys/dev/isci/scil/sati_passthrough.c   Mon Mar 17 22:30:54 2014
(r263275)
@@ -441,6 +441,13 @@ SATI_STATUS sati_passthrough_16_translat
   sati_set_ata_lba_mid_exp(register_fis, sati_get_cdb_byte(cdb, 9));
   sati_set_ata_lba_high_exp(register_fis, sati_get_cdb_byte(cdb, 11));
}
+
+   if (PASSTHROUGH_CDB_CK_COND(cdb) ||
+   PASSTHROUGH_CDB_PROTOCOL(cdb) == PASSTHROUGH_RETURN_RESPONSE)
+   {
+  sequence->is_translate_response_required = TRUE;
+   }
+
sati_set_ata_features(register_fis, sati_get_cdb_byte(cdb, 4));
sati_set_ata_sector_count(register_fis, sati_get_cdb_byte(cdb, 6));
sati_set_ata_lba_low(register_fis, sati_get_cdb_byte(cdb, 8));
@@ -483,6 +490,8 @@ SATI_STATUS sati_passthrough_translate_r
   return SATI_FAILURE_CHECK_RESPONSE_DATA;
}
 
+   sequence->state = SATI_SEQUENCE_STATE_FINAL;
+
// If the user set the check condition bit, fill out the sense data
if (PASSTHROUGH_CDB_CK_COND(cdb) ||
PASSTHROUGH_CDB_PROTOCOL(cdb) == PASSTHROUGH_RETURN_RESPONSE)
@@ -496,10 +505,9 @@ SATI_STATUS sati_passthrough_translate_r
  SCSI_ASC_NO_ADDITIONAL_SENSE,
  SCSI_ASCQ_ATA_PASS_THROUGH_INFORMATION_AVAILABLE
   );
+  return SATI_FAILURE_CHECK_RESPONSE_DATA;
}
 
-   sequence->state = SATI_SEQUENCE_STATE_FINAL;
-
return SATI_COMPLETE;
 }
 
___
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-unsubscr...@freebsd.org"


Re: svn commit: r263198 - in head/sys: amd64/conf conf net netinet netinet6 sys

2014-03-17 Thread Adrian Chadd
On 17 March 2014 01:26, Robert N. M. Watson  wrote:
>
> On 17 Mar 2014, at 07:54, David Malone  wrote:
>
>>>  (1) Merge a software implementation of the Toeplitz hash specified in
>>>  RSS implemented by David Malone.  This is used to allow suitable
>>>  pcbgroup placement of connections before the first packet is
>>>  received from the NIC.  Software hashing is generally avoided,
>>>  however, due to high cost of the hash on general-purpose CPUs.
>>
>> I could look at a faster software implementation, but I guess most of
>> the value is when hashing is done on the NIC.
>
> In my benchmarking (a couple of years ago) the software path never really 
> turned up a lot. If you end up with a flow migrating from an RSS NIC to a 
> non-RSS NIC, you fall back on the 'reservation' hash table, using the 
> conventional hash and picking up contention, but you don't end up doing the 
> software version of Toeplitz per-packet. The only reason we need a software 
> implementation (currently) is to do an initial placement of a new outbound 
> flow into the hash table prior to receiving a packet with the 
> hardware-generated hash on it. For the inbound direction, we can pick it up 
> from the first packet. (Although, actually, we also need to do it for inbound 
> flows that come from non-RSS NICs -- or localhost or such).

If it's done right, then yes, we should only see a per-packet RSS hash on:

* NICs / paths that don't do it in hardware on the receive side;
* Doing per-packet sanity checking - ie, doing a software RSS as well
as the hardware RSS in order to verify that they both line up.

I plan on adding the latter at some point soon so we can ensure that
things end up on the right queue.

For higher connection rate workloads, we want to ensure that the
initial hash selection for outbound matches the inbound, as we don't
want to be grabbing non-local-CPU locks to migrate connections to
other pcbgroups after they've been established. We absolutely want to
keep things on the local CPU as much as we can.

Thanks!


-a
___
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-unsubscr...@freebsd.org"


svn commit: r263271 - head/share/man/man9

2014-03-17 Thread Alan Somers
Author: asomers
Date: Mon Mar 17 19:55:27 2014
New Revision: 263271
URL: http://svnweb.freebsd.org/changeset/base/263271

Log:
  share/man/man9/counter.9
Fix logic error in the description of counter_u64_alloc: the command
may fail only if M_NOWAIT is specified, not M_WAITOK.
  
  Reviewed by:  glebius
  MFC after:2 weeks
  Sponsored by: Spectra Logic Corporation

Modified:
  head/share/man/man9/counter.9

Modified: head/share/man/man9/counter.9
==
--- head/share/man/man9/counter.9   Mon Mar 17 19:09:39 2014
(r263270)
+++ head/share/man/man9/counter.9   Mon Mar 17 19:55:27 2014
(r263271)
@@ -91,7 +91,7 @@ wait flag, should be either
 or
 .Va M_WAITOK .
 If
-.Va M_WAITOK
+.Va M_NOWAIT
 is specified the operation may fail.
 .It Fn counter_u64_free c
 Free the previously allocated counter
___
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-unsubscr...@freebsd.org"


Re: svn commit: r262810 - in head: release release/arm release/tools share/man/man7

2014-03-17 Thread Stacey Son

On Mar 6, 2014, at 11:50 AM, David Chisnall  wrote:

> 
> On 6 Mar 2014, at 17:47, Glen Barber  wrote:
> 
>> On Thu, Mar 06, 2014 at 04:37:11PM +, David Chisnall wrote:
>>> On 5 Mar 2014, at 23:17, Glen Barber  wrote:
>>> 
 After several months of testing and fixing (and breaking)
 various parts of release/release.sh changes, it is now
 possible to build FreeBSD/arm images as part of the release
 process.
>>> 
>>> That's great!  How much effort would it be to add QEMU images for
>>> ARM and MIPS images to the things that we build by default?  I'd
>>> love to see these built for ARM and MIPS as part of the Jenkins
>>> builds and for releases.
>>> 
>> 
>> It should be fairly trivial, however I've never had luck getting qemu to
>> run non-x86 images.  Maybe I am doing it wrong, though.
> 
> Stacey may be able to help there.  I think he did some FreeBSD/MIPS-on-QEMU 
> testing with the system emulation mode before working on the user-mode 
> emulation.

Hi All,

Sorry I have been in South American for about the last 11 days and away from 
internet (mostly).  

As for Qemu System-Mode emulation the following wiki page works for MIPS...

https://wiki.freebsd.org/FreeBSD/MipsEmulation

I have not tried system-mode emulation for ARM but I have built a number of 
ports using qemu user-mode (using my rather large patch) for that arch.

-stacey.


___
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-unsubscr...@freebsd.org"


svn commit: r263268 - head/sys/dev/xen/console

2014-03-17 Thread Roger Pau Monné
Author: royger
Date: Mon Mar 17 16:45:28 2014
New Revision: 263268
URL: http://svnweb.freebsd.org/changeset/base/263268

Log:
  xen: fix usage of db_active in xen console
  
  Replace usage of db_active in Xen console with kdb_active.
  
  Reported by: Andrzej Tobola 
  Approved by: gibbs
  Sponsored by: Citrix Systems R&D

Modified:
  head/sys/dev/xen/console/console.c

Modified: head/sys/dev/xen/console/console.c
==
--- head/sys/dev/xen/console/console.c  Mon Mar 17 16:10:42 2014
(r263267)
+++ head/sys/dev/xen/console/console.c  Mon Mar 17 16:45:28 2014
(r263268)
@@ -247,13 +247,12 @@ xc_cnputc(struct consdev *dev, int c)
xc_cnputc_domu(dev, c);
 }
 
-extern int db_active;
 static boolean_t
 xcons_putc(int c)
 {
int force_flush = xc_mute ||
 #ifdef DDB
-   db_active ||
+   kdb_active ||
 #endif
panicstr;   /* we're not gonna recover, so force
 * flush 
___
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-unsubscr...@freebsd.org"


Re: svn commit: r263140 - in head: . contrib/mdocml etc etc/defaults etc/mtree etc/rc.d gnu/usr.bin/groff/tmac include lib lib/libipx release/picobsd/bridge release/picobsd/qemu rescue/rescue sbin/ifc

2014-03-17 Thread Slawa Olhovchenkov
On Fri, Mar 14, 2014 at 02:58:48AM +, Gleb Smirnoff wrote:

> Author: glebius
> Date: Fri Mar 14 02:58:48 2014
> New Revision: 263140
> URL: http://svnweb.freebsd.org/changeset/base/263140
> 
> Log:
>   Remove IPX support.
>   
>   IPX was a network transport protocol in Novell's NetWare network operating
>   system from late 80s and then 90s. The NetWare itself switched to TCP/IP
>   as default transport in 1998. Later, in this century the Novell Open
>   Enterprise Server became successor of Novell NetWare. The last release
>   that claimed to still support IPX was OES 2 in 2007. Routing equipment
>   vendors (e.g. Cisco) discontinued support for IPX in 2011.

Just for truth: Cisco don't fully discontinued support for IPX in 2011.
In 2011 Cisco discontinued support for IPX only in selected software
lines: 15.1(3)S, 15.2(2)T, 15.1(1)SY, 15.2(1)E, and later.

12.4  supported to January 31, 2016
12.4T supported to November 30, 2016
15.0M supported to April 30, 2017
15.0S don't have EoL/EoS notice
15.1M supported to March 31, 2018
15.2M don't have EoL/EoS notice
15.3M don't have EoL/EoS notice

___
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-unsubscr...@freebsd.org"


svn commit: r263267 - head/sys/boot/uboot/common

2014-03-17 Thread Ian Lepore
Author: ian
Date: Mon Mar 17 16:10:42 2014
New Revision: 263267
URL: http://svnweb.freebsd.org/changeset/base/263267

Log:
  Cosmetic changes to printed output, mostly related to probing devices...
  
   - Display slice and partition as  instead of 0 or -1 when they're
 not set to specific values (the paritition=-1 was confusing folks).
   - When loaderdev isn't set in the u-boot environment, say so rather
 than displaying unknown device ''.
   - Print the loader(8) ident/version info earlier, so that all device-
 related info appears together afterwards.
  
  The one change here that isn't purely cosmetic is to call setheap()
  earlier.  The comment says "Initialise heap as early as possible", now
  that's more accurate.  It shouldn't make any functional difference, but
  may be safer if future changes lead to trying to allocate memory earlier.

Modified:
  head/sys/boot/uboot/common/main.c

Modified: head/sys/boot/uboot/common/main.c
==
--- head/sys/boot/uboot/common/main.c   Mon Mar 17 14:19:42 2014
(r263266)
+++ head/sys/boot/uboot/common/main.c   Mon Mar 17 16:10:42 2014
(r263267)
@@ -128,7 +128,7 @@ meminfo(void)
for (i = 0; i < 3; i++) {
size = memsize(si, t[i]);
if (size > 0)
-   printf("%s:\t %lldMB\n", ub_mem_type(t[i]),
+   printf("%s: %lldMB\n", ub_mem_type(t[i]),
size / 1024 / 1024);
}
 }
@@ -198,18 +198,20 @@ get_load_device(int *type, int *unit, in
const char *p;
char *endp;
 
-   devstr = ub_env_get("loaderdev");
-   if (devstr == NULL)
-   devstr = "";
-   else
-   printf("U-Boot setting: loaderdev=%s\n", devstr);
-
-   p = get_device_type(devstr, type);
-
+   *type = -1;
*unit = -1;
*slice = 0;
*partition = -1;
 
+   devstr = ub_env_get("loaderdev");
+   if (devstr == NULL) {
+   printf("U-Boot env: loaderdev not set, will probe all 
devices.\n");
+   return;
+   }
+   printf("U-Boot env: loaderdev='%s'\n", devstr);
+
+   p = get_device_type(devstr, type);
+
/*
 * Empty device string, or unknown device name, or a bare, known 
 * device name. 
@@ -297,6 +299,27 @@ get_load_device(int *type, int *unit, in
*partition = -1;
 } 
 
+static void
+print_disk_probe_info()
+{
+   char slice[32];
+   char partition[32];
+
+   if (currdev.d_disk.slice > 0)
+   sprintf(slice, "%d", currdev.d_disk.slice);
+   else
+   strcpy(slice, "");
+
+   if (currdev.d_disk.partition > 0)
+   sprintf(partition, "%d", currdev.d_disk.partition);
+   else
+   strcpy(partition, "");
+
+   printf("  Checking unit=%d slice=%s partition=%s...",
+   currdev.d_unit, slice, partition);
+
+}
+
 static int
 probe_disks(int devidx, int load_type, int load_unit, int load_slice, 
 int load_partition)
@@ -311,13 +334,11 @@ probe_disks(int devidx, int load_type, i
open_result = -1;
 
if (load_type == -1) {
-   printf("Probing all storage devices...\n");
+   printf("  Probing all disk devices...\n");
/* Try each disk in succession until one works.  */
for (currdev.d_unit = 0; currdev.d_unit < UB_MAX_DEV;
 currdev.d_unit++) {
-   printf("Checking unit=%d slice=%d partition=%d...",
-   currdev.d_unit, currdev.d_disk.slice, 
-   currdev.d_disk.partition);
+   print_disk_probe_info();
open_result = devsw[devidx]->dv_open(&f, &currdev);
if (open_result == 0) {
printf(" good.\n");
@@ -329,15 +350,13 @@ probe_disks(int devidx, int load_type, i
}
 
if (load_unit == -1) {
-   printf("Probing all %s devices...\n", 
device_typename(load_type));
+   printf("  Probing all %s devices...\n", 
device_typename(load_type));
/* Try each disk of given type in succession until one works. */
for (unit = 0; unit < UB_MAX_DEV; unit++) {
currdev.d_unit = uboot_diskgetunit(load_type, unit);
if (currdev.d_unit == -1)
break;
-   printf("Checking unit=%d slice=%d partition=%d...",
-   currdev.d_unit, currdev.d_disk.slice, 
-   currdev.d_disk.partition);
+   print_disk_probe_info();
open_result = devsw[devidx]->dv_open(&f, &currdev);
if (open_result == 0) {
printf(" good.\n");
@@ -349,18 +368,16 @@ probe_disks(int devidx, int load_typ

svn commit: r263266 - head/usr.sbin/jail

2014-03-17 Thread Robert Watson
Author: rwatson
Date: Mon Mar 17 14:19:42 2014
New Revision: 263266
URL: http://svnweb.freebsd.org/changeset/base/263266

Log:
  Line-wrapping tweak: make the sample jail command line fit in 80 characters.
  
  MFC after:3 days

Modified:
  head/usr.sbin/jail/jail.8

Modified: head/usr.sbin/jail/jail.8
==
--- head/usr.sbin/jail/jail.8   Mon Mar 17 13:54:53 2014(r263265)
+++ head/usr.sbin/jail/jail.8   Mon Mar 17 14:19:42 2014(r263266)
@@ -898,8 +898,9 @@ or for running a virtual server.
 .Pp
 Start a shell in the jail:
 .Bd -literal -offset indent
-jail -c path=/data/jail/testjail mount.devfs host.hostname=testhostname \\
-   ip4.addr=192.0.2.100 command=/bin/sh
+jail -c path=/data/jail/testjail mount.devfs \\
+   host.hostname=testhostname ip4.addr=192.0.2.100 \\
+   command=/bin/sh
 .Ed
 .Pp
 Assuming no errors, you will end up with a shell prompt within the jail.
___
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-unsubscr...@freebsd.org"


svn commit: r263265 - head/sys/boot/uboot/common

2014-03-17 Thread Ian Lepore
Author: ian
Date: Mon Mar 17 13:54:53 2014
New Revision: 263265
URL: http://svnweb.freebsd.org/changeset/base/263265

Log:
  Fix the paren nesting so that the network device is probed if the load
  device type is either network or wildcard.

Modified:
  head/sys/boot/uboot/common/main.c

Modified: head/sys/boot/uboot/common/main.c
==
--- head/sys/boot/uboot/common/main.c   Mon Mar 17 11:58:48 2014
(r263264)
+++ head/sys/boot/uboot/common/main.c   Mon Mar 17 13:54:53 2014
(r263265)
@@ -446,8 +446,8 @@ main(void)
break;
}
 
-   if (load_type == -1 || ((load_type & DEV_TYP_NET) &&
-   strcmp(devsw[i]->dv_name, "net") == 0))
+   if ((load_type == -1 || (load_type & DEV_TYP_NET)) &&
+   strcmp(devsw[i]->dv_name, "net") == 0)
break;
}
 
___
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-unsubscr...@freebsd.org"


Re: svn commit: r263264 - head/usr.bin/talk

2014-03-17 Thread Gleb Smirnoff
On Mon, Mar 17, 2014 at 11:58:49AM +, Gleb Smirnoff wrote:
T> Author: glebius
T> Date: Mon Mar 17 11:58:48 2014
T> New Revision: 263264
T> URL: http://svnweb.freebsd.org/changeset/base/263264
T> 
T> Log:
T>   Make talk(1) capable of displaying UTF-8 characters.

NB: the network talk protocol is a protocol originating from 4.3BSD, 
that never underwent any standardization. It consists of the talkd(8) 
daemon, that runs via inetd(8) and initiates a talk session between 
remote users, and the talk(1) utility that displays the actual chatting 
session.

The session initialization is defined as protocol in

/usr/include/protocols/talkd.h

The protocol even has version field, so can be carefully extended.

However, nothing is said about contents of the stream session
established. Apparently, original authors didn't care about locale
awareness of the utility.

I decided not to touch the protocol version. Here are my reasons:

1) The signalling protocol didn't change. Only stream session, which
   isn't defined.

2) I doubt anyone in modern world runs talk(1) over a network wider
   than 127.0.0.0/8. Moreover, only extremely old fashioned geeks run
   it at all.

3) The interoperability isn't broken at all, it is only extended. If
   both sides of session run same locale, they communicate correctly.
   Plain ASCII or KOI8-R work as they did before.

-- 
Totus tuus, Glebius.
___
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-unsubscr...@freebsd.org"


svn commit: r263264 - head/usr.bin/talk

2014-03-17 Thread Gleb Smirnoff
Author: glebius
Date: Mon Mar 17 11:58:48 2014
New Revision: 263264
URL: http://svnweb.freebsd.org/changeset/base/263264

Log:
  Make talk(1) capable of displaying UTF-8 characters.
  
  Sponsored by: Nginx, Inc.

Modified:
  head/usr.bin/talk/Makefile
  head/usr.bin/talk/display.c
  head/usr.bin/talk/io.c
  head/usr.bin/talk/talk.h

Modified: head/usr.bin/talk/Makefile
==
--- head/usr.bin/talk/Makefile  Mon Mar 17 09:01:01 2014(r263263)
+++ head/usr.bin/talk/Makefile  Mon Mar 17 11:58:48 2014(r263264)
@@ -4,7 +4,7 @@
 PROG=  talk
 SRCS=  ctl.c ctl_transact.c display.c get_addrs.c get_iface.c get_names.c \
init_disp.c invite.c io.c look_up.c msgs.c talk.c
-DPADD= ${LIBCURSES}
-LDADD= -lcurses
+DPADD= ${LIBCURSESW}
+LDADD= -lcursesw
 
 .include 

Modified: head/usr.bin/talk/display.c
==
--- head/usr.bin/talk/display.c Mon Mar 17 09:01:01 2014(r263263)
+++ head/usr.bin/talk/display.c Mon Mar 17 11:58:48 2014(r263264)
@@ -41,9 +41,14 @@ static const char sccsid[] = "@(#)displa
  */
 #include 
 #include 
+#include 
+#define _XOPEN_SOURCE_EXTENDED
+#include 
 
 #include "talk.h"
 
+void   display(xwin_t *, wchar_t *);
+
 xwin_t my_win;
 xwin_t his_win;
 WINDOW *line_win;
@@ -61,111 +66,130 @@ max(int a, int b)
return (a > b ? a : b);
 }
 
+static cchar_t *
+makecchar(wchar_t in)
+{
+   static cchar_t cc;
+   wchar_t wc[2];
+
+   wc[0] = in;
+   wc[1] = L'\0';
+
+   if (setcchar(&cc, wc, A_NORMAL, 0, NULL) != OK)
+   p_error("settchar(3) failure");
+
+   return (&cc);
+}
+
 /*
- * Display some text on somebody's window, processing some control
+ * Display a symbol on somebody's window, processing some control
  * characters while we are at it.
  */
 void
-display(xwin_t *win, char *text, int size)
+display(xwin_t *win, wchar_t *wc)
 {
-   int i;
-   char cch;
 
-   for (i = 0; i < size; i++) {
-   if (*text == '\n' || *text == '\r') {
-   waddch(win->x_win, '\n');
-   getyx(win->x_win, win->x_line, win->x_col);
-   text++;
-   continue;
-   }
-   if (*text == 004 && win == &my_win) {
-   /* control-D clears the screen */
+   /*
+* Alas, can't use variables in C switch statement.
+* Workaround these 3 cases with goto.
+*/
+   if (*wc == win->kill)
+   goto kill;
+   else if (*wc == win->cerase)
+   goto cerase;
+   else if (*wc == win->werase)
+   goto werase;
+
+   switch (*wc) {
+   case L'\n':
+   case L'\r':
+   wadd_wch(win->x_win, makecchar(L'\n'));
+   getyx(win->x_win, win->x_line, win->x_col);
+   wrefresh(win->x_win);
+   return;
+
+   case 004:
+   if (win == &my_win) {
+   /* Ctrl-D clears the screen. */
werase(my_win.x_win);
getyx(my_win.x_win, my_win.x_line, my_win.x_col);
wrefresh(my_win.x_win);
werase(his_win.x_win);
getyx(his_win.x_win, his_win.x_line, his_win.x_col);
wrefresh(his_win.x_win);
-   text++;
-   continue;
}
+   return;
 
-   /* erase character */
-   if (   *text == win->cerase
-   || *text == 010 /* BS */
-   || *text == 0177/* DEL */
-  ) {
-   wmove(win->x_win, win->x_line, max(--win->x_col, 0));
-   getyx(win->x_win, win->x_line, win->x_col);
-   waddch(win->x_win, ' ');
-   wmove(win->x_win, win->x_line, win->x_col);
-   getyx(win->x_win, win->x_line, win->x_col);
-   text++;
-   continue;
-   }
+   /* Erase character. */
+   case 010:   /* BS */
+   case 0177:  /* DEL */
+cerase:
+   wmove(win->x_win, win->x_line, max(--win->x_col, 0));
+   getyx(win->x_win, win->x_line, win->x_col);
+   waddch(win->x_win, ' ');
+   wmove(win->x_win, win->x_line, win->x_col);
+   getyx(win->x_win, win->x_line, win->x_col);
+   wrefresh(win->x_win);
+   return;
+
+   case 027:   /* ^W */
+werase:
+   {
/*
 * On word erase search backwards until we find
 * the beginning of a word or the beginning of
 * the line.
 */
-   if (   *text == win->werase
-   || *text == 027 /* ^W */
-   

Re: svn commit: r263198 - in head/sys: amd64/conf conf net netinet netinet6 sys

2014-03-17 Thread Robert N. M. Watson

On 17 Mar 2014, at 07:54, David Malone  wrote:

>>  (1) Merge a software implementation of the Toeplitz hash specified in
>>  RSS implemented by David Malone.  This is used to allow suitable
>>  pcbgroup placement of connections before the first packet is
>>  received from the NIC.  Software hashing is generally avoided,
>>  however, due to high cost of the hash on general-purpose CPUs.
> 
> I could look at a faster software implementation, but I guess most of
> the value is when hashing is done on the NIC.

In my benchmarking (a couple of years ago) the software path never really 
turned up a lot. If you end up with a flow migrating from an RSS NIC to a 
non-RSS NIC, you fall back on the 'reservation' hash table, using the 
conventional hash and picking up contention, but you don't end up doing the 
software version of Toeplitz per-packet. The only reason we need a software 
implementation (currently) is to do an initial placement of a new outbound flow 
into the hash table prior to receiving a packet with the hardware-generated 
hash on it. For the inbound direction, we can pick it up from the first packet. 
(Although, actually, we also need to do it for inbound flows that come from 
non-RSS NICs -- or localhost or such).

Robert
___
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-unsubscr...@freebsd.org"


Re: svn commit: r263198 - in head/sys: amd64/conf conf net netinet netinet6 sys

2014-03-17 Thread David Malone
>   (1) Merge a software implementation of the Toeplitz hash specified in
>   RSS implemented by David Malone.  This is used to allow suitable
>   pcbgroup placement of connections before the first packet is
>   received from the NIC.  Software hashing is generally avoided,
>   however, due to high cost of the hash on general-purpose CPUs.

I could look at a faster software implementation, but I guess most of
the value is when hashing is done on the NIC.

David.
___
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-unsubscr...@freebsd.org"


svn commit: r263262 - head/sys/dev/usb/input

2014-03-17 Thread Hans Petter Selasky
Author: hselasky
Date: Mon Mar 17 07:19:19 2014
New Revision: 263262
URL: http://svnweb.freebsd.org/changeset/base/263262

Log:
  Fix spelling.
  
  Reported by:  Kevin P. Neal 

Modified:
  head/sys/dev/usb/input/ukbd.c

Modified: head/sys/dev/usb/input/ukbd.c
==
--- head/sys/dev/usb/input/ukbd.c   Mon Mar 17 06:38:40 2014
(r263261)
+++ head/sys/dev/usb/input/ukbd.c   Mon Mar 17 07:19:19 2014
(r263262)
@@ -1909,7 +1909,7 @@ ukbd_ioctl(keyboard_t *kbd, u_long cmd, 
int result;
 
/*
-* XXX Check of someone is calling us from a critical section:
+* XXX Check if someone is calling us from a critical section:
 */
if (curthread->td_critnest != 0)
return (EDEADLK);
___
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-unsubscr...@freebsd.org"