Skip site navigation (1)Skip section navigation (2)
Date:      Tue, 9 Oct 2012 19:53:15 +0000 (UTC)
From:      Jim Harris <jimharris@FreeBSD.org>
To:        src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org
Subject:   svn commit: r241379 - stable/9/sys/dev/tws
Message-ID:  <201210091953.q99JrFJr066234@svn.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: jimharris
Date: Tue Oct  9 19:53:15 2012
New Revision: 241379
URL: http://svn.freebsd.org/changeset/base/241379

Log:
  MFC r240900:
  
  Specify MTX_RECURSE for the controller's io_lock.  Without it, tws(4)
  immediately panics on boot with INVARIANTS enabled.  The driver already
  clearly expects to be able to recurse on this mutex - the main I/O path
  is always recursing on this lock.

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

Modified: stable/9/sys/dev/tws/tws.c
==============================================================================
--- stable/9/sys/dev/tws/tws.c	Tue Oct  9 18:45:08 2012	(r241378)
+++ stable/9/sys/dev/tws/tws.c	Tue Oct  9 19:53:15 2012	(r241379)
@@ -197,7 +197,7 @@ tws_attach(device_t dev)
     mtx_init( &sc->q_lock, "tws_q_lock", NULL, MTX_DEF);
     mtx_init( &sc->sim_lock,  "tws_sim_lock", NULL, MTX_DEF);
     mtx_init( &sc->gen_lock,  "tws_gen_lock", NULL, MTX_DEF);
-    mtx_init( &sc->io_lock,  "tws_io_lock", NULL, MTX_DEF);
+    mtx_init( &sc->io_lock,  "tws_io_lock", NULL, MTX_DEF | MTX_RECURSE);
 
     if ( tws_init_trace_q(sc) == FAILURE )
         printf("trace init failure\n");



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