*
* Further, this software is distributed without any warranty that it is
* free of the rightful claim of any third person regarding infringement
- * or the like. Any license provided herein, whether implied or
+ * or the like. Any license provided herein, whether implied or
* otherwise, applies only to this software file. Patent licenses, if
* any, provided herein do not apply to combinations of this program with
* other software, or any other product whatsoever.
* Could compact these but I think we always do the conversion
* after squeezing out stale entries.
*/
- bcopy(blp, leaf->ents, INT_GET(btp->count, ARCH_CONVERT) * sizeof(xfs_dir2_leaf_entry_t));
+ memcpy(leaf->ents, blp, INT_GET(btp->count, ARCH_CONVERT) * sizeof(xfs_dir2_leaf_entry_t));
xfs_dir2_leaf_log_ents(tp, lbp, 0, INT_GET(leaf->hdr.count, ARCH_CONVERT) - 1);
needscan = 0;
needlog = 1;
*/
if (use_block >= INT_GET(ltp->bestcount, ARCH_CONVERT)) {
bestsp--;
- ovbcopy(&bestsp[1], &bestsp[0],
+ memmove(&bestsp[0], &bestsp[1],
INT_GET(ltp->bestcount, ARCH_CONVERT) * sizeof(bestsp[0]));
INT_MOD(ltp->bestcount, ARCH_CONVERT, +1);
xfs_dir2_leaf_log_tail(tp, lbp);
dep = (xfs_dir2_data_entry_t *)dup;
INT_SET(dep->inumber, ARCH_CONVERT, args->inumber);
dep->namelen = args->namelen;
- bcopy(args->name, dep->name, dep->namelen);
+ memcpy(dep->name, args->name, dep->namelen);
tagp = XFS_DIR2_DATA_ENTRY_TAG_P(dep);
INT_SET(*tagp, ARCH_CONVERT, (xfs_dir2_data_off_t)((char *)dep - (char *)data));
/*
* lep is still good as the index leaf entry.
*/
if (index < INT_GET(leaf->hdr.count, ARCH_CONVERT))
- ovbcopy(lep, lep + 1,
+ memmove(lep + 1, lep,
(INT_GET(leaf->hdr.count, ARCH_CONVERT) - index) * sizeof(*lep));
/*
* Record low and high logging indices for the leaf.
* and make room for the new entry.
*/
if (index - lowstale - 1 > 0)
- ovbcopy(&leaf->ents[lowstale + 1],
- &leaf->ents[lowstale],
+ memmove(&leaf->ents[lowstale],
+ &leaf->ents[lowstale + 1],
(index - lowstale - 1) * sizeof(*lep));
lep = &leaf->ents[index - 1];
lfloglow = MIN(lowstale, lfloglow);
* and make room for the new entry.
*/
if (highstale - index > 0)
- ovbcopy(&leaf->ents[index],
- &leaf->ents[index + 1],
+ memmove(&leaf->ents[index + 1],
+ &leaf->ents[index],
(highstale - index) * sizeof(*lep));
lep = &leaf->ents[index];
lfloglow = MIN(index, lfloglow);
return 0;
}
-
#ifdef DEBUG
/*
* Check the internal consistency of a leaf1 block.
xfs_dabuf_t *bp) /* leaf buffer */
{
int from; /* source leaf index */
- xfs_dir2_leaf_t *leaf; /* leaf structure */
+ xfs_dir2_leaf_t *leaf; /* leaf structure */
int loglow; /* first leaf entry to log */
int to; /* target leaf index */
int highstale; /* stale entry at/after index */
int index; /* insertion index */
int keepstale; /* source index of kept stale */
- xfs_dir2_leaf_t *leaf; /* leaf structure */
+ xfs_dir2_leaf_t *leaf; /* leaf structure */
int lowstale; /* stale entry before index */
int newindex=0; /* new insertion index */
int to; /* destination copy index */
*/
if (dep->namelen == args->namelen &&
dep->name[0] == args->name[0] &&
- bcmp(dep->name, args->name, args->namelen) == 0) {
+ memcmp(dep->name, args->name, args->namelen) == 0) {
*dbpp = dbp;
*indexp = index;
return 0;
* Copy the table down so inactive entries at the
* end are removed.
*/
- ovbcopy(bestsp, &bestsp[db - i],
+ memmove(&bestsp[db - i], bestsp,
(INT_GET(ltp->bestcount, ARCH_CONVERT) - (db - i)) * sizeof(*bestsp));
INT_MOD(ltp->bestcount, ARCH_CONVERT, -(db - i));
xfs_dir2_leaf_log_tail(tp, lbp);
*/
bestsp = XFS_DIR2_LEAF_BESTS_P_ARCH(ltp, ARCH_CONVERT);
INT_MOD(ltp->bestcount, ARCH_CONVERT, -1);
- ovbcopy(&bestsp[0], &bestsp[1], INT_GET(ltp->bestcount, ARCH_CONVERT) * sizeof(*bestsp));
+ memmove(&bestsp[1], &bestsp[0], INT_GET(ltp->bestcount, ARCH_CONVERT) * sizeof(*bestsp));
xfs_dir2_leaf_log_tail(tp, lbp);
xfs_dir2_leaf_log_bests(tp, lbp, 0, INT_GET(ltp->bestcount, ARCH_CONVERT) - 1);
return 0;
/*
* Set up the leaf bests table.
*/
- bcopy(free->bests, XFS_DIR2_LEAF_BESTS_P_ARCH(ltp, ARCH_CONVERT),
+ memcpy(XFS_DIR2_LEAF_BESTS_P_ARCH(ltp, ARCH_CONVERT), free->bests,
INT_GET(ltp->bestcount, ARCH_CONVERT) * sizeof(leaf->bests[0]));
xfs_dir2_leaf_log_bests(tp, lbp, 0, INT_GET(ltp->bestcount, ARCH_CONVERT) - 1);
xfs_dir2_leaf_log_tail(tp, lbp);