Skip site navigation (1)Skip section navigation (2)
Date:      Wed, 4 Sep 2019 09:54:22 +0000 (UTC)
From:      Andriy Gapon <avg@FreeBSD.org>
To:        src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-11@freebsd.org
Subject:   svn commit: r351809 - stable/11/sys/kern
Message-ID:  <201909040954.x849sMfV078172@repo.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: avg
Date: Wed Sep  4 09:54:21 2019
New Revision: 351809
URL: https://svnweb.freebsd.org/changeset/base/351809

Log:
  MFC r351213: assert that td_lk_slocks is not leaked upon return from kernel

Modified:
  stable/11/sys/kern/subr_trap.c
Directory Properties:
  stable/11/   (props changed)

Modified: stable/11/sys/kern/subr_trap.c
==============================================================================
--- stable/11/sys/kern/subr_trap.c	Wed Sep  4 09:54:05 2019	(r351808)
+++ stable/11/sys/kern/subr_trap.c	Wed Sep  4 09:54:21 2019	(r351809)
@@ -164,6 +164,9 @@ userret(struct thread *td, struct trapframe *frame)
 	KASSERT(td->td_rw_rlocks == 0,
 	    ("userret: Returning with %d rwlocks held in read mode",
 	    td->td_rw_rlocks));
+	KASSERT(td->td_lk_slocks == 0,
+	    ("userret: Returning with %d lockmanager locks held in shared mode",
+	    td->td_lk_slocks));
 	KASSERT((td->td_pflags & TDP_NOFAULTING) == 0,
 	    ("userret: Returning with pagefaults disabled"));
 	KASSERT(td->td_no_sleeping == 0,



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201909040954.x849sMfV078172>