svn commit: r283027 - head/cddl/lib/libdtrace

2015-05-16 Thread Mark Johnston
Author: markj
Date: Sun May 17 04:17:08 2015
New Revision: 283027
URL: https://svnweb.freebsd.org/changeset/base/283027

Log:
  Actually remove siftr-related definitions from tcp.d, missed in r283026.

Modified:
  head/cddl/lib/libdtrace/tcp.d

Modified: head/cddl/lib/libdtrace/tcp.d
==
--- head/cddl/lib/libdtrace/tcp.d   Sun May 17 04:09:22 2015
(r283026)
+++ head/cddl/lib/libdtrace/tcp.d   Sun May 17 04:17:08 2015
(r283027)
@@ -241,78 +241,3 @@ translator tcpinfoh_t < struct tcphdr *p
 translator tcplsinfo_t < int s > {
tcps_state =s;
 };
-
-/*
- * Convert a SIFTR direction value to a string
- */
-#pragma D binding "1.12.1" SIFTR_IN
-inline int SIFTR_IN =  1;
-#pragma D binding "1.12.1" SIFTR_OUT
-inline int SIFTR_OUT = 2;
-
-/* SIFTR direction strings. */
-#pragma D binding "1.12.1" siftr_dir_string
-inline string siftr_dir_string[uint8_t direction] =
-   direction == SIFTR_IN ? "in" :
-   direction == SIFTR_OUT ? "out" :
-   "unknown" ;
-
-typedef struct siftrinfo {
-   struct timeval  tval;
-   uint8_t direction;
-   uint8_t ipver;
-   uint32_thash;
-   uint16_ttcp_localport;
-   uint16_ttcp_foreignport;
-   uint64_tsnd_cwnd;
-   u_long  snd_wnd;
-   u_long  rcv_wnd;
-   u_long  snd_bwnd;
-   u_long  snd_ssthresh;
-   int conn_state;
-   u_int   max_seg_size;
-   int smoothed_rtt;
-   u_char  sack_enabled;
-   u_char  snd_scale;
-   u_char  rcv_scale;
-   u_int   flags;
-   int rxt_length;
-   u_int   snd_buf_hiwater;
-   u_int   snd_buf_cc;
-   u_int   rcv_buf_hiwater;
-   u_int   rcv_buf_cc;
-   u_int   sent_inflight_bytes;
-   int t_segqlen;
-   u_int   flowid;
-   u_int   flowtype;
-} siftrinfo_t;
-
-#pragma D binding "1.12.1" translator
-translator siftrinfo_t < struct pkt_node *p > {
-   direction = p == NULL ? 0 : p->direction;
-   ipver = p == NULL ? 0 : p->ipver;
-   hash =  p == NULL ? 0 : p->hash;
-   tcp_localport = p == NULL ? 0 : ntohs(p->tcp_localport);
-   tcp_foreignport =   p == NULL ? 0 : ntohs(p->tcp_foreignport);
-   snd_cwnd =  p == NULL ? 0 : p->snd_cwnd;
-   snd_wnd =   p == NULL ? 0 : p->snd_wnd;
-   rcv_wnd =   p == NULL ? 0 : p->rcv_wnd;
-   snd_bwnd =  p == NULL ? 0 : p->snd_bwnd;
-   snd_ssthresh =  p == NULL ? 0 : p->snd_ssthresh;
-   conn_state =p == NULL ? 0 : p->conn_state;
-   max_seg_size =  p == NULL ? 0 : p->max_seg_size;
-   smoothed_rtt =  p == NULL ? 0 : p->smoothed_rtt;
-   sack_enabled =  p == NULL ? 0 : p->sack_enabled;
-   snd_scale = p == NULL ? 0 : p->snd_scale;
-   rcv_scale = p == NULL ? 0 : p->rcv_scale;
-   flags = p == NULL ? 0 : p->flags;
-   rxt_length =p == NULL ? 0 : p->rxt_length;
-   snd_buf_hiwater =   p == NULL ? 0 : p->snd_buf_hiwater;
-   snd_buf_cc =p == NULL ? 0 : p->snd_buf_cc;
-   rcv_buf_hiwater =   p == NULL ? 0 : p->rcv_buf_hiwater;
-   rcv_buf_cc =p == NULL ? 0 : p->rcv_buf_cc;
-   sent_inflight_bytes =   p == NULL ? 0 : p->sent_inflight_bytes;
-   t_segqlen = p == NULL ? 0 : p->t_segqlen;
-   flowid =p == NULL ? 0 : p->flowid;
-   flowtype =  p == NULL ? 0 : p->flowtype;
-};
___
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: r283026 - head/cddl/lib/libdtrace

2015-05-16 Thread Mark Johnston
Author: markj
Date: Sun May 17 04:09:22 2015
New Revision: 283026
URL: https://svnweb.freebsd.org/changeset/base/283026

Log:
  Move siftr-related definitions out of tcp.d and into a separate library
  which declares a dependency on siftr(4). This is necessitated by a
  reference to struct pkt_node, which is defined in siftr(4): otherwise,
  dtrace(1) will return an error during startup if siftr.ko is not loaded.

Added:
  head/cddl/lib/libdtrace/siftr.d   (contents, props changed)
Modified:
  head/cddl/lib/libdtrace/Makefile

Modified: head/cddl/lib/libdtrace/Makefile
==
--- head/cddl/lib/libdtrace/MakefileSun May 17 03:59:08 2015
(r283025)
+++ head/cddl/lib/libdtrace/MakefileSun May 17 04:09:22 2015
(r283026)
@@ -50,6 +50,7 @@ DSRCS=errno.d \
io.d\
ip.d\
psinfo.d\
+   siftr.d \
signal.d\
tcp.d   \
udp.d   \

Added: head/cddl/lib/libdtrace/siftr.d
==
--- /dev/null   00:00:00 1970   (empty, because file is newly added)
+++ head/cddl/lib/libdtrace/siftr.d Sun May 17 04:09:22 2015
(r283026)
@@ -0,0 +1,100 @@
+/*
+ * CDDL HEADER START
+ *
+ * The contents of this file are subject to the terms of the
+ * Common Development and Distribution License (the "License").
+ * You may not use this file except in compliance with the License.
+ *
+ * You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
+ * or http://www.opensolaris.org/os/licensing.
+ * See the License for the specific language governing permissions
+ * and limitations under the License.
+ *
+ * When distributing Covered Code, include this CDDL HEADER in each
+ * file and include the License file at usr/src/OPENSOLARIS.LICENSE.
+ * If applicable, add the following below this CDDL HEADER, with the
+ * fields enclosed by brackets "[]" replaced with your own identifying
+ * information: Portions Copyright [] [name of copyright owner]
+ *
+ * CDDL HEADER END
+ *
+ * $FreeBSD$
+ */
+
+#pragma D depends_on module siftr
+#pragma D depends_on provider tcp
+
+/*
+ * Convert a SIFTR direction value to a string
+ */
+#pragma D binding "1.12.1" SIFTR_IN
+inline int SIFTR_IN =  1;
+#pragma D binding "1.12.1" SIFTR_OUT
+inline int SIFTR_OUT = 2;
+
+/* SIFTR direction strings. */
+#pragma D binding "1.12.1" siftr_dir_string
+inline string siftr_dir_string[uint8_t direction] =
+   direction == SIFTR_IN ? "in" :
+   direction == SIFTR_OUT ? "out" :
+   "unknown" ;
+
+typedef struct siftrinfo {
+   struct timeval  tval;
+   uint8_t direction;
+   uint8_t ipver;
+   uint32_thash;
+   uint16_ttcp_localport;
+   uint16_ttcp_foreignport;
+   uint64_tsnd_cwnd;
+   u_long  snd_wnd;
+   u_long  rcv_wnd;
+   u_long  snd_bwnd;
+   u_long  snd_ssthresh;
+   int conn_state;
+   u_int   max_seg_size;
+   int smoothed_rtt;
+   u_char  sack_enabled;
+   u_char  snd_scale;
+   u_char  rcv_scale;
+   u_int   flags;
+   int rxt_length;
+   u_int   snd_buf_hiwater;
+   u_int   snd_buf_cc;
+   u_int   rcv_buf_hiwater;
+   u_int   rcv_buf_cc;
+   u_int   sent_inflight_bytes;
+   int t_segqlen;
+   u_int   flowid;
+   u_int   flowtype;
+} siftrinfo_t;
+
+#pragma D binding "1.12.1" translator
+translator siftrinfo_t < struct pkt_node *p > {
+   direction = p == NULL ? 0 : p->direction;
+   ipver = p == NULL ? 0 : p->ipver;
+   hash =  p == NULL ? 0 : p->hash;
+   tcp_localport = p == NULL ? 0 : ntohs(p->tcp_localport);
+   tcp_foreignport =   p == NULL ? 0 : ntohs(p->tcp_foreignport);
+   snd_cwnd =  p == NULL ? 0 : p->snd_cwnd;
+   snd_wnd =   p == NULL ? 0 : p->snd_wnd;
+   rcv_wnd =   p == NULL ? 0 : p->rcv_wnd;
+   snd_bwnd =  p == NULL ? 0 : p->snd_bwnd;
+   snd_ssthresh =  p == NULL ? 0 : p->snd_ssthresh;
+   conn_state =p == NULL ? 0 : p->conn_state;
+   max_seg_size =  p == NULL ? 0 : p->max_seg_size;
+   smoothed_rtt =  p == NULL ? 0 : p->smoothed_rtt;
+   sack_enabled =  p == 

Re: svn commit: r282985 - in head/sys: arm/annapurna arm/annapurna/alpine arm/annapurna/alpine/hal arm/conf boot/fdt/dts/arm

2015-05-16 Thread Garrett Cooper

> On May 16, 2015, at 18:45, Adrian Chadd  wrote:
> 
> Did you commit files with DOS newlines in them? :)
> 
> tsk tsk tsk tsk tsk. I think should fix that..

Better yet it should probably be disabled in svn...
___
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: r283025 - head/cddl/contrib/opensolaris/lib/libdtrace/common

2015-05-16 Thread Mark Johnston
Author: markj
Date: Sun May 17 03:59:08 2015
New Revision: 283025
URL: https://svnweb.freebsd.org/changeset/base/283025

Log:
  As dtrace(1) processes D libraries under /usr/lib/dtrace, the compiler may
  return an error if one of the depends_on directives in a library is not
  satisfied. In this case, libdtrace is supposed to ignore the library and
  carry on. However, the remainder of the library may still be buffered by
  the lexer, causing libdtrace to erroneously continue processing it on the
  next call to yyparse(). Fix this by explicitly flushing the input buffer
  each time the compiler state is reset.
  
  MFC after:3 weeks

Modified:
  head/cddl/contrib/opensolaris/lib/libdtrace/common/dt_lex.l

Modified: head/cddl/contrib/opensolaris/lib/libdtrace/common/dt_lex.l
==
--- head/cddl/contrib/opensolaris/lib/libdtrace/common/dt_lex.l Sun May 17 
03:50:42 2015(r283024)
+++ head/cddl/contrib/opensolaris/lib/libdtrace/common/dt_lex.l Sun May 17 
03:59:08 2015(r283025)
@@ -743,6 +743,7 @@ yyinit(dt_pcb_t *pcb)
 #ifdef illumos
