Skip to content

Commit

Permalink
[JFFS2] Allocate node_ref for wasted space when skipping to page boun…
Browse files Browse the repository at this point in the history
…dary

One more place where we were changing the accounting info without
actually allocating a ref for the lost space...

Signed-off-by: David Woodhouse <dwmw2@infradead.org>
  • Loading branch information
David Woodhouse committed May 25, 2006
1 parent 12efdde commit f560928
Showing 1 changed file with 2 additions and 5 deletions.
7 changes: 2 additions & 5 deletions fs/jffs2/scan.c
Original file line number Diff line number Diff line change
Expand Up @@ -244,11 +244,8 @@ int jffs2_scan_medium(struct jffs2_sb_info *c)

D1(printk(KERN_DEBUG "jffs2_scan_medium(): Skipping %d bytes in nextblock to ensure page alignment\n",
skip));
c->nextblock->wasted_size += skip;
c->wasted_size += skip;

c->nextblock->free_size -= skip;
c->free_size -= skip;
jffs2_prealloc_raw_node_refs(c, 1);
jffs2_scan_dirty_space(c, c->nextblock, skip);
}
#endif
if (c->nr_erasing_blocks) {
Expand Down

0 comments on commit f560928

Please sign in to comment.