aboutsummaryrefslogtreecommitdiff
path: root/sys/contrib
Commit message (Collapse)AuthorAgeFilesLines
* zfs: Fix build on 32-bit platforms after most recent import.John Baldwin2023-05-251-2/+2
| | | | | | | | | | unsigned long is not a uint64_t on 32-bit platforms. The zfs.4 manpage documents this variable as a uint, and it is only compared with other variables of type int, so uint_t makes more sense than unsigned long. (I also wasn't sure if ULONG would work as a ZFS_MODULE_PARAM type on other OS's)
* zfs: merge openzfs/zfs@ad0a55461Martin Matuska2023-05-2342-181/+2028
| | | | | | | | | | | | | | | Notable upstream pull request merges: #12355 Teach zpool scrub to scrub only blocks in error log #14811 Refine special_small_blocks property validation #14854 zil: Some micro-optimizations #14855 zil: Free lwb_buf after write completion #14860 Fixes for issues identified by recent Coverity defect reports #14861 Probe vdevs before marking removed #14873 Add the ability to uninitialize a zpool #14875 Hold db_mtx when updating db_state Obtained from: OpenZFS OpenZFS commit: ad0a554614b096698d9969340c4c593690042d5b
* spdx: The BSD-2-Clause-FreeBSD identifier is obsolete, drop -FreeBSDWarner Losh2023-05-1216-16/+16
| | | | | | | | | The SPDX folks have obsoleted the BSD-2-Clause-FreeBSD identifier. Catch up to that fact and revert to their recommended match of BSD-2-Clause. Discussed with: pfg MFC After: 3 days Sponsored by: Netflix
* ath11k: import ath11k driverBjoern A. Zeeb2023-05-1262-0/+68403
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Import BSD-3-Clause-Clear ath11k driver assumed to be based on Linux kvalo/ath.git master at 6bae9de622d3ef4805aba40e763eb4b0975c4f6d. Complement the driver to make compile on FreeBSD using LinuxKPI with changes covered by #ifdef (__FreeBSD__). Further select updates were applied since the initial import in order to keep compiling along with other LinuxKPI based drivers. Add the module build framework but keep disconnected from the build for now. The current driver (or rather LinuxKPI) lacks support for some "qcom" bits needed in order to get things working. There was interest by various people to enhance support further. We initially only plan to support PCI parts but it would be great to further enhance qcom SoC support to run on several (cheap) APs. The firmware is provided by port net/wifi-firmware-ath11k-kmod. Given the lack of full license texts on most files this is imported under the draft policy for handling SPDX files (D29226) and with approval for BSD-3-Clause-Clear. [1] Approved by: core (jhb, 2023-05-11) [1] MFC after: 2 months
* zfs: merge openzfs/zfs@e61076683Martin Matuska2023-05-1242-457/+1723
| | | | | | | | | | | | | | | | | | | | | | | Notable upstream pull request merges: #14744 Optimize check_filesystem() and process_error_log() #14773 Allow zhack label repair to restore detached devices #14794 zpool import -m also removing spare and cache when log device is missing #14805 Simplify and optimize random_int_between() #14813 Enable the head_errlog feature to remove errors #14816 Fix two abd_gang_add_gang() issues #14817 Verify block pointers before writing them out #14819 Add dmu_tx_hold_append() interface #14823 Remove single parent assertion from zio_nowait() #14824 Plug memory leak in zfsdev_state #14825 Block cloning dbuf fixes #14828 Remove duplicate code in l2arc_evict() #14837 Fixes in head_errlog feature with encryption #14839 Prevent panic during concurrent snapshot rollback and zvol read #14853 zil: Don't expect zio_shrink() to succeed Obtained from: OpenZFS OpenZFS commit: e6107668385044718b0a73330ed6423650806473
* zfs: merge openzfs/zfs@d96e29576Martin Matuska2023-05-03125-625/+1965
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Notable upstream pull request merges: #11680 Add support for zpool user properties #14145 Storage device expansion "silently" fails on degraded vdev #14405 Create zap for root vdev #14659 Allow MMP to bypass waiting for other threads #14674 Miscellaneous FreBSD compilation bugfixes #14692 Fix some signedness issues in arc_evict() #14702 Fix typo in check_clones() #14715 module: small fixes for FreeBSD/aarch64 #14716 Trim needless zeroes from checksum events #14719 vdev: expose zfs_vdev_max_ms_shift as a module parameter #14722 Fix "Detach spare vdev in case if resilvering does not happen" #14723 freebsd clone range fixes #14728 Fix BLAKE3 aarch64 assembly for FreeBSD and macOS #14735 Fix in check_filesystem() #14739 Fix data corruption when cloning embedded blocks #14758 Fix VERIFY(!zil_replaying(zilog, tx)) panic #14761 Revert "ZFS_IOC_COUNT_FILLED does unnecessary txg_wait_synced()" #14774 FreeBSD .zfs fixups #14776 FreeBSD: make zfs_vfs_held() definition consistent with declaration #14779 powerpc64: Support ELFv2 asm on Big Endian #14788 FreeBSD: add missing vop_fplookup assignments #14789 PAM: support the authentication facility #14790 Revert "Fix data race between zil_commit() and zil_suspend()" #14795 Fix positive ABD size assertion in abd_verify() #14798 Mark TX_COMMIT transaction with TXG_NOTHROTTLE #14804 Correct ABD size for split block ZIOs #14806 Use correct block pointer in block cloning case. #14808 blake3: fix up bogus checksums in face of cpu migration Obtained from: OpenZFS OpenZFS commit: d96e29576c89e6e547cb82b477651d2b85ea0fed
* stand: Add isspace to FreeBSD ctypes.hWarner Losh2023-05-011-0/+1
| | | | | | | | And eliminate blake3_impl_hack.c since it's no longer needed. Sponsored by: Netflix Reviewed by: delphij Differential Revision: https://reviews.freebsd.org/D39899
* stand: back out the most of the horrible aarch64 kludgeWarner Losh2023-05-011-5/+8
| | | | | | | | | Add one ifdef to upstrem code and get rid of compiling the horrible checked-in aarch64 assembler for the boot loader that the loader will never use. I'll attempt to upstream this and adjust as needed. Sponsored by: Netflix Differential Revision: https://reviews.freebsd.org/D39897
* openzfs: re-enable FPU usage on aarch64Kyle Evans2023-04-271-6/+1
| | | | | The BLAKE3 generated assembly files have now been updated to avoid clobbering x18, we can safely re-enable FPU usage on aarch64.
* Fix BLAKE3 aarch64 assembly for FreeBSD and macOSTino Reichardt2023-04-272-4511/+4057
| | | | | | | | | | | The x18 register isn't useable within FreeBSD kernel space, so we have to fix the BLAKE3 aarch64 assembly for not using it. The source files are here: https://github.com/mcmilk/BLAKE3-tests Reviewed-by: Kyle Evans <kevans@FreeBSD.org> Signed-off-by: Tino Reichardt <milky-zfs@mcmilk.de> Closes #14728
* zfs: Fix positive ABD size assertion in abd_verify().Mateusz Guzik2023-04-261-1/+2
| | | | | | | | | | | | | | | | | | | | | This cherry-picks upstream: commit bba7cbf0a481ab16f9a9a4874b7dbd5682e4d3a4 Author: Alexander Motin <mav@FreeBSD.org> Date: Wed Apr 26 12:20:43 2023 -0400 Fix positive ABD size assertion in abd_verify(). Gang ABDs without childred are legal, and they do have zero size. For other ABD types zero size doesn't have much sense and likely not working correctly now. Reviewed-by: Igor Kozhukhov <igor@dilos.org> Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov> Signed-off-by: Alexander Motin <mav@FreeBSD.org> Sponsored by: iXsystems, Inc. Closes #14795 Sponsored by: Rubicon Communications, LLC ("Netgate")
* openzfs: arm64: implement kfpu_begin/kfpu_endKyle Evans2023-04-261-1/+27
| | | | | | | | | | | | | | | This is part one of a fix for booting with ZFS on arm64 using accelerated checksum implementations. Checksum benchmarking will attempt to use the FPU, so we currently panic quickly on boot. BLAKE3 is still broken, as it clobbers x18 and we promptly discover that fact as soon as we attempt to fetch curthread in kfpu_end(). Note that _STANDALONE is special-cased here, but ideally we wouldn't be building the code that uses kfpu_begin()/kfpu_end() at all in the loader environment. Discussed with: imp (a bit) Differential Revision: https://reviews.freebsd.org/D39448
* irdma: Convert to IfAPIJustin Hibbits2023-04-251-1/+1
| | | | | | | | | | Mostly mechanical changes, with some reworking in irdma_cm for iterating over interfaces and addresses. Further rework by Bartosz Sobczak. Reviewed by: bartosz.sobczak_intel.com Tested by: mateusz.moga_intel.com Sponsored by: Juniper Networks, Inc. Differential Revision: https://reviews.freebsd.org/D38960
* zfs: make zfs_vfs_held() definition consistent with declarationDimitry Andric2023-04-251-1/+1
| | | | | | | | | | | | Noticed while attempting to change boolean_t into an actual bool: in include/sys/zfs_ioctl_impl.h, zfs_vfs_held() is declared to return a boolean_t, but in module/os/freebsd/zfs/zfs_ioctl_os.c it is defined to return an int. Make the definition match the declaration. Obtained from: https://github.com/openzfs/zfs/commit/62cc9d4f6 Reviewed by: jhb MFC after: 1 week Differential Revision: https://reviews.freebsd.org/D39753
* zfs: Revert "Fix data race between zil_commit() and zil_suspend()"Mateusz Guzik2023-04-252-28/+0
| | | | | | | | | | | | | This reverts commit 4c856fb333ac57d9b4a6ddd44407fd022a702f00. To quote a pending upstream PR: This reverts commit 4c856fb to resolve a newly introduced deadlock which in practice is more disruptive that the issue this commit intended to address. Causes deadlocks described in https://github.com/openzfs/zfs/issues/14775 Sponsored by: Rubicon Communications, LLC ("Netgate")
* Add support for zpool user propertiesAllan Jude2023-04-2512-48/+627
| | | | | | | | | | | | | | | | | | Usage: zpool set org.freebsd:comment="this is my pool" poolname Tests are based on zfs_set's user property tests. Also stop truncating property values at MAXNAMELEN, use ZFS_MAXPROPLEN. Reviewed by: markj Approved by: markj Co-authored-by: Mateusz Piotrowski <0mp@FreeBSD.org> Obtained from: OpenZFS 8eae2d214cfa Add support for zpool user properties Sponsored by: Beckhoff Automation GmbH & Co. KG. Sponsored by: Klara Inc. Differential Revision: https://reviews.freebsd.org/D39657
* zfs: fix up bogus checksums with blake3 in face of cpu migrationMateusz Guzik2023-04-251-2/+5
| | | | | | | | This is a temporary measure until a better fix is sorted out. Upstream report: https://github.com/openzfs/zfs/issues/14785 Reported by: Evgeniy Khramtsov Sponsored by: Rubicon Communications, LLC ("Netgate")
* powerpc: Use valid prototypes for function declarations with no arguments.John Baldwin2023-04-241-1/+1
| | | | | Reviewed by: emaste Differential Revision: https://reviews.freebsd.org/D39733
* ath10k: import ath10k driverBjoern A. Zeeb2023-04-2364-0/+87477
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Import ISC-licensed ath10k driver assumed to be based on Linux kvalo/ath.git master at 6bae9de622d3ef4805aba40e763eb4b0975c4f6d. Import support to redirect fwlogs to kernel messages from https://chromium-review.googlesource.com/c/chromiumos/third_party/kernel/+/389075 Complement the driver to make compile on FreeBSD using LinuxKPI with changes covered by #ifdef (__FreeBSD__). Further select updates were applied since the initial import in order to keep compiling along with other LinuxKPI based drivers. Any other native driver using BUS_PROBE_DEFAULT will attach ignoring this one by default given bsd_probe_return is set to a lower priority. Add the module build framework. We only support PCI parts. The firmware is provided by port net/wifi-firmware-ath10k-kmod. Given the lack of full license texts on most files this is imported under the draft policy for handling SPDX files (D29226). [1] Approved by: core (emaste, 2022-04-08) [1] MFC after: 2 months
* athk: import common code for ath1?k driversBjoern A. Zeeb2023-04-2316-0/+4182
| | | | | | | | | | | | | | | | Import common ISC-licensed athk parts assumed to be based on Linux kvalo/ath.git master at 6bae9de622d3ef4805aba40e763eb4b0975c4f6d. The only modification should be for FreeBSD module handling in main.c. Add the module build framework unconnected to the build for now. These files will be shared by ath1?k drivers. MFC after: 2 months
* mt76: import mediatek/mt76 driverBjoern A. Zeeb2023-04-23158-0/+71107
| | | | | | | | | | | | | | | | | | | | | | | | | Import ISC-licensed driver parts of mediatek/mt76 assumed to be based on Linux wireless-testing at a02411a5b98612c12be99349836d99f07db12a77 (tag: wt-2022-11-23). Complement the driver and LinuxKPI with our own (dummy) implementations of missing parts (util.h and soc/mediatek/) as well as changes to make compile on FreeBSD with changes covered by #ifdef (__FreeBSD__) conditions. Further select updates were applied since the initial import in order to keep compiling along with other LinuxKPI based drivers. For the moment we only target the mt7915 and mt7921 PCI parts. More may follow in the future. Firmware is provided by port net/wifi-firmware-mt76-kmod. Given the lack of full license texts on non-local files this is imported under the draft policy for handling SPDX files (D29226). [1] Approved by: core (emaste, 2022-04-08) [1] MFC after: 2 months
* zfs/powerpc64: Fix big-endian powerpc64 asmJustin Hibbits2023-04-225-1/+62
| | | | | | | | | | The powerpc asm from openzfs assumes that big-endian is always ELFv1 and ELFv2 is always little-endian, while FreeBSD uses ELFv2 everywhere. Add the necessary bits to the checksum asm to work on big-endian ELFv2. This was also submitted upstream as PR#14779. Tested by: dbaio
* iwlwifi: quieten more compiler warningsBjoern A. Zeeb2023-04-207-0/+21
| | | | | | | | | | | Quieten some more (valid) gcc warnings and disable dead code. There are more warnings, some probably a compiler problem, the other related to firmware structs which I do not want to adjust just locally. Leave a comment to revisit after a next driver update. Sponsored by: The FreeBSD Foundation MFC after: 3 days
* zfs: fix up EINVAL from getdirentries on .zfsMateusz Guzik2023-04-201-0/+11
| | | | PR: 270909
* zfs: add missing vn state transition for .zfsMateusz Guzik2023-04-201-0/+4
| | | | Reported by: des
* iwlwifi: rtw88: rtw89: fix gcc warningsBjoern A. Zeeb2023-04-197-5/+25
| | | | | | | | | | | Fix -Wno-format and unused variables warnings with gcc by adopting (to|the) FreeBSD-specific code. Reported by: jhb Sponsored by: The FreeBSD Foundation MFC after: 3 days Reviewed by: jhb Differential Revision: https://reviews.freebsd.org/D39673
* zfs: Add vfs.zfs.bclone_enabled sysctl.Pawel Jakub Dawidek2023-04-173-2/+11
| | | | | | | | | | Keep block cloning disabled by default for now, but allow to enable and use it after setting vfs.zfs.bclone_enabled to 1, so people can easily try it. Approved by: oshogbo Reviewed by: mm, oshogbo Differential Revision: https://reviews.freebsd.org/D39613
* zfs: Merge https://github.com/openzfs/zfs/pull/14739Pawel Jakub Dawidek2023-04-171-3/+1
| | | | | | | | | | | | | | The zfs_log_clone_range() function is never called from the zfs_clone_range_replay() function, so I assumed it is safe to assert that zil_replaying() is never TRUE here. It turns out zil_replaying() also returns TRUE when the sync property is set to disabled. Fix the problem by just returning if zil_replaying() returns TRUE. Reported by: Florian Smeets Signed-off-by: Pawel Jakub Dawidek pawel@dawidek.net Approved by: oshogbo, mm
* zfs: cherry-pick openzfs/zfs@c71fe7164Pawel Jakub Dawidek2023-04-171-2/+4
| | | | | | | | | | | | | | | Fix data corruption when cloning embedded blocks Don't overwrite blk_phys_birth, as for embedded blocks it is part of the payload. Reviewed-by: Richard Yao <richard.yao@alumni.stonybrook.edu> Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov> Signed-off-by: Pawel Jakub Dawidek <pawel@dawidek.net> Issue #13392 Closes #14739 Approved by: oshogbo, mm
* zfs: Revert "ZFS_IOC_COUNT_FILLED does unnecessary txg_wait_synced()"Mateusz Guzik2023-04-151-16/+5
| | | | | | | | | This reverts commit 519851122b1703b8445ec17bc89b347cea965bb9. It results in data corruption, see: https://github.com/openzfs/zfs/issues/14753 Sponsored by: Rubicon Communications, LLC ("Netgate")
* zfs: don't use zfs_freebsd_copy_file_rangeMateusz Guzik2023-04-151-1/+2
| | | | | | | | | | | | | | | | | There is one data corruption problem reported and fixed upstream, not cherry-picked here yet. On top of it the following fires under load: VERIFY(zil_replaying(zfsvfs->z_log, tx)); The patch which introduced the entire machinery is a revert candidate, but as the machinery came with a dedicated feature flag, doing so would render affected pools read-only at best. To be figured out. As a temporary bandaid at least stop the active usage. Note this patch does not make the feature disappear from zpool upgrade. Sponsored by: Rubicon Communications, LLC ("Netgate")
* zfs: Appease set by unused warnings for spl_fstrans_*mark stubs.John Baldwin2023-04-101-1/+1
| | | | | | | Use a void cast to mark the cookie value as used in spl_fstrans_unmark. Reported by: GCC Differential Revision: https://reviews.freebsd.org/D39357
* openzfs: adopt to the new vn_lock_pair() interfaceKonstantin Belousov2023-04-071-1/+2
| | | | | Sponsored by: The FreeBSD Foundation MFC after: 1 week
* zfs: disable kernel fpu usage on arm and aarc64Mateusz Guzik2023-04-072-2/+2
| | | | | | | | | It is not implemented and causes panics on boot. This is a temporary measure until someone(tm) sorts it out. Reported by: many Sponsored by: Rubicon Communications, LLC ("Netgate")
* zfs: try to fallback early if can't do optimized copyMateusz Guzik2023-04-071-0/+8
| | | | | | Not complete, but already shaves on some locking. Sponsored by: Rubicon Communications, LLC ("Netgate")
* zfs: fix up EXDEV handling for clone_rangeMateusz Guzik2023-04-071-29/+27
| | | | | | | | | | | | | | | | | | | | | | | | | | | | API contract requires VOPs to handle EXDEV internally, worst case by falling back to the generic copy routine. This broke with the recent changes. While here whack custom loop to lock 2 vnodes with vn_lock_pair, which provides the same functionality internally. write start/finish around it plays no role so got eliminated. One difference is that vn_lock_pair always takes an exclusive lock on both vnodes. I did not patch around it because current code takes an exclusive lock on the target vnode. zfs supports shared-locking for writes, so this serializes different calls to the routine as is, despite range locking inside. At the same time you may notice the source vnode can get some traffic if only shared-locked, thus once more this goes the safer route of exclusive-locking. Note this should be patched to use shared-locking for both once the feature is considered stable. Technically the switch to vn_lock_pair should be a separate change, but it would only introduce churn immediately whacked by the rest of the patch. [note: technically the review is still in progress, but so is the active breakage] Sponsored by: Rubicon Communications, LLC ("Netgate")
* zfs: add missing vop_fplookup_vexec assignmentsMateusz Guzik2023-04-061-0/+9
| | | | This happens to be a nop right now.
* zfs: fix null ap->a_fsizetd NULL pointer derefernceMartin Matuska2023-04-051-1/+1
| | | | | | | | Submitted by: rmacklem Reported by: cy Tested by: cy, mm Reviewed by: pjd, mm Differential revision: https://reviews.freebsd.org/D39418
* Revert "zfs: fall back if block_cloning feature is disabled"Martin Matuska2023-04-041-10/+7
| | | | This reverts commit 8ee579abe09ec1fe15c588fc9a08370b83b81cd6.
* zfs: fall back if block_cloning feature is disabledMartin Matuska2023-04-041-7/+10
| | | | | | | | | | | | | If block_cloning is disabled, or other errors from zfs_clone_range() return an EXDEV we should fall back to vn_generic_copy_file_range(). This fixes issues when copying files on the same dataset with block_cloning disabled. Upstreamed as pull request to OpenZFS. Reviewed by: Mateusz Guzik <mjguzik@gmail.com> OpenZFS pull request: 14713
* zfs: merge openzfs/zfs@431083f75Martin Matuska2023-04-03309-15331/+45241
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Notable upstream pull request merges: #12194 Fix short-lived txg caused by autotrim #13368 ZFS_IOC_COUNT_FILLED does unnecessary txg_wait_synced() #13392 Implementation of block cloning for ZFS #13741 SHA2 reworking and API for iterating over multiple implementations #14282 Sync thread should avoid holding the spa config write lock when possible #14283 txg_sync should handle write errors in ZIL #14359 More adaptive ARC eviction #14469 Fix NULL pointer dereference in zio_ready() #14479 zfs redact fails when dnodesize=auto #14496 improve error message of zfs redact #14500 Skip memory allocation when compressing holes #14501 FreeBSD: don't verify recycled vnode for zfs control directory #14502 partially revert PR 14304 (eee9362a7) #14509 Fix per-jail zfs.mount_snapshot setting #14514 Fix data race between zil_commit() and zil_suspend() #14516 System-wide speculative prefetch limit #14517 Use rw_tryupgrade() in dmu_bonus_hold_by_dnode() #14519 Do not hold spa_config in ZIL while blocked on IO #14523 Move dmu_buf_rele() after dsl_dataset_sync_done() #14524 Ignore too large stack in case of dsl_deadlist_merge #14526 Use .section .rodata instead of .rodata on FreeBSD #14528 ICP: AES-GCM: Refactor gcm_clear_ctx() #14529 ICP: AES-GCM: Unify gcm_init_ctx() and gmac_init_ctx() #14532 Handle unexpected errors in zil_lwb_commit() without ASSERT() #14544 icp: Prevent compilers from optimizing away memset() in gcm_clear_ctx() #14546 Revert zfeature_active() to static #14556 Remove bad kmem_free() oversight from previous zfsdev_state_list patch #14563 Optimize the is_l2cacheable functions #14565 FreeBSD: zfs_znode_alloc: lock the vnode earlier #14566 FreeBSD: fix false assert in cache_vop_rmdir when replaying ZIL #14567 spl: Add cmn_err_once() to log a message only on the first call #14568 Fix incremental receive silently failing for recursive sends #14569 Restore ASMABI and other Unify work #14576 Fix detection of IBM Power8 machines (ISA 2.07) #14577 Better handling for future crypto parameters #14600 zcommon: Refactor FPU state handling in fletcher4 #14603 Fix prefetching of indirect blocks while destroying #14633 Fixes in persistent error log #14639 FreeBSD: Remove extra arc_reduce_target_size() call #14641 Additional limits on hole reporting #14649 Drop lying to the compiler in the fletcher4 code #14652 panic loop when removing slog device #14653 Update vdev state for spare vdev #14655 Fix cloning into already dirty dbufs #14678 Revert "Do not hold spa_config in ZIL while blocked on IO" Obtained from: OpenZFS OpenZFS commit: 431083f75bdd3efaee992bdd672625ec7240d252
* rtw89: fix -Wunused-but-set-variableBjoern A. Zeeb2023-03-231-0/+5
| | | | | | | Fix a -Wunused-but-set-variable warning by adding the field to the debug logging as is done for other versions handler functions. MFC after: 3 days
* zfs: Use .section .rodata instead of .rodata on FreeBSDDimitry Andric2023-03-132-2/+2
| | | | | | | | | | | | | | | | | | | In commit 0a5b942d4 the FreeBSD SECTION_STATIC macro was set to ".rodata". This assembler directive is supported by LLVM (as a convenience alias for ".section .rodata") by not by GNU as. This caused the FreeBSD builds that are done with gcc to fail. Therefore, use ".section .rodata" instead, similar to the other asm_linkage.h headers. [mjg: cherry-picked from upstream zfs bf1bec394e715de9f7ac4a54b5b1b884d7e41a32 to unbreak gcc12 build] Reviewed-by: Mateusz Guzik <mjguzik@gmail.com> Reviewed-by: Attila Fülöp <attila@fueloep.org> Reviewed-by: Jorgen Lundman <lundman@lundman.net> Signed-off-by: Dimitry Andric <dimitry@andric.com> Closes #14526
* NgATM: Remove netgraph ATM supportBrooks Davis2023-03-0963-43531/+0
| | | | | | | | | | Most ATM support was removed prior to FreeBSD 12. The netgraph support was kept as it was less intrusive, but it is presumed to be unused. Reviewed by: manu Relnotes: yes Sponsored by: DARPA Differential Revision: https://reviews.freebsd.org/D38879
* xen: fetch dom0 video console information from XenRoger Pau Monné2023-03-091-0/+5
| | | | | | | | | It's possible for Xen to switch the video mode set by the boot loader, so that the information passed in the kernel metadata is no longer valid. Fetch the video mode used by Xen using an hypercall and update the medatada for the kernel to use the correct video mode. Sponsored by: Citrix Systems R&D
* krping: Use get_cyclecount for get_cycles.John Baldwin2023-03-081-7/+1
| | | | | | | This avoids having to duplicate identical MD code. Reviewed by: np, emaste Differential Revision: https://reviews.freebsd.org/D38971
* powerpc64*: port mlx5, OFED, KTLS and krpingPiotr Kubaj2023-02-261-0/+4
| | | | | | | | | | | | | | | | Summary: This review ports mlx5 driver, kernel's OFED stack (userland is already enabled), KTLS and krping to powerpc64 and powerpc64le. krping requires a small change since it uses assembly for amd64 / i386. NOTE: On powerpc64le RDMA works fine in the userspace with libmlx5, but on powerpc64 it does not. The problem is that contrib/ofed/libmlx5/doorbell.h checks for SIZEOF_LONG but this macro exists on neither powerpc64* nor amd64. Thus, the file silently goes to the fallback function written for 32-bit architectures. It works fine on little-endian architectures, but causes a hard fail on big-endian. It's possible it may also cause some runtime issues on little-endian. Thus, on powerpc64 I verified that RDMA works with krping. Reviewers: #powerpc, hselasky Subscribers: bdrewery, imp, emaste, jhibbits Differential Revision: https://reviews.freebsd.org/D38786
* Revert "powerpc64*: port mlx5, OFED, KTLS and krping"Piotr Kubaj2023-02-251-4/+0
| | | | | | Wrong push, another commit was supposed to be pushed. This reverts commit 83d6d8877ef7dad4f4e8f409a01c9f28139cd026.
* powerpc64*: port mlx5, OFED, KTLS and krpingPiotr Kubaj2023-02-251-0/+4
| | | | | | | | | | | | | | | | Summary: This review ports mlx5 driver, kernel's OFED stack (userland is already enabled), KTLS and krping to powerpc64 and powerpc64le. krping requires a small change since it uses assembly for amd64 / i386. NOTE: On powerpc64le RDMA works fine in the userspace with libmlx5, but on powerpc64 it does not. The problem is that contrib/ofed/libmlx5/doorbell.h checks for SIZEOF_LONG but this macro exists on neither powerpc64* nor amd64. Thus, the file silently goes to the fallback function written for 32-bit architectures. It works fine on little-endian architectures, but causes a hard fail on big-endian. It's possible it may also cause some runtime issues on little-endian. Thus, on powerpc64 I verified that RDMA works with krping. Reviewers: #powerpc, hselasky Subscribers: bdrewery, imp, emaste, jhibbits Differential Revision: https://reviews.freebsd.org/D38786
* ck_queue: add CK_*_FOREACH_FROMMark Johnston2023-02-251-0/+15
| | | | | | | | | | | This is a variant of CK_*_FOREACH from FreeBSD queue.h which starts iteration at the specified item. If the item pointer is NULL, iteration starts from the beginning of the list. Upstream commit 74366be35a6f4635f248a3c62d2d23245a4eb0f4. MFC after: 2 weeks Sponsored by: Klara, Inc.