From owner-svn-src-all@FreeBSD.ORG Fri May 31 03:14:50 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id 80DB71114; Fri, 31 May 2013 03:14:50 +0000 (UTC) (envelope-from sbruno@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id 74317B4E; Fri, 31 May 2013 03:14:50 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.6/8.14.6) with ESMTP id r4V3EoLa087788; Fri, 31 May 2013 03:14:50 GMT (envelope-from sbruno@svn.freebsd.org) Received: (from sbruno@localhost) by svn.freebsd.org (8.14.6/8.14.5/Submit) id r4V3Eo59087787; Fri, 31 May 2013 03:14:50 GMT (envelope-from sbruno@svn.freebsd.org) Message-Id: <201305310314.r4V3Eo59087787@svn.freebsd.org> From: Sean Bruno Date: Fri, 31 May 2013 03:14:50 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r251172 - head/sys/dev/mfi X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 31 May 2013 03:14:50 -0000 Author: sbruno Date: Fri May 31 03:14:49 2013 New Revision: 251172 URL: http://svnweb.freebsd.org/changeset/base/251172 Log: xpt_create_path() requires mfi_io_lock to be held, so do it. mfi(4) doesn't panic on host startup now. MFC this if svn 249468-242726 is shoveled back to stable/9 Obtained from: Yahoo! Inc. Modified: head/sys/dev/mfi/mfi_cam.c Modified: head/sys/dev/mfi/mfi_cam.c ============================================================================== --- head/sys/dev/mfi/mfi_cam.c Fri May 31 00:43:41 2013 (r251171) +++ head/sys/dev/mfi/mfi_cam.c Fri May 31 03:14:49 2013 (r251172) @@ -318,13 +318,16 @@ mfip_cam_rescan(struct mfi_softc *sc, ui } sim = camsc->sim; + mtx_lock(&sc->mfi_io_lock); if (xpt_create_path(&ccb->ccb_h.path, NULL, cam_sim_path(sim), tid, CAM_LUN_WILDCARD) != CAM_REQ_CMP) { xpt_free_ccb(ccb); + mtx_unlock(&sc->mfi_io_lock); device_printf(sc->mfi_dev, "Cannot create path for bus rescan.\n"); return; } + mtx_unlock(&sc->mfi_io_lock); xpt_rescan(ccb);