Spdk/include/spdk
yidong0635 dabca25646 util: Extract a common lib between iovs and buf.
It's useful to add these APIs.
spdk_copy_iovs_to_buf and spdk_copy_buf_to_iovs.

It prepares that other ones can call these.
We don't need to define them in static state
repeatedly.

And add corresponding unit tests.

Change-Id: Ife40fec8d047a48af67b04e6c055e4932282abfb
Signed-off-by: yidong0635 <dongx.yi@intel.com>
Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/12075
Community-CI: Broadcom CI <spdk-ci.pdl@broadcom.com>
Community-CI: Mellanox Build Bot
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Reviewed-by: Konrad Sztyber <konrad.sztyber@intel.com>
Reviewed-by: Shuhei Matsumoto <smatsumoto@nvidia.com>
Reviewed-by: Ben Walker <benjamin.walker@intel.com>
2022-06-20 10:01:15 +00:00
..
accel_engine.h Replace most BSD 3-clause license text with SPDX identifier. 2022-06-09 07:35:12 +00:00
assert.h Replace most BSD 3-clause license text with SPDX identifier. 2022-06-09 07:35:12 +00:00
barrier.h Replace most BSD 3-clause license text with SPDX identifier. 2022-06-09 07:35:12 +00:00
base64.h Replace most BSD 3-clause license text with SPDX identifier. 2022-06-09 07:35:12 +00:00
bdev_module.h Replace most BSD 3-clause license text with SPDX identifier. 2022-06-09 07:35:12 +00:00
bdev_zone.h Replace most BSD 3-clause license text with SPDX identifier. 2022-06-09 07:35:12 +00:00
bdev.h Replace most BSD 3-clause license text with SPDX identifier. 2022-06-09 07:35:12 +00:00
bit_array.h Replace most BSD 3-clause license text with SPDX identifier. 2022-06-09 07:35:12 +00:00
bit_pool.h Replace most BSD 3-clause license text with SPDX identifier. 2022-06-09 07:35:12 +00:00
blob_bdev.h Replace most BSD 3-clause license text with SPDX identifier. 2022-06-09 07:35:12 +00:00
blob.h Replace most BSD 3-clause license text with SPDX identifier. 2022-06-09 07:35:12 +00:00
blobfs_bdev.h Replace most BSD 3-clause license text with SPDX identifier. 2022-06-09 07:35:12 +00:00
blobfs.h Replace most BSD 3-clause license text with SPDX identifier. 2022-06-09 07:35:12 +00:00
conf.h Replace most BSD 3-clause license text with SPDX identifier. 2022-06-09 07:35:12 +00:00
cpuset.h Replace most BSD 3-clause license text with SPDX identifier. 2022-06-09 07:35:12 +00:00
crc16.h Replace most BSD 3-clause license text with SPDX identifier. 2022-06-09 07:35:12 +00:00
crc32.h Replace most BSD 3-clause license text with SPDX identifier. 2022-06-09 07:35:12 +00:00
dif.h Replace most BSD 3-clause license text with SPDX identifier. 2022-06-09 07:35:12 +00:00
dma.h Replace most BSD 3-clause license text with SPDX identifier. 2022-06-09 07:35:12 +00:00
endian.h Replace most BSD 3-clause license text with SPDX identifier. 2022-06-09 07:35:12 +00:00
env_dpdk.h Replace most BSD 3-clause license text with SPDX identifier. 2022-06-09 07:35:12 +00:00
env.h Replace most BSD 3-clause license text with SPDX identifier. 2022-06-09 07:35:12 +00:00
event.h Replace most BSD 3-clause license text with SPDX identifier. 2022-06-09 07:35:12 +00:00
fd_group.h Replace most BSD 3-clause license text with SPDX identifier. 2022-06-09 07:35:12 +00:00
fd.h Replace most BSD 3-clause license text with SPDX identifier. 2022-06-09 07:35:12 +00:00
file.h Replace most BSD 3-clause license text with SPDX identifier. 2022-06-09 07:35:12 +00:00
ftl.h Replace most BSD 3-clause license text with SPDX identifier. 2022-06-09 07:35:12 +00:00
gpt_spec.h Replace most BSD 3-clause license text with SPDX identifier. 2022-06-09 07:35:12 +00:00
histogram_data.h Replace most BSD 3-clause license text with SPDX identifier. 2022-06-09 07:35:12 +00:00
idxd_spec.h Replace most BSD 3-clause license text with SPDX identifier. 2022-06-09 07:35:12 +00:00
idxd.h Replace most BSD 3-clause license text with SPDX identifier. 2022-06-09 07:35:12 +00:00
init.h Replace most BSD 3-clause license text with SPDX identifier. 2022-06-09 07:35:12 +00:00
ioat_spec.h Replace most BSD 3-clause license text with SPDX identifier. 2022-06-09 07:35:12 +00:00
ioat.h Replace most BSD 3-clause license text with SPDX identifier. 2022-06-09 07:35:12 +00:00
iscsi_spec.h Replace most BSD 3-clause license text with SPDX identifier. 2022-06-09 07:35:12 +00:00
json.h Replace most BSD 3-clause license text with SPDX identifier. 2022-06-09 07:35:12 +00:00
jsonrpc.h Replace most BSD 3-clause license text with SPDX identifier. 2022-06-09 07:35:12 +00:00
likely.h Replace most BSD 3-clause license text with SPDX identifier. 2022-06-09 07:35:12 +00:00
log.h Replace most BSD 3-clause license text with SPDX identifier. 2022-06-09 07:35:12 +00:00
lvol.h Replace most BSD 3-clause license text with SPDX identifier. 2022-06-09 07:35:12 +00:00
memory.h Replace most BSD 3-clause license text with SPDX identifier. 2022-06-09 07:35:12 +00:00
mmio.h Replace most BSD 3-clause license text with SPDX identifier. 2022-06-09 07:35:12 +00:00
nbd.h Replace most BSD 3-clause license text with SPDX identifier. 2022-06-09 07:35:12 +00:00
notify.h Replace most BSD 3-clause license text with SPDX identifier. 2022-06-09 07:35:12 +00:00
nvme_intel.h Replace most BSD 3-clause license text with SPDX identifier. 2022-06-09 07:35:12 +00:00
nvme_ocssd_spec.h Replace most BSD 3-clause license text with SPDX identifier. 2022-06-09 07:35:12 +00:00
nvme_ocssd.h Replace most BSD 3-clause license text with SPDX identifier. 2022-06-09 07:35:12 +00:00
nvme_spec.h include/nvme_spec.h: update cdata fields for fabric commands 2022-06-20 09:58:57 +00:00
nvme_zns.h Replace most BSD 3-clause license text with SPDX identifier. 2022-06-09 07:35:12 +00:00
nvme.h nvme.h: Correct an incorrect comment for AER 2022-06-14 09:42:35 +00:00
nvmf_cmd.h Replace most BSD 3-clause license text with SPDX identifier. 2022-06-09 07:35:12 +00:00
nvmf_fc_spec.h Replace most BSD 3-clause license text with SPDX identifier. 2022-06-09 07:35:12 +00:00
nvmf_spec.h Replace most BSD 3-clause license text with SPDX identifier. 2022-06-09 07:35:12 +00:00
nvmf_transport.h nvmf: Add NVMe fused operations to spdk_nvmf_ctrlr_data 2022-06-10 07:54:33 +00:00
nvmf.h Replace most BSD 3-clause license text with SPDX identifier. 2022-06-09 07:35:12 +00:00
opal_spec.h Replace most BSD 3-clause license text with SPDX identifier. 2022-06-09 07:35:12 +00:00
opal.h Replace most BSD 3-clause license text with SPDX identifier. 2022-06-09 07:35:12 +00:00
pci_ids.h Replace most BSD 3-clause license text with SPDX identifier. 2022-06-09 07:35:12 +00:00
pipe.h Replace most BSD 3-clause license text with SPDX identifier. 2022-06-09 07:35:12 +00:00
queue_extras.h include: remove util.h include from queue_extras.h 2021-04-14 07:25:21 +00:00
queue.h Replace most BSD 3-clause license text with SPDX identifier. 2022-06-09 07:35:12 +00:00
reduce.h Replace most BSD 3-clause license text with SPDX identifier. 2022-06-09 07:35:12 +00:00
rpc.h Replace most BSD 3-clause license text with SPDX identifier. 2022-06-09 07:35:12 +00:00
scheduler.h Replace most BSD 3-clause license text with SPDX identifier. 2022-06-09 07:35:12 +00:00
scsi_spec.h Replace most BSD 3-clause license text with SPDX identifier. 2022-06-09 07:35:12 +00:00
scsi.h Replace most BSD 3-clause license text with SPDX identifier. 2022-06-09 07:35:12 +00:00
sock.h Replace most BSD 3-clause license text with SPDX identifier. 2022-06-09 07:35:12 +00:00
stdinc.h Replace most BSD 3-clause license text with SPDX identifier. 2022-06-09 07:35:12 +00:00
string.h Replace most BSD 3-clause license text with SPDX identifier. 2022-06-09 07:35:12 +00:00
thread.h Replace most BSD 3-clause license text with SPDX identifier. 2022-06-09 07:35:12 +00:00
trace_parser.h Replace most BSD 3-clause license text with SPDX identifier. 2022-06-09 07:35:12 +00:00
trace.h Replace most BSD 3-clause license text with SPDX identifier. 2022-06-09 07:35:12 +00:00
tree.h util: rename RB_ROOT into _RB_ROOT 2021-06-04 22:46:40 +00:00
util.h util: Extract a common lib between iovs and buf. 2022-06-20 10:01:15 +00:00
uuid.h Replace most BSD 3-clause license text with SPDX identifier. 2022-06-09 07:35:12 +00:00
version.h Replace most BSD 3-clause license text with SPDX identifier. 2022-06-09 07:35:12 +00:00
vfio_user_pci.h Replace most BSD 3-clause license text with SPDX identifier. 2022-06-09 07:35:12 +00:00
vfio_user_spec.h Replace most BSD 3-clause license text with SPDX identifier. 2022-06-09 07:35:12 +00:00
vhost.h Replace most BSD 3-clause license text with SPDX identifier. 2022-06-09 07:35:12 +00:00
vmd.h Replace most BSD 3-clause license text with SPDX identifier. 2022-06-09 07:35:12 +00:00
zipf.h Replace most BSD 3-clause license text with SPDX identifier. 2022-06-09 07:35:12 +00:00