Lines Matching refs:bh
41 struct buffer_head *bh; in qnx4_sync_inode()
43 bh = qnx4_update_inode(inode); in qnx4_sync_inode()
44 if (bh && buffer_dirty(bh)) in qnx4_sync_inode()
46 ll_rw_block(WRITE, 1, &bh); in qnx4_sync_inode()
47 wait_on_buffer(bh); in qnx4_sync_inode()
48 if (buffer_req(bh) && !buffer_uptodate(bh)) in qnx4_sync_inode()
54 brelse (bh); in qnx4_sync_inode()
55 } else if (!bh) { in qnx4_sync_inode()
83 struct buffer_head *bh; in qnx4_write_inode() local
98 if (!(bh = sb_bread(inode->i_sb, block))) { in qnx4_write_inode()
104 raw_inode = ((struct qnx4_inode_entry *) bh->b_data) + in qnx4_write_inode()
115 mark_buffer_dirty(bh); in qnx4_write_inode()
116 brelse(bh); in qnx4_write_inode()
191 struct buffer_head *bh; in qnx4_bread() local
193 bh = qnx4_getblk(inode, block, create); in qnx4_bread()
194 if (!bh || buffer_uptodate(bh)) { in qnx4_bread()
195 return bh; in qnx4_bread()
197 ll_rw_block(READ, 1, &bh); in qnx4_bread()
198 wait_on_buffer(bh); in qnx4_bread()
199 if (buffer_uptodate(bh)) { in qnx4_bread()
200 return bh; in qnx4_bread()
202 brelse(bh); in qnx4_bread()
207 int qnx4_get_block( struct inode *inode, long iblock, struct buffer_head *bh, int create ) in qnx4_get_block() argument
216 bh->b_dev = inode->i_dev; in qnx4_get_block()
217 bh->b_blocknr = phys; in qnx4_get_block()
218 bh->b_state |= (1UL << BH_Mapped); in qnx4_get_block()
230 struct buffer_head *bh = 0; in qnx4_block_map() local
246 bh = sb_bread(inode->i_sb, i_xblk - 1); in qnx4_block_map()
247 if ( !bh ) { in qnx4_block_map()
251 xblk = (struct qnx4_xblk*)bh->b_data; in qnx4_block_map()
266 brelse( bh ); in qnx4_block_map()
267 bh = 0; in qnx4_block_map()
270 if ( bh ) in qnx4_block_map()
271 brelse( bh ); in qnx4_block_map()
297 struct buffer_head *bh; in qnx4_checkroot() local
310 bh = sb_bread(sb, rd + j); /* root dir, first block */ in qnx4_checkroot()
311 if (bh == NULL) { in qnx4_checkroot()
315 rootdir = (struct qnx4_inode_entry *) (bh->b_data + i * QNX4_DIR_ENTRY_SIZE); in qnx4_checkroot()
322 brelse (bh); in qnx4_checkroot()
330 brelse(bh); in qnx4_checkroot()
345 struct buffer_head *bh; in qnx4_read_super() local
357 bh = sb_bread(s, 1); in qnx4_read_super()
358 if (!bh) { in qnx4_read_super()
362 if ( le32_to_cpu( *(__u32*)bh->b_data ) != QNX4_SUPER_MAGIC ) { in qnx4_read_super()
372 s->u.qnx4_sb.sb_buf = bh; in qnx4_read_super()
373 s->u.qnx4_sb.sb = (struct qnx4_super_block *) bh->b_data; in qnx4_read_super()
395 brelse(bh); in qnx4_read_super()
402 brelse(bh); in qnx4_read_super()
442 struct buffer_head *bh; in qnx4_read_inode() local
457 if (!(bh = sb_bread(inode->i_sb, block))) { in qnx4_read_inode()
462 raw_inode = ((struct qnx4_inode_entry *) bh->b_data) + in qnx4_read_inode()
491 brelse(bh); in qnx4_read_inode()