Add sysctls for zfs_immediate_write_sz and zvol_immediate_write_sz.

This commit is contained in:
mav 2016-10-29 23:25:12 +00:00
parent ad944a452a
commit be23d3b87c
2 changed files with 9 additions and 0 deletions

View File

@ -454,6 +454,11 @@ zfs_log_rename(zilog_t *zilog, dmu_tx_t *tx, uint64_t txtype,
* Handles TX_WRITE transactions.
*/
ssize_t zfs_immediate_write_sz = 32768;
#ifdef _KERNEL
SYSCTL_DECL(_vfs_zfs);
SYSCTL_LONG(_vfs_zfs, OID_AUTO, immediate_write_sz, CTLFLAG_RWTUN,
&zfs_immediate_write_sz, 0, "Minimal size for indirect log write");
#endif
void
zfs_log_write(zilog_t *zilog, dmu_tx_t *tx, int txtype,

View File

@ -1375,6 +1375,10 @@ zvol_get_data(void *arg, lr_write_t *lr, char *buf, zio_t *zio)
* Otherwise we will later flush the data out via dmu_sync().
*/
ssize_t zvol_immediate_write_sz = 32768;
#ifdef _KERNEL
SYSCTL_LONG(_vfs_zfs_vol, OID_AUTO, immediate_write_sz, CTLFLAG_RWTUN,
&zvol_immediate_write_sz, 0, "Minimal size for indirect log write");
#endif
static void
zvol_log_write(zvol_state_t *zv, dmu_tx_t *tx, offset_t off, ssize_t resid,