From nobody Wed May 08 15:25:52 2024 X-Original-To: dev-commits-src-branches@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4VZJrK1ZvTz5JLq2; Wed, 08 May 2024 15:25:53 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VZJrK1LpCz4jLJ; Wed, 8 May 2024 15:25:53 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1715181953; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=N/8Vck1V/qYrugzHU1COeEZRlrFxiLEBbG2fUB/DrNk=; b=i2lImALP/d30jTeGJ43DHBiMByqcxAHAaMKQfVOc9Ynvjb5vFj1+LjVkio5Lo43XvAAnJQ 6Uf7RphQf+OtqyPBa+mLE9LL46EaFMPsC5tdoI5NuPU0Um0ol4AIqSTOgxZSBFMCFnsnca FRZZGmTnvHyUJNRa7WEK3ymdRfeM4zHrF6vOhv/4ACog8jxK2nKXcG7fyWRKNtDJD40jSw vtyTfq7+HALVwcEoxfS1n9oV0pABf7boG+Bqc/zFFtnhU0cjyUVdys+Yoxuika3EJCoD7w mnBQYa3NHoGzXteulvX60gtqmlq+XCMLb9goJ2WOitXo81/s6dRX2CTpZQ/zBA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1715181953; a=rsa-sha256; cv=none; b=FG7xnSaAKifoOi/j7rMqqUQ3MZaoFwTql2Qo/3QUQlbnDGYwdqC+xziBjfj3aiLkufN29d 7st1Kp1F/aJeAycBTuqc9XeBKWD9HMmGSGhohg0RVyTCfMmKKBS2Cb6tEfxOVSVVQNRd0B JeNuoBWT944o+WzBWH8XMC2ahxm2uAaTrdz5/GFMQVkllmHS8vegLpQtVwo6u82qZGAmox KTS5fIxjFIYtXQeHL9nxQv29/OfAtSqNtXxeBG84DLzlsOBX6tkqhMFCIL7a9CItRTmm8H CBZYrEnBCVsGQ7vsvFOHLfvMwQDykVVxOa2vWoojfVRsK9iMVm4pXSXMLmRNxQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1715181953; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=N/8Vck1V/qYrugzHU1COeEZRlrFxiLEBbG2fUB/DrNk=; b=modKRVqZeQkSfSZ94t0T+nwhvpKihohRRC9/lZnGa50xSY/+j5ZGXKyrUAfMkvIHoLuosg /O4rsn3oSM2qqKIS/F+xmEMCD2CkiSNBdoP8/azVrIprt28i/kg04Gmd/WoxThOT9wKRVS CMUjgCs/zcwJ+B3DrYtQ9hqJKbHYNEtMz/r5/vVbg0mRn/kWRRCsrU7dXPsemfysOxYoUo B2vOKlbaq5nPlcOQq8OjhcP2iqYlKc4uS0dbmPQAT17qED1ZNgDHxRhL7LPjMP3AKeuFM6 XZY5OONg/ATCw/3I6TLJ6Rsfb9eKNI1D6v182yKxDnXjcNiDdOC1NZUFlFB6fw== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4VZJrK0m6ZzVyD; Wed, 8 May 2024 15:25:53 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 448FPrbj016665; Wed, 8 May 2024 15:25:53 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 448FPqaW016662; Wed, 8 May 2024 15:25:52 GMT (envelope-from git) Date: Wed, 8 May 2024 15:25:52 GMT Message-Id: <202405081525.448FPqaW016662@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Martin Matuska Subject: git: 78c9d8f1ce65 - releng/14.1 - zfs: merge openzfs/zfs@256659204 (zfs-2.2-release) into stable/14 List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: mm X-Git-Repository: src X-Git-Refname: refs/heads/releng/14.1 X-Git-Reftype: branch X-Git-Commit: 78c9d8f1ce655f10368c06272f5e320b8a263612 Auto-Submitted: auto-generated The branch releng/14.1 has been updated by mm: URL: https://cgit.FreeBSD.org/src/commit/?id=78c9d8f1ce655f10368c06272f5e320b8a263612 commit 78c9d8f1ce655f10368c06272f5e320b8a263612 Author: Martin Matuska AuthorDate: 2024-05-03 21:51:01 +0000 Commit: Martin Matuska CommitDate: 2024-05-08 15:24:29 +0000 zfs: merge openzfs/zfs@256659204 (zfs-2.2-release) into stable/14 OpenZFS release 2.2.4 Notable upstream pull request merges: #15076 fdd97e009 Refactor dmu_prefetch() #15225 5972bb856 Use ASSERT0P() to check that a pointer is NULL #15381 7ea833100 ZIL: Detect single-threaded workloads #15515 8b1a132de ZIO: Optimize zio_flush() #15225 d6da6cbd7 Clean up existing VERIFY*() macros #15225 5dda8c091 Add VERIFY0P() and ASSERT0P() macros #15436 61f3638a3 Add prefetch property #15509 6f323353d Add ashift validation when adding devices to a pool #15539 ea3f7c12a Extend import_progress kstat with a notes field #15635 25ea8ce94 ZIL: Improve next log block size prediction #15784 16c223eec Do no use .cfi_negate_ra_state within the assembly on Arm64 #15839 706307445 vdev probe to slow disk can stall mmp write checker #15879 86b39b41a zpool: Fix locale-specific time #15927 fa5de0c5c Update resume token at object receive #15941 fdd8c0aea BRT: Skip duplicate BRT prefetches #15942 889152ce4 Give better message from 'zpool get' with invalid pool name #15950 3e91a9c52 BRT: Skip getting length in brt_entry_lookup() #15951 19bf54b76 ZAP: Massively switch to _by_dnode() interfaces #15954 f7c1db636 BRT: Change brt_pending_tree sorting order #15955 457e62d7c BRT: Relax brt_pending_apply() locking #15967 c94f73007 BRT: Make BRT block sizes configurable #15976 dced953b6 ZAP: Some cleanups/micro-optimizations #15983 531572b59 Fix panics when truncating/deleting files #15992 5fc134ff2 zvol: use multiple taskq #16007 2ea370a4e BRT: Fix holes cloning #16008 67995229a zpool: Fix option string, adding -e and fixing order #16015 8a5604713 Add support for zfs mount -R #16022 026fe7964 Speculative prefetch for reordered requests #16040 575872cc3 L2ARC: Relax locking during write #16042 d5fb6abd3 Improve dbuf_read() error reporting #16051 5d859a2e2 xdr: header cleanup #16052 602b5dca7 Fix read errors race after block cloning #16057 97d7228f4 Remove db_state DB_NOFILL checks from syncing context #16072 f4ce02ae4 Small fix to prefetch ranges aggregation #16074 97889c037 return NULL at end of send_progress_thread #16086 7aaf6ce9d Add the BTI elf note to the AArch64 SHA2 assembly #16094 4d17e200d Add zfetch stats in arcstats #16128 3d4d61988 Fix updating the zvol_htable when renaming a zvol #16141 b3b37b84e Fix arcstats for FreeBSD after zfetch support Obtained from: OpenZFS OpenZFS commit: 2566592045780e7be7afc899c2496b1ae3af4f4d OpenZFS tag: zfs-2.2.4 Approved by: re (cperciva) (cherry picked from commit 9a5f0cb5b639f8e0435103d44b17eb8a352af990) --- cddl/lib/libnvpair/Makefile | 2 - sys/contrib/openzfs/.mailmap | 18 + sys/contrib/openzfs/AUTHORS | 35 + sys/contrib/openzfs/META | 4 +- sys/contrib/openzfs/cmd/arc_summary | 11 +- sys/contrib/openzfs/cmd/arcstat.in | 57 +- sys/contrib/openzfs/cmd/zed/agents/fmd_api.c | 57 +- sys/contrib/openzfs/cmd/zed/agents/fmd_api.h | 3 +- sys/contrib/openzfs/cmd/zed/agents/fmd_serd.c | 3 +- sys/contrib/openzfs/cmd/zed/agents/fmd_serd.h | 2 +- sys/contrib/openzfs/cmd/zed/agents/zfs_diagnosis.c | 143 +++- sys/contrib/openzfs/cmd/zed/agents/zfs_retire.c | 3 + sys/contrib/openzfs/cmd/zfs/zfs_main.c | 75 +- sys/contrib/openzfs/cmd/zinject/zinject.c | 16 + .../openzfs/cmd/zpool/os/linux/zpool_vdev_os.c | 4 +- sys/contrib/openzfs/cmd/zpool/zpool_main.c | 146 ++-- sys/contrib/openzfs/cmd/ztest.c | 8 +- sys/contrib/openzfs/config/Substfiles.am | 3 +- sys/contrib/openzfs/config/always-pyzfs.m4 | 9 +- sys/contrib/openzfs/config/ax_python_devel.m4 | 341 +++++--- sys/contrib/openzfs/config/kernel-blk-queue.m4 | 15 + sys/contrib/openzfs/config/kernel-blkdev.m4 | 159 +++- sys/contrib/openzfs/config/kernel-filemap.m4 | 1 + .../openzfs/config/kernel-make-request-fn.m4 | 33 + sys/contrib/openzfs/config/kernel-mm-page-size.m4 | 17 + .../openzfs/config/kernel-vfs-file_range.m4 | 27 + sys/contrib/openzfs/config/kernel.m4 | 4 + sys/contrib/openzfs/config/zfs-build.m4 | 8 +- sys/contrib/openzfs/contrib/debian/control | 2 +- sys/contrib/openzfs/etc/init.d/README.md | 6 +- sys/contrib/openzfs/etc/init.d/zfs-import.in | 2 +- sys/contrib/openzfs/etc/init.d/zfs-load-key.in | 2 +- sys/contrib/openzfs/etc/init.d/zfs-mount.in | 2 +- sys/contrib/openzfs/etc/init.d/zfs-share.in | 3 +- sys/contrib/openzfs/etc/init.d/zfs-zed.in | 3 +- sys/contrib/openzfs/include/libzfs.h | 6 +- sys/contrib/openzfs/include/os/freebsd/Makefile.am | 4 +- .../openzfs/include/os/freebsd/spl/rpc/xdr.h | 71 -- .../openzfs/include/os/freebsd/spl/sys/debug.h | 40 +- sys/contrib/openzfs/include/os/linux/Makefile.am | 2 + .../include/os/linux/kernel/linux/blkdev_compat.h | 6 +- .../include/os/linux/kernel/linux/mm_compat.h | 36 + .../include/os/linux/kernel/linux/mod_compat.h | 1 + .../openzfs/include/os/linux/spl/rpc/types.h | 30 + sys/contrib/openzfs/include/os/linux/spl/rpc/xdr.h | 2 - .../openzfs/include/os/linux/spl/sys/debug.h | 38 +- .../openzfs/include/os/linux/spl/sys/taskq.h | 2 +- .../openzfs/include/os/linux/zfs/sys/trace_zil.h | 14 +- sys/contrib/openzfs/include/sys/abd.h | 9 + sys/contrib/openzfs/include/sys/abd_impl.h | 26 +- sys/contrib/openzfs/include/sys/dmu.h | 5 +- sys/contrib/openzfs/include/sys/dmu_objset.h | 1 + sys/contrib/openzfs/include/sys/dmu_zfetch.h | 16 +- sys/contrib/openzfs/include/sys/fm/fs/zfs.h | 2 + sys/contrib/openzfs/include/sys/fs/zfs.h | 14 +- sys/contrib/openzfs/include/sys/multilist.h | 5 +- sys/contrib/openzfs/include/sys/spa.h | 12 +- sys/contrib/openzfs/include/sys/uberblock_impl.h | 16 +- sys/contrib/openzfs/include/sys/vdev_impl.h | 7 +- sys/contrib/openzfs/include/sys/zap.h | 8 + sys/contrib/openzfs/include/sys/zap_impl.h | 1 + sys/contrib/openzfs/include/sys/zap_leaf.h | 10 +- sys/contrib/openzfs/include/sys/zil_impl.h | 10 +- sys/contrib/openzfs/lib/libspl/include/assert.h | 15 +- sys/contrib/openzfs/lib/libuutil/uu_list.c | 14 +- sys/contrib/openzfs/lib/libzfs/libzfs.abi | 84 +- sys/contrib/openzfs/lib/libzfs/libzfs_pool.c | 13 +- sys/contrib/openzfs/lib/libzfs/libzfs_sendrecv.c | 1 + sys/contrib/openzfs/lib/libzfs/libzfs_util.c | 12 +- .../openzfs/lib/libzfs/os/linux/libzfs_pool_os.c | 10 + sys/contrib/openzfs/man/Makefile.am | 4 +- sys/contrib/openzfs/man/man4/spl.4 | 18 +- sys/contrib/openzfs/man/man4/zfs.4 | 83 +- sys/contrib/openzfs/man/man7/vdevprops.7 | 12 +- sys/contrib/openzfs/man/man7/zfsprops.7 | 17 + sys/contrib/openzfs/man/man7/zpoolconcepts.7 | 4 +- sys/contrib/openzfs/man/man8/zfs-mount.8 | 6 +- sys/contrib/openzfs/man/man8/zinject.8 | 1 + sys/contrib/openzfs/man/man8/zpool-add.8 | 18 +- sys/contrib/openzfs/man/man8/zpool-clear.8 | 7 +- sys/contrib/openzfs/man/man8/zpool-status.8 | 18 +- .../icp/asm-aarch64/blake3/b3_aarch64_sse2.S | 14 +- .../icp/asm-aarch64/blake3/b3_aarch64_sse41.S | 12 +- .../module/icp/asm-aarch64/sha2/sha256-armv8.S | 10 + .../module/icp/asm-aarch64/sha2/sha512-armv8.S | 10 + sys/contrib/openzfs/module/nvpair/nvpair.c | 1 + sys/contrib/openzfs/module/os/freebsd/zfs/abd_os.c | 4 +- .../openzfs/module/os/freebsd/zfs/zfs_vnops_os.c | 4 +- .../openzfs/module/os/freebsd/zfs/zvol_os.c | 2 +- .../openzfs/module/os/linux/spl/spl-taskq.c | 85 +- sys/contrib/openzfs/module/os/linux/spl/spl-xdr.c | 1 + sys/contrib/openzfs/module/os/linux/zfs/abd_os.c | 123 ++- .../openzfs/module/os/linux/zfs/vdev_disk.c | 913 ++++++++++++++++----- .../openzfs/module/os/linux/zfs/zfs_vnops_os.c | 12 +- sys/contrib/openzfs/module/os/linux/zfs/zpl_file.c | 8 +- .../openzfs/module/os/linux/zfs/zpl_file_range.c | 16 +- sys/contrib/openzfs/module/os/linux/zfs/zvol_os.c | 140 +++- sys/contrib/openzfs/module/zcommon/zfs_prop.c | 11 + sys/contrib/openzfs/module/zcommon/zpool_prop.c | 6 + sys/contrib/openzfs/module/zfs/abd.c | 42 + sys/contrib/openzfs/module/zfs/arc.c | 179 ++-- sys/contrib/openzfs/module/zfs/brt.c | 147 +--- sys/contrib/openzfs/module/zfs/dbuf.c | 160 ++-- sys/contrib/openzfs/module/zfs/dmu.c | 149 ++-- sys/contrib/openzfs/module/zfs/dmu_objset.c | 29 +- sys/contrib/openzfs/module/zfs/dmu_recv.c | 17 +- sys/contrib/openzfs/module/zfs/dmu_zfetch.c | 296 +++++-- sys/contrib/openzfs/module/zfs/dsl_deadlist.c | 8 +- sys/contrib/openzfs/module/zfs/metaslab.c | 8 +- sys/contrib/openzfs/module/zfs/mmp.c | 5 +- sys/contrib/openzfs/module/zfs/multilist.c | 26 +- sys/contrib/openzfs/module/zfs/spa.c | 149 +++- sys/contrib/openzfs/module/zfs/spa_log_spacemap.c | 16 +- sys/contrib/openzfs/module/zfs/spa_misc.c | 74 +- sys/contrib/openzfs/module/zfs/txg.c | 9 + sys/contrib/openzfs/module/zfs/vdev.c | 52 +- sys/contrib/openzfs/module/zfs/vdev_label.c | 4 +- sys/contrib/openzfs/module/zfs/vdev_raidz.c | 5 +- sys/contrib/openzfs/module/zfs/zap.c | 43 +- sys/contrib/openzfs/module/zfs/zap_leaf.c | 77 +- sys/contrib/openzfs/module/zfs/zap_micro.c | 206 +++-- sys/contrib/openzfs/module/zfs/zfs_fm.c | 26 + sys/contrib/openzfs/module/zfs/zfs_ioctl.c | 13 +- sys/contrib/openzfs/module/zfs/zfs_vnops.c | 6 +- sys/contrib/openzfs/module/zfs/zil.c | 352 +++++--- sys/contrib/openzfs/module/zfs/zio.c | 42 +- sys/contrib/openzfs/module/zfs/zio_inject.c | 6 + sys/contrib/openzfs/module/zfs/zvol.c | 2 +- sys/contrib/openzfs/rpm/redhat/zfs-kmod.spec.in | 2 +- sys/contrib/openzfs/tests/runfiles/common.run | 8 +- sys/contrib/openzfs/tests/runfiles/linux.run | 5 +- sys/contrib/openzfs/tests/runfiles/sanity.run | 3 +- .../openzfs/tests/zfs-tests/tests/Makefile.am | 5 + .../tests/functional/bclone/bclone_common.kshlib | 47 +- .../functional/bclone/bclone_corner_cases.kshlib | 20 +- .../functional/cli_root/zfs_mount/zfs_mount.cfg | 1 + .../cli_root/zfs_mount/zfs_mount_recursive.ksh | 146 ++++ .../functional/cli_root/zpool_add/add-o_ashift.ksh | 17 +- .../cli_root/zpool_add/add_prop_ashift.ksh | 16 +- .../zpool_add/zpool_add--allow-ashift-mismatch.ksh | 0 .../cli_root/zpool_add/zpool_add_002_pos.ksh | 11 + .../cli_root/zpool_add/zpool_add_004_pos.ksh | 2 +- .../cli_root/zpool_add/zpool_add_005_pos.ksh | 2 + .../cli_root/zpool_add/zpool_add_009_neg.ksh | 2 + .../cli_root/zpool_add/zpool_add_010_pos.ksh | 2 +- .../functional/cli_root/zpool_get/vdev_get.cfg | 2 + .../cli_root/zpool_import/zpool_import_status.ksh | 132 +++ .../tests/functional/cp_files/cp_files_002_pos.ksh | 6 +- .../zfs-tests/tests/functional/events/cleanup.ksh | 4 +- .../tests/functional/events/zed_slow_io.ksh | 205 +++++ .../functional/events/zed_slow_io_many_vdevs.ksh | 177 ++++ .../zfs-tests/tests/functional/fault/cleanup.ksh | 1 + .../zfs-tests/tests/functional/fault/setup.ksh | 1 + .../tests/functional/mmp/mmp_write_slow_disk.ksh | 97 +++ .../user_namespace/user_namespace_004.ksh | 4 +- sys/contrib/openzfs/udev/zvol_id.c | 9 +- sys/modules/zfs/zfs_config.h | 50 +- sys/modules/zfs/zfs_gitrev.h | 2 +- 158 files changed, 4808 insertions(+), 1646 deletions(-) diff --git a/cddl/lib/libnvpair/Makefile b/cddl/lib/libnvpair/Makefile index fb80d7c22ea5..a93ffcbd00de 100644 --- a/cddl/lib/libnvpair/Makefile +++ b/cddl/lib/libnvpair/Makefile @@ -27,6 +27,4 @@ CFLAGS+= -I${SRCTOP}/cddl/compat/opensolaris/include CFLAGS+= -include ${SRCTOP}/sys/contrib/openzfs/include/os/freebsd/spl/sys/ccompile.h CFLAGS+= -DHAVE_ISSETUGID -DHAVE_CONFIG_H -DHAVE_XDR_BYTESREC - -CFLAGS.nvpair.c+= -UHAVE_RPC_TYPES .include diff --git a/sys/contrib/openzfs/.mailmap b/sys/contrib/openzfs/.mailmap index 46ef016b93f8..32bdb5209613 100644 --- a/sys/contrib/openzfs/.mailmap +++ b/sys/contrib/openzfs/.mailmap @@ -30,6 +30,7 @@ Andreas Dilger Andrew Walker Benedikt Neuffer Chengfei Zhu +ChenHao Lu <18302010006@fudan.edu.cn> Chris Lindee Colm Buckley Crag Wang @@ -43,6 +44,7 @@ Glenn Washburn Gordan Bobic Gregory Bartholomew hedong zhang +Ilkka Sovanto InsanePrawn Jason Cohen Jason Harmening @@ -57,6 +59,7 @@ KernelOfTruth Liu Hua Liu Qing loli10K +Mart Frauenlob Matthias Blankertz Michael Gmelin Olivier Mazouffre @@ -73,6 +76,9 @@ WHR Yanping Gao Youzhong Yang +# Signed-off-by: overriding Author: +Yuxin Wang + # Commits from strange places, long ago Brian Behlendorf Brian Behlendorf @@ -102,12 +108,15 @@ Brandon Thetford buzzingwires <131118055+buzzingwires@users.noreply.github.com> Cedric Maunoury <38213715+cedricmaunoury@users.noreply.github.com> Charles Suh +Chris Peredun <126915832+chrisperedun@users.noreply.github.com> Dacian Reece-Stremtan <35844628+dacianstremtan@users.noreply.github.com> Damian Szuberski <30863496+szubersk@users.noreply.github.com> Daniel Hiepler <32984777+heeplr@users.noreply.github.com> Daniel Kobras Daniel Reichelt David Quigley +Dennis R. Friedrichsen <31087738+dennisfriedrichsen@users.noreply.github.com> +Dex Wood DHE Dmitri John Ledkov <19779+xnox@users.noreply.github.com> Dries Michiels <32487486+driesmp@users.noreply.github.com> @@ -128,6 +137,7 @@ Harry Mallon <1816667+hjmallon@users.noreply.github.com> Hiếu Lê Jake Howard James Cowgill +Jaron Kent-Dobias Jason King Jeff Dike <52420226+jdike@users.noreply.github.com> Jitendra Patidar <53164267+jsai20@users.noreply.github.com> @@ -137,7 +147,9 @@ John L. Hammond <35266395+jhammond-intel@users.noreply. John-Mark Gurney John Ramsden Jonathon Fernyhough <559369+jonathonf@users.noreply.github.com> +Jose Luis Duran Justin Hibbits +Kevin Greene <104801862+kxgreene@users.noreply.github.com> Kevin Jin <33590050+jxdking@users.noreply.github.com> Kevin P. Fleming Krzysztof Piecuch <3964215+pikrzysztof@users.noreply.github.com> @@ -148,9 +160,11 @@ Lorenz Hüdepohl Luís Henriques <73643340+lumigch@users.noreply.github.com> Marcin Skarbek Matt Fiddaman <81489167+matt-fidd@users.noreply.github.com> +Maxim Filimonov Max Zettlmeißl <6818198+maxz@users.noreply.github.com> Michael Niewöhner Michael Zhivich <33133421+mzhivich@users.noreply.github.com> +MigeljanImeri <78048439+MigeljanImeri@users.noreply.github.com> Mo Zhou <5723047+cdluminate@users.noreply.github.com> Nick Mattis omni <79493359+omnivagant@users.noreply.github.com> @@ -164,6 +178,7 @@ Ping Huang <101400146+hpingfs@users.noreply.github.com> Piotr P. Stefaniak Richard Allen <33836503+belperite@users.noreply.github.com> Rich Ercolani <214141+rincebrain@users.noreply.github.com> +Rick Macklem <64620010+rmacklem@users.noreply.github.com> Rob Wing <98866084+rob-wing@users.noreply.github.com> Roman Strashkin Ryan Hirasaki <4690732+RyanHir@users.noreply.github.com> @@ -174,6 +189,8 @@ Scott Colby Sean Eric Fagan Spencer Kinny <30333052+Spencer-Kinny@users.noreply.github.com> Srikanth N S <75025422+nssrikanth@users.noreply.github.com> +Stefan Lendl <1321542+stfl@users.noreply.github.com> +Thomas Bertschinger <101425190+bertschinger@users.noreply.github.com> Thomas Geppert Tim Crawford Tom Matthews @@ -181,6 +198,7 @@ Tony Perkins <62951051+tony-zfs@users.noreply.github.com> Torsten Wörtwein Tulsi Jain Václav Skála <33496485+vaclavskala@users.noreply.github.com> +Vaibhav Bhanawat <88050553+vaibhav-delphix@users.noreply.github.com> Violet Purcell <66446404+vimproved@users.noreply.github.com> Vipin Kumar Verma <75025470+vermavipinkumar@users.noreply.github.com> Wolfgang Bumiller diff --git a/sys/contrib/openzfs/AUTHORS b/sys/contrib/openzfs/AUTHORS index be1efb87b34c..d7d55f42d2e7 100644 --- a/sys/contrib/openzfs/AUTHORS +++ b/sys/contrib/openzfs/AUTHORS @@ -88,9 +88,11 @@ CONTRIBUTORS: Bassu Ben Allen Ben Cordero + Benda Xu Benedikt Neuffer Benjamin Albrecht Benjamin Gentil + Benjamin Sherman Ben McGough Ben Rubson Ben Wolsieffer @@ -111,6 +113,7 @@ CONTRIBUTORS: bzzz77 cable2999 Caleb James DeLisle + Cameron Harr Cao Xuewen Carlo Landmeter Carlos Alberto Lopez Perez @@ -120,12 +123,15 @@ CONTRIBUTORS: Chen Can Chengfei Zhu Chen Haiquan + ChenHao Lu <18302010006@fudan.edu.cn> Chip Parker Chris Burroughs + Chris Davidson Chris Dunlap Chris Dunlop Chris Lindee Chris McDonough + Chris Peredun Chris Siden Chris Siebenmann Christer Ekholm @@ -144,6 +150,7 @@ CONTRIBUTORS: Clint Armstrong Coleman Kane Colin Ian King + Colin Percival Colm Buckley Crag Wang Craig Loomis @@ -156,6 +163,7 @@ CONTRIBUTORS: Damiano Albani Damian Szuberski Damian Wojsław + Daniel Berlin Daniel Hiepler Daniel Hoffman Daniel Kobras @@ -176,8 +184,10 @@ CONTRIBUTORS: David Quigley Debabrata Banerjee D. Ebdrup + Dennis R. Friedrichsen Denys Rtveliashvili Derek Dai + Dex Wood DHE Didier Roche Dimitri John Ledkov @@ -235,9 +245,11 @@ CONTRIBUTORS: Gionatan Danti Giuseppe Di Natale Glenn Washburn + gofaster Gordan Bobic Gordon Bergling Gordon Ross + Gordon Tetlow Graham Christensen Graham Perrin Gregor Kopka @@ -265,6 +277,7 @@ CONTRIBUTORS: Igor Kozhukhov Igor Lvovsky ilbsmart + Ilkka Sovanto illiliti ilovezfs InsanePrawn @@ -280,9 +293,11 @@ CONTRIBUTORS: Jan Engelhardt Jan Kryl Jan Sanislo + Jaron Kent-Dobias Jason Cohen Jason Harmening Jason King + Jason Lee Jason Zaman Javen Wu Jean-Baptiste Lallement @@ -313,6 +328,7 @@ CONTRIBUTORS: Jonathon Fernyhough Jorgen Lundman Josef 'Jeff' Sipek + Jose Luis Duran Josh Soref Joshua M. Clulow José Luis Salvador Rufo @@ -336,8 +352,10 @@ CONTRIBUTORS: Kash Pande Kay Pedersen Keith M Wesolowski + Kent Ross KernelOfTruth Kevin Bowling + Kevin Greene Kevin Jin Kevin P. Fleming Kevin Tanguy @@ -389,6 +407,7 @@ CONTRIBUTORS: Mark Shellenbaum marku89 Mark Wright + Mart Frauenlob Martin Matuska Martin Rüegg Massimo Maggi @@ -405,6 +424,7 @@ CONTRIBUTORS: Matus Kral Mauricio Faria de Oliveira Max Grossman + Maxim Filimonov Maximilian Mehnert Max Zettlmeißl Md Islam @@ -417,6 +437,7 @@ CONTRIBUTORS: Michael Niewöhner Michael Zhivich Michal Vasilek + MigeljanImeri Mike Gerdts Mike Harsch Mike Leddy @@ -448,6 +469,7 @@ CONTRIBUTORS: Olaf Faaland Oleg Drokin Oleg Stepura + Olivier Certner Olivier Mazouffre omni Orivej Desh @@ -479,6 +501,7 @@ CONTRIBUTORS: Prasad Joshi privb0x23 P.SCH + Quartz Quentin Zdanis Rafael Kitover RageLtMan @@ -491,11 +514,15 @@ CONTRIBUTORS: Riccardo Schirone Richard Allen Richard Elling + Richard Kojedzinszky Richard Laager Richard Lowe Richard Sharpe Richard Yao Rich Ercolani + Rick Macklem + rilysh + Robert Evans Robert Novak Roberto Ricci Rob Norris @@ -509,7 +536,9 @@ CONTRIBUTORS: Ryan Lahfa Ryan Libby Ryan Moeller + Sam Atkinson Sam Hathaway + Sam James Sam Lunt Samuel VERSCHELDE Samuel Wycliffe @@ -530,6 +559,8 @@ CONTRIBUTORS: Shaan Nobee Shampavman Shaun Tancheff + Shawn Bayern + Shengqi Chen Shen Yan Simon Guest Simon Klinkert @@ -537,6 +568,7 @@ CONTRIBUTORS: Spencer Kinny Srikanth N S Stanislav Seletskiy + Stefan Lendl Steffen Müthing Stephen Blinick sterlingjensen @@ -557,6 +589,7 @@ CONTRIBUTORS: Teodor Spæren TerraTech Thijs Cramer + Thomas Bertschinger Thomas Geppert Thomas Lamprecht Till Maas @@ -586,6 +619,7 @@ CONTRIBUTORS: Turbo Fredriksson Tyler J. Stachecki Umer Saleem + Vaibhav Bhanawat Valmiky Arquissandas Val Packett Vince van Oosten @@ -614,6 +648,7 @@ CONTRIBUTORS: yuina822 YunQiang Su Yuri Pankov + Yuxin Wang Yuxuan Shui Zachary Bedell Zach Dykstra diff --git a/sys/contrib/openzfs/META b/sys/contrib/openzfs/META index d64414e32225..383fa37fd42a 100644 --- a/sys/contrib/openzfs/META +++ b/sys/contrib/openzfs/META @@ -1,10 +1,10 @@ Meta: 1 Name: zfs Branch: 1.0 -Version: 2.2.3 +Version: 2.2.4 Release: 1 Release-Tags: relext License: CDDL Author: OpenZFS -Linux-Maximum: 6.7 +Linux-Maximum: 6.8 Linux-Minimum: 3.10 diff --git a/sys/contrib/openzfs/cmd/arc_summary b/sys/contrib/openzfs/cmd/arc_summary index 9c69ec4f8ccc..100fb1987a8b 100755 --- a/sys/contrib/openzfs/cmd/arc_summary +++ b/sys/contrib/openzfs/cmd/arc_summary @@ -793,18 +793,27 @@ def section_dmu(kstats_dict): zfetch_stats = isolate_section('zfetchstats', kstats_dict) - zfetch_access_total = int(zfetch_stats['hits'])+int(zfetch_stats['misses']) + zfetch_access_total = int(zfetch_stats['hits']) +\ + int(zfetch_stats['future']) + int(zfetch_stats['stride']) +\ + int(zfetch_stats['past']) + int(zfetch_stats['misses']) prt_1('DMU predictive prefetcher calls:', f_hits(zfetch_access_total)) prt_i2('Stream hits:', f_perc(zfetch_stats['hits'], zfetch_access_total), f_hits(zfetch_stats['hits'])) + future = int(zfetch_stats['future']) + int(zfetch_stats['stride']) + prt_i2('Hits ahead of stream:', f_perc(future, zfetch_access_total), + f_hits(future)) + prt_i2('Hits behind stream:', + f_perc(zfetch_stats['past'], zfetch_access_total), + f_hits(zfetch_stats['past'])) prt_i2('Stream misses:', f_perc(zfetch_stats['misses'], zfetch_access_total), f_hits(zfetch_stats['misses'])) prt_i2('Streams limit reached:', f_perc(zfetch_stats['max_streams'], zfetch_stats['misses']), f_hits(zfetch_stats['max_streams'])) + prt_i1('Stream strides:', f_hits(zfetch_stats['stride'])) prt_i1('Prefetches issued', f_hits(zfetch_stats['io_issued'])) print() diff --git a/sys/contrib/openzfs/cmd/arcstat.in b/sys/contrib/openzfs/cmd/arcstat.in index 8df1c62f7e86..c4f10a1d6d3b 100755 --- a/sys/contrib/openzfs/cmd/arcstat.in +++ b/sys/contrib/openzfs/cmd/arcstat.in @@ -157,6 +157,16 @@ cols = { "free": [5, 1024, "ARC free memory"], "avail": [5, 1024, "ARC available memory"], "waste": [5, 1024, "Wasted memory due to round up to pagesize"], + "ztotal": [6, 1000, "zfetch total prefetcher calls per second"], + "zhits": [5, 1000, "zfetch stream hits per second"], + "zahead": [6, 1000, "zfetch hits ahead of streams per second"], + "zpast": [5, 1000, "zfetch hits behind streams per second"], + "zmisses": [7, 1000, "zfetch stream misses per second"], + "zmax": [4, 1000, "zfetch limit reached per second"], + "zfuture": [7, 1000, "zfetch stream future per second"], + "zstride": [7, 1000, "zfetch stream strides per second"], + "zissued": [7, 1000, "zfetch prefetches issued per second"], + "zactive": [7, 1000, "zfetch prefetches active per second"], } v = {} @@ -164,6 +174,8 @@ hdr = ["time", "read", "ddread", "ddh%", "dmread", "dmh%", "pread", "ph%", "size", "c", "avail"] xhdr = ["time", "mfu", "mru", "mfug", "mrug", "unc", "eskip", "mtxmis", "dread", "pread", "read"] +zhdr = ["time", "ztotal", "zhits", "zahead", "zpast", "zmisses", "zmax", + "zfuture", "zstride", "zissued", "zactive"] sint = 1 # Default interval is 1 second count = 1 # Default count is 1 hdr_intr = 20 # Print header every 20 lines of output @@ -188,6 +200,8 @@ if sys.platform.startswith('freebsd'): k = [ctl for ctl in sysctl.filter('kstat.zfs.misc.arcstats') if ctl.type != sysctl.CTLTYPE_NODE] + k += [ctl for ctl in sysctl.filter('kstat.zfs.misc.zfetchstats') + if ctl.type != sysctl.CTLTYPE_NODE] if not k: sys.exit(1) @@ -199,19 +213,28 @@ if sys.platform.startswith('freebsd'): continue name, value = s.name, s.value - # Trims 'kstat.zfs.misc.arcstats' from the name - kstat[name[24:]] = int(value) + + if "arcstats" in name: + # Trims 'kstat.zfs.misc.arcstats' from the name + kstat[name[24:]] = int(value) + else: + kstat["zfetch_" + name[27:]] = int(value) elif sys.platform.startswith('linux'): def kstat_update(): global kstat - k = [line.strip() for line in open('/proc/spl/kstat/zfs/arcstats')] + k1 = [line.strip() for line in open('/proc/spl/kstat/zfs/arcstats')] - if not k: + k2 = ["zfetch_" + line.strip() for line in + open('/proc/spl/kstat/zfs/zfetchstats')] + + if k1 is None or k2 is None: sys.exit(1) - del k[0:2] + del k1[0:2] + del k2[0:2] + k = k1 + k2 kstat = {} for s in k: @@ -239,6 +262,7 @@ def usage(): sys.stderr.write("\t -v : List all possible field headers and definitions" "\n") sys.stderr.write("\t -x : Print extended stats\n") + sys.stderr.write("\t -z : Print zfetch stats\n") sys.stderr.write("\t -f : Specify specific fields to print (see -v)\n") sys.stderr.write("\t -o : Redirect output to the specified file\n") sys.stderr.write("\t -s : Override default field separator with custom " @@ -357,6 +381,7 @@ def init(): global count global hdr global xhdr + global zhdr global opfile global sep global out @@ -368,15 +393,17 @@ def init(): xflag = False hflag = False vflag = False + zflag = False i = 1 try: opts, args = getopt.getopt( sys.argv[1:], - "axo:hvs:f:p", + "axzo:hvs:f:p", [ "all", "extended", + "zfetch", "outfile", "help", "verbose", @@ -410,13 +437,15 @@ def init(): i += 1 if opt in ('-p', '--parsable'): pretty_print = False + if opt in ('-z', '--zfetch'): + zflag = True i += 1 argv = sys.argv[i:] sint = int(argv[0]) if argv else sint count = int(argv[1]) if len(argv) > 1 else (0 if len(argv) > 0 else 1) - if hflag or (xflag and desired_cols): + if hflag or (xflag and zflag) or ((zflag or xflag) and desired_cols): usage() if vflag: @@ -425,6 +454,9 @@ def init(): if xflag: hdr = xhdr + if zflag: + hdr = zhdr + update_hdr_intr() # check if L2ARC exists @@ -569,6 +601,17 @@ def calculate(): v["el2mru"] = d["evict_l2_eligible_mru"] // sint v["el2inel"] = d["evict_l2_ineligible"] // sint v["mtxmis"] = d["mutex_miss"] // sint + v["ztotal"] = (d["zfetch_hits"] + d["zfetch_future"] + d["zfetch_stride"] + + d["zfetch_past"] + d["zfetch_misses"]) // sint + v["zhits"] = d["zfetch_hits"] // sint + v["zahead"] = (d["zfetch_future"] + d["zfetch_stride"]) // sint + v["zpast"] = d["zfetch_past"] // sint + v["zmisses"] = d["zfetch_misses"] // sint + v["zmax"] = d["zfetch_max_streams"] // sint + v["zfuture"] = d["zfetch_future"] // sint + v["zstride"] = d["zfetch_stride"] // sint + v["zissued"] = d["zfetch_io_issued"] // sint + v["zactive"] = d["zfetch_io_active"] // sint if l2exist: v["l2hits"] = d["l2_hits"] // sint diff --git a/sys/contrib/openzfs/cmd/zed/agents/fmd_api.c b/sys/contrib/openzfs/cmd/zed/agents/fmd_api.c index 4a6cfbf8c05c..fe43e2ab971e 100644 --- a/sys/contrib/openzfs/cmd/zed/agents/fmd_api.c +++ b/sys/contrib/openzfs/cmd/zed/agents/fmd_api.c @@ -22,6 +22,7 @@ * Copyright (c) 2004, 2010, Oracle and/or its affiliates. All rights reserved. * * Copyright (c) 2016, Intel Corporation. + * Copyright (c) 2023, Klara Inc. */ /* @@ -231,28 +232,6 @@ fmd_prop_get_int32(fmd_hdl_t *hdl, const char *name) if (strcmp(name, "spare_on_remove") == 0) return (1); - if (strcmp(name, "io_N") == 0 || strcmp(name, "checksum_N") == 0) - return (10); /* N = 10 events */ - - return (0); -} - -int64_t -fmd_prop_get_int64(fmd_hdl_t *hdl, const char *name) -{ - (void) hdl; - - /* - * These can be looked up in mp->modinfo->fmdi_props - * For now we just hard code for phase 2. In the - * future, there can be a ZED based override. - */ - if (strcmp(name, "remove_timeout") == 0) - return (15ULL * 1000ULL * 1000ULL * 1000ULL); /* 15 sec */ - - if (strcmp(name, "io_T") == 0 || strcmp(name, "checksum_T") == 0) - return (1000ULL * 1000ULL * 1000ULL * 600ULL); /* 10 min */ - return (0); } @@ -535,20 +514,31 @@ fmd_serd_exists(fmd_hdl_t *hdl, const char *name) return (fmd_serd_eng_lookup(&mp->mod_serds, name) != NULL); } -void -fmd_serd_reset(fmd_hdl_t *hdl, const char *name) +int +fmd_serd_active(fmd_hdl_t *hdl, const char *name) { fmd_module_t *mp = (fmd_module_t *)hdl; fmd_serd_eng_t *sgp; if ((sgp = fmd_serd_eng_lookup(&mp->mod_serds, name)) == NULL) { zed_log_msg(LOG_ERR, "serd engine '%s' does not exist", name); - return; + return (0); } + return (fmd_serd_eng_fired(sgp) || !fmd_serd_eng_empty(sgp)); +} - fmd_serd_eng_reset(sgp); +void +fmd_serd_reset(fmd_hdl_t *hdl, const char *name) +{ + fmd_module_t *mp = (fmd_module_t *)hdl; + fmd_serd_eng_t *sgp; - fmd_hdl_debug(hdl, "serd_reset %s", name); + if ((sgp = fmd_serd_eng_lookup(&mp->mod_serds, name)) == NULL) { + zed_log_msg(LOG_ERR, "serd engine '%s' does not exist", name); + } else { + fmd_serd_eng_reset(sgp); + fmd_hdl_debug(hdl, "serd_reset %s", name); + } } int @@ -556,16 +546,21 @@ fmd_serd_record(fmd_hdl_t *hdl, const char *name, fmd_event_t *ep) { fmd_module_t *mp = (fmd_module_t *)hdl; fmd_serd_eng_t *sgp; - int err; if ((sgp = fmd_serd_eng_lookup(&mp->mod_serds, name)) == NULL) { zed_log_msg(LOG_ERR, "failed to add record to SERD engine '%s'", name); return (0); } - err = fmd_serd_eng_record(sgp, ep->ev_hrt); + return (fmd_serd_eng_record(sgp, ep->ev_hrt)); +} + +void +fmd_serd_gc(fmd_hdl_t *hdl) +{ + fmd_module_t *mp = (fmd_module_t *)hdl; - return (err); + fmd_serd_hash_apply(&mp->mod_serds, fmd_serd_eng_gc, NULL); } /* FMD Timers */ @@ -579,7 +574,7 @@ _timer_notify(union sigval sv) const fmd_hdl_ops_t *ops = mp->mod_info->fmdi_ops; struct itimerspec its; - fmd_hdl_debug(hdl, "timer fired (%p)", ftp->ft_tid); + fmd_hdl_debug(hdl, "%s timer fired (%p)", mp->mod_name, ftp->ft_tid); /* disarm the timer */ memset(&its, 0, sizeof (struct itimerspec)); diff --git a/sys/contrib/openzfs/cmd/zed/agents/fmd_api.h b/sys/contrib/openzfs/cmd/zed/agents/fmd_api.h index b940d0d395ec..8471feecf33f 100644 --- a/sys/contrib/openzfs/cmd/zed/agents/fmd_api.h +++ b/sys/contrib/openzfs/cmd/zed/agents/fmd_api.h @@ -151,7 +151,6 @@ extern void fmd_hdl_vdebug(fmd_hdl_t *, const char *, va_list); extern void fmd_hdl_debug(fmd_hdl_t *, const char *, ...); extern int32_t fmd_prop_get_int32(fmd_hdl_t *, const char *); -extern int64_t fmd_prop_get_int64(fmd_hdl_t *, const char *); #define FMD_STAT_NOALLOC 0x0 /* fmd should use caller's memory */ #define FMD_STAT_ALLOC 0x1 /* fmd should allocate stats memory */ @@ -195,10 +194,12 @@ extern size_t fmd_buf_size(fmd_hdl_t *, fmd_case_t *, const char *); extern void fmd_serd_create(fmd_hdl_t *, const char *, uint_t, hrtime_t); extern void fmd_serd_destroy(fmd_hdl_t *, const char *); extern int fmd_serd_exists(fmd_hdl_t *, const char *); +extern int fmd_serd_active(fmd_hdl_t *, const char *); extern void fmd_serd_reset(fmd_hdl_t *, const char *); extern int fmd_serd_record(fmd_hdl_t *, const char *, fmd_event_t *); extern int fmd_serd_fired(fmd_hdl_t *, const char *); extern int fmd_serd_empty(fmd_hdl_t *, const char *); +extern void fmd_serd_gc(fmd_hdl_t *); extern id_t fmd_timer_install(fmd_hdl_t *, void *, fmd_event_t *, hrtime_t); extern void fmd_timer_remove(fmd_hdl_t *, id_t); diff --git a/sys/contrib/openzfs/cmd/zed/agents/fmd_serd.c b/sys/contrib/openzfs/cmd/zed/agents/fmd_serd.c index 0bb2c535f094..f942e62b3f48 100644 --- a/sys/contrib/openzfs/cmd/zed/agents/fmd_serd.c +++ b/sys/contrib/openzfs/cmd/zed/agents/fmd_serd.c @@ -310,8 +310,9 @@ fmd_serd_eng_reset(fmd_serd_eng_t *sgp) } void -fmd_serd_eng_gc(fmd_serd_eng_t *sgp) +fmd_serd_eng_gc(fmd_serd_eng_t *sgp, void *arg) { + (void) arg; fmd_serd_elem_t *sep, *nep; hrtime_t hrt; diff --git a/sys/contrib/openzfs/cmd/zed/agents/fmd_serd.h b/sys/contrib/openzfs/cmd/zed/agents/fmd_serd.h index 25b6888e61f2..80ff9a3b25b8 100644 --- a/sys/contrib/openzfs/cmd/zed/agents/fmd_serd.h +++ b/sys/contrib/openzfs/cmd/zed/agents/fmd_serd.h @@ -77,7 +77,7 @@ extern int fmd_serd_eng_fired(fmd_serd_eng_t *); extern int fmd_serd_eng_empty(fmd_serd_eng_t *); extern void fmd_serd_eng_reset(fmd_serd_eng_t *); -extern void fmd_serd_eng_gc(fmd_serd_eng_t *); +extern void fmd_serd_eng_gc(fmd_serd_eng_t *, void *); #ifdef __cplusplus } diff --git a/sys/contrib/openzfs/cmd/zed/agents/zfs_diagnosis.c b/sys/contrib/openzfs/cmd/zed/agents/zfs_diagnosis.c index f6ba334a3ba3..e0ad00800add 100644 --- a/sys/contrib/openzfs/cmd/zed/agents/zfs_diagnosis.c +++ b/sys/contrib/openzfs/cmd/zed/agents/zfs_diagnosis.c @@ -23,6 +23,7 @@ * Copyright (c) 2010, Oracle and/or its affiliates. All rights reserved. * Copyright 2015 Nexenta Systems, Inc. All rights reserved. * Copyright (c) 2016, Intel Corporation. + * Copyright (c) 2023, Klara Inc. */ #include @@ -47,11 +48,16 @@ #define DEFAULT_CHECKSUM_T 600 /* seconds */ #define DEFAULT_IO_N 10 /* events */ #define DEFAULT_IO_T 600 /* seconds */ +#define DEFAULT_SLOW_IO_N 10 /* events */ +#define DEFAULT_SLOW_IO_T 30 /* seconds */ + +#define CASE_GC_TIMEOUT_SECS 43200 /* 12 hours */ /* - * Our serd engines are named 'zfs___{checksum,io}'. This - * #define reserves enough space for two 64-bit hex values plus the length of - * the longest string. + * Our serd engines are named in the following format: + * 'zfs___{checksum,io,slow_io}' + * This #define reserves enough space for two 64-bit hex values plus the + * length of the longest string. */ #define MAX_SERDLEN (16 * 2 + sizeof ("zfs___checksum")) @@ -68,6 +74,7 @@ typedef struct zfs_case_data { int zc_pool_state; char zc_serd_checksum[MAX_SERDLEN]; char zc_serd_io[MAX_SERDLEN]; + char zc_serd_slow_io[MAX_SERDLEN]; int zc_has_remove_timer; } zfs_case_data_t; @@ -114,7 +121,8 @@ zfs_de_stats_t zfs_stats = { { "resource_drops", FMD_TYPE_UINT64, "resource related ereports" } }; -static hrtime_t zfs_remove_timeout; +/* wait 15 seconds after a removal */ +static hrtime_t zfs_remove_timeout = SEC2NSEC(15); uu_list_pool_t *zfs_case_pool; *** 11838 LINES SKIPPED ***