@@ -576,8 +576,7 @@ static struct dentry *f2fs_lookup(struct inode *dir, struct dentry *dentry,
576
576
goto out_iput ;
577
577
}
578
578
out_splice :
579
- #if IS_ENABLED (CONFIG_UNICODE )
580
- if (!inode && IS_CASEFOLDED (dir )) {
579
+ if (IS_ENABLED (CONFIG_UNICODE ) && !inode && IS_CASEFOLDED (dir )) {
581
580
/* Eventually we want to call d_add_ci(dentry, NULL)
582
581
* for negative dentries in the encoding case as
583
582
* well. For now, prevent the negative dentry
@@ -586,7 +585,7 @@ static struct dentry *f2fs_lookup(struct inode *dir, struct dentry *dentry,
586
585
trace_f2fs_lookup_end (dir , dentry , ino , err );
587
586
return NULL ;
588
587
}
589
- #endif
588
+
590
589
new = d_splice_alias (inode , dentry );
591
590
trace_f2fs_lookup_end (dir , !IS_ERR_OR_NULL (new ) ? new : dentry ,
592
591
ino , IS_ERR (new ) ? PTR_ERR (new ) : err );
@@ -639,16 +638,15 @@ static int f2fs_unlink(struct inode *dir, struct dentry *dentry)
639
638
f2fs_delete_entry (de , page , dir , inode );
640
639
f2fs_unlock_op (sbi );
641
640
642
- #if IS_ENABLED (CONFIG_UNICODE )
643
641
/* VFS negative dentries are incompatible with Encoding and
644
642
* Case-insensitiveness. Eventually we'll want avoid
645
643
* invalidating the dentries here, alongside with returning the
646
644
* negative dentries at f2fs_lookup(), when it is better
647
645
* supported by the VFS for the CI case.
648
646
*/
649
- if (IS_CASEFOLDED (dir ))
647
+ if (IS_ENABLED ( CONFIG_UNICODE ) && IS_CASEFOLDED (dir ))
650
648
d_invalidate (dentry );
651
- #endif
649
+
652
650
if (IS_DIRSYNC (dir ))
653
651
f2fs_sync_fs (sbi -> sb , 1 );
654
652
fail :
0 commit comments