/* * Addresses of records, keys, and pointers within an incore rtrmapbt block. * * (note that some of these may appear unused, but they are used in userspace)
*/ staticinlinestruct xfs_rmap_rec *
xfs_rtrmap_rec_addr( struct xfs_btree_block *block, unsignedint index)
{ return (struct xfs_rmap_rec *)
((char *)block + XFS_RTRMAP_BLOCK_LEN +
(index - 1) * sizeof(struct xfs_rmap_rec));
}
/* * Address of pointers within the incore btree root. * * These are to be used when we know the size of the block and * we don't have a cursor.
*/ staticinline xfs_rtrmap_ptr_t *
xfs_rtrmap_broot_ptr_addr( struct xfs_mount *mp, struct xfs_btree_block *bb, unsignedint index, unsignedint block_size)
{ return xfs_rtrmap_ptr_addr(bb, index,
xfs_rtrmapbt_maxrecs(mp, block_size, false));
}
/* * Compute the space required for the incore btree root containing the given * number of records.
*/ staticinline size_t
xfs_rtrmap_broot_space_calc( struct xfs_mount *mp, unsignedint level, unsignedint nrecs)
{
size_t sz = XFS_RTRMAP_BLOCK_LEN;
/* * Compute the space required for the ondisk root block given an incore root * block.
*/ staticinline size_t
xfs_rtrmap_droot_space(struct xfs_btree_block *bb)
{ return xfs_rtrmap_droot_space_calc(be16_to_cpu(bb->bb_level),
be16_to_cpu(bb->bb_numrecs));
}
Die Informationen auf dieser Webseite wurden
nach bestem Wissen sorgfältig zusammengestellt. Es wird jedoch weder Vollständigkeit, noch Richtigkeit,
noch Qualität der bereit gestellten Informationen zugesichert.
Bemerkung:
Die farbliche Syntaxdarstellung und die Messung sind noch experimentell.