mirror of
https://git.proxmox.com/git/mirror_zfs.git
synced 2026-05-22 10:37:35 +03:00
Remove bcopy(), bzero(), bcmp()
bcopy() has a confusing argument order and is actually a move, not a copy; they're all deprecated since POSIX.1-2001 and removed in -2008, and we shim them out to mem*() on Linux anyway Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov> Signed-off-by: Ahelenia Ziemiańska <nabijaczleweli@nabijaczleweli.xyz> Closes #12996
This commit is contained in:
@@ -250,7 +250,8 @@ kcf_add_mech_provider(short mech_indx,
|
||||
|
||||
/* allocate and initialize new kcf_prov_mech_desc */
|
||||
prov_mech = kmem_zalloc(sizeof (kcf_prov_mech_desc_t), KM_SLEEP);
|
||||
bcopy(mech_info, &prov_mech->pm_mech_info, sizeof (crypto_mech_info_t));
|
||||
memcpy(&prov_mech->pm_mech_info, mech_info,
|
||||
sizeof (crypto_mech_info_t));
|
||||
prov_mech->pm_prov_desc = prov_desc;
|
||||
prov_desc->pd_mech_indx[KCF_MECH2CLASS(kcf_mech_type)]
|
||||
[KCF_MECH2INDEX(kcf_mech_type)] = mech_indx;
|
||||
|
||||
@@ -70,7 +70,7 @@ crypto_uio_copy_to_data(crypto_data_t *data, uchar_t *buf, int len)
|
||||
offset, length);
|
||||
|
||||
datap = (uchar_t *)(zfs_uio_iovbase(uiop, vec_idx) + offset);
|
||||
bcopy(buf, datap, cur_len);
|
||||
memcpy(datap, buf, cur_len);
|
||||
buf += cur_len;
|
||||
|
||||
length -= cur_len;
|
||||
@@ -99,8 +99,8 @@ crypto_put_output_data(uchar_t *buf, crypto_data_t *output, int len)
|
||||
output->cd_length = len;
|
||||
return (CRYPTO_BUFFER_TOO_SMALL);
|
||||
}
|
||||
bcopy(buf, (uchar_t *)(output->cd_raw.iov_base +
|
||||
output->cd_offset), len);
|
||||
memcpy((uchar_t *)(output->cd_raw.iov_base +
|
||||
output->cd_offset), buf, len);
|
||||
break;
|
||||
|
||||
case CRYPTO_DATA_UIO:
|
||||
|
||||
Reference in New Issue
Block a user