yysptr = yysbuf;
 #endif
+   YY_FLUSH_BUFFER;
 }
 
 /*
___
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: r283024 - head/cddl/contrib/opensolaris/lib/libdtrace/common

2015-05-16 Thread Mark Johnston
Author: markj
Date: Sun May 17 03:50:42 2015
New Revision: 283024
URL: https://svnweb.freebsd.org/changeset/base/283024

Log:
  When in lazyload mode, write the DOF to a temporary file and rename it
  rather than writing directly to the output file.
  
  CID:  1147172

Modified:
  head/cddl/contrib/opensolaris/lib/libdtrace/common/dt_link.c

Modified: head/cddl/contrib/opensolaris/lib/libdtrace/common/dt_link.c
==
--- head/cddl/contrib/opensolaris/lib/libdtrace/common/dt_link.cSun May 
17 00:55:44 2015(r283023)
+++ head/cddl/contrib/opensolaris/lib/libdtrace/common/dt_link.cSun May 
17 03:50:42 2015(r283024)
@@ -1785,17 +1785,11 @@ dtrace_program_link(dtrace_hdl_t *dtp, d
"failed to open %s: %s", file, strerror(errno)));
}
 #else
-   if (dtp->dt_lazyload) {
-   if ((fd = open(file, O_RDWR | O_CREAT | O_TRUNC, 0666)) < 0)
-   return (dt_link_error(dtp, NULL, -1, NULL,
-   "failed to open %s: %s", file, strerror(errno)));
-   } else {
-   snprintf(tfile, sizeof(tfile), "%s.XX", file);
-   if ((fd = mkstemp(tfile)) == -1)
-   return (dt_link_error(dtp, NULL, -1, NULL,
-   "failed to create temporary file %s: %s",
-   tfile, strerror(errno)));
-   }
+   snprintf(tfile, sizeof(tfile), "%s.XX", file);
+   if ((fd = mkostemp(tfile, O_CLOEXEC)) == -1)
+   return (dt_link_error(dtp, NULL, -1, NULL,
+   "failed to create temporary file %s: %s",
+   tfile, strerror(errno)));
 #endif
 
/*
@@ -1951,14 +1945,23 @@ dtrace_program_link(dtrace_hdl_t *dtp, d
}
 #endif
} else {
+#ifdef __FreeBSD__
+   if (rename(tfile, file) != 0) {
+   ret = dt_link_error(dtp, NULL, fd, NULL,
+   "failed to rename %s to %s: %s", tfile, file,
+   strerror(errno));
+   goto done;
+   }
+#endif
(void) close(fd);
}
 
 done:
dtrace_dof_destroy(dtp, dof);
 
-#ifndef illumos
-   unlink(tfile);
+#ifdef illumos
+   if (!dtp->dt_lazyload)
+   (void) unlink(tfile);
 #endif
return (ret);
 }
___
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: r282985 - in head/sys: arm/annapurna arm/annapurna/alpine arm/annapurna/alpine/hal arm/conf boot/fdt/dts/arm

2015-05-16 Thread Adrian Chadd
Did you commit files with DOS newlines in them? :)

tsk tsk tsk tsk tsk. I think should fix that..


-adrian
___
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: r283023 - head/usr.sbin/bsdinstall/scripts

2015-05-16 Thread Allan Jude
Author: allanjude (doc committer)
Date: Sun May 17 00:55:44 2015
New Revision: 283023
URL: https://svnweb.freebsd.org/changeset/base/283023

Log:
  bsdinstall/zfsboot: Skip adding swap lines to /etc/fstab if swap is 0 sized
  
  Differential Revision:https://reviews.freebsd.org/D2571
  Reviewed by:  dim
  Approved by:  eadler (mentor)
  Sponsored by: ScaleEngine Inc.

Modified:
  head/usr.sbin/bsdinstall/scripts/zfsboot

Modified: head/usr.sbin/bsdinstall/scripts/zfsboot
==
--- head/usr.sbin/bsdinstall/scripts/zfsbootSat May 16 23:51:24 2015
(r283022)
+++ head/usr.sbin/bsdinstall/scripts/zfsbootSun May 17 00:55:44 2015
(r283023)
@@ -953,6 +953,8 @@ zfs_create_diskpart()
esac # $ZFSBOOT_PARTITION_SCHEME
 
# Update fstab(5)
+   local swapsize
+   f_expand_number "$ZFSBOOT_SWAP_SIZE" swapsize
if [ "$isswapmirror" ]; then
# This is not the first disk in the mirror, do nothing
elif [ "$ZFSBOOT_SWAP_ENCRYPTION" -a "$ZFSBOOT_SWAP_MIRROR" ]; then
@@ -972,6 +974,8 @@ zfs_create_diskpart()
 /dev/$disk${swappart}.eli none swap sw 0 0 \
 $BSDINSTALL_TMPETC/fstab ||
 return $FAILURE
+   elif [ ${swapsize:-0} -eq 0 ]
+   # If swap is 0 sized, don't add it to fstab
else
f_eval_catch $funcname printf "$PRINTF_FSTAB" \
 /dev/$disk$swappart none swap sw 0 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: r283022 - head/sys/mips/include

2015-05-16 Thread Adrian Chadd
Author: adrian
Date: Sat May 16 23:51:24 2015
New Revision: 283022
URL: https://svnweb.freebsd.org/changeset/base/283022

Log:
  Increment the vm stats "v_intr" counter so the global system interrupt
  statistics work again.
  
  I'm not sure why/when this broke, only that it used to work fine.
  
  This commit is brought to you by Maker Faire Bay Area 2015.

Modified:
  head/sys/mips/include/intr_machdep.h

Modified: head/sys/mips/include/intr_machdep.h
==
--- head/sys/mips/include/intr_machdep.hSat May 16 23:39:54 2015
(r283021)
+++ head/sys/mips/include/intr_machdep.hSat May 16 23:51:24 2015
(r283022)
@@ -70,5 +70,6 @@ mips_intrcnt_inc(mips_intrcnt_t counter)
 {
if (counter)
atomic_add_long(counter, 1);
+   PCPU_INC(cnt.v_intr);
 }
 #endif /* !_MACHINE_INTR_MACHDEP_H_ */
___
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: r283021 - in stable/10: etc/mtree tests/sys/kern tests/sys/kern/execve

2015-05-16 Thread Garrett Cooper
Author: ngie
Date: Sat May 16 23:39:54 2015
New Revision: 283021
URL: https://svnweb.freebsd.org/changeset/base/283021

Log:
  MFC r282061:
  
  Integrate tools/regression/execve into the FreeBSD test suite as
  tests/sys/kern/execve

Added:
  stable/10/tests/sys/kern/execve/
 - copied from r282061, head/tests/sys/kern/execve/
Modified:
  stable/10/etc/mtree/BSD.tests.dist
  stable/10/tests/sys/kern/Makefile
Directory Properties:
  stable/10/   (props changed)

Modified: stable/10/etc/mtree/BSD.tests.dist
==
--- stable/10/etc/mtree/BSD.tests.dist  Sat May 16 23:18:30 2015
(r283020)
+++ stable/10/etc/mtree/BSD.tests.dist  Sat May 16 23:39:54 2015
(r283021)
@@ -185,6 +185,8 @@
 file
 ..
 kern
+execve
+..
 ..
 kqueue
 ..

Modified: stable/10/tests/sys/kern/Makefile
==
--- stable/10/tests/sys/kern/Makefile   Sat May 16 23:18:30 2015
(r283020)
+++ stable/10/tests/sys/kern/Makefile   Sat May 16 23:39:54 2015
(r283021)
@@ -10,4 +10,6 @@ LDADD.unix_seqpacket_test+=   -lpthread
 
 WARNS?=5
 
+TESTS_SUBDIRS+=execve
+
 .include 
___
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: r283020 - stable/9/contrib/llvm/patches

2015-05-16 Thread Dimitry Andric
Author: dim
Date: Sat May 16 23:18:30 2015
New Revision: 283020
URL: https://svnweb.freebsd.org/changeset/base/283020

Log:
  Bring the contrib/llvm/patches directory up-to-date for stable/9.
  
  MFC r263892:
  Add the llvm/clang patch for r263891.
  
  MFC r264350:
  Update the llvm/clang patch for r264345.
  
  MFC r264828:
  Add patches corresponding to r264826 and r264827
  
  MFC r266630:
  Add the clang patch for r265477.  While here, add a description to the
  patch for r263619, and unify all the URLs to point to svnweb.
  
  MFC r266675:
  Add the clang patch for r266674.
  
  MFC r275651:
  Add llvm patch corresponding to r275633.
  
  MFC r275747:
  Update llvm patches for r274286 and r275633 so all the tests will pass.
  
  MFC r275760:
  Add clang patch corresponding to r275759.
  
  MFC r275772:
  Update clang patch for r275759 to use correct test cases.
  
  MFC r283015:
  Bring the contrib/llvm/patches directory up-to-date.
  
  MFC r263892:
  Add the llvm/clang patch for r263891.
  
  MFC r264350:
  Update the llvm/clang patch for r264345.
  
  MFC r266675:
  Add the clang patch for r266674.
  
  MFC r275651:
  Add llvm patch corresponding to r275633.
  
  MFC r275747:
  Update llvm patches for r274286 and r275633 so all the tests will pass.
  
  MFC r275760:
  Add clang patch corresponding to r275759.
  
  MFC r275772:
  Update clang patch for r275759 to use correct test cases.
  
  Partially merge r283015 from stable/10:
  Additionally:
  * Remove the clang patch corresponding to r263619, as ARM EABI
hard-float support was never MFC'd.
  * Add clang patch corresponding to r279302.

Added:
  stable/9/contrib/llvm/patches/patch-r264345-dwarf2-freebsd10.diff
 - copied unchanged from r264350, 
head/contrib/llvm/patches/patch-r264345-dwarf2-freebsd10.diff
  
stable/9/contrib/llvm/patches/patch-r264826-llvm-r202188-variadic-fn-debug-info.diff
 - copied, changed from r264828, 
head/contrib/llvm/patches/patch-r264826-llvm-r202188-variadic-fn-debug-info.diff
  
stable/9/contrib/llvm/patches/patch-r264827-clang-r202185-variadic-fn-debug-info.diff
 - copied, changed from r264828, 
head/contrib/llvm/patches/patch-r264827-clang-r202185-variadic-fn-debug-info.diff
  
stable/9/contrib/llvm/patches/patch-r265477-clang-r198655-standalone-debug.diff
 - copied unchanged from r266630, 
head/contrib/llvm/patches/patch-r265477-clang-r198655-standalone-debug.diff
  stable/9/contrib/llvm/patches/patch-r266674-clang-r209489-fix-xmmintrin.diff
 - copied unchanged from r266675, 
