aboutsummaryrefslogtreecommitdiff
Commit message (Collapse)AuthorAgeFilesLines
...
* | | | | | Revert "bsd.own.mk: Deorbit compat include of bsd.compiler.mk"Mateusz Piotrowski2026-03-151-0/+6
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This reverts commit 0bebad8d072bb7abef1cea0d8c8d04d500913adf. It might be that all that's needed to fix this is to add ".include <bsd.compiler.mk>" to some Makefiles. I'll look into it soon but for now let's unbreak HEAD. Approved by: bnovkov (mentor) Differential Revision: https://reviews.freebsd.org/D55869
* | | | | | backlight.8: Fix typo in manSalman Sarray2026-03-151-2/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Increment and decrement where swapped. Signed-off-by: Salman Sarray <salman@sarray.de> Reviewed by: ziaee, Christos Longros <chris.longros@gmail.com> Pull Request: https://github.com/freebsd/freebsd-src/pull/2072
* | | | | | rtlbtfw(8): Add support for Realtek 8852CEYing Xu2026-03-153-1/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Add the USB Vendor/Product ID (0x13d3:0x3612) for the new Realtek 8852CE drive to make sure it works. Signed-off-by: Ying Xu <fakeshadow1337@gmail.com> Reviewed by: pouria, wulf Pull Request: https://github.com/freebsd/freebsd-src/pull/2071
* | | | | | bsd.own.mk: Deorbit compat include of bsd.compiler.mkMateusz Piotrowski2026-03-151-6/+0
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Commit b946bedd09d3bd1 ("Previous versions of bsd.own.mk [...]") mentions that bsd.own.mk included bsd.compiler.mk as a temporary workaround and was destined to be removed in FreeBSD 12. Do that now. PR: 203540 Reviewed by: bnovkov, imp Approved by: bnovkov (mentor) Differential Revision: https://reviews.freebsd.org/D55867
* | | | | | Unbreak LINT after ZFS importDag-Erling Smørgrav2026-03-151-0/+3
| | | | | | | | | | | | | | | | | | | | | | | | Fixes: 8a62a2a5659d ("zfs: merge openzfs/zfs@f8e5af53e")
* | | | | | resolver.5: document six previously undocumented optionsChristos Longros2026-03-151-1/+39
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Document the edns0, inet6, insecure1, insecure2, no-check-names, and rotate options which are parsed by res_init(3) but were not described in the resolver(5) man page. MFC after: 1 week Signed-off-by: Christos Longros <chris.longros@gmail.com> Reviewed by: des Differential Revision: https://reviews.freebsd.org/D55864
* | | | | | amd64: do reset %rip after page fault if pcb_onfault is setKonstantin Belousov2026-03-151-13/+20
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | for any kernel page fault, and not only for EFIRT case. Reported and tested by: pho Fixes: 914a53570750ce5a104a5870403d7669656fddc3 Sponsored by: The FreeBSD Foundation MFC after: 1 week
* | | | | | ipfwpcap: Fix build after libpcap 1.10.6 updateJoseph Mingrone2026-03-151-7/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | pcap-int.h now references SIZEOF_TIME_T from libpcap's config.h, which is not available to consumers of the internal header outside of the libpcap build. Switch to the public <pcap.h> header and replace the direct FILE* casts and ferror()/fflush() calls with pcap_dump_flush(3), which is the correct public API for flushing a pcap dump file. Sponsored by: The FreeBSD Foundation
* | | | | | libpcap: Update to 1.10.6Joseph Mingrone2026-03-1573-1479/+3552
|\ \ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Changes: https://raw.githubusercontent.com/the-tcpdump-group/libpcap/89e982c37c36ad0bf9f10b7ded421cb42422effa/CHANGES Reviewed by: bms, emaste Obtained from: https://www.tcpdump.org/release/libpcap-1.10.6.tar.gz Sponsored by: The FreeBSD Foundation Differential Revision: https://reviews.freebsd.org/D55545 Differential Revision: https://reviews.freebsd.org/D55858
| * | | | | | Import libpcap 1.10.6vendor/libpcap/1.10.6vendor/libpcapJoseph Mingrone2026-01-0769-1387/+3203
| | | | | | |
* | | | | | | re(4), rge(4): improve Realtek driver man pagesChristos Longros2026-03-142-0/+6
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Add D-Link DGE-530(T) and Killer E2600 to the re(4) HARDWARE list. Both are supported by the driver but were missing from the man page. Also add cross-references between re(4) and rge(4) in SEE ALSO, as both are Realtek NIC drivers. Signed-off-by: Christos Longros <chris.longros@gmail.com> Reviewed by: adrian Differential Revision: https://reviews.freebsd.org/D55745
* | | | | | | EC2: Fix comment re avoiding unicodeColin Percival2026-03-141-1/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | We're avoiding *unicode*, not avoiding *ascii*. Reported by: marck Fixes: 277830b4d3ae ("EC2: Don't use unicode in boot loader") MFC after: 3 days
* | | | | | | tarfs: swap deprecated ZSTD_resetDStream() with ZSTD_DCtx_reset()Siva Mahadevan2026-03-141-2/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | ZSTD_resetDStream() is deprecated since 1.5.4: https://github.com/facebook/zstd/commit/5d8cfa6b96a6442ab1251f9de3b47a0eb12561a0 This change is needed to MFV zstd 1.5.7. Approved by: emaste (mentor) MFC after: 3 days Differential Revision: https://reviews.freebsd.org/D55835
* | | | | | | tests/fusefs: fix sign-compare warning on armv7Siva Mahadevan2026-03-141-5/+5
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Fixes: 7e68af7ce2c1b892954df415774fe59fd2f1b62f Reviewed by: asomers Approved by: emaste (mentor) Differential Revision: https://reviews.freebsd.org/D55846
* | | | | | | committers-ports.dot: Add new committer (laurent)Laurent Chardon2026-03-141-1/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Update Mentor (thierry) and Mentee (laurent) Information. Reviewed by: thierry (mentor) Approved by: thierry (mentor) Differential Revision: https://reviews.freebsd.org/D55856
* | | | | | | zfs: merge openzfs/zfs@f8e5af53eMartin Matuska2026-03-14513-10854/+34028
|\ \ \ \ \ \ \ | | |_|/ / / / | |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Notable upstream pull request merges: #17358 4975430cf Add vdev property to disable vdev scheduler #18031 c77f17b75 Add snapshots_changed_nsecs dataset property #18080 dbb3f247e cmd/zfs: clone: accept `-u` to not mount newly created datasets #18089 -multiple Zstd: Update bundled library to version 1.5.7 #18091 2301755df Fix zfs_open() to skip zil_async_to_sync() for the snapshot #18093 -multiple L2ARC: Rework write throttling with DWPD rate limiting and parallel writes #18095 2dbd6af5e Rename several printf attributes declarations to __printf__ #18096 8605bdfdd FreeBSD: unbreak compilation on i386 #18105 794f1587d When receiving a stream with the large block flag, activate feature #18115 765929cb4 DDT: Add locking for table ZAP destruction #18118 09e4e01e9 Fix history logging for `zpool create -t` #18119 2f1f25217 icp: emit .note.GNU-stack section for all ELF targets #18131 3fffe4e70 Fix --enable-invariants on FreeBSD #18133 d2f5cb3a5 Move range_tree, btree, highbit64 to common code #18136 54b141fab FreeBSD: Remove references to DEBUG_VFS_LOCKS #18138 cdf89f413 Flush RRD only when TXGs contain data #18139 a157ef62a Make sure we can still write data to txg #18140 cd895f0e5 remove thread unsafe debug code causing FreeBSD double free panic #18144 4f180e095 Fix activating large_microzap on receive #18146 35b2d3970 Lock db_mtx around arc_release() in couple places #18154 b36472052 nvpair: chase FreeBSD xdrproc_t definition #18160 21bbe7cb6 Improve caching for dbuf prefetches #18177 -multiple Multihost Improvements #18179 2646bd558 Allow rewrite skip cloned and snapshotted blocks #18180 aa29455dd Restrict cloning with different properties #18184 040ba7a7c libzfs: improve error message for zpool create with ENXIO #18188 1412bdc6c zfs_vnops_os.c: Move a vput() to after zfs_setattr_dir() #18198 cc184fe98 Fix `send:raw` permission for send `-w -I` #18208 ba970eb20 Cleanup allocation class selection #18212 0f9564e85 Simplify dnode_level_is_l2cacheable() #18214 370570890 Remove parent ZIO from dbuf_prefetch() #18218 bfb276e55 freebsd: Fix TIMESPEC_OVERFLOW for PowerPC #18222 d06a1d9ac Fix available space accounting for special/dedup #18225 d48967728 ICP: AES-GCM VAES-AVX2: fix typos and document source files #18226 c8a72a27e ICP: AES-GCM assembly: remove unused Gmul functions #18230 -multiple Fix zdb --key crash for unencrypted datasets, and teach tests to understand this better #18233 -multiple icp: add SHA-512 implementation using Intel SHA512 extension #18245 991fc56fa Introduce dedupused/dedupsaved pool properties #18251 6a717f31e Improve misleading error messages for ZPOOL_STATUS_CORRUPT_POOL #18254 7744f0496 SIMD: libspl: test the correct CPUID bit for AVX512VL #18255 6495dafd5 range_tree: use zfs_panic_recover() for partial-overlap remov #18256 3408332d7 zhack: Fix importing large allocation profiles on small pools #18258 f8457fbdc Fix deadlock on dmu_tx_assign() from vdev_rebuild() #18263 f8e5af53e Fix redundant declaration of dsl_pool_t Obtained from: OpenZFS OpenZFS commit: f8e5af53e92fa7c03393fbd4922cb9c1d0c15920
| * | | | | | Fix redundant declaration of dsl_pool_tAkash B2026-02-271-6/+5
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Remove redundant dsl_pool variable and duplicate spa_get_dsl() call in vdev_rebuild_thread. Reviewed-by: Alexander Motin <mav@FreeBSD.org> Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov> Signed-off-by: Akash B <akash-b@hpe.com> Closes #18263
| * | | | | | Fix deadlock on dmu_tx_assign() from vdev_rebuild()Andriy Tkachuk2026-02-263-7/+6
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | vdev_rebuild() is always called with spa_config_lock held in RW_WRITER mode. However, when it tries to call dmu_tx_assign() the latter may hang on dmu_tx_wait() waiting for available txg. But that available txg may not happen because txg_sync takes spa_config_lock in order to process the current txg. So we have a deadlock case here: - dmu_tx_assign() waits for txg holding spa_config_lock; - txg_sync waits for spa_config_lock not progressing with txg. Here are the stacks: __schedule+0x24e/0x590 schedule+0x69/0x110 cv_wait_common+0xf8/0x130 [spl] __cv_wait+0x15/0x20 [spl] dmu_tx_wait+0x8e/0x1e0 [zfs] dmu_tx_assign+0x49/0x80 [zfs] vdev_rebuild_initiate+0x39/0xc0 [zfs] vdev_rebuild+0x84/0x90 [zfs] spa_vdev_attach+0x305/0x680 [zfs] zfs_ioc_vdev_attach+0xc7/0xe0 [zfs] cv_wait_common+0xf8/0x130 [spl] __cv_wait+0x15/0x20 [spl] spa_config_enter+0xf9/0x120 [zfs] spa_sync+0x6d/0x5b0 [zfs] txg_sync_thread+0x266/0x2f0 [zfs] The solution is to pass txg returned by spa_vdev_enter(spa) at the top of spa_vdev_attach() to vdev_rebuild() and call dmu_tx_create_assigned(txg) which doesn't wait for txg. Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov> Reviewed-by: Akash B <akash-b@hpe.com> Reviewed-by: Alek Pinchuk <apinchuk@axcient.com> Signed-off-by: Andriy Tkachuk <andriy.tkachuk@seagate.com> Closes #18210 Closes #18258
| * | | | | | zpl_super: prefer "new" mount API when availableRob Norris2026-02-254-53/+47
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This API has been available since kernel 5.2, and having it available (almost) everywhere should give us a lot more flexibility for mount management in the future. Sponsored-by: TrueNAS Reviewed-by: Tony Hutter <hutter2@llnl.gov> Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov> Signed-off-by: Rob Norris <rob.norris@truenas.com> Closes #18260
| * | | | | | icp: add SHA512 implementation using Intel SHA512 extensionsRob Norris2026-02-252-1/+338
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Generated from crypto/sha/asm/sha512-x86_64.pl in openssl/openssl@241d4826f8. Sponsored-by: TrueNAS Reviewed-by: Tony Hutter <hutter2@llnl.gov> Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov> Reviewed-by: Attila Fülöp <attila@fueloep.org> Signed-off-by: Rob Norris <rob.norris@truenas.com> Closes #18233
| * | | | | | simd: detect and surface support for Intel SHA512 extensionsRob Norris2026-02-254-1/+53
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Recent Intel CPUs (starting with Arrow Lake and Lunar Lake) include new vectorised SHA512 instructions. Detect them and make them available to the rest of the system. Note the internal name "sha512ext". This is to disambiguate from other uses of "sha512". Sponsored-by: TrueNAS Reviewed-by: Tony Hutter <hutter2@llnl.gov> Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov> Reviewed-by: Attila Fülöp <attila@fueloep.org> Signed-off-by: Rob Norris <rob.norris@truenas.com> Closes #18233
| * | | | | | range_tree: use zfs_panic_recover() for partial-overlap removeclefru2026-02-251-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | zfs_range_tree_remove_impl() used a bare panic() when a segment to be removed was not completely overlapped by an existing tree entry. Every other consistency check in range_tree.c uses zfs_panic_recover(), which respects the zfs_recover tunable and allows pools with on-disk corruption to be imported and recovered. This one call was inconsistent, making the partial-overlap case unrecoverable regardless of zfs_recover. Replace panic() with zfs_panic_recover() so that operators can set zfs_recover=1 to import a corrupted pool and reclaim data, consistent with all other range tree error paths. Related-to: https://github.com/openzfs/zfs/issues/13483 Reviewed-by: Tony Hutter <hutter2@llnl.gov> Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov> Signed-off-by: Clemens Fruhwirth <clemens@endorphin.org> Co-authored-by: Claude Sonnet 4.6 <noreply@anthropic.com> Closes #18255
| * | | | | | CI: Remove deprecated Fedora 41Tony Hutter2026-02-253-7/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Fedora 41 was deprecated on Dec 15 2025. Remove it from CI tests. Reviewed-by: Rob Norris <robn@despairlabs.com> Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov> Reviewed-by: George Melikov <mail@gmelikov.ru> Signed-off-by: Tony Hutter <hutter2@llnl.gov> Closes #18261
| * | | | | | Introduce dedupused/dedupsaved pool propertiesAlexander Motin2026-02-2510-3/+53
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Currently there is only a dedup ratio reported via pool properties. If dedup is enabled only for some datasets, it is impossible to say how much space the ratio actually covers. Fix this by introducing dedupused/dedupsaved pool properties, similar to earlier added block cloning ones. Combined with work to expose allocation classes stats, it should give user-space enough visibility to correlate `zpool list` and `zfs list` space numbers. Reviewed-by: Tony Hutter <hutter2@llnl.gov> Reviewed-by: Ryan Moeller <ryan.moeller@klarasystems.com> Signed-off-by: Alexander Motin <alexander.motin@TrueNAS.com> Closes #18245
| * | | | | | zhack: Fix importing large allocation profiles on small pools (#18256)Mateusz Piotrowski2026-02-241-2/+5
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This patch fixes a segmentation fault in zhack metaslab leak which might be triggered by feeding zhack with a fragmentation profile that's exported from a pool larger than the target pool. Fixes: 8f15d2e4d58525e583277ccfef83f2056be4f72e Sponsored-by: Klara, Inc. Sponsored-by: Wasabi Technology, Inc. Reviewed-by: Paul Dagnelie <paul.dagnelie@klarasystems.com> Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov> Signed-off-by: Mateusz Piotrowski <mateusz.piotrowski@klarasystems.com>
| * | | | | | Linux 7.0: add shims for the fs_context-based mount APIRob Norris2026-02-232-1/+72
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The traditional mount API has been removed, so detect when its not available and instead use a small adapter to allow our existing mount functions to keep working. Sponsored-by: TrueNAS Reviewed-by: Tony Hutter <hutter2@llnl.gov> Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov> Signed-off-by: Rob Norris <rob.norris@truenas.com> Closes #18216
| * | | | | | Linux 7.0: posix_acl_to_xattr() now allocates memoryRob Norris2026-02-232-0/+48
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Kernel devs noted that almost all callers to posix_acl_to_xattr() would check the ACL value size and allocate a buffer before make the call. To reduce the repetition, they've changed it to allocate this buffer internally and return it. Unfortunately that's not true for us; most of our calls are from xattr_handler->get() to convert a stored ACL to an xattr, and that call provides a buffer. For now we have no other option, so this commit detects the new version and wraps to copy the value back into the provided buffer and then free it. Sponsored-by: TrueNAS Reviewed-by: Tony Hutter <hutter2@llnl.gov> Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov> Signed-off-by: Rob Norris <rob.norris@truenas.com> Closes #18216
| * | | | | | Linux 7.0: blk_queue_nonrot() renamed to blk_queue_rot()Rob Norris2026-02-232-0/+30
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | It does exactly the same thing, just inverts the return. Detect its presence or absence and call the right one. Sponsored-by: TrueNAS Reviewed-by: Tony Hutter <hutter2@llnl.gov> Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov> Signed-off-by: Rob Norris <rob.norris@truenas.com> Closes #18216
| * | | | | | SIMD: libspl: test the correct CPUID bit for AVX512VLAttila Fülöp2026-02-231-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov> Signed-off-by: Attila Fülöp <attila@fueloep.org> Closes #18254
| * | | | | | Improve misleading error messages for ZPOOL_STATUS_CORRUPT_POOLChristos Longros2026-02-232-3/+12
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | When devices are missing or claimed by another subsystem (e.g. mdadm, LVM), zpool import reports "The pool metadata is corrupted" and suggests destroying the pool. This is misleading because the metadata is not necessarily corrupted -- it may simply be incomplete due to inaccessible devices. Update the status, action, and recovery messages to acknowledge that missing devices can trigger this status, and suggest checking device availability before resorting to pool destruction. Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov> Signed-off-by: Chris Longros <chris.longros@gmail.com> Closes #18251 Closes #8236
| * | | | | | build: get objtool from $kernelbuildLouis Leseur2026-02-231-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | On systems where `$kernelsrc` is different than `$kernelbuild`, the objtool binary will be located in `$kernelbuild` as it's the result of running `make prepare` during kernel build. Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov> Reviewed-by: Attila Fülöp <attila@fueloep.org> Signed-off-by: Louis Leseur <louis.leseur@gmail.com> Closes #18248 Closes #18249
| * | | | | | Add vdev property to disable vdev schedulerMigeljanImeri2026-02-2314-2/+206
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Added vdev property to disable the vdev scheduler. The intention behind this property is to improve IOPS performance when using o_direct. Reviewed-by: Tony Hutter <hutter2@llnl.gov> Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov> Reviewed-by: Alexander Motin <alexander.motin@TrueNAS.com> Signed-off-by: MigeljanImeri <ImeriMigel@gmail.com> Closes #17358
| * | | | | | Move range_tree, btree, highbit64 to common codeTony Hutter2026-02-2215-88/+117
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Break out the range_tree, btree, and highbit64/lowbit64 code from kernel space into shared kernel and userspace code. This is needed for the updated `zpool status -vv` error byte range reporting that will be coming in a future commit. That commit needs the range_tree code in kernel and userspace. Reviewed-by: Rob Norris <robn@despairlabs.com> Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov> Signed-off-by: Tony Hutter <hutter2@llnl.gov> Closes #18133
| * | | | | | Linux 7.0: explicitly set setlease handler to kernel implementationRob Norris2026-02-2213-7/+275
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The upcoming 7.0 kernel will no longer fall back to generic_setlease(), instead returning EINVAL if .setlease is NULL. So, we set it explicitly. To ensure that we catch any future kernel change, adds a sanity test for F_SETLEASE and F_GETLEASE too. Since this is a Linux-specific test, also a small adjustment to the test runner to allow OS-specific helper programs. Sponsored-by: TrueNAS Reviewed-by: Tony Hutter <hutter2@llnl.gov> Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov> Signed-off-by: Rob Norris <rob.norris@truenas.com> Closes #18215
| * | | | | | zdb: handle key load/derive failures a bit more gracefullyRob Norris2026-02-201-9/+23
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | There's no real need to outright crash if key loading fails; we can just unwind nicely. Sponsored-by: TrueNAS Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov> Reviewed-by: Alexander Motin <alexander.motin@TrueNAS.com> Signed-off-by: Rob Norris <rob.norris@truenas.com> Closes #18230
| * | | | | | zdb: don't try to load key for unencrypted datasetRob Norris2026-02-201-7/+18
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Previously using -K/--key on an unencrypted dataset would trip a VERIFY, because the dataset has nowhere to load the key into. Now, just ignore it. This makes zdb much easier to drive when there's a mix of encrypt and non-encrypted datasets, as the key can provided for all of them (at least, assuming the same encryption root, which is a common enough case). Sponsored-by: TrueNAS Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov> Reviewed-by: Alexander Motin <alexander.motin@TrueNAS.com> Signed-off-by: Rob Norris <rob.norris@truenas.com> Closes #18230
| * | | | | | ZTS: make get_same_blocks() fail harder if zdb failsRob Norris2026-02-201-9/+37
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Because it's called in $(...), it will swallow all errors, so we have to work harder to recognise falure and echo a string that can't ever match what the test is expecting. Sponsored-by: TrueNAS Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov> Reviewed-by: Alexander Motin <alexander.motin@TrueNAS.com> Signed-off-by: Rob Norris <rob.norris@truenas.com> Closes #18230
| * | | | | | sha2_test: do correctness checks for all implementationsRob Norris2026-02-191-11/+28
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Sponsored-by: TrueNAS Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov> Reviewed-by: Attila Fülöp <attila@fueloep.org> Reviewed-by: Tony Hutter <hutter2@llnl.gov> Reviewed-by: Alexander Motin <alexander.motin@TrueNAS.com> Signed-off-by: Rob Norris <rob.norris@truenas.com> Closes #18232
| * | | | | | get_cpu_freq: handle CPUs with variable frequencyRob Norris2026-02-191-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | If a CPU has variable frequency, then lscpu will list separate "CPU min freq" and "CPU max freq" values. In this case, take the maximum. Sponsored-by: TrueNAS Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov> Reviewed-by: Attila Fülöp <attila@fueloep.org> Reviewed-by: Tony Hutter <hutter2@llnl.gov> Reviewed-by: Alexander Motin <alexander.motin@TrueNAS.com> Signed-off-by: Rob Norris <rob.norris@truenas.com> Closes #18232
| * | | | | | Fix available space accounting for special/dedup (#18222)Alexander Motin2026-02-196-36/+60
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Currently, spa_dspace (base to calculate dataset AVAIL) only includes the normal allocation class capacity, but dd_used_bytes tracks space allocated across all classes. Since we don't want to report free space of other classes as available (we can't promise new allocations will be able to use it), report only allocated space, similar to how we report space saved by dedup and block cloning. Since we need deflated space here, make allocation classes track deflated allocated space also. While here, make mc_deferred also deflated, matching its use contexts. Also while there, use atomic_load() to read the allocation class stats. Reviewed-by: Rob Norris <robn@despairlabs.com> Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov> Signed-off-by: Alexander Motin <alexander.motin@TrueNAS.com> Closes #18190 Closes #18222
| * | | | | | CI: Test & fix Linux ZFS built-in buildTony Hutter2026-02-198-10/+77
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | ZFS can be built directly into the Linux kernel. Add a test build of this to the CI to verify it works. The test build is only enabled on Fedora runners (since they run the newest kernels) and is done in parallel with ZTS. The test build is done on vm2, since it typically finishes ~15min before vm1 and thus has time to spare. In addition: - Update 'copy-builtin' to check that $1 is a directory - Fix some VERIFYs that were causing the built-in build to fail Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov> Signed-off-by: Tony Hutter <hutter2@llnl.gov> Closes #18234
| * | | | | | ICP: AES-GCM assembly: remove unused Gmul functionsAttila Fülöp2026-02-193-101/+0
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | In the AES-GCM assembly files we are defining Gmul functions we don't use anywhere. Just remove the dead code. Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov> Signed-off-by: Attila Fülöp <attila@fueloep.org> Closes #18226
| * | | | | | Remove parent ZIO from dbuf_prefetch()Alexander Motin2026-02-191-14/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | I am not sure why it was added there 10 years ago, but it seems not needed now. According to my tests removing it improves sequential read performance with recordsize=4K by 5-10% by reducing the CPU overhead in prefetcher. Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov> Reviewed-by: Rob Norris <robn@despairlabs.com> Reviewed-by: Ameer Hamza <ahamza@ixsystems.com> Reviewed-by: Akash B <akash-b@hpe.com> Signed-off-by: Alexander Motin <alexander.motin@TrueNAS.com> Closes #18214
| * | | | | | ICP: AES-GCM VAES-AVX2: fix typos and document source filesAttila Fülöp2026-02-181-2/+5
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Require AVX2 compiler support and document source files for `aesni-gcm-avx2-vaes.S`. Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov> Reviewed-by: Tony Hutter <hutter2@llnl.gov> Signed-off-by: Attila Fülöp <attila@fueloep.org> Closes #18225
| * | | | | | freebsd: Fix TIMESPEC_OVERFLOW for PowerPCJessica Clarke2026-02-181-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Once upon a time, 32-bit PowerPC did indeed have a 32-bit time_t, but FreeBSD 12.0 switched to a 64-bit time_t for PowerPC as an ABI break, which predates the addition of FreeBSD support to OpenZFS. Moreover, 64-bit PowerPC has existed since FreeBSD 9.0, where __powerpc__ is also defined (alongside __powerpc64__ to disambiguate), which has always had a 64-bit time_t. This code has therefore always been wrong for all PowerPC variants. Fix this by limiting the 32-bit case to just i386, which is the only architecture in FreeBSD to have a 32-bit time_t and not have broken ABI, due to its special legacy compatibility status. Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov> Reviewed-by: Alexander Motin <alexander.motin@TrueNAS.com> Signed-off-by: Jessica Clarke <jrtc27@jrtc27.com> Closes #18217 Closes #18218
| * | | | | | Linux 6.19 compat: in-tree build: fix duplicate GCM assembly functionsAttila Fülöp2026-02-173-0/+41
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Linux 6.19 added an AES-GCM VAES-AVX2 assembly implementation. It's basically a translation from the BoringSSL perlasm syntax to macro assembly. We're using the same source but the perlasm generated flat assembly which shares some global function names with the former. When building in-tree this results in the linker failing due to the duplicate symbols. To avoid the error we prepend `icp_` via a macro to our function names. Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov> Reviewed-by: Alexander Moch <mail@alexmoch.com> Signed-off-by: Attila Fülöp <attila@fueloep.org> Closes #18204 Closes #18224
| * | | | | | Simplify dnode_level_is_l2cacheable()Alexander Motin2026-02-161-2/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | We should not dereference through dn_handle->dnh_dnode once we already have a dnode pointer. The result will be the same. Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov> Signed-off-by: Alexander Motin <alexander.motin@TrueNAS.com> Closes #18212
| * | | | | | Cleanup allocation class selectionAlexander Motin2026-02-162-29/+17
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | - For multilevel gang blocks it seemed possible to fallback from normal to special class, since they don't have proper object type, and DMU_OT_NONE is a "metadata". They should never fallback. - Fix possible inversion with zfs_user_indirect_is_special = 0, when indirects written to normal vdev, while small data to special. Make small indirect blocks also follow special_small_blocks there. - With special_small_blocks now applying to both files and ZVOLs, make it apply to all non-metadata without extra checks, since there are no other non-metadata types. Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov> Signed-off-by: Alexander Motin <alexander.motin@TrueNAS.com> Closes #18208
| * | | | | | Flush RRD only when TXGs contain dataMariusz Zaborski2026-02-111-12/+20
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This change modifies the behavior of spa_sync_time_logger when flushing the RRD database. Previously, once the sync interval elapsed, a flush would always be generated. On solid-state devices, especially when the pool was otherwise idle, this caused disks to wake up solely to write RRD data. Since RRD is best-effort telemetry, this behavior is unnecessary and wasteful. With this change, spa_sync_time_logger delays flushing until a TXG that already contains data is being synced. The RRD update is appended to that TXG instead of forcing the creation of a new write-only TXG. During pool export, flushing is forced regardless of whether the TXG contains user data. At that stage, data durability takes precedence and a write must be issued. Sponsored by: [Wasabi Technology, Inc.; Klara, Inc.] Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov> Signed-off-by: Mariusz Zaborski <mariusz.zaborski@klarasystems.com> Closes #18082 Closes #18138
| * | | | | | Fix `send:raw` permission for send `-w -I`Marc Sladek2026-02-112-6/+11
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | When performing an incremental raw send with intermediates (-w -I), the standard 'send' permission was incorrectly required instead of allowing 'send:raw'. This was due to a strict boolean comparison on the 'rawok' flag in zfs_secpolicy_send() with non-boolean value. This change normalizes the 'rawok' variable to be strictly 0/1 and updates the test suite to properly verify delegated raw send behavior. Introduced-by: https://github.com/openzfs/zfs/pull/17543 Reviewed-by: Alexander Motin <alexander.motin@TrueNAS.com> Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov> Signed-off-by: Marc Sladek <marc@sladek.dev> Closes #18198 Closes #18193