[Ocfs2-commits] mfasheh commits r2196 - trunk/fs/ocfs2/cluster
svn-commits at oss.oracle.com
svn-commits at oss.oracle.com
Thu Apr 28 18:54:08 CDT 2005
Author: mfasheh
Signed-off-by: jlbec
Date: 2005-04-28 18:54:06 -0500 (Thu, 28 Apr 2005)
New Revision: 2196
Modified:
trunk/fs/ocfs2/cluster/heartbeat.c
Log:
* print block device name in our error
Signed-off-by: jlbec
Modified: trunk/fs/ocfs2/cluster/heartbeat.c
===================================================================
--- trunk/fs/ocfs2/cluster/heartbeat.c 2005-04-28 21:50:19 UTC (rev 2195)
+++ trunk/fs/ocfs2/cluster/heartbeat.c 2005-04-28 23:54:06 UTC (rev 2196)
@@ -141,6 +141,8 @@
* has reached a 'steady' state. This will be fixed when we have
* a more complete api that doesn't lead to this sort of fragility. */
atomic_t hr_steady_iterations;
+
+ char hr_dev_name[BDEVNAME_SIZE];
};
struct hb_bio_wait_ctxt {
@@ -677,7 +679,8 @@
* other node has been improperly configured to heartbeat in
* our slot. */
if (!hb_check_last_timestamp(reg))
- mlog(ML_ERROR, "Another node is heartbeating in our slot!\n");
+ mlog(ML_ERROR, "Device \"%s\": another node is heartbeating "
+ "in our slot!\n", reg->hr_dev_name);
/* Set our raw timestamp */
hb_set_local_node_timestamp(reg);
@@ -943,12 +946,10 @@
static ssize_t hb_region_dev_read(struct hb_region *reg, char *page)
{
unsigned int ret = 0;
- const char *str;
- if (reg->hr_bdev) {
- str = bdevname(reg->hr_bdev, page);
- ret = sprintf(page, "%s\n", str);
- }
+ if (reg->hr_bdev)
+ ret = sprintf(page, "%s\n", reg->hr_dev_name);
+
return ret;
}
@@ -1080,6 +1081,8 @@
}
inode = NULL;
+ bdevname(reg->hr_bdev, reg->hr_dev_name);
+
hb_calculate_region_offsets(reg);
ret = hb_map_slot_data(reg);
More information about the Ocfs2-commits
mailing list