summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorThierry Deval <tdeval@cvs.openbsd.org>2002-08-05 22:11:28 +0000
committerThierry Deval <tdeval@cvs.openbsd.org>2002-08-05 22:11:28 +0000
commit50622bca403d54eaf50c5531d185ef9c45af8c6a (patch)
tree4c7f3c69cfeea5aac4c7a59dc4fc3592547e0705
parent39ea21095ec430a72ec819ed6ec5d895f01e2559 (diff)
Clean up hook cookies from shutdown hook.
-rw-r--r--sys/dev/raidframe/rf_engine.h4
-rw-r--r--sys/dev/raidframe/rf_openbsdkintf.c6
2 files changed, 8 insertions, 2 deletions
diff --git a/sys/dev/raidframe/rf_engine.h b/sys/dev/raidframe/rf_engine.h
index d6eeb744b1a..dd21e705369 100644
--- a/sys/dev/raidframe/rf_engine.h
+++ b/sys/dev/raidframe/rf_engine.h
@@ -1,4 +1,4 @@
-/* $OpenBSD: rf_engine.h,v 1.2 1999/02/16 00:02:43 niklas Exp $ */
+/* $OpenBSD: rf_engine.h,v 1.3 2002/08/05 22:11:27 tdeval Exp $ */
/* $NetBSD: rf_engine.h,v 1.3 1999/02/05 00:06:11 oster Exp $ */
/*
* Copyright (c) 1995 Carnegie-Mellon University.
@@ -36,6 +36,8 @@
#ifndef _RF__RF_ENGINE_H_
#define _RF__RF_ENGINE_H_
+extern void **rf_hook_cookies;
+
int
rf_ConfigureEngine(RF_ShutdownList_t ** listp,
RF_Raid_t * raidPtr, RF_Config_t * cfgPtr);
diff --git a/sys/dev/raidframe/rf_openbsdkintf.c b/sys/dev/raidframe/rf_openbsdkintf.c
index ca856ea232a..bb101951113 100644
--- a/sys/dev/raidframe/rf_openbsdkintf.c
+++ b/sys/dev/raidframe/rf_openbsdkintf.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: rf_openbsdkintf.c,v 1.17 2002/05/28 23:38:10 tdeval Exp $ */
+/* $OpenBSD: rf_openbsdkintf.c,v 1.18 2002/08/05 22:11:27 tdeval Exp $ */
/* $NetBSD: rf_netbsdkintf.c,v 1.109 2001/07/27 03:30:07 oster Exp $ */
/*-
* Copyright (c) 1996, 1997, 1998 The NetBSD Foundation, Inc.
@@ -141,6 +141,7 @@
#include "rf_dagflags.h"
#include "rf_desc.h"
#include "rf_diskqueue.h"
+#include "rf_engine.h"
#include "rf_acctrace.h"
#include "rf_etimer.h"
#include "rf_general.h"
@@ -576,6 +577,9 @@ rf_shutdown_hook(arg)
/* Shutdown the system */
+ if (rf_hook_cookies != NULL && rf_hook_cookies[unit] != NULL)
+ rf_hook_cookies[unit] = NULL;
+
rf_Shutdown(raidPtr);
pool_destroy(&rs->sc_cbufpool);