From 4cb7b9c5d42c831878e0cf90c845ed52a2a34d72 Mon Sep 17 00:00:00 2001 From: Brian Behlendorf Date: Mon, 24 Aug 2015 14:18:48 -0700 Subject: Check large block feature flag on volumes Since ZoL allows large blocks to be used by volumes, unlike upstream illumos, the feature flag must be checked prior to volume creation. This is critical because unlike filesystems, volumes will create a object which uses large blocks as part of the create. Therefore, it cannot be safely checked in zfs_check_settable() after the dataset can been created. In addition this patch updates the relevant error messages to use zfs_nicenum() to print the maximum blocksize. Signed-off-by: Brian Behlendorf Closes #3591 --- include/sys/zvol.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'include/sys/zvol.h') diff --git a/include/sys/zvol.h b/include/sys/zvol.h index 04e099657..898e23521 100644 --- a/include/sys/zvol.h +++ b/include/sys/zvol.h @@ -34,7 +34,7 @@ #ifdef _KERNEL extern int zvol_check_volsize(uint64_t volsize, uint64_t blocksize); -extern int zvol_check_volblocksize(uint64_t volblocksize); +extern int zvol_check_volblocksize(const char *name, uint64_t volblocksize); extern int zvol_get_stats(objset_t *os, nvlist_t *nv); extern boolean_t zvol_is_zvol(const char *); extern void zvol_create_cb(objset_t *os, void *arg, cred_t *cr, dmu_tx_t *tx); -- cgit v1.2.3