Skip to content

Commit

Permalink
Merge pull request torvalds#109 from hayley-leblanc/issue_100
Browse files Browse the repository at this point in the history
Fix crash consistency issue with alternate logs (torvalds#100)
  • Loading branch information
Andiry committed Jul 18, 2021
2 parents 587e252 + d09bcfc commit b04a2c8
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion fs/nova/log.c
Original file line number Diff line number Diff line change
Expand Up @@ -1184,7 +1184,6 @@ static int nova_initialize_inode_log(struct super_block *sb,
sih->log_pages++;
nova_flush_buffer(&pi->alter_log_head, CACHELINE_SIZE, 1);
}
nova_update_inode_checksum(pi);
nova_memlock_inode(sb, pi, &irq_flags);

return 0;
Expand Down Expand Up @@ -1221,6 +1220,10 @@ static u64 nova_extend_inode_log(struct super_block *sb, struct nova_inode *pi,
nova_memlock_inode(sb, pi, &irq_flags);
}

nova_memunlock_inode(sb, pi, &irq_flags);
nova_update_inode_checksum(pi);
nova_memlock_inode(sb, pi, &irq_flags);

return sih->log_head;
}

Expand Down

0 comments on commit b04a2c8

Please sign in to comment.