module/raid: fix incorrect error code

Signed-off-by: paul luse <paul.e.luse@intel.com>
Change-Id: I00212580ad8ffc1ddc77e8922e35b84422cae466
Reviewed-on: https://review.gerrithub.io/c/spdk/spdk/+/468905
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Reviewed-by: Shuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com>
Reviewed-by: Jim Harris <james.r.harris@intel.com>
This commit is contained in:
paul luse 2019-09-19 19:15:33 -04:00 committed by Jim Harris
parent 3b128baead
commit a77217feb8

View File

@ -1570,7 +1570,7 @@ raid_bdev_create(struct raid_bdev_config *raid_cfg)
default:
SPDK_ERRLOG("invalid raid level %u\n", raid_bdev->raid_level);
free(raid_bdev);
return -ENOMEM;
return -EINVAL;
}
raid_bdev_gen = &raid_bdev->bdev;