diff --git a/fs/f2fs/node.h b/fs/f2fs/node.h index 6aea13024ac1..7371c09174cb 100644 --- a/fs/f2fs/node.h +++ b/fs/f2fs/node.h @@ -105,6 +105,7 @@ static inline bool get_nat_flag(struct nat_entry *ne, unsigned int type) static inline void nat_reset_flag(struct nat_entry *ne) { + ne->ni.flag = 0; /* these states can be set only after checkpoint was done */ set_nat_flag(ne, IS_CHECKPOINTED, true); set_nat_flag(ne, HAS_FSYNCED_INODE, false); @@ -117,6 +118,7 @@ static inline void node_info_from_raw_nat(struct node_info *ni, ni->ino = le32_to_cpu(raw_ne->ino); ni->blk_addr = le32_to_cpu(raw_ne->block_addr); ni->version = raw_ne->version; + ni->flag = 0; } static inline void raw_nat_from_node_info(struct f2fs_nat_entry *raw_ne,