]> err.no Git - linux-2.6/blobdiff - fs/ocfs2/heartbeat.c
Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/shaggy...
[linux-2.6] / fs / ocfs2 / heartbeat.c
index 6239fc52790c6a01e06c76bd42896b1288f23923..0758daf64da07c41fcf4f73a7b55d634589ab87d 100644 (file)
@@ -41,7 +41,6 @@
 #include "heartbeat.h"
 #include "inode.h"
 #include "journal.h"
-#include "vote.h"
 
 #include "buffer_head_io.h"
 
@@ -50,17 +49,20 @@ static inline void __ocfs2_node_map_set_bit(struct ocfs2_node_map *map,
 static inline void __ocfs2_node_map_clear_bit(struct ocfs2_node_map *map,
                                              int bit);
 static inline int __ocfs2_node_map_is_empty(struct ocfs2_node_map *map);
-static void __ocfs2_node_map_dup(struct ocfs2_node_map *target,
-                                struct ocfs2_node_map *from);
-static void __ocfs2_node_map_set(struct ocfs2_node_map *target,
-                                struct ocfs2_node_map *from);
+
+/* special case -1 for now
+ * TODO: should *really* make sure the calling func never passes -1!!  */
+static void ocfs2_node_map_init(struct ocfs2_node_map *map)
+{
+       map->num_nodes = OCFS2_NODE_MAP_MAX_NODES;
+       memset(map->map, 0, BITS_TO_LONGS(OCFS2_NODE_MAP_MAX_NODES) *
+              sizeof(unsigned long));
+}
 
 void ocfs2_init_node_maps(struct ocfs2_super *osb)
 {
        spin_lock_init(&osb->node_map_lock);
-       ocfs2_node_map_init(&osb->mounted_map);
        ocfs2_node_map_init(&osb->recovery_map);
-       ocfs2_node_map_init(&osb->umount_map);
        ocfs2_node_map_init(&osb->osb_recovering_orphan_dirs);
 }
 
@@ -82,8 +84,6 @@ static void ocfs2_do_node_down(int node_num,
        }
 
        ocfs2_recovery_thread(osb, node_num);
-
-       ocfs2_remove_node_from_vote_queues(osb, node_num);
 }
 
 /* Called from the dlm when it's about to evict a node. We may also
@@ -141,15 +141,6 @@ void ocfs2_stop_heartbeat(struct ocfs2_super *osb)
                mlog_errno(ret);
 }
 
-/* special case -1 for now
- * TODO: should *really* make sure the calling func never passes -1!!  */
-void ocfs2_node_map_init(struct ocfs2_node_map *map)
-{
-       map->num_nodes = OCFS2_NODE_MAP_MAX_NODES;
-       memset(map->map, 0, BITS_TO_LONGS(OCFS2_NODE_MAP_MAX_NODES) *
-              sizeof(unsigned long));
-}
-
 static inline void __ocfs2_node_map_set_bit(struct ocfs2_node_map *map,
                                            int bit)
 {
@@ -221,6 +212,8 @@ int ocfs2_node_map_is_empty(struct ocfs2_super *osb,
        return ret;
 }
 
+#if 0
+
 static void __ocfs2_node_map_dup(struct ocfs2_node_map *target,
                                 struct ocfs2_node_map *from)
 {
@@ -259,6 +252,8 @@ static void __ocfs2_node_map_set(struct ocfs2_node_map *target,
                target->map[i] = from->map[i];
 }
 
+#endif  /*  0  */
+
 /* Returns whether the recovery bit was actually set - it may not be
  * if a node is still marked as needing recovery */
 int ocfs2_recovery_map_set(struct ocfs2_super *osb,
@@ -268,8 +263,6 @@ int ocfs2_recovery_map_set(struct ocfs2_super *osb,
 
        spin_lock(&osb->node_map_lock);
 
-       __ocfs2_node_map_clear_bit(&osb->mounted_map, num);
-
        if (!test_bit(num, osb->recovery_map.map)) {
            __ocfs2_node_map_set_bit(&osb->recovery_map, num);
            set = 1;