aboutsummaryrefslogtreecommitdiffstats
path: root/fs/ocfs2/dlmglue.c
diff options
context:
space:
mode:
authorMark Fasheh <mfasheh@suse.com>2008-12-24 19:03:48 -0500
committerMark Fasheh <mfasheh@suse.com>2009-01-05 11:40:36 -0500
commita641dc2a5a1445eb4cb491080dfc41c42a9eb37d (patch)
tree95e33d83f3399924521febd6e886b62d4715e23c /fs/ocfs2/dlmglue.c
parent38d59ef61c11cafc50a66787bdbbe80d58bbd9c0 (diff)
ocfs2: remove unneeded lvb casts
dlmglue.c has lots of code which casts the return value of ocfs2_dlm_lvb(). This is pointless however, as ocfs2_dlm_lvb() returns void *. Signed-off-by: Mark Fasheh <mfasheh@suse.com>
Diffstat (limited to 'fs/ocfs2/dlmglue.c')
-rw-r--r--fs/ocfs2/dlmglue.c12
1 files changed, 5 insertions, 7 deletions
diff --git a/fs/ocfs2/dlmglue.c b/fs/ocfs2/dlmglue.c
index b1c75911d8ad..f731ab491795 100644
--- a/fs/ocfs2/dlmglue.c
+++ b/fs/ocfs2/dlmglue.c
@@ -115,8 +115,7 @@ static void ocfs2_dump_meta_lvb_info(u64 level,
115 unsigned int line, 115 unsigned int line,
116 struct ocfs2_lock_res *lockres) 116 struct ocfs2_lock_res *lockres)
117{ 117{
118 struct ocfs2_meta_lvb *lvb = 118 struct ocfs2_meta_lvb *lvb = ocfs2_dlm_lvb(&lockres->l_lksb);
119 (struct ocfs2_meta_lvb *)ocfs2_dlm_lvb(&lockres->l_lksb);
120 119
121 mlog(level, "LVB information for %s (called from %s:%u):\n", 120 mlog(level, "LVB information for %s (called from %s:%u):\n",
122 lockres->l_name, function, line); 121 lockres->l_name, function, line);
@@ -1864,7 +1863,7 @@ static void __ocfs2_stuff_meta_lvb(struct inode *inode)
1864 1863
1865 mlog_entry_void(); 1864 mlog_entry_void();
1866 1865
1867 lvb = (struct ocfs2_meta_lvb *)ocfs2_dlm_lvb(&lockres->l_lksb); 1866 lvb = ocfs2_dlm_lvb(&lockres->l_lksb);
1868 1867
1869 /* 1868 /*
1870 * Invalidate the LVB of a deleted inode - this way other 1869 * Invalidate the LVB of a deleted inode - this way other
@@ -1916,7 +1915,7 @@ static void ocfs2_refresh_inode_from_lvb(struct inode *inode)
1916 1915
1917 mlog_meta_lvb(0, lockres); 1916 mlog_meta_lvb(0, lockres);
1918 1917
1919 lvb = (struct ocfs2_meta_lvb *)ocfs2_dlm_lvb(&lockres->l_lksb); 1918 lvb = ocfs2_dlm_lvb(&lockres->l_lksb);
1920 1919
1921 /* We're safe here without the lockres lock... */ 1920 /* We're safe here without the lockres lock... */
1922 spin_lock(&oi->ip_lock); 1921 spin_lock(&oi->ip_lock);
@@ -1951,8 +1950,7 @@ static void ocfs2_refresh_inode_from_lvb(struct inode *inode)
1951static inline int ocfs2_meta_lvb_is_trustable(struct inode *inode, 1950static inline int ocfs2_meta_lvb_is_trustable(struct inode *inode,
1952 struct ocfs2_lock_res *lockres) 1951 struct ocfs2_lock_res *lockres)
1953{ 1952{
1954 struct ocfs2_meta_lvb *lvb = 1953 struct ocfs2_meta_lvb *lvb = ocfs2_dlm_lvb(&lockres->l_lksb);
1955 (struct ocfs2_meta_lvb *)ocfs2_dlm_lvb(&lockres->l_lksb);
1956 1954
1957 if (lvb->lvb_version == OCFS2_LVB_VERSION 1955 if (lvb->lvb_version == OCFS2_LVB_VERSION
1958 && be32_to_cpu(lvb->lvb_igeneration) == inode->i_generation) 1956 && be32_to_cpu(lvb->lvb_igeneration) == inode->i_generation)
@@ -3489,7 +3487,7 @@ static void ocfs2_set_qinfo_lvb(struct ocfs2_lock_res *lockres)
3489 3487
3490 mlog_entry_void(); 3488 mlog_entry_void();
3491 3489
3492 lvb = (struct ocfs2_qinfo_lvb *)ocfs2_dlm_lvb(&lockres->l_lksb); 3490 lvb = ocfs2_dlm_lvb(&lockres->l_lksb);
3493 lvb->lvb_version = OCFS2_QINFO_LVB_VERSION; 3491 lvb->lvb_version = OCFS2_QINFO_LVB_VERSION;
3494 lvb->lvb_bgrace = cpu_to_be32(info->dqi_bgrace); 3492 lvb->lvb_bgrace = cpu_to_be32(info->dqi_bgrace);
3495 lvb->lvb_igrace = cpu_to_be32(info->dqi_igrace); 3493 lvb->lvb_igrace = cpu_to_be32(info->dqi_igrace);