diff options
author | Al Viro <viro@zeniv.linux.org.uk> | 2012-02-13 20:57:12 -0500 |
---|---|---|
committer | Al Viro <viro@zeniv.linux.org.uk> | 2012-03-20 21:29:51 -0400 |
commit | 8f82ecae53347ec65721e1c0683c3f26647e3c97 (patch) | |
tree | 594d1064acfda1f44aa4eaf0a2fde01ada760b2c /fs/qnx4/namei.c | |
parent | 19e5109fef2c368ab3f8a5157270f87f4a7c0326 (diff) |
qnx4: get rid of qnx4_bread/qnx4_getblk
pointless, since the only caller will want the physical block
number anyway; might as well call qnx4_block_map() and use
sb_bread()
Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
Diffstat (limited to 'fs/qnx4/namei.c')
-rw-r--r-- | fs/qnx4/namei.c | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/fs/qnx4/namei.c b/fs/qnx4/namei.c index e8eb8784ed30..a512c0b30e8e 100644 --- a/fs/qnx4/namei.c +++ b/fs/qnx4/namei.c | |||
@@ -68,7 +68,9 @@ static struct buffer_head *qnx4_find_entry(int len, struct inode *dir, | |||
68 | block = offset = blkofs = 0; | 68 | block = offset = blkofs = 0; |
69 | while (blkofs * QNX4_BLOCK_SIZE + offset < dir->i_size) { | 69 | while (blkofs * QNX4_BLOCK_SIZE + offset < dir->i_size) { |
70 | if (!bh) { | 70 | if (!bh) { |
71 | bh = qnx4_bread(dir, blkofs, 0); | 71 | block = qnx4_block_map(dir, blkofs); |
72 | if (block) | ||
73 | bh = sb_bread(dir->i_sb, block); | ||
72 | if (!bh) { | 74 | if (!bh) { |
73 | blkofs++; | 75 | blkofs++; |
74 | continue; | 76 | continue; |
@@ -76,7 +78,6 @@ static struct buffer_head *qnx4_find_entry(int len, struct inode *dir, | |||
76 | } | 78 | } |
77 | *res_dir = (struct qnx4_inode_entry *) (bh->b_data + offset); | 79 | *res_dir = (struct qnx4_inode_entry *) (bh->b_data + offset); |
78 | if (qnx4_match(len, name, bh, &offset)) { | 80 | if (qnx4_match(len, name, bh, &offset)) { |
79 | block = qnx4_block_map( dir, blkofs ); | ||
80 | *ino = block * QNX4_INODES_PER_BLOCK + | 81 | *ino = block * QNX4_INODES_PER_BLOCK + |
81 | (offset / QNX4_DIR_ENTRY_SIZE) - 1; | 82 | (offset / QNX4_DIR_ENTRY_SIZE) - 1; |
82 | return bh; | 83 | return bh; |