aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/md/dm-thin.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/md/dm-thin.c')
-rw-r--r--drivers/md/dm-thin.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/drivers/md/dm-thin.c b/drivers/md/dm-thin.c
index 493478989dbd..07705ee181e3 100644
--- a/drivers/md/dm-thin.c
+++ b/drivers/md/dm-thin.c
@@ -3385,6 +3385,12 @@ static int pool_message(struct dm_target *ti, unsigned argc, char **argv)
3385 struct pool_c *pt = ti->private; 3385 struct pool_c *pt = ti->private;
3386 struct pool *pool = pt->pool; 3386 struct pool *pool = pt->pool;
3387 3387
3388 if (get_pool_mode(pool) >= PM_READ_ONLY) {
3389 DMERR("%s: unable to service pool target messages in READ_ONLY or FAIL mode",
3390 dm_device_name(pool->pool_md));
3391 return -EINVAL;
3392 }
3393
3388 if (!strcasecmp(argv[0], "create_thin")) 3394 if (!strcasecmp(argv[0], "create_thin"))
3389 r = process_create_thin_mesg(argc, argv, pool); 3395 r = process_create_thin_mesg(argc, argv, pool);
3390 3396