aboutsummaryrefslogtreecommitdiffstats
path: root/fs/dlm/lockspace.c
diff options
context:
space:
mode:
Diffstat (limited to 'fs/dlm/lockspace.c')
-rw-r--r--fs/dlm/lockspace.c11
1 files changed, 11 insertions, 0 deletions
diff --git a/fs/dlm/lockspace.c b/fs/dlm/lockspace.c
index 31ed0fe16a31..7adaad53fc38 100644
--- a/fs/dlm/lockspace.c
+++ b/fs/dlm/lockspace.c
@@ -81,6 +81,11 @@ static ssize_t dlm_recover_status_show(struct dlm_ls *ls, char *buf)
81 return sprintf(buf, "%x\n", status); 81 return sprintf(buf, "%x\n", status);
82} 82}
83 83
84static ssize_t dlm_recover_nodeid_show(struct dlm_ls *ls, char *buf)
85{
86 return sprintf(buf, "%d\n", ls->ls_recover_nodeid);
87}
88
84struct dlm_attr { 89struct dlm_attr {
85 struct attribute attr; 90 struct attribute attr;
86 ssize_t (*show)(struct dlm_ls *, char *); 91 ssize_t (*show)(struct dlm_ls *, char *);
@@ -108,11 +113,17 @@ static struct dlm_attr dlm_attr_recover_status = {
108 .show = dlm_recover_status_show 113 .show = dlm_recover_status_show
109}; 114};
110 115
116static struct dlm_attr dlm_attr_recover_nodeid = {
117 .attr = {.name = "recover_nodeid", .mode = S_IRUGO},
118 .show = dlm_recover_nodeid_show
119};
120
111static struct attribute *dlm_attrs[] = { 121static struct attribute *dlm_attrs[] = {
112 &dlm_attr_control.attr, 122 &dlm_attr_control.attr,
113 &dlm_attr_event.attr, 123 &dlm_attr_event.attr,
114 &dlm_attr_id.attr, 124 &dlm_attr_id.attr,
115 &dlm_attr_recover_status.attr, 125 &dlm_attr_recover_status.attr,
126 &dlm_attr_recover_nodeid.attr,
116 NULL, 127 NULL,
117}; 128};
118 129