Skip to contentSkip to conversation

GFS2: Remove unnecessary if

PATCH New Bob Peterson 1 participant 1 message Sep 2, 2015 1 message not in the archive GFS2 file system

lore
Share & tools
lore

A message that is not in the archive (sent off-list or not yet received): [email protected]

#1 lore raw

PATCH 1/1 GFS2: Remove unnecessary if

Hi,

This patch removes an unnecessary if in function gfs2_glock_put.

---

fs/gfs2/glock.c +1 -2
index ae3f846..9bd1244 100644
@@ -170,8 +170,7 @@ void gfs2_glock_put(struct gfs2_glock *gl)
 
 	gfs2_glock_remove_from_lru(gl);
 	spin_unlock(&gl->gl_lockref.lock);
-	if (gl->gl_node.next != NULL)
-		rhashtable_remove_fast(&gl_hash_table, &gl->gl_node, ht_parms);
+	rhashtable_remove_fast(&gl_hash_table, &gl->gl_node, ht_parms);
 	GLOCK_BUG_ON(gl, !list_empty(&gl->gl_holders));
 	GLOCK_BUG_ON(gl, mapping && mapping->nrpages);
 	trace_gfs2_glock_put(gl);