| Commit message (Collapse) | Author | Age | Files | Lines |
| ... | |
| |
|
|
|
|
|
|
| |
This is a preparation step for a future addition to this file. This is
also closer to what Linux does.
Reviewed by: emaste
Sponsored by: The FreeBSD Foundation
|
| |
|
|
|
|
|
|
|
| |
Add the conditional compile time option defaulting to off as we do
not support leds in LinuxKPI to ath10k for the new file.
Add empty struct gpio_led to LinuxKPI.
MFC after: 3 days
|
| |
|
|
|
|
|
|
|
| |
If CONFIG_NET_MEDIATEK_SOC_WED is not set then be silent; if
CONFIG_NET_MEDIATEK_SOC_WED is set we will enable logic or rather te
pr_debug("TODO") calls for now.
Spsonsored by: The FreeBSD Foundation
MFC after: 3 days
|
| |
|
|
|
|
|
|
|
|
| |
Move the enum and leave a comment on the struct member for the vif
about the type.
No functional changes.
Sponsored by: The FreeBSD Foundation
MFC after: 3 days
|
| |
|
|
|
|
|
|
|
|
|
|
| |
Some of these are used by mt76 and while I was here and it only was
a handfull I figured I should just clean this all up.
There is one problem in that between 802.11az and 802.11-2024 action
frame formats have changed; I got compile errors from iwlwifi(4) given
I updated them to -2024 so we remain on older versions for the moment.
Sponsored by: The FreeBSD Foundation
MFC after: 3 days
|
| |
|
|
|
|
|
|
|
| |
The logic in device_release_driver() got disabled in 93b14194acaf2
and since left alone. Add a pr_debug() call so we have a chance to
notice if that code is actually still in need to be fixed and re-enabled.
Sponsored by: The FreeBSD Foundation
MFC after: 3 days
|
| |
|
|
|
|
|
|
|
| |
We are ways away from implementing "airtime fairness" in LinuxKPI
(or rather net80211). For now make it an 'improve' rather than a
'todo' to get the logging away. Everything will work without it.
Sponsored by: The FreeBSD Foundation
MFC after: 3 days
|
| |
|
|
|
|
|
|
| |
Switch to link_sta_dereference_check rather than _protected to access
the value. The actual problem we hit was elsewhere though.
Sponsored by: The FreeBSD Foundation
MFC after: 3 days
|
| |
|
|
|
|
|
|
|
|
|
|
|
| |
cfg80211_chandef_create() gets passed a pointer to a cfg80211_chan_def.
It seems that several users are passing in an uninitialized variable
from the stack and expect cfg80211_chandef_create() to initialize it.
Run memset() on the struct, which for all callers currently seems to do
the right thing, to avoid later accesses to uninitialized struct members
like "punctured".
Reported by: CI (gcc build)
MFC after: 3 days
Sponsonred by: The FreeBSD Foundation
|
| |
|
|
|
|
|
|
|
|
| |
This adds empty implementations of pm_vt_switch_(un)register which
are used by nvidia-drm. We do not need to specify anything here as
a VT switch always happens on suspend/resume.
Sponsored by: NVIDIA
Reviewed by: kbowling (mentor), emaste
Differential Revision: https://reviews.freebsd.org/D53400
|
| |
|
|
|
|
|
| |
This includes the conflicting changes from previous driver versions
(v6.11/v6.14), mostly being function pointer or function arguments.
MFC after: 3 days
|
| |
|
|
|
|
|
|
|
|
|
| |
Don't use __LP64__ to decide the value, as it gives the wrong result on
CHERI platforms. Just define it in terms of __SIZEOF_LONG__. Make a
similar adjustment for BITS_PER_LONG_LONG while here.
Reviewed by: bz, dumbbell, emaste
MFC after: 1 week
Sponsored by: CHERI Research Centre (EPSRC grant UKRI3001)
Differential Revision: https://reviews.freebsd.org/D53135
|
| |
|
|
|
|
|
|
|
|
|
|
| |
This includes some type cleanups as well as some shuffling of structs
and functions to sort dependencies out. Few new functions and defines
as well as new struct members. Minor fixes to style and debug logging.
This is the majority of changes. None of these should conflict with
current in-tree drivers. The final bit of changes will come along with
the driver updates adding an extra argument to function pointers.
MFC after: 3 days
|
| |
|
|
|
|
|
| |
For the moment add skeleton functions for netif_device_attach/detach()
needed by rtw8[89] v6.17.
MFC after; 3 days
|
| |
|
|
|
|
|
| |
This likely belongs in socket code which we do not have in LinuxKPI.
Needed by a wirless driver at v6.17.
MFC after: 3 days
|
| |
|
|
|
|
|
|
| |
We do not support Wireless Ethernet Dispatch (wed) on the mt76 (yet).
Add pr_debug calls with TODO in case we run into the calls anyway so
we could deal with them.
MFC after: 3 days
|
| |
|
|
|
|
|
|
|
| |
page_pool headers were not used yet; they were created for mt76 but
are without functionality. Upstream has migrated them for v6.17 and
split them up into multiple files. Also add netmem.h which the little
needed is directly related to page pools.
MFC after: 3 days
|
| |
|
|
|
|
|
|
|
|
|
|
| |
Given we do not yet support "wake" bits in device there is little need
doing it in PCI if we cannot check if we are supposed to do the
operation in first place. Once we would implement this, we would need
to also do the appropriate PCI (pme) checks before enabling (disabling)
it.
MFC after: 3 days
Reviewed by: dumbbell
Differential Revision: https://reviews.freebsd.org/D53208
|
| |
|
|
|
|
|
|
|
| |
We do not currently aim to support crypto FIPS compliance in LinuxKPI
so keep this turned off.
MFC after: 3 days
Reviewed by: emaste, dumbbell
Differential Revision: https://reviews.freebsd.org/D53207
|
| |
|
|
|
|
|
|
|
| |
Needed by multiple wireless driver for the v6.17 update (likely earlier
versions already).
MFC after: 3 days
Reviewed by: dumbbell
Differential Revision: https://reviews.freebsd.org/D53206
|
| |
|
|
|
|
|
|
|
|
| |
The return type now is void; I believe no one ever used this
so we can just chnage it. The only active platform_driver_register()
calls seems to be in ath1[01]k and mt76 and there in unsupported code.
MFC after: 3 days
Reviewed by: dumbbell, emaste
Differential Revision: https://reviews.freebsd.org/D53205
|
| |
|
|
|
|
|
|
| |
We will see how much we will need them and how to fill them at that
point. They are left with a pr_debug("TODO") for now.
MFC after: 3 days
Differential Revision: https://reviews.freebsd.org/D53204
|
| |
|
|
|
|
|
|
| |
The former is needed by a wireless driver at v6.17.
MFC after: 3 days
Reviewed by: dumbbell, emaste
Differential Revision: https://reviews.freebsd.org/D53203
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Like lkpi_pci_get_domain_bus_and_slot() implement lkpi_pci_get_slot()
using pci_find_bsf() instead of pci_find_dbsf() (no domain).
This is needed for a wireless driver.
Unfortunately the name [pci_get_slot()] collides with the native PCI
function. Add a guard around it and disable the use when the native
version is required (in lkpifill_pci_dev() and in bnxt/bnxt_en; if the
latter gets fixed we can probably also fix work around it in the former;
further conflicts in drm-kmod 6.1-lts, 6.6-lts, and master were resolved).
Sponsored by: The FreeBSD Foundation (initially)
MFC aftre: 3 days
Reviewed by: dumbbell
Differential Revision: https://reviews.freebsd.org/D52065
|
| |
|
|
|
|
|
|
|
|
|
|
| |
Chace Linux change fca76071bab2 ("lib/string_helpers: Split out
string_choices.h") from v6.5. Everything that we implemented from
string_helpers.h has moved, so rename the file, update the include
guards, and add a new dummy string_helpers.h that just #includes it.
This matches Linux for the functionality that we have.
Reviewed by: bz
Sponsored by: The FreeBSD Foundation
Differential Revision: https://reviews.freebsd.org/D52606
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
| |
dem_kfree() is called from all over the place and should actually
do something; contrary to lkpi_devm_kmalloc_release() it can also
take a const void *. We have to __DECONST() that though as the
entire devres framework does otherwise not take a const argument.
This was discovered during the rtw89 upadte to 6.16.
Sponsored by: The FreeBSD Foundation (initially)
MFC after: 3 days
Reviewed by: dumbbell
Differential Revision: https://reviews.freebsd.org/D52082
|
| |
|
|
|
|
|
|
|
| |
Needed by a wifi driver update.
Sponsored by: The FreeBSD Foundation (initially)
MFC after: 3 days
Reviewed by: dumbbell
Differential Revision: https://reviews.freebsd.org/D52080
|
| |
|
|
|
|
|
|
|
| |
These came up during a wifi driver update.
Sponsored by: The FreeBSD Foundation (initially)
MFC after: 3 days
Reviewed by: dumbbell
Differential Revision: https://reviews.freebsd.org/D52079
|
| |
|
|
|
|
|
|
|
|
|
|
| |
It seems overflow.h wsa imported directly from Linux in 3208d4ad2b8320a.
Update the file to the newer version as needed for wireless driver updates.
Sponsored by: The FreeBSD Foundation (initially)
MFC after: 3 days
Obtained from: git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
038d61fd642278 (tag: v6.16)
Reviewed by: dumbbell
Differential Revision: https://reviews.freebsd.org/D52078
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
| |
Use __builtin_object_size() by default.
If __builtin_dynamic_object_size() is available use that instead.
I would hope that in a future version we can remove the conditional
checks but in order to be able to MFC this without checking all
compiler versions simply keep it this way for now.
Sponsored by: The FreeBSD Foundation (initially)
MFC after: 3 days
Reviewed by: dumbbell
Differential Revision: https://reviews.freebsd.org/D52077
|
| |
|
|
|
|
|
|
|
|
|
|
|
| |
This adds guard support for non-real-types like rcu locking meaning
that we need to keep the lock state separately ourselves. _T is still
special and needs to be updated. Given it may not be used it needs
an __unused attribute (we are using the LinuxKPI __maybe_unused which
indeed is more expressive in this case).
Sponsored by: The FreeBSD Foundation (initially)
MFC after: 3 days
Reviewed by: dumbbell
Differential Revision: https://reviews.freebsd.org/D52076
|
| |
|
|
|
|
|
|
|
| |
A wifi driver update needs this.
Sponsored by: The FreeBSD Foundation (initially)
MFC after: 3 days
Reviewed by: dumbbell
Differential Revision: https://reviews.freebsd.org/D52075
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
| |
del_timer() got renamed to timer_delete() approximately in Linux 6.2
(similar for *_sync and likely others).
Keep the old functions as compat; unclear when we can gc them.
We should also re-define them with a linuxkpi_ prefix to avoid possible
conflicts in the future if we do a full pass over this at some point.
Sponsored by: The FreeBSD Foundation (intiially)
MFC after: 3 days
X-MFC; preserve symbols, not inline
Reviewed by: dumbbell
Differential Revision: https://reviews.freebsd.org/D52074
|
| |
|
|
|
|
|
|
|
|
|
|
| |
With Linux 6.16 from_timer() got renamed to timer_container_of(); add
the LINUXKPI_VERSION check with a default to the current version.
Update all in-tree consumers (apart from wireless drivers managed
otherwise).
Sponsored by: The FreeBSD Foundation (initially)
MFC after: 3 days
Reviewed by: dumbbell
Differential Revision: https://reviews.freebsd.org/D52073
|
| |
|
|
|
|
|
|
|
|
|
| |
The native AcpiGetHandle() and acpi_get_handle() take a
const char * argument for pathname and not an acpi_string (char *).
For that they spell it out fully as 'const char *', so should we.
Sponsored by: The FreeBSD Foundation (intially)
MFC after: 3 days
Reviewed by: dumbbell
Differential Revision: https://reviews.freebsd.org/D52072
|
| |
|
|
|
|
|
|
|
|
|
|
|
| |
The code introduced abs_diff() as migrated from drm to standard
linux headers. The LINUXKPI_VERSION check did not allow this to
be visible by default in-tree. Make sure the v6.6 check is optional.
drm-kmod always defines LINUXKPI_VERSION so this should be fine.
Sponsored by: The FreeBSD Foundation (initially)
Fixes: afc450fac9f04
MFC after: 3 days
Reviewed by: dumbbell
Differential Revision: https://reviews.freebsd.org/D52071
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Factor out the pci_request_region() implementation into an internal
function and make pci_request_region() a simple wrapperaround it.
Likewise implement pcim_request_all_regions() as a loop calling
pci_request_region() for each entry.
In two cases which we returned an error before (bar index is valid but
bar is not (no len), and neither IO nor MEM) we now reutrn success
(nothing to do for us). Otherwise callers, especially
pcim_request_all_regions() would error out for the wrong reasons.
This seems to also match the expected behaviour of pci_request_region().
Sponsored by: The FreeBSD Foundation (intially)
MFC after: 3 days
Reviewed by: dumbbell
Differential Revision: https://reviews.freebsd.org/D52068
|
| |
|
|
|
|
|
|
|
|
|
|
|
| |
Like pci_iomap() add the devres version pcim_iomap() using the former
to get the resource.
Add a helper function to validate that the bar is within a valid range
and sprinkle that check also to other related functions.
Sponsored by: The FreeBSD Foundation (intially)
MFC after: 3 days
Reviewed by: dumbbell
Differential Revision: https://reviews.freebsd.org/D52067
|
| |
|
|
|
|
|
|
|
|
|
| |
Implement for_each_pci_dev() needed by a wireless driver update.
For that also improve pci_get_device() and add the functionality to
support the odev argument to start searching from that.
Sponsored by: The FreeBSD Foundation (intially)
MFC after: 3 days
Reviewed by: dumbbell
Differential Revision: https://reviews.freebsd.org/D52066
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
| |
A port using linux(kpi) header files but not using skbuffs is hitting
the case that it cannot find opt_wlan.h. Give up to the idea that
skbuff.h is only used by wireless drivers (or in-tree) and that
IEEE80211_DEBUG (via opt_lwan.h) could autmatically compile in debug
support.
It is likely time to add a LINUXKPI_DEBUG knob in the near future
(also for linuxkpi_debug or linuxkpi_debug_rcu).
PR: 289268
MFC after: 3 days
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
The initial thought of migrating the LinuxKPI 802.11 enum into net80211
for shared use did not work out well. Currently in the need for yet
another adjustment, I decided to undo/de-couple net80211 and
LinuxKPI 802.11 again.
The enum name now gets used in LinuxKPI based wifi drivers and it
turns out it is spelt differntly than what I used initially.
This creates a conflict.
net80211 still in the need to be able to express BW_320 in an uint8_t
will likely be fine with the current solution as well. Rename the
enum and prefixes in net80211 to "net80211" instead of "ieee80211".
Apart from the names/prefix we leave the values the same.
In LinuxKPI add the enum with the expected name and use it there
throughout to make modern versions of LinuxKPI based wifi drivers
compile.
Sponsored by: The FreeBSD Foundation
Fixes: ca389486a9599, 2c8b0d6205f6f
MFC after: 3 days
Reviewed by: adrian
Differential Revision: https://reviews.freebsd.org/D52064
|
| |
|
|
|
|
|
|
|
|
|
| |
Given the checksum offloading flags are mutually exclusive and are
not a bit mask, we can compress them into 2 bit for the four possible
values. Change the define but leave the type at uint8_t for now with
a comment. We can possible combine them with another sub-octet field
in the future.
Sponsored by: The FreeBSD Foundation
MFC after: 3 days
|
| |
|
|
|
|
|
|
| |
These structs as part of the union are used to handle raw packet data
so mark them all __packed.
Sponsored by: The FreeBSD Foundation
MFC after: 3 days
|
| |
|
|
|
|
|
|
|
|
| |
Implement str_disable_enable() needed by a wireless driver by using
the already existing str_enable_disable() with a toggled argument.
Sponsored by: The FreeBSD Foundation
MFC after: 3 days
Reviewed by: emaste
Differential Revision: https://reviews.freebsd.org/D52081
|
| |
|
|
|
|
| |
- s/__FreeBSD_verison/__FreeBSD_version/
MFC after: 3 days
|
| |
|
|
|
|
|
|
|
|
|
|
| |
Multicast filter updates are done at different times and either
triggered by net80211/if code or within LinuxKPI.
Keep the setting and address list and update that (only) if triggered
from net80211. Otherwise we will (depending on state) just update
additional flags.
Sponsored by: The FreeBSD Foundation
MFC after: 3 days
|
| |
|
|
|
|
|
|
|
|
| |
Adjust logging from TODO() to IMPROVE() now that we can use fmt strings
there too. Make sure we are not getting unsuported values to print.
Also for non-station mode simply return.
Sponsored by: The FreeBSD Foundation
MFC after: 3 days
|
| |
|
|
|
|
|
|
|
|
|
| |
While we used to pass in the dev_name(), we now use wiphy_dev() inside
the implementation to get the dev and the name. This is for two reasons:
(1) ath1xk also unset the dev and we need to check once we add support,
and (2) in preparation for future work, which needs to hook into that
point.
Sponsored by: The FreeBSD Foundation
MFC after: 3 days
|
| |
|
|
|
|
|
|
|
| |
Some of the annotations were not quite right. Also various fields had
not been typed properly. Correct the types of field members and
given the change also re-sort.
Sponsored by: The FreeBSD Foundation
MFC after: 3 days
|
| |
|
|
|
|
|
|
|
|
|
| |
Adjust the IMPROVE macro to also take a format string and use that
in reg_query_regdb_wmm() instead of TODO() to avoid spamming the console
with something that needs larger reworks. Return -ENODATA instead of
-ENXIO as that seems a better fit though the only consumer uses it
without checking the return value these days.
Sponsored by: The FreeBSD Foundation
MFC after: 3 days
|