1
0
mirror of https://github.com/RIOT-OS/RIOT.git synced 2024-12-29 04:50:03 +01:00
RIOT/sys/include/net/sock
Martine S. Lenders a7d468988d
sock: amend with zero-copy receive functions
This change amends the `sock` API by a set of functions to `sock` that
allow provisioning of stack-internal buffers to the caller on receive.

This allows to cover two use-cases

1. Zero-copy systems: if the stacks supported the buffer space provided
   by these functions can be the same that was filled in the link-layer
2. asynchronous receive within a wrapping sock layer (e.g. `sock_dtls`
   wrapping `sock_udp`): to receive packets of the lower level protocol
   asynchronously, the wrapping implementation layer would currently
   need to allocate its own buffer space, introducing a third buffer
   space in addition to the one of the application and the network
   stack. For a wrapping layer this is undesirable.

While there are security considerations exposing stack internal memory
space to the caller, I believe they are minor, as in the end the
application developer is the person in control of the node.
2020-03-24 14:02:36 +01:00
..
async sock_async: include sock_async_ctx.h before sock-types 2020-02-24 12:33:38 +01:00
async.h sock_async: fix cyclic dependency with sock_types.h 2020-01-07 10:13:01 +01:00
dns.h sock_dns: make sock_dns_query() return the length of the address 2020-02-24 14:29:17 +01:00
dtls.h sock: amend with zero-copy receive functions 2020-03-24 14:02:36 +01:00
ip.h sock: amend with zero-copy receive functions 2020-03-24 14:02:36 +01:00
tcp.h sock: ignore -Wtypedef-redefinition for LLVM where needed 2020-01-07 10:13:02 +01:00
udp.h sock: amend with zero-copy receive functions 2020-03-24 14:02:36 +01:00
util.h net/sock/util: Move configuration macros to 'CONFIG_' namespace 2019-12-13 12:04:54 +01:00