[GFS2] Addendum to the journaled file/unmount patch
authorRobert Peterson <rpeterso@redhat.com>
Wed, 20 Jun 2007 13:34:06 +0000 (08:34 -0500)
committerSteven Whitehouse <swhiteho@redhat.com>
Mon, 9 Jul 2007 07:23:52 +0000 (08:23 +0100)
This patch is an addendum to the previous journaled file/unmount patch.
It fixes a problem discovered during testing.

Signed-off-by: Bob Peterson <rpeterso@redhat.com>
Signed-off-by: Steven Whitehouse <swhiteho@redhat.com>
fs/gfs2/lops.c

index dd810ad68cf04cefd03154ade0595de6630c1f42..aff70f0698fdd887799e3d23a0057ea715714112 100644 (file)
@@ -472,8 +472,10 @@ static void databuf_lo_add(struct gfs2_sbd *sdp, struct gfs2_log_element *le)
                return;
        }
        tr->tr_touched = 1;
-       tr->tr_num_buf++;
-       list_add(&bd->bd_list_tr, &tr->tr_list_buf);
+       if (gfs2_is_jdata(ip)) {
+               tr->tr_num_buf++;
+               list_add(&bd->bd_list_tr, &tr->tr_list_buf);
+       }
        gfs2_log_unlock(sdp);
        if (!list_empty(&le->le_list))
                return;