Skip site navigation (1)Skip section navigation (2)
Date:      Wed, 4 Sep 2019 09:54:06 +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-12@freebsd.org
Subject:   svn commit: r351808 - stable/12/sys/kern
Message-ID:  <201909040954.x849s6BQ078112@repo.freebsd.org>

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

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

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

Modified: stable/12/sys/kern/subr_trap.c
==============================================================================
--- stable/12/sys/kern/subr_trap.c	Wed Sep  4 08:48:12 2019	(r351807)
+++ stable/12/sys/kern/subr_trap.c	Wed Sep  4 09:54:05 2019	(r351808)
@@ -176,6 +176,9 @@ userret(struct thread *td, struct trapframe *frame)
 	KASSERT(td->td_sx_slocks == 0,
 	    ("userret: Returning with %d sx locks held in shared mode",
 	    td->td_sx_slocks));
+	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.x849s6BQ078112>