diff options
author | Ryusuke Konishi <konishi.ryusuke@lab.ntt.co.jp> | 2009-11-13 08:25:19 +0100 |
---|---|---|
committer | Ryusuke Konishi <konishi.ryusuke@lab.ntt.co.jp> | 2009-11-20 02:05:49 +0100 |
commit | 45f4910bc0bb904bcf53aa04ee1b807abe1387a6 (patch) | |
tree | d40f556ef778f9d4c2b37b4978fae29835de150d /fs/nilfs2/btnode.c | |
parent | nilfs2: separate function for creating new btree node block (diff) | |
download | linux-45f4910bc0bb904bcf53aa04ee1b807abe1387a6.tar.xz linux-45f4910bc0bb904bcf53aa04ee1b807abe1387a6.zip |
nilfs2: use nilfs_btnode_create_block function
This displaces nilfs_btnode_get() use to create new btree node block
with nilfs_btnode_create_block.
Signed-off-by: Ryusuke Konishi <konishi.ryusuke@lab.ntt.co.jp>
Diffstat (limited to 'fs/nilfs2/btnode.c')
-rw-r--r-- | fs/nilfs2/btnode.c | 13 |
1 files changed, 7 insertions, 6 deletions
diff --git a/fs/nilfs2/btnode.c b/fs/nilfs2/btnode.c index fc3e4bdb62ae..7086a2a1f7fa 100644 --- a/fs/nilfs2/btnode.c +++ b/fs/nilfs2/btnode.c @@ -270,12 +270,13 @@ retry: unlock_page(obh->b_page); } - err = nilfs_btnode_get(btnc, newkey, 0, &nbh, 1); - if (likely(!err)) { - BUG_ON(nbh == obh); - ctxt->newbh = nbh; - } - return err; + nbh = nilfs_btnode_create_block(btnc, newkey); + if (!nbh) + return -ENOMEM; + + BUG_ON(nbh == obh); + ctxt->newbh = nbh; + return 0; failed_unlock: unlock_page(obh->b_page); |