Skip to content

Commit

Permalink
Do not allow the user to manually set compress_level
Browse files Browse the repository at this point in the history
It is set atomically as part of setting `compress` when the
compression type supports multiple levels.

Signed-off-by: Allan Jude <allan@klarasystems.com>
  • Loading branch information
allanjude committed Jun 30, 2020
1 parent 81bf2af commit 622b7e1
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions module/zfs/zfs_ioctl.c
Original file line number Diff line number Diff line change
Expand Up @@ -4582,6 +4582,10 @@ zfs_check_settable(const char *dsname, nvpair_t *pair, cred_t *cr)
}
break;

case ZFS_PROP_COMPRESS_LEVEL:
return (SET_ERROR(EINVAL));
break;

case ZFS_PROP_COPIES:
if (zfs_earlier_version(dsname, SPA_VERSION_DITTO_BLOCKS))
return (SET_ERROR(ENOTSUP));
Expand Down

0 comments on commit 622b7e1

Please sign in to comment.