svn commit: r230253 - in stable: 8/sys/dev/tws 9/sys/dev/tws

Xin LI delphij at FreeBSD.org
Tue Jan 17 01:28:44 UTC 2012


Author: delphij
Date: Tue Jan 17 01:28:43 2012
New Revision: 230253
URL: http://svn.freebsd.org/changeset/base/230253

Log:
  MFC 229416 + 223200:
  
  Don't forget to release queue lock when allocation of memory failed.
  
  Submitted by:	Sascha Wildner <saw online de>
  Obtained from:	DragonFly

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

Changes in other areas also in this revision:
Modified:
  stable/8/sys/dev/tws/tws.c
Directory Properties:
  stable/8/sys/   (props changed)

Modified: stable/9/sys/dev/tws/tws.c
==============================================================================
--- stable/9/sys/dev/tws/tws.c	Tue Jan 17 01:25:53 2012	(r230252)
+++ stable/9/sys/dev/tws/tws.c	Tue Jan 17 01:28:43 2012	(r230253)
@@ -685,6 +685,7 @@ tws_init_reqs(struct tws_softc *sc, u_in
     {
         if (bus_dmamap_create(sc->data_tag, 0, &sc->reqs[i].dma_map)) {
             /* log a ENOMEM failure msg here */
+            mtx_unlock(&sc->q_lock);
             return(FAILURE);
         } 
         sc->reqs[i].cmd_pkt =  &cmd_buf[i];


More information about the svn-src-all mailing list