From 16b1493df0d926317268edde9de2ad195582e9fc Mon Sep 17 00:00:00 2001 From: Kent Overstreet Date: Thu, 11 Aug 2016 08:08:55 -0800 Subject: bcache: disable compressed_size disk space accounting until copygc issue fixed --- drivers/md/bcache/buckets.c | 14 ++++++++++++++ 1 file changed, 14 insertions(+) diff --git a/drivers/md/bcache/buckets.c b/drivers/md/bcache/buckets.c index d7c37223bcfd..c742e520b4a5 100644 --- a/drivers/md/bcache/buckets.c +++ b/drivers/md/bcache/buckets.c @@ -357,6 +357,9 @@ do { \ } \ } while (0) +#if 0 +/* Reverting this until the copygc + compression issue is fixed: */ + static unsigned __disk_sectors(struct bch_extent_crc64 crc, unsigned sectors) { return crc.compression_type @@ -370,6 +373,17 @@ static unsigned __compressed_sectors(struct bch_extent_crc64 crc, unsigned secto ? min_t(unsigned, crc.compressed_size, sectors) : sectors; } +#else +static unsigned __disk_sectors(struct bch_extent_crc64 crc, unsigned sectors) +{ + return sectors; +} + +static unsigned __compressed_sectors(struct bch_extent_crc64 crc, unsigned sectors) +{ + return sectors; +} +#endif /* * Checking against gc's position has to be done here, inside the cmpxchg() -- cgit v1.2.3