mirror of
https://github.com/opnsense/src.git
synced 2026-05-28 04:12:45 -04:00
zfs: merge openzfs/zfs@e96fbdba3 (zfs-2.2-release) into stable/14
Notable upstream pull request merges:
#15251 Add more constraints for block cloning
Obtained from: OpenZF
OpenZFS commit: e96fbdba34
This commit is contained in:
commit
2b2fbeb3a9
5 changed files with 25 additions and 6 deletions
|
|
@ -2,7 +2,7 @@ Meta: 1
|
|||
Name: zfs
|
||||
Branch: 1.0
|
||||
Version: 2.2.0
|
||||
Release: rc3
|
||||
Release: rc4
|
||||
Release-Tags: relext
|
||||
License: CDDL
|
||||
Author: OpenZFS
|
||||
|
|
|
|||
|
|
@ -193,7 +193,9 @@ qat_dc_init(void)
|
|||
sd.huffType = CPA_DC_HT_FULL_DYNAMIC;
|
||||
sd.sessDirection = CPA_DC_DIR_COMBINED;
|
||||
sd.sessState = CPA_DC_STATELESS;
|
||||
#if (CPA_DC_API_VERSION_NUM_MAJOR == 1 && CPA_DC_API_VERSION_NUM_MINOR < 6)
|
||||
sd.deflateWindowSize = 7;
|
||||
#endif
|
||||
sd.checksum = CPA_DC_ADLER32;
|
||||
status = cpaDcGetSessionSize(dc_inst_handles[i],
|
||||
&sd, &sess_size, &ctx_size);
|
||||
|
|
|
|||
|
|
@ -1172,9 +1172,20 @@ zfs_clone_range(znode_t *inzp, uint64_t *inoffp, znode_t *outzp,
|
|||
inblksz = inzp->z_blksz;
|
||||
|
||||
/*
|
||||
* We cannot clone into files with different block size.
|
||||
* We cannot clone into files with different block size if we can't
|
||||
* grow it (block size is already bigger or more than one block).
|
||||
*/
|
||||
if (inblksz != outzp->z_blksz && outzp->z_size > inblksz) {
|
||||
if (inblksz != outzp->z_blksz && (outzp->z_size > outzp->z_blksz ||
|
||||
outzp->z_size > inblksz)) {
|
||||
error = SET_ERROR(EINVAL);
|
||||
goto unlock;
|
||||
}
|
||||
|
||||
/*
|
||||
* Block size must be power-of-2 if destination offset != 0.
|
||||
* There can be no multiple blocks of non-power-of-2 size.
|
||||
*/
|
||||
if (outoff != 0 && !ISP2(inblksz)) {
|
||||
error = SET_ERROR(EINVAL);
|
||||
goto unlock;
|
||||
}
|
||||
|
|
@ -1358,6 +1369,12 @@ unlock:
|
|||
*inoffp += done;
|
||||
*outoffp += done;
|
||||
*lenp = done;
|
||||
} else {
|
||||
/*
|
||||
* If we made no progress, there must be a good reason.
|
||||
* EOF is handled explicitly above, before the loop.
|
||||
*/
|
||||
ASSERT3S(error, !=, 0);
|
||||
}
|
||||
|
||||
zfs_exit_two(inzfsvfs, outzfsvfs, FTAG);
|
||||
|
|
|
|||
|
|
@ -1074,7 +1074,7 @@
|
|||
/* #undef ZFS_IS_GPL_COMPATIBLE */
|
||||
|
||||
/* Define the project alias string. */
|
||||
#define ZFS_META_ALIAS "zfs-2.2.0-FreeBSD_g32949f256"
|
||||
#define ZFS_META_ALIAS "zfs-2.2.0-FreeBSD_ge96fbdba3"
|
||||
|
||||
/* Define the project author. */
|
||||
#define ZFS_META_AUTHOR "OpenZFS"
|
||||
|
|
@ -1104,7 +1104,7 @@
|
|||
#define ZFS_META_NAME "zfs"
|
||||
|
||||
/* Define the project release. */
|
||||
#define ZFS_META_RELEASE "FreeBSD_g32949f256"
|
||||
#define ZFS_META_RELEASE "FreeBSD_ge96fbdba3"
|
||||
|
||||
/* Define the project version. */
|
||||
#define ZFS_META_VERSION "2.2.0"
|
||||
|
|
|
|||
|
|
@ -1 +1 @@
|
|||
#define ZFS_META_GITREV "zfs-2.2.0-rc3-31-g32949f256"
|
||||
#define ZFS_META_GITREV "zfs-2.2.0-rc4-1-ge96fbdba3"
|
||||
|
|
|
|||
Loading…
Reference in a new issue