Home
last modified time | relevance | path

Searched refs:max_discard (Results 1 – 4 of 4) sorted by relevance

/linux-6.6.21/drivers/mmc/core/
Dqueue.c180 unsigned max_discard; in mmc_queue_setup_discard() local
182 max_discard = mmc_calc_max_discard(card); in mmc_queue_setup_discard()
183 if (!max_discard) in mmc_queue_setup_discard()
186 blk_queue_max_discard_sectors(q, max_discard); in mmc_queue_setup_discard()
189 if (card->pref_erase > max_discard) in mmc_queue_setup_discard()
192 blk_queue_max_secure_erase_sectors(q, max_discard); in mmc_queue_setup_discard()
194 blk_queue_max_write_zeroes_sectors(q, max_discard); in mmc_queue_setup_discard()
Dcore.c1881 unsigned int max_discard, x, y, qty = 0, max_qty, min_qty, timeout; in mmc_do_calc_max_discard() local
1946 max_discard = qty << card->erase_shift; in mmc_do_calc_max_discard()
1948 max_discard = qty + 1; in mmc_do_calc_max_discard()
1950 max_discard = qty * card->erase_size; in mmc_do_calc_max_discard()
1952 return max_discard; in mmc_do_calc_max_discard()
1958 unsigned int max_discard, max_trim; in mmc_calc_max_discard() local
1968 max_discard = mmc_do_calc_max_discard(card, MMC_ERASE_ARG); in mmc_calc_max_discard()
1971 if (max_trim < max_discard || max_discard == 0) in mmc_calc_max_discard()
1972 max_discard = max_trim; in mmc_calc_max_discard()
1973 } else if (max_discard < card->erase_size) { in mmc_calc_max_discard()
[all …]
/linux-6.6.21/block/
Dblk-sysfs.c177 unsigned long max_discard; in queue_discard_max_store() local
178 ssize_t ret = queue_var_store(&max_discard, page, count); in queue_discard_max_store()
183 if (max_discard & (q->limits.discard_granularity - 1)) in queue_discard_max_store()
186 max_discard >>= 9; in queue_discard_max_store()
187 if (max_discard > UINT_MAX) in queue_discard_max_store()
190 if (max_discard > q->limits.max_hw_discard_sectors) in queue_discard_max_store()
191 max_discard = q->limits.max_hw_discard_sectors; in queue_discard_max_store()
193 q->limits.max_discard_sectors = max_discard; in queue_discard_max_store()
/linux-6.6.21/drivers/block/drbd/
Ddrbd_nl.c1261 unsigned int max_discard = device->rq_queue->limits.max_discard_sectors; in fixup_discard_support() local
1265 if (discard_granularity > max_discard) { in fixup_discard_support()