]> git.proxmox.com Git - mirror_zfs.git/commit - module/zfs/spa_stats.c
Refactor txg history kstat
authorBrian Behlendorf <behlendorf1@llnl.gov>
Fri, 2 Dec 2016 23:57:49 +0000 (16:57 -0700)
committerGitHub <noreply@github.com>
Fri, 2 Dec 2016 23:57:49 +0000 (16:57 -0700)
commitbaf67d15a59025fb53fc60bf439ef291397366e8
treed6c71227595717eb14a8eaeae5189abdc04aad1c
parent6c09d3e5a04db023536aab467064cad3f7858776
Refactor txg history kstat

It was observed that even when the txg history is disabled by
setting `zfs_txg_history=0` the txg_sync thread still fetches
the vdev stats unnecessarily.

This patch refactors the code such that vdev_get_stats() is no
longer called when `zfs_txg_history=0`.  And it further reduces
the  differences between upstream and the ZoL txg_sync_thread()
function.

Reviewed-by: Tony Hutter <hutter2@llnl.gov>
Signed-off-by: Brian Behlendorf <behlendorf1@llnl.gov>
Closes #5412
include/sys/spa.h
module/zfs/spa_stats.c
module/zfs/txg.c