qnx4_nxtnt_t nxtnt = le16_to_cpu(qnx4_inode->di_num_xtnts); 
u16 nxtnt = le16_to_cpu(qnx4_inode->di_num_xtnts); 
unsigned long qnx4_block_map( struct inode *inode, long iblock ){	int ix;	long offset, i_xblk;	unsigned long block = 0;	struct buffer_head *bh = NULL;	struct qnx4_xblk *xblk = NULL;	struct qnx4_inode_entry *qnx4_inode = qnx4_raw_inode(inode);	qnx4_nxtnt_t nxtnt = le16_to_cpu(qnx4_inode->di_num_xtnts);	if ( iblock < le32_to_cpu(qnx4_inode->di_first_xtnt.xtnt_size) ) {		// iblock is in the first extent. This is easy.		block = le32_to_cpu(qnx4_inode->di_first_xtnt.xtnt_blk) + iblock - 1;	} else {		// iblock is beyond first extent. We have to follow the extent chain.		i_xblk = le32_to_cpu(qnx4_inode->di_xblk);		offset = iblock - le32_to_cpu(qnx4_inode->di_first_xtnt.xtnt_size);		ix = 0;		while ( --nxtnt > 0 ) {			if ( ix == 0 ) {				// read next xtnt block.				bh = sb_bread(inode->i_sb, i_xblk - 1);				if ( !bh ) {					QNX4DEBUG(("qnx4: I/O error reading xtnt block [%ld])\n", i_xblk - 1));					return -EIO;				}				xblk = (struct qnx4_xblk*)bh->b_data;				if ( memcmp( xblk->xblk_signature, "IamXblk", 7 ) ) {					QNX4DEBUG(("qnx4: block at %ld is not a valid xtnt\n", qnx4_inode->i_xblk));					return -EIO;				}			}			if ( offset < le32_to_cpu(xblk->xblk_xtnts[ix].xtnt_size) ) {				// got it!				block = le32_to_cpu(xblk->xblk_xtnts[ix].xtnt_blk) + offset - 1;				break;			}			offset -= le32_to_cpu(xblk->xblk_xtnts[ix].xtnt_size);			if ( ++ix >= xblk->xblk_num_xtnts ) {				i_xblk = le32_to_cpu(xblk->xblk_next_xblk);				ix = 0;				brelse( bh );				bh = NULL;			}		}		if ( bh )			brelse( bh );	}	QNX4DEBUG(("qnx4: mapping block %ld of inode %ld = %ld\n",iblock,inode->i_ino,block));	return block;}
10457	/local/tlutelli/issta_data/temp/c/2005_temp/2005/10457/75043cb5b386e5a01fd03b88f647dd992de02f97/inode.c/clean/fs/qnx4/inode.c