提交 bd0fc288 编写于 作者: M Minfei Huang 提交者: Jens Axboe

nvme: use UINT_MAX for max discard sectors

It's more elegant to use UINT_MAX to represent the max value of
type unsigned int. So replace the actual value by using this define.
Signed-off-by: NMinfei Huang <mnghuan@gmail.com>
Signed-off-by: NJens Axboe <axboe@fb.com>
上级 c55a2fd4
......@@ -781,7 +781,7 @@ static void nvme_config_discard(struct nvme_ns *ns)
ns->queue->limits.discard_alignment = logical_block_size;
ns->queue->limits.discard_granularity = logical_block_size;
blk_queue_max_discard_sectors(ns->queue, 0xffffffff);
blk_queue_max_discard_sectors(ns->queue, UINT_MAX);
queue_flag_set_unlocked(QUEUE_FLAG_DISCARD, ns->queue);
}
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册