diff options
| author | oster <oster@NetBSD.org> | 2000-05-27 20:29:14 +0000 |
|---|---|---|
| committer | oster <oster@NetBSD.org> | 2000-05-27 20:29:14 +0000 |
| commit | 26b459873685b6c14c9edea598dfeee03367e9d8 (patch) | |
| tree | 4d419fc106fa6b516accc32d6becc7958a6b9eca /sys/dev/raidframe | |
| parent | 6cfde8f14668ffe191341c58175106e828ed74cd (diff) | |
Components which match on everything but the mod_counter are
renegades, and must be handled correctly. In particular, they should
be added to their old auto-config set, but then immediately released.
Failing to do otherwise means that they potentialy end up in a
different (and competing!) RAID set which may auto-configure in place
of the correct one, and cause all sorts of chaos at auto-configure
time.
Diffstat (limited to 'sys/dev/raidframe')
| -rw-r--r-- | sys/dev/raidframe/rf_netbsdkintf.c | 27 |
1 files changed, 23 insertions, 4 deletions
diff --git a/sys/dev/raidframe/rf_netbsdkintf.c b/sys/dev/raidframe/rf_netbsdkintf.c index 3d998941751..ba244006697 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.81 2000/05/27 19:12:03 oster Exp $ */ +/* $NetBSD: rf_netbsdkintf.c,v 1.82 2000/05/27 20:29:14 oster Exp $ */ /*- * Copyright (c) 1996, 1997, 1998 The NetBSD Foundation, Inc. * All rights reserved. @@ -2842,9 +2842,28 @@ rf_create_auto_sets(ac_list) cset = config_sets; while(cset!=NULL) { if (rf_does_it_fit(cset, ac)) { - /* looks like it matches */ - ac->next = cset->ac; - cset->ac = ac; + /* looks like it matches... how about + the mod_counter? */ + + if (cset->ac->clabel->mod_counter == + ac->clabel->mod_counter) { + ac->next = cset->ac; + cset->ac = ac; + } else { + /* else we ignore this, as + it used to belong to a + valid set, but is no + longer in sync. It's + effectively a renegade, + and we don't want to add + it *anywhere*. Close it, + and carry on. + */ + VOP_CLOSE(ac->vp, FREAD, + NOCRED, 0); + vput(ac->vp); + + } break; } cset = cset->next; |
