Lines Matching refs:logical_sector
264 sector_t logical_sector; member
1094 return range1->logical_sector < range2->logical_sector + range2->n_sectors && in ranges_overlap()
1095 range1->logical_sector + range1->n_sectors > range2->logical_sector; in ranges_overlap()
1103 BUG_ON((new_range->logical_sector | new_range->n_sectors) & (unsigned)(ic->sectors_per_block - 1)); in add_new_range()
1119 if (new_range->logical_sector + new_range->n_sectors <= range->logical_sector) { in add_new_range()
1121 } else if (new_range->logical_sector >= range->logical_sector + range->n_sectors) { in add_new_range()
1434 dio->range.logical_sector += dio->range.n_sectors; in dec_in_flight()
1524 sector_t sector = dio->range.logical_sector; in integrity_metadata()
1634 dio->range.logical_sector = dm_target_offset(ti, bio->bi_iter.bi_sector); in dm_integrity_map()
1644 if (unlikely(dio->range.logical_sector + bio_sectors(bio) > ic->provided_data_sectors)) { in dm_integrity_map()
1646 (unsigned long long)dio->range.logical_sector, bio_sectors(bio), in dm_integrity_map()
1650 …if (unlikely((dio->range.logical_sector | bio_sectors(bio)) & (unsigned)(ic->sectors_per_block - 1… in dm_integrity_map()
1653 (unsigned long long)dio->range.logical_sector, bio_sectors(bio)); in dm_integrity_map()
1693 get_area_and_offset(ic, dio->range.logical_sector, &area, &offset); in dm_integrity_map()
1705 sector_t logical_sector; in __journal_read_write() local
1708 logical_sector = dio->range.logical_sector; in __journal_read_write()
1739 BUG_ON(journal_entry_get_sector(je) != logical_sector); in __journal_read_write()
1753 integrity_sector_checksum(ic, logical_sector, mem + bv.bv_offset, checksums_onstack); in __journal_read_write()
1756 (unsigned long long)logical_sector); in __journal_read_write()
1802 integrity_sector_checksum(ic, logical_sector, (char *)js, checksums_onstack); in __journal_read_write()
1805 integrity_sector_checksum(ic, logical_sector, (char *)js, journal_entry_tag(ic, je)); in __journal_read_write()
1808 journal_entry_set_sector(je, logical_sector); in __journal_read_write()
1810 logical_sector += ic->sectors_per_block; in __journal_read_write()
1843 dio->range.logical_sector = logical_sector; in __journal_read_write()
1844 get_area_and_offset(ic, dio->range.logical_sector, &area, &offset); in __journal_read_write()
1908 add_journal_node(ic, &ic->journal_tree[pos], dio->range.logical_sector + i); in dm_integrity_map_continue()
1928 journal_read_pos = find_journal_node(ic, dio->range.logical_sector, &next_sector); in dm_integrity_map_continue()
1930 if (unlikely(dio->range.n_sectors > next_sector - dio->range.logical_sector)) in dm_integrity_map_continue()
1931 dio->range.n_sectors = next_sector - dio->range.logical_sector; in dm_integrity_map_continue()
1936 if (!test_journal_node(ic, jp, dio->range.logical_sector + i)) in dm_integrity_map_continue()
1966 unsigned new_pos = find_journal_node(ic, dio->range.logical_sector, &next_sector); in dm_integrity_map_continue()
1982 if (!block_bitmap_op(ic, ic->may_write_bitmap, dio->range.logical_sector, in dm_integrity_map_continue()
1986 bbs = sector_to_bitmap_block(ic, dio->range.logical_sector); in dm_integrity_map_continue()
2022 dio->range.logical_sector + dio->range.n_sectors > le64_to_cpu(ic->sb->recalc_sector)) in dm_integrity_map_continue()
2025 if (!block_bitmap_op(ic, ic->recalc_bitmap, dio->range.logical_sector, in dm_integrity_map_continue()
2221 io->range.logical_sector = sec; in do_journal_write()
2362 sector_t logical_sector, n_sectors; in integrity_recalc() local
2377 range.logical_sector = le64_to_cpu(ic->sb->recalc_sector); in integrity_recalc()
2378 if (unlikely(range.logical_sector >= ic->provided_data_sectors)) { in integrity_recalc()
2386 get_area_and_offset(ic, range.logical_sector, &area, &offset); in integrity_recalc()
2387 range.n_sectors = min((sector_t)RECALC_SECTORS, ic->provided_data_sectors - range.logical_sector); in integrity_recalc()
2393 logical_sector = range.logical_sector; in integrity_recalc()
2397 if (block_bitmap_op(ic, ic->recalc_bitmap, logical_sector, n_sectors, BITMAP_OP_TEST_ALL_CLEAR)) { in integrity_recalc()
2400 while (block_bitmap_op(ic, ic->recalc_bitmap, logical_sector, in integrity_recalc()
2402 logical_sector += ic->sectors_per_block; in integrity_recalc()
2406 while (block_bitmap_op(ic, ic->recalc_bitmap, logical_sector + n_sectors - ic->sectors_per_block, in integrity_recalc()
2411 get_area_and_offset(ic, logical_sector, &area, &offset); in integrity_recalc()
2414 DEBUG_print("recalculating: %lx, %lx\n", logical_sector, n_sectors); in integrity_recalc()
2445 integrity_sector_checksum(ic, logical_sector + i, ic->recalc_buffer + (i << SECTOR_SHIFT), t); in integrity_recalc()
2462 ic->sb->recalc_sector = cpu_to_le64(range.logical_sector + range.n_sectors); in integrity_recalc()
2495 if (block_bitmap_op(ic, ic->may_write_bitmap, dio->range.logical_sector, in bitmap_block_work()
2501 block_bitmap_op(ic, ic->journal, dio->range.logical_sector, in bitmap_block_work()
2517 block_bitmap_op(ic, ic->may_write_bitmap, dio->range.logical_sector, in bitmap_block_work()
2537 range.logical_sector = 0; in bitmap_flush_work()