head/contrib/llvm/patches/patch-r266674-clang-r209489-fix-xmmintrin.diff
  stable/9/contrib/llvm/patches/patch-r275633-llvm-r223171-fix-vectorizer.diff
 - copied, changed from r275651, 
head/contrib/llvm/patches/patch-r275633-llvm-r223171-fix-vectorizer.diff
  stable/9/contrib/llvm/patches/patch-r275759-clang-r221170-ppc-vaarg.diff
 - copied, changed from r275760, 
head/contrib/llvm/patches/patch-r275759-clang-r221170-ppc-vaarg.diff
  stable/9/contrib/llvm/patches/patch-r279302-clang-r211785-add-fuse-ld.diff
 - copied unchanged from r283015, 
stable/10/contrib/llvm/patches/patch-r279302-clang-r211785-add-fuse-ld.diff
Modified:
  stable/9/contrib/llvm/patches/patch-r208961-clang-version-include.diff
  stable/9/contrib/llvm/patches/patch-r208987-format-extensions.diff
  stable/9/contrib/llvm/patches/patch-r209107-clang-vendor-suffix.diff
  stable/9/contrib/llvm/patches/patch-r213492-amd64-multi-os-dot.diff
  stable/9/contrib/llvm/patches/patch-r221503-default-target-triple.diff
  stable/9/contrib/llvm/patches/patch-r243830-arm-disable-clear-cache.diff
  stable/9/contrib/llvm/patches/patch-r252503-arm-transient-stack-alignment.diff
  stable/9/contrib/llvm/patches/patch-r257109-add-CC-aliases.diff
  stable/9/contrib/llvm/patches/patch-r259053-gcc-installation-detector.diff
  stable/9/contrib/llvm/patches/patch-r259498-add-fxsave.diff
  
stable/9/contrib/llvm/patches/patch-r261680-clang-r200899-fix-security-quantis.diff
  stable/9/contrib/llvm/patches/patch-r261991-llvm-r195391-fix-dwarf2.diff
  stable/9/contrib/llvm/patches/patch-r261991-llvm-r198385-fix-dwarf2.diff
  stable/9/contrib/llvm/patches/patch-r261991-llvm-r198389-fix-dwarf2.diff
  stable/9/contrib/llvm/patches/patch-r262261-llvm-r198028-sparc.diff
  stable/9/contrib/llvm/patches/patch-r262261-llvm-r198029-sparc.diff
  stable/9/contrib/llvm/patches/patch-r262261-llvm-r198030-sparc.diff
  stable/9/contrib/llvm/patches/patch-r262261-llvm-r198145-sparc.diff
  stable/9/contrib/llvm/patches/patch-r262261-llvm-r198149-sparc.diff
  stable/9/contrib/llvm/patches/patch-r262261-llvm-r198157-sparc.diff
  stable/9/contrib/llvm/patches/patch-r262261-llvm-r198280-sparc.diff
  stable/9/contrib/llvm/patches/patch-r262261-llvm-r198281-sparc.diff
  stable/9/contrib/llvm/patches/patch-r262261-llvm-r198286-sparc.diff
  stable/9/contrib/llvm/patches/patch-r262261-llvm-r198480-sparc.diff
  stable/9/contrib/llvm/patches/patch-r262261-llvm-r198484-sparc.diff
  stable/9/co

svn commit: r283019 - in stable/9/contrib/llvm: include/llvm lib/CodeGen/AsmPrinter lib/Target/ARM tools/clang/include/clang/Driver tools/clang/include/clang/Frontend tools/clang/lib/CodeGen tools/...

2015-05-16 Thread Dimitry Andric
Author: dim
Date: Sat May 16 23:00:03 2015
New Revision: 283019
URL: https://svnweb.freebsd.org/changeset/base/283019

Log:
  Bring clang 3.4.1 in stable/9 in sync with the version in stable/10.
  
  MFC r252503 (by andrew):
  Work around an ARM EABI issue where clang would sometimes incorrectly align
  the stack in a leaf function that uses TLS.
  
  The issue is, when using TLS, the function is no longer a leaf as it calls
  __aeabi_read_tp. With statically linked programs this is not an issue as
  it doesn't make use of the stack, however with dynamically linked
  applications we enter rtld which does use the stack and makes assumptions
  about it's alignment.
  
  This is only a temporary fix until a better patch can be made and submitted
  upstream.
  
  MFC r264826 (by emaste):
  Merge LLVM r202188:
  
Debug info: Support variadic functions.
Variadic functions have an unspecified parameter tag after the last
argument. In IR this is represented as an unspecified parameter in the
subroutine type.
  
Paired commit with CFE r202185.
  
rdar://problem/13690847
  
This re-applies r202184 + a bugfix in DwarfDebug's argument handling.
  
  This merge includes a change to use the LLVM 3.4 API in
  lib/CodeGen/AsmPrinter/DwarfCompileUnit.cpp:
  
  DwarfUnit -> CompileUnit
  
  Sponsored by:   DARPA, AFRL
  
  MFC r264827 (by emaste):
  Merge Clang r202185:
  
Debug info: Generate debug info for variadic functions.
Paired commit with LLVM.
  
rdar://problem/13690847
  
  This merege includes changes to use the Clang 3.4 API (revisions
  199686 and 200082) in lib/CodeGen/CGDebugInfo.cpp:
  
  getParamType  -> getArgType
  getNumParams  -> getNumArgs
  getReturnType -> getResultType
  
  Sponsored by: DARPA, AFRL
  
  MFC r265477 (by emaste):
  Merge -fstandalone-debug from Clang r198655:
  
Implement a new -fstandalone-debug option. rdar://problem/15685848
It controls everything that -flimit-debug-info used to, plus the
vtable type optimization. The old -fno-limit-debug-info option is now an
alias to -fstandalone-debug and vice versa.
  
