@@ -211,6 +211,7 @@ struct pool_features {
bool discard_enabled:1;
bool discard_passdown:1;
bool error_if_no_space:1;
+ bool keep_bio_blkcg:1;
};
struct thin_c;
@@ -277,6 +278,7 @@ struct pool {
static enum pool_mode get_pool_mode(struct pool *pool);
static void metadata_operation_failed(struct pool *pool, const char *op, int r);
+static bool keep_pool_bio_blkcg(struct pool *pool);
/*
* Target context for a pool.
@@ -2390,6 +2392,11 @@ static void noflush_work(struct thin_c *tc, void (*fn)(struct work_struct *))
/*----------------------------------------------------------------*/
+static bool keep_pool_bio_blkcg(struct pool *pool)
+{
+ return pool->pf.keep_bio_blkcg;
+}
+
static enum pool_mode get_pool_mode(struct pool *pool)
{
return pool->pf.mode;
"keep_bio_blkcg" is used to control whether or not dm-thin needs to save the original blkcg of bio Signed-off-by: Hou Tao <houtao1@huawei.com> --- drivers/md/dm-thin.c | 7 +++++++ 1 file changed, 7 insertions(+)