Module Name: src Committed By: snj Date: Sat Jan 30 19:06:26 UTC 2010
Modified Files: src/sys/dev/ata [netbsd-5-0]: wd.c Log Message: Pull up following revision(s) (requested by bouyer in ticket #1269): sys/dev/ata/wd.c: revision 1.383 via patch struct buf::b_iodone is not called at splbio() any more. Make sure non-MPsafe iodone callbacks raise the SPL as appropriate. To generate a diff of this commit: cvs rdiff -u -r1.363.8.1 -r1.363.8.1.2.1 src/sys/dev/ata/wd.c Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files.
Modified files: Index: src/sys/dev/ata/wd.c diff -u src/sys/dev/ata/wd.c:1.363.8.1 src/sys/dev/ata/wd.c:1.363.8.1.2.1 --- src/sys/dev/ata/wd.c:1.363.8.1 Wed Feb 18 00:23:09 2009 +++ src/sys/dev/ata/wd.c Sat Jan 30 19:06:26 2010 @@ -1,4 +1,4 @@ -/* $NetBSD: wd.c,v 1.363.8.1 2009/02/18 00:23:09 snj Exp $ */ +/* $NetBSD: wd.c,v 1.363.8.1.2.1 2010/01/30 19:06:26 snj Exp $ */ /* * Copyright (c) 1998, 2001 Manuel Bouyer. All rights reserved. @@ -59,7 +59,7 @@ */ #include <sys/cdefs.h> -__KERNEL_RCSID(0, "$NetBSD: wd.c,v 1.363.8.1 2009/02/18 00:23:09 snj Exp $"); +__KERNEL_RCSID(0, "$NetBSD: wd.c,v 1.363.8.1.2.1 2010/01/30 19:06:26 snj Exp $"); #include "opt_ata.h" @@ -638,6 +638,7 @@ struct buf *obp = bp->b_private; struct wd_softc *sc = device_lookup_private(&wd_cd, DISKUNIT(obp->b_dev)); + int s; if (__predict_false(bp->b_error != 0)) { /* @@ -666,15 +667,19 @@ bp->b_data = (char *)bp->b_data + bp->b_bcount; bp->b_blkno += (bp->b_bcount / 512); bp->b_rawblkno += (bp->b_bcount / 512); + s = splbio(); __wdstart(sc, bp); + splx(s); return; done: obp->b_error = bp->b_error; obp->b_resid = bp->b_resid; + s = splbio(); putiobuf(bp); biodone(obp); sc->openings++; + splx(s); /* wddone() will call wdstart() */ }