Source-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[src/netbsd-1-6]: src/sys/dev/raidframe Pull up revision 1.42 (requested by o...
details: https://anonhg.NetBSD.org/src/rev/979e66d6293a
branches: netbsd-1-6
changeset: 530898:979e66d6293a
user: cyber <cyber%NetBSD.org@localhost>
date: Mon Oct 20 05:25:38 2003 +0000
description:
Pull up revision 1.42 (requested by oster in ticket #1531):
Remember to close the component if we decide it's not suitable for use
as a hot spare. Closes PR#20989 by David Brownlee.
diffstat:
sys/dev/raidframe/rf_disks.c | 7 +++++--
1 files changed, 5 insertions(+), 2 deletions(-)
diffs (42 lines):
diff -r 5ee6db1e4635 -r 979e66d6293a sys/dev/raidframe/rf_disks.c
--- a/sys/dev/raidframe/rf_disks.c Mon Oct 20 05:19:50 2003 +0000
+++ b/sys/dev/raidframe/rf_disks.c Mon Oct 20 05:25:38 2003 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: rf_disks.c,v 1.38 2001/11/15 09:48:13 lukem Exp $ */
+/* $NetBSD: rf_disks.c,v 1.38.10.1 2003/10/20 05:25:38 cyber Exp $ */
/*-
* Copyright (c) 1999 The NetBSD Foundation, Inc.
* All rights reserved.
@@ -67,7 +67,7 @@
***************************************************************/
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: rf_disks.c,v 1.38 2001/11/15 09:48:13 lukem Exp $");
+__KERNEL_RCSID(0, "$NetBSD: rf_disks.c,v 1.38.10.1 2003/10/20 05:25:38 cyber Exp $");
#include <dev/raidframe/raidframevar.h>
@@ -1047,6 +1047,7 @@
if (disks[spare_number].status != rf_ds_optimal) {
RF_ERRORMSG1("Warning: spare disk %s failed TUR\n",
sparePtr->component_name);
+ rf_close_component(raidPtr, raidPtr->raid_cinfo[0][raidPtr->numCol+spare_number].ci_vp, 0);
ret=EINVAL;
goto fail;
} else {
@@ -1064,6 +1065,7 @@
bs = 1 << raidPtr->logBytesPerSector;
if (disks[spare_number].blockSize != bs) {
RF_ERRORMSG3("Block size of %d on spare disk %s is not the same as on other disks (%d)\n", disks[spare_number].blockSize, disks[spare_number].devname, bs);
+ rf_close_component(raidPtr, raidPtr->raid_cinfo[0][raidPtr->numCol+spare_number].ci_vp, 0);
ret = EINVAL;
goto fail;
}
@@ -1072,6 +1074,7 @@
disks[spare_number].devname,
disks[spare_number].blockSize,
(long int) raidPtr->sectorsPerDisk);
+ rf_close_component(raidPtr, raidPtr->raid_cinfo[0][raidPtr->numCol+spare_number].ci_vp, 0);
ret = EINVAL;
goto fail;
} else {
Home |
Main Index |
Thread Index |
Old Index