lib/lvol: bad cluster size error message
As spdk_lvs_init() validates arguments, it uses o->cluster_sz in a comparison but misleadingly prints opts.cluster_sz in the error message. This changes the error message to print cluster_sz from the proper structure. Signed-off-by: Mike Gerdts <mgerdts@nvidia.com> Change-Id: I810bf9ad4a24ed7cc844c2835e0edda988cb2cbe Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/15970 Tested-by: SPDK CI Jenkins <sys_sgci@intel.com> Reviewed-by: Jim Harris <james.r.harris@intel.com> Reviewed-by: Shuhei Matsumoto <smatsumoto@nvidia.com>
This commit is contained in:
parent
857e8cae85
commit
6e770cf8d6
@ -562,7 +562,7 @@ spdk_lvs_init(struct spdk_bs_dev *bs_dev, struct spdk_lvs_opts *o,
|
|||||||
|
|
||||||
if (o->cluster_sz < bs_dev->blocklen) {
|
if (o->cluster_sz < bs_dev->blocklen) {
|
||||||
SPDK_ERRLOG("Cluster size %" PRIu32 " is smaller than blocklen %" PRIu32 "\n",
|
SPDK_ERRLOG("Cluster size %" PRIu32 " is smaller than blocklen %" PRIu32 "\n",
|
||||||
opts.cluster_sz, bs_dev->blocklen);
|
o->cluster_sz, bs_dev->blocklen);
|
||||||
return -EINVAL;
|
return -EINVAL;
|
||||||
}
|
}
|
||||||
total_clusters = bs_dev->blockcnt / (o->cluster_sz / bs_dev->blocklen);
|
total_clusters = bs_dev->blockcnt / (o->cluster_sz / bs_dev->blocklen);
|
||||||
|
Loading…
Reference in New Issue
Block a user