X-Git-Url: https://git.camperquake.de/gitweb.cgi?a=blobdiff_plain;f=module%2Fzfs%2Fdmu_zfetch.c;h=b36c30fc62783309118c547c961b91dff07478cd;hb=4c0d8e50b99b4f3b4a9b7bc67ac7fc4e406f5755;hp=37037c30f62354359befc3f6896665158ba6ef74;hpb=428870ff734fdaccc342b33fc53cf94724409a46;p=zfs.git diff --git a/module/zfs/dmu_zfetch.c b/module/zfs/dmu_zfetch.c index 37037c3..b36c30f 100644 --- a/module/zfs/dmu_zfetch.c +++ b/module/zfs/dmu_zfetch.c @@ -665,7 +665,7 @@ dmu_zfetch(zfetch_t *zf, uint64_t offset, uint64_t size, int prefetched) ZFETCHSTAT_BUMP(zfetchstat_hits); } else { ZFETCHSTAT_BUMP(zfetchstat_misses); - if (fetched = dmu_zfetch_colinear(zf, &zst)) { + if ((fetched = dmu_zfetch_colinear(zf, &zst))) { ZFETCHSTAT_BUMP(zfetchstat_colinear_hits); } else { ZFETCHSTAT_BUMP(zfetchstat_colinear_misses); @@ -722,3 +722,9 @@ dmu_zfetch(zfetch_t *zf, uint64_t offset, uint64_t size, int prefetched) } } } + +#if defined(_KERNEL) && defined(HAVE_SPL) +module_param(zfs_prefetch_disable, int, 0644); +MODULE_PARM_DESC(zfs_prefetch_disable, "Disable all ZFS prefetching"); +#endif +