Spdk/test/unit
Jim Harris 3327bb4391 histogram_data: check bucket_shift when merging
When merging data from one spdk_histogram_data to
another, the merging is only valid if the bucket_shift
for each structure is the same.  Otherwise we are
combining data points that cover different ranges
of values.

So check that the bucket_shifts are the same before
merging. Change the return type to int to
return -EINVAL if structures with different
bucket_shifts are attempted to be merged.

Signed-off-by: Jim Harris <james.r.harris@intel.com>
Change-Id: If98e2d03384d85f478965956da2a42cfcff4713d
Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/15813
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Community-CI: Mellanox Build Bot
Reviewed-by: Shuhei Matsumoto <smatsumoto@nvidia.com>
Reviewed-by: Tomasz Zawadzki <tomasz.zawadzki@intel.com>
2022-12-21 09:32:40 +00:00
..
include histogram_data: check bucket_shift when merging 2022-12-21 09:32:40 +00:00
lib blobstore: missing lock leads to md page race 2022-12-20 09:19:09 +00:00
.gitignore test: optimize unit test .gitignore files 2021-08-20 07:29:57 +00:00
Makefile update Intel copyright notices 2022-11-10 08:28:53 +00:00
unittest.sh test/reduce: fix missing mem free call and add test call to UT script 2022-12-08 12:55:27 +00:00