]> granicus.if.org Git - zfs/commitdiff
Fix arc_adjust_meta_balanced()
authorTim Chase <tim@chase2k.com>
Mon, 19 Sep 2016 16:28:35 +0000 (11:28 -0500)
committerBrian Behlendorf <behlendorf1@llnl.gov>
Mon, 19 Sep 2016 16:28:35 +0000 (09:28 -0700)
The type of "adjustmnt" was erroneously changed to unsigned when the compressed
ARC code was ported in d3c2ae1c0806b183a315e3d43cc8018cfdca79b5.

As a result of it being unsigned, the balanced metadata eviction logic
would evict all of the non-metadata.

Reviewed-by: Chris Severance <github.severach@spamgourmet.com>
Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov>
Reviewed by: David Quigley <david.quigley@intel.com>
Signed-off-by: Tim Chase <tim@onlight.com>
Closes #5128
Closes #5129

module/zfs/arc.c

index 2bf7a988311f63e2bada57376cad6838db20d9e5..f848c4c093cf33e44b6b045438e3113854e77dde 100755 (executable)
@@ -3520,8 +3520,8 @@ arc_adjust_impl(arc_state_t *state, uint64_t spa, int64_t bytes,
 static uint64_t
 arc_adjust_meta_balanced(void)
 {
-       int64_t delta, prune = 0;
-       uint64_t adjustmnt, total_evicted = 0;
+       int64_t delta, prune = 0, adjustmnt;
+       uint64_t total_evicted = 0;
        arc_buf_contents_t type = ARC_BUFC_DATA;
        int restarts = MAX(zfs_arc_meta_adjust_restarts, 0);