diff options
| author | oster <oster@NetBSD.org> | 1999-07-21 03:15:26 +0000 |
|---|---|---|
| committer | oster <oster@NetBSD.org> | 1999-07-21 03:15:26 +0000 |
| commit | 5cef006d4018883bc51b297694ca799fe86fda17 (patch) | |
| tree | 5f6065554f37a1df8937fde645a6edf141a7056b /sys/dev/raidframe | |
| parent | 8dd6bc6db8d12d0d36dc1e0d8e8b72626eb8f35e (diff) | |
Need to splbio()/splx() protect some of the reconstruction stuff.
Without this, we have potentially bad interatctions with the pool
code.
Diffstat (limited to 'sys/dev/raidframe')
| -rw-r--r-- | sys/dev/raidframe/rf_netbsdkintf.c | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/sys/dev/raidframe/rf_netbsdkintf.c b/sys/dev/raidframe/rf_netbsdkintf.c index 0953868f2e6..e69a4601e2d 100644 --- a/sys/dev/raidframe/rf_netbsdkintf.c +++ b/sys/dev/raidframe/rf_netbsdkintf.c @@ -1,4 +1,4 @@ -/* $NetBSD: rf_netbsdkintf.c,v 1.20 1999/07/08 00:45:23 oster Exp $ */ +/* $NetBSD: rf_netbsdkintf.c,v 1.21 1999/07/21 03:15:26 oster Exp $ */ /*- * Copyright (c) 1996, 1997, 1998 The NetBSD Foundation, Inc. * All rights reserved. @@ -683,6 +683,7 @@ raidioctl(dev, cmd, data, flag, p) int retcode = 0; int row; int column; + int s; struct rf_recon_req *rrcopy, *rr; RF_ComponentLabel_t *component_label; RF_ComponentLabel_t ci_label; @@ -1024,8 +1025,10 @@ raidioctl(dev, cmd, data, flag, p) return(EINVAL); } printf("Attempting a rebuild in place\n"); + s = splbio(); raidPtrs[unit]->proc = p; /* Blah... :-p GO */ retcode = rf_ReconstructInPlace(raidPtrs[unit], row, column); + splx(s); return(retcode); /* issue a test-unit-ready through raidframe to the indicated @@ -1148,7 +1151,9 @@ raidioctl(dev, cmd, data, flag, p) case RAIDFRAME_COPYBACK: /* borrow the current thread to get this done */ raidPtrs[unit]->proc = p; /* ICK.. but needed :-p GO */ + s = splbio(); rf_CopybackReconstructedData(raidPtrs[unit]); + splx(s); return (0); /* return the percentage completion of reconstruction */ |
