summaryrefslogtreecommitdiff
path: root/fs/gfs2/locking/dlm
diff options
context:
space:
mode:
authorAdrian Bunk <bunk@stusta.de>2006-04-28 10:59:12 -0400
committerSteven Whitehouse <swhiteho@redhat.com>2006-04-28 10:59:12 -0400
commit08bc2dbc7327e89b9d5b9c8ef9401d1df2622fca (patch)
tree2c16cbd9f5bd856b00ef0a0d9f88b3afa67712ee /fs/gfs2/locking/dlm
parentc56b39cd2c55d521597f04bbd872a08d1c4373ca (diff)
[GFS2] [-mm patch] fs/gfs2/: possible cleanups
This patch contains the following possible cleanups: - make needlessly global code static - #if 0 unused functions - remove the following global function that was both unused and unimplemented: - super.c: gfs2_do_upgrade() Signed-off-by: Adrian Bunk <bunk@stusta.de> Signed-off-by: Steven Whitehouse <swhiteho@redhat.com>
Diffstat (limited to 'fs/gfs2/locking/dlm')
-rw-r--r--fs/gfs2/locking/dlm/lock.c10
-rw-r--r--fs/gfs2/locking/dlm/lock_dlm.h4
-rw-r--r--fs/gfs2/locking/dlm/main.c4
3 files changed, 7 insertions, 11 deletions
diff --git a/fs/gfs2/locking/dlm/lock.c b/fs/gfs2/locking/dlm/lock.c
index a309b799dff1..3b0dfd7ae26e 100644
--- a/fs/gfs2/locking/dlm/lock.c
+++ b/fs/gfs2/locking/dlm/lock.c
@@ -158,8 +158,8 @@ static inline void make_strname(struct lm_lockname *lockname,
str->namelen = GDLM_STRNAME_BYTES;
}
-int gdlm_create_lp(struct gdlm_ls *ls, struct lm_lockname *name,
- struct gdlm_lock **lpp)
+static int gdlm_create_lp(struct gdlm_ls *ls, struct lm_lockname *name,
+ struct gdlm_lock **lpp)
{
struct gdlm_lock *lp;
@@ -276,7 +276,7 @@ unsigned int gdlm_do_lock(struct gdlm_lock *lp)
return LM_OUT_ASYNC;
}
-unsigned int gdlm_do_unlock(struct gdlm_lock *lp)
+static unsigned int gdlm_do_unlock(struct gdlm_lock *lp)
{
struct gdlm_ls *ls = lp->ls;
unsigned int lkf = 0;
@@ -378,7 +378,7 @@ void gdlm_cancel(lm_lock_t *lock)
clear_bit(LFL_DLM_CANCEL, &lp->flags);
}
-int gdlm_add_lvb(struct gdlm_lock *lp)
+static int gdlm_add_lvb(struct gdlm_lock *lp)
{
char *lvb;
@@ -391,7 +391,7 @@ int gdlm_add_lvb(struct gdlm_lock *lp)
return 0;
}
-void gdlm_del_lvb(struct gdlm_lock *lp)
+static void gdlm_del_lvb(struct gdlm_lock *lp)
{
kfree(lp->lvb);
lp->lvb = NULL;
diff --git a/fs/gfs2/locking/dlm/lock_dlm.h b/fs/gfs2/locking/dlm/lock_dlm.h
index e6c1e4786fec..530c2f542584 100644
--- a/fs/gfs2/locking/dlm/lock_dlm.h
+++ b/fs/gfs2/locking/dlm/lock_dlm.h
@@ -162,12 +162,8 @@ int16_t gdlm_make_lmstate(int16_t);
void gdlm_queue_delayed(struct gdlm_lock *);
void gdlm_submit_delayed(struct gdlm_ls *);
int gdlm_release_all_locks(struct gdlm_ls *);
-int gdlm_create_lp(struct gdlm_ls *, struct lm_lockname *, struct gdlm_lock **);
void gdlm_delete_lp(struct gdlm_lock *);
-int gdlm_add_lvb(struct gdlm_lock *);
-void gdlm_del_lvb(struct gdlm_lock *);
unsigned int gdlm_do_lock(struct gdlm_lock *);
-unsigned int gdlm_do_unlock(struct gdlm_lock *);
int gdlm_get_lock(lm_lockspace_t *, struct lm_lockname *, lm_lock_t **);
void gdlm_put_lock(lm_lock_t *);
diff --git a/fs/gfs2/locking/dlm/main.c b/fs/gfs2/locking/dlm/main.c
index 3c9adf18fd9c..89728c91665f 100644
--- a/fs/gfs2/locking/dlm/main.c
+++ b/fs/gfs2/locking/dlm/main.c
@@ -16,7 +16,7 @@ extern int gdlm_drop_period;
extern struct lm_lockops gdlm_ops;
-int __init init_lock_dlm(void)
+static int __init init_lock_dlm(void)
{
int error;
@@ -48,7 +48,7 @@ int __init init_lock_dlm(void)
return 0;
}
-void __exit exit_lock_dlm(void)
+static void __exit exit_lock_dlm(void)
{
gdlm_plock_exit();
gdlm_sysfs_exit();