-
Notifications
You must be signed in to change notification settings - Fork 2k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
sys/net/gnrc_netif: Make use of confirm send #18139
Merged
maribu
merged 2 commits into
RIOT-OS:master
from
maribu:sys/net/gnrc/netif/confirm_send
Sep 17, 2022
Merged
sys/net/gnrc_netif: Make use of confirm send #18139
maribu
merged 2 commits into
RIOT-OS:master
from
maribu:sys/net/gnrc/netif/confirm_send
Sep 17, 2022
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
maribu
added
Area: network
Area: Networking
State: WIP
State: The PR is still work-in-progress and its code is not in its final presentable form yet
Type: new feature
The issue requests / The PR implemements a new feature for RIOT
labels
May 25, 2022
maribu
requested review from
miri64,
haukepetersen,
PeterKietzmann,
cgundogan,
aabadie,
jia200x,
bergzand,
jue89,
daniel-k,
smlng,
benpicco,
fjmolinas,
DipSwitch,
vincent-d,
dylad,
keestux and
gschorcht
as code owners
May 25, 2022 13:44
github-actions
bot
added
Area: build system
Area: Build system
Area: cpu
Area: CPU/MCU ports
Area: drivers
Area: Device drivers
Area: LoRa
Area: LoRa radio support
Area: sys
Area: System
Platform: ARM
Platform: This PR/issue effects ARM-based platforms
Platform: ESP
Platform: This PR/issue effects ESP-based platforms
labels
May 25, 2022
maribu
force-pushed
the
sys/net/gnrc/netif/confirm_send
branch
from
July 22, 2022 08:10
bc18120
to
47f807f
Compare
Does the WIP label still apply? |
This could be merged if I drop the Ethernet change, as that change will break lwIP. I am currently working on the same thing for lwIP, after which driver could safely start making use of confirm_send. |
maribu
added
the
State: waiting for other PR
State: The PR requires another PR to be merged first
label
Aug 9, 2022
This was referenced Aug 9, 2022
benpicco
removed
the
State: waiting for other PR
State: The PR requires another PR to be merged first
label
Aug 18, 2022
This needs a rebase |
maribu
force-pushed
the
sys/net/gnrc/netif/confirm_send
branch
from
August 22, 2022 09:02
21d2f01
to
eb21b20
Compare
github-actions
bot
removed
Area: cpu
Area: CPU/MCU ports
Platform: ESP
Platform: This PR/issue effects ESP-based platforms
Area: build system
Area: Build system
Area: drivers
Area: Device drivers
Platform: ARM
Platform: This PR/issue effects ARM-based platforms
Area: LoRa
Area: LoRa radio support
labels
Aug 22, 2022
Ping :) |
benpicco
reviewed
Sep 14, 2022
maribu
force-pushed
the
sys/net/gnrc/netif/confirm_send
branch
from
September 15, 2022 11:02
eb21b20
to
21c0969
Compare
Please squash! |
This adds support for netdevs implementing the new API that provides `netdev_driver_t::confirm_send()`. This allows implementing netdevs in an event based non-blocking fashion, making live of driver developers a bit easier. In addition, `gnrc_tx_sync` will now throttle users of `sock_udp_send()` so that they can only send datagrams as fast as the network stack and hardware is able to send out. Finally, this lays the groundwork to fetch TX statistics (such as TX timestamps, reception of layer 2 ACKs/NACKs, etc.) from the network devices.
For Ethernet, raw netifs, and IEEE 802.15.4 netifs only release outgoing frame with legacy drivers, as gnrc_netif does so with new non-blocking API.
maribu
force-pushed
the
sys/net/gnrc/netif/confirm_send
branch
from
September 15, 2022 11:23
460a279
to
581f35e
Compare
benpicco
added
the
CI: ready for build
If set, CI server will compile all applications for all available boards for the labeled PR
label
Sep 15, 2022
benpicco
approved these changes
Sep 15, 2022
All green. If anyone wants to have another look before I hit merge, it is now or never ;) |
maribu
added
CI: ready for build
If set, CI server will compile all applications for all available boards for the labeled PR
and removed
CI: ready for build
If set, CI server will compile all applications for all available boards for the labeled PR
labels
Sep 17, 2022
Thx everyone :) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Labels
Area: network
Area: Networking
Area: sys
Area: System
CI: ready for build
If set, CI server will compile all applications for all available boards for the labeled PR
Type: new feature
The issue requests / The PR implemements a new feature for RIOT
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Contribution description
netdev_legacy_api
andnetdev_new_api
to allow optimizing for the "withconfirm_send()
" and "withoutconfirm_send()
" variant of the netdev APInetdev_new_api
translateNETDEV_EVENT_TX_COMPLETE
into ansys/event
event, so that this can be signaled from ISR. This safes a roundtrip to the ISR handler if the type of the event is known at ISR time (e.g. multiple signal pins or peripheral netdev)NETDEV_EVENT_TX_COMPLETE
event before signalling upper layers completion withgnrc_tx_sync
.Testing procedure
This needs to be tested in conjunction with a driver actually being ported to the new API. However, we cannot port drivers to the new API until both GNRC and lwIP correctly operate with the new API.
#18428 ports the STM32 Ethernet driver to the new API, so that this PR can be tested there.
Issues/PRs references
Similar to #15821 but uses the now existing sys/event infrastructure rather than thread_flags
fixes #7474