Skip to contentSkip to conversation

cluster/gfs-kernel/src/gfs rgrp.c

Cluster-devel [email protected] 1 participant 1 message Jan 2, 2008

lore
Share & tools
lore
#0 lore raw

CVSROOT: /cvs/cluster
Module name: cluster
Branch: RHEL4
Changes by: wcheng at sourceware.org 2008-01-02 19:17:09

Modified files:
gfs-kernel/src/gfs: rgrp.c

Log message:
Bugzilla 227892:
1. Warn people about the RG corruption and request a gfs_fsck
2. Upon error detection, perform a minimum error data collection.

Patches:
http://sourceware.org/cgi-bin/cvsweb.cgi/cluster/gfs-kernel/src/gfs/rgrp.c.diff?cvsroot=cluster&only_with_tag=RHEL4&r1=1.14.2.4&r2=1.14.2.5

gfs-kernel/src/gfs/rgrp.c +7 -2
@@ -1456,8 +1456,13 @@
 		goal = 0;
 	}
 
-	if (gfs_assert_withdraw(rgd->rd_sbd, x <= length))
-		blk = 0;
+	if (unlikely(x > length)) {
+		printk("GFS error: possible RG corruption\n");
+		printk("    please run gfs_fsck after withdraw\n");
+		dump_stack();
+		if (gfs_assert_withdraw(rgd->rd_sbd, x <= length))
+			blk = 0;
+	}
 
 	/* Attach bitmap buffer to trans, modify bits to do block alloc */
 	gfs_trans_add_bh(rgd->rd_gl, rgd->rd_bh[buf]);