Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/sparc
[firefly-linux-kernel-4.4.55.git] / fs / ocfs2 / stackglue.c
index ca5ce14cbddcef81498305f8ccbccc978750faed..83f1a665ae977634fa17ee8b15b9d4ae98abb5af 100644 (file)
@@ -496,7 +496,7 @@ static ssize_t ocfs2_max_locking_protocol_show(struct kobject *kobj,
 }
 
 static struct kobj_attribute ocfs2_attr_max_locking_protocol =
-       __ATTR(max_locking_protocol, S_IFREG | S_IRUGO,
+       __ATTR(max_locking_protocol, S_IRUGO,
               ocfs2_max_locking_protocol_show, NULL);
 
 static ssize_t ocfs2_loaded_cluster_plugins_show(struct kobject *kobj,
@@ -528,7 +528,7 @@ static ssize_t ocfs2_loaded_cluster_plugins_show(struct kobject *kobj,
 }
 
 static struct kobj_attribute ocfs2_attr_loaded_cluster_plugins =
-       __ATTR(loaded_cluster_plugins, S_IFREG | S_IRUGO,
+       __ATTR(loaded_cluster_plugins, S_IRUGO,
               ocfs2_loaded_cluster_plugins_show, NULL);
 
 static ssize_t ocfs2_active_cluster_plugin_show(struct kobject *kobj,
@@ -550,7 +550,7 @@ static ssize_t ocfs2_active_cluster_plugin_show(struct kobject *kobj,
 }
 
 static struct kobj_attribute ocfs2_attr_active_cluster_plugin =
-       __ATTR(active_cluster_plugin, S_IFREG | S_IRUGO,
+       __ATTR(active_cluster_plugin, S_IRUGO,
               ocfs2_active_cluster_plugin_show, NULL);
 
 static ssize_t ocfs2_cluster_stack_show(struct kobject *kobj,
@@ -599,15 +599,29 @@ static ssize_t ocfs2_cluster_stack_store(struct kobject *kobj,
 
 
 static struct kobj_attribute ocfs2_attr_cluster_stack =
-       __ATTR(cluster_stack, S_IFREG | S_IRUGO | S_IWUSR,
+       __ATTR(cluster_stack, S_IRUGO | S_IWUSR,
               ocfs2_cluster_stack_show,
               ocfs2_cluster_stack_store);
 
+
+
+static ssize_t ocfs2_dlm_recover_show(struct kobject *kobj,
+                                       struct kobj_attribute *attr,
+                                       char *buf)
+{
+       return snprintf(buf, PAGE_SIZE, "1\n");
+}
+
+static struct kobj_attribute ocfs2_attr_dlm_recover_support =
+       __ATTR(dlm_recover_callback_support, S_IRUGO,
+              ocfs2_dlm_recover_show, NULL);
+
 static struct attribute *ocfs2_attrs[] = {
        &ocfs2_attr_max_locking_protocol.attr,
        &ocfs2_attr_loaded_cluster_plugins.attr,
        &ocfs2_attr_active_cluster_plugin.attr,
        &ocfs2_attr_cluster_stack.attr,
+       &ocfs2_attr_dlm_recover_support.attr,
        NULL,
 };