public inbox for cluster-cvs@sourceware.org
help / color / mirror / Atom feed
* cluster: RHEL4 - dlm-kernel: prevent dlm module unload following emergency shutdown
@ 2009-01-20 20:25 David Teigland
  0 siblings, 0 replies; only message in thread
From: David Teigland @ 2009-01-20 20:25 UTC (permalink / raw)
  To: cluster-cvs-relay

Gitweb:        http://git.fedorahosted.org/git/cluster.git?p=cluster.git;a=commitdiff;h=fe92396a2237644cc75adc85472d332760d57782
Commit:        fe92396a2237644cc75adc85472d332760d57782
Parent:        7a3b8199468d06f679ddc067eca3e6fa14641d13
Author:        Bryn M. Reeves <bmr@redhat.com>
AuthorDate:    Tue Jan 20 14:21:36 2009 -0600
Committer:     David Teigland <teigland@redhat.com>
CommitterDate: Tue Jan 20 14:21:36 2009 -0600

dlm-kernel: prevent dlm module unload following emergency shutdown

bz 467040

This patch takes a reference on the DLM module at the top of the emergency
shutdown routine preventing the modprobe -r in the initscript from unloading
the module (it may throw an error, but that's harmless).

Signed-off-by: David Teigland <teigland@redhat.com>
---
 dlm-kernel/src/lockspace.c |    7 +++++++
 1 files changed, 7 insertions(+), 0 deletions(-)

diff --git a/dlm-kernel/src/lockspace.c b/dlm-kernel/src/lockspace.c
index 2a006fa..f0c01ea 100644
--- a/dlm-kernel/src/lockspace.c
+++ b/dlm-kernel/src/lockspace.c
@@ -604,6 +604,13 @@ void dlm_emergency_shutdown()
 
 	printk("WARNING: dlm_emergency_shutdown\n");
 
+	/* prevent unloading since we cannot guarantee that slab
+	 * caches are empty here. This prevents a warning when our
+	 * module_exit tries to destroy the slab caches and
+	 * possible oopsen if something accesses /proc/slabinfo
+	 */
+	module_get(THIS_MODULE);
+
 	/* Shut lowcomms down to prevent any socket activity */
 	lowcomms_stop_accept();
 


^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2009-01-20 20:25 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2009-01-20 20:25 cluster: RHEL4 - dlm-kernel: prevent dlm module unload following emergency shutdown David Teigland

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).