Skip to content

Commit a491486

Browse files
Joakim Tjernlunddwmw2
authored andcommitted
[JFFS2] Obsolete dirent nodes immediately on unlink, where possible.
Signed-off-by: Joakim Tjernlund <Joakim.Tjernlund@transmode.se> Signed-off-by: David Woodhouse <dwmw2@infradead.org>
1 parent ec98c68 commit a491486

1 file changed

Lines changed: 1 addition & 2 deletions

File tree

‎fs/jffs2/write.c‎

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -507,8 +507,7 @@ int jffs2_do_unlink(struct jffs2_sb_info *c, struct jffs2_inode_info *dir_f,
507507
uint32_t alloclen;
508508
int ret;
509509

510-
if (1 /* alternative branch needs testing */ ||
511-
!jffs2_can_mark_obsolete(c)) {
510+
if (!jffs2_can_mark_obsolete(c)) {
512511
/* We can't mark stuff obsolete on the medium. We need to write a deletion dirent */
513512

514513
rd = jffs2_alloc_raw_dirent();

0 commit comments

Comments
 (0)