Re: get_block

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Mon, May 18, 2009 at 09:32:48PM +0200, Alberich de megres wrote:
> Hi!
> 
> Again, i got another question this time is about get_block function
> used on "mpage_writepages" for address_space_operations writepage.
> 
> It is supposed to map the number of blocks passed in sector_t iblock
> parameter? or it is asking for the block number iblock?
> 
> thanks!!

iblock is the relative block # in the inode that you want to map.  Whatever you
set as bh_result->b_size is how much will be mapped, so its usually something
like

bh_result->b_size = num_of_blocks_we_want << inode->i_blkbits;

Hope that helps,

Josef
--
To unsubscribe from this list: send the line "unsubscribe linux-fsdevel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html

[Index of Archives]     [Linux Ext4 Filesystem]     [Union Filesystem]     [Filesystem Testing]     [Ceph Users]     [Ecryptfs]     [AutoFS]     [Kernel Newbies]     [Share Photos]     [Security]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux Cachefs]     [Reiser Filesystem]     [Linux RAID]     [Samba]     [Device Mapper]     [CEPH Development]
  Powered by Linux