svn commit: r284948 - stable/10/sys/sys

2015-06-30 Thread Tijl Coosemans
Author: tijl
Date: Tue Jun 30 08:40:15 2015
New Revision: 284948
URL: https://svnweb.freebsd.org/changeset/base/284948

Log:
  MFC r284858:
  
  Enable the use of __builtin_va_* for ICC.
  
  PR:   198822
  Submitted by: Sergey Melnikov sergey.melni...@intel.com

Modified:
  stable/10/sys/sys/cdefs.h
Directory Properties:
  stable/10/   (props changed)

Modified: stable/10/sys/sys/cdefs.h
==
--- stable/10/sys/sys/cdefs.h   Tue Jun 30 08:39:34 2015(r284947)
+++ stable/10/sys/sys/cdefs.h   Tue Jun 30 08:40:15 2015(r284948)
@@ -92,7 +92,7 @@
 #  undef __GNUCLIKE_BUILTIN_CONSTANT_P
 # endif
 
-#if (__GNUC_MINOR__  95 || __GNUC__ = 3)  !defined(__INTEL_COMPILER)
+#if (__GNUC_MINOR__  95 || __GNUC__ = 3)
 # define __GNUCLIKE_BUILTIN_VARARGS 1
 # define __GNUCLIKE_BUILTIN_STDARG 1
 # define __GNUCLIKE_BUILTIN_VAALIST 1
___
svn-src-all@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/svn-src-all
To unsubscribe, send any mail to svn-src-all-unsubscr...@freebsd.org


svn commit: r284947 - stable/9/sys/sys

2015-06-30 Thread Tijl Coosemans
Author: tijl
Date: Tue Jun 30 08:39:34 2015
New Revision: 284947
URL: https://svnweb.freebsd.org/changeset/base/284947

Log:
  MFC r284858:
  
  Enable the use of __builtin_va_* for ICC.
  
  PR:   198822
  Submitted by: Sergey Melnikov sergey.melni...@intel.com

Modified:
  stable/9/sys/sys/cdefs.h
Directory Properties:
  stable/9/   (props changed)
  stable/9/sys/   (props changed)
  stable/9/sys/sys/   (props changed)

Modified: stable/9/sys/sys/cdefs.h
==
--- stable/9/sys/sys/cdefs.hTue Jun 30 07:46:06 2015(r284946)
+++ stable/9/sys/sys/cdefs.hTue Jun 30 08:39:34 2015(r284947)
@@ -72,7 +72,7 @@
 #  undef __GNUCLIKE_BUILTIN_CONSTANT_P
 # endif
 
-#if (__GNUC_MINOR__  95 || __GNUC__ = 3)  !defined(__INTEL_COMPILER)
+#if (__GNUC_MINOR__  95 || __GNUC__ = 3)
 # define __GNUCLIKE_BUILTIN_VARARGS 1
 # define __GNUCLIKE_BUILTIN_STDARG 1
 # define __GNUCLIKE_BUILTIN_VAALIST 1
___
svn-src-all@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/svn-src-all
To unsubscribe, send any mail to svn-src-all-unsubscr...@freebsd.org


svn commit: r284946 - head/share/misc

2015-06-30 Thread Maxim Konovalov
Author: maxim
Date: Tue Jun 30 07:46:06 2015
New Revision: 284946
URL: https://svnweb.freebsd.org/changeset/base/284946

Log:
  o DragonFly 4.2.0 added.

Modified:
  head/share/misc/bsd-family-tree

Modified: head/share/misc/bsd-family-tree
==
--- head/share/misc/bsd-family-tree Tue Jun 30 06:02:42 2015
(r284945)
+++ head/share/misc/bsd-family-tree Tue Jun 30 07:46:06 2015
(r284946)
@@ -330,7 +330,7 @@ FreeBSD 5.2   |  |  
  ||  | |   DragonFly 4.0.5
  ||  | |   |
  ||  |OpenBSD 5.7  |
- ||  | |   |
+ ||  | |   DragonFly 4.2.0
  ||  | |   |
 FreeBSD 11 -current   |  NetBSD -current  OpenBSD -current DragonFly 
-current
  ||  | |   |
@@ -672,6 +672,7 @@ DragonFly 4.0.3 2015-01-21 [DFB]
 DragonFly 4.0.42015-03-09 [DFB]
 DragonFly 4.0.52015-03-23 [DFB]
 OpenBSD 5.72015-05-01 [OBD]
+DragonFly 4.2.02015-06-29 [DFB]
 
 Bibliography
 
___
svn-src-all@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/svn-src-all
To unsubscribe, send any mail to svn-src-all-unsubscr...@freebsd.org


svn commit: r284988 - head/sys/dev/cxgbe

2015-06-30 Thread Navdeep Parhar
Author: np
Date: Wed Jul  1 00:34:14 2015
New Revision: 284988
URL: https://svnweb.freebsd.org/changeset/base/284988

Log:
  cxgbe(4): request an automatic tx update when a netmap tx queue idles.
  The NIC tx queues already do this.
  
  MFC after:1 week
  Differential Revision:

Modified:
  head/sys/dev/cxgbe/t4_netmap.c

