diff options
author | David Woodhouse <dwmw2@infradead.org> | 2007-06-29 12:39:57 (GMT) |
---|---|---|
committer | David Woodhouse <dwmw2@infradead.org> | 2007-06-29 12:39:57 (GMT) |
commit | 43dfa07fbb6b8bd5b6173a5bab48470f578c8e5b (patch) | |
tree | 2818c8f74de363c2a4084b9b050685d0a17beec9 /fs/jffs2/write.c | |
parent | 663d77a7ccfd407cf7491dbd53c7c17eef58c96a (diff) | |
download | linux-fsl-qoriq-43dfa07fbb6b8bd5b6173a5bab48470f578c8e5b.tar.xz |
[JFFS2] Deletion dirents should be REF_NORMAL, not REF_PRISTINE.
Otherwise they'll never actually get garbage-collected.
Noted by Jonathan Larmour.
Signed-off-by: David Woodhouse <dwmw2@infradead.org>
Diffstat (limited to 'fs/jffs2/write.c')
-rw-r--r-- | fs/jffs2/write.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/fs/jffs2/write.c b/fs/jffs2/write.c index 1406f2c..bc61859 100644 --- a/fs/jffs2/write.c +++ b/fs/jffs2/write.c @@ -296,7 +296,8 @@ struct jffs2_full_dirent *jffs2_write_dirent(struct jffs2_sb_info *c, struct jff return ERR_PTR(ret?ret:-EIO); } /* Mark the space used */ - fd->raw = jffs2_add_physical_node_ref(c, flash_ofs | REF_PRISTINE, PAD(sizeof(*rd)+namelen), f->inocache); + fd->raw = jffs2_add_physical_node_ref(c, flash_ofs | dirent_node_state(rd), + PAD(sizeof(*rd)+namelen), f->inocache); if (IS_ERR(fd->raw)) { void *hold_err = fd->raw; /* Release the full_dirent which is now useless, and return */ |