diff options
author | Kent Overstreet <kmo@daterainc.com> | 2014-02-11 02:26:40 +0100 |
---|---|---|
committer | Kent Overstreet <kmo@daterainc.com> | 2014-03-18 20:22:33 +0100 |
commit | 90db6919f5f1614d1b7a92052445506bc6c564d2 (patch) | |
tree | 61e0dca7d52529ce0dd13b77c1452592ddf781b4 /drivers/md | |
parent | bcache: Fix another bug recovering from unclean shutdown (diff) | |
download | linux-90db6919f5f1614d1b7a92052445506bc6c564d2.tar.xz linux-90db6919f5f1614d1b7a92052445506bc6c564d2.zip |
bcache: Fix discard granularity
blk_stack_limits() doesn't like a discard granularity of 0.
Signed-off-by: Kent Overstreet <kmo@daterainc.com>
Diffstat (limited to 'drivers/md')
-rw-r--r-- | drivers/md/bcache/super.c | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/drivers/md/bcache/super.c b/drivers/md/bcache/super.c index 5136e11eadb0..fb343276beef 100644 --- a/drivers/md/bcache/super.c +++ b/drivers/md/bcache/super.c @@ -843,6 +843,7 @@ static int bcache_device_init(struct bcache_device *d, unsigned block_size, q->limits.max_segment_size = UINT_MAX; q->limits.max_segments = BIO_MAX_PAGES; q->limits.max_discard_sectors = UINT_MAX; + q->limits.discard_granularity = 512; q->limits.io_min = block_size; q->limits.logical_block_size = block_size; q->limits.physical_block_size = block_size; |