Standalone is the default on Darwin until dtrace is updated to work with
non-standalone debug info (rdar://problem/15758808).
  
Note: I kept the LimitedDebugInfo name in CodeGenOptions::DebugInfoKind
because NoStandaloneDebugInfo sounded even more confusing.
  
  MFC r269387 (by andrew):
  Update the ARMv6 core clang targets to be an arm1176jzf-s. This brings us
  in line with gcc in base as this makes llvm generate code for the armv6k
  variant of the instruction set.

Modified:
  stable/9/contrib/llvm/include/llvm/DIBuilder.h
  stable/9/contrib/llvm/lib/CodeGen/AsmPrinter/DwarfCompileUnit.cpp
  stable/9/contrib/llvm/lib/CodeGen/AsmPrinter/DwarfCompileUnit.h
  stable/9/contrib/llvm/lib/CodeGen/AsmPrinter/DwarfDebug.cpp
  stable/9/contrib/llvm/lib/Target/ARM/ARMFrameLowering.h
  stable/9/contrib/llvm/tools/clang/include/clang/Driver/Options.td
  stable/9/contrib/llvm/tools/clang/include/clang/Frontend/CodeGenOptions.h
  stable/9/contrib/llvm/tools/clang/lib/CodeGen/CGDebugInfo.cpp
  stable/9/contrib/llvm/tools/clang/lib/Driver/ToolChain.cpp
  stable/9/contrib/llvm/tools/clang/lib/Driver/Tools.cpp
  stable/9/contrib/llvm/tools/clang/lib/Frontend/CompilerInvocation.cpp
Directory Properties:
  stable/9/   (props changed)
  stable/9/contrib/   (props changed)
  stable/9/contrib/llvm/   (props changed)
  stable/9/contrib/llvm/tools/clang/   (props changed)

Modified: stable/9/contrib/llvm/include/llvm/DIBuilder.h
==
--- stable/9/contrib/llvm/include/llvm/DIBuilder.h  Sat May 16 22:53:26 
2015(r283018)
+++ stable/9/contrib/llvm/include/llvm/DIBuilder.h  Sat May 16 23:00:03 
2015(r283019)
@@ -439,7 +439,7 @@ namespace llvm {
 /// through debug info anchors.
 void retainType(DIType T);
 
-/// createUnspecifiedParameter - Create unspeicified type descriptor
+/// createUnspecifiedParameter - Create unspecified type descriptor
 /// for a subroutine type.
 DIDescriptor createUnspecifiedParameter();
 

Modified: stable/9/contrib/llvm/lib/CodeGen/AsmPrinter/DwarfCompileUnit.cpp
==
--- stable/9/contrib/llvm/lib/CodeGen/AsmPrinter/DwarfCompileUnit.cpp   Sat May 
16 22:53:26 2015(r283018)
+++ stable/9/contrib/llvm/lib/CodeGen/AsmPrinter/DwarfCompileUnit.cpp   Sat May 
16 23:00:03 2015(r283019)
@@ -1116,6 +1116,22 @@ void CompileUnit::constructTypeDIE(DIE &
 addSourceLine(&Buffer, DTy);
 }
 
+/// constructSubprogramArguments - Construct function argument DIEs.
+void CompileUnit::constructSubprogramArguments(DIE &Buffer, DIArray Args) {
+for (unsigned i = 1, N = Args.getNumElements(); i < N; ++i) {
+  DIDescriptor Ty = Args.getElement(i);
+  if (Ty.isUnspecifiedParameter()) {
+assert(i 

svn commit: r283018 - head/tools/regression/p1003_1b

2015-05-16 Thread Garrett Cooper
Author: ngie
Date: Sat May 16 22:53:26 2015
New Revision: 283018
URL: https://svnweb.freebsd.org/changeset/base/283018

Log:
  Fix more warnings related to missing headers
  
  MFC after: 1 week

Modified:
  head/tools/regression/p1003_1b/main.c
  head/tools/regression/p1003_1b/prutil.c

Modified: head/tools/regression/p1003_1b/main.c
==
--- head/tools/regression/p1003_1b/main.c   Sat May 16 22:38:16 2015
(r283017)
+++ head/tools/regression/p1003_1b/main.c   Sat May 16 22:53:26 2015
(r283018)
@@ -1,5 +1,6 @@
 /* $FreeBSD$ */
 #include 
+#include 
 
 int fifo(int argc, char *argv[]);
 int memlock(int argc, char *argv[]);

Modified: head/tools/regression/p1003_1b/prutil.c
==
--- head/tools/regression/p1003_1b/prutil.c Sat May 16 22:38:16 2015
(r283017)
+++ head/tools/regression/p1003_1b/prutil.c Sat May 16 22:53:26 2015
(r283018)
@@ -1,10 +1,11 @@
+#include 
 #include 
-#include 
 #include 
 #include 
-
-#include 
+#include 
 #include 
+#include 
+
 #include "prutil.h"
 
 /*
@@ -12,7 +13,7 @@
  */
 void quit(const char *text)
 {
-   err(errno, text);
+   err(errno, "%s", text);
 }
 
 char *sched_text(int scheduler)
___
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: r283017 - stable/9/sbin/ifconfig

2015-05-16 Thread Garrett Cooper
Author: ngie
Date: Sat May 16 22:38:16 2015
New Revision: 283017
URL: https://svnweb.freebsd.org/changeset/base/283017

Log:
  MFstable/10 r283016:
  
  MFC r282747:
  
  Use MIN from sys/param.h instead of handrolling the macro
  
  Replace sys/types.h with sys/param.h per-style(9)
  
  Sponsored by: EMC / Isilon Storage Division

Modified:
  stable/9/sbin/ifconfig/af_inet.c
Directory Properties:
  stable/9/   (props changed)
  stable/9/sbin/   (props changed)
  stable/9/sbin/ifconfig/   (props changed)

Modified: stable/9/sbin/ifconfig/af_inet.c
==
--- stable/9/sbin/ifconfig/af_inet.cSat May 16 22:36:19 2015
(r283016)
+++ stable/9/sbin/ifconfig/af_inet.cSat May 16 22:38:16 2015
(r283017)
@@ -32,7 +32,7 @@ static const char rcsid[] =
   "$FreeBSD$";
 #endif /* not lint */
 
-#include 
+#include 
 #include 
 #include 
 #include 
@@ -98,7 +98,6 @@ static struct sockaddr_in *sintab[] = {
 static void
 in_getaddr(const char *s, int which)
 {
-#defineMIN(a,b)((a)<(b)?(a):(b))
struct sockaddr_in *sin = sintab[which];
struct hostent *hp;
struct netent *np;
@@ -139,7 +138,6 @@ in_getaddr(const char *s, int which)
sin->sin_addr = inet_makeaddr(np->n_net, INADDR_ANY);
else
errx(1, "%s: bad value", s);
-#undef MIN
 }
 
 static void
___
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: r283016 - stable/10/sbin/ifconfig

2015-05-16 Thread Garrett Cooper
Author: ngie
Date: Sat May 16 22:36:19 2015
New Revision: 283016
URL: https://svnweb.freebsd.org/changeset/base/283016

Log:
  MFC r282747:
  
  Use MIN from sys/param.h instead of handrolling the macro
  
  Replace sys/types.h with sys/param.h per-style(9)
  
  Sponsored by: EMC / Isilon Storage Division

Modified:
  stable/10/sbin/ifconfig/af_inet.c
Directory Properties:
  stable/10/   (props changed)

Modified: stable/10/sbin/ifconfig/af_inet.c
==
--- stable/10/sbin/ifconfig/af_inet.c   Sat May 16 22:06:40 2015
(r283015)
+++ stable/10/sbin/ifconfig/af_inet.c   Sat May 16 22:36:19 2015
(r283016)
@@ -32,7 +32,7 @@ static const char rcsid[] =
   "$FreeBSD$";
 #endif /* not lint */
 
-#include 
+#include 
 #include 
 #include 
 #include 
@@ -101,7 +101,6 @@ static struct sockaddr_in *sintab[] = {
 static void
 in_getaddr(const char *s, int which)
 {
-#defineMIN(a,b)((a)<(b)?(a):(b))
struct sockaddr_in *sin = sintab[which];
struct hostent *hp;
struct netent *np;
@@ -142,7 +141,6 @@ in_getaddr(const char *s, int which)
sin->sin_addr = inet_makeaddr(np->n_net, INADDR_ANY);
else
errx(1, "%s: bad value", s);
-#undef MIN
 }
 
 static void
___
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: r283015 - stable/10/contrib/llvm/patches

2015-05-16 Thread Dimitry Andric
Author: dim
Date: Sat May 16 22:06:40 2015
New Revision: 283015
URL: https://svnweb.freebsd.org/changeset/base/283015

Log:
  Bring the contrib/llvm/patches directory up-to-date.
  
  MFC r263892:
  Add the llvm/clang patch for r263891.
  
  MFC r264350:
  Update the llvm/clang patch for r264345.
  
  MFC r266675:
  Add the clang patch for r266674.
  
  MFC r275651:
  Add llvm patch corresponding to r275633.
  
  MFC r275747:
  Update llvm patches for r274286 and r275633 so all the tests will pass.
  
  MFC r275760:
  Add clang patch corresponding to r275759.
  
  MFC r275772:
  Update clang patch for r275759 to use correct test cases.
  
  Additionally:
  * Remove the clang patch corresponding to r263619, as ARM EABI
hard-float support was never MFC'd.
  * Add clang patch corresponding to r279302.

Added:
  stable/10/contrib/llvm/patches/patch-r264345-dwarf2-freebsd10.diff
 - copied unchanged from r264350, 
head/contrib/llvm/patches/patch-r264345-dwarf2-freebsd10.diff
  stable/10/contrib/llvm/patches/patch-r266674-clang-r209489-fix-xmmintrin.diff
 - copied unchanged from r266675, 
head/contrib/llvm/patches/patch-r266674-clang-r209489-fix-xmmintrin.diff
  stable/10/contrib/llvm/patches/patch-r275633-llvm-r223171-fix-vectorizer.diff
 - copied, changed from r275651, 
head/contrib/llvm/patches/patch-r275633-llvm-r223171-fix-vectorizer.diff
  stable/10/contrib/llvm/patches/patch-r275759-clang-r221170-ppc-vaarg.diff
 - copied, changed from r275760, 
head/contrib/llvm/patches/patch-r275759-clang-r221170-ppc-vaarg.diff
  stable/10/contrib/llvm/patches/patch-r279302-clang-r211785-add-fuse-ld.diff
Deleted:
  stable/10/contrib/llvm/patches/patch-r263619-clang-r201662-arm-gnueabihf.diff
Modified:
  stable/10/contrib/llvm/patches/patch-r274286-llvm-r201784-asm-dollar.diff
Directory Properties:
  stable/10/   (props changed)

Copied: stable/10/contrib/llvm/patches/patch-r264345-dwarf2-freebsd10.diff 
(from r264350, head/contrib/llvm/patches/patch-r264345-dwarf2-freebsd10.diff)
==
--- /dev/null   00:00:00 1970   (empty, because file is newly added)
+++ stable/10/contrib/llvm/patches/patch-r264345-dwarf2-freebsd10.diff  Sat May 
16 22:06:40 2015(r283015, copy of r264350, 
head/contrib/llvm/patches/patch-r264345-dwarf2-freebsd10.diff)
@@ -0,0 +1,20 @@
+This patch makes clang default to DWARF2 debug info format for FreeBSD.
+
+Introduced here: http://svnweb.freebsd.org/changeset/base/264345
+
+Index: tools/clang/lib/Driver/Tools.cpp
+===
+--- tools/clang/lib/Driver/Tools.cpp
 tools/clang/lib/Driver/Tools.cpp
+@@ -2627,8 +2635,9 @@ void Clang::ConstructJob(Compilation &C, const Job
+   CmdArgs.push_back("-gdwarf-4");
+ else if (!A->getOption().matches(options::OPT_g0) &&
+  !A->getOption().matches(options::OPT_ggdb0)) {
+-  // Default is dwarf-2 for darwin.
+-  if (getToolChain().getTriple().isOSDarwin())
++  // Default is dwarf-2 for darwin and FreeBSD.
++  const llvm::Triple &Triple = getToolChain().getTriple();
++  if (Triple.isOSDarwin() || Triple.getOS() == llvm::Triple::FreeBSD)
+ CmdArgs.push_back("-gdwarf-2");
+   else
+ CmdArgs.push_back("-g");

Copied: 
stable/10/contrib/llvm/patches/patch-r266674-clang-r209489-fix-xmmintrin.diff 
(from r266675, 
head/contrib/llvm/patches/patch-r266674-clang-r209489-fix-xmmintrin.diff)
==
--- /dev/null   00:00:00 1970   (empty, because file is newly added)
+++ 
stable/10/contrib/llvm/patches/patch-r266674-clang-r209489-fix-xmmintrin.diff   
Sat May 16 22:06:40 2015(r283015, copy of r266675, 
head/contrib/llvm/patches/patch-r266674-clang-r209489-fix-xmmintrin.diff)
@@ -0,0 +1,49 @@
+Pull in r209489 from upstream clang trunk (by Akira Hatanaka):
+
+  Fix a bug in xmmintrin.h.
+
+  The last step of _mm_cvtps_pi16 should use _mm_packs_pi32, which is a 
function
+  that reads two __m64 values and packs four 32-bit values into four 16-bit
+  values.  
+
+  
+
+Pull in r209559 from upstream clang trunk (by Akira Hatanaka):
+
+  Recommit r209532 with -ffreestanding.
+
+  This is a test case for r209489.
+
+Introduced here: http://svnweb.freebsd.org/changeset/base/266674
+
+Index: tools/clang/lib/Headers/xmmintrin.h
+===
+--- tools/clang/lib/Headers/xmmintrin.h
 tools/clang/lib/Headers/xmmintrin.h
+@@ -903,7 +903,7 @@ _mm_cvtps_pi16(__m128 __a)
+   __a = _mm_movehl_ps(__a, __a);
+   __c = _mm_cvtps_pi32(__a);
+   
+-  return _mm_packs_pi16(__b, __c);
++  return _mm_packs_pi32(__b, __c);
+ }
+ 
+ static __inline__ __m64 __attribute__((__always_inline__, __nodebug__))
+Index: tools/clang/test/Headers/xmmintrin.c
+===
+--- tools/clang/test/Headers/x

svn commit: r283014 - head/sys/arm/arm

2015-05-16 Thread Warner Losh
Author: imp
Date: Sat May 16 21:24:32 2015
New Revision: 283014
URL: https://svnweb.freebsd.org/changeset/base/283014

Log:
  Don't allow unmapped I/O. The pmap isn't quite up to the task. Add a
  comment to this effect and switch the default. My old AT91SAM9G20
  now boots, fsck's the SD card and runs w/o an issue for the first
  time since a 9.1-ish stable build I did a few years ago.
  
  Problems with unmapped I/O:
  o un-page-aligned I/O requests to devices fail (notably fsck
and newfs).
  o write-back caching was totally broken. write-through caching
needed to be enabled.
  o Even page-aligned I/O requests sometimes failed for reasons
not thoroughly investigated.
  
  Suggested by: ian@
  MFC after: 2 days

Modified:
  head/sys/arm/arm/pmap.c

Modified: head/sys/arm/arm/pmap.c
==
--- head/sys/arm/arm/pmap.c Sat May 16 21:08:33 2015(r283013)
+++ head/sys/arm/arm/pmap.c Sat May 16 21:24:32 2015(r283014)
@@ -4310,7 +4310,13 @@ pmap_copy_page(vm_page_t src, vm_page_t 
pmap_copy_page_func(VM_PAGE_TO_PHYS(src), VM_PAGE_TO_PHYS(dst));
 }
 
-int unmapped_buf_allowed = 1;
+/*
+ * We have code to do unmapped I/O. However, it isn't quite right
+ * an causes un-page-aligned I/O to devices to fail (most notably
+ * newfs or fsck). We give up a little performance to do this, but
+ * we trade that for rock-solid stability so it is a good trade.
+ */
+int unmapped_buf_allowed = 0;
 
 void
 pmap_copy_pages(vm_page_t ma[], vm_offset_t a_offset, vm_page_t mb[],
___
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: r283013 - head/sys/boot/arm/uboot

2015-05-16 Thread Ian Lepore
Author: ian
Date: Sat May 16 21:08:33 2015
New Revision: 283013
URL: https://svnweb.freebsd.org/changeset/base/283013

Log:
  Re-link ubldr when any of its libraries change.

Modified:
  head/sys/boot/arm/uboot/Makefile

Modified: head/sys/boot/arm/uboot/Makefile
==
--- head/sys/boot/arm/uboot/MakefileSat May 16 20:06:39 2015
(r283012)
+++ head/sys/boot/arm/uboot/MakefileSat May 16 21:08:33 2015
(r283013)
@@ -130,11 +130,11 @@ ldscript.abs:
 ldscript.pie:
echo "UBLDR_LOADADDR = 0;" >${.TARGET}
 
-ubldr: ${OBJS} ldscript.abs ${.CURDIR}/ldscript.${MACHINE_CPUARCH}
+ubldr: ${OBJS} ldscript.abs ${.CURDIR}/ldscript.${MACHINE_CPUARCH} ${DPADD}
${CC} ${CFLAGS} -T ldscript.abs ${LDFLAGS} \
-o ${.TARGET} ${OBJS} ${LDADD}
 
-ubldr.pie: ${OBJS} ldscript.pie ${.CURDIR}/ldscript.${MACHINE_CPUARCH}
+ubldr.pie: ${OBJS} ldscript.pie ${.CURDIR}/ldscript.${MACHINE_CPUARCH} ${DPADD}
${CC} ${CFLAGS} -T ldscript.pie ${LDFLAGS} -pie -Wl,-Bsymbolic \
-o ${.TARGET} ${OBJS} ${LDADD}
 
___
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: r282314 - in head: include lib/libc/stdlib

2015-05-16 Thread Oliver Pinter
On 5/3/15, Oliver Pinter  wrote:
> On 5/3/15, Baptiste Daroussin  wrote:
>> On Sun, May 03, 2015 at 04:00:15PM +0200, Oliver Pinter wrote:
>>> On 5/1/15, Baptiste Daroussin  wrote:
>>> > Author: bapt
>>> > Date: Fri May  1 18:32:16 2015
>>> > New Revision: 282314
>>> > URL: https://svnweb.freebsd.org/changeset/base/282314
>>> >
>>> > Log:
>>> >   Import reallocarray(3) from OpenBSD
>>> >
>>> >   Add a manpage for it, assign the copyright to the OpenBSD project on
>>> > it
>>> > since it
>>> >   is mostly copy/paste from OpenBSD manpage.
>>> >   style(9) fixes
>>> >
>>> >   Differential Revision:  https://reviews.freebsd.org/D2420
>>> >   Reviewed by:kib
>>> >
>>> > Added:
>>> >   head/lib/libc/stdlib/reallocarray.3   (contents, props changed)
>>> >   head/lib/libc/stdlib/reallocarray.c   (contents, props changed)
>>> > Modified:
>>> >   head/include/stdlib.h
>>> >   head/lib/libc/stdlib/Makefile.inc
>>> >   head/lib/libc/stdlib/Symbol.map
>>> >
>>> > Modified: head/include/stdlib.h
>>> > ...
>>> > +}
>>>
>>> Hey Bapt!
>>>
>>> Do you have any plan to MFC these changes to 10-STABLE?
>>
>> I had no plan to but you are the 5th one to ask me about that :)
>> So yes I may MFC that in a couple of weeks.
>>
> Cool! Thanks!

Hi Baptiste!

Is the any ongoing efforts to merge this stuff to 10-STABLE? If you
have a patch and you need help, then ping me.

>
>> Best regards,
>> Bapt
>>
>
___
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: r283012 - head/sys/dev/acpi_support

2015-05-16 Thread Rui Paulo
Author: rpaulo
Date: Sat May 16 20:06:39 2015
New Revision: 283012
URL: https://svnweb.freebsd.org/changeset/base/283012

Log:
  acpi_ibm: whitespace.

Modified:
  head/sys/dev/acpi_support/acpi_ibm.c

Modified: head/sys/dev/acpi_support/acpi_ibm.c
==
--- head/sys/dev/acpi_support/acpi_ibm.cSat May 16 20:04:49 2015
(r283011)
+++ head/sys/dev/acpi_support/acpi_ibm.cSat May 16 20:06:39 2015
(r283012)
@@ -530,7 +530,7 @@ acpi_ibm_sysctl(SYSCTL_HANDLER_ARGS)
int error = 0;
int function;
int method;
-   
+
ACPI_FUNCTION_TRACE((char *)(uintptr_t)__func__);
 
sc = (struct acpi_ibm_softc *)oidp->oid_arg1;
@@ -823,7 +823,7 @@ acpi_ibm_sysctl_init(struct acpi_ibm_sof
return (FALSE);
 
case ACPI_IBM_METHOD_FANSPEED:
-   /* 
+   /*
 * Some models report the fan speed in levels from 0-7
 * Newer models report it contiguously
 */
@@ -834,7 +834,7 @@ acpi_ibm_sysctl_init(struct acpi_ibm_sof
 
case ACPI_IBM_METHOD_FANLEVEL:
case ACPI_IBM_METHOD_FANSTATUS:
-   /* 
+   /*
 * Fan status is only supported on those models,
 * which report fan RPM contiguously, not in levels
 */
@@ -871,10 +871,10 @@ acpi_ibm_thermal_sysctl(SYSCTL_HANDLER_A
 
for (int i = 0; i < 8; ++i) {
temp_cmd[3] = '0' + i;
-   
-   /* 
+
+   /*
 * The TMPx methods seem to return +/- 128 or 0
-* when the respecting sensor is not available 
+* when the respecting sensor is not available
 */
if (ACPI_FAILURE(acpi_GetInteger(sc->ec_handle, temp_cmd,
&temp[i])) || ABS(temp[i]) == 128 || temp[i] == 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: r283011 - head/sys/arm/annapurna/alpine

2015-05-16 Thread Bjoern A. Zeeb
Author: bz
Date: Sat May 16 20:04:49 2015
New Revision: 283011
URL: https://svnweb.freebsd.org/changeset/base/283011

Log:
  More tr -d '\r' t make config happy and
  some re-alignment whitespace changes.

Modified:
  head/sys/arm/annapurna/alpine/files.alpine
  head/sys/arm/annapurna/alpine/std.alpine

Modified: head/sys/arm/annapurna/alpine/files.alpine
==
--- head/sys/arm/annapurna/alpine/files.alpine  Sat May 16 15:44:13 2015
(r283010)
+++ head/sys/arm/annapurna/alpine/files.alpine  Sat May 16 20:04:49 2015
(r283011)
@@ -1,16 +1,16 @@
-# $FreeBSD$
-
-kern/kern_clocksource.cstandard
-
-arm/arm/bus_space_base.c   standard
-arm/arm/bus_space_generic.cstandard
-arm/arm/bus_space_asm_generic.Sstandard
-
-arm/versatile/sp804.c  standard
-arm/versatile/versatile_timer.cstandard
-dev/uart/uart_dev_ns8250.c optionaluart
-dev/ofw/ofw_cpu.c  standard
-
-arm/annapurna/alpine/common.c  standard
-arm/annapurna/alpine/alpine_machdep.c  standard
-arm/annapurna/alpine/alpine_machdep_mp.c   optionalsmp
+# $FreeBSD$
+
+kern/kern_clocksource.cstandard
+
+arm/arm/bus_space_base.c   standard
+arm/arm/bus_space_generic.cstandard
+arm/arm/bus_space_asm_generic.Sstandard
+
+arm/versatile/sp804.c  standard
+arm/versatile/versatile_timer.cstandard
+dev/uart/uart_dev_ns8250.c optionaluart
+dev/ofw/ofw_cpu.c  standard
+
+arm/annapurna/alpine/common.c  standard
+arm/annapurna/alpine/alpine_machdep.c  standard
+arm/annapurna/alpine/alpine_machdep_mp.c   optionalsmp

Modified: head/sys/arm/annapurna/alpine/std.alpine
==
--- head/sys/arm/annapurna/alpine/std.alpineSat May 16 15:44:13 2015
(r283010)
+++ head/sys/arm/annapurna/alpine/std.alpineSat May 16 20:04:49 2015
(r283011)
@@ -1,23 +1,23 @@
-# $FreeBSD$
-
-makeoption ARM_LITTLE_ENDIAN
-
-cpuCPU_CORTEXA
-machinearm armv6
-makeoptionsCONF_CFLAGS="-march=armv7a -DAL_HAVE_TYPES"
-
-makeoptionsKERNPHYSADDR=0x0020
-optionsKERNPHYSADDR=0x0020
-
-makeoptionsKERNVIRTADDR=0xa020
-optionsKERNVIRTADDR=0xa020
-
-makeoptionsKERNBASE=0xa000
-optionsKERNBASE=0xa000
-
-optionsARM_L2_PIPT
-
-optionsIPI_IRQ_START=0
-optionsIPI_IRQ_END=15
-
-files  "../annapurna/alpine/files.alpine"
+# $FreeBSD$
+
+makeoption ARM_LITTLE_ENDIAN
+
+cpuCPU_CORTEXA
+machinearm armv6
+makeoptionsCONF_CFLAGS="-march=armv7a -DAL_HAVE_TYPES"
+
+makeoptionsKERNPHYSADDR=0x0020
+optionsKERNPHYSADDR=0x0020
+
+makeoptionsKERNVIRTADDR=0xa020
+optionsKERNVIRTADDR=0xa020
+
+makeoptionsKERNBASE=0xa000
+optionsKERNBASE=0xa000
+
+optionsARM_L2_PIPT
+
+optionsIPI_IRQ_START=0
+optionsIPI_IRQ_END=15
+
+files  "../annapurna/alpine/files.alpine"
___
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: kasan (was Re: svn commit: r282948 - head/lib/libthr/thread)

2015-05-16 Thread Pedro Giffuni

> Il giorno 16/mag/2015, alle ore 14:01, Bryan Drewery  
> ha scritto:
> 
> On 5/16/2015 12:31 PM, Pedro Giffuni wrote:
>> FWIW, and somewhat off-topic ...
>> 
>> On 05/16/15 11:40, Bryan Drewery wrote:
>>> ...
>>> Modified:
>>>   head/lib/libthr/thread/thr_spec.c
>>> 
>>> Thank you for this!
>>> 
>>> I have a lot of patches at Isilon for adding a libc cleanup function to
>>> free all caching, for use in memory leak detectors such as valgrind. I
>>> even fixed valgrind to utilize it.
>> 
>> Valgrind is good but it would be nicer to have the
>> Kernel AddressSANitizer:
>> 
>> https://github.com/google/kasan/wiki
>> 
> 
> Doesn't memguard(9) basically do this? I don't like that memguard is so
> limited in its scope but it seems to be for this.
> 
> 

Somewhat, but this one is based on the Google Address Sanitizer
(the userland version is already supported in FreeBSD).

It is compiler assisted and it compares favorably to Valgrind
plus it also has an interesting record already.

There are several talks about it in youtube, for example:

https://youtu.be/capbD_aRz40  (audio is poor the 
first half)

https://youtu.be/Q2C2lP8_tNE 

Pedro.


___
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: kasan (was Re: svn commit: r282948 - head/lib/libthr/thread)

2015-05-16 Thread Bryan Drewery
On 5/16/2015 12:31 PM, Pedro Giffuni wrote:
> FWIW, and somewhat off-topic ...
> 
> On 05/16/15 11:40, Bryan Drewery wrote:
>> ...
>> Modified:
>>head/lib/libthr/thread/thr_spec.c
>>
>> Thank you for this!
>>
>> I have a lot of patches at Isilon for adding a libc cleanup function to
>> free all caching, for use in memory leak detectors such as valgrind. I
>> even fixed valgrind to utilize it.
> 
> Valgrind is good but it would be nicer to have the
> Kernel AddressSANitizer:
> 
> https://github.com/google/kasan/wiki
> 

Doesn't memguard(9) basically do this? I don't like that memguard is so
limited in its scope but it seems to be for this.


-- 
Regards,
Bryan Drewery



signature.asc
Description: OpenPGP digital signature


kasan (was Re: svn commit: r282948 - head/lib/libthr/thread)

2015-05-16 Thread Pedro Giffuni

FWIW, and somewhat off-topic ...

On 05/16/15 11:40, Bryan Drewery wrote:

...
Modified:
   head/lib/libthr/thread/thr_spec.c

Thank you for this!

I have a lot of patches at Isilon for adding a libc cleanup function to
free all caching, for use in memory leak detectors such as valgrind. I
even fixed valgrind to utilize it.


Valgrind is good but it would be nicer to have the
Kernel AddressSANitizer:

https://github.com/google/kasan/wiki

Cheers,

Pedro.
___
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: r282948 - head/lib/libthr/thread

2015-05-16 Thread Bryan Drewery
On 5/15/2015 3:40 AM, Konstantin Belousov wrote:
> Author: kib
> Date: Fri May 15 08:40:17 2015
> New Revision: 282948
> URL: https://svnweb.freebsd.org/changeset/base/282948
> 
> Log:
>   Some third-party malloc(3) implementations use pthread_setspecific(3)
>   to handle per-thread information.  Since our pthread_setspecific()
>   implementation calls calloc(3) to allocate per-thread specific data
>   storage, things get complicated.
>   
>   Switch the allocator to use bare mmap(2).  There is some loss of the
>   allocated page, since e.g. on amd64, PTHREAD_KEYS_MAX * sizeof(struct
>   pthread_specific_elem) is 3K (it actually spans whole page due to
>   padding), but I believe it is more acceptable than additional code for
>   specialized allocator().
>   
>   The alternatives would either to make the specific data array be part of
>   the struct thread, or use internal bindings to call the libc malloc,
>   avoiding interposing.
>   
>   Also do the style pass over the thr_spec.c, esp. simplify the
>   conditionals nesting by returning early when an error detected.
>   Remove trivial comments.
>   
>   Found by:   y...@rawbw.com
>   PR: 200138
>   Sponsored by:   The FreeBSD Foundation
>   MFC after:  2 weeks
> 
> Modified:
>   head/lib/libthr/thread/thr_spec.c
> 

Thank you for this!

I have a lot of patches at Isilon for adding a libc cleanup function to
free all caching, for use in memory leak detectors such as valgrind. I
even fixed valgrind to utilize it. This particular code was problematic.

I wrote up an arch mail about my patch a few months ago and it ended up
being several pages about libthr. I never sent it because it became too
long. I need to revisit that work and get an arch@ discussion going on
my proposal and the various issues I ran into with libthr.

While developing this cleanup feature, and working on a malloc wrapper
(dmalloc), I had a lot of problems with pthread_mutext_t (and similar
primitives) using calloc(3). I found that David Xu actually did do most
of the work to change this but abandoned it (it's all in SVN still).
Using pthreads from a malloc wrapper is really painful to get right.

-- 
Regards,
Bryan Drewery



signature.asc
Description: OpenPGP digital signature


svn commit: r283010 - in stable/10: contrib/gcclibs/libgomp contrib/gcclibs/libgomp/config/bsd contrib/gcclibs/libgomp/config/linux contrib/gcclibs/libgomp/config/mingw32 contrib/gcclibs/libgomp/co...

2015-05-16 Thread Pedro F. Giffuni
Author: pfg
Date: Sat May 16 15:44:13 2015
New Revision: 283010
URL: https://svnweb.freebsd.org/changeset/base/283010

Log:
  MFC   r282115, r282152, r282201
  MFV   r282150
  libgomp: Update to version 4.3.5.
  bring initial BSD support from upstream.
  
  This was not meant to be MFC'd at first but the original OMP support
  for FreeBSD was in very poor shape.  The effect of this change should
  be minimal as all ports are already using the version of libgomp that
  comes with the gcc ports. The local libgomp is planned to be disabled
  for platforms that are not using older gcc by default so this version
  of libgomp will not be shipped in tier-1 platform releases.
  
  Discussed with:   emaste

Added:
  stable/10/contrib/gcclibs/libgomp/ChangeLog.gcc44
 - copied unchanged from r282201, 
head/contrib/gcclibs/libgomp/ChangeLog.gcc44
  stable/10/contrib/gcclibs/libgomp/config/bsd/
 - copied from r282201, head/contrib/gcclibs/libgomp/config/bsd/
  stable/10/contrib/gcclibs/libgomp/config/linux/affinity.c
 - copied unchanged from r282152, 
head/contrib/gcclibs/libgomp/config/linux/affinity.c
  stable/10/contrib/gcclibs/libgomp/config/linux/proc.c
 - copied unchanged from r282152, 
head/contrib/gcclibs/libgomp/config/linux/proc.c
  stable/10/contrib/gcclibs/libgomp/config/mingw32/proc.c
 - copied unchanged from r282152, 
head/contrib/gcclibs/libgomp/config/mingw32/proc.c
  stable/10/contrib/gcclibs/libgomp/config/posix/affinity.c
 - copied unchanged from r282152, 
head/contrib/gcclibs/libgomp/config/posix/affinity.c
Modified:
  stable/10/contrib/gcclibs/libgomp/ChangeLog
  stable/10/contrib/gcclibs/libgomp/Makefile.am
  stable/10/contrib/gcclibs/libgomp/Makefile.in
  stable/10/contrib/gcclibs/libgomp/aclocal.m4
  stable/10/contrib/gcclibs/libgomp/config.h.in
  stable/10/contrib/gcclibs/libgomp/configure
  stable/10/contrib/gcclibs/libgomp/configure.ac
  stable/10/contrib/gcclibs/libgomp/configure.tgt
  stable/10/contrib/gcclibs/libgomp/env.c
  stable/10/contrib/gcclibs/libgomp/iter.c
  stable/10/contrib/gcclibs/libgomp/libgomp.h
  stable/10/contrib/gcclibs/libgomp/libgomp.texi
  stable/10/contrib/gcclibs/libgomp/omp.h.in
  stable/10/contrib/gcclibs/libgomp/omp_lib.h.in
  stable/10/contrib/gcclibs/libgomp/team.c
  stable/10/gnu/lib/libgomp/Makefile
  stable/10/gnu/lib/libgomp/config.h
Directory Properties:
  stable/10/   (props changed)

Modified: stable/10/contrib/gcclibs/libgomp/ChangeLog
==
--- stable/10/contrib/gcclibs/libgomp/ChangeLog Sat May 16 13:11:35 2015
(r283009)
+++ stable/10/contrib/gcclibs/libgomp/ChangeLog Sat May 16 15:44:13 2015
(r283010)
@@ -1,6 +1,223 @@
-2007-07-19  Release Manager
+2010-05-22  Release Manager
 
-   * GCC 4.2.1 released.
+   * GCC 4.3.5 released.
+
+2010-05-06  Ralf Wildenhues  
+
+   PR other/43620
+   * configure.ac (AM_INIT_AUTOMAKE): Add no-dist.
+   * configure: Regenerate.
+   * aclocal.m4: Regenerate.
+   * config.h.in: Regenerate.
+   * Makefile.in: Regenerate.
+   * testsuite/Makefile.in: Regenerate.
+
+2009-08-19  Tobias Burnus  
+
+   PR fortran/41102
+   omp_lib.h.in: Fix -std=f95 errors.
+
+2009-08-14  Uros Bizjak  
+
+   Backport from mainline:
+   2008-12-26  Uros Bizjak  
+
+   * testsuite/libgomp.c/atomic-6.c: Add -mieee for alpha*-*-* targets.
+
+2009-08-04  Release Manager
+
+   * GCC 4.3.4 released.
+
+2009-01-24  Release Manager
+
+   * GCC 4.3.3 released.
+
+2008-12-05  Janis Johnson  
+
+   Backport from mainline:
+   2008-05-15  Janis Johnson  
+
+   * testsuite/lib/libgomp.exp: Load new torture support.
+
+2008-12-02  Janis Johnson  
+
+   Backport from mainline:
+   2008-11-26  Janis Johnson  
+
+   PR testsuite/28870
+   * testsuite/lib/libgomp.exp: Include new timeout library files.
+   (libgomp_target_compile): Set timeout value from new proc.
+
+2008-08-27  Release Manager
+
+   * GCC 4.3.2 released.
+
+2008-06-12  Jakub Jelinek  
+
+   PR middle-end/36506
+   * testsuite/libgomp.c/reduction-5.c: New test.
+
+2008-06-06  Release Manager
+
+   * GCC 4.3.1 released.
+
+2008-05-23  Jakub Jelinek  
+
+   PR c++/36308
+   * testsuite/libgomp.c++/ctor-11.C: New test.
+   * testsuite/libgomp.c++/ctor-12.C: New test.
+
+2008-05-07  Jakub Jelinek  
+
+   PR middle-end/36106
+   * testsuite/libgomp.c/atomic-5.c: New test.
+   * testsuite/libgomp.c/atomic-6.c: New test.
+   * testsuite/libgomp.c/autopar-1.c: New test.
+
+2008-03-18  Jakub Jelinek  
+
+   PR middle-end/35611
+   * testsuite/libgomp.c/atomic-4.c: New test.
+
+   PR libgomp/35625
+   * iter.c (gomp_iter_guided_next_locked): If q > n, set end to ws->end.
+   (gomp_iter_guided_next): Likewise.
+   * testsuite/libgomp.c/pr35625.c: New test.
+
+2008-03-13  Jakub Jelinek  
+
+   PR middle-end/35185
+   * tes

svn commit: r283009 - in head: sbin/ifconfig sys/net

2015-05-16 Thread Alexander V. Chernikov
Author: melifaro
Date: Sat May 16 13:11:35 2015
New Revision: 283009
URL: https://svnweb.freebsd.org/changeset/base/283009

Log:
  * Update SFF-8024 Identifier constants.
  * Fix SFF_8436_CC_EXT in SFF-8436 memory map.
  * Add SFF-8436/8636 bits (revision compliance/nominal bitrate).
  * Do some small style/type fixes.

Modified:
  head/sbin/ifconfig/sfp.c
  head/sys/net/sff8436.h
  head/sys/net/sff8472.h

Modified: head/sbin/ifconfig/sfp.c
==
--- head/sbin/ifconfig/sfp.cSat May 16 12:05:26 2015(r283008)
+++ head/sbin/ifconfig/sfp.cSat May 16 13:11:35 2015(r283009)
@@ -182,6 +182,18 @@ static struct _nv eth_1040g[] = {
{ 0, NULL }
 };
 
+/* SFF-8636 Rev. 2.5 table 6.3: Revision compliance */
+static struct _nv rev_compl[] = {
+   { 0x1, "SFF-8436 rev <=4.8" },
+   { 0x2, "SFF-8436 rev <=4.8" },
+   { 0x3, "SFF-8636 rev <=1.3" },
+   { 0x4, "SFF-8636 rev <=1.4" },
+   { 0x5, "SFF-8636 rev <=1.5" },
+   { 0x6, "SFF-8636 rev <=2.0" },
+   { 0x7, "SFF-8636 rev <=2.5" },
+   { 0x0, "Unspecified" }
+};
+
 const char *
 find_value(struct _nv *x, int value)
 {
@@ -246,6 +258,19 @@ convert_sff_connector(char *buf, size_t 
 }
 
 static void
+convert_sff_rev_compliance(char *buf, size_t size, uint8_t value)
+{
+   const char *x;
+
+   if (value > 0x07)
+   x = "Unallocated";
+   else
+   x = find_value(rev_compl, value);
+
+   snprintf(buf, size, "%s", x);
+}
+
+static void
 get_sfp_identifier(struct i2c_info *ii, char *buf, size_t size)
 {
uint8_t data;
@@ -604,23 +629,50 @@ get_sfp_tx_power(struct i2c_info *ii, ch
 static void
 get_qsfp_rx_power(struct i2c_info *ii, char *buf, size_t size, int chan)
 {
-   char xbuf[2];
+   uint8_t xbuf[2];
 
memset(xbuf, 0, sizeof(xbuf));
-   read_i2c(ii, SFF_8436_BASE, SFF_8436_RX_CH1_MSB + (chan - 1) * 2, 2, 
xbuf);
+   read_i2c(ii, SFF_8436_BASE, SFF_8436_RX_CH1_MSB + (chan-1)*2, 2, xbuf);
convert_sff_power(ii, buf, size, xbuf);
 }
 
 static void
 get_qsfp_tx_power(struct i2c_info *ii, char *buf, size_t size, int chan)
 {
-   char xbuf[2];
+   uint8_t xbuf[2];
 
memset(xbuf, 0, sizeof(xbuf));
-   read_i2c(ii, SFF_8436_BASE, SFF_8436_TX_CH1_MSB + (chan -1) * 2, 2, 
xbuf);
+   read_i2c(ii, SFF_8436_BASE, SFF_8436_TX_CH1_MSB + (chan-1)*2, 2, xbuf);
convert_sff_power(ii, buf, size, xbuf);
 }
 
+static void
+get_qsfp_rev_compliance(struct i2c_info *ii, char *buf, size_t size)
+{
+   uint8_t xbuf;
+
+   xbuf = 0;
+   read_i2c(ii, SFF_8436_BASE, SFF_8436_STATUS, 1, &xbuf);
+   convert_sff_rev_compliance(buf, size, xbuf);
+}
+
+static uint32_t 
+get_qsfp_br(struct i2c_info *ii)
+{
+   uint8_t xbuf;
+   uint32_t rate;
+
+   xbuf = 0;
+   read_i2c(ii, SFF_8436_BASE, SFF_8436_BITRATE, 1, &xbuf);
+   rate = xbuf * 100;
+   if (xbuf == 0xFF) {
+   read_i2c(ii, SFF_8436_BASE, SFF_8636_BITRATE, 1, &xbuf);
+   rate = xbuf * 250;
+   }
+
+   return (rate);
+}
+
 /*
  * Reads i2c data from opened kernel socket.
  */
@@ -689,6 +741,7 @@ print_qsfp_status(struct i2c_info *ii, i
 {
char buf[80], buf2[40], buf3[40];
uint8_t diag_type;
+   uint32_t bitrate;
int i;
 
/* Read diagnostic monitoring type */
@@ -715,6 +768,16 @@ print_qsfp_status(struct i2c_info *ii, i
if (ii->error == 0)
printf("\t%s\n", buf);
 
+   if (verbose > 1) {
+   get_qsfp_rev_compliance(ii, buf, sizeof(buf));
+   if (ii->error == 0)
+   printf("\tcompliance level: %s\n", buf);
+
+   bitrate = get_qsfp_br(ii);
+   if (ii->error == 0 && bitrate > 0)
+   printf("\tnominal bitrate: %u Mbps\n", bitrate);
+   }
+
/* Request current measurements if they are provided: */
if (ii->do_diag != 0) {
get_qsfp_temp(ii, buf, sizeof(buf));

Modified: head/sys/net/sff8436.h
==
--- head/sys/net/sff8436.h  Sat May 16 12:05:26 2015(r283008)
+++ head/sys/net/sff8436.h  Sat May 16 13:11:35 2015(r283009)
@@ -202,7 +202,9 @@ enum {
* optional features are implemented
* (if any) in the transceiver
* (see Table 42) */
-   SFF_8436_CC_EXT = 222,  /* Check code for the Extended ID
+   SFF_8636_BITRATE= 222,  /* Nominal bit rate per channel, units
+   * of 250 Mbps */
+   SFF_8436_CC_EXT = 223,  /* Check code for the Extended ID
* Fields (bytes 192-222 incl) */
SFF_8436_VENDOR_RSRVD_START = 224,
SFF_8436_VENDOR

svn commit: r283008 - head/usr.sbin/mountd

2015-05-16 Thread Rick Macklem
Author: rmacklem
Date: Sat May 16 12:05:26 2015
New Revision: 283008
URL: https://svnweb.freebsd.org/changeset/base/283008

Log:
  Add a warning message to mountd for exported file
  systems that are automounted, since that configuration
  isn't supported. This still allows the export, since
  two emails I received felt that this should not be
  disabled. It sends the message to syslog(LOG_ERR..), so that
  it goes to the same places as the other messages related
  to /etc/exports problems, even though it is a warning and not an error.
  
  Reviewed by:  trasz
  MFC after:2 weeks

Modified:
  head/usr.sbin/mountd/mountd.c

Modified: head/usr.sbin/mountd/mountd.c
==
--- head/usr.sbin/mountd/mountd.c   Sat May 16 10:35:30 2015
(r283007)
+++ head/usr.sbin/mountd/mountd.c   Sat May 16 12:05:26 2015
(r283008)
@@ -1410,6 +1410,9 @@ get_exportlist_one(void)
}
if (check_dirpath(cp) &&
statfs(cp, &fsb) >= 0) {
+   if ((fsb.f_flags & MNT_AUTOMOUNTED) != 0)
+   syslog(LOG_ERR, "Warning: exporting of "
+   "automounted fs %s not supported", cp);
if (got_nondir) {
syslog(LOG_ERR, "dirs must be first");
getexp_err(ep, tgrp);
___
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: r283007 - head/sys/dev/sfxge

2015-05-16 Thread Andrew Rybchenko
Author: arybchik
Date: Sat May 16 10:35:30 2015
New Revision: 283007
URL: https://svnweb.freebsd.org/changeset/base/283007

Log:
  sfxge: avoid usage of ifm_data
  
  The driver uses ifm_data to save capabilities mask calculated during
  initialization when supported phy modes are discovered.
  The patch simply calculates it when either media or options are changed.
  
  Reviewed by:glebius
  Sponsored by:   Solarflare Communications, Inc.
  MFC after:  2 days
  Differential Revision: https://reviews.freebsd.org/D2540

Modified:
  head/sys/dev/sfxge/sfxge_port.c

Modified: head/sys/dev/sfxge/sfxge_port.c
==
--- head/sys/dev/sfxge/sfxge_port.c Sat May 16 10:31:15 2015
(r283006)
+++ head/sys/dev/sfxge/sfxge_port.c Sat May 16 10:35:30 2015
(r283007)
@@ -39,6 +39,8 @@ __FBSDID("$FreeBSD$");
 
 #include "sfxge.h"
 
+static int sfxge_phy_cap_mask(struct sfxge_softc *, int, uint32_t *);
+
 static int
 sfxge_mac_stat_update(struct sfxge_softc *sc)
 {
@@ -443,6 +445,7 @@ sfxge_port_start(struct sfxge_softc *sc)
efx_nic_t *enp;
size_t pdu;
int rc;
+   uint32_t phy_cap_mask;
 
port = &sc->port;
enp = sc->enp;
@@ -483,10 +486,13 @@ sfxge_port_start(struct sfxge_softc *sc)
if ((rc = efx_mac_drain(enp, B_FALSE)) != 0)
goto fail3;
 
-   if ((rc = efx_phy_adv_cap_set(sc->enp, sc->media.ifm_cur->ifm_data))
-   != 0)
+   if ((rc = sfxge_phy_cap_mask(sc, sc->media.ifm_cur->ifm_media,
+&phy_cap_mask)) != 0)
goto fail4;
 
+   if ((rc = efx_phy_adv_cap_set(sc->enp, phy_cap_mask)) != 0)
+   goto fail5;
+
port->init_state = SFXGE_PORT_STARTED;
 
/* Single poll in case there were missing initial events */
@@ -495,6 +501,7 @@ sfxge_port_start(struct sfxge_softc *sc)
 
return (0);
 
+fail5:
 fail4:
(void)efx_mac_drain(enp, B_TRUE);
 fail3:
@@ -738,12 +745,95 @@ sfxge_media_status(struct ifnet *ifp, st
SFXGE_ADAPTER_UNLOCK(sc);
 }
 
+static efx_phy_cap_type_t
+sfxge_link_mode_to_phy_cap(efx_link_mode_t mode)
+{
+   switch (mode) {
+   case EFX_LINK_10HDX:
+   return (EFX_PHY_CAP_10HDX);
+   case EFX_LINK_10FDX:
+   return (EFX_PHY_CAP_10FDX);
+   case EFX_LINK_100HDX:
+   return (EFX_PHY_CAP_100HDX);
+   case EFX_LINK_100FDX:
+   return (EFX_PHY_CAP_100FDX);
+   case EFX_LINK_1000HDX:
+   return (EFX_PHY_CAP_1000HDX);
+   case EFX_LINK_1000FDX:
+   return (EFX_PHY_CAP_1000FDX);
+   case EFX_LINK_1FDX:
+   return (EFX_PHY_CAP_1FDX);
+   default:
+   EFSYS_ASSERT(B_FALSE);
+   return (EFX_PHY_CAP_INVALID);
+   }
+}
+
+static int
+sfxge_phy_cap_mask(struct sfxge_softc *sc, int ifmedia, uint32_t *phy_cap_mask)
+{
+   efx_phy_media_type_t medium_type;
+   boolean_t mode_found = B_FALSE;
+   uint32_t cap_mask, mode_cap_mask;
+   efx_link_mode_t mode;
+   efx_phy_cap_type_t phy_cap;
+
+   efx_phy_media_type_get(sc->enp, &medium_type);
+   if (medium_type >= nitems(sfxge_link_mode)) {
+   if_printf(sc->ifnet, "unexpected media type %d\n", medium_type);
+   return (EINVAL);
+   }
+
+   efx_phy_adv_cap_get(sc->enp, EFX_PHY_CAP_PERM, &cap_mask);
+
+   for (mode = EFX_LINK_10HDX; mode < EFX_LINK_NMODES; mode++) {
+   if (ifmedia == sfxge_link_mode[medium_type][mode]) {
+   mode_found = B_TRUE;
+   break;
+   }
+   }
+
+   if (!mode_found) {
+   /*
+* If media is not in the table, it must be IFM_AUTO.
+*/
+   KASSERT((cap_mask & (1 << EFX_PHY_CAP_AN)) &&
+   ifmedia == (IFM_ETHER | IFM_AUTO),
+   ("%s: no mode for media %d", __func__, ifmedia));
+   *phy_cap_mask = (cap_mask & ~(1 << EFX_PHY_CAP_ASYM));
+   return (0);
+   }
+
+   phy_cap = sfxge_link_mode_to_phy_cap(mode);
+   if (phy_cap == EFX_PHY_CAP_INVALID) {
+   if_printf(sc->ifnet,
+ "cannot map link mode %d to phy capability\n",
+ mode);
+   return (EINVAL);
+   }
+
+   mode_cap_mask = (1 << phy_cap);
+   mode_cap_mask |= cap_mask & (1 << EFX_PHY_CAP_AN);
+#ifdef SFXGE_HAVE_PAUSE_MEDIAOPTS
+   if (ifmedia & IFM_ETH_RXPAUSE)
+   mode_cap_mask |= cap_mask & (1 << EFX_PHY_CAP_PAUSE);
+   if (!(ifmedia & IFM_ETH_TXPAUSE))
+   mode_cap_mask |= cap_mask & (1 << EFX_PHY_CAP_ASYM);
+#else
+   mode_cap_mask |= cap_mask & (1 << EFX_PHY_CAP_PAUSE);
+#endif
+
+   *phy_cap_mask = mode_cap_mask;
+   return (0);
+}
+
 static int
 sfxge_media_change(struct ifnet *ifp)
 {

svn commit: r283006 - head/sys/boot/i386/boot0

2015-05-16 Thread Thomas Quinot
Author: thomas
Date: Sat May 16 10:31:15 2015
New Revision: 283006
URL: https://svnweb.freebsd.org/changeset/base/283006

Log:
  Minor comments fixes

Modified:
  head/sys/boot/i386/boot0/boot0.S

Modified: head/sys/boot/i386/boot0/boot0.S
==
--- head/sys/boot/i386/boot0/boot0.SSat May 16 10:27:27 2015
(r283005)
+++ head/sys/boot/i386/boot0/boot0.SSat May 16 10:31:15 2015
(r283006)
@@ -541,11 +541,11 @@ putchr:
int $0x10   #  character
popw %bx# Restore
 #else /* SIO */
-   movb $0x01,%ah  # BIOS: Send
+   movb $0x01,%ah  # BIOS: Send character
 bioscom:
pushw %dx   # Save
xorw %dx,%dx# Use COM1
-   int $0x14   #  Character
+   int $0x14   # BIOS: Serial I/O
popw %dx# Restore
 #endif /* SIO */
retw# To caller
___
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: r283005 - head/sys/arm/conf

2015-05-16 Thread Bjoern A. Zeeb
Author: bz
Date: Sat May 16 10:27:27 2015
New Revision: 283005
URL: https://svnweb.freebsd.org/changeset/base/283005

Log:
  tr -d '\r' makes config a lot more happy.

Modified:
  head/sys/arm/conf/ALPINE

Modified: head/sys/arm/conf/ALPINE
==
--- head/sys/arm/conf/ALPINESat May 16 09:13:56 2015(r283004)
+++ head/sys/arm/conf/ALPINESat May 16 10:27:27 2015(r283005)
@@ -1,83 +1,83 @@
-# Kernel configuration for Alpine Board.
-#
-# For more information on this file, please read the config(5) manual page,
-# and/or the handbook section on Kernel Configuration Files:
-#
-#
http://www.FreeBSD.org/doc/en_US.ISO8859-1/books/handbook/kernelconfig-config.html
-#
-# The handbook is also available locally in /usr/share/doc/handbook
-# if you've installed the doc distribution, otherwise always see the
-# FreeBSD World Wide Web server (http://www.FreeBSD.org/) for the
-# latest information.
-#
-# An exhaustive list of options and more detailed explanations of the
-# device lines is also present in the ../../conf/NOTES and NOTES files.
-# If you are in doubt as to the purpose or necessity of a line, check first
-# in NOTES.
-#
-# $FreeBSD$
-
-ident  ALPINE
-
-include"std.armv6"
-include"../annapurna/alpine/std.alpine"
-
-makeoptionsMODULES_OVERRIDE=""
-makeoptionsWERROR="-Werror"
-
-optionsHZ=100
-optionsSCHED_4BSD  # 4BSD scheduler
-optionsSMP # Enable multiple cores
-
-# Debugging
-makeoptionsDEBUG=-g#Build kernel with gdb(1) debug symbols
-optionsBREAK_TO_DEBUGGER
-optionsKDB
-optionsDDB #Enable the kernel debugger
-
-# NFS support
-optionsNFSCL   #Network Filesystem Client
-optionsNFSLOCKD#Network Lock Manager
-optionsNFS_ROOT#NFS usable as /, requires NFSCLIENT
-
-# Interrupt controller
-device gic
-
-# Pseudo devices
-device loop
-device random
-device pty
-device md
-device gpio
-
-# ATA controllers
-device ahci# AHCI-compatible SATA controllers
-device ata # Legacy ATA/SATA controllers
-optionsATA_STATIC_ID   # Static device numbering
-
-# ATA/SCSI peripherals
-device scbus   # SCSI bus (required for ATA/SCSI)
-device ch  # SCSI media changers
-device da  # Direct Access (disks)
-device sa  # Sequential Access (tape etc)
-device cd  # CD
-device pass# Passthrough device (direct ATA/SCSI access)
-device ses # Enclosure Services (SES and SAF-TE)
-#devicectl # CAM Target Layer
-
-# Serial ports
-device uart
-
-# Ethernet
-device ether
-device mii
-device bpf
-optionsDEVICE_POLLING
-
-# USB ethernet support, requires miibus
-device miibus
-
-#FDT
-optionsFDT
-optionsFDT_DTB_STATIC
-makeoptionsFDT_DTS_FILE=annapurna-alpine.dts
+# Kernel configuration for Alpine Board.
+#
+# For more information on this file, please read the config(5) manual page,
+# and/or the handbook section on Kernel Configuration Files:
+#
+#
http://www.FreeBSD.org/doc/en_US.ISO8859-1/books/handbook/kernelconfig-config.html
+#
+# The handbook is also available locally in /usr/share/doc/handbook
+# if you've installed the doc distribution, otherwise always see the
+# FreeBSD World Wide Web server (http://www.FreeBSD.org/) for the
+# latest information.
+#
+# An exhaustive list of options and more detailed explanations of the
+# device lines is also present in the ../../conf/NOTES and NOTES files.
+# If you are in doubt as to the purpose or necessity of a line, check first
+# in NOTES.
+#
+# $FreeBSD$
+
+ident  ALPINE
+
+include"std.armv6"
+include"../annapurna/alpine/std.alpine"
+
+makeoptionsMODULES_OVERRIDE=""
+makeoptionsWERROR="-Werror"
+
+optionsHZ=100
+optionsSCHED_4BSD  # 4BSD scheduler
+optionsSMP # Enable multiple cores
+
+# Debugging
+makeoptionsDEBUG=-g#Build kernel with gdb(1) debug symbols
+optionsBREAK_TO_DEBUGGER
+optionsKDB
+optionsDDB #Enable the kernel debugger
+
+# NFS support
+optionsNFSCL   #Network Filesystem Client
+optionsNFSLOCKD#Network Lock Manager
+optionsNFS_ROOT#NFS usable as /, requires NFSCLIENT
+
+# Interrupt controller
+device gic
+
+# Pseudo devices
+device loop
+device random
+device pty
+device md
+device gpio
+
+# ATA controllers
+device ahci# A

svn commit: r283004 - stable/10/sys/kern

2015-05-16 Thread Konstantin Belousov
Author: kib
Date: Sat May 16 09:13:56 2015
New Revision: 283004
URL: https://svnweb.freebsd.org/changeset/base/283004

Log:
  MFC r282679:
  Do not return from thread_single(SINGLE_BOUNDARY) until all stopped
  thread are guarenteed to be removed from the processors.

Modified:
  stable/10/sys/kern/kern_thread.c
Directory Properties:
  stable/10/   (props changed)

Modified: stable/10/sys/kern/kern_thread.c
==
--- stable/10/sys/kern/kern_thread.cSat May 16 08:12:00 2015
(r283003)
+++ stable/10/sys/kern/kern_thread.cSat May 16 09:13:56 2015
(r283004)
@@ -758,6 +758,29 @@ stopme:
PROC_LOCK(p);
PROC_SLOCK(p);
}
+   } else if (mode == SINGLE_BOUNDARY) {
+   /*
+* Wait until all suspended threads are removed from
+* the processors.  The thread_suspend_check()
+* increments p_boundary_count while it is still
+* running, which makes it possible for the execve()
+* to destroy vmspace while our other threads are
+* still using the address space.
+*
+* We lock the thread, which is only allowed to
+* succeed after context switch code finished using
+* the address space.
+*/
+   FOREACH_THREAD_IN_PROC(p, td2) {
+   if (td2 == td)
+   continue;
+   thread_lock(td2);
+   KASSERT((td2->td_flags & TDF_BOUNDARY) != 0,
+   ("td %p not on boundary", td2));
+   KASSERT(TD_IS_SUSPENDED(td2),
+   ("td %p is not suspended", td2));
+   thread_unlock(td2);
+   }
}
PROC_SUNLOCK(p);
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: r283003 - head/usr.sbin/syslogd

2015-05-16 Thread Xin LI
Author: delphij
Date: Sat May 16 08:12:00 2015
New Revision: 283003
URL: https://svnweb.freebsd.org/changeset/base/283003

Log:
  path.h is not needed here.

Modified:
  head/usr.sbin/syslogd/pathnames.h

Modified: head/usr.sbin/syslogd/pathnames.h
==
--- head/usr.sbin/syslogd/pathnames.h   Sat May 16 06:18:39 2015
(r283002)
+++ head/usr.sbin/syslogd/pathnames.h   Sat May 16 08:12:00 2015
(r283003)
@@ -30,8 +30,6 @@
  * $FreeBSD$
  */
 
-#include 
-
 #define_PATH_KLOG  "/dev/klog"
 #define_PATH_LOGCONF   "/etc/syslog.conf"
 #define_PATH_LOGPID"/var/run/syslog.pid"
___
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"