Lines Matching refs:block

22  * On-disk super block magic.
30 * On disk super block.
31 * This uses only 512 B but uses on disk a full 4KB block. This block is
33 * blocks indicating zone block validity.
35 * (1) Super block (1 block)
51 /* This block number */
54 /* The number of metadata blocks, including this super block */
66 /* The number of blocks used for the block bitmaps */
99 * Chunk mapping table metadata: 512 8-bytes entries per 4KB block.
107 * Meta data block descriptor (for cached metadata blocks).
120 * Metadata block state flags.
130 * Super block information (one per metadata set).
133 sector_t block;
404 * Allocate a metadata block.
426 /* Allocate a new block */
450 * Free a metadata block.
461 * Insert a metadata block in the rbtree.
482 * Lookup a metadata block in the rbtree. If the block is found, increment
496 * If this is the first reference to the block,
512 * Metadata block BIO end callback.
535 * Read an uncached metadata block from disk and add it to the cache.
541 sector_t block = zmd->sb[zmd->mblk_primary].block + mblk_no;
548 /* Get a new block and a BIO to read it */
560 * the block already.
577 bio->bi_iter.bi_sector = dmz_blk2sect(block);
640 * Release a metadata block.
666 * Get a metadata block from the rbtree. If the block
681 /* Cache miss: read the block from disk */
700 * Mark a metadata block dirty.
711 * Issue a metadata block write BIO.
717 sector_t block = zmd->sb[set].block + mblk->no;
728 bio->bi_iter.bi_sector = dmz_blk2sect(block);
738 * Read/write a metadata block.
741 sector_t block, struct page *page)
754 bio->bi_iter.bi_sector = dmz_blk2sect(block);
765 * Write super block of the specified metadata set.
789 * The metadata always references the absolute block address,
790 * ie relative to the entire block range, not the per-device
791 * block address.
805 ret = dmz_rdwr_block(dev, REQ_OP_WRITE, zmd->sb[set].block,
872 * log index super block generation.
977 * Check super block.
1096 * Read the first or second super block from disk.
1100 dmz_zmd_debug(zmd, "read superblock set %d dev %pg block %llu",
1101 set, sb->dev->bdev, sb->block);
1104 sb->block, sb->mblk->page);
1109 * This is used only if a corruption of the primary super block
1119 /* Allocate a block */
1127 /* Bad first super block: search for the second one */
1128 zmd->sb[1].block = zmd->sb[0].block + zone_nr_blocks;
1136 zmd->sb[1].block += zone_nr_blocks;
1149 * Read a super block from disk.
1156 /* Allocate a block */
1164 /* Read super block */
1188 zmd->sb[0].block = dmz_start_block(zmd, zmd->sb[0].zone);
1190 zmd->sb[1].block = dmz_start_block(zmd, zmd->sb[1].zone);
1199 zmd->sb[src_set].block + i, page);
1203 zmd->sb[dst_set].block + i, page);
1208 /* Finalize with the super block */
1226 * Get super block from disk.
1235 dmz_zmd_err(zmd, "Primary super block zone not set");
1239 /* Read and check the primary super block */
1240 zmd->sb[0].block = dmz_start_block(zmd, zmd->sb[0].zone);
1244 dmz_dev_err(zmd->sb[0].dev, "Read primary super block failed");
1250 /* Read and check secondary super block */
1259 zmd->sb[1].block = dmz_start_block(zmd, zmd->sb[1].zone);
1266 dmz_dev_err(zmd->sb[1].dev, "Read secondary super block failed");
1276 dmz_zmd_err(zmd, "No valid super block found");
1312 "Using super block %u (gen %llu)",
1323 sb->block = 0;
1328 "Tertiary super block zone %u not marked as metadata zone",
1336 "Read tertiary super block failed");
1408 /* Primary super block zone */
1544 * time, determine where the super block should be: first block of the
1693 /* Metadata block array for the chunk mapping table */
1702 /* Get mapping block */
2124 * Write and discard change the block validity of data zones and their buffer
2401 * Get the bitmap block storing the bit for chunk_block in zone.
2477 * Validate all the blocks in the range [block..block+nr_blocks-1].
2487 dmz_zmd_debug(zmd, "=> VALIDATE zone %u, block %llu, %u blocks",
2494 /* Get bitmap block */
2558 * Invalidate all the blocks in the range [block..block+nr_blocks-1].
2567 dmz_zmd_debug(zmd, "=> INVALIDATE zone %u, block %llu, %u blocks",
2573 /* Get bitmap block */
2606 * Get a block bit value.
2616 /* Get bitmap block */
2631 * Return the number of blocks from chunk_block to the first block with a bit
2647 /* Get bitmap block */
2686 /* The block is valid: get the number of valid blocks from block */
2692 * Find the first valid block from @chunk_block in @zone.
2693 * If such a block is found, its number is returned using
2756 /* Get bitmap block */
2763 /* Count bits in this block */
2843 dmz_dev_info(dev, "Regular block device");
2845 dmz_dev_info(dev, "Host-managed zoned block device");
2906 /* Get super block */