'ret' should be used a return value, thi patch fixes this error. Reported-by: kernel test robot <lkp@xxxxxxxxx> Signed-off-by: Coly Li <colyli@xxxxxxx> --- drivers/md/bcache/super.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/md/bcache/super.c b/drivers/md/bcache/super.c index c273eeef0d38..47a1225b3496 100644 --- a/drivers/md/bcache/super.c +++ b/drivers/md/bcache/super.c @@ -2554,7 +2554,7 @@ static ssize_t register_nvdimm_meta(struct kobject *k, struct kobj_attribute *at ret = -EINVAL; } - return size; + return ret; } #endif -- 2.26.2