aboutsummaryrefslogtreecommitdiff
path: root/sys/compat/linuxkpi/common/include
Commit message (Collapse)AuthorAgeFilesLines
...
* LinuxKPI: 802.11: improve emulate chanctx implementationBjoern A. Zeeb2026-04-181-56/+16
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Now that all dependencies are implemented improve our chanctx emulation. Some drivers still rely on chandef information for channel work. In order to only do chanctx updates within mac80211 in Linux and likewise in the LinuxKPI 802.11 compat layer, emulation functions were introduced which claim to support chanctx driver operation but in reality convert these to chandef field updates and (*config) downcalls. This is relevant to several mt76 chipsets (at least 7615, 7915), and rtw88 and certain rtw89 chipsets (8851b, and the ones not supporting SCAN_OFFLOAD or BEACON_FILTER) for us. Migrate the logic out of the header and improve it. Make use of the introduced dflt_chandef and scan_chandef fields, add comparison of chandefs to see if we have to update, etc. Also add strict checks for driver settings in linuxkpi_ieee80211_alloc_hw() to make sure all preconditions are correctly met. Store the result if we are using the emulation functions in a field, so we can later check on it and also leave a note to the users if emulation is used in order to improve debugging on possible problem reports. Use the new field that we use emulation in lkpi_ic_set_channel() instead of a hand crafted check. Sponsored by: The FreeBSD Foundation MFC after: 3 days Fixes: ac1d519c01ca8 ("LinuxKPI: 802.11: adjustments for v6.11..")
* linuxkpi: Fix an off-by-one error in the kfifo implementationMark Johnston2026-04-151-2/+2
| | | | | | | | | | | | | | "total" is the number of slots in the array, so wraparound needs to be done when "first" or "last" is greater than or equal to the number of slots. Note that no consumers of the code are currently connected to the kernel build. Reported by: Stanislav Fort <stanislav.fort@aisle.com> Reviewed by: bz, emaste MFC after: 1 week Differential Revision: https://reviews.freebsd.org/D56371
* linuxkpi: Add <linux/ascii85.h>Jean-Sébastien Pédron2026-04-061-0/+46
| | | | | | | | | This is used by the i915 DRM driver for some time to log more details about a GPU error, but the code was commented out. Reviewed by: emaste Sponsored by: The FreeBSD Foundation Differential Revision: https://reviews.freebsd.org/D56282
* linuxkpi: Define missing `SZ_*` below 1 kibJean-Sébastien Pédron2026-04-061-0/+11
| | | | | | | | The amdgpu DRM driver started to use it in Linux 6.11. Reviewed by: bz, emaste Sponsored by: The FreeBSD Foundation Differential Revision: https://reviews.freebsd.org/D55740
* linuxkpi: Define `MIN_T()` and `MAX_T()`Jean-Sébastien Pédron2026-04-061-0/+3
| | | | | | | | | | | There are the same as `MIN()` and `MAX()` except that they take a type to cast both arguments to compare. The DRM generic code started to use it in Linux 6.11. Reviewed by: bz, emaste Sponsored by: The FreeBSD Foundation Differential Revision: https://reviews.freebsd.org/D55739
* linuxkpi: Document why <linux/pci.h> can't include <linux/ioport.h>Jean-Sébastien Pédron2026-04-061-0/+11
| | | | | | Reviewed by: bz, emaste Sponsored by: The FreeBSD Foundation Differential Revision: https://reviews.freebsd.org/D55738
* linuxkpi: Add field `flags` to `struct resource`Jean-Sébastien Pédron2026-04-061-0/+1
| | | | | | | | | | | This in the Linux version of `struct resource`, not the FreeBSD native structure. The amdgpu DRM driver started to use it in Linux 6.11. Reviewed by: bz Sponsored by: The FreeBSD Foundation Differential Revision: https://reviews.freebsd.org/D55737
* linuxkpi: Add <linux/mfd/core.h>Jean-Sébastien Pédron2026-04-061-0/+49
| | | | | | | | | | | | | | | | | | | To be exact, there was a dummy file with no content before. This commit defines `struct mfd_cell` and adds two function stubs. The function stubs are not implemented but still return success. They log a message to indicate they need to be implemented. Also, unlike Linux, <linux/mfd/core.h> includes <linux/ioport.h>. This works around the fact that we can't include <linux/ioport.h> from <linux/pci.h>, due to a conflict with the FreeBSD-native `struct resource`. The amdgpu DRM driver started to use it in Linux 6.11. Reviewed by: bz, emaste Sponsored by: The FreeBSD Foundation Differential Revision: https://reviews.freebsd.org/D55736
* linuxkpi: Add <linux/linux_logo.h>Jean-Sébastien Pédron2026-04-061-0/+19
| | | | | | | | | It only defines the `struct linux_logo` structure for now. It does not define any actual logo. Reviewed by: bz, emaste Sponsored by: The FreeBSD Foundation Differential Revision: https://reviews.freebsd.org/D55735
* linuxkpi: Define `PMD_SHIFT`Jean-Sébastien Pédron2026-04-061-0/+34
| | | | | | | | | | For now, only define it for x86 architectures. The DRM generic code started to use it in Linux 6.11. Reviewed by: bz, emaste Sponsored by: The FreeBSD Foundation Differential Revision: https://reviews.freebsd.org/D55734
* linuxkpi: Define `CONFIG_PGTABLE_LEVELS`Jean-Sébastien Pédron2026-04-061-0/+35
| | | | | | | | | | This is a kernel configuration constant that is expected to be defined. The DRM generic code started to use it in Linux 6.11. Reviewed by: bz Sponsored by: The FreeBSD Foundation Differential Revision: https://reviews.freebsd.org/D55733
* linuxkpi: Add mising functions in <linux/kmsg_dump.h>Jean-Sébastien Pédron2026-04-061-0/+42
| | | | | | | | | The DRM generic code started to use `kmsg_dump_get_buffer()` and `kmsg_dump_rewind()` in Linux 6.11. Reviewed by: bz, emaste Sponsored by: The FreeBSD Foundation Differential Revision: https://reviews.freebsd.org/D55732
* linuxkpi: Define `_THIS_IP_`Jean-Sébastien Pédron2026-04-061-0/+2
| | | | | | | | | | For now, the macro is not implemented and it returns 0. The DRM generic code started to use it in Linux 6.11. Reviewed by: bz, emaste Sponsored by: The FreeBSD Foundation Differential Revision: https://reviews.freebsd.org/D55731
* linuxkpi: Move `_RET_IP_` to <linux/instruction_pointer.h>Jean-Sébastien Pédron2026-04-062-2/+14
| | | | | | | | This matches the declaration on Linux. Reviewed by: bz, emaste Sponsored by: The FreeBSD Foundation Differential Revision: https://reviews.freebsd.org/D55730
* linuxkpi: Add `strtomem()` and `strtomem_pad()`Jean-Sébastien Pédron2026-04-061-0/+16
| | | | | | | | The DRM generic code started to use `strtomem_pad()` in Linux 6.11. Reviewed by: bz Sponsored by: The FreeBSD Foundation Differential Revision: https://reviews.freebsd.org/D55729
* linuxkpi: Handle bin attributes in sysfs attribute groupsJean-Sébastien Pédron2026-04-011-9/+25
| | | | | | | | | | | | | | | | | | | | | For instance, this is used by DRM drivers to declare the EDID property of an GPU output connector: sysctl -b sys.device.drmn1.card0.card0-DP-1.edid | edid-decode ... Block 0, Base EDID: EDID Structure Version & Revision: 1.4 Vendor & Product Identification: Manufacturer: SAM Model: 29814 Serial Number: 810635354 (0x3051505a) Made in: week 15 of 2025 ... Reviewed by: bz, emaste, wulf Sponsored by: The FreeBSD Foundation Differential Revision: https://reviews.freebsd.org/D55176
* LinuxKPI: add supporting #includesBjoern A. Zeeb2026-03-213-0/+3
| | | | | | | | | | | | | | Compiling drm-kmod on !X86 does not include asm/smp.h which includes preempt.h on FreeBSD. In order to compile drm-kmod on other architectures add the secondary #includes for preempt.h to spinlock.h and hardirq.h (which now also gets included from highmem.h) to connect the #include chain. Sponsored by: The FreeBSD Foundation MFC after: 3 days PR: 279864 Reviewed by: jhibbits, emaste Differential Revision: https://reviews.freebsd.org/D55974
* LinuxKPI: Fix simple_read_from_buffer for zero-size and off-the-end readsJohn Baldwin2026-03-171-2/+2
| | | | | | | | | | | | I noticed that the buf_size < 0 check can never be true (it's a size_t) and decided to check for this condition by an alternate expression, and I also noticed that a read_size of 0 would incorrectly return -EFAULT. Instead, return success for both of these cases as reading beyond the EOF of a normal file also returns EOF, not EINVAL. Reviewed by: bz Sponsored by: AFRL, DARPA Differential Revision: https://reviews.freebsd.org/D55845
* lindebugfs: Pass user buffer pointers to the read/write file operationsJohn Baldwin2026-03-172-16/+14
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The Linux file_operations API expects the read and write operations to take a single user buffer pointer (along with the length and the file offset as an in/out parameter). However, the debugfs_fill function was violating this part of the contract as it was passing down kernel pointers instead. An earlier commit (5668c22a13c6befa9b8486387d38457c40ce7af4) hacked around this by modifying simple_read_from_buffer() to treat its user pointer argument as a kernel pointer instead. However, other commits keep tripping over this same API mismatch (e.g. 78e25e65bf381303c8bdac9a713ab7b26a854b8c passes a kernel pointer to copy_from_user in fops_str_write). Instead, change debugfs_fill to use the "raw" pseudofs mode where the uio is passed down to directly to the fill callback rather than an sbuf. debufs_fill now iterates over the iovec in the uio similar to the implementation of uiomove invoking the read or write operation on each user pointer. This also fixes a tiny bug where the initial file offset from uio_offset was ignored. Instead, the operations were always invoked with a file offset of 0. As part of this, revert the the changes to simple_read_from_buffer() from commit 5668c22a13c6befa9b8486387d38457c40ce7af4. Also as part of this, the simple_attr_read/write methods and seq_read now also need to accept and handle user pointers (also matching the API in Linux). For simple_attr_write*(), copy the user buffer into a kernel buffer before parsing. Also, do not permit writes at an offset as it's unclear what the semantics for those would even be (perhaps you would write out the formatted value into a buffer first and then allow the copy_from_user to overwrite/extend that buffer and then re-parse the integer value?). The old handling of *ppos for writes was definitely wrong before and only worked for an offset of 0 anyway. Reviewed by: bz Sponsored by: AFRL, DARPA Differential Revision: https://reviews.freebsd.org/D55833
* LinuxKPI: pass attrs in more places in dma-mapping.hBjoern A. Zeeb2026-03-041-6/+6
| | | | | | | | | | | | | | | | Various macros (dma_map_sg_attrs, dma_unmap_sg_attrs, dma_map_single_attrs, and dma_unmap_single_attrs) currently supress passing on the attrs argument. Their implementation (even though at times still marked the argument __unused; we remove that) have long gained support for handling the argument. With ofed fixed (5edf24aac1d09), pass the argument through so that other drivers using these functions may hopefully work just a bit better as well. Sponsored by: The FreeBSD Foundation MFC after: 3 days Reviewed by: kib Differential Revision: https://reviews.freebsd.org/D55391
* LinuxKPI: 802.11: improve prep_tx_infoBjoern A. Zeeb2026-03-041-1/+0
| | | | | | | | | | | | | | | | | | | | | Over time struct ieee80211_prep_tx_info has grown further fields. One which is becoming mandatory is the subtype (of the mgmt frame). iwlwifi(mld) has a WARN for it if it does not match, so we now have to set this for proper operation. In addition we are tyring to improve the situation of setting/unsetting (prepare_tx/complete_tx) in various states and cleanup the use of other fields but link_id which we now leave as a marker for the future everywhere. The general problem we are facing is that our hook surface in this case is the state machine but likely would have to be tx/rx mgmt frames but we would alos have to driver the TX queues from there which is tricky. The long-term answer is to change net80211. Further the hardware flag DEAUTH_NEED_MGD_TX_PREP is dead and was removed again in favour of leting drivers deal with it. iwlwifi(mvm) likely being the only driver which ever used this. Sponsored by: The FreeBSD Foundation MFC after: 3 days
* LinuxKPI: avoid -Werror=unused-value in sort() from BUILD_BUG_ON_ZERO()Siva Mahadevan2026-03-031-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | The BUILD_BUG_ON_ZERO() macro returns an (int)0 if it does not fail at build time. LinuxKPI sort() has it as a guard for an unsupported argument but ignores the return value. This leads to gcc complaining: /usr/src/sys/compat/linuxkpi/common/include/linux/build_bug.h:60:33: error: statement with no effect [-Werror=unused-value] 60 | #define BUILD_BUG_ON_ZERO(x) ((int)sizeof(struct { int:-((x) != 0); })) | ^ /usr/src/sys/compat/linuxkpi/common/include/linux/sort.h:37:9: note: in expansion of macro 'BUILD_BUG_ON_ZERO' 37 | BUILD_BUG_ON_ZERO(swap); \ | ^~~~~~~~~~~~~~~~~ /usr/src/sys/contrib/dev/rtw89/core.c:2575:9: note: in expansion of macro 'sort' 2575 | sort(drift, RTW89_BCN_TRACK_STAT_NR, sizeof(*drift), cmp_u16, NULL); Change to BUILD_BUG_ON() for the statement version. Reported by: CI Co-authored-by: bz Approved by: emaste (mentor) MFC after: 3 days Sponsored by: The FreeBSD Foundation Differential Revision: https://reviews.freebsd.org/D55634
* LinuxKPI: 802.11: add cfg80211 (*change_bss) and related structsBjoern A. Zeeb2026-02-111-1/+11
| | | | | | | Needed by brcmfmac v6.19. Sponsored by: The FreeBSD Foundation MFC after: 3 days
* brcm80211: add LinuxKPI files and module MakefilesBjoern A. Zeeb2026-02-105-0/+277
| | | | | | | | | | | | | | sys/compat/linuxkpi/common/include/linux/platform_data/brcmfmac.h is based on git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git e5f0a698b34ed76002dc5cff3804a61c80233a7a ( tag: v6.17 ). Currently only PCIe is made to compile. It does load firmware (if needed, e.g., on arm64 with an alignment issue fixed), and starts to come up. To make it work there is a cfg80211 layer and netdevice integration to do, so do not hold your breath just yet.
* LinuxKPI: add scoped_guard(), spinlock guard supportBjoern A. Zeeb2026-02-092-28/+109
| | | | | | | | | | | | | | | | | | | The "cleanup.h" implementation got a bit more complicated. For one we now use a macro to concatenate a prefix, the name, and a suffix for variable and function declarations. This was triggered by the fact that the "guard_" prefix we used was confusing. We now use a generic "cleanup_" which is only encoded in the single place rather than all over the file. As already indicated by the comment the DEFINE_LOCK_GUARD_0() macro got split up and a _1 version which also takes a type got implemented and is used for a spinlock variant used by rtw89(4) via the new scoped_guard() bits. Sponsored by: The FreeBSD Foundation MFC after: 3 days Differential Revision: https://reviews.freebsd.org/D54808
* LinuxKPI: mod_devicetable, add comment about [future] LinuxKPI USBBjoern A. Zeeb2026-02-091-0/+6
| | | | | | | | | | USB structures are defined with the native USB implementation. Just leave a comment why they are not here. Sponsored by: The FreeBSD Foundation MFC after: 3 days Reviewed by: dumbbell Differential Revision: https://reviews.freebsd.org/D54991
* LinuxKPI: move MODULE_DEVICE_TABLE from pci.h to module.hBjoern A. Zeeb2026-02-092-18/+18
| | | | | | | | | | | | | | | | Move the MODULE_DEVICE_TABLE macro to module.h where it belongs in preparation for different bus (e.g., USB, SDIO) support. The various struct <bus>_device_id, if not elsewhere, should be defined in mod_devicetable.h. This is the next step after 2f5666c1727c. No functional changes. Sponsored by: The FreeBSD Foundation MFC after: 3 days Reviewed by: emaste, dumbbell Differential Revision: https://reviews.freebsd.org/D54900
* LinuxKPI: string_choices.h: use ternary operatorBjoern A. Zeeb2026-02-031-20/+5
| | | | | | | | | | | Switch from using if () else to a direct return (?:) code. No functional changes. Suggested by: kib (D55029) Sponosred by: The FreeBSD Foundation MFC after: 3 days Reviewed by: emaste (before removing more () as suggested by him) Differential Revision: https://reviews.freebsd.org/D55088
* LinuxKPI: add str_read_write()Bjoern A. Zeeb2026-02-031-0/+9
| | | | | | | | | Needed by a wireless driver. Sponsored by: The FreeBSD Foundation MFC after: 3 days Reviewed by: kib, emaste Differential Revision: https://reviews.freebsd.org/D55029
* linuxkpi: Add tag support to radix treeJean-Sébastien Pédron2026-01-281-4/+25
| | | | | | | | | | | | | | | | | | | | | The tag is used to perform lookup in a different way. New functions were introduced: * to set, check and clear a tag * to walk through a radix tree based on a given tag Furthermore, the `radix_tree_delete()` function was modified to clear tags on deletion. The amdgpu DRM driver started to use this in Linux 6.10. While here, the `radix_tree_gang_lookup()` function was added because it is very close to `radix_tree_gang_lookup_tag()`, but it is not used by the DRM drivers as of this commit. Reviewed by: emaste Sponsored by: The FreeBSD Foundation Differential Revision: https://reviews.freebsd.org/D54503
* linuxkpi: Add eventfd_*()Jean-Sébastien Pédron2026-01-251-0/+54
| | | | | | | | | | | | Add <linux/eventfd.h> and expose the `eventfd_*()` API. This is used by DRM drivers for some time, but the code was commented out so far. Note that Linux uses `struct eventfd_ctx`, but FreeBSD defines `struct eventfd`. We define `eventfd_ctx` as a synonym to `eventfd`. Reviewed by: christos, markj Sponsored by: The FreeBSD Foundation Differential Revision: https://reviews.freebsd.org/D50853
* LinuxKPI: improve hweight<n> if complie time constantBjoern A. Zeeb2026-01-251-6/+6
| | | | | | | | | | | rtw89(4) uses a static_assert() with hweight<n> calls. In order to avoid compile time errors, deal with the case when the arguments to hweight<n> are complie time constant. Sponsored by: The FreeBSD Foundation MFC after: 3 days Reviewed by: emaste Differential Revision: https://reviews.freebsd.org/D54806
* LinuxKPI: add umin()Bjoern A. Zeeb2026-01-251-0/+3
| | | | | | | | | | Add a version of umin() simply using MIN() assuming that the Linux upstream code properly check that the arguments are unsigned, etc. Sponsored by: The FreeBSD Foundation MFC after: 3 days Reviewed by: emaste Differential Revision: https://reviews.freebsd.org/D54807
* LinuxKPI: implement dmam_free_coherent()Bjoern A. Zeeb2026-01-251-0/+9
| | | | | | | | | | | dmam_free_coherent() is used by an updated mt76 driver at v6.19-rc6. We need to surgically find the devres information and destroy it before calling dma_free_coherent. Sponsored by: The FreeBSD Foundation MFC after: 3 days Reviewed by: emaste Differential Revision: https://reviews.freebsd.org/D54810
* LinuxKPI: PTP add (*settime64) to struct ptp_clock_infoBjoern A. Zeeb2026-01-251-0/+1
| | | | | | | | | | | | While iwlwifi supportes PTP, LinuxKPI does not and we only add the definitons to avoid mangling upstream drivers. iwlwifi(4) does not even support the (*settime64) callback but only returns -EOPNOTSUPP. Sponosred by: The FreeBSD Foundation MFC after: 3 days Reviewed by: emaste Differential Revision: https://reviews.freebsd.org/D54802
* linuxkpi: Implement <linux/seq_buf.h>Jean-Sébastien Pédron2026-01-241-0/+73
| | | | | | | | | | | | It is a wrapper above a `char *` to track the overall available space in the buffer as well as the used space. This wrapper does not manage memory allocation. The DRM generic code started to use this in Linux 6.10. Reviewed by: bz Sponsored by: The FreeBSD Foundation Differential Revision: https://reviews.freebsd.org/D54488
* mt76: update Mediatek's mt76 driverBjoern A. Zeeb2026-01-232-1/+61
| | | | | | | | | | | | | | | This version is based on git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git 24d479d26b25bce5faea3ddd9fa8f3a6c3129ea7 ( tag: v6.19-rc6 ). Notable change: license got switched from ISC to BSD-3-Clause-Clear. util.h is now imported from upstream given it is no longer GPL-only. See the upstream repository 909675fd4344f73aad5f75f123bd271ada2ab9fb and a96fed2825d8dfb068bf640419c619b5f2df4218. For us the new version should also help with page pools and DMA32. Sponsored by: The FreeBSD Foundation
* LinuxKPI: netdevice: add structs net_device_path, net_device_path_ctxBjoern A. Zeeb2026-01-211-0/+24
| | | | | | | | mt76(4) is using this along with a mac80211.h functiontion pointer to resolve a path in an offload case. Sponsored by: The FreeBSD Foundation MFC after: 3 days
* LinuxKPi: 802.11: add more definesBjoern A. Zeeb2026-01-213-0/+4
| | | | | | | | Add more defines and a mac80211 op function pointer used by mt76(4) at Linux v6.19-rc6. Sponsored by: The FreeBSD Foundation MFC after: 3 days
* LinuxKPI: skbuff: implement skb_queue_splice()Bjoern A. Zeeb2026-01-211-1/+8
| | | | | | | | | Add skb_queue_splice() and use it in skb_queue_splice_init() which already had that functionality (plus the init bit). The new function is used by rtw89(4). Sponosred by: The FreeBSD Foundation MFC after: 3 days
* LinuxKPI: 802.11: rename enum ieee80211_tx_rate_flags and move fileBjoern A. Zeeb2026-01-212-14/+13
| | | | | | | | | | What we used to call enum ieee80211_tx_rate_flags is now used as enum mac80211_rate_control_flags for the ieee80211_tx_rate.flags in rtw89(4). Rename the enum and move it to mac80211 as it seems to belong there. Sponsonred by: The FreeBSD Foundation MFC after: 3 days
* LinuxKPI: 802.11: add new field to struct cfg80211_bitrate_maskBjoern A. Zeeb2026-01-211-0/+3
| | | | | | | | rtw89(4) accesses eht_mcs[]. Add the field to struct cfg80211_bitrate_mask. Sponsored by: The FreeBSD Foundation MFC after: 3 days
* LinuxKPI: 802.11: Management MIC element can have 8 or 16 octets MICBjoern A. Zeeb2026-01-211-3/+11
| | | | | | | | | Management MIC element (MME) can have 8 or 16 octets MIC. Add a second structure used by at least iwlwifi and update reference to latest standard version. Sponsored by: The FreeBSD Foundation MFC after: 3 days
* LinuxKPI: 802.11: factor out rate logic for mandatory channelsBjoern A. Zeeb2026-01-202-3/+14
| | | | | | | | | | | | | | | I was looking at rate work for another problem and found more flags in ath9k (which we will likely never need). The documentation then revealed the "mandatory" flags as well and with discussions about cfg80211 going on I decided to use the momentum and split our "supp_rates" setup between lkpi_lsta_alloc() and wiphy_register(). There should be no functional change. While there also initialize max_rc_amsdu_len. Sponsored by: The FreeBSD Foundation MFC after: 3 days
* LinuxKPI: pci: fix pcie_get_speed_cap()Bjoern A. Zeeb2026-01-141-9/+18
| | | | | | | | | | | | | pcie_get_speed_cap() has a hard coded skip of 3 devices at the beginning. It is either called on a pdev or on a result from pci_upstream_bridge(). In the latter case skipping another three devices might get us to acpi0 or nexus, neither of which is a PCI device still and pci_get_vendor() will panic() on that. Sponsored by: The FreeBSD Foundation (commit) GHI: https://github.com/freebsd/drm-kmod/issues/393 MFC after: 2 weeks Differential Revision: https://reviews.freebsd.org/D53862
* LinuxKPI: include acpi headers for RISC-VBjoern A. Zeeb2026-01-141-1/+1
| | | | | | | | | | | | In order to compile iwlwifi(4), which is reported to work on RISC-V, include the ACPI headers to avoid adding further FreeBSD-specific #ifdefs to the driver. With this iwlwifi(4) just compiles on RISC-V (at least if ACPI support is turned off in the module Makefile). Sponsored by: The FreeBSD Foundation MFC after: 3 days Reviewed by: emaste Differential Revision: https://reviews.freebsd.org/D54692
* linuxkpi: Add `rol32()`Jean-Sébastien Pédron2026-01-071-0/+6
| | | | | | | | | | | `rol64()` and `rol32()` are used by <linux/siphash.h>. The former was added previously, before <linux/siphash.h> was added. However the latter was not, and it broke the build on armv7. Reported by: adrian Reviewed by: adrian, rpokala Sponsored by: The FreeBSD Foundation Differential Revision: https://reviews.freebsd.org/D54588
* linuxkpi: Replicate the chain of #include in the `cec*.h` headersJean-Sébastien Pédron2026-01-074-0/+59
| | | | | | | | | | The i915 DRM driver depends on this namespace pollution to access `debugfs_*` functions, after several explicit #include of <linux/debugfs.h> were removed in Linux 6.10. Reviewed by: bz, christos Sponsored by: The FreeBSD Foundation Differential Revision: https://reviews.freebsd.org/D54494
* linuxkpi: Add WARN_RATELIMIT()Jean-Sébastien Pédron2026-01-071-0/+7
| | | | | | | | The i915 DRM driver started to use it in Linux 6.10. Reviewed by: bz, christos Sponsored by: The FreeBSD Foundation Differential Revision: https://reviews.freebsd.org/D54493
* linuxkpi: Add <linux/kmsg_dump.h>Jean-Sébastien Pédron2026-01-071-0/+51
| | | | | | | | | | | | | This header declares register/unregister functions to allow a piece of code to tell what function to call in case of a panic. Several panic handlers may be registered. The DRM generic code started to use it in Linux 6.10 as part of the panic handler. Reviewed by: bz, christos Sponsored by: The FreeBSD Foundation Differential Revision: https://reviews.freebsd.org/D54492