Modified: head/sys/dev/cxgbe/t4_netmap.c
==
--- head/sys/dev/cxgbe/t4_netmap.c  Tue Jun 30 23:21:59 2015
(r284987)
+++ head/sys/dev/cxgbe/t4_netmap.c  Wed Jul  1 00:34:14 2015
(r284988)
@@ -405,8 +405,8 @@ alloc_nm_txq_hwq(struct port_info *pi, s
V_FW_EQ_ETH_CMD_VFN(0));
c.alloc_to_len16 = htobe32(F_FW_EQ_ETH_CMD_ALLOC |
F_FW_EQ_ETH_CMD_EQSTART | FW_LEN16(c));
-   c.autoequiqe_to_viid = htobe32(F_FW_EQ_ETH_CMD_AUTOEQUEQE |
-   V_FW_EQ_ETH_CMD_VIID(pi-nm_viid));
+   c.autoequiqe_to_viid = htobe32(F_FW_EQ_ETH_CMD_AUTOEQUIQE |
+   F_FW_EQ_ETH_CMD_AUTOEQUEQE | V_FW_EQ_ETH_CMD_VIID(pi-nm_viid));
c.fetchszm_to_iqid =
htobe32(V_FW_EQ_ETH_CMD_HOSTFCMODE(X_HOSTFCMODE_NONE) |
V_FW_EQ_ETH_CMD_PCIECHN(pi-tx_chan) | F_FW_EQ_ETH_CMD_FETCHRO |
___
svn-src-all@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/svn-src-all
To unsubscribe, send any mail to svn-src-all-unsubscr...@freebsd.org


svn commit: r284989 - svnadmin/conf

2015-06-30 Thread Cy Schubert
Author: cy
Date: Wed Jul  1 02:55:20 2015
New Revision: 284989
URL: https://svnweb.freebsd.org/changeset/base/284989

Log:
  Temporarily remove size limit restriction in order to import ntp-4.2.8p3
  into the vendor branch.

Modified:
  svnadmin/conf/sizelimit.conf

Modified: svnadmin/conf/sizelimit.conf
==
--- svnadmin/conf/sizelimit.confWed Jul  1 00:34:14 2015
(r284988)
+++ svnadmin/conf/sizelimit.confWed Jul  1 02:55:20 2015
(r284989)
@@ -21,7 +21,7 @@
 # adrian
 bapt
 brooks
-# cy
+cy
 #delphij
 davidcs
 des
___
svn-src-all@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/svn-src-all
To unsubscribe, send any mail to svn-src-all-unsubscr...@freebsd.org


svn commit: r284990 - in vendor/ntp/dist: . adjtimed clockstuff html html/drivers include include/isc kernel kernel/sys lib/isc/unix libjsmn libjsmn/example libntp libparse ntpd ntpdate ntpdc ntpq ...

2015-06-30 Thread Cy Schubert
Author: cy
Date: Wed Jul  1 03:12:13 2015
New Revision: 284990
URL: https://svnweb.freebsd.org/changeset/base/284990

Log:
  Vendor import ntp-4.2.8p3.
  
  Approved by:  delphij (implicit, using SO hat)
  Security: VuXML: 0d0f3050-1f69-11e5-9ba9-d050996490d0
  Security: http://bugs.ntp.org/show_bug.cgi?id=2853
  Security: https://www.kb.cert.org/vuls/id/668167
  Security: 
http://support.ntp.org/bin/view/Main/SecurityNotice#June_2015_NTP_Security_Vulnerabi

Added:
  vendor/ntp/dist/README.leapsmear
  vendor/ntp/dist/html/drivers/driver40-ja.html   (contents, props changed)
  vendor/ntp/dist/include/refidsmear.h   (contents, props changed)
  vendor/ntp/dist/libjsmn/example/
  vendor/ntp/dist/libjsmn/example/jsondump.c   (contents, props changed)
  vendor/ntp/dist/libjsmn/example/simple.c   (contents, props changed)
  vendor/ntp/dist/libntp/refidsmear.c   (contents, props changed)
  vendor/ntp/dist/ntpd/rc_cmdlength.c   (contents, props changed)
  vendor/ntp/dist/ports/winnt/vs2008/common.vsprops   (contents, props changed)
  vendor/ntp/dist/ports/winnt/vs2008/debug-x64.vsprops   (contents, props 
changed)
  vendor/ntp/dist/ports/winnt/vs2008/debug.vsprops   (contents, props changed)
  vendor/ntp/dist/ports/winnt/vs2008/release-x64.vsprops   (contents, props 
changed)
  vendor/ntp/dist/ports/winnt/vs2008/release.vsprops   (contents, props changed)
  vendor/ntp/dist/ports/winnt/vs2013/common.props   (contents, props changed)
  vendor/ntp/dist/ports/winnt/vs2013/debug-x64.props   (contents, props changed)
  vendor/ntp/dist/ports/winnt/vs2013/debug.props   (contents, props changed)
  vendor/ntp/dist/ports/winnt/vs2013/release-x64.props   (contents, props 
changed)
  vendor/ntp/dist/ports/winnt/vs2013/release.props   (contents, props changed)
  vendor/ntp/dist/scripts/update-leap/update-leap.in   (contents, props changed)
  vendor/ntp/dist/scripts/update-leap/update-leap.sh   (contents, props changed)
  vendor/ntp/dist/sntp/ag-tpl/Mdoc.pm   (contents, props changed)
  vendor/ntp/dist/sntp/ag-tpl/mdoc2man   (contents, props changed)
  vendor/ntp/dist/sntp/libevent/build-aux/ar-lib   (contents, props changed)
  vendor/ntp/dist/sntp/libevent/build-aux/test-driver   (contents, props 
changed)
  vendor/ntp/dist/sntp/libpkgver/
  vendor/ntp/dist/sntp/libpkgver/colcomp.c   (contents, props changed)
  vendor/ntp/dist/sntp/libpkgver/pkgver.h   (contents, props changed)
  vendor/ntp/dist/sntp/m4/ntp_unitytest.m4
  vendor/ntp/dist/sntp/tests/crypto.c   (contents, props changed)
  vendor/ntp/dist/sntp/tests/fileHandlingTest.h.in   (contents, props changed)
  vendor/ntp/dist/sntp/tests/g_fileHandlingTest.h   (contents, props changed)
  vendor/ntp/dist/sntp/tests/g_networking.cpp   (contents, props changed)
  vendor/ntp/dist/sntp/tests/g_packetHandling.cpp   (contents, props changed)
  vendor/ntp/dist/sntp/tests/g_packetProcessing.cpp   (contents, props changed)
  vendor/ntp/dist/sntp/tests/g_sntptest.h   (contents, props changed)
  vendor/ntp/dist/sntp/tests/keyFile.c   (contents, props changed)
  vendor/ntp/dist/sntp/tests/kodDatabase.c   (contents, props changed)
  vendor/ntp/dist/sntp/tests/kodFile.c   (contents, props changed)
  vendor/ntp/dist/sntp/tests/networking.c   (contents, props changed)
  vendor/ntp/dist/sntp/tests/packetHandling.c   (contents, props changed)
  vendor/ntp/dist/sntp/tests/packetProcessing.c   (contents, props changed)
  vendor/ntp/dist/sntp/tests/run-crypto.c   (contents, props changed)
  vendor/ntp/dist/sntp/tests/run-keyFile.c   (contents, props changed)
  vendor/ntp/dist/sntp/tests/run-kodDatabase.c   (contents, props changed)
  vendor/ntp/dist/sntp/tests/run-kodFile.c   (contents, props changed)
  vendor/ntp/dist/sntp/tests/run-networking.c   (contents, props changed)
  vendor/ntp/dist/sntp/tests/run-packetHandling.c   (contents, props changed)
  vendor/ntp/dist/sntp/tests/run-packetProcessing.c   (contents, props changed)
  vendor/ntp/dist/sntp/tests/run-utilities.c   (contents, props changed)
  vendor/ntp/dist/sntp/tests/utilities.c   (contents, props changed)
  vendor/ntp/dist/sntp/unity/
  vendor/ntp/dist/sntp/unity/Makefile.am   (contents, props changed)
  vendor/ntp/dist/sntp/unity/Makefile.in   (contents, props changed)
  vendor/ntp/dist/sntp/unity/auto/
  vendor/ntp/dist/sntp/unity/auto/colour_prompt.rb   (contents, props changed)
  vendor/ntp/dist/sntp/unity/auto/colour_reporter.rb   (contents, props changed)
  vendor/ntp/dist/sntp/unity/auto/generate_config.yml
  vendor/ntp/dist/sntp/unity/auto/generate_module.rb   (contents, props changed)
  vendor/ntp/dist/sntp/unity/auto/generate_test_runner.rb   (contents, props 
changed)
  vendor/ntp/dist/sntp/unity/auto/runner_maybe.c   (contents, props changed)
  vendor/ntp/dist/sntp/unity/auto/test_file_filter.rb   (contents, props 
changed)
  vendor/ntp/dist/sntp/unity/auto/unity_test_summary.rb   (contents, props 
changed)
  vendor/ntp/dist/sntp/unity/unity.c   (contents, props changed)
  

svn commit: r284992 - vendor/ntp/4.2.8p3

2015-06-30 Thread Cy Schubert
Author: cy
Date: Wed Jul  1 03:49:35 2015
New Revision: 284992
URL: https://svnweb.freebsd.org/changeset/base/284992

Log:
  Tag ntp-4.2.8p3.
  
  Approved by:  delphij (implicit, wearing SO hat)
  Security: VuXML: 0d0f3050-1f69-11e5-9ba9-d050996490d0
  Security: http://bugs.ntp.org/show_bug.cgi?id=2853
  Security: https://www.kb.cert.org/vuls/id/668167
  Security: 
http://support.ntp.org/bin/view/Main/SecurityNotice#June_2015_NTP_Security_Vulnerabi

Added:
 - copied from r284991, vendor/ntp/dist/
Directory Properties:
  vendor/ntp/4.2.8p3/   (props changed)
___
svn-src-all@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/svn-src-all
To unsubscribe, send any mail to svn-src-all-unsubscr...@freebsd.org


svn commit: r284991 - svnadmin/conf

2015-06-30 Thread Cy Schubert
Author: cy
Date: Wed Jul  1 03:17:10 2015
New Revision: 284991
URL: https://svnweb.freebsd.org/changeset/base/284991

Log:
  ntp-4.2.8p3 vendor import complete. Revert size limit restriction.

Modified:
  svnadmin/conf/sizelimit.conf

Modified: svnadmin/conf/sizelimit.conf
==
--- svnadmin/conf/sizelimit.confWed Jul  1 03:12:13 2015
(r284990)
+++ svnadmin/conf/sizelimit.confWed Jul  1 03:17:10 2015
(r284991)
@@ -21,7 +21,7 @@
 # adrian
 bapt
 brooks
-cy
+# cy
 #delphij
 davidcs
 des
___
svn-src-all@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/svn-src-all
To unsubscribe, send any mail to svn-src-all-unsubscr...@freebsd.org


svn commit: r284952 - stable/10/etc/defaults

2015-06-30 Thread Dag-Erling Smørgrav
Author: des
Date: Tue Jun 30 13:30:10 2015
New Revision: 284952
URL: https://svnweb.freebsd.org/changeset/base/284952

Log:
  MFH (r270391): don't set rc_debug in /etc/defaults/rc.conf

Modified:
  stable/10/etc/defaults/rc.conf
Directory Properties:
  stable/10/   (props changed)

Modified: stable/10/etc/defaults/rc.conf
==
--- stable/10/etc/defaults/rc.conf  Tue Jun 30 12:57:35 2015
(r284951)
+++ stable/10/etc/defaults/rc.conf  Tue Jun 30 13:30:10 2015
(r284952)
@@ -21,7 +21,7 @@
 ###  Important initial Boot-time options  
 ##
 
-rc_debug=NO  # Set to YES to enable debugging output from rc.d
+#rc_debug=NO # Set to YES to enable debugging output from rc.d
 rc_info=NO   # Enables display of informational messages at boot.
 rc_startmsgs=YES # Show Starting foo: messages at boot
 rcshutdown_timeout=90 # Seconds to wait before terminating rc.shutdown
___
svn-src-all@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/svn-src-all
To unsubscribe, send any mail to svn-src-all-unsubscr...@freebsd.org


svn commit: r284953 - stable/9/etc/defaults

2015-06-30 Thread Dag-Erling Smørgrav
Author: des
Date: Tue Jun 30 13:34:46 2015
New Revision: 284953
URL: https://svnweb.freebsd.org/changeset/base/284953

Log:
  MFH (r270391): don't set rc_debug in /etc/defaults/rc.conf

Modified:
  stable/9/etc/defaults/rc.conf
Directory Properties:
  stable/9/   (props changed)
  stable/9/etc/   (props changed)

Modified: stable/9/etc/defaults/rc.conf
==
--- stable/9/etc/defaults/rc.conf   Tue Jun 30 13:30:10 2015
(r284952)
+++ stable/9/etc/defaults/rc.conf   Tue Jun 30 13:34:46 2015
(r284953)
@@ -21,7 +21,7 @@
 ###  Important initial Boot-time options  
 ##
 
-rc_debug=NO  # Set to YES to enable debugging output from rc.d
+#rc_debug=NO # Set to YES to enable debugging output from rc.d
 rc_info=NO   # Enables display of informational messages at boot.
 rc_startmsgs=YES # Show Starting foo: messages at boot
 rcshutdown_timeout=90 # Seconds to wait before terminating rc.shutdown
___
svn-src-all@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/svn-src-all
To unsubscribe, send any mail to svn-src-all-unsubscr...@freebsd.org


Re: svn commit: r284942 - in head/release: . scripts

2015-06-30 Thread Ian Lepore
On Tue, 2015-06-30 at 01:11 +, Glen Barber wrote:
 On Mon, Jun 29, 2015 at 09:09:13PM -0400, Philip M. Gollucci wrote:
  On Mon, Jun 29, 2015 at 5:26 PM, Brad Davis b...@freebsd.org wrote:
  
   +   env ASSUME_ALWAYS_YES=yes pkg install -y curl
  
  
  why do we have both the env and the -y switch?
  
 
 Because if pkg is not bootstrapped (pkg(7) versus pkg(8)), the former
 (/usr/sbin/pkg) does not recognize '-y'.
 
 Glen
 

Is there any reason we shouldn't just fix that?

-- Ian


___
svn-src-all@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/svn-src-all
To unsubscribe, send any mail to svn-src-all-unsubscr...@freebsd.org


Re: svn commit: r284942 - in head/release: . scripts

2015-06-30 Thread Baptiste Daroussin
On Mon, Jun 29, 2015 at 09:09:13PM -0400, Philip M. Gollucci wrote:
 On Mon, Jun 29, 2015 at 5:26 PM, Brad Davis b...@freebsd.org wrote:
 
  +   env ASSUME_ALWAYS_YES=yes pkg install -y curl
 
 
 why do we have both the env and the -y switch?
 
-y is not needed in this case

Best regards,
Bapt


pgpkmRcg1v5p2.pgp
Description: PGP signature


svn commit: r284957 - stable/10/bin/freebsd-version

2015-06-30 Thread Dag-Erling Smørgrav
Author: des
Date: Tue Jun 30 15:32:57 2015
New Revision: 284957
URL: https://svnweb.freebsd.org/changeset/base/284957

Log:
  MFH (r275659): fix dependency on newvers.sh

Modified:
  stable/10/bin/freebsd-version/Makefile
Directory Properties:
  stable/10/   (props changed)

Modified: stable/10/bin/freebsd-version/Makefile
==
--- stable/10/bin/freebsd-version/Makefile  Tue Jun 30 15:22:47 2015
(r284956)
+++ stable/10/bin/freebsd-version/Makefile  Tue Jun 30 15:32:57 2015
(r284957)
@@ -5,8 +5,7 @@ MAN = freebsd-version.1
 CLEANFILES = freebsd-version.sh
 NEWVERS = ${.CURDIR}/../../sys/conf/newvers.sh
 
-freebsd-version.sh.in: ${NEWVERS}
-freebsd-version.sh: ${.CURDIR}/freebsd-version.sh.in
+freebsd-version.sh: ${.CURDIR}/freebsd-version.sh.in ${NEWVERS}
eval $$(egrep '^(TYPE|REVISION|BRANCH)=' ${NEWVERS}) ; \
if ! sed -e \
s/@@TYPE@@/$${TYPE}/g; \
___
svn-src-all@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/svn-src-all
To unsubscribe, send any mail to svn-src-all-unsubscr...@freebsd.org


svn commit: r284954 - in stable/10: libexec/rtld-elf usr.bin/kdump

2015-06-30 Thread Dag-Erling Smørgrav
Author: des
Date: Tue Jun 30 14:17:02 2015
New Revision: 284954
URL: https://svnweb.freebsd.org/changeset/base/284954

Log:
  MFH (r277695): allow tracing dlfunc() / dlsym() events

Modified:
  stable/10/libexec/rtld-elf/rtld.c
  stable/10/usr.bin/kdump/kdump.c
Directory Properties:
  stable/10/   (props changed)

Modified: stable/10/libexec/rtld-elf/rtld.c
==
--- stable/10/libexec/rtld-elf/rtld.c   Tue Jun 30 13:34:46 2015
(r284953)
+++ stable/10/libexec/rtld-elf/rtld.c   Tue Jun 30 14:17:02 2015
(r284954)
@@ -279,6 +279,8 @@ bool ld_library_path_rpath = false;
 #defineUTRACE_PRELOAD_FINISHED 8
 #defineUTRACE_INIT_CALL9
 #defineUTRACE_FINI_CALL10
+#defineUTRACE_DLSYM_START  11
+#defineUTRACE_DLSYM_STOP   12
 
 struct utrace_rtld {
char sig[4];/* 'RTLD' */
@@ -3055,6 +3057,7 @@ do_dlsym(void *handle, const char *name,
 #ifndef __ia64__
 tls_index ti;
 #endif
+void *sym;
 int res;
 
 def = NULL;
@@ -3064,6 +3067,7 @@ do_dlsym(void *handle, const char *name,
 req.flags = flags | SYMLOOK_IN_PLT;
 req.lockstate = lockstate;
 
+LD_UTRACE(UTRACE_DLSYM_START, handle, NULL, 0, 0, name);
 rlock_acquire(rtld_bind_lock, lockstate);
 if (sigsetjmp(lockstate.env, 0) != 0)
lock_upgrade(rtld_bind_lock, lockstate);
@@ -3073,6 +3077,7 @@ do_dlsym(void *handle, const char *name,
if ((obj = obj_from_addr(retaddr)) == NULL) {
_rtld_error(Cannot determine caller's shared object);
lock_release(rtld_bind_lock, lockstate);
+   LD_UTRACE(UTRACE_DLSYM_STOP, handle, NULL, 0, 0, name);
return NULL;
}
if (handle == NULL) {   /* Just the caller's shared object. */
@@ -3120,6 +3125,7 @@ do_dlsym(void *handle, const char *name,
 } else {
if ((obj = dlcheck(handle)) == NULL) {
lock_release(rtld_bind_lock, lockstate);
+   LD_UTRACE(UTRACE_DLSYM_STOP, handle, NULL, 0, 0, name);
return NULL;
}
 
@@ -3166,23 +3172,26 @@ do_dlsym(void *handle, const char *name,
 * the relocated value of the symbol.
 */
if (ELF_ST_TYPE(def-st_info) == STT_FUNC)
-   return (make_function_pointer(def, defobj));
+   sym = make_function_pointer(def, defobj);
else if (ELF_ST_TYPE(def-st_info) == STT_GNU_IFUNC)
-   return (rtld_resolve_ifunc(defobj, def));
+   sym = rtld_resolve_ifunc(defobj, def);
else if (ELF_ST_TYPE(def-st_info) == STT_TLS) {
 #ifdef __ia64__
return (__tls_get_addr(defobj-tlsindex, def-st_value));
 #else
ti.ti_module = defobj-tlsindex;
ti.ti_offset = def-st_value;
-   return (__tls_get_addr(ti));
+   sym = __tls_get_addr(ti);
 #endif
} else
-   return (defobj-relocbase + def-st_value);
+   sym = defobj-relocbase + def-st_value;
+   LD_UTRACE(UTRACE_DLSYM_STOP, handle, sym, 0, 0, name);
+   return (sym);
 }
 
 _rtld_error(Undefined symbol \%s\, name);
 lock_release(rtld_bind_lock, lockstate);
+LD_UTRACE(UTRACE_DLSYM_STOP, handle, NULL, 0, 0, name);
 return NULL;
 }
 

Modified: stable/10/usr.bin/kdump/kdump.c
==
--- stable/10/usr.bin/kdump/kdump.c Tue Jun 30 13:34:46 2015
(r284953)
+++ stable/10/usr.bin/kdump/kdump.c Tue Jun 30 14:17:02 2015
(r284954)
@@ -1452,6 +1452,8 @@ ktrcsw(struct ktr_csw *cs)
 #defineUTRACE_PRELOAD_FINISHED 8
 #defineUTRACE_INIT_CALL9
 #defineUTRACE_FINI_CALL10
+#defineUTRACE_DLSYM_START  11
+#defineUTRACE_DLSYM_STOP   12
 
 struct utrace_rtld {
char sig[4];/* 'RTLD' */
@@ -1531,6 +1533,13 @@ ktruser_rtld(int len, void *p)
printf(RTLD: fini %p for %p (%s)\n, ut-mapbase, ut-handle,
ut-name);
break;
+   case UTRACE_DLSYM_START:
+   printf(RTLD: dlsym(%p, %s)\n, ut-handle, ut-name);
+   break;
+   case UTRACE_DLSYM_STOP:
+   printf(RTLD: %p = dlsym(%p, %s)\n, ut-mapbase, ut-handle,
+   ut-name);
+   break;
default:
cp = p;
cp += 4;
___
svn-src-all@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/svn-src-all
To unsubscribe, send any mail to svn-src-all-unsubscr...@freebsd.org


svn commit: r284956 - head/sys/kern

2015-06-30 Thread Konstantin Belousov
Author: kib
Date: Tue Jun 30 15:22:47 2015
New Revision: 284956
URL: https://svnweb.freebsd.org/changeset/base/284956

Log:
  Do not calculate the stack's bottom address twice.
  
  Submitted by: Olivц╘r Pintц╘r
  Review:   https://reviews.freebsd.org/D2953
  MFC after:1 week

Modified:
  head/sys/kern/kern_exec.c

Modified: head/sys/kern/kern_exec.c
==
--- head/sys/kern/kern_exec.c   Tue Jun 30 15:21:18 2015(r284955)
+++ head/sys/kern/kern_exec.c   Tue Jun 30 15:22:47 2015(r284956)
@@ -1096,7 +1096,7 @@ exec_new_vmspace(imgp, sv)
 * are still used to enforce the stack rlimit on the process stack.
 */
vmspace-vm_ssize = sgrowsiz  PAGE_SHIFT;
-   vmspace-vm_maxsaddr = (char *)sv-sv_usrstack - ssiz;
+   vmspace-vm_maxsaddr = (char *)stack_addr;
 
return (0);
 }
___
svn-src-all@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/svn-src-all
To unsubscribe, send any mail to svn-src-all-unsubscr...@freebsd.org

svn commit: r284955 - in stable/9: libexec/rtld-elf usr.bin/kdump

2015-06-30 Thread Dag-Erling Smørgrav
Author: des
Date: Tue Jun 30 15:21:18 2015
New Revision: 284955
URL: https://svnweb.freebsd.org/changeset/base/284955

Log:
  MFH (r277695): allow tracing dlfunc() / dlsym() events

Modified:
  stable/9/libexec/rtld-elf/rtld.c
  stable/9/usr.bin/kdump/kdump.c
Directory Properties:
  stable/9/   (props changed)
  stable/9/libexec/rtld-elf/   (props changed)
  stable/9/usr.bin/   (props changed)
  stable/9/usr.bin/kdump/   (props changed)

Modified: stable/9/libexec/rtld-elf/rtld.c
==
--- stable/9/libexec/rtld-elf/rtld.cTue Jun 30 14:17:02 2015
(r284954)
+++ stable/9/libexec/rtld-elf/rtld.cTue Jun 30 15:21:18 2015
(r284955)
@@ -259,6 +259,8 @@ bool ld_library_path_rpath = true;
 #defineUTRACE_PRELOAD_FINISHED 8
 #defineUTRACE_INIT_CALL9
 #defineUTRACE_FINI_CALL10
+#defineUTRACE_DLSYM_START  11
+#defineUTRACE_DLSYM_STOP   12
 
 struct utrace_rtld {
char sig[4];/* 'RTLD' */
@@ -2957,6 +2959,7 @@ do_dlsym(void *handle, const char *name,
 #ifndef __ia64__
 tls_index ti;
 #endif
+void *sym;
 int res;
 
 def = NULL;
@@ -2966,6 +2969,7 @@ do_dlsym(void *handle, const char *name,
 req.flags = flags | SYMLOOK_IN_PLT;
 req.lockstate = lockstate;
 
+LD_UTRACE(UTRACE_DLSYM_START, handle, NULL, 0, 0, name);
 rlock_acquire(rtld_bind_lock, lockstate);
 if (sigsetjmp(lockstate.env, 0) != 0)
lock_upgrade(rtld_bind_lock, lockstate);
@@ -2975,6 +2979,7 @@ do_dlsym(void *handle, const char *name,
if ((obj = obj_from_addr(retaddr)) == NULL) {
_rtld_error(Cannot determine caller's shared object);
lock_release(rtld_bind_lock, lockstate);
+   LD_UTRACE(UTRACE_DLSYM_STOP, handle, NULL, 0, 0, name);
return NULL;
}
if (handle == NULL) {   /* Just the caller's shared object. */
@@ -3022,6 +3027,7 @@ do_dlsym(void *handle, const char *name,
 } else {
if ((obj = dlcheck(handle)) == NULL) {
lock_release(rtld_bind_lock, lockstate);
+   LD_UTRACE(UTRACE_DLSYM_STOP, handle, NULL, 0, 0, name);
return NULL;
}
 
@@ -3068,23 +3074,26 @@ do_dlsym(void *handle, const char *name,
 * the relocated value of the symbol.
 */
if (ELF_ST_TYPE(def-st_info) == STT_FUNC)
-   return (make_function_pointer(def, defobj));
+   sym = make_function_pointer(def, defobj);
else if (ELF_ST_TYPE(def-st_info) == STT_GNU_IFUNC)
-   return (rtld_resolve_ifunc(defobj, def));
+   sym = rtld_resolve_ifunc(defobj, def);
else if (ELF_ST_TYPE(def-st_info) == STT_TLS) {
 #ifdef __ia64__
return (__tls_get_addr(defobj-tlsindex, def-st_value));
 #else
ti.ti_module = defobj-tlsindex;
ti.ti_offset = def-st_value;
-   return (__tls_get_addr(ti));
+   sym = __tls_get_addr(ti);
 #endif
} else
-   return (defobj-relocbase + def-st_value);
+   sym = defobj-relocbase + def-st_value;
+   LD_UTRACE(UTRACE_DLSYM_STOP, handle, sym, 0, 0, name);
+   return (sym);
 }
 
 _rtld_error(Undefined symbol \%s\, name);
 lock_release(rtld_bind_lock, lockstate);
+LD_UTRACE(UTRACE_DLSYM_STOP, handle, NULL, 0, 0, name);
 return NULL;
 }
 

Modified: stable/9/usr.bin/kdump/kdump.c
==
--- stable/9/usr.bin/kdump/kdump.c  Tue Jun 30 14:17:02 2015
(r284954)
+++ stable/9/usr.bin/kdump/kdump.c  Tue Jun 30 15:21:18 2015
(r284955)
@@ -1283,6 +1283,8 @@ ktrcsw(struct ktr_csw *cs)
 #defineUTRACE_PRELOAD_FINISHED 8
 #defineUTRACE_INIT_CALL9
 #defineUTRACE_FINI_CALL10
+#defineUTRACE_DLSYM_START  11
+#defineUTRACE_DLSYM_STOP   12
 
 struct utrace_rtld {
char sig[4];/* 'RTLD' */
@@ -1361,6 +1363,13 @@ ktruser_rtld(int len, unsigned char *p)
printf(RTLD: fini %p for %p (%s)\n, ut-mapbase, ut-handle,
ut-name);
break;
+   case UTRACE_DLSYM_START:
+   printf(RTLD: dlsym(%p, %s)\n, ut-handle, ut-name);
+   break;
+   case UTRACE_DLSYM_STOP:
+   printf(RTLD: %p = dlsym(%p, %s)\n, ut-mapbase, ut-handle,
+   ut-name);
+   break;
default:
p += 4;
len -= 4;
___
svn-src-all@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/svn-src-all
To unsubscribe, send any mail to svn-src-all-unsubscr...@freebsd.org


svn commit: r284960 - in head: etc/defaults etc/rc.d share/man/man5 share/man/man9 sys/boot/forth

2015-06-30 Thread Mark Murray
Author: markm
Date: Tue Jun 30 17:09:41 2015
New Revision: 284960
URL: https://svnweb.freebsd.org/changeset/base/284960

Log:
  Updated random(4) boot/shutdown scripting.
  Fix the man pages as well.
  
  Differential Revision: https://reviews.freebsd.org/D2924
  Approved by: so (delphij)

Modified:
  head/etc/defaults/rc.conf
  head/etc/rc.d/random
  head/share/man/man5/rc.conf.5
  head/share/man/man9/random.9
  head/sys/boot/forth/loader.conf
  head/sys/boot/forth/loader.conf.5

Modified: head/etc/defaults/rc.conf
==
--- head/etc/defaults/rc.conf   Tue Jun 30 17:00:45 2015(r284959)
+++ head/etc/defaults/rc.conf   Tue Jun 30 17:09:41 2015(r284960)
@@ -630,15 +630,16 @@ kern_securelevel=-1 # range: -1..3 ; `
# in the system booting with securelevel set to 1, as
# init(8) will raise the level when rc(8) completes.
 update_motd=YES  # update version info in /etc/motd (or NO)
-entropy_file=/entropy# Set to NO to disable caching entropy through 
reboots.
+entropy_boot_file=/boot/entropy  # Set to NO to disable very early
+   # (used at early boot time) entropy caching through 
reboots.
+entropy_file=/entropy# Set to NO to disable late (used when going 
multi-user)
+   # entropy through reboots.
# /var/db/entropy-file is preferred if / is not avail.
 entropy_dir=/var/db/entropy # Set to NO to disable caching entropy via cron.
 entropy_save_sz=4096 # Size of the entropy cache files.
 entropy_save_num=8   # Number of entropy cache files to save.
-harvest_interrupt=YES# Entropy device harvests interrupt randomness
-harvest_ethernet=YES # Entropy device harvests ethernet randomness
-harvest_p_to_p=YES   # Entropy device harvests point-to-point randomness
-harvest_swi=YES  # Entropy device harvests internal SWI randomness
+harvest_mask=511 # Entropy device harvests all but the very invasive 
sources.
+   # (See 'sysctl kern.random.harvest' and random(4))
 dmesg_enable=YES # Save dmesg(8) to /var/run/dmesg.boot
 watchdogd_enable=NO  # Start the software watchdog daemon
 watchdogd_flags= # Flags to watchdogd (if enabled)

Modified: head/etc/rc.d/random
==
--- head/etc/rc.d/randomTue Jun 30 17:00:45 2015(r284959)
+++ head/etc/rc.d/randomTue Jun 30 17:09:41 2015(r284960)
@@ -41,6 +41,13 @@ feed_dev_random()
 
 random_start()
 {
+
+   if [ ${harvest_mask} -gt 0 ]; then
+   echo -n 'Setting up harvesting:'
+   ${SYSCTL} kern.random.harvest.mask=${harvest_mask}  /dev/null
+   ${SYSCTL_N} kern.random.harvest.mask_symbolic
+   fi
+
echo -n 'Feeding entropy:'
 
if [ ! -w /dev/random ] ; then
@@ -68,6 +75,14 @@ random_start()
;;
esac
 
+   case ${entropy_boot_file:=/boot/entropy} in
+   [Nn][Oo] | '')
+   ;;
+   *)
+   save_dev_random ${entropy_boot_file}
+   ;;
+   esac
+
echo '.'
 }
 
@@ -100,7 +115,33 @@ random_stop()
;;
*)
dd if=/dev/random of=${entropy_file_confirmed} \
-  bs=4096 count=1 2 /dev/null
+   bs=4096 count=1 2 /dev/null ||
+   warn 'write failed (unwriteable file or full fs?)'
+   echo '.'
+   ;;
+   esac
+   umask ${oumask}
+   ;;
+   esac
+   case ${entropy_boot_file:=/boot/entropy} in
+   [Nn][Oo] | '')
+   ;;
+   *)
+   echo -n 'Writing early boot entropy file:'
+   rm -f ${entropy_boot_file} 2 /dev/null
+   oumask=`umask`
+   umask 077
+   if touch ${entropy_boot_file} 2 /dev/null; then
+   entropy_boot_file_confirmed=${entropy_boot_file}
+   fi
+   case ${entropy_boot_file_confirmed} in
+   '')
+   warn 'write failed (read-only fs?)'
+   ;;
+   *)
+   dd if=/dev/random of=${entropy_boot_file_confirmed} \
+   bs=4096 count=1 2 /dev/null ||
+   warn 'write failed (unwriteable file or full fs?)'
echo '.'
;;
esac

Modified: head/share/man/man5/rc.conf.5
==
--- head/share/man/man5/rc.conf.5   Tue Jun 30 17:00:45 2015
(r284959)
+++ head/share/man/man5/rc.conf.5   Tue Jun 30 17:09:41 2015
(r284960)
@@ -3995,27 +3995,11 @@ set from
 .Va jail_ Ns Ao Ar jname Ac Ns Va 

svn commit: r284959 - in head: . share/man/man4 share/man/man9 sys/conf sys/dev/glxsb sys/dev/hifn sys/dev/random sys/dev/rndtest sys/dev/safe sys/dev/syscons sys/dev/ubsec sys/dev/virtio/random sy...

2015-06-30 Thread Mark Murray
  head/share/man/man9/random_harvest.9
  head/sys/conf/files
  head/sys/conf/options
  head/sys/dev/glxsb/glxsb.c
  head/sys/dev/hifn/hifn7751.c
  head/sys/dev/random/build.sh
  head/sys/dev/random/fortuna.c
  head/sys/dev/random/fortuna.h
  head/sys/dev/random/hash.c
  head/sys/dev/random/hash.h
  head/sys/dev/random/ivy.c
  head/sys/dev/random/nehemiah.c
  head/sys/dev/random/random_harvestq.c
  head/sys/dev/random/random_harvestq.h
  head/sys/dev/random/randomdev.c
  head/sys/dev/random/randomdev.h
  head/sys/dev/random/uint128.h
  head/sys/dev/random/unit_test.c
  head/sys/dev/random/unit_test.h
  head/sys/dev/random/yarrow.c
  head/sys/dev/random/yarrow.h
  head/sys/dev/rndtest/rndtest.c
  head/sys/dev/safe/safe.c
  head/sys/dev/syscons/scmouse.c
  head/sys/dev/syscons/syscons.c
  head/sys/dev/ubsec/ubsec.c
  head/sys/dev/virtio/random/virtio_random.c
  head/sys/dev/vt/vt_core.c
  head/sys/dev/vt/vt_sysmouse.c
  head/sys/fs/tmpfs/tmpfs_subr.c
  head/sys/kern/kern_intr.c
  head/sys/kern/kern_mib.c
  head/sys/kern/subr_bus.c
  head/sys/libkern/arc4random.c
  head/sys/libkern/random.c
  head/sys/mips/cavium/octeon_rnd.c
  head/sys/mips/conf/AR71XX_BASE
  head/sys/mips/conf/AR724X_BASE
  head/sys/mips/conf/AR91XX_BASE
  head/sys/mips/conf/AR933X_BASE
  head/sys/mips/conf/AR934X_BASE
  head/sys/mips/conf/PB92
  head/sys/mips/conf/QCA955X_BASE
  head/sys/mips/conf/RT305X
  head/sys/modules/Makefile
  head/sys/modules/crypto/Makefile
  head/sys/net/if_ethersubr.c
  head/sys/net/if_tun.c
  head/sys/netgraph/ng_iface.c
  head/sys/sys/kernel.h
  head/sys/sys/random.h
  head/sys/ufs/ffs/ffs_inode.c
  head/sys/vm/uma_core.c

Modified: head/UPDATING
==
--- head/UPDATING   Tue Jun 30 16:26:13 2015(r284958)
+++ head/UPDATING   Tue Jun 30 17:00:45 2015(r284959)
@@ -31,6 +31,41 @@ NOTE TO PEOPLE WHO THINK THAT FreeBSD 11
disable the most expensive debugging functionality run
ln -s 'abort:false,junk:false' /etc/malloc.conf.)
 
+20150630:
+   The default kernel entropy-processing algorithm is now
+   Fortuna, replacing Yarrow.
+
+   Assuming you have 'device random' in your kernel config
+   file, the configurations allow a kernel option to override
+   this default. You may choose *ONE* of:
+
+   options RANDOM_YARROW   # Legacy /dev/random algorithm.
+   options RANDOM_DUMMY# Blocking-only driver.
+
+   If you have neither, you get Fortuna.  For most people,
+   read no further, Fortuna will give a /dev/random that works
+   like it always used to, and the difference will be irrelevant.
+
+   If you remove 'device random', you get *NO* kernel-processed
+   entopy at all. This may be acceptable to folks building
+   embedded systems, but has complications. Carry on reading,
+   and it is assumed you know what you need.
+
+   *PLEASE* read random(4) and random(9) if you are in the
+   habit of tweeking kernel configs, and/or if you are a member
+   of the embedded community, wanting specific and not-usual
+   behaviour from your security subsystems.
+
+   NOTE!! If you use RANDOM_DUMMY and/or have no 'device
+   random', you will NOT have a functioning /dev/random, and
+   many cryptographic features will not work, including SSH.
+   You may also find strange behaviour from the random(3) set
+   of library functions, in particular sranddev(3), srandomdev(3)
+   and arc4random(3). The reason for this is that the KERN_ARND
+   sysctl only returns entropy if it thinks it has some to
+   share, and with RANDOM_DUMMY or no 'device random' this
+   will never happen.
+
 20150623:
An additional fix for the issue described in the 20150614 sendmail
entry below has been been committed in revision 284717.

Modified: head/share/man/man4/random.4
==
--- head/share/man/man4/random.4Tue Jun 30 16:26:13 2015
(r284958)
+++ head/share/man/man4/random.4Tue Jun 30 17:00:45 2015
(r284959)
@@ -1,4 +1,4 @@
-.\ Copyright (c) 2001-2013Mark R V Murray.  All rights reserved.
+.\ Copyright (c) 2001-2015Mark R V Murray.  All rights reserved.
 .\
 .\ Redistribution and use in source and binary forms, with or without
 .\ modification, are permitted provided that the following conditions
@@ -23,7 +23,7 @@
 .\
 .\ $FreeBSD$
 .\
-.Dd October 12, 2013
+.Dd June 30, 2015
 .Dt RANDOM 4
 .Os
 .Sh NAME
@@ -37,31 +37,32 @@ The
 device
 returns an endless supply of random bytes when read.
 It also accepts and reads data
-as any ordinary (and willing) file,
-but discards data written to it.
-The device will probe for
-certain hardware entropy sources,
-and use these in preference to the fallback,
-which is a generator implemented in software.
+as any ordinary file.
 .Pp
-The software generator will start

svn commit: r284964 - head/share/dtrace

2015-06-30 Thread Hiren Panchasara
Author: hiren
Date: Tue Jun 30 18:23:08 2015
New Revision: 284964
URL: https://svnweb.freebsd.org/changeset/base/284964

Log:
  Add missing DTrace scripts that exist in the source tree to the Makefile for
  install.
  While here, sort the list.
  
  Differential Revision:D2950
  Submitted by: Jason Wolfe j at nitrology.com
  Reviewed by:  gnn, markj, hiren
  Sponsored by: Limelight Networks

Modified:
  head/share/dtrace/Makefile

Modified: head/share/dtrace/Makefile
==
--- head/share/dtrace/Makefile  Tue Jun 30 17:59:14 2015(r284963)
+++ head/share/dtrace/Makefile  Tue Jun 30 18:23:08 2015(r284964)
@@ -15,11 +15,13 @@ _toolkit=   toolkit
 SCRIPTS=   disklatency \
disklatencycmd \
hotopen \
+   nfsattrstats \
nfsclienttime \
-   udptrack \
+   siftr \
+   tcpconn \
tcpstate \
tcptrack \
-   tcpconn 
+   udptrack
 
 SCRIPTSDIR= ${SHAREDIR}/dtrace
 
___
svn-src-all@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/svn-src-all
To unsubscribe, send any mail to svn-src-all-unsubscr...@freebsd.org


svn commit: r284962 - stable/10/sys/dev/bxe

2015-06-30 Thread David C Somayajulu
Author: davidcs
Date: Tue Jun 30 17:44:44 2015
New Revision: 284962
URL: https://svnweb.freebsd.org/changeset/base/284962

Log:
  MFC r284335
  
  PHY LOCK acquires the hardware lock via bxe_acquire_phy_lock() and releases 
it via bxe_release_phy_lock(). It was simply acquiring a mutex earlier which 
can cause the PHY to use bogus values. Fixes intermittent link failures.
  
  bxe_ioctl() completes all functions within its context as opposed to a 
taskqueue earlier.
  
  bxe_handle_rx_mode_tq() no longer required. bxe_set_rx_mode() handles the 
functionality within its context
  
  Submitted by: gary.zambr...@qlogic.com

Modified:
  stable/10/sys/dev/bxe/bxe.c
  stable/10/sys/dev/bxe/bxe.h
  stable/10/sys/dev/bxe/ecore_reg.h
Directory Properties:
  stable/10/   (props changed)

Modified: stable/10/sys/dev/bxe/bxe.c
==
--- stable/10/sys/dev/bxe/bxe.c Tue Jun 30 17:19:58 2015(r284961)
+++ stable/10/sys/dev/bxe/bxe.c Tue Jun 30 17:44:44 2015(r284962)
@@ -737,7 +737,6 @@ static __noinline int bxe_nic_unload(str
  uint8_t  keep_link);
 
 static void bxe_handle_sp_tq(void *context, int pending);
-static void bxe_handle_rx_mode_tq(void *context, int pending);
 static void bxe_handle_fp_tq(void *context, int pending);
 
 
@@ -1185,7 +1184,17 @@ bxe_release_hw_lock(struct bxe_softc *sc
 REG_WR(sc, hw_lock_control_reg, resource_bit);
 return (0);
 }
+static void bxe_acquire_phy_lock(struct bxe_softc *sc)
+{
+   BXE_PHY_LOCK(sc);
+   bxe_acquire_hw_lock(sc,HW_LOCK_RESOURCE_MDIO); 
+}
 
+static void bxe_release_phy_lock(struct bxe_softc *sc)
+{
+   bxe_release_hw_lock(sc,HW_LOCK_RESOURCE_MDIO); 
+   BXE_PHY_UNLOCK(sc);
+}
 /*
  * Per pf misc lock must be acquired before the per port mcp lock. Otherwise,
  * had we done things the other way around, if two pfs from the same port
@@ -4775,29 +4784,6 @@ bxe_handle_chip_tq(void *context,
 
 switch (work)
 {
-case CHIP_TQ_START:
-if ((sc-ifnet-if_flags  IFF_UP) 
-!(sc-ifnet-if_drv_flags  IFF_DRV_RUNNING)) {
-/* start the interface */
-BLOGD(sc, DBG_LOAD, Starting the interface...\n);
-BXE_CORE_LOCK(sc);
-bxe_init_locked(sc);
-BXE_CORE_UNLOCK(sc);
-}
-break;
-
-case CHIP_TQ_STOP:
-if (!(sc-ifnet-if_flags  IFF_UP) 
-(sc-ifnet-if_drv_flags  IFF_DRV_RUNNING)) {
-/* bring down the interface */
-BLOGD(sc, DBG_LOAD, Stopping the interface...\n);
-bxe_periodic_stop(sc);
-BXE_CORE_LOCK(sc);
-bxe_stop_locked(sc);
-BXE_CORE_UNLOCK(sc);
-}
-break;
-
 case CHIP_TQ_REINIT:
 if (sc-ifnet-if_drv_flags  IFF_DRV_RUNNING) {
 /* restart the interface */
@@ -4867,21 +4853,22 @@ bxe_ioctl(struct ifnet *ifp,
 /* toggle the interface state up or down */
 BLOGD(sc, DBG_IOCTL, Received SIOCSIFFLAGS ioctl\n);
 
+   BXE_CORE_LOCK(sc);
 /* check if the interface is up */
 if (ifp-if_flags  IFF_UP) {
 if (ifp-if_drv_flags  IFF_DRV_RUNNING) {
 /* set the receive mode flags */
 bxe_set_rx_mode(sc);
 } else {
-atomic_store_rel_long(sc-chip_tq_flags, CHIP_TQ_START);
-taskqueue_enqueue(sc-chip_tq, sc-chip_tq_task);
+   bxe_init_locked(sc);
 }
 } else {
 if (ifp-if_drv_flags  IFF_DRV_RUNNING) {
-atomic_store_rel_long(sc-chip_tq_flags, CHIP_TQ_STOP);
-taskqueue_enqueue(sc-chip_tq, sc-chip_tq_task);
+   bxe_periodic_stop(sc);
+   bxe_stop_locked(sc);
 }
 }
+   BXE_CORE_UNLOCK(sc);
 
 break;
 
@@ -4893,7 +4880,9 @@ bxe_ioctl(struct ifnet *ifp,
 /* check if the interface is up */
 if (ifp-if_drv_flags  IFF_DRV_RUNNING) {
 /* set the receive mode flags */
+   BXE_CORE_LOCK(sc);
 bxe_set_rx_mode(sc);
+   BXE_CORE_UNLOCK(sc); 
 }
 
 break;
@@ -5051,8 +5040,11 @@ bxe_ioctl(struct ifnet *ifp,
 if (reinit  (sc-ifnet-if_drv_flags  IFF_DRV_RUNNING)) {
 BLOGD(sc, DBG_LOAD | DBG_IOCTL,
   Re-initializing hardware from IOCTL change\n);
-atomic_store_rel_long(sc-chip_tq_flags, CHIP_TQ_REINIT);
-taskqueue_enqueue(sc-chip_tq, sc-chip_tq_task);
+   bxe_periodic_stop(sc);
+   BXE_CORE_LOCK(sc);
+   bxe_stop_locked(sc);
+   bxe_init_locked(sc);
+   BXE_CORE_UNLOCK(sc);
 }
 
 return (error);
@@ -7494,8 +7486,7 @@ bxe_attn_int_asserted(struct bxe_softc *
 if (asserted  ATTN_HARD_WIRED_MASK) {
 if (asserted  ATTN_NIG_FOR_FUNC) {
 
-BXE_PHY_LOCK(sc);
-
+   bxe_acquire_phy_lock(sc);
 /* save nig interrupt 

svn commit: r284963 - stable/10/sys/dev/bxe

2015-06-30 Thread David C Somayajulu
Author: davidcs
Date: Tue Jun 30 17:59:14 2015
New Revision: 284963
URL: https://svnweb.freebsd.org/changeset/base/284963

Log:
  MFC r284470
  In bxe_init_mcast_macs_list(): mc_mac-mac needs to point to the multicast 
mac address
  In bxe_set_mc_list(): added missing BXE_MCAST_UNLOCK()
  In __ecore_vlan_mac_h_exec_pending(): need to check for ECORE_PENDING
  
  Submitted by: gary.zambr...@qlogic.com

Modified:
  stable/10/sys/dev/bxe/bxe.c
  stable/10/sys/dev/bxe/ecore_sp.c
Directory Properties:
  stable/10/   (props changed)

Modified: stable/10/sys/dev/bxe/bxe.c
==
--- stable/10/sys/dev/bxe/bxe.c Tue Jun 30 17:44:44 2015(r284962)
+++ stable/10/sys/dev/bxe/bxe.c Tue Jun 30 17:59:14 2015(r284963)
@@ -12535,6 +12535,7 @@ bxe_init_mcast_macs_list(struct bxe_soft
 BLOGE(sc, Failed to allocate temp mcast list\n);
 return (-1);
 }
+bzero(mc_mac, (sizeof(*mc_mac) * mc_count));
 
 TAILQ_FOREACH(ifma, ifp-if_multiaddrs, ifma_link) {
 if (ifma-ifma_addr-sa_family != AF_LINK) {
@@ -12585,6 +12586,7 @@ bxe_set_mc_list(struct bxe_softc *sc)
 rc = ecore_config_mcast(sc, rparam, ECORE_MCAST_CMD_DEL);
 if (rc  0) {
 BLOGE(sc, Failed to clear multicast configuration: %d\n, rc);
+BXE_MCAST_UNLOCK(sc);
 return (rc);
 }
 

Modified: stable/10/sys/dev/bxe/ecore_sp.c
==
--- stable/10/sys/dev/bxe/ecore_sp.cTue Jun 30 17:44:44 2015
(r284962)
+++ stable/10/sys/dev/bxe/ecore_sp.cTue Jun 30 17:59:14 2015
(r284963)
@@ -474,7 +474,7 @@ static void __ecore_vlan_mac_h_exec_pend
o-head_exe_request = FALSE;
o-saved_ramrod_flags = 0;
rc = ecore_exe_queue_step(sc, o-exe_queue, ramrod_flags);
-   if (rc != ECORE_SUCCESS) {
+   if ((rc != ECORE_SUCCESS)  (rc != ECORE_PENDING)) {
ECORE_ERR(execution of pending commands failed with rc %d\n,
  rc);
 #ifdef ECORE_STOP_ON_ERROR
___
svn-src-all@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/svn-src-all
To unsubscribe, send any mail to svn-src-all-unsubscr...@freebsd.org


svn commit: r284958 - stable/10/sys/dev/ixgbe

2015-06-30 Thread Eric Joyner
Author: erj
Date: Tue Jun 30 16:26:13 2015
New Revision: 284958
URL: https://svnweb.freebsd.org/changeset/base/284958

Log:
  Re-add if_hw_tso* assignments to if_ix.c that were removed in r283668.
  
  These are used in stable/10 as well as 11.
  
  Requested by: rmacklem@

Modified:
  stable/10/sys/dev/ixgbe/if_ix.c

Modified: stable/10/sys/dev/ixgbe/if_ix.c
==
--- stable/10/sys/dev/ixgbe/if_ix.c Tue Jun 30 15:32:57 2015
(r284957)
+++ stable/10/sys/dev/ixgbe/if_ix.c Tue Jun 30 16:26:13 2015
(r284958)
@@ -2499,6 +2499,10 @@ ixgbe_setup_interface(device_t dev, stru
ifp-if_softc = adapter;
ifp-if_flags = IFF_BROADCAST | IFF_SIMPLEX | IFF_MULTICAST;
ifp-if_ioctl = ixgbe_ioctl;
+   /* TSO parameters */
+   ifp-if_hw_tsomax = 65518;
+   ifp-if_hw_tsomaxsegcount = IXGBE_82599_SCATTER;
+   ifp-if_hw_tsomaxsegsize = 2048;
 #ifndef IXGBE_LEGACY_TX
ifp-if_transmit = ixgbe_mq_start;
ifp-if_qflush = ixgbe_qflush;
___
svn-src-all@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/svn-src-all
To unsubscribe, send any mail to svn-src-all-unsubscr...@freebsd.org


svn commit: r284961 - in head/sys: kern netinet sys

2015-06-30 Thread Navdeep Parhar
Author: np
Date: Tue Jun 30 17:19:58 2015
New Revision: 284961
URL: https://svnweb.freebsd.org/changeset/base/284961

Log:
  Fix leak in tcp_lro_rx.  Simply clearing M_PKTHDR isn't enough, any tags
  hanging off the header need to be freed too.
  
  Differential Revision:https://reviews.freebsd.org/D2708
  Reviewed by:  ae@, hiren@

Modified:
  head/sys/kern/uipc_mbuf.c
  head/sys/netinet/tcp_lro.c
  head/sys/sys/mbuf.h

Modified: head/sys/kern/uipc_mbuf.c
==
--- head/sys/kern/uipc_mbuf.c   Tue Jun 30 17:09:41 2015(r284960)
+++ head/sys/kern/uipc_mbuf.c   Tue Jun 30 17:19:58 2015(r284961)
@@ -420,6 +420,17 @@ mb_dupcl(struct mbuf *n, struct mbuf *m)
n-m_flags |= m-m_flags  M_RDONLY;
 }
 
+void
+m_demote_pkthdr(struct mbuf *m)
+{
+
+   M_ASSERTPKTHDR(m);
+
+   m_tag_delete_chain(m, NULL);
+   m-m_flags = ~M_PKTHDR;
+   bzero(m-m_pkthdr, sizeof(struct pkthdr));
+}
+
 /*
  * Clean up mbuf (chain) from any tags and packet headers.
  * If all is set then the first mbuf in the chain will be
@@ -433,11 +444,8 @@ m_demote(struct mbuf *m0, int all, int f
for (m = all ? m0 : m0-m_next; m != NULL; m = m-m_next) {
KASSERT(m-m_nextpkt == NULL, (%s: m_nextpkt in m %p, m0 %p,
__func__, m, m0));
-   if (m-m_flags  M_PKTHDR) {
-   m_tag_delete_chain(m, NULL);
-   m-m_flags = ~M_PKTHDR;
-   bzero(m-m_pkthdr, sizeof(struct pkthdr));
-   }
+   if (m-m_flags  M_PKTHDR)
+   m_demote_pkthdr(m);
m-m_flags = m-m_flags  (M_EXT | M_RDONLY | M_NOFREE | flags);
}
 }

Modified: head/sys/netinet/tcp_lro.c
==
--- head/sys/netinet/tcp_lro.c  Tue Jun 30 17:09:41 2015(r284960)
+++ head/sys/netinet/tcp_lro.c  Tue Jun 30 17:19:58 2015(r284961)
@@ -550,7 +550,7 @@ tcp_lro_rx(struct lro_ctrl *lc, struct m
 * append new segment to existing mbuf chain.
 */
m_adj(m, m-m_pkthdr.len - tcp_data_len);
-   m-m_flags = ~M_PKTHDR;
+   m_demote_pkthdr(m);
 
le-m_tail-m_next = m;
le-m_tail = m_last(m);

Modified: head/sys/sys/mbuf.h
==
--- head/sys/sys/mbuf.h Tue Jun 30 17:09:41 2015(r284960)
+++ head/sys/sys/mbuf.h Tue Jun 30 17:19:58 2015(r284961)
@@ -959,6 +959,7 @@ struct mbuf *m_copypacket(struct mbuf *,
 voidm_copy_pkthdr(struct mbuf *, struct mbuf *);
 struct mbuf*m_copyup(struct mbuf *, int, int);
 struct mbuf*m_defrag(struct mbuf *, int);
+voidm_demote_pkthdr(struct mbuf *);
 voidm_demote(struct mbuf *, int, int);
 struct mbuf*m_devget(char *, int, int, struct ifnet *,
void (*)(char *, caddr_t, u_int));
___
svn-src-all@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/svn-src-all
To unsubscribe, send any mail to svn-src-all-unsubscr...@freebsd.org


svn commit: r284973 - stable/9

2015-06-30 Thread David C Somayajulu
Author: davidcs
Date: Tue Jun 30 20:01:24 2015
New Revision: 284973
URL: https://svnweb.freebsd.org/changeset/base/284973

Log:
  MFC r284739
tx_mtx should be grabbed before calling buf_ring_dequeue_sc()
  
  Submitted by: attilio@isilon.com

Modified:
Directory Properties:
  stable/9/   (props changed)
___
svn-src-all@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/svn-src-all
To unsubscribe, send any mail to svn-src-all-unsubscr...@freebsd.org


svn commit: r284977 - stable/8/sys/dev/bxe

2015-06-30 Thread David C Somayajulu
Author: davidcs
Date: Tue Jun 30 20:28:07 2015
New Revision: 284977
URL: https://svnweb.freebsd.org/changeset/base/284977

Log:
  MFC r284470
  In bxe_set_mc_list(): added missing BXE_MCAST_UNLOCK()
  In __ecore_vlan_mac_h_exec_pending(): need to check for ECORE_PENDING
  
  Submitted by: gary.zambr...@qlogic.com

Modified:
  stable/8/sys/dev/bxe/bxe.c
  stable/8/sys/dev/bxe/ecore_sp.c
Directory Properties:
  stable/8/   (props changed)
  stable/8/sys/   (props changed)
  stable/8/sys/dev/   (props changed)

Modified: stable/8/sys/dev/bxe/bxe.c
==
--- stable/8/sys/dev/bxe/bxe.c  Tue Jun 30 20:24:23 2015(r284976)
+++ stable/8/sys/dev/bxe/bxe.c  Tue Jun 30 20:28:07 2015(r284977)
@@ -12544,6 +12544,7 @@ bxe_init_mcast_macs_list(struct bxe_soft
 BLOGE(sc, Failed to allocate temp mcast list\n);
 return (-1);
 }
+bzero(mc_mac, (sizeof(*mc_mac) * mc_count));
 
 TAILQ_FOREACH(ifma, ifp-if_multiaddrs, ifma_link) {
 if (ifma-ifma_addr-sa_family != AF_LINK) {
@@ -12594,6 +12595,7 @@ bxe_set_mc_list(struct bxe_softc *sc)
 rc = ecore_config_mcast(sc, rparam, ECORE_MCAST_CMD_DEL);
 if (rc  0) {
 BLOGE(sc, Failed to clear multicast configuration: %d\n, rc);
+BXE_MCAST_UNLOCK(sc);
 return (rc);
 }
 

Modified: stable/8/sys/dev/bxe/ecore_sp.c
==
--- stable/8/sys/dev/bxe/ecore_sp.c Tue Jun 30 20:24:23 2015
(r284976)
+++ stable/8/sys/dev/bxe/ecore_sp.c Tue Jun 30 20:28:07 2015
(r284977)
@@ -474,7 +474,7 @@ static void __ecore_vlan_mac_h_exec_pend
o-head_exe_request = FALSE;
o-saved_ramrod_flags = 0;
rc = ecore_exe_queue_step(sc, o-exe_queue, ramrod_flags);
-   if (rc != ECORE_SUCCESS) {
+   if ((rc != ECORE_SUCCESS)  (rc != ECORE_PENDING)) {
ECORE_ERR(execution of pending commands failed with rc %d\n,
  rc);
 #ifdef ECORE_STOP_ON_ERROR
___
svn-src-all@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/svn-src-all
To unsubscribe, send any mail to svn-src-all-unsubscr...@freebsd.org


svn commit: r284979 - stable/7/sys/dev/bxe

2015-06-30 Thread David C Somayajulu
Author: davidcs
Date: Tue Jun 30 20:37:04 2015
New Revision: 284979
URL: https://svnweb.freebsd.org/changeset/base/284979

Log:
  MFC r284335
  
  PHY LOCK acquires the hardware lock via bxe_acquire_phy_lock() and releases 
it via bxe_release_phy_lock(). It was simply acquiring a mutex earlier which 
can cause the PHY to use bogus values. Fixes intermittent link failures.
  
  bxe_ioctl() completes all functions within its context as opposed to a 
taskqueue earlier.
  
  bxe_handle_rx_mode_tq() no longer required. bxe_set_rx_mode() handles the 
functionality within its context
  
  Submitted by:gary.zambr...@qlogic.com

Modified:
  stable/7/sys/dev/bxe/bxe.c
  stable/7/sys/dev/bxe/bxe.h
  stable/7/sys/dev/bxe/ecore_reg.h
Directory Properties:
  stable/7/sys/   (props changed)

Modified: stable/7/sys/dev/bxe/bxe.c
==
--- stable/7/sys/dev/bxe/bxe.c  Tue Jun 30 20:31:00 2015(r284978)
+++ stable/7/sys/dev/bxe/bxe.c  Tue Jun 30 20:37:04 2015(r284979)
@@ -737,7 +737,6 @@ static __noinline int bxe_nic_unload(str
  uint8_t  keep_link);
 
 static void bxe_handle_sp_tq(void *context, int pending);
-static void bxe_handle_rx_mode_tq(void *context, int pending);
 static void bxe_handle_fp_tq(void *context, int pending);
 
 
@@ -1185,7 +1184,17 @@ bxe_release_hw_lock(struct bxe_softc *sc
 REG_WR(sc, hw_lock_control_reg, resource_bit);
 return (0);
 }
+static void bxe_acquire_phy_lock(struct bxe_softc *sc)
+{
+   BXE_PHY_LOCK(sc);
+   bxe_acquire_hw_lock(sc,HW_LOCK_RESOURCE_MDIO); 
+}
 
+static void bxe_release_phy_lock(struct bxe_softc *sc)
+{
+   bxe_release_hw_lock(sc,HW_LOCK_RESOURCE_MDIO); 
+   BXE_PHY_UNLOCK(sc);
+}
 /*
  * Per pf misc lock must be acquired before the per port mcp lock. Otherwise,
  * had we done things the other way around, if two pfs from the same port
@@ -4775,29 +4784,6 @@ bxe_handle_chip_tq(void *context,
 
 switch (work)
 {
-case CHIP_TQ_START:
-if ((sc-ifnet-if_flags  IFF_UP) 
-!(sc-ifnet-if_drv_flags  IFF_DRV_RUNNING)) {
-/* start the interface */
-BLOGD(sc, DBG_LOAD, Starting the interface...\n);
-BXE_CORE_LOCK(sc);
-bxe_init_locked(sc);
-BXE_CORE_UNLOCK(sc);
-}
-break;
-
-case CHIP_TQ_STOP:
-if (!(sc-ifnet-if_flags  IFF_UP) 
-(sc-ifnet-if_drv_flags  IFF_DRV_RUNNING)) {
-/* bring down the interface */
-BLOGD(sc, DBG_LOAD, Stopping the interface...\n);
-bxe_periodic_stop(sc);
-BXE_CORE_LOCK(sc);
-bxe_stop_locked(sc);
-BXE_CORE_UNLOCK(sc);
-}
-break;
-
 case CHIP_TQ_REINIT:
 if (sc-ifnet-if_drv_flags  IFF_DRV_RUNNING) {
 /* restart the interface */
@@ -4867,21 +4853,22 @@ bxe_ioctl(struct ifnet *ifp,
 /* toggle the interface state up or down */
 BLOGD(sc, DBG_IOCTL, Received SIOCSIFFLAGS ioctl\n);
 
+   BXE_CORE_LOCK(sc);
 /* check if the interface is up */
 if (ifp-if_flags  IFF_UP) {
 if (ifp-if_drv_flags  IFF_DRV_RUNNING) {
 /* set the receive mode flags */
 bxe_set_rx_mode(sc);
 } else {
-atomic_store_rel_long(sc-chip_tq_flags, CHIP_TQ_START);
-taskqueue_enqueue(sc-chip_tq, sc-chip_tq_task);
+   bxe_init_locked(sc);
 }
 } else {
 if (ifp-if_drv_flags  IFF_DRV_RUNNING) {
-atomic_store_rel_long(sc-chip_tq_flags, CHIP_TQ_STOP);
-taskqueue_enqueue(sc-chip_tq, sc-chip_tq_task);
+   bxe_periodic_stop(sc);
+   bxe_stop_locked(sc);
 }
 }
+   BXE_CORE_UNLOCK(sc);
 
 break;
 
@@ -4893,7 +4880,9 @@ bxe_ioctl(struct ifnet *ifp,
 /* check if the interface is up */
 if (ifp-if_drv_flags  IFF_DRV_RUNNING) {
 /* set the receive mode flags */
+   BXE_CORE_LOCK(sc);
 bxe_set_rx_mode(sc);
+   BXE_CORE_UNLOCK(sc); 
 }
 
 break;
@@ -5051,8 +5040,11 @@ bxe_ioctl(struct ifnet *ifp,
 if (reinit  (sc-ifnet-if_drv_flags  IFF_DRV_RUNNING)) {
 BLOGD(sc, DBG_LOAD | DBG_IOCTL,
   Re-initializing hardware from IOCTL change\n);
-atomic_store_rel_long(sc-chip_tq_flags, CHIP_TQ_REINIT);
-taskqueue_enqueue(sc-chip_tq, sc-chip_tq_task);
+   bxe_periodic_stop(sc);
+   BXE_CORE_LOCK(sc);
+   bxe_stop_locked(sc);
+   bxe_init_locked(sc);
+   BXE_CORE_UNLOCK(sc);
 }
 
 return (error);
@@ -7505,8 +7497,7 @@ bxe_attn_int_asserted(struct bxe_softc *
 if (asserted  ATTN_HARD_WIRED_MASK) {
 if (asserted  ATTN_NIG_FOR_FUNC) {
 
-BXE_PHY_LOCK(sc);
-
+   bxe_acquire_phy_lock(sc);
 /* save nig interrupt 

svn commit: r284975 - stable/9/sys/dev/bxe

2015-06-30 Thread David C Somayajulu
Author: davidcs
Date: Tue Jun 30 20:17:38 2015
New Revision: 284975
URL: https://svnweb.freebsd.org/changeset/base/284975

Log:
  MFC r284739
  tx_mtx should be grabbed before calling buf_ring_dequeue_sc()
  
  Submitted by:attilio@isilon.com

Modified:
  stable/9/sys/dev/bxe/bxe.c
Directory Properties:
  stable/9/   (props changed)
  stable/9/sys/   (props changed)
  stable/9/sys/dev/   (props changed)

Modified: stable/9/sys/dev/bxe/bxe.c
==
--- stable/9/sys/dev/bxe/bxe.c  Tue Jun 30 20:11:48 2015(r284974)
+++ stable/9/sys/dev/bxe/bxe.c  Tue Jun 30 20:17:38 2015(r284975)
@@ -6562,10 +6562,14 @@ bxe_free_fp_buffers(struct bxe_softc *sc
 
 #if __FreeBSD_version = 80
 if (fp-tx_br != NULL) {
-struct mbuf *m;
 /* just in case bxe_mq_flush() wasn't called */
-while ((m = buf_ring_dequeue_sc(fp-tx_br)) != NULL) {
-m_freem(m);
+if (mtx_initialized(fp-tx_mtx)) {
+struct mbuf *m;
+
+BXE_FP_TX_LOCK(fp);
+while ((m = buf_ring_dequeue_sc(fp-tx_br)) != NULL)
+m_freem(m);
+BXE_FP_TX_UNLOCK(fp);
 }
 buf_ring_free(fp-tx_br, M_DEVBUF);
 fp-tx_br = NULL;
___
svn-src-all@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/svn-src-all
To unsubscribe, send any mail to svn-src-all-unsubscr...@freebsd.org


svn commit: r284981 - stable/7/sys/dev/bxe

2015-06-30 Thread David C Somayajulu
Author: davidcs
Date: Tue Jun 30 20:45:41 2015
New Revision: 284981
URL: https://svnweb.freebsd.org/changeset/base/284981

Log:
  MFC r284739
  tx_mtx should be grabbed before calling buf_ring_dequeue_sc()
  
  Submitted by: attilio@isilon.com

Modified:
  stable/7/sys/dev/bxe/bxe.c
Directory Properties:
  stable/7/sys/   (props changed)

Modified: stable/7/sys/dev/bxe/bxe.c
==
--- stable/7/sys/dev/bxe/bxe.c  Tue Jun 30 20:40:38 2015(r284980)
+++ stable/7/sys/dev/bxe/bxe.c  Tue Jun 30 20:45:41 2015(r284981)
@@ -6564,10 +6564,14 @@ bxe_free_fp_buffers(struct bxe_softc *sc
 
 #if __FreeBSD_version = 80
 if (fp-tx_br != NULL) {
-struct mbuf *m;
 /* just in case bxe_mq_flush() wasn't called */
-while ((m = buf_ring_dequeue_sc(fp-tx_br)) != NULL) {
-m_freem(m);
+if (mtx_initialized(fp-tx_mtx)) {
+struct mbuf *m;
+
+BXE_FP_TX_LOCK(fp);
+while ((m = buf_ring_dequeue_sc(fp-tx_br)) != NULL)
+m_freem(m);
+BXE_FP_TX_UNLOCK(fp);
 }
 buf_ring_free(fp-tx_br, M_DEVBUF);
 fp-tx_br = NULL;
___
svn-src-all@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/svn-src-all
To unsubscribe, send any mail to svn-src-all-unsubscr...@freebsd.org


svn commit: r284982 - in stable/10/sys: dev/qlxgbe modules/qlxgbe

2015-06-30 Thread David C Somayajulu
Author: davidcs
Date: Tue Jun 30 20:59:07 2015
New Revision: 284982
URL: https://svnweb.freebsd.org/changeset/base/284982

Log:
  MFC r284741
  
  Updated Copyright information
  Added support for the following:
   - iSCSI TLV (requires 64 Tx and 32 Rx rings
   - 9K receive buffers for jumbo frames (feature may be enabled/disabled)
   - builtin firmware, bootloader and minidump template
   - quick stats
   - async event handling for SFP insertion/removal and DCBX changes
   - Configuring DCBX and interrupt coalescing parameters

Added:
  stable/10/sys/dev/qlxgbe/ql_boot.c
 - copied unchanged from r284741, head/sys/dev/qlxgbe/ql_boot.c
  stable/10/sys/dev/qlxgbe/ql_fw.c
 - copied unchanged from r284741, head/sys/dev/qlxgbe/ql_fw.c
  stable/10/sys/dev/qlxgbe/ql_minidump.c
 - copied unchanged from r284741, head/sys/dev/qlxgbe/ql_minidump.c
Modified:
  stable/10/sys/dev/qlxgbe/ql_dbg.c
  stable/10/sys/dev/qlxgbe/ql_dbg.h
  stable/10/sys/dev/qlxgbe/ql_def.h
  stable/10/sys/dev/qlxgbe/ql_glbl.h
  stable/10/sys/dev/qlxgbe/ql_hw.c
  stable/10/sys/dev/qlxgbe/ql_hw.h
  stable/10/sys/dev/qlxgbe/ql_inline.h
  stable/10/sys/dev/qlxgbe/ql_ioctl.c
  stable/10/sys/dev/qlxgbe/ql_ioctl.h
  stable/10/sys/dev/qlxgbe/ql_isr.c
  stable/10/sys/dev/qlxgbe/ql_misc.c
  stable/10/sys/dev/qlxgbe/ql_os.c
  stable/10/sys/dev/qlxgbe/ql_os.h
  stable/10/sys/dev/qlxgbe/ql_reset.c
  stable/10/sys/dev/qlxgbe/ql_tmplt.h
  stable/10/sys/dev/qlxgbe/ql_ver.h
  stable/10/sys/modules/qlxgbe/Makefile
Directory Properties:
  stable/10/   (props changed)

Copied: stable/10/sys/dev/qlxgbe/ql_boot.c (from r284741, 
head/sys/dev/qlxgbe/ql_boot.c)
==
--- /dev/null   00:00:00 1970   (empty, because file is newly added)
+++ stable/10/sys/dev/qlxgbe/ql_boot.c  Tue Jun 30 20:59:07 2015
(r284982, copy of r284741, head/sys/dev/qlxgbe/ql_boot.c)
@@ -0,0 +1,10964 @@
+/*
+ * Copyright (c) 2012-2016 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_boot.c
+ */
+#include sys/cdefs.h
+__FBSDID($FreeBSD$);
+
+#include ql_os.h
+
+unsigned int ql83xx_bootloader_version_major = 5;
+unsigned int ql83xx_bootloader_version_minor = 2;
+unsigned int ql83xx_bootloader_version_sub = 7;
+unsigned char ql83xx_bootloader[] = {
+  0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+  0x00, 0x00, 0x00, 0xa0, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+  0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xa0, 0x00, 0x00, 0x00, 0x00,
+  0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xa0,
+  0x04, 0x00, 0x80, 0x82, 0x05, 0x1f, 0x00, 0x1c, 0x00, 0x00, 0x00, 0x00,
+  0x00, 0x00, 0x00, 0x80, 0x1e, 0x02, 0x21, 0x00, 0x08, 0x00, 0x00, 0x00,
+  0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x02, 0x00, 0x20, 0x00,
+  0x00, 0x00, 0x00, 0x00, 0x04, 0x01, 0x7c, 0x00, 0x00, 0x00, 0x00, 0x70,
+  0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+  0x00, 0x00, 0x00, 0xa0, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+  0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xa0, 0x00, 0x00, 0x00, 0x00,
+  0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xa0,
+  0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+  0x00, 0x00, 0x00, 0xa0, 0x02, 0x00, 0x20, 0x00, 0x00, 0x00, 0x00, 0x00,
+  0x21, 0x00, 0x7c, 0x00, 0x00, 0x00, 0x00, 0x70, 0x00, 0x00, 0x00, 0x00,
+  0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xa0,
+  0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+  0x00, 0x00, 0x00, 0xa0, 0x00, 0x00, 0x00, 

Re: svn commit: r284965 - head/lib/libc/sys

2015-06-30 Thread Justin Hibbits
On Tue, Jun 30, 2015 at 11:53 AM, Konstantin Belousov k...@freebsd.org wrote:
 Author: kib
 Date: Tue Jun 30 18:53:42 2015
 New Revision: 284965
 URL: https://svnweb.freebsd.org/changeset/base/284965

 Log:
   Document x86 machine-specific ptrace(2) requests.  Provide list of the
   ppc requests.

   Reviewed by:  brueffer, emaste, gjb (previous version)
   Sponsored by: The FreeBSD Foundation
   Review:   https://reviews.freebsd.org/D2962
   MFC after:2 weeks

 Modified:
   head/lib/libc/sys/ptrace.2

...
 +.Sh PowerPC MACHINE-SPECIFIC REQUESTS
 +.Bl -tag -width Dv PT_SETVRREGS
 +.It Dv PT_GETVRREGS
 +Returns the
 +.Dv ALTIVEC
 +machine state for the thread into the buffer pointed to by
 +the argument
 +.Fa addr .
 +.Pp
 +The
 +.Fa data
 +argument is ignored.
 +.It Dv PT_SETVRREGS
 +Set the
 +.Dv ALTIVEC
 +machine state for the thread from the buffer pointed to by
 +the argument
 +.Fa addr .
 +.Pp
 +The
 +.Fa data
 +argument is ignored.
 +.El
 +.Pp

Thanks for documenting these.  I'm way too lazy for my own good when
it comes to documentation.

- Justin
___
svn-src-all@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/svn-src-all
To unsubscribe, send any mail to svn-src-all-unsubscr...@freebsd.org


svn commit: r284968 - head/release

2015-06-30 Thread Glen Barber
Author: gjb
Date: Tue Jun 30 19:18:08 2015
New Revision: 284968
URL: https://svnweb.freebsd.org/changeset/base/284968

Log:
  Default the VAGRANT_VERSION to ${REVISION}-${BRANCH} if
  not set, which expands to '11.0-CURRENT', for example.
  
  If the branch is -CURRENT, -STABLE, or -PRERELEASE, suffix
  the VAGRANT_VERSION with the snapshot date.
  
  MFC after:3 days
  X-MFC-Needs:  r284893, r284895, r284896, r284897, r284942
  Tested with:  head@r284961 (patched)
  Sponsored by: The FreeBSD Foundation

Modified:
  head/release/Makefile.vagrant

Modified: head/release/Makefile.vagrant
==
--- head/release/Makefile.vagrant   Tue Jun 30 19:06:14 2015
(r284967)
+++ head/release/Makefile.vagrant   Tue Jun 30 19:18:08 2015
(r284968)
@@ -11,7 +11,7 @@ VAGRANT_UPLOAD_TGTS=  vagrant-check-depen
 CLEANFILES+=   ${VAGRANT_UPLOAD_TGTS}
 
 .if defined(VAGRANT_UPLOAD_CONF)  !empty(VAGRANT_UPLOAD_CONF)
-. for VAR in _KEY _USERNAME _VERSION
+. for VAR in _KEY _USERNAME
 VAGRANT${VAR}!=grep -E ^VAGRANT${VAR} ${VAGRANT_UPLOAD_CONF} | 
awk -F' ' '{print $$2}'
 ATLAS${VAR}:=  ${VAGRANT${VAR}}
 . endfor
@@ -21,6 +21,8 @@ ATLAS${VAR}:= ${VAGRANT${VAR}}
 SNAPSHOT_DATE!=date +-%Y-%m-%d-%H-%M
 .endif
 
+VAGRANT_VERSION?=  ${REVISION}-${BRANCH}${SNAPSHOT_DATE}
+
 VAGRANT_TARGET:=   ${OSRELEASE}${SNAPSHOT_DATE}.box
 VAGRANT_PROVIDERS?=vmware_desktop
 #VAGRANT_PROVIDERS+=   virtualbox
@@ -54,7 +56,7 @@ vagrant-do-package-vmware: vagrant-creat
 
 atlas-do-upload: vagrant-do-package-vmware
 .for PROVIDER in ${VAGRANT_PROVIDERS}
-   ${.CURDIR}/scripts/atlas-upload.sh -b FreeBSD-${REVISION}-${BRANCH} -f 
${VAGRANT_TARGET} -p ${PROVIDER} -k ${VAGRANT_KEY} -u ${VAGRANT_USERNAME} -v 0.1
+   ${.CURDIR}/scripts/atlas-upload.sh -b FreeBSD-${REVISION}-${BRANCH} -f 
${VAGRANT_TARGET} -p ${PROVIDER} -k ${VAGRANT_KEY} -u ${VAGRANT_USERNAME} -v 
${VAGRANT_VERSION}
 .endfor
touch ${.OBJDIR}/${.TARGET}
 
___
svn-src-all@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/svn-src-all
To unsubscribe, send any mail to svn-src-all-unsubscr...@freebsd.org


Re: svn commit: r284973 - stable/9

2015-06-30 Thread Glen Barber
On Tue, Jun 30, 2015 at 08:01:24PM +, David C Somayajulu wrote:
 Author: davidcs
 Date: Tue Jun 30 20:01:24 2015
 New Revision: 284973
 URL: https://svnweb.freebsd.org/changeset/base/284973
 
 Log:
   MFC r284739
 tx_mtx should be grabbed before calling buf_ring_dequeue_sc()
   
   Submitted by:   attilio@isilon.com
 
 Modified:
 Directory Properties:
   stable/9/   (props changed)
 

Something does not look right here.  It looks like the file change(s)
did not get committed.

Glen



pgpZCrxTeQTyd.pgp
Description: PGP signature


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

2015-06-30 Thread John-Mark Gurney
Author: jmg
Date: Tue Jun 30 19:06:14 2015
New Revision: 284967
URL: https://svnweb.freebsd.org/changeset/base/284967

Log:
  add units to the length and count so that it's clear what they
  are measured in...  Gems like: len is the length of the buffer.
  aren't useful in man pages.

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

Modified: head/share/man/man9/hash.9
==
--- head/share/man/man9/hash.9  Tue Jun 30 18:58:33 2015(r284966)
+++ head/share/man/man9/hash.9  Tue Jun 30 19:06:14 2015(r284967)
@@ -26,7 +26,7 @@
 .\ $OpenBSD: hash.9,v 1.5 2003/04/17 05:08:39 jmc Exp $
 .\ $FreeBSD$
 .\
-.Dd October 18, 2014
+.Dd June 30, 2015
 .Dt HASH 9
 .Os
 .Sh NAME
@@ -72,6 +72,13 @@ These functions can be used to hash
 .Dv NUL
 terminated strings, as well as blocks of memory.
 .Pp
+A
+.Fa len
+argument is the length of the buffer in bytes.
+A
+.Fa count
+argument is the length of the buffer in 32-bit words.
+.Pp
 The
 .Fn hash32_buf
 function is used as a general buffer hashing function.
@@ -79,7 +86,7 @@ The argument
 .Fa buf
 is used to pass in the location, and
 .Fa len
-is the length of the buffer.
+is the length of the buffer in bytes.
 The argument
 .Fa hash
 is used to extend an existing hash, or is passed the initial value
___
svn-src-all@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/svn-src-all
To unsubscribe, send any mail to svn-src-all-unsubscr...@freebsd.org


svn commit: r284972 - stable/9/sys/dev/bxe

2015-06-30 Thread David C Somayajulu
Author: davidcs
Date: Tue Jun 30 19:59:19 2015
New Revision: 284972
URL: https://svnweb.freebsd.org/changeset/base/284972

Log:
  MFC r284470
  In bxe_init_mcast_macs_list(): mc_mac-mac needs to point to the multicast 
mac address
  In bxe_set_mc_list(): added missing BXE_MCAST_UNLOCK()
  In __ecore_vlan_mac_h_exec_pending(): need to check for ECORE_PENDING
  
  Submitted by:gary.zambr...@qlogic.com

Modified:
  stable/9/sys/dev/bxe/bxe.c
  stable/9/sys/dev/bxe/ecore_sp.c
Directory Properties:
  stable/9/   (props changed)
  stable/9/sys/   (props changed)
  stable/9/sys/dev/   (props changed)

Modified: stable/9/sys/dev/bxe/bxe.c
==
--- stable/9/sys/dev/bxe/bxe.c  Tue Jun 30 19:53:59 2015(r284971)
+++ stable/9/sys/dev/bxe/bxe.c  Tue Jun 30 19:59:19 2015(r284972)
@@ -12544,6 +12544,7 @@ bxe_init_mcast_macs_list(struct bxe_soft
 BLOGE(sc, Failed to allocate temp mcast list\n);
 return (-1);
 }
+bzero(mc_mac, (sizeof(*mc_mac) * mc_count));
 
 TAILQ_FOREACH(ifma, ifp-if_multiaddrs, ifma_link) {
 if (ifma-ifma_addr-sa_family != AF_LINK) {
@@ -12594,6 +12595,7 @@ bxe_set_mc_list(struct bxe_softc *sc)
 rc = ecore_config_mcast(sc, rparam, ECORE_MCAST_CMD_DEL);
 if (rc  0) {
 BLOGE(sc, Failed to clear multicast configuration: %d\n, rc);
+BXE_MCAST_UNLOCK(sc);
 return (rc);
 }
 

Modified: stable/9/sys/dev/bxe/ecore_sp.c
==
--- stable/9/sys/dev/bxe/ecore_sp.c Tue Jun 30 19:53:59 2015
(r284971)
+++ stable/9/sys/dev/bxe/ecore_sp.c Tue Jun 30 19:59:19 2015
(r284972)
@@ -474,7 +474,7 @@ static void __ecore_vlan_mac_h_exec_pend
o-head_exe_request = FALSE;
o-saved_ramrod_flags = 0;
rc = ecore_exe_queue_step(sc, o-exe_queue, ramrod_flags);
-   if (rc != ECORE_SUCCESS) {
+   if ((rc != ECORE_SUCCESS)  (rc != ECORE_PENDING)) {
ECORE_ERR(execution of pending commands failed with rc %d\n,
  rc);
 #ifdef ECORE_STOP_ON_ERROR
___
svn-src-all@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/svn-src-all
To unsubscribe, send any mail to svn-src-all-unsubscr...@freebsd.org


svn commit: r284974 - stable/9

2015-06-30 Thread David C Somayajulu
Author: davidcs
Date: Tue Jun 30 20:11:48 2015
New Revision: 284974
URL: https://svnweb.freebsd.org/changeset/base/284974

Log:
  reverse r284973

Modified:
Directory Properties:
  stable/9/   (props changed)
___
svn-src-all@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/svn-src-all
To unsubscribe, send any mail to svn-src-all-unsubscr...@freebsd.org


svn commit: r284969 - head/sys/modules/hyperv/netvsc

2015-06-30 Thread Li-Wen Hsu
Author: lwhsu (ports committer)
Date: Tue Jun 30 19:35:14 2015
New Revision: 284969
URL: https://svnweb.freebsd.org/changeset/base/284969

Log:
  - Fix `make depend` in sys/modules
  
  Differential Revision:https://reviews.freebsd.org/D2951
  Approved by:  delphij

Modified:
  head/sys/modules/hyperv/netvsc/Makefile

Modified: head/sys/modules/hyperv/netvsc/Makefile
==
--- head/sys/modules/hyperv/netvsc/Makefile Tue Jun 30 19:18:08 2015
(r284968)
+++ head/sys/modules/hyperv/netvsc/Makefile Tue Jun 30 19:35:14 2015
(r284969)
@@ -6,7 +6,7 @@ KMOD=   hv_netvsc
 SRCS=  hv_net_vsc.c \
hv_netvsc_drv_freebsd.c \
hv_rndis_filter.c
-SRCS+= bus_if.h device_if.h
+SRCS+= bus_if.h device_if.h opt_inet.h opt_inet6.h
 
 CFLAGS+= -I${.CURDIR}/../../../dev/hyperv/netvsc
 
___
svn-src-all@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/svn-src-all
To unsubscribe, send any mail to svn-src-all-unsubscr...@freebsd.org


svn commit: r284978 - stable/8/sys/dev/bxe

2015-06-30 Thread David C Somayajulu
Author: davidcs
Date: Tue Jun 30 20:31:00 2015
New Revision: 284978
URL: https://svnweb.freebsd.org/changeset/base/284978

Log:
  MFC r284739
tx_mtx should be grabbed before calling buf_ring_dequeue_sc()
  
  Submitted by: attilio@isilon.com

Modified:
  stable/8/sys/dev/bxe/bxe.c
Directory Properties:
  stable/8/   (props changed)
  stable/8/sys/   (props changed)
  stable/8/sys/dev/   (props changed)

Modified: stable/8/sys/dev/bxe/bxe.c
==
--- stable/8/sys/dev/bxe/bxe.c  Tue Jun 30 20:28:07 2015(r284977)
+++ stable/8/sys/dev/bxe/bxe.c  Tue Jun 30 20:31:00 2015(r284978)
@@ -6562,10 +6562,14 @@ bxe_free_fp_buffers(struct bxe_softc *sc
 
 #if __FreeBSD_version = 80
 if (fp-tx_br != NULL) {
-struct mbuf *m;
 /* just in case bxe_mq_flush() wasn't called */
-while ((m = buf_ring_dequeue_sc(fp-tx_br)) != NULL) {
-m_freem(m);
+if (mtx_initialized(fp-tx_mtx)) {
+struct mbuf *m;
+
+BXE_FP_TX_LOCK(fp);
+while ((m = buf_ring_dequeue_sc(fp-tx_br)) != NULL)
+m_freem(m);
+BXE_FP_TX_UNLOCK(fp);
 }
 buf_ring_free(fp-tx_br, M_DEVBUF);
 fp-tx_br = NULL;
___
svn-src-all@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/svn-src-all
To unsubscribe, send any mail to svn-src-all-unsubscr...@freebsd.org


svn commit: r284971 - stable/9/sys/dev/bxe

2015-06-30 Thread David C Somayajulu
Author: davidcs
Date: Tue Jun 30 19:53:59 2015
New Revision: 284971
URL: https://svnweb.freebsd.org/changeset/base/284971

Log:
  MFC r284335
  
  PHY LOCK acquires the hardware lock via bxe_acquire_phy_lock() and releases 
it via bxe_release_phy_lock(). It was simply acquiring a mutex earlier which 
can cause the PHY to use bogus values. Fixes intermittent link failures.
  
  bxe_ioctl() completes all functions within its context as opposed to a 
taskqueue earlier.
  
  bxe_handle_rx_mode_tq() no longer required. bxe_set_rx_mode() handles the 
functionality within its context
  
  Submitted by:gary.zambr...@qlogic.com

Modified:
  stable/9/sys/dev/bxe/bxe.c
  stable/9/sys/dev/bxe/bxe.h
  stable/9/sys/dev/bxe/ecore_reg.h
Directory Properties:
  stable/9/   (props changed)
  stable/9/sys/   (props changed)
  stable/9/sys/dev/   (props changed)

Modified: stable/9/sys/dev/bxe/bxe.c
==
--- stable/9/sys/dev/bxe/bxe.c  Tue Jun 30 19:53:26 2015(r284970)
+++ stable/9/sys/dev/bxe/bxe.c  Tue Jun 30 19:53:59 2015(r284971)
@@ -737,7 +737,6 @@ static __noinline int bxe_nic_unload(str
  uint8_t  keep_link);
 
 static void bxe_handle_sp_tq(void *context, int pending);
-static void bxe_handle_rx_mode_tq(void *context, int pending);
 static void bxe_handle_fp_tq(void *context, int pending);
 
 
@@ -1185,7 +1184,17 @@ bxe_release_hw_lock(struct bxe_softc *sc
 REG_WR(sc, hw_lock_control_reg, resource_bit);
 return (0);
 }
+static void bxe_acquire_phy_lock(struct bxe_softc *sc)
+{
+   BXE_PHY_LOCK(sc);
+   bxe_acquire_hw_lock(sc,HW_LOCK_RESOURCE_MDIO); 
+}
 
+static void bxe_release_phy_lock(struct bxe_softc *sc)
+{
+   bxe_release_hw_lock(sc,HW_LOCK_RESOURCE_MDIO); 
+   BXE_PHY_UNLOCK(sc);
+}
 /*
  * Per pf misc lock must be acquired before the per port mcp lock. Otherwise,
  * had we done things the other way around, if two pfs from the same port
@@ -4775,29 +4784,6 @@ bxe_handle_chip_tq(void *context,
 
 switch (work)
 {
-case CHIP_TQ_START:
-if ((sc-ifnet-if_flags  IFF_UP) 
-!(sc-ifnet-if_drv_flags  IFF_DRV_RUNNING)) {
-/* start the interface */
-BLOGD(sc, DBG_LOAD, Starting the interface...\n);
-BXE_CORE_LOCK(sc);
-bxe_init_locked(sc);
-BXE_CORE_UNLOCK(sc);
-}
-break;
-
-case CHIP_TQ_STOP:
-if (!(sc-ifnet-if_flags  IFF_UP) 
-(sc-ifnet-if_drv_flags  IFF_DRV_RUNNING)) {
-/* bring down the interface */
-BLOGD(sc, DBG_LOAD, Stopping the interface...\n);
-bxe_periodic_stop(sc);
-BXE_CORE_LOCK(sc);
-bxe_stop_locked(sc);
-BXE_CORE_UNLOCK(sc);
-}
-break;
-
 case CHIP_TQ_REINIT:
 if (sc-ifnet-if_drv_flags  IFF_DRV_RUNNING) {
 /* restart the interface */
@@ -4867,21 +4853,22 @@ bxe_ioctl(struct ifnet *ifp,
 /* toggle the interface state up or down */
 BLOGD(sc, DBG_IOCTL, Received SIOCSIFFLAGS ioctl\n);
 
+   BXE_CORE_LOCK(sc);
 /* check if the interface is up */
 if (ifp-if_flags  IFF_UP) {
 if (ifp-if_drv_flags  IFF_DRV_RUNNING) {
 /* set the receive mode flags */
 bxe_set_rx_mode(sc);
 } else {
-atomic_store_rel_long(sc-chip_tq_flags, CHIP_TQ_START);
-taskqueue_enqueue(sc-chip_tq, sc-chip_tq_task);
+   bxe_init_locked(sc);
 }
 } else {
 if (ifp-if_drv_flags  IFF_DRV_RUNNING) {
-atomic_store_rel_long(sc-chip_tq_flags, CHIP_TQ_STOP);
-taskqueue_enqueue(sc-chip_tq, sc-chip_tq_task);
+   bxe_periodic_stop(sc);
+   bxe_stop_locked(sc);
 }
 }
+   BXE_CORE_UNLOCK(sc);
 
 break;
 
@@ -4893,7 +4880,9 @@ bxe_ioctl(struct ifnet *ifp,
 /* check if the interface is up */
 if (ifp-if_drv_flags  IFF_DRV_RUNNING) {
 /* set the receive mode flags */
+   BXE_CORE_LOCK(sc);
 bxe_set_rx_mode(sc);
+   BXE_CORE_UNLOCK(sc); 
 }
 
 break;
@@ -5051,8 +5040,11 @@ bxe_ioctl(struct ifnet *ifp,
 if (reinit  (sc-ifnet-if_drv_flags  IFF_DRV_RUNNING)) {
 BLOGD(sc, DBG_LOAD | DBG_IOCTL,
   Re-initializing hardware from IOCTL change\n);
-atomic_store_rel_long(sc-chip_tq_flags, CHIP_TQ_REINIT);
-taskqueue_enqueue(sc-chip_tq, sc-chip_tq_task);
+   bxe_periodic_stop(sc);
+   BXE_CORE_LOCK(sc);
+   bxe_stop_locked(sc);
+   bxe_init_locked(sc);
+   BXE_CORE_UNLOCK(sc);
 }
 
 return (error);
@@ -7503,8 +7495,7 @@ bxe_attn_int_asserted(struct bxe_softc *
 if (asserted  ATTN_HARD_WIRED_MASK) {
 if (asserted  ATTN_NIG_FOR_FUNC) {
 
-BXE_PHY_LOCK(sc);
-
+   

svn commit: r284976 - stable/8/sys/dev/bxe

2015-06-30 Thread David C Somayajulu
Author: davidcs
Date: Tue Jun 30 20:24:23 2015
New Revision: 284976
URL: https://svnweb.freebsd.org/changeset/base/284976

Log:
  MFC r284335
  
  PHY LOCK acquires the hardware lock via bxe_acquire_phy_lock() and releases 
it via bxe_release_phy_lock(). It was simply acquiring a mutex earlier which 
can cause the PHY to use bogus values. Fixes intermittent link failures.
  
  bxe_ioctl() completes all functions within its context as opposed to a 
taskqueue earlier.
  
  bxe_handle_rx_mode_tq() no longer required. bxe_set_rx_mode() handles the 
functionality within its context
  
  Submitted by:gary.zambr...@qlogic.com

Modified:
  stable/8/sys/dev/bxe/bxe.c
  stable/8/sys/dev/bxe/bxe.h
  stable/8/sys/dev/bxe/ecore_reg.h
Directory Properties:
  stable/8/   (props changed)
  stable/8/sys/   (props changed)
  stable/8/sys/dev/   (props changed)

Modified: stable/8/sys/dev/bxe/bxe.c
==
--- stable/8/sys/dev/bxe/bxe.c  Tue Jun 30 20:17:38 2015(r284975)
+++ stable/8/sys/dev/bxe/bxe.c  Tue Jun 30 20:24:23 2015(r284976)
@@ -737,7 +737,6 @@ static __noinline int bxe_nic_unload(str
  uint8_t  keep_link);
 
 static void bxe_handle_sp_tq(void *context, int pending);
-static void bxe_handle_rx_mode_tq(void *context, int pending);
 static void bxe_handle_fp_tq(void *context, int pending);
 
 
@@ -1185,7 +1184,17 @@ bxe_release_hw_lock(struct bxe_softc *sc
 REG_WR(sc, hw_lock_control_reg, resource_bit);
 return (0);
 }
+static void bxe_acquire_phy_lock(struct bxe_softc *sc)
+{
+   BXE_PHY_LOCK(sc);
+   bxe_acquire_hw_lock(sc,HW_LOCK_RESOURCE_MDIO); 
+}
 
+static void bxe_release_phy_lock(struct bxe_softc *sc)
+{
+   bxe_release_hw_lock(sc,HW_LOCK_RESOURCE_MDIO); 
+   BXE_PHY_UNLOCK(sc);
+}
 /*
  * Per pf misc lock must be acquired before the per port mcp lock. Otherwise,
  * had we done things the other way around, if two pfs from the same port
@@ -4775,29 +4784,6 @@ bxe_handle_chip_tq(void *context,
 
 switch (work)
 {
-case CHIP_TQ_START:
-if ((sc-ifnet-if_flags  IFF_UP) 
-!(sc-ifnet-if_drv_flags  IFF_DRV_RUNNING)) {
-/* start the interface */
-BLOGD(sc, DBG_LOAD, Starting the interface...\n);
-BXE_CORE_LOCK(sc);
-bxe_init_locked(sc);
-BXE_CORE_UNLOCK(sc);
-}
-break;
-
-case CHIP_TQ_STOP:
-if (!(sc-ifnet-if_flags  IFF_UP) 
-(sc-ifnet-if_drv_flags  IFF_DRV_RUNNING)) {
-/* bring down the interface */
-BLOGD(sc, DBG_LOAD, Stopping the interface...\n);
-bxe_periodic_stop(sc);
-BXE_CORE_LOCK(sc);
-bxe_stop_locked(sc);
-BXE_CORE_UNLOCK(sc);
-}
-break;
-
 case CHIP_TQ_REINIT:
 if (sc-ifnet-if_drv_flags  IFF_DRV_RUNNING) {
 /* restart the interface */
@@ -4867,21 +4853,22 @@ bxe_ioctl(struct ifnet *ifp,
 /* toggle the interface state up or down */
 BLOGD(sc, DBG_IOCTL, Received SIOCSIFFLAGS ioctl\n);
 
+   BXE_CORE_LOCK(sc);
 /* check if the interface is up */
 if (ifp-if_flags  IFF_UP) {
 if (ifp-if_drv_flags  IFF_DRV_RUNNING) {
 /* set the receive mode flags */
 bxe_set_rx_mode(sc);
 } else {
-atomic_store_rel_long(sc-chip_tq_flags, CHIP_TQ_START);
-taskqueue_enqueue(sc-chip_tq, sc-chip_tq_task);
+   bxe_init_locked(sc);
 }
 } else {
 if (ifp-if_drv_flags  IFF_DRV_RUNNING) {
-atomic_store_rel_long(sc-chip_tq_flags, CHIP_TQ_STOP);
-taskqueue_enqueue(sc-chip_tq, sc-chip_tq_task);
+   bxe_periodic_stop(sc);
+   bxe_stop_locked(sc);
 }
 }
+   BXE_CORE_UNLOCK(sc);
 
 break;
 
@@ -4893,7 +4880,9 @@ bxe_ioctl(struct ifnet *ifp,
 /* check if the interface is up */
 if (ifp-if_drv_flags  IFF_DRV_RUNNING) {
 /* set the receive mode flags */
+   BXE_CORE_LOCK(sc);
 bxe_set_rx_mode(sc);
+   BXE_CORE_UNLOCK(sc); 
 }
 
 break;
@@ -5051,8 +5040,11 @@ bxe_ioctl(struct ifnet *ifp,
 if (reinit  (sc-ifnet-if_drv_flags  IFF_DRV_RUNNING)) {
 BLOGD(sc, DBG_LOAD | DBG_IOCTL,
   Re-initializing hardware from IOCTL change\n);
-atomic_store_rel_long(sc-chip_tq_flags, CHIP_TQ_REINIT);
-taskqueue_enqueue(sc-chip_tq, sc-chip_tq_task);
+   bxe_periodic_stop(sc);
+   BXE_CORE_LOCK(sc);
+   bxe_stop_locked(sc);
+   bxe_init_locked(sc);
+   BXE_CORE_UNLOCK(sc);
 }
 
 return (error);
@@ -7503,8 +7495,7 @@ bxe_attn_int_asserted(struct bxe_softc *
 if (asserted  ATTN_HARD_WIRED_MASK) {
 if (asserted  ATTN_NIG_FOR_FUNC) {
 
-BXE_PHY_LOCK(sc);
-
+   

svn commit: r284980 - stable/7/sys/dev/bxe

2015-06-30 Thread David C Somayajulu
Author: davidcs
Date: Tue Jun 30 20:40:38 2015
New Revision: 284980
URL: https://svnweb.freebsd.org/changeset/base/284980

Log:
  MFC r284470
  In bxe_set_mc_list(): added missing BXE_MCAST_UNLOCK()
  In __ecore_vlan_mac_h_exec_pending(): need to check for ECORE_PENDING
  
  Submitted by:gary.zambr...@qlogic.com

Modified:
  stable/7/sys/dev/bxe/bxe.c
  stable/7/sys/dev/bxe/ecore_sp.c
Directory Properties:
  stable/7/sys/   (props changed)

Modified: stable/7/sys/dev/bxe/bxe.c
==
--- stable/7/sys/dev/bxe/bxe.c  Tue Jun 30 20:37:04 2015(r284979)
+++ stable/7/sys/dev/bxe/bxe.c  Tue Jun 30 20:40:38 2015(r284980)
@@ -12546,6 +12546,7 @@ bxe_init_mcast_macs_list(struct bxe_soft
 BLOGE(sc, Failed to allocate temp mcast list\n);
 return (-1);
 }
+bzero(mc_mac, (sizeof(*mc_mac) * mc_count));
 
 TAILQ_FOREACH(ifma, ifp-if_multiaddrs, ifma_link) {
 if (ifma-ifma_addr-sa_family != AF_LINK) {
@@ -12596,6 +12597,7 @@ bxe_set_mc_list(struct bxe_softc *sc)
 rc = ecore_config_mcast(sc, rparam, ECORE_MCAST_CMD_DEL);
 if (rc  0) {
 BLOGE(sc, Failed to clear multicast configuration: %d\n, rc);
+BXE_MCAST_UNLOCK(sc);
 return (rc);
 }
 

Modified: stable/7/sys/dev/bxe/ecore_sp.c
==
--- stable/7/sys/dev/bxe/ecore_sp.c Tue Jun 30 20:37:04 2015
(r284979)
+++ stable/7/sys/dev/bxe/ecore_sp.c Tue Jun 30 20:40:38 2015
(r284980)
@@ -474,7 +474,7 @@ static void __ecore_vlan_mac_h_exec_pend
o-head_exe_request = FALSE;
o-saved_ramrod_flags = 0;
rc = ecore_exe_queue_step(sc, o-exe_queue, ramrod_flags);
-   if (rc != ECORE_SUCCESS) {
+   if ((rc != ECORE_SUCCESS)  (rc != ECORE_PENDING)) {
ECORE_ERR(execution of pending commands failed with rc %d\n,
  rc);
 #ifdef ECORE_STOP_ON_ERROR
___
svn-src-all@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/svn-src-all
To unsubscribe, send any mail to svn-src-all-unsubscr...@freebsd.org


svn commit: r284965 - head/lib/libc/sys

2015-06-30 Thread Konstantin Belousov
Author: kib
Date: Tue Jun 30 18:53:42 2015
New Revision: 284965
URL: https://svnweb.freebsd.org/changeset/base/284965

Log:
  Document x86 machine-specific ptrace(2) requests.  Provide list of the
  ppc requests.
  
  Reviewed by:  brueffer, emaste, gjb (previous version)
  Sponsored by: The FreeBSD Foundation
  Review:   https://reviews.freebsd.org/D2962
  MFC after:2 weeks

Modified:
  head/lib/libc/sys/ptrace.2

Modified: head/lib/libc/sys/ptrace.2
==
--- head/lib/libc/sys/ptrace.2  Tue Jun 30 18:23:08 2015(r284964)
+++ head/lib/libc/sys/ptrace.2  Tue Jun 30 18:53:42 2015(r284965)
@@ -2,7 +2,7 @@
 .\$NetBSD: ptrace.2,v 1.2 1995/02/27 12:35:37 cgd Exp $
 .\
 .\ This file is in the public domain.
-.Dd July 22, 2013
+.Dd June 30, 2015
 .Dt PTRACE 2
 .Os
 .Sh NAME
@@ -503,8 +503,161 @@ The
 .Fa data
 argument is ignored.
 .El
+.Sh x86 MACHINE-SPECIFIC REQUESTS
+.Bl -tag -width Dv PT_GETXSTATE_INFO
+.It Dv PT_GETXMMREGS
+Copies out the XMM FPU state into the buffer pointed to by the
+argument
+.Fa addr .
+The buffer has the same layout as the 32bit save buffer for the
+machine instruction
+.Dv FXSAVE .
+.Pp
+This request is only valid for i386 programs, both on native 32bit
+systems and on amd64 kernels.
+For 64bit amd64 programs, the XMM state is reported as part of
+the FPU state returned by the
+.Dv PT_GETFPREGS
+request.
+.Pp
+The
+.Fa data
+argument is ignored.
+.It Dv PT_SETXMMREGS
+Loads the XMM FPU state for the thread from the buffer pointed to
+by the argument
+.Fa addr .
+The buffer has the same layout as the 32bit load buffer for the
+machine instruction
+.Dv FXRSTOR .
+.Pp
+As with
+.Dv PT_GETXMMREGS,
+this request is only valid for i386 programs.
+.Pp
+The
+.Fa data
+argument is ignored.
+.It Dv PT_GETXSTATE_INFO
+Returns the information about the enablement state of the XSAVE FPU
+extensions supported by the CPU and allowed by the OS for use by userspace
+programs.
+The
+.Fa addr
+argument must point to the variable of type
+.Vt struct ptrace_xstate_info ,
+which contains the information on the request return.
+The
+.Vt struct ptrace_xstate_info
+is defined as follows:
+.Bd -literal
+struct ptrace_xstate_info {
+   uint64_txsave_mask;
+   uint32_txsave_len;
+};
+.Ed
+The
+.Dv xsave_mask
+field is the bitmask of the currently enabled extensions.
+The meaning of the bits is defined by the Intel and AMD
+processor documentation.
+The
+.Dv xsave_len
+field reports the length of the XSAVE area for storing the hardware
+state for currently enabled extensions in the format defined by the x86
+.Dv XSAVE
+machine instruction.
+.Pp
+The
+.Fa data
+argument value must be equal to the size of the
+.Vt struct ptrace_xstate_info .
+.It Dv PT_GETXSTATE
+Returns the content of the XSAVE area for the thread.
+The
+.Fa addr
+argument points to the buffer where the content is copied, the
+.Fa data
+argument specifies the size of the buffer.
+The kernel copies out as much content as allowed by the buffer size.
+The buffer layout is specified by the layout of the save area for the
+.Dv XSAVE
+machine instruction.
+.It Dv PT_SETXSTATE
+Load the XSAVE state for the thread from the buffer specified by the
+.Fa addr
+pointer.
+The buffer size is passed in the
+.Fa data
+argument.
+The buffer must be at least as large to allow the x87 FPU and XMM state,
+but not large than the XSAVE state length, as reported by the
+.Dv xsave_len
+field from the
+.Vt struct ptrace_xstate_info
+of the
+.Dv PT_GETXSTATE_INFO
+request.
+Layout of the buffer is identical to the layout of the load area for the
+.Dv XRSTOR
+machine instruction.
+.It Dv PT_GETFSBASE
+The request returns the value of base used when doing segmented
+memory addressing using the %fs segment register.
+The
+.Fa addr
+argument points to the
+.Vt unsigned long
+variable which gets the base value.
+.Pp
+The
+.Fa data
+argument is ignored.
+.It Dv PT_GETGSBASE
+Same as the
+.Dv PT_GETFSBASE
+request, but returns the base for the %gs segment register.
+.It Dv PT_SETFSBASE
+Sets the base for the %fs segment register to the value pointed
+by the
+.Fa addr
+argument, which must point to the
+.Vt unsigned long
+variable containing the new base.
 .Pp
-Additionally, machine-specific requests can exist.
+The
+.Fa data
+argument is ignored.
+.It Dv PT_SETGSBASE
+Same as the
+.Dv PT_SETFSBASE
+request, but allows setting the base for the %gs segment register.
+.El
+.Sh PowerPC MACHINE-SPECIFIC REQUESTS
+.Bl -tag -width Dv PT_SETVRREGS
+.It Dv PT_GETVRREGS
+Returns the
+.Dv ALTIVEC
+machine state for the thread into the buffer pointed to by
+the argument
+.Fa addr .
+.Pp
+The
+.Fa data
+argument is ignored.
+.It Dv PT_SETVRREGS
+Set the
+.Dv ALTIVEC
+machine state for the thread from the buffer pointed to by
+the argument
+.Fa addr .
+.Pp
+The
+.Fa data
+argument is ignored.
+.El
+.Pp
+Additionally, other machine-specific requests can exist.
 .Sh 

svn commit: r284966 - stable/10/sys/dev/bxe

2015-06-30 Thread David C Somayajulu
Author: davidcs
Date: Tue Jun 30 18:58:33 2015
New Revision: 284966
URL: https://svnweb.freebsd.org/changeset/base/284966

Log:
  MFC r284739
  tx_mtx should be grabbed before calling buf_ring_dequeue_sc()
  
  Submitted by:attilio@isilon.com

Modified:
  stable/10/sys/dev/bxe/bxe.c
Directory Properties:
  stable/10/   (props changed)

Modified: stable/10/sys/dev/bxe/bxe.c
==
--- stable/10/sys/dev/bxe/bxe.c Tue Jun 30 18:53:42 2015(r284965)
+++ stable/10/sys/dev/bxe/bxe.c Tue Jun 30 18:58:33 2015(r284966)
@@ -6553,10 +6553,14 @@ bxe_free_fp_buffers(struct bxe_softc *sc
 
 #if __FreeBSD_version = 80
 if (fp-tx_br != NULL) {
-struct mbuf *m;
 /* just in case bxe_mq_flush() wasn't called */
-while ((m = buf_ring_dequeue_sc(fp-tx_br)) != NULL) {
-m_freem(m);
+if (mtx_initialized(fp-tx_mtx)) {
+struct mbuf *m;
+
+BXE_FP_TX_LOCK(fp);
+while ((m = buf_ring_dequeue_sc(fp-tx_br)) != NULL)
+m_freem(m);
+BXE_FP_TX_UNLOCK(fp);
 }
 buf_ring_free(fp-tx_br, M_DEVBUF);
 fp-tx_br = NULL;
___
svn-src-all@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/svn-src-all
To unsubscribe, send any mail to svn-src-all-unsubscr...@freebsd.org


svn commit: r284970 - stable/10/libexec/atrun

2015-06-30 Thread Warren Block
Author: wblock (doc committer)
Date: Tue Jun 30 19:53:26 2015
New Revision: 284970
URL: https://svnweb.freebsd.org/changeset/base/284970

Log:
  MFC 284709:
Call /etc/crontab the system crontab, not root's crontab.  While
here, fix some other wording issues

Modified:
  stable/10/libexec/atrun/atrun.man
Directory Properties:
  stable/10/   (props changed)

Modified: stable/10/libexec/atrun/atrun.man
==
--- stable/10/libexec/atrun/atrun.man   Tue Jun 30 19:35:14 2015
(r284969)
+++ stable/10/libexec/atrun/atrun.man   Tue Jun 30 19:53:26 2015
(r284970)
@@ -1,5 +1,5 @@
 .\ $FreeBSD$
-.Dd October 30, 2012
+.Dd June 22, 2015
 .Dt ATRUN 8
 .Os
 .Sh NAME
@@ -14,32 +14,32 @@
 runs jobs queued by
 .Xr at 1 .
 .Pp
-Root's
+The system
 .Xr crontab 5
 file
 .Pa /etc/crontab
-has to contain the line
+must contain the line
 .Bd -literal
 */5 *   *   *   *   root/usr/libexec/atrun
 .Ed
 .Pp
-so that
+so
 .Nm
-gets invoked every five minutes.
+is invoked every five minutes.
 .Pp
 At every invocation,
 .Nm
-will start all the jobs in the lowercase queues whose start
+starts all the jobs in the lowercase queues whose start
 time has elapsed.
 In addition, if the load average over the last minute was less than
-the specified limit then a maximum of one batch job (denoted by the
+the specified limit, then a maximum of one batch job (denoted by the
 uppercase queues) is started.
 .Pp
 Before starting a job,
 .Nm
-will check the status of its owner's account with
+checks the status of its owner's account with
 .Xr pam 3
-and refuse to run the job if the account is unavailable,
+and refuses to run the job if the account is unavailable,
 e.g., locked out or expired.
 .Sh OPTIONS
 .Bl -tag -width indent
@@ -53,9 +53,11 @@ Debug; print error messages to standard 
 .Sh WARNINGS
 For
 .Nm
-to work, you have to start up a
+to work, a
 .Xr cron 8
-daemon.
+daemon must be running
+.Nm
+periodically.
 .Sh FILES
 .Bl -tag -width /etc/pam.d/atrun -compact
 .It Pa /etc/pam.d/atrun
___
svn-src-all@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/svn-src-all
To unsubscribe, send any mail to svn-src-all-unsubscr...@freebsd.org


svn commit: r284945 - head/usr.bin/mkesdb

2015-06-30 Thread Justin Hibbits
Author: jhibbits
Date: Tue Jun 30 06:02:42 2015
New Revision: 284945
URL: https://svnweb.freebsd.org/changeset/base/284945

Log:
  The LDFLAGS isn't needed, and breaks the build on powerpc64.
  
  This hack is very fragile, and was broken on powerpc64 when metamode was
  introduced.  Removing it survives a buildworld for all architectures, and
  fixes the build on powerpc64.

Modified:
  head/usr.bin/mkesdb/Makefile

Modified: head/usr.bin/mkesdb/Makefile
==
--- head/usr.bin/mkesdb/MakefileTue Jun 30 05:53:15 2015
(r284944)
+++ head/usr.bin/mkesdb/MakefileTue Jun 30 06:02:42 2015
(r284945)
@@ -3,7 +3,6 @@
 .PATH: ${.CURDIR}/../../lib/libc/iconv
 
 PROG=  mkesdb
-LDFLAGS+= -L${.OBJDIR}/../../lib/libc
 
 NO_WMISSING_VARIABLE_DECLARATIONS=
 
___
svn-src-all@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/svn-src-all
To unsubscribe, send any mail to svn-src-all-unsubscr...@freebsd.org


svn commit: r284949 - stable/10/share/man/man4

2015-06-30 Thread Christian Brueffer
Author: brueffer
Date: Tue Jun 30 09:34:59 2015
New Revision: 284949
URL: https://svnweb.freebsd.org/changeset/base/284949

Log:
  MFC: r262233
  
  Spelling, grammar and mdoc cleanup.

Modified:
  stable/10/share/man/man4/gpio.4
Directory Properties:
  stable/10/   (props changed)

Modified: stable/10/share/man/man4/gpio.4
==
--- stable/10/share/man/man4/gpio.4 Tue Jun 30 08:40:15 2015
(r284948)
+++ stable/10/share/man/man4/gpio.4 Tue Jun 30 09:34:59 2015
(r284949)
@@ -42,7 +42,7 @@ following lines in your kernel configura
 .Pp
 Additional device entries for the
 .Li ARM
-architecure include:
+architecture include:
 .Bd -ragged -offset indent
 .Cd device a10_gpio
 .Cd device bcm_gpio
@@ -58,7 +58,7 @@ architecure include:
 .Pp
 Additional device entries for the
 .Li MIPS
-architecure include:
+architecture include:
 .Bd -ragged -offset indent
 .Cd device ar71xxx_gpio
 .Cd device octeon_gpio
@@ -67,14 +67,14 @@ architecure include:
 .Pp
 Additional device entries for the
 .Li POWERPC
-architecure include:
+architecture include:
 .Bd -ragged -offset indent
 .Cd device wiigpio
 .Cd device macgpio
 .Ed
 .Sh DESCRIPTION
 The
-.Em gpiobus
+.Nm
 system provides a simple interface to the GPIO pins that are usually
 available on embedded architectures and can provide bit banging style
 devices to the system.
@@ -89,7 +89,7 @@ for input/output, IRQ delivery, SDA/SCL
 .Em iicbus
 use, etc.
 .Pp
-On some embedded architechtures (like MIPS), discovery of the bus and
+On some embedded architectures (like MIPS), discovery of the bus and
 configuration of the pins is done via
 .Xr device.hints 5
 in the platform's kernel
@@ -101,28 +101,30 @@ On some others (like ARM), where
 is used to describe the device tree, the bus discovery is done via the DTS
 passed to the kernel, being either statically compiled in, or by a variety
 of ways where the boot loader (or Open Firmware enabled system) passes the
-DTS blob to kernel at boot.
+DTS blob to the kernel at boot.
 .Pp
-The following are only provided by the
+The following
+.Xr device.hints 5
+are only provided by the
 .Cd ar71xx_gpio
-driver.
+driver:
 .Bl -tag -width .Va hint.gpioiic.%d.atXXX
 .It Va hint.gpio.%d.pinmask
-This is a bitmask of pins on the gpio board that we would like to expose
-for use to the host o/s.
+This is a bitmask of pins on the GPIO board that we would like to expose
+for use to the host operating system.
 To expose pin 0, 4 and 7, use the bitmask of
 10010001 converted to the hexadecimal value 0x0091.
 .It Va hint.gpio.%d.pinon
-This is a bitmask of pins on the gpio board that will be set to ON at host
+This is a bitmask of pins on the GPIO board that will be set to ON at host
 start.
 To set pin 2, 5 and 13 to be set ON at boot, use the bitmask of
 110010 converted to the hexadecimal value 0x2012.
 .It Va hint.gpio.function_set
 .It Va hint.gpio.function_clear
-These are a bitmask of pins that will remap a pin to handle a specific
+These are bitmasks of pins that will remap a pin to handle a specific
 function (USB, UART TX/RX, etc) in the Atheros function registers.
-This is mainly used to set/clear functions that we need when they are setup or
-not setup by uBoot.
+This is mainly used to set/clear functions that we need when they are set up or
+not set up by uBoot.
 .El
 .Pp
 Simply put, each pin of the GPIO interface is connected to an input/output
___
svn-src-all@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/svn-src-all
To unsubscribe, send any mail to svn-src-all-unsubscr...@freebsd.org


Notice to appear in Court #00461402

2015-06-30 Thread State Court
Notice to Appear,

This is to inform you to appear in the Court on the July 06 for your case 
hearing.
Please, do not forget to bring all the documents related to the case.
Note: The case will be heard by the judge in your absence if you do not come.

You can review complete details of the Court Notice in the attachment.

Yours faithfully,
Philip Barrett,
Clerk of Court.

___
svn-src-all@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/svn-src-all
To unsubscribe, send any mail to svn-src-all-unsubscr...@freebsd.org


svn commit: r284986 - in releng/9.3: . contrib/sendmail/src lib/libc/locale sys/conf

2015-06-30 Thread Xin LI
Author: delphij
Date: Tue Jun 30 23:21:48 2015
New Revision: 284986
URL: https://svnweb.freebsd.org/changeset/base/284986

Log:
  [EN-15:08] Revised: Improvements to sendmail TLS/DH interoperability.
  
  [EN-15:09] Fix inconsistency between locale and rune locale states.
  
  Approved by:  so

Modified:
  releng/9.3/UPDATING
  releng/9.3/contrib/sendmail/src/sendmail.h
  releng/9.3/lib/libc/locale/setrunelocale.c
  releng/9.3/lib/libc/locale/xlocale.c
  releng/9.3/sys/conf/newvers.sh

Modified: releng/9.3/UPDATING
==
--- releng/9.3/UPDATING Tue Jun 30 23:21:37 2015(r284985)
+++ releng/9.3/UPDATING Tue Jun 30 23:21:48 2015(r284986)
@@ -11,6 +11,14 @@ handbook:
 Items affecting the ports and packages system can be found in
 /usr/ports/UPDATING.  Please read that file before running portupgrade.
 
+20150630:  p18 FreeBSD-EN-15:08.sendmail [revised]
+   FreeBSD-EN-15:09.xlocale
+
+   Improvements to sendmail TLS/DH interoperability. [EN-15:08]
+
+   Fix inconsistency between locale and rune locale states.
+   [EN-15:09]
+
 20150618:  p17 FreeBSD-EN-15:08.sendmail
Improvements to sendmail TLS/DH interoperability. [EN-15:08]
 

Modified: releng/9.3/contrib/sendmail/src/sendmail.h
==
--- releng/9.3/contrib/sendmail/src/sendmail.h  Tue Jun 30 23:21:37 2015
(r284985)
+++ releng/9.3/contrib/sendmail/src/sendmail.h  Tue Jun 30 23:21:48 2015
(r284986)
@@ -1935,7 +1935,7 @@ struct termescape
 
 /* server requirements */
 #define TLS_I_SRV  (TLS_I_SRV_CERT | TLS_I_RSA_TMP | TLS_I_VRFY_PATH | \
-TLS_I_VRFY_LOC | TLS_I_TRY_DH | TLS_I_DH512 | \
+TLS_I_VRFY_LOC | TLS_I_TRY_DH | TLS_I_DH1024 | \
 TLS_I_CACHE)
 
 /* client requirements */

Modified: releng/9.3/lib/libc/locale/setrunelocale.c
==
--- releng/9.3/lib/libc/locale/setrunelocale.c  Tue Jun 30 23:21:37 2015
(r284985)
+++ releng/9.3/lib/libc/locale/setrunelocale.c  Tue Jun 30 23:21:48 2015
(r284986)
@@ -202,6 +202,8 @@ __set_thread_rune_locale(locale_t loc)
 
if (loc == NULL) {
_ThreadRuneLocale = _DefaultRuneLocale;
+   } else if (loc == LC_GLOBAL_LOCALE) {
+   _ThreadRuneLocale = 0;
} else {
_ThreadRuneLocale = XLOCALE_CTYPE(loc)-runes;
}

Modified: releng/9.3/lib/libc/locale/xlocale.c
==
--- releng/9.3/lib/libc/locale/xlocale.cTue Jun 30 23:21:37 2015
(r284985)
+++ releng/9.3/lib/libc/locale/xlocale.cTue Jun 30 23:21:48 2015
(r284986)
@@ -154,23 +154,24 @@ __get_locale(void)
 static void
 set_thread_locale(locale_t loc)
 {
+   locale_t l = (loc == LC_GLOBAL_LOCALE) ? 0 : loc;
 
_once(once_control, init_key);

-   if (NULL != loc) {
-   xlocale_retain((struct xlocale_refcounted*)loc);
+   if (NULL != l) {
+   xlocale_retain((struct xlocale_refcounted*)l);
}
locale_t old = pthread_getspecific(locale_info_key);
-   if ((NULL != old)  (loc != old)) {
+   if ((NULL != old)  (l != old)) {
xlocale_release((struct xlocale_refcounted*)old);
}
if (fake_tls) {
-   thread_local_locale = loc;
+   thread_local_locale = l;
} else {
-   pthread_setspecific(locale_info_key, loc);
+   pthread_setspecific(locale_info_key, l);
}
 #ifndef __NO_TLS
-   __thread_locale = loc;
+   __thread_locale = l;
__set_thread_rune_locale(loc);
 #endif
 }
@@ -361,9 +362,6 @@ locale_t uselocale(locale_t loc)
 {
locale_t old = get_thread_locale();
if (NULL != loc) {
-   if (LC_GLOBAL_LOCALE == loc) {
-   loc = NULL;
-   }
set_thread_locale(loc);
}
return (old ? old : LC_GLOBAL_LOCALE);

Modified: releng/9.3/sys/conf/newvers.sh
==
--- releng/9.3/sys/conf/newvers.sh  Tue Jun 30 23:21:37 2015
(r284985)
+++ releng/9.3/sys/conf/newvers.sh  Tue Jun 30 23:21:48 2015
(r284986)
@@ -32,7 +32,7 @@
 
 TYPE=FreeBSD
 REVISION=9.3
-BRANCH=RELEASE-p17
+BRANCH=RELEASE-p18
 if [ X${BRANCH_OVERRIDE} != X ]; then
BRANCH=${BRANCH_OVERRIDE}
 fi
___
svn-src-all@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/svn-src-all
To unsubscribe, send any mail to svn-src-all-unsubscr...@freebsd.org


svn commit: r284985 - in releng/10.1: . contrib/sendmail/src lib/libc/locale lib/libiconv_modules/UTF7 sys/conf

2015-06-30 Thread Xin LI
Author: delphij
Date: Tue Jun 30 23:21:37 2015
New Revision: 284985
URL: https://svnweb.freebsd.org/changeset/base/284985

Log:
  [EN-15:08] Revised: Improvements to sendmail TLS/DH interoperability.
  
  [EN-15:09] Fix inconsistency between locale and rune locale states.
  
  [EN-15:10] Improved iconv(3) UTF-7 support.
  
  Approved by:  so

Modified:
  releng/10.1/UPDATING
  releng/10.1/contrib/sendmail/src/sendmail.h
  releng/10.1/lib/libc/locale/setrunelocale.c
  releng/10.1/lib/libc/locale/xlocale.c
  releng/10.1/lib/libiconv_modules/UTF7/citrus_utf7.c
  releng/10.1/sys/conf/newvers.sh

Modified: releng/10.1/UPDATING
==
--- releng/10.1/UPDATINGTue Jun 30 22:30:21 2015(r284984)
+++ releng/10.1/UPDATINGTue Jun 30 23:21:37 2015(r284985)
@@ -16,6 +16,17 @@ from older versions of FreeBSD, try WITH
 stable/10, and then rebuild without this option. The bootstrap process from
 older version of current is a bit fragile.
 
+20150630:  p14 FreeBSD-EN-15:08.sendmail [revised]
+   FreeBSD-EN-15:09.xlocale
+   FreeBSD-EN-15:10.iconv
+
+   Improvements to sendmail TLS/DH interoperability. [EN-15:08]
+
+   Fix inconsistency between locale and rune locale states.
+   [EN-15:09]
+
+   Improved iconv(3) UTF-7 support. [EN-15:10]
+
 20150618:  p13 FreeBSD-EN-15:08.sendmail
Improvements to sendmail TLS/DH interoperability. [EN-15:08]
 

Modified: releng/10.1/contrib/sendmail/src/sendmail.h
==
--- releng/10.1/contrib/sendmail/src/sendmail.h Tue Jun 30 22:30:21 2015
(r284984)
+++ releng/10.1/contrib/sendmail/src/sendmail.h Tue Jun 30 23:21:37 2015
(r284985)
@@ -1935,7 +1935,7 @@ struct termescape
 
 /* server requirements */
 #define TLS_I_SRV  (TLS_I_SRV_CERT | TLS_I_RSA_TMP | TLS_I_VRFY_PATH | \
-TLS_I_VRFY_LOC | TLS_I_TRY_DH | TLS_I_DH512 | \
+TLS_I_VRFY_LOC | TLS_I_TRY_DH | TLS_I_DH1024 | \
 TLS_I_CACHE)
 
 /* client requirements */

Modified: releng/10.1/lib/libc/locale/setrunelocale.c
==
--- releng/10.1/lib/libc/locale/setrunelocale.c Tue Jun 30 22:30:21 2015
(r284984)
+++ releng/10.1/lib/libc/locale/setrunelocale.c Tue Jun 30 23:21:37 2015
(r284985)
@@ -202,6 +202,8 @@ __set_thread_rune_locale(locale_t loc)
 
if (loc == NULL) {
_ThreadRuneLocale = _DefaultRuneLocale;
+   } else if (loc == LC_GLOBAL_LOCALE) {
+   _ThreadRuneLocale = 0;
} else {
_ThreadRuneLocale = XLOCALE_CTYPE(loc)-runes;
}

Modified: releng/10.1/lib/libc/locale/xlocale.c
==
--- releng/10.1/lib/libc/locale/xlocale.c   Tue Jun 30 22:30:21 2015
(r284984)
+++ releng/10.1/lib/libc/locale/xlocale.c   Tue Jun 30 23:21:37 2015
(r284985)
@@ -154,23 +154,24 @@ __get_locale(void)
 static void
 set_thread_locale(locale_t loc)
 {
+   locale_t l = (loc == LC_GLOBAL_LOCALE) ? 0 : loc;
 
_once(once_control, init_key);

-   if (NULL != loc) {
-   xlocale_retain((struct xlocale_refcounted*)loc);
+   if (NULL != l) {
+   xlocale_retain((struct xlocale_refcounted*)l);
}
locale_t old = pthread_getspecific(locale_info_key);
-   if ((NULL != old)  (loc != old)) {
+   if ((NULL != old)  (l != old)) {
xlocale_release((struct xlocale_refcounted*)old);
}
if (fake_tls) {
-   thread_local_locale = loc;
+   thread_local_locale = l;
} else {
-   pthread_setspecific(locale_info_key, loc);
+   pthread_setspecific(locale_info_key, l);
}
 #ifndef __NO_TLS
-   __thread_locale = loc;
+   __thread_locale = l;
__set_thread_rune_locale(loc);
 #endif
 }
@@ -361,9 +362,6 @@ locale_t uselocale(locale_t loc)
 {
locale_t old = get_thread_locale();
if (NULL != loc) {
-   if (LC_GLOBAL_LOCALE == loc) {
-   loc = NULL;
-   }
set_thread_locale(loc);
}
return (old ? old : LC_GLOBAL_LOCALE);

Modified: releng/10.1/lib/libiconv_modules/UTF7/citrus_utf7.c
==
--- releng/10.1/lib/libiconv_modules/UTF7/citrus_utf7.c Tue Jun 30 22:30:21 
2015(r284984)
+++ releng/10.1/lib/libiconv_modules/UTF7/citrus_utf7.c Tue Jun 30 23:21:37 
2015(r284985)
@@ -62,8 +62,7 @@ typedef struct {
unsigned int
mode: 1,/* whether base64 mode */
bits: 4,/* need to hold 0 - 15 */
-   cache

svn commit: r284987 - in releng/8.4: . contrib/sendmail/src sys/conf

2015-06-30 Thread Xin LI
Author: delphij
Date: Tue Jun 30 23:21:59 2015
New Revision: 284987
URL: https://svnweb.freebsd.org/changeset/base/284987

Log:
  [EN-15:08] Revised: Improvements to sendmail TLS/DH interoperability.
  
  Approved by:  so

Modified:
  releng/8.4/UPDATING
  releng/8.4/contrib/sendmail/src/sendmail.h
  releng/8.4/sys/conf/newvers.sh

Modified: releng/8.4/UPDATING
==
--- releng/8.4/UPDATING Tue Jun 30 23:21:48 2015(r284986)
+++ releng/8.4/UPDATING Tue Jun 30 23:21:59 2015(r284987)
@@ -15,6 +15,10 @@ NOTE TO PEOPLE WHO THINK THAT FreeBSD 8.
debugging tools present in HEAD were left in place because
sun4v support still needs work to become production ready.
 
+20150630:  p32 FreeBSD-EN-15:08.sendmail [revised]
+
+   Improvements to sendmail TLS/DH interoperability. [EN-15:08]
+
 20150618:  p31 FreeBSD-EN-15:08.sendmail
Improvements to sendmail TLS/DH interoperability. [EN-15:08]
 

Modified: releng/8.4/contrib/sendmail/src/sendmail.h
==
--- releng/8.4/contrib/sendmail/src/sendmail.h  Tue Jun 30 23:21:48 2015
(r284986)
+++ releng/8.4/contrib/sendmail/src/sendmail.h  Tue Jun 30 23:21:59 2015
(r284987)
@@ -1929,7 +1929,7 @@ struct termescape
 
 /* server requirements */
 #define TLS_I_SRV  (TLS_I_SRV_CERT | TLS_I_RSA_TMP | TLS_I_VRFY_PATH | \
-TLS_I_VRFY_LOC | TLS_I_TRY_DH | TLS_I_DH512 | \
+TLS_I_VRFY_LOC | TLS_I_TRY_DH | TLS_I_DH1024 | \
 TLS_I_CACHE)
 
 /* client requirements */

Modified: releng/8.4/sys/conf/newvers.sh
==
--- releng/8.4/sys/conf/newvers.sh  Tue Jun 30 23:21:48 2015
(r284986)
+++ releng/8.4/sys/conf/newvers.sh  Tue Jun 30 23:21:59 2015
(r284987)
@@ -32,7 +32,7 @@
 
 TYPE=FreeBSD
 REVISION=8.4
-BRANCH=RELEASE-p31
+BRANCH=RELEASE-p32
 if [ X${BRANCH_OVERRIDE} != X ]; then
BRANCH=${BRANCH_OVERRIDE}
 fi
___
svn-src-all@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/svn-src-all
To unsubscribe, send any mail to svn-src-all-unsubscr...@freebsd.org


svn commit: r284983 - in stable/9/sys: dev/qlxgbe modules/qlxgbe

2015-06-30 Thread David C Somayajulu
Author: davidcs
Date: Tue Jun 30 21:19:27 2015
New Revision: 284983
URL: https://svnweb.freebsd.org/changeset/base/284983

Log:
  MFC r284741
  
  Updated Copyright information
  Added support for the following:
  - iSCSI TLV (requires 64 Tx and 32 Rx rings
  - 9K receive buffers for jumbo frames (feature may be enabled/disabled)
  - builtin firmware, bootloader and minidump template
  - quick stats
  - async event handling for SFP insertion/removal and DCBX changes
  - Configuring DCBX and interrupt coalescing parameters

Added:
  stable/9/sys/dev/qlxgbe/ql_boot.c
 - copied unchanged from r284741, head/sys/dev/qlxgbe/ql_boot.c
  stable/9/sys/dev/qlxgbe/ql_fw.c
 - copied unchanged from r284741, head/sys/dev/qlxgbe/ql_fw.c
  stable/9/sys/dev/qlxgbe/ql_minidump.c
 - copied unchanged from r284741, head/sys/dev/qlxgbe/ql_minidump.c
Modified:
  stable/9/sys/dev/qlxgbe/ql_dbg.c
  stable/9/sys/dev/qlxgbe/ql_dbg.h
  stable/9/sys/dev/qlxgbe/ql_def.h
  stable/9/sys/dev/qlxgbe/ql_glbl.h
  stable/9/sys/dev/qlxgbe/ql_hw.c
  stable/9/sys/dev/qlxgbe/ql_hw.h
  stable/9/sys/dev/qlxgbe/ql_inline.h
  stable/9/sys/dev/qlxgbe/ql_ioctl.c
  stable/9/sys/dev/qlxgbe/ql_ioctl.h
  stable/9/sys/dev/qlxgbe/ql_isr.c
  stable/9/sys/dev/qlxgbe/ql_misc.c
  stable/9/sys/dev/qlxgbe/ql_os.c
  stable/9/sys/dev/qlxgbe/ql_os.h
  stable/9/sys/dev/qlxgbe/ql_reset.c
  stable/9/sys/dev/qlxgbe/ql_tmplt.h
  stable/9/sys/dev/qlxgbe/ql_ver.h
  stable/9/sys/modules/qlxgbe/Makefile
Directory Properties:
  stable/9/   (props changed)
  stable/9/sys/   (props changed)
  stable/9/sys/dev/   (props changed)
  stable/9/sys/modules/   (props changed)

Copied: stable/9/sys/dev/qlxgbe/ql_boot.c (from r284741, 
head/sys/dev/qlxgbe/ql_boot.c)
==
--- /dev/null   00:00:00 1970   (empty, because file is newly added)
+++ stable/9/sys/dev/qlxgbe/ql_boot.c   Tue Jun 30 21:19:27 2015
(r284983, copy of r284741, head/sys/dev/qlxgbe/ql_boot.c)
@@ -0,0 +1,10964 @@
+/*
+ * Copyright (c) 2012-2016 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_boot.c
+ */
+#include sys/cdefs.h
+__FBSDID($FreeBSD$);
+
+#include ql_os.h
+
+unsigned int ql83xx_bootloader_version_major = 5;
+unsigned int ql83xx_bootloader_version_minor = 2;
+unsigned int ql83xx_bootloader_version_sub = 7;
+unsigned char ql83xx_bootloader[] = {
+  0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+  0x00, 0x00, 0x00, 0xa0, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+  0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xa0, 0x00, 0x00, 0x00, 0x00,
+  0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xa0,
+  0x04, 0x00, 0x80, 0x82, 0x05, 0x1f, 0x00, 0x1c, 0x00, 0x00, 0x00, 0x00,
+  0x00, 0x00, 0x00, 0x80, 0x1e, 0x02, 0x21, 0x00, 0x08, 0x00, 0x00, 0x00,
+  0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x02, 0x00, 0x20, 0x00,
+  0x00, 0x00, 0x00, 0x00, 0x04, 0x01, 0x7c, 0x00, 0x00, 0x00, 0x00, 0x70,
+  0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+  0x00, 0x00, 0x00, 0xa0, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+  0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xa0, 0x00, 0x00, 0x00, 0x00,
+  0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xa0,
+  0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+  0x00, 0x00, 0x00, 0xa0, 0x02, 0x00, 0x20, 0x00, 0x00, 0x00, 0x00, 0x00,
+  0x21, 0x00, 0x7c, 0x00, 0x00, 0x00, 0x00, 0x70, 0x00, 0x00, 0x00, 0x00,
+  0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xa0,
+  0x00, 0x00, 0x00, 0x00, 0x00, 

svn commit: r284984 - head/tools/tools/cxgbetool

2015-06-30 Thread Navdeep Parhar
Author: np
Date: Tue Jun 30 22:30:21 2015
New Revision: 284984
URL: https://svnweb.freebsd.org/changeset/base/284984

Log:
  cxgbetool: fix code that decodes T5 SGE contexts.  Some of the fields
  that changed between T4 and T5 were not displayed correctly.
  
  Obtained from:Chelsio
  MFC after:3 days
  Differential Revision:

Modified:
  head/tools/tools/cxgbetool/cxgbetool.c

Modified: head/tools/tools/cxgbetool/cxgbetool.c
==
--- head/tools/tools/cxgbetool/cxgbetool.c  Tue Jun 30 21:19:27 2015
(r284983)
+++ head/tools/tools/cxgbetool/cxgbetool.c  Tue Jun 30 22:30:21 2015
(r284984)
@@ -1245,9 +1245,159 @@ show_struct(const uint32_t *words, int n
 #define FIELD1(name, start) FIELD(name, start, start)
 
 static void
-show_sge_context(const struct t4_sge_context *p)
+show_t5_ctxt(const struct t4_sge_context *p)
 {
-   static struct field_desc egress[] = {
+   static struct field_desc egress_t5[] = {
+   FIELD(DCA_ST:, 181, 191),
+   FIELD1(StatusPgNS:, 180),
+   FIELD1(StatusPgRO:, 179),
+   FIELD1(FetchNS:, 178),
+   FIELD1(FetchRO:, 177),
+   FIELD1(Valid:, 176),
+   FIELD(PCIeDataChannel:, 174, 175),
+   FIELD1(StatusPgTPHintEn:, 173),
+   FIELD(StatusPgTPHint:, 171, 172),
+   FIELD1(FetchTPHintEn:, 170),
+   FIELD(FetchTPHint:, 168, 169),
+   FIELD1(FCThreshOverride:, 167),
+   { WRLength:, 162, 166, 9, 0, 1 },
+   FIELD1(WRLengthKnown:, 161),
+   FIELD1(ReschedulePending:, 160),
+   FIELD1(OnChipQueue:, 159),
+   FIELD1(FetchSizeMode:, 158),
+   { FetchBurstMin:, 156, 157, 4, 0, 1 },
+   FIELD1(FLMPacking:, 155),
+   FIELD(FetchBurstMax:, 153, 154),
+   FIELD(uPToken:, 133, 152),
+   FIELD1(uPTokenEn:, 132),
+   FIELD1(UserModeIO:, 131),
+   FIELD(uPFLCredits:, 123, 130),
+   FIELD1(uPFLCreditEn:, 122),
+   FIELD(FID:, 111, 121),
+   FIELD(HostFCMode:, 109, 110),
+   FIELD1(HostFCOwner:, 108),
+   { CIDXFlushThresh:, 105, 107, 0, 0, 1 },
+   FIELD(CIDX:, 89, 104),
+   FIELD(PIDX:, 73, 88),
+   { BaseAddress:, 18, 72, 9, 1 },
+   FIELD(QueueSize:, 2, 17),
+   FIELD1(QueueType:, 1),
+   FIELD1(CachePriority:, 0),
+   { NULL }
+   };
+   static struct field_desc fl_t5[] = {
+   FIELD(DCA_ST:, 181, 191),
+   FIELD1(StatusPgNS:, 180),
+   FIELD1(StatusPgRO:, 179),
+   FIELD1(FetchNS:, 178),
+   FIELD1(FetchRO:, 177),
+   FIELD1(Valid:, 176),
+   FIELD(PCIeDataChannel:, 174, 175),
+   FIELD1(StatusPgTPHintEn:, 173),
+   FIELD(StatusPgTPHint:, 171, 172),
+   FIELD1(FetchTPHintEn:, 170),
+   FIELD(FetchTPHint:, 168, 169),
+   FIELD1(FCThreshOverride:, 167),
+   FIELD1(ReschedulePending:, 160),
+   FIELD1(OnChipQueue:, 159),
+   FIELD1(FetchSizeMode:, 158),
+   { FetchBurstMin:, 156, 157, 4, 0, 1 },
+   FIELD1(FLMPacking:, 155),
+   FIELD(FetchBurstMax:, 153, 154),
+   FIELD1(FLMcongMode:, 152),
+   FIELD(MaxuPFLCredits:, 144, 151),
+   FIELD(FLMcontextID:, 133, 143),
+   FIELD1(uPTokenEn:, 132),
+   FIELD1(UserModeIO:, 131),
+   FIELD(uPFLCredits:, 123, 130),
+   FIELD1(uPFLCreditEn:, 122),
+   FIELD(FID:, 111, 121),
+   FIELD(HostFCMode:, 109, 110),
+   FIELD1(HostFCOwner:, 108),
+   { CIDXFlushThresh:, 105, 107, 0, 0, 1 },
+   FIELD(CIDX:, 89, 104),
+   FIELD(PIDX:, 73, 88),
+   { BaseAddress:, 18, 72, 9, 1 },
+   FIELD(QueueSize:, 2, 17),
+   FIELD1(QueueType:, 1),
+   FIELD1(CachePriority:, 0),
+   { NULL }
+   };
+   static struct field_desc ingress_t5[] = {
+   FIELD(DCA_ST:, 143, 153),
+   FIELD1(ISCSICoalescing:, 142),
+   FIELD1(Queue_Valid:, 141),
+   FIELD1(TimerPending:, 140),
+   FIELD1(DropRSS:, 139),
+   FIELD(PCIeChannel:, 137, 138),
+   FIELD1(SEInterruptArmed:, 136),
+   FIELD1(CongestionMgtEnable:, 135),
+   FIELD1(NoSnoop:, 134),
+   FIELD1(RelaxedOrdering:, 133),
+   FIELD1(GTSmode:, 132),
+   FIELD1(TPHintEn:, 131),
+   FIELD(TPHint:, 129, 130),
+   FIELD1(UpdateScheduling:, 128),
+   FIELD(UpdateDelivery:, 126, 127),
+