svn commit: r357110 - in head/sys: kern sys

2020-01-25 Thread Jason A. Harmening
Author: jah
Date: Sat Jan 25 08:57:26 2020
New Revision: 357110
URL: https://svnweb.freebsd.org/changeset/base/357110

Log:
  Implement cycle-detecting garbage collector for AF_UNIX sockets
  
  The existing AF_UNIX socket garbage collector destroys any socket
  which may potentially be in a cycle, as indicated by its file reference
  count being equal to its enqueue count. However, this can produce false
  positives for in-flight sockets which aren't part of a cycle but are
  part of one or more SCM_RIGHTS mssages and which have been closed
  on the sending side. If the garbage collector happens to run at
  exactly the wrong time, destruction of these sockets will render them
  unusable on the receiving side, such that no previously-written data
  may be read.
  
  This change rewrites the garbage collector to precisely detect cycles:
  
  1. The existing check of msgcount==f_count is still used to determine
 whether the socket is potentially in a cycle.
  2. The socket is now placed on a local "dead list", which is used to
 reduce iteration time (and therefore contention on the global
 unp_link_rwlock).
  3. The first pass through the dead list removes each potentially-dead
 socket's outgoing references from the graph of potentially-dead
 sockets, using a gc-specific copy of the original reference count.
  4. The second series of passes through the dead list removes from the
 list any socket whose remaining gc refcount is non-zero, as this
 indicates the socket is actually accessible outside of any possible
 cycle.  Iteration is repeated until no further sockets are removed
 from the dead list.
  5. Sockets remaining in the dead list are destroyed as before.
  
  PR:   227285
  Submitted by: jan.kokemuel...@gmail.com (prior version)
  Reviewed by:  markj
  Differential Revision:https://reviews.freebsd.org/D23142

Modified:
  head/sys/kern/uipc_usrreq.c
  head/sys/sys/unpcb.h

Modified: head/sys/kern/uipc_usrreq.c
==
--- head/sys/kern/uipc_usrreq.c Sat Jan 25 05:52:31 2020(r357109)
+++ head/sys/kern/uipc_usrreq.c Sat Jan 25 08:57:26 2020(r357110)
@@ -260,7 +260,7 @@ static struct mtx   unp_defers_lock;
 #defineUNP_LINK_LOCK_INIT()rw_init(&unp_link_rwlock,   
\
"unp_link_rwlock")
 
-#defineUNP_LINK_LOCK_ASSERT()  rw_assert(&unp_link_rwlock, \
+#defineUNP_LINK_LOCK_ASSERT()  rw_assert(&unp_link_rwlock, 
\
RA_LOCKED)
 #defineUNP_LINK_UNLOCK_ASSERT()rw_assert(&unp_link_rwlock, 
\
RA_UNLOCKED)
@@ -778,6 +778,8 @@ uipc_detach(struct socket *so)
 
UNP_LINK_WLOCK();
LIST_REMOVE(unp, unp_link);
+   if (unp->unp_gcflag & UNPGC_DEAD)
+   LIST_REMOVE(unp, unp_dead);
unp->unp_gencnt = ++unp_gencnt;
--unp_count;
UNP_LINK_WUNLOCK();
@@ -2481,50 +2483,61 @@ unp_externalize_fp(struct file *fp)
  * synchronization.
  */
 static int unp_marked;
-static int unp_unreachable;
 
 static void
-unp_accessable(struct filedescent **fdep, int fdcount)
+unp_remove_dead_ref(struct filedescent **fdep, int fdcount)
 {
struct unpcb *unp;
struct file *fp;
int i;
 
+   /*
+* This function can only be called from the gc task.
+*/
+   KASSERT(taskqueue_member(taskqueue_thread, curthread) != 0,
+   ("%s: not on gc callout", __func__));
+   UNP_LINK_LOCK_ASSERT();
+
for (i = 0; i < fdcount; i++) {
fp = fdep[i]->fde_file;
if ((unp = fptounp(fp)) == NULL)
continue;
-   if (unp->unp_gcflag & UNPGC_REF)
+   if ((unp->unp_gcflag & UNPGC_DEAD) == 0)
continue;
-   unp->unp_gcflag &= ~UNPGC_DEAD;
-   unp->unp_gcflag |= UNPGC_REF;
-   unp_marked++;
+   unp->unp_gcrefs--;
}
 }
 
 static void
-unp_gc_process(struct unpcb *unp)
+unp_restore_undead_ref(struct filedescent **fdep, int fdcount)
 {
-   struct socket *so, *soa;
+   struct unpcb *unp;
struct file *fp;
+   int i;
 
-   /* Already processed. */
-   if (unp->unp_gcflag & UNPGC_SCANNED)
-   return;
-   fp = unp->unp_file;
-
/*
-* Check for a socket potentially in a cycle.  It must be in a
-* queue as indicated by msgcount, and this must equal the file
-* reference count.  Note that when msgcount is 0 the file is NULL.
+* This function can only be called from the gc task.
 */
-   if ((unp->unp_gcflag & UNPGC_REF) == 0 && fp &&
-   unp->unp_msgcount != 0 && fp->f_count == unp->unp_msgcount) {
-   unp->unp_gcflag |= UNPGC_DEAD;
-   unp_unreachab

svn commit: r357111 - stable/12/sys/net

2020-01-25 Thread Eugene Grosbein
Author: eugen
Date: Sat Jan 25 09:12:20 2020
New Revision: 357111
URL: https://svnweb.freebsd.org/changeset/base/357111

Log:
  MFC r356863: ifa_maintain_loopback_route: adjust debugging output
  
  Correction after r333476:
  
  - write this as LOG_DEBUG again instead of LOG_INFO;
  - get back function name into the message;
  - error may be ESRCH if an address is removed in process (by carp f.e.),
not only ENOENT;
  - expression complexity grows, so try making it more readable.

Modified:
  stable/12/sys/net/if.c
Directory Properties:
  stable/12/   (props changed)

Modified: stable/12/sys/net/if.c
==
--- stable/12/sys/net/if.c  Sat Jan 25 08:57:26 2020(r357110)
+++ stable/12/sys/net/if.c  Sat Jan 25 09:12:20 2020(r357111)
@@ -1920,10 +1920,13 @@ ifa_maintain_loopback_route(int cmd, const char *otype
 
error = rtrequest1_fib(cmd, &info, NULL, ifp->if_fib);
 
-   if (error != 0 &&
-   !(cmd == RTM_ADD && error == EEXIST) &&
-   !(cmd == RTM_DELETE && error == ENOENT))
-   if_printf(ifp, "%s failed: %d\n", otype, error);
+   if (error == 0 ||
+   (cmd == RTM_ADD && error == EEXIST) ||
+   (cmd == RTM_DELETE && (error == ENOENT || error == ESRCH)))
+   return (error);
+
+   log(LOG_DEBUG, "%s: %s failed for interface %s: %u\n",
+   __func__, otype, if_name(ifp), error);
 
return (error);
 }
___
svn-src-all@freebsd.org mailing list
https://lists.freebsd.org/mailman/listinfo/svn-src-all
To unsubscribe, send any mail to "svn-src-all-unsubscr...@freebsd.org"


svn commit: r357112 - stable/11/sys/net

2020-01-25 Thread Eugene Grosbein
Author: eugen
Date: Sat Jan 25 09:22:28 2020
New Revision: 357112
URL: https://svnweb.freebsd.org/changeset/base/357112

Log:
  MFC r356863: ifa_maintain_loopback_route: adjust debugging output

Modified:
  stable/11/sys/net/if.c
Directory Properties:
  stable/11/   (props changed)

Modified: stable/11/sys/net/if.c
==
--- stable/11/sys/net/if.c  Sat Jan 25 09:12:20 2020(r357111)
+++ stable/11/sys/net/if.c  Sat Jan 25 09:22:28 2020(r357112)
@@ -1831,9 +1831,13 @@ ifa_maintain_loopback_route(int cmd, const char *otype
 
error = rtrequest1_fib(cmd, &info, NULL, ifp->if_fib);
 
-   if (error != 0)
-   log(LOG_DEBUG, "%s: %s failed for interface %s: %u\n",
-   __func__, otype, if_name(ifp), error);
+   if (error == 0 ||
+   (cmd == RTM_ADD && error == EEXIST) ||
+   (cmd == RTM_DELETE && (error == ENOENT || error == ESRCH)))
+   return (error);
+
+   log(LOG_DEBUG, "%s: %s failed for interface %s: %u\n",
+   __func__, otype, if_name(ifp), error);
 
return (error);
 }
___
svn-src-all@freebsd.org mailing list
https://lists.freebsd.org/mailman/listinfo/svn-src-all
To unsubscribe, send any mail to "svn-src-all-unsubscr...@freebsd.org"


svn commit: r357113 - head/tests/sys/net/routing

2020-01-25 Thread Kristof Provost
Author: kp
Date: Sat Jan 25 10:51:51 2020
New Revision: 357113
URL: https://svnweb.freebsd.org/changeset/base/357113

Log:
  tests: Routing tests overwrote net tests
  
  The routing subdirectory installed into the same directory as the test tests,
  which caused them to overwrite the net Kyuafile. As a result these tests were
  not executed.
  
  X-MFC-With:   r356146

Modified:
  head/tests/sys/net/routing/Makefile

Modified: head/tests/sys/net/routing/Makefile
==
--- head/tests/sys/net/routing/Makefile Sat Jan 25 09:22:28 2020
(r357112)
+++ head/tests/sys/net/routing/Makefile Sat Jan 25 10:51:51 2020
(r357113)
@@ -2,7 +2,7 @@
 
 PACKAGE=   tests
 
-TESTSDIR=   ${TESTSBASE}/sys/net
+TESTSDIR=   ${TESTSBASE}/sys/net/routing
 
 ATF_TESTS_C += test_rtsock_l3
 ATF_TESTS_C += test_rtsock_lladdr
___
svn-src-all@freebsd.org mailing list
https://lists.freebsd.org/mailman/listinfo/svn-src-all
To unsubscribe, send any mail to "svn-src-all-unsubscr...@freebsd.org"


svn commit: r357114 - in head/sys/netinet: . tcp_stacks

2020-01-25 Thread Michael Tuexen
Author: tuexen
Date: Sat Jan 25 13:11:14 2020
New Revision: 357114
URL: https://svnweb.freebsd.org/changeset/base/357114

Log:
  As a TCP client only enable ECN when the corresponding sysctl variable
  indicates that ECN should be negotiated for the client side.
  
  Submitted by: Richard Scheffenegger
  Reviewed by:  rgrimes@, tuexen@
  MFC after:1 week
  Differential Revision:https://reviews.freebsd.org/D23228

Modified:
  head/sys/netinet/tcp_input.c
  head/sys/netinet/tcp_stacks/rack.c

Modified: head/sys/netinet/tcp_input.c
==
--- head/sys/netinet/tcp_input.cSat Jan 25 10:51:51 2020
(r357113)
+++ head/sys/netinet/tcp_input.cSat Jan 25 13:11:14 2020
(r357114)
@@ -1979,7 +1979,7 @@ tcp_do_segment(struct mbuf *m, struct tcphdr *th, stru
tp->t_flags |= TF_ACKNOW;
 
if (((thflags & (TH_CWR | TH_ECE)) == TH_ECE) &&
-   V_tcp_do_ecn) {
+   (V_tcp_do_ecn == 1)) {
tp->t_flags2 |= TF2_ECN_PERMIT;
TCPSTAT_INC(tcps_ecn_shs);
}

Modified: head/sys/netinet/tcp_stacks/rack.c
==
--- head/sys/netinet/tcp_stacks/rack.c  Sat Jan 25 10:51:51 2020
(r357113)
+++ head/sys/netinet/tcp_stacks/rack.c  Sat Jan 25 13:11:14 2020
(r357114)
@@ -6296,7 +6296,7 @@ rack_do_syn_sent(struct mbuf *m, struct tcphdr *th, st
}
 
if (((thflags & (TH_CWR | TH_ECE)) == TH_ECE) &&
-   V_tcp_do_ecn) {
+   (V_tcp_do_ecn == 1)) {
tp->t_flags2 |= TF2_ECN_PERMIT;
TCPSTAT_INC(tcps_ecn_shs);
}
___
svn-src-all@freebsd.org mailing list
https://lists.freebsd.org/mailman/listinfo/svn-src-all
To unsubscribe, send any mail to "svn-src-all-unsubscr...@freebsd.org"


svn commit: r357115 - in head/sys/netinet: . tcp_stacks

2020-01-25 Thread Michael Tuexen
Author: tuexen
Date: Sat Jan 25 13:34:29 2020
New Revision: 357115
URL: https://svnweb.freebsd.org/changeset/base/357115

Log:
  Don't set the ECT codepoint on retransmitted packets during SACK loss
  recovery. This is required by RFC 3168.
  
  Submitted by: Richard Scheffenegger
  Reviewed by:  rgrimes@, tuexen@, Cheng Cui
  MFC after:1 week
  Differential Revision:https://reviews.freebsd.org/D23118

Modified:
  head/sys/netinet/tcp_output.c
  head/sys/netinet/tcp_stacks/rack.c

Modified: head/sys/netinet/tcp_output.c
==
--- head/sys/netinet/tcp_output.c   Sat Jan 25 13:11:14 2020
(r357114)
+++ head/sys/netinet/tcp_output.c   Sat Jan 25 13:34:29 2020
(r357115)
@@ -1162,6 +1162,7 @@ send:
 * Ignore pure ack packets, retransmissions and window probes.
 */
if (len > 0 && SEQ_GEQ(tp->snd_nxt, tp->snd_max) &&
+   (sack_rxmit == 0) &&
!((tp->t_flags & TF_FORCEDATA) && len == 1)) {
 #ifdef INET6
if (isipv6)

Modified: head/sys/netinet/tcp_stacks/rack.c
==
--- head/sys/netinet/tcp_stacks/rack.c  Sat Jan 25 13:11:14 2020
(r357114)
+++ head/sys/netinet/tcp_stacks/rack.c  Sat Jan 25 13:34:29 2020
(r357115)
@@ -9477,6 +9477,7 @@ send:
 * retransmissions and window probes.
 */
if (len > 0 && SEQ_GEQ(tp->snd_nxt, tp->snd_max) &&
+   (sack_rxmit == 0) &&
!((tp->t_flags & TF_FORCEDATA) && len == 1)) {
 #ifdef INET6
if (isipv6)
___
svn-src-all@freebsd.org mailing list
https://lists.freebsd.org/mailman/listinfo/svn-src-all
To unsubscribe, send any mail to "svn-src-all-unsubscr...@freebsd.org"


svn commit: r357116 - in head/sys/netinet: . cc tcp_stacks

2020-01-25 Thread Michael Tuexen
Author: tuexen
Date: Sat Jan 25 13:45:10 2020
New Revision: 357116
URL: https://svnweb.freebsd.org/changeset/base/357116

Log:
  Sending CWR after an RTO is according to RFC 3168 generally required
  and not only for the DCTCP congestion control.
  
  Submitted by: Richard Scheffenegger
  Reviewed by:  rgrimes, tuexen@, Cheng Cui
  MFC after:1 week
  Differential Revision:https://reviews.freebsd.org/D23119

Modified:
  head/sys/netinet/cc/cc_dctcp.c
  head/sys/netinet/tcp_input.c
  head/sys/netinet/tcp_stacks/rack.c

Modified: head/sys/netinet/cc/cc_dctcp.c
==
--- head/sys/netinet/cc/cc_dctcp.c  Sat Jan 25 13:34:29 2020
(r357115)
+++ head/sys/netinet/cc/cc_dctcp.c  Sat Jan 25 13:45:10 2020
(r357116)
@@ -284,7 +284,6 @@ dctcp_cong_signal(struct cc_var *ccv, uint32_t type)
dctcp_data->ece_curr = 1;
break;
case CC_RTO:
-   CCV(ccv, t_flags2) |= TF2_ECN_SND_CWR;
dctcp_update_alpha(ccv);
dctcp_data->save_sndnxt += CCV(ccv, t_maxseg);
dctcp_data->num_cong_events++;

Modified: head/sys/netinet/tcp_input.c
==
--- head/sys/netinet/tcp_input.cSat Jan 25 13:34:29 2020
(r357115)
+++ head/sys/netinet/tcp_input.cSat Jan 25 13:45:10 2020
(r357116)
@@ -460,6 +460,8 @@ cc_cong_signal(struct tcpcb *tp, struct tcphdr *th, ui
tp->snd_ssthresh = max(2, min(tp->snd_wnd, tp->snd_cwnd) / 2 /
maxseg) * maxseg;
tp->snd_cwnd = maxseg;
+   if (tp->t_flags2 & TF2_ECN_PERMIT)
+   tp->t_flags2 |= TF2_ECN_SND_CWR;
break;
case CC_RTO_ERR:
TCPSTAT_INC(tcps_sndrexmitbad);

Modified: head/sys/netinet/tcp_stacks/rack.c
==
--- head/sys/netinet/tcp_stacks/rack.c  Sat Jan 25 13:34:29 2020
(r357115)
+++ head/sys/netinet/tcp_stacks/rack.c  Sat Jan 25 13:45:10 2020
(r357116)
@@ -1813,6 +1813,8 @@ rack_cong_signal(struct tcpcb *tp, struct tcphdr *th, 
tp->snd_ssthresh = max(2, min(tp->snd_wnd, tp->snd_cwnd) / 2 /
ctf_fixed_maxseg(tp)) * ctf_fixed_maxseg(tp);
tp->snd_cwnd = ctf_fixed_maxseg(tp);
+   if (tp->t_flags2 & TF2_ECN_PERMIT)
+   tp->t_flags2 |= TF2_ECN_SND_CWR;
break;
case CC_RTO_ERR:
TCPSTAT_INC(tcps_sndrexmitbad);
___
svn-src-all@freebsd.org mailing list
https://lists.freebsd.org/mailman/listinfo/svn-src-all
To unsubscribe, send any mail to "svn-src-all-unsubscr...@freebsd.org"


Re: svn commit: r357090 - head/sys/dev/re

2020-01-25 Thread Mark Johnston
On Fri, Jan 24, 2020 at 05:24:03PM +, Gleb Smirnoff wrote:
> Author: glebius
> Date: Fri Jan 24 17:24:02 2020
> New Revision: 357090
> URL: https://svnweb.freebsd.org/changeset/base/357090
> 
> Log:
>   re(4) uses taskqueue to process input packets.  Enter network epoch
>   in there.

ena(4) and the virtio network driver are similarly broken.

> Modified:
>   head/sys/dev/re/if_re.c
> 
> Modified: head/sys/dev/re/if_re.c
> ==
> --- head/sys/dev/re/if_re.c   Fri Jan 24 17:15:31 2020(r357089)
> +++ head/sys/dev/re/if_re.c   Fri Jan 24 17:24:02 2020(r357090)
> @@ -2576,6 +2576,7 @@ re_intr(void *arg)
>  static void
>  re_int_task(void *arg, int npending)
>  {
> + struct epoch_trackeret;
>   struct rl_softc *sc;
>   struct ifnet*ifp;
>   u_int16_t   status;
> @@ -2602,8 +2603,11 @@ re_int_task(void *arg, int npending)
>   }
>  #endif
>  
> - if (status & (RL_ISR_RX_OK|RL_ISR_RX_ERR|RL_ISR_FIFO_OFLOW))
> + if (status & (RL_ISR_RX_OK|RL_ISR_RX_ERR|RL_ISR_FIFO_OFLOW)) {
> + NET_EPOCH_ENTER(et);
>   rval = re_rxeof(sc, NULL);
> + NET_EPOCH_EXIT(et);
> + }
>  
>   /*
>* Some chips will ignore a second TX request issued
___
svn-src-all@freebsd.org mailing list
https://lists.freebsd.org/mailman/listinfo/svn-src-all
To unsubscribe, send any mail to "svn-src-all-unsubscr...@freebsd.org"


svn commit: r357124 - vendor/Juniper/libxo/1.4.0

2020-01-25 Thread Phil Shafer
Author: phil
Date: Sat Jan 25 21:09:27 2020
New Revision: 357124
URL: https://svnweb.freebsd.org/changeset/base/357124

Log:
  Tag libxo 1.4.0

Added:
 - copied from r357123, vendor/Juniper/libxo/dist/
Directory Properties:
  vendor/Juniper/libxo/1.4.0/   (props changed)
___
svn-src-all@freebsd.org mailing list
https://lists.freebsd.org/mailman/listinfo/svn-src-all
To unsubscribe, send any mail to "svn-src-all-unsubscr...@freebsd.org"


svn commit: r357123 - in vendor/Juniper/libxo/dist: . doc encoder/csv libxo tests/core tests/core/saved

2020-01-25 Thread Phil Shafer
Author: phil
Date: Sat Jan 25 21:09:12 2020
New Revision: 357123
URL: https://svnweb.freebsd.org/changeset/base/357123

Log:
  Import libxo 1.4.0

Modified:
  vendor/Juniper/libxo/dist/configure.ac
  vendor/Juniper/libxo/dist/doc/api.rst
  vendor/Juniper/libxo/dist/doc/encoders.rst
  vendor/Juniper/libxo/dist/doc/options.rst
  vendor/Juniper/libxo/dist/encoder/csv/enc_csv.c
  vendor/Juniper/libxo/dist/libxo/libxo.c
  vendor/Juniper/libxo/dist/libxo/xo.h
  vendor/Juniper/libxo/dist/libxo/xo_encoder.c
  vendor/Juniper/libxo/dist/libxo/xo_encoder.h
  vendor/Juniper/libxo/dist/tests/core/Makefile.am
  vendor/Juniper/libxo/dist/tests/core/saved/test_02.H.out
  vendor/Juniper/libxo/dist/tests/core/saved/test_02.HIPx.out
  vendor/Juniper/libxo/dist/tests/core/saved/test_02.HP.out
  vendor/Juniper/libxo/dist/tests/core/saved/test_02.J.out
  vendor/Juniper/libxo/dist/tests/core/saved/test_02.JP.out
  vendor/Juniper/libxo/dist/tests/core/saved/test_02.T.err
  vendor/Juniper/libxo/dist/tests/core/saved/test_02.X.out
  vendor/Juniper/libxo/dist/tests/core/saved/test_02.XP.out
  vendor/Juniper/libxo/dist/tests/core/test_02.c
  vendor/Juniper/libxo/dist/tests/core/test_12.c

Modified: vendor/Juniper/libxo/dist/configure.ac
==
--- vendor/Juniper/libxo/dist/configure.ac  Sat Jan 25 16:46:39 2020
(r357122)
+++ vendor/Juniper/libxo/dist/configure.ac  Sat Jan 25 21:09:12 2020
(r357123)
@@ -12,7 +12,7 @@
 #
 
 AC_PREREQ(2.2)
-AC_INIT([libxo], [1.3.1], [p...@juniper.net])
+AC_INIT([libxo], [1.4.0], [p...@juniper.net])
 AM_INIT_AUTOMAKE([-Wall -Werror foreign -Wno-portability])
 
 # Support silent build rules.  Requires at least automake-1.11.

Modified: vendor/Juniper/libxo/dist/doc/api.rst
==
--- vendor/Juniper/libxo/dist/doc/api.rst   Sat Jan 25 16:46:39 2020
(r357122)
+++ vendor/Juniper/libxo/dist/doc/api.rst   Sat Jan 25 21:09:12 2020
(r357123)
@@ -1204,6 +1204,11 @@ message associated with either *errno* or the *code* p
 xo_err(1, "cannot open file '%s'", filename);
 
 .. index:: xo_error
+.. index:: xo_error_h
+.. index:: xo_error_hv
+.. index:: xo_errorn
+.. index:: xo_errorn_h
+.. index:: xo_errorn_hv
 
 xo_error
 
@@ -1214,6 +1219,50 @@ xo_error
   :type fmt: const char *
   :returns: void
 
+.. c:function:: void xo_error_h (xo_handle_t *xop, const char *fmt, ...)
+
+  :param xop: libxo handle pointer
+  :type xop: xo_handle_t *
+  :param fmt: Format string
+  :type fmt: const char *
+  :returns: void
+
+.. c:function:: void xo_error_hv (xo_handle_t *xop, const char *fmt, va_list 
vap)
+
+  :param xop: libxo handle pointer
+  :type xop: xo_handle_t *
+  :param fmt: Format string
+  :type fmt: const char *
+  :param vap: variadic arguments
+  :type xop: va_list
+  :returns: void
+
+.. c:function:: void xo_errorn (const char *fmt, ...)
+
+  :param fmt: Format string
+  :type fmt: const char *
+  :returns: void
+
+.. c:function:: void xo_errorn_h (xo_handle_t *xop, const char *fmt, ...)
+
+  :param xop: libxo handle pointer
+  :type xop: xo_handle_t *
+  :param fmt: Format string
+  :type fmt: const char *
+  :returns: void
+
+.. c:function:: void xo_errorn_hv (xo_handle_t *xop, int need_newline, const 
char *fmt, va_list vap)
+
+  :param xop: libxo handle pointer
+  :type xop: xo_handle_t *
+  :param need_newline: boolean indicating need for trailing newline
+  :type need_newline: int
+  :param fmt: Format string
+  :type fmt: const char *
+  :param vap: variadic arguments
+  :type xop: va_list
+  :returns: void
+
   The `xo_error` function can be used for generic errors that should
   be reported over the handle, rather than to stderr.  The `xo_error`
   function behaves like `xo_err` for TEXT and HTML output styles, but
@@ -1225,6 +1274,16 @@ xo_error
 Does not compute
 JSON::
 "error": { "message": "Does not compute" }
+
+  The `xo_error_h` and `xo_error_hv` add a handle object and a
+  variadic-ized parameter to the signature, respectively.
+
+  The `xo_errorn` function supplies a newline at the end the error
+  message if the format string does not include one.  The
+  `xo_errorn_h` and `xo_errorn_hv` functions add a handle object and
+  a variadic-ized parameter to the signature, respectively.  The
+  `xo_errorn_hv` function also adds a boolean to indicate the need for
+  a trailing newline.
 
 .. index:: xo_no_setlocale
 .. index:: Locale

Modified: vendor/Juniper/libxo/dist/doc/encoders.rst
==
--- vendor/Juniper/libxo/dist/doc/encoders.rst  Sat Jan 25 16:46:39 2020
(r357122)
+++ vendor/Juniper/libxo/dist/doc/encoders.rst  Sat Jan 25 21:09:12 2020
(r357123)
@@ -26,12 +26,13 @@ example uses the "cbor" encoder, saving the output int
 df --libxo encoder=cbor > df-output.cbor
 
 Encoders

svn commit: r357125 - in head: contrib/libxo contrib/libxo/doc contrib/libxo/encoder/csv contrib/libxo/libxo contrib/libxo/tests/core contrib/libxo/tests/core/saved lib/libxo lib/libxo/libxo usr.bi...

2020-01-25 Thread Phil Shafer
Author: phil
Date: Sat Jan 25 21:16:45 2020
New Revision: 357125
URL: https://svnweb.freebsd.org/changeset/base/357125

Log:
  Import libxo-1.4.0:
  
  - Two changes to encoder options:
  encoder options may use plus or colon, but only one
  encoder names can be specified as "@name"
  This results in the syntax:
  
  df --libxo @csv:no-header:leafs=name.available-blocks /
  
  - If xo_set_program is called before xo_parse_args, honor the requested 
value
  - add xo_errorn* function; repair newline-adding-on-xo_error bug
  - test programs now use fixed name, since linux libtool prefixs "lt-"
  - Fix "horse butt" comment in source code
  - update test cases
  
  PR:   242686

Modified:
  head/contrib/libxo/configure.ac
  head/contrib/libxo/doc/api.rst
  head/contrib/libxo/doc/encoders.rst
  head/contrib/libxo/doc/options.rst
  head/contrib/libxo/encoder/csv/enc_csv.c
  head/contrib/libxo/libxo/libxo.c
  head/contrib/libxo/libxo/xo.h
  head/contrib/libxo/libxo/xo_encoder.c
  head/contrib/libxo/libxo/xo_encoder.h
  head/contrib/libxo/tests/core/Makefile.am
  head/contrib/libxo/tests/core/saved/test_02.H.out
  head/contrib/libxo/tests/core/saved/test_02.HIPx.out
  head/contrib/libxo/tests/core/saved/test_02.HP.out
  head/contrib/libxo/tests/core/saved/test_02.J.out
  head/contrib/libxo/tests/core/saved/test_02.JP.out
  head/contrib/libxo/tests/core/saved/test_02.T.err
  head/contrib/libxo/tests/core/saved/test_02.X.out
  head/contrib/libxo/tests/core/saved/test_02.XP.out
  head/contrib/libxo/tests/core/test_02.c
  head/contrib/libxo/tests/core/test_12.c
  head/lib/libxo/add.man
  head/lib/libxo/libxo/xo_config.h
  head/usr.bin/xohtml/xohtml.sh
Directory Properties:
  head/contrib/libxo/   (props changed)

Modified: head/contrib/libxo/configure.ac
==
--- head/contrib/libxo/configure.ac Sat Jan 25 21:09:27 2020
(r357124)
+++ head/contrib/libxo/configure.ac Sat Jan 25 21:16:45 2020
(r357125)
@@ -12,7 +12,7 @@
 #
 
 AC_PREREQ(2.2)
-AC_INIT([libxo], [1.3.1], [p...@juniper.net])
+AC_INIT([libxo], [1.4.0], [p...@juniper.net])
 AM_INIT_AUTOMAKE([-Wall -Werror foreign -Wno-portability])
 
 # Support silent build rules.  Requires at least automake-1.11.

Modified: head/contrib/libxo/doc/api.rst
==
--- head/contrib/libxo/doc/api.rst  Sat Jan 25 21:09:27 2020
(r357124)
+++ head/contrib/libxo/doc/api.rst  Sat Jan 25 21:16:45 2020
(r357125)
@@ -1204,6 +1204,11 @@ message associated with either *errno* or the *code* p
 xo_err(1, "cannot open file '%s'", filename);
 
 .. index:: xo_error
+.. index:: xo_error_h
+.. index:: xo_error_hv
+.. index:: xo_errorn
+.. index:: xo_errorn_h
+.. index:: xo_errorn_hv
 
 xo_error
 
@@ -1214,6 +1219,50 @@ xo_error
   :type fmt: const char *
   :returns: void
 
+.. c:function:: void xo_error_h (xo_handle_t *xop, const char *fmt, ...)
+
+  :param xop: libxo handle pointer
+  :type xop: xo_handle_t *
+  :param fmt: Format string
+  :type fmt: const char *
+  :returns: void
+
+.. c:function:: void xo_error_hv (xo_handle_t *xop, const char *fmt, va_list 
vap)
+
+  :param xop: libxo handle pointer
+  :type xop: xo_handle_t *
+  :param fmt: Format string
+  :type fmt: const char *
+  :param vap: variadic arguments
+  :type xop: va_list
+  :returns: void
+
+.. c:function:: void xo_errorn (const char *fmt, ...)
+
+  :param fmt: Format string
+  :type fmt: const char *
+  :returns: void
+
+.. c:function:: void xo_errorn_h (xo_handle_t *xop, const char *fmt, ...)
+
+  :param xop: libxo handle pointer
+  :type xop: xo_handle_t *
+  :param fmt: Format string
+  :type fmt: const char *
+  :returns: void
+
+.. c:function:: void xo_errorn_hv (xo_handle_t *xop, int need_newline, const 
char *fmt, va_list vap)
+
+  :param xop: libxo handle pointer
+  :type xop: xo_handle_t *
+  :param need_newline: boolean indicating need for trailing newline
+  :type need_newline: int
+  :param fmt: Format string
+  :type fmt: const char *
+  :param vap: variadic arguments
+  :type xop: va_list
+  :returns: void
+
   The `xo_error` function can be used for generic errors that should
   be reported over the handle, rather than to stderr.  The `xo_error`
   function behaves like `xo_err` for TEXT and HTML output styles, but
@@ -1225,6 +1274,16 @@ xo_error
 Does not compute
 JSON::
 "error": { "message": "Does not compute" }
+
+  The `xo_error_h` and `xo_error_hv` add a handle object and a
+  variadic-ized parameter to the signature, respectively.
+
+  The `xo_errorn` function supplies a newline at the end the error
+  message if the format string does not include one.  The
+  `xo_errorn_h` and `xo_errorn_hv` functions add a handle object and
+  a variadic-ized parameter to the signature, respectively.  The
+  `xo_errorn_hv` funct

svn commit: r357126 - head/tests/sys/netinet

2020-01-25 Thread Li-Wen Hsu
Author: lwhsu
Date: Sat Jan 25 23:22:08 2020
New Revision: 357126
URL: https://svnweb.freebsd.org/changeset/base/357126

Log:
  Specify PACKAGE to install tests files
  
  MFC after:3 weeks
  MFC with: r356984
  Sponsored by: The FreeBSD Foundation

Modified:
  head/tests/sys/netinet/Makefile

Modified: head/tests/sys/netinet/Makefile
==
--- head/tests/sys/netinet/Makefile Sat Jan 25 21:16:45 2020
(r357125)
+++ head/tests/sys/netinet/Makefile Sat Jan 25 23:22:08 2020
(r357126)
@@ -1,5 +1,7 @@
 # $FreeBSD$
 
+PACKAGE=   tests
+
 TESTSDIR=  ${TESTSBASE}/sys/netinet
 BINDIR=${TESTSDIR}
 
___
svn-src-all@freebsd.org mailing list
https://lists.freebsd.org/mailman/listinfo/svn-src-all
To unsubscribe, send any mail to "svn-src-all-unsubscr...@freebsd.org"


svn commit: r357128 - head/sys/kern

2020-01-25 Thread Mateusz Guzik
Author: mjg
Date: Sun Jan 26 00:34:57 2020
New Revision: 357128
URL: https://svnweb.freebsd.org/changeset/base/357128

Log:
  vfs: predict vn_lock failure as unlikely in vget

Modified:
  head/sys/kern/vfs_subr.c

Modified: head/sys/kern/vfs_subr.c
==
--- head/sys/kern/vfs_subr.cSun Jan 26 00:21:30 2020(r357127)
+++ head/sys/kern/vfs_subr.cSun Jan 26 00:34:57 2020(r357128)
@@ -2911,7 +2911,8 @@ vget_finish(struct vnode *vp, int flags, enum vgetstat
__func__));
}
 
-   if ((error = vn_lock(vp, flags)) != 0) {
+   error = vn_lock(vp, flags);
+   if (__predict_false(error != 0)) {
if (vs == VGET_USECOUNT)
vrele(vp);
else
___
svn-src-all@freebsd.org mailing list
https://lists.freebsd.org/mailman/listinfo/svn-src-all
To unsubscribe, send any mail to "svn-src-all-unsubscr...@freebsd.org"


svn commit: r357129 - in head/sys/ufs: ffs ufs

2020-01-25 Thread Mateusz Guzik
Author: mjg
Date: Sun Jan 26 00:38:06 2020
New Revision: 357129
URL: https://svnweb.freebsd.org/changeset/base/357129

Log:
  ufs: add vgone calls for unconstructed vnodes in the error path
  
  This mostly eliminates the requirement that vput never unlocks the vnode
  before calling VOP_INACTIVE. Note it may still be present for other
  filesystems.
  
  See r356126 for an example bug.
  
  Note vput stopped doing early unlock in r357070 thus this change does
  not affect correctness as it is.
  
  Reviewed by:  kib
  Differential Revision:https://reviews.freebsd.org/D23215

Modified:
  head/sys/ufs/ffs/ffs_vfsops.c
  head/sys/ufs/ufs/ufs_vnops.c

Modified: head/sys/ufs/ffs/ffs_vfsops.c
==
--- head/sys/ufs/ffs/ffs_vfsops.c   Sun Jan 26 00:34:57 2020
(r357128)
+++ head/sys/ufs/ffs/ffs_vfsops.c   Sun Jan 26 00:38:06 2020
(r357129)
@@ -1787,6 +1787,7 @@ ffs_vgetf(mp, ino, flags, vpp, ffs_flags)
 * still zero, it will be unlinked and returned to the free
 * list by vput().
 */
+   vgone(vp);
vput(vp);
*vpp = NULL;
return (error);
@@ -1797,6 +1798,7 @@ ffs_vgetf(mp, ino, flags, vpp, ffs_flags)
ip->i_din2 = uma_zalloc(uma_ufs2, M_WAITOK);
if ((error = ffs_load_inode(bp, ip, fs, ino)) != 0) {
bqrelse(bp);
+   vgone(vp);
vput(vp);
*vpp = NULL;
return (error);
@@ -1814,6 +1816,7 @@ ffs_vgetf(mp, ino, flags, vpp, ffs_flags)
error = ufs_vinit(mp, I_IS_UFS1(ip) ? &ffs_fifoops1 : &ffs_fifoops2,
&vp);
if (error) {
+   vgone(vp);
vput(vp);
*vpp = NULL;
return (error);
@@ -1849,6 +1852,7 @@ ffs_vgetf(mp, ino, flags, vpp, ffs_flags)
error = mac_vnode_associate_extattr(mp, vp);
if (error) {
/* ufs_inactive will release ip->i_devvp ref. */
+   vgone(vp);
vput(vp);
*vpp = NULL;
return (error);

Modified: head/sys/ufs/ufs/ufs_vnops.c
==
--- head/sys/ufs/ufs/ufs_vnops.cSun Jan 26 00:34:57 2020
(r357128)
+++ head/sys/ufs/ufs/ufs_vnops.cSun Jan 26 00:38:06 2020
(r357129)
@@ -1839,6 +1839,7 @@ ufs_mkdir(ap)
if (DOINGSOFTDEP(tvp))
softdep_revert_link(dp, ip);
UFS_VFREE(tvp, ip->i_number, dmode);
+   vgone(tvp);
vput(tvp);
return (error);
}
@@ -1853,6 +1854,7 @@ ufs_mkdir(ap)
if (DOINGSOFTDEP(tvp))
softdep_revert_link(dp, ip);
UFS_VFREE(tvp, ip->i_number, dmode);
+   vgone(tvp);
vput(tvp);
return (error);
}
@@ -1980,7 +1982,7 @@ bad:
UFS_INODE_SET_FLAG(ip, IN_CHANGE);
if (DOINGSOFTDEP(tvp))
softdep_revert_mkdir(dp, ip);
-
+   vgone(tvp);
vput(tvp);
}
 out:
@@ -2607,6 +2609,7 @@ ufs_makeinode(mode, dvp, vpp, cnp, callfunc)
if (DOINGSOFTDEP(tvp))
softdep_revert_link(pdir, ip);
UFS_VFREE(tvp, ip->i_number, mode);
+   vgone(tvp);
vput(tvp);
return (error);
}
@@ -2621,6 +2624,7 @@ ufs_makeinode(mode, dvp, vpp, cnp, callfunc)
if (DOINGSOFTDEP(tvp))
softdep_revert_link(pdir, ip);
UFS_VFREE(tvp, ip->i_number, mode);
+   vgone(tvp);
vput(tvp);
return (error);
}
@@ -2691,6 +2695,7 @@ bad:
UFS_INODE_SET_FLAG(ip, IN_CHANGE);
if (DOINGSOFTDEP(tvp))
softdep_revert_create(VTOI(dvp), ip);
+   vgone(tvp);
vput(tvp);
return (error);
 }
___
svn-src-all@freebsd.org mailing list
https://lists.freebsd.org/mailman/listinfo/svn-src-all
To unsubscribe, send any mail to "svn-src-all-unsubscr...@freebsd.org"


svn commit: r357130 - head/sys/kern

2020-01-25 Thread Mateusz Guzik
Author: mjg
Date: Sun Jan 26 00:40:27 2020
New Revision: 357130
URL: https://svnweb.freebsd.org/changeset/base/357130

Log:
  vfs: fix freevnodes count update race against preemption
  
  vdbatch_process leaves the critical section too early, openign a time
  window where another thread can get scheduled and modify vd->freevnodes.
  Once it the preempted thread gets back it overrides the value with 0.
  
  Just move critical_exit to the end of the function.

Modified:
  head/sys/kern/vfs_subr.c

Modified: head/sys/kern/vfs_subr.c
==
--- head/sys/kern/vfs_subr.cSun Jan 26 00:38:06 2020(r357129)
+++ head/sys/kern/vfs_subr.cSun Jan 26 00:40:27 2020(r357130)
@@ -3324,10 +3324,10 @@ vdbatch_process(struct vdbatch *vd)
vp->v_dbatchcpu = NOCPU;
}
mtx_unlock(&vnode_list_mtx);
-   critical_exit();
vd->freevnodes = 0;
bzero(vd->tab, sizeof(vd->tab));
vd->index = 0;
+   critical_exit();
 }
 
 static void
___
svn-src-all@freebsd.org mailing list
https://lists.freebsd.org/mailman/listinfo/svn-src-all
To unsubscribe, send any mail to "svn-src-all-unsubscr...@freebsd.org"


svn commit: r357131 - head/sys/tools

2020-01-25 Thread Mateusz Guzik
Author: mjg
Date: Sun Jan 26 00:41:38 2020
New Revision: 357131
URL: https://svnweb.freebsd.org/changeset/base/357131

Log:
  vfs: stop null checking routines in vop wrappers
  
  Calls to vop_bypass pass the same argument, but type casted to something else.
  Thus by replacing NULL routines with vop_bypass we avoid a runtime check.
  
  Reviewed by:  kib
  Differential Revision:https://reviews.freebsd.org/D23357

Modified:
  head/sys/tools/vnode_if.awk

Modified: head/sys/tools/vnode_if.awk
==
--- head/sys/tools/vnode_if.awk Sun Jan 26 00:40:27 2020(r357130)
+++ head/sys/tools/vnode_if.awk Sun Jan 26 00:41:38 2020(r357131)
@@ -367,14 +367,11 @@ while ((getline < srcfile) > 0) {
add_pre(name);
for (i = 0; i < numargs; ++i)
add_debug_code(name, args[i], "Entry", "\t");
-   printc("\tif (__predict_true(!SDT_PROBES_ENABLED() && 
vop->"name" != NULL)) {");
+   printc("\tif (!SDT_PROBES_ENABLED()) {");
printc("\t\trc = vop->"name"(a);")
printc("\t} else {")
printc("\t\tSDT_PROBE2(vfs, vop, " name ", entry, a->a_" 
args[0] ", a);");
-   printc("\t\tif (vop->"name" != NULL)")
-   printc("\t\t\trc = vop->"name"(a);")
-   printc("\t\telse")
-   printc("\t\t\trc = vop->vop_bypass(&a->a_gen);")
+   printc("\t\trc = vop->"name"(a);")
printc("\t\tSDT_PROBE3(vfs, vop, " name ", return, a->a_" 
args[0] ", a, rc);");
printc("\t}")
printc("\tif (rc == 0) {");
@@ -449,6 +446,11 @@ if (cfile) {
printc("\t\tvop = vop->vop_default;")
printc("\tif (vop != NULL)");
printc("\t\torig_vop->vop_bypass = vop->vop_bypass;");
+   printc("");
+   for (name in funcarr) {
+   printc("\tif (orig_vop->"name" == NULL)");
+   printc("\t\torig_vop->"name" = (void *)orig_vop->vop_bypass;");
+   }
printc("");
printc("\torig_vop->registered = true;");
printc("}")
___
svn-src-all@freebsd.org mailing list
https://lists.freebsd.org/mailman/listinfo/svn-src-all
To unsubscribe, send any mail to "svn-src-all-unsubscr...@freebsd.org"


svn commit: r357132 - stable/12/sbin/swapon

2020-01-25 Thread Don Lewis
Author: truckman
Date: Sun Jan 26 01:42:47 2020
New Revision: 357132
URL: https://svnweb.freebsd.org/changeset/base/357132

Log:
  MFC r33
  
  Fix a logic bug in error handling code.  It is an error if p == NULL.
  The linelen tests are only meaningful when p != NULL.
  
  Reported by:  Coverity
  Coverity CID: 1368655

Modified:
  stable/12/sbin/swapon/swapon.c
Directory Properties:
  stable/12/   (props changed)

Modified: stable/12/sbin/swapon/swapon.c
==
--- stable/12/sbin/swapon/swapon.c  Sun Jan 26 00:41:38 2020
(r357131)
+++ stable/12/sbin/swapon/swapon.c  Sun Jan 26 01:42:47 2020
(r357132)
@@ -542,7 +542,7 @@ swap_on_off_md(const char *name, char *mntops, int doi
goto err;
}
p = fgetln(sfd, &linelen);
-   if (p == NULL &&
+   if (p == NULL ||
(linelen < 2 || linelen > sizeof(linebuf))) {
warn("mdconfig (attach) unexpected output");
ret = NULL;
___
svn-src-all@freebsd.org mailing list
https://lists.freebsd.org/mailman/listinfo/svn-src-all
To unsubscribe, send any mail to "svn-src-all-unsubscr...@freebsd.org"


svn commit: r357133 - stable/11/sbin/swapon

2020-01-25 Thread Don Lewis
Author: truckman
Date: Sun Jan 26 01:45:22 2020
New Revision: 357133
URL: https://svnweb.freebsd.org/changeset/base/357133

Log:
  MFC r33
  
  Fix a logic bug in error handling code.  It is an error if p == NULL.
  The linelen tests are only meaningful when p != NULL.
  
  Reported by:  Coverity
  Coverity CID: 1368655

Modified:
  stable/11/sbin/swapon/swapon.c
Directory Properties:
  stable/11/   (props changed)

Modified: stable/11/sbin/swapon/swapon.c
==
--- stable/11/sbin/swapon/swapon.c  Sun Jan 26 01:42:47 2020
(r357132)
+++ stable/11/sbin/swapon/swapon.c  Sun Jan 26 01:45:22 2020
(r357133)
@@ -521,7 +521,7 @@ swap_on_off_md(const char *name, char *mntops, int doi
goto err;
}
p = fgetln(sfd, &linelen);
-   if (p == NULL &&
+   if (p == NULL ||
(linelen < 2 || linelen > sizeof(linebuf))) {
warn("mdconfig (attach) unexpected output");
ret = NULL;
___
svn-src-all@freebsd.org mailing list
https://lists.freebsd.org/mailman/listinfo/svn-src-all
To unsubscribe, send any mail to "svn-src-all-unsubscr...@freebsd.org"


A question from Susi (for gcu-squad.org)

2020-01-25 Thread Susi Miguelito
Greetings! I’m Susi, editor at one of the internet’s best-loved adult review 
sites. I’ve been reading through your site, and I’d love to work with you – 
ideally by buying a guest post. In return, I can guarantee: A well-written, 
engaging post, created by industry-leading copywriters.  A flexible approach; 
if you’ve got a topic in mind, we can work with it. Otherwise, we’re happy to 
come up with the goods. SEO optimisation, with explicit or non-explicit 
keywords covered. If this sounds like something you’d be up for, let me know. I 
look forward to discussing things further. === Thank you, Susi Miguelito 
___
svn-src-all@freebsd.org mailing list
https://lists.freebsd.org/mailman/listinfo/svn-src-all
To unsubscribe, send any mail to "svn-src-all-unsubscr...@freebsd.org"


svn commit: r357134 - stable/11/usr.bin/vmstat

2020-01-25 Thread Takahashi Yoshihiro
Author: nyan
Date: Sun Jan 26 04:54:17 2020
New Revision: 357134
URL: https://svnweb.freebsd.org/changeset/base/357134

Log:
  MFC r322252 by manu: vmstat: Always emit a space after the free-memory column
  
  > When displaying in non-human form, if the free-memory number
  > is large (more than 7 digits), there is no space between it and
  > the page fault column.
  
  PR:   242350

Modified:
  stable/11/usr.bin/vmstat/vmstat.c
Directory Properties:
  stable/11/   (props changed)

Modified: stable/11/usr.bin/vmstat/vmstat.c
==
--- stable/11/usr.bin/vmstat/vmstat.c   Sun Jan 26 01:45:22 2020
(r357133)
+++ stable/11/usr.bin/vmstat/vmstat.c   Sun Jan 26 04:54:17 2020
(r357134)
@@ -793,6 +793,7 @@ dovmstat(unsigned int interval, int reps)
xo_emit(" ");
xo_emit("{:free-memory/%7d}",
vmstat_pgtok(total.t_free));
+   xo_emit(" ");
}
xo_emit("{:total-page-faults/%5lu} ",
(unsigned long)rate(sum.v_vm_faults -
___
svn-src-all@freebsd.org mailing list
https://lists.freebsd.org/mailman/listinfo/svn-src-all
To unsubscribe, send any mail to "svn-src-all-unsubscr...@freebsd.org"


svn commit: r357135 - head/sys/kern

2020-01-25 Thread Mateusz Guzik
Author: mjg
Date: Sun Jan 26 07:05:06 2020
New Revision: 357135
URL: https://svnweb.freebsd.org/changeset/base/357135

Log:
  vfs: remove vop loop from vop_sigdefer
  
  All ops are guaranteed to be present since r357131.

Modified:
  head/sys/kern/vfs_default.c

Modified: head/sys/kern/vfs_default.c
==
--- head/sys/kern/vfs_default.c Sun Jan 26 04:54:17 2020(r357134)
+++ head/sys/kern/vfs_default.c Sun Jan 26 07:05:06 2020(r357135)
@@ -1450,20 +1450,7 @@ vop_sigdefer(struct vop_vector *vop, struct vop_generi
vop_bypass_t *bp;
int prev_stops, rc;
 
-   for (; vop != NULL; vop = vop->vop_default) {
-   bp = bp_by_off(vop, a);
-   if (bp != NULL)
-   break;
-
-   /*
-* Bypass is not really supported.  It is done for
-* fallback to unimplemented vops in the default
-* vector.
-*/
-   bp = vop->vop_bypass;
-   if (bp != NULL)
-   break;
-   }
+   bp = bp_by_off(vop, a);
MPASS(bp != NULL);
 
prev_stops = sigdeferstop(SIGDEFERSTOP_SILENT);
___
svn-src-all@freebsd.org mailing list
https://lists.freebsd.org/mailman/listinfo/svn-src-all
To unsubscribe, send any mail to "svn-src-all-unsubscr...@freebsd.org"


svn commit: r357136 - head/sys/kern

2020-01-25 Thread Mateusz Guzik
Author: mjg
Date: Sun Jan 26 07:06:18 2020
New Revision: 357136
URL: https://svnweb.freebsd.org/changeset/base/357136

Log:
  vfs: do an unlocked check before iterating the lazy list
  
  For most filesystems it is expected to be empty most of the time.

Modified:
  head/sys/kern/vfs_subr.c

Modified: head/sys/kern/vfs_subr.c
==
--- head/sys/kern/vfs_subr.cSun Jan 26 07:05:06 2020(r357135)
+++ head/sys/kern/vfs_subr.cSun Jan 26 07:06:18 2020(r357136)
@@ -6368,6 +6368,9 @@ __mnt_vnode_first_lazy(struct vnode **mvp, struct moun
 {
struct vnode *vp;
 
+   if (TAILQ_EMPTY(&mp->mnt_lazyvnodelist))
+   return (NULL);
+
*mvp = vn_alloc_marker(mp);
MNT_ILOCK(mp);
MNT_REF(mp);
___
svn-src-all@freebsd.org mailing list
https://lists.freebsd.org/mailman/listinfo/svn-src-all
To unsubscribe, send any mail to "svn-src-all-unsubscr...@freebsd.org"


svn commit: r357137 - head/tests/sys/kern

2020-01-25 Thread Li-Wen Hsu
Author: lwhsu
Date: Sun Jan 26 07:24:49 2020
New Revision: 357137
URL: https://svnweb.freebsd.org/changeset/base/357137

Log:
  Temporarily skip flakey test case 
sys.kern.ptrace_test.ptrace__procdesc_reparent_wait_child
  
  PR:   243605
  Sponsored by: The FreeBSD Foundation

Modified:
  head/tests/sys/kern/ptrace_test.c

Modified: head/tests/sys/kern/ptrace_test.c
==
--- head/tests/sys/kern/ptrace_test.c   Sun Jan 26 07:06:18 2020
(r357136)
+++ head/tests/sys/kern/ptrace_test.c   Sun Jan 26 07:24:49 2020
(r357137)
@@ -4189,6 +4189,9 @@ ATF_TC_BODY(ptrace__procdesc_reparent_wait_child, tc)
pid_t traced, debuger, wpid;
int pd, status;
 
+   if (atf_tc_get_config_var_as_bool_wd(tc, "ci", false))
+   atf_tc_skip("https://bugs.freebsd.org/243605";);
+
traced = pdfork(&pd, 0);
ATF_REQUIRE(traced >= 0);
if (traced == 0) {
___
svn-src-all@freebsd.org mailing list
https://lists.freebsd.org/mailman/listinfo/svn-src-all
To unsubscribe, send any mail to "svn-src-all-unsubscr...@freebsd.org"