提交 b568be62 编写于 作者: J Jens Axboe

block: temporarily disable discard granularity

Commit 86b37281 adds a check for
misaligned stacking offsets, but it's buggy since the defaults are 0.
Hence all dm devices that pass in a non-zero starting offset will
be marked as misaligned amd dm will complain.

A real fix is coming, in the mean time disable the discard granularity
check so that users don't worry about dm reporting about misaligned
devices.
Signed-off-by: NJens Axboe <jens.axboe@oracle.com>
上级 8bea8672
......@@ -554,11 +554,18 @@ int blk_stack_limits(struct queue_limits *t, struct queue_limits *b,
ret = -1;
}
/*
* Temporarily disable discard granularity. It's currently buggy
* since we default to 0 for discard_granularity, hence this
* "failure" will always trigger for non-zero offsets.
*/
#if 0
if (offset &&
(offset & (b->discard_granularity - 1)) != b->discard_alignment) {
t->discard_misaligned = 1;
ret = -1;
}
#endif
/* If top has no alignment offset, inherit from bottom */
if (!t->alignment_offset)
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册