/linux-6.6.21/block/ |
D | blk-settings.c | 51 lim->discard_granularity = 0; in blk_set_default_limits() 510 granularity = lim->discard_granularity >> SECTOR_SHIFT; in queue_limit_discard_alignment() 662 if (b->discard_granularity) { in blk_stack_limits() 665 if (t->discard_granularity != 0 && in blk_stack_limits() 667 top = t->discard_granularity + t->discard_alignment; in blk_stack_limits() 668 bottom = b->discard_granularity + alignment; in blk_stack_limits() 679 t->discard_granularity = max(t->discard_granularity, in blk_stack_limits() 680 b->discard_granularity); in blk_stack_limits() 682 t->discard_granularity; in blk_stack_limits()
|
D | blk-lib.c | 15 unsigned int discard_granularity = bdev_discard_granularity(bdev); in bio_discard_limit() local 22 round_up(sector, discard_granularity >> SECTOR_SHIFT); in bio_discard_limit() 35 return round_down(UINT_MAX, discard_granularity) >> SECTOR_SHIFT; in bio_discard_limit()
|
D | blk-sysfs.c | 158 return queue_var_show(q->limits.discard_granularity, page); in queue_discard_granularity_show() 183 if (max_discard & (q->limits.discard_granularity - 1)) in queue_discard_max_store()
|
/linux-6.6.21/drivers/md/ |
D | dm-zero.c | 66 limits->discard_granularity = 512; in zero_io_hints()
|
D | dm-target.c | 156 limits->discard_granularity = 512; in io_err_io_hints()
|
D | dm-clone-target.c | 2052 limits->discard_granularity = clone->region_size << SECTOR_SHIFT; in set_discard_limits() 2064 limits->discard_granularity = dest_limits->discard_granularity; in set_discard_limits()
|
D | dm-cache-target.c | 3399 limits->discard_granularity = cache->discard_block_size << SECTOR_SHIFT; in set_discard_limits() 3409 limits->discard_granularity = origin_limits->discard_granularity; in set_discard_limits()
|
D | dm-log-writes.c | 873 limits->discard_granularity = lc->sectorsize; in log_writes_io_hints()
|
/linux-6.6.21/drivers/block/ |
D | virtio_blk.c | 1312 u32 discard_granularity = 0; in virtblk_probe() local 1472 discard_sector_alignment, &discard_granularity); in virtblk_probe() 1515 discard_granularity = min_not_zero(discard_granularity, v); in virtblk_probe() 1561 if (discard_granularity) in virtblk_probe() 1562 q->limits.discard_granularity = discard_granularity << SECTOR_SHIFT; in virtblk_probe() 1564 q->limits.discard_granularity = blk_size; in virtblk_probe()
|
D | xen-blkfront.c | 221 unsigned int discard_granularity; member 955 rq->limits.discard_granularity = info->discard_granularity ?: in blkif_set_queue_limits() 2149 info->discard_granularity = xenbus_read_unsigned(info->xbdev->otherend, in blkfront_setup_discard()
|
D | ublk_drv.c | 532 q->limits.discard_granularity = p->discard_granularity; in ublk_dev_param_discard_apply() 566 if (!p->discard_granularity) in ublk_validate_params()
|
D | nbd.c | 338 nbd->disk->queue->limits.discard_granularity = blksize; in nbd_set_size() 1356 nbd->disk->queue->limits.discard_granularity = 0; in nbd_config_put() 1849 disk->queue->limits.discard_granularity = 0; in nbd_dev_add()
|
/linux-6.6.21/drivers/block/rnbd/ |
D | rnbd-proto.h | 150 __le32 discard_granularity; member
|
D | rnbd-clt.c | 1350 dev->queue->limits.discard_granularity = in setup_request_queue() 1351 le32_to_cpu(rsp->discard_granularity); in setup_request_queue() 1634 le32_to_cpu(rsp->discard_granularity), in rnbd_clt_map_device()
|
D | rnbd-srv.c | 549 rsp->discard_granularity = cpu_to_le32(bdev_discard_granularity(bdev)); in rnbd_srv_fill_msg_open_rsp()
|
/linux-6.6.21/include/uapi/linux/ |
D | ublk_cmd.h | 352 __u32 discard_granularity; member
|
/linux-6.6.21/drivers/mmc/core/ |
D | queue.c | 187 q->limits.discard_granularity = card->pref_erase << 9; in mmc_queue_setup_discard() 190 q->limits.discard_granularity = SECTOR_SIZE; in mmc_queue_setup_discard()
|
/linux-6.6.21/drivers/block/drbd/ |
D | drbd_worker.c | 596 int discard_granularity = 0; in make_resync_request() local 618 discard_granularity = rcu_dereference(device->ldev->disk_conf)->rs_discard_granularity; in make_resync_request() 686 if (discard_granularity && size == discard_granularity) in make_resync_request() 736 size == discard_granularity ? P_RS_THIN_REQ : P_RS_DATA_REQUEST, in make_resync_request()
|
D | drbd_nl.c | 1194 q->limits.discard_granularity = granularity; in blk_queue_discard_granularity() 1262 unsigned int discard_granularity = in fixup_discard_support() local 1263 device->rq_queue->limits.discard_granularity >> SECTOR_SHIFT; in fixup_discard_support() 1265 if (discard_granularity > max_discard) { in fixup_discard_support() 1459 unsigned int discard_granularity = bdev_discard_granularity(bdev); in sanitize_disk_conf() local 1462 if (discard_granularity > disk_conf->rs_discard_granularity) in sanitize_disk_conf() 1463 disk_conf->rs_discard_granularity = discard_granularity; in sanitize_disk_conf() 1466 discard_granularity; in sanitize_disk_conf()
|
/linux-6.6.21/fs/ntfs3/ |
D | super.c | 1189 sbi->discard_granularity = bdev_discard_granularity(bdev); in ntfs_fill_super() 1191 ~(u64)(sbi->discard_granularity - 1); in ntfs_fill_super() 1675 start = (lbo + sbi->discard_granularity - 1) & in ntfs_discard()
|
/linux-6.6.21/Documentation/ABI/stable/ |
D | sysfs-block | 216 What: /sys/block/<disk>/queue/discard_granularity 222 block size. The discard_granularity parameter indicates the size 224 device. Otherwise the discard_granularity will be set to match 225 the device's physical block size. A discard_granularity of 0
|
/linux-6.6.21/include/linux/ |
D | blkdev.h | 308 unsigned int discard_granularity; member 1211 return bdev_get_queue(bdev)->limits.discard_granularity; in bdev_discard_granularity()
|
/linux-6.6.21/drivers/mtd/ |
D | mtd_blkdevs.c | 381 new->rq->limits.discard_granularity = tr->blksize; in add_mtd_blktrans_dev()
|
/linux-6.6.21/fs/f2fs/ |
D | sysfs.c | 927 DCC_INFO_GENERAL_RW_ATTR(discard_granularity); 1075 ATTR_LIST(discard_granularity),
|
/linux-6.6.21/drivers/s390/block/ |
D | dasd_fba.c | 784 q->limits.discard_granularity = logical_block_size; in dasd_fba_setup_blk_queue()
|