diff options
author | David Woodhouse <dwmw2@infradead.org> | 2006-05-24 20:50:35 -0400 |
---|---|---|
committer | David Woodhouse <dwmw2@infradead.org> | 2006-05-24 20:50:35 -0400 |
commit | 046b8b9808127d63326a33bc6298c90eaee90eeb (patch) | |
tree | 93caaabd7ae10969acb4758634b9b1c9448ef951 /fs/jffs2/wbuf.c | |
parent | f61579c33736476e41e296a16c0d4ead4b953187 (diff) |
[JFFS2] Add 'jeb' argument to jffs2_prealloc_raw_node_refs()
Preallocation of refs is shortly going to be a per-eraseblock thing,
rather than per-filesystem. Add the required argument to the function.
Signed-off-by: David Woodhouse <dwmw2@infradead.org>
Diffstat (limited to 'fs/jffs2/wbuf.c')
-rw-r--r-- | fs/jffs2/wbuf.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/fs/jffs2/wbuf.c b/fs/jffs2/wbuf.c index 1871140e1e78..e16e45ea0474 100644 --- a/fs/jffs2/wbuf.c +++ b/fs/jffs2/wbuf.c | |||
@@ -179,13 +179,13 @@ static void jffs2_wbuf_recover(struct jffs2_sb_info *c) | |||
179 | unsigned char *buf; | 179 | unsigned char *buf; |
180 | uint32_t start, end, ofs, len; | 180 | uint32_t start, end, ofs, len; |
181 | 181 | ||
182 | if (jffs2_prealloc_raw_node_refs(c, c->reserved_refs + 1)) | 182 | jeb = &c->blocks[c->wbuf_ofs / c->sector_size]; |
183 | |||
184 | if (jffs2_prealloc_raw_node_refs(c, jeb, c->reserved_refs + 1)) | ||
183 | return; | 185 | return; |
184 | 186 | ||
185 | spin_lock(&c->erase_completion_lock); | 187 | spin_lock(&c->erase_completion_lock); |
186 | 188 | ||
187 | jeb = &c->blocks[c->wbuf_ofs / c->sector_size]; | ||
188 | |||
189 | jffs2_block_refile(c, jeb, REFILE_NOTEMPTY); | 189 | jffs2_block_refile(c, jeb, REFILE_NOTEMPTY); |
190 | 190 | ||
191 | /* Find the first node to be recovered, by skipping over every | 191 | /* Find the first node to be recovered, by skipping over every |
@@ -417,7 +417,7 @@ static int __jffs2_flush_wbuf(struct jffs2_sb_info *c, int pad) | |||
417 | if (!c->wbuf_len) /* already checked c->wbuf above */ | 417 | if (!c->wbuf_len) /* already checked c->wbuf above */ |
418 | return 0; | 418 | return 0; |
419 | 419 | ||
420 | if (jffs2_prealloc_raw_node_refs(c, c->reserved_refs + 1)) | 420 | if (jffs2_prealloc_raw_node_refs(c, c->nextblock, c->reserved_refs + 1)) |
421 | return -ENOMEM; | 421 | return -ENOMEM; |
422 | 422 | ||
423 | /* claim remaining space on the page | 423 | /* claim remaining space on the page |