| bf1dea8f | 05-Apr-2022 |
Warner Losh <[email protected]> |
linuxkpi: move io_mapping_create_wc to .c
Move io_mapping_create_wc to .c because it encodes the size of struct io_mapping so we move this from the client module to the linuxkpi module.
Approved by
linuxkpi: move io_mapping_create_wc to .c
Move io_mapping_create_wc to .c because it encodes the size of struct io_mapping so we move this from the client module to the linuxkpi module.
Approved by: re@ (gjb) Sponsored by: Netflix Reviewed by: hselasky, emaste Differential Revision: https://reviews.freebsd.org/D34776
(cherry picked from commit 132b00f90613d8cc797137d4c3d2dcb99ba3c690) (cherry picked from commit 4e94b3542dd6a5c3f60431e811013f4dbf603227)
show more ...
|
| a84ef318 | 05-Apr-2022 |
Warner Losh <[email protected]> |
linuxkpi: Move lkpi_pcim_iomap_devres_find to .c file
lkpi_pcim_iomap_devres_find encodes the size of struct pcim_iomap_devres in the code, so move from .h to .c to move from client driver to linuxk
linuxkpi: Move lkpi_pcim_iomap_devres_find to .c file
lkpi_pcim_iomap_devres_find encodes the size of struct pcim_iomap_devres in the code, so move from .h to .c to move from client driver to linuxkpi module.
Approved by: re@ (gjb) Sponsored by: Netflix Reviewed by: hselasky Differential Revision: https://reviews.freebsd.org/D34775
(cherry picked from commit 2bf3361d56f70d87a19f5d2bc8d258d418fb7a24) (cherry picked from commit 211621030e19553c7bd321b05694418920517736)
show more ...
|
| ebd35d1c | 05-Apr-2022 |
Warner Losh <[email protected]> |
linuxkpi: Move pci_alloc_irq_vectors to .c file
pci_alloc_irq_vectors encodes the size of struct msix_entry into its code. Move from .h to .c to move this knowledge from client modules to linuxkpi m
linuxkpi: Move pci_alloc_irq_vectors to .c file
pci_alloc_irq_vectors encodes the size of struct msix_entry into its code. Move from .h to .c to move this knowledge from client modules to linuxkpi module.
Approved by: re@ (gjb) Sponsored by: Netflix Reviewed by: hselasky Differential Revision: https://reviews.freebsd.org/D34774
(cherry picked from commit 36b5c440028b44b22cfc0596125f575ca513656f) (cherry picked from commit bc01b383945ca4f327ddb5cc940dcbafa3aaff7c)
show more ...
|
| 20f0a3ac | 05-Apr-2022 |
Warner Losh <[email protected]> |
linuxkpi: Move pci_request_region and _lkpi_pci_iomap into .c
Both pci_request_region and _lkpi_pci_iomap encode the size of struct pci_mmio_region into their code. Move from .h to .c files to move
linuxkpi: Move pci_request_region and _lkpi_pci_iomap into .c
Both pci_request_region and _lkpi_pci_iomap encode the size of struct pci_mmio_region into their code. Move from .h to .c files to move that knowledge from the client drivers into the linuxkpi module.
Approved by: re@ (gjb) Sponsored by: Netflix Reviewed by: hselasky Differential Revision: https://reviews.freebsd.org/D34773
(cherry picked from commit 1cdb25340f8ee5dd145b0dc370cbab1bd7bdca65) (cherry picked from commit 4859994c42950600b57e9d2259bd027562eefbe3)
show more ...
|
| 43b32959 | 05-Apr-2022 |
Warner Losh <[email protected]> |
linuxkpi: Move lkpi_pci_devres_get_alloc into .c file
lkpi_pci_devres_get_alloc encodes the struct pci_devres into its code. Move from .h file to .c file to move this knowledge into linuxkpi module.
linuxkpi: Move lkpi_pci_devres_get_alloc into .c file
lkpi_pci_devres_get_alloc encodes the struct pci_devres into its code. Move from .h file to .c file to move this knowledge into linuxkpi module.
Approved by: re@ (gjb) Sponsored by: Netflix Reviewed by: hselasky, emaste Differential Revision: https://reviews.freebsd.org/D34772
(cherry picked from commit 3ea682e21eed92f31dcfb8a34409580d36c452f7) (cherry picked from commit 2cd55de380d3d6f02c9b40ea53a319b477268f1c)
show more ...
|
| 88543510 | 05-Apr-2022 |
Warner Losh <[email protected]> |
linuxkpi: Move cdev_alloc into .c file
Move cdev_alloc into linux_compat.c since it encodes the size of struct linux_cdev into the client modules otherwise.
Approved by: re@ (gjb) Sponsored by: N
linuxkpi: Move cdev_alloc into .c file
Move cdev_alloc into linux_compat.c since it encodes the size of struct linux_cdev into the client modules otherwise.
Approved by: re@ (gjb) Sponsored by: Netflix Reviewed by: hselasky, emaste Differential Revision: https://reviews.freebsd.org/D34771
(cherry picked from commit aca0bcbca344b39f2a448e8c1c0d80bac8c0d6de) (cherry picked from commit d1f93d6721a6c51c0cb49078ad5c5d535a383964)
show more ...
|
| 169aa349 | 05-Apr-2022 |
Warner Losh <[email protected]> |
linuxkpi: Move class_create to .c file
class_create encodes the size of struct class into the generated code. Move from .h file to .c file to move this knowledge from the client modules that call th
linuxkpi: Move class_create to .c file
class_create encodes the size of struct class into the generated code. Move from .h file to .c file to move this knowledge from the client modules that call this into the linuxkpi module.
Approved by: re@ (gjb) Sponsored by: Netflix Reviewed by: hselasky, emaste Differential Revision: https://reviews.freebsd.org/D34769
(cherry picked from commit 1341ac9f9c111bba4e1ca046c479f32f2d4989c0) (cherry picked from commit 98d2b4a158f15d6d971a88315c5c5987036f89a3)
show more ...
|
| f6f168a1 | 05-Apr-2022 |
Warner Losh <[email protected]> |
linuxkpi: Move device_create_groups_vargs to linux_compat.c
device_create_groups_vargs encodes the size of struct device. Move definition from .h to .c to move this size into the linuxkpi module rat
linuxkpi: Move device_create_groups_vargs to linux_compat.c
device_create_groups_vargs encodes the size of struct device. Move definition from .h to .c to move this size into the linuxkpi module rather than encoding it in all client driver modules.
Approved by: re@ (gjb) Sponsored by: Netflix Reviewed by: hselasky, emaste Differential Revision: https://reviews.freebsd.org/D34768
(cherry picked from commit 702b6875035921252d0f2b72171c7662f28766fb) (cherry picked from commit 417f1c81491ae26643ea7e3f3fc5c08b8e8944a9)
show more ...
|
| d3113190 | 05-Apr-2022 |
Warner Losh <[email protected]> |
linuxkpi: move kobject_create to .c file
kobject_create knows the size of struct kobject. Move it to linux_compat.c so this knowledge is confined to the loadable module and not the clients.
Approve
linuxkpi: move kobject_create to .c file
kobject_create knows the size of struct kobject. Move it to linux_compat.c so this knowledge is confined to the loadable module and not the clients.
Approved by: re@ (gjb) Sponsored by: Netflix Reviewed by: hselasky, emaste Differential Revision: https://reviews.freebsd.org/D34767
(cherry picked from commit 36929b55849c8f553a744d6e4fbc8b1a5ff73f66) (cherry picked from commit 2f3d11894be6fb727be77184d232de24bf5551ba)
show more ...
|
| 871bfac8 | 01-Apr-2022 |
Bjoern A. Zeeb <[email protected]> |
LinuxKPI: 802.11: fix RSSI (and NF)
As in 4a22cd6c4e5f4fc4a38aa7400742d4005c5ae3de nf and rss should be signed and not unsigned. Change the types in the header and while here change a magic number
LinuxKPI: 802.11: fix RSSI (and NF)
As in 4a22cd6c4e5f4fc4a38aa7400742d4005c5ae3de nf and rss should be signed and not unsigned. Change the types in the header and while here change a magic number to a define as done elsewhere (value does not change).
When calculating c_rssi we need to make it relative so subtract nf. And while here improve the debug output.
This will hopefully fix ifconfig wlanN list scan S:N output which tools use to chose a BSSID and help net80211 internal calculations.
Sponsored by: The FreeBSD Foundation Approved by: re (gjb)
(cherry picked from commit 60970a328e280b25b05f1d9a9de1ef91af573c4a) (cherry picked from commit 7b9d8e33bc4ee0b8cc22ab28a1f09a062e103bd5)
show more ...
|
| ecb69114 | 22-Mar-2022 |
Bjoern A. Zeeb <[email protected]> |
LinuxKPI: 802.11: various updates for iwlwifi stability and upcoming rtw
Various updates to the internals of the LinuxKPI 802.11 implementation. Most notably improving state machine handling for de-
LinuxKPI: 802.11: various updates for iwlwifi stability and upcoming rtw
Various updates to the internals of the LinuxKPI 802.11 implementation. Most notably improving state machine handling for de-assoc/de-auth and always creating a new station as net80211 does and mac80211 seems to do. This avoids firmware crashes for iwlwifi and often panics and lead to more stability. Some other secondary changes are in order to support upcoming drivers so that we could possibly provide them out-of-tree for 13.1.
- implement ieee80211_beacon_loss()
Sponsored by: The FreeBSD Foundation
(cherry picked from commit bb81db90f7e00f56df9ea14132a54ee983e7177f) (cherry picked from commit 24c2117bafdba3c6998ddd407d643e142c5deda5)
- factor out lkpi_lsta_alloc() from lkpi_ic_node_alloc()
Sponsored by: The FreeBSD Foundation
(cherry picked from commit 4f61ef8b78b25761b1b859ce39213f92fcbb24ce) (cherry picked from commit 34f8e38ea7a5fccdf7f5de2cdcfabbdf68825480)
- factor out dtim/tsf updates
Sponsored by: The FreeBSD Foundation
(cherry picked from commit fa8f007de913623c066bf8f09213f92ee8cbca3a) (cherry picked from commit bc472e0a3ef06cb8eb309b00e7fbdae64a21626a)
- rework sta state machine compatibility
Sponsored by: The FreeBSD Foundation
(cherry picked from commit d9f59799fc3e7940c47aa674c25994e640eae45e) (cherry picked from commit 67674c1cb11512f09873c6d8e463af31548ef87f) (cherry picked from commit 471a438a007eff18df3d0bd9dd8849faa9f2d6ff)
- improve lkpi_80211_mo_sta_state() for non (*sta_state)
Sponsored by: The FreeBSD Foundation
(cherry picked from commit 878fb1e5754cc5bfbec57bc24859b07936f82a41) (cherry picked from commit eb580265974013be43fa17d37e22124174a7ef86)
- use cfg80211_chandef_create()
Sponsored by: The FreeBSD Foundation
(cherry picked from commit 4a07abdeb8ce5271996d85f648832e3d7bc741a7) (cherry picked from commit 4836b8ac0ed3a3b155a7fb5f2322221f48c81687)
- make lkpi_ic_set_channel() unconditional
Sponsored by: The FreeBSD Foundation
(cherry picked from commit b2cf3c2125bf6f34cb01296e7eda93f73bc4b715) (cherry picked from commit beaed0d4b5d0f901f78fc196f4b86d426a589792)
- check IEEE80211_FEXT_SCAN_OFFLOAD on vap
Sponsored by: The FreeBSD Foundation
(cherry picked from commit 768dd32a164b35fb2f66fc8a0250cee84c79471e) (cherry picked from commit 39bc4b2949e2ac32ad211aa6f1859559e21c7eb2)
- remove special handling for (*ic_scan_curchan)
Sponsored by: The FreeBSD Foundation
(cherry picked from commit 321735f451d1eaa710a768d9e35ff87acb089d35) (cherry picked from commit 5f88604cf7d9df1edbc662c4278e01476534f3ef)
- improve hw_scan fallback to sw_scan
Sponsored by: The FreeBSD Foundation
(cherry picked from commit 196cfd0b2eb640a63d007a7e9c3a74e4256255f3) (cherry picked from commit a1272e7d9621f95ca53f1bdef5ed78be12cac277)
- 802.11: cleanup debugging
Sponsored by: The FreeBSD Foundation
(cherry picked from commit 9d9ba2b79b3196935431879efd9094eb9bfedd95) (cherry picked from commit e269958566ff0df8d479996507636ed14ff6078a)
Approved by: re (gjb)
show more ...
|
| fef73ef9 | 23-Mar-2022 |
Bjoern A. Zeeb <[email protected]> |
LinuxKPI: skbuff: fix skb_queue_splice_init()
In skb_queue_splice_init() we set a next value and then used that new value to further update the remaining linking rather than the original value. Int
LinuxKPI: skbuff: fix skb_queue_splice_init()
In skb_queue_splice_init() we set a next value and then used that new value to further update the remaining linking rather than the original value. Introduce another temporary variable 'n' to hold the original value and use that. While here rename q and h to from and to as otherwise it was too confusing to read.
Also initialize skb->prev and skb->next to point to skb itself if for nothing else at least to aid debugging.
Approved by: re (gjb) Reported by: phk (panic in iwl_txq_reclaim) Sponsored by: The FreeBSD Foundation
(cherry picked from commit 6a8973c3324c0c6c270ae4ad371e50c0ec5761da) (cherry picked from commit 32d1d7fee61328e65ae944836d1027335ccb979c)
show more ...
|
| 63ec5947 | 24-Mar-2022 |
Bjoern A. Zeeb <[email protected]> |
LinuxKPI: allow bsddriver name to be set for PCI
Allow a driver to overwrite the bsddriver name (we use for pci and for wlan parent devices). This allows us to to set .bsddriver.name in struct pci_
LinuxKPI: allow bsddriver name to be set for PCI
Allow a driver to overwrite the bsddriver name (we use for pci and for wlan parent devices). This allows us to to set .bsddriver.name in struct pci_driver passed to module_pci_driver() and with that set the BSD driver name while retaining the Linux .name one.
This is helpful for divers which have different parts depending on chipset and with that would change driver names which is highly confusing especially for configuration. One example is an upcoming rtw88 driver which would be rtw_8822be or rtw_8822ce depending on chipset.
Approved by: re (gjb) Sponsored by: The FreeBSD Foundation Reviewed by: emaste, hselasky Differential Revision: https://reviews.freebsd.org/D34653
(cherry picked from commit 81d058df6d255b7f551564f6d29a03692b51fe5a) (cherry picked from commit 00450eeab2465d6dc800680158b2cc67c1a7d9fc)
show more ...
|
| a85cf688 | 16-Feb-2022 |
Bjoern A. Zeeb <[email protected]> |
LinuxKPI: pci: implement pci_upstream_bridge()
Allow drivers to query the "upstream PCI bridge". Currently we point back to ourselves on pdev->bus->self rather than to the parent PCI bridge. We keep
LinuxKPI: pci: implement pci_upstream_bridge()
Allow drivers to query the "upstream PCI bridge". Currently we point back to ourselves on pdev->bus->self rather than to the parent PCI bridge. We keep this as status-quo with an extra comment and only on-demand allocate a pci_dev for the parent bridge if we are asked for in pci_upstream_bridge(). When releasing the pci_dev we check if pdev->bus->self has changed and call pci_dev_put() to release the reference count on the parent bridge as well.
This code moves pci_is_root_bus() higher up in pci.h but no functional change there.
Approved by: re (gjb) Sponsored by: The FreeBSD Foundation Reviewed by: hselasky, (jhb some earlier) Thanks to: wulf for handling drm-kmod Differential Revision: https://reviews.freebsd.org/D34305
(cherry picked from commit b3b836251f9fefa817d158784189f6d336917f7a) (cherry picked from commit 50136233846e59eeb53c95498fdd4f3e1acf0a16)
show more ...
|
| 6bbd9be6 | 18-Feb-2022 |
Bjoern A. Zeeb <[email protected]> |
LinuxKPI: USB change successful probe result to BUS_PROBE_DEFAULT
Rather than returning 0 (which is BUS_PROBE_SPECIFIC) return BUS_PROBE_DEFAULT to give other drivers a possible chance too to attach
LinuxKPI: USB change successful probe result to BUS_PROBE_DEFAULT
Rather than returning 0 (which is BUS_PROBE_SPECIFIC) return BUS_PROBE_DEFAULT to give other drivers a possible chance too to attach.
Reported by: jhb Reviewed by: hselasky, jhb, imp Differential Revision: https://reviews.freebsd.org/D34317
(cherry picked from commit 810ca5629aae1c525f29fae5498a64b596736094)
show more ...
|
| 999377a6 | 17-Feb-2022 |
Bjoern A. Zeeb <[email protected]> |
LinuxKPI: 802.11 simplify beacon checks in rx path
In linuxkpi_ieee80211_rx() check if the frame is a beacon once upfront and use the result for enhanced debugging and further checks. This was done
LinuxKPI: 802.11 simplify beacon checks in rx path
In linuxkpi_ieee80211_rx() check if the frame is a beacon once upfront and use the result for enhanced debugging and further checks. This was done intially for rx_status->device_timestamp debugging.
Sponsored by: The FreeBSD Foundation
(cherry picked from commit c0cadd99d1e36ffe0994f8b30df2939f1d3d0fee)
show more ...
|
| ddcb65c5 | 01-Oct-2021 |
Bjoern A. Zeeb <[email protected]> |
LinuxKPI: implement dma_sync_single_for_*, apply to (un)map single/sg
Implement dma_sync_single_for_{cpu,device} translating the Linux DMA_ flags to BUS_DMASYNC_ combinations. Make map_single/unmap
LinuxKPI: implement dma_sync_single_for_*, apply to (un)map single/sg
Implement dma_sync_single_for_{cpu,device} translating the Linux DMA_ flags to BUS_DMASYNC_ combinations. Make map_single/unmap_single* functions call the respective sync function. Apply the same logic to the scatter-gather list map/unmap functions.
Sponsored by: The FreeBSD Foundation Reviewed by: hselasky Differential Revision: https://reviews.freebsd.org/D32255
(cherry picked from commit 95edb10b47fc1a919cd1687aaf16be9e14456c89)
show more ...
|
| d21079b4 | 16-Feb-2022 |
Bjoern A. Zeeb <[email protected]> |
LinuxKPI: 802.11: disable ic_headroom for the moment
There is a problem with some drivers, such as rtw88, asking for more headroom than we currently can handle throughout the stack (we have other le
LinuxKPI: 802.11: disable ic_headroom for the moment
There is a problem with some drivers, such as rtw88, asking for more headroom than we currently can handle throughout the stack (we have other legacy wireless driver in the tree with similar problems). This may trigger an assertion in the TCP syncache where we are checking for a reply to fit in MHLEN. While for the moment we still copy data from mbufs to skbs, we can simply disable the extra headroom request in ic_headroom and deal with it ourselves (which we already did anyway). Leave a link to the thread on freebsd-transport detailing more of the problem so we can find it again and solve it here or there.
(cherry picked from commit 3d09d310d9981dde1d6e51fed6ecf9576480b9f7)
show more ...
|
| 266cae80 | 17-Feb-2022 |
Bjoern A. Zeeb <[email protected]> |
LinuxKPI: 802.11 advertise full offload scanning based on hw_scan only
We disabled hw_scan for drivers not advertising SINGLE_SCAN_ON_ALL_BANDS. Do not depend on this hw flag to set IEEE80211_FEXT_S
LinuxKPI: 802.11 advertise full offload scanning based on hw_scan only
We disabled hw_scan for drivers not advertising SINGLE_SCAN_ON_ALL_BANDS. Do not depend on this hw flag to set IEEE80211_FEXT_SCAN_OFFLOAD for net80211 as otherwise scanning will never work. Long-term we probably want to re-think how we do/integrate hw_scan better in net80211.
Sponsored by: The FreeBSD Foundation
(cherry picked from commit cc4e78d51351d6362b0536e326280c1e230648d5)
show more ...
|