Skip site navigation (1)Skip section navigation (2)
Date:      Sat, 11 Feb 2012 14:58:47 +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-8@freebsd.org
Subject:   svn commit: r231523 - stable/8/sys/cam/scsi
Message-ID:  <201202111458.q1BEwlxG035785@svn.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: avg
Date: Sat Feb 11 14:58:46 2012
New Revision: 231523
URL: http://svn.freebsd.org/changeset/base/231523

Log:
  MFC r230157: dadump: don't leak the periph lock on i/o error

Modified:
  stable/8/sys/cam/scsi/scsi_da.c
Directory Properties:
  stable/8/sys/   (props changed)
  stable/8/sys/amd64/include/xen/   (props changed)
  stable/8/sys/boot/   (props changed)
  stable/8/sys/cddl/contrib/opensolaris/   (props changed)
  stable/8/sys/contrib/dev/acpica/   (props changed)
  stable/8/sys/contrib/pf/   (props changed)
  stable/8/sys/dev/e1000/   (props changed)

Modified: stable/8/sys/cam/scsi/scsi_da.c
==============================================================================
--- stable/8/sys/cam/scsi/scsi_da.c	Sat Feb 11 14:55:05 2012	(r231522)
+++ stable/8/sys/cam/scsi/scsi_da.c	Sat Feb 11 14:58:46 2012	(r231523)
@@ -1097,6 +1097,7 @@ dadump(void *arg, void *virtual, vm_offs
 				/*sense_len*/SSD_FULL_SIZE,
 				da_default_timeout * 1000);
 		xpt_polled_action((union ccb *)&csio);
+		cam_periph_unlock(periph);
 
 		if ((csio.ccb_h.status & CAM_STATUS_MASK) != CAM_REQ_CMP) {
 			printf("Aborting dump due to I/O error.\n");
@@ -1108,7 +1109,6 @@ dadump(void *arg, void *virtual, vm_offs
 				       csio.ccb_h.status, csio.scsi_status);
 			return(EIO);
 		}
-		cam_periph_unlock(periph);
 		return(0);
 	}
 		



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