Skip site navigation (1)Skip section navigation (2)
Date:      Mon, 8 Apr 2013 23:06:26 +0000 (UTC)
From:      Xin LI <delphij@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: r249290 - in stable: 8/sys/dev/mfi 9/sys/dev/mfi
Message-ID:  <201304082306.r38N6QOt057717@svn.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: delphij
Date: Mon Apr  8 23:06:25 2013
New Revision: 249290
URL: http://svnweb.freebsd.org/changeset/base/249290

Log:
  MFC r248627:
  
  Don't attempt to reference sc before testing whether it's NULL.
  
  Submitted by:	Sascha Wildner
  Obtained from:	DragonFly

Modified:
  stable/8/sys/dev/mfi/mfi_disk.c
Directory Properties:
  stable/8/sys/   (props changed)
  stable/8/sys/dev/   (props changed)
  stable/8/sys/dev/mfi/   (props changed)

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

Modified: stable/8/sys/dev/mfi/mfi_disk.c
==============================================================================
--- stable/8/sys/dev/mfi/mfi_disk.c	Mon Apr  8 23:01:33 2013	(r249289)
+++ stable/8/sys/dev/mfi/mfi_disk.c	Mon Apr  8 23:06:25 2013	(r249290)
@@ -261,7 +261,6 @@ mfi_disk_strategy(struct bio *bio)
 	struct mfi_softc *controller;
 
 	sc = bio->bio_disk->d_drv1;
-	controller = sc->ld_controller;
 
 	if (sc == NULL) {
 		bio->bio_error = EINVAL;
@@ -271,6 +270,7 @@ mfi_disk_strategy(struct bio *bio)
 		return;
 	}
 
+	controller = sc->ld_controller;
 	if (controller->adpreset) {
 		bio->bio_error = EBUSY;
 		return;



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