Skip to content

Commit

Permalink
Merge branch 'main' into dev-frame-filter
Browse files Browse the repository at this point in the history
  • Loading branch information
tony-josi-aws committed Mar 13, 2024
2 parents e1fbeaf + 350dfea commit ddd8eb6
Show file tree
Hide file tree
Showing 85 changed files with 1,027 additions and 976 deletions.
3 changes: 0 additions & 3 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -217,9 +217,6 @@ add_compile_options(
$<$<COMPILE_LANG_AND_ID:C,Clang>:-Wno-extra-semi-stmt>
$<$<COMPILE_LANG_AND_ID:C,Clang>:-Wno-missing-noreturn>
$<$<COMPILE_LANG_AND_ID:C,Clang>:-Wno-cast-align>

# Suppressions required to build clean with GCC.
$<$<COMPILE_LANG_AND_ID:C,GNU>:-Wno-declaration-after-statement>
)

########################################################################
Expand Down
8 changes: 4 additions & 4 deletions GettingStarted.md
Original file line number Diff line number Diff line change
@@ -1,16 +1,16 @@
Moving to 4.0.0 from 3.x.x:
Moving to version 4.0.0 and later from 3.x.x:
--------------------------------

Version 4.0.0 adds new files to support IPv6 functionality, breaking each file into logically separated IPv4 and IPv6 files. The folder structure of FreeRTOS-Plus-TCP remains unchanged. Build separation is added to make the library modular, enabling users to compile and create a low-footprint binary with only the required functionalities. For more details on supported build combinations, see [History.txt](https://github.com/FreeRTOS/FreeRTOS-Plus-TCP/blob/main/History.txt) .
Version 4.0.0 and later adds new files to support IPv6 functionality, breaking each file into logically separated IPv4 and IPv6 files. The folder structure of FreeRTOS-Plus-TCP remains unchanged. Build separation is added to make the library modular, enabling users to compile and create a low-footprint binary with only the required functionalities. For more details on supported build combinations, see [History.txt](https://github.com/FreeRTOS/FreeRTOS-Plus-TCP/blob/main/History.txt) .

Some of the APIs have changed which is illustrated in the section below. However, there is a backward compatibility mode provided as well.

Backward Compatibility Mode:
---------------------------
If you are moving your code from V3.x.x to V4.0.0, then set the "ipconfigIPv4_BACKWARD_COMPATIBLE" macro to 1 in “FreeRTOSIPConfigDefaults.h” to run the code in backward compatible mode.
If you are moving your code from version 3.x.x to version 4.0.0 and later, then set the "ipconfigIPv4_BACKWARD_COMPATIBLE" macro to 1 in “FreeRTOSIPConfigDefaults.h” to run the code in backward compatible mode.
The "Existing API's" defined in all the API changes below work only when the backward compatibility mode is enabled.

API changes in 4.0.0:
API changes in version 4.0.0 and later:
----------------------

The changes mentioned below uses ipconfigIPv4_BACKWARD_COMPATIBLE flag to differentiate between old API and new API.
Expand Down
100 changes: 100 additions & 0 deletions History.txt
Original file line number Diff line number Diff line change
@@ -1,5 +1,105 @@
Documentation and download available at https://www.FreeRTOS.org/

Changes between FreeRTOS-plus-TCP V4.1.0 and V4.0.0 released March 8, 2024
+ Add new Network Interface for Corstone-300 FVP (MPS3_AN552).
We thank @urutva for their contribution.
+ Add new loopback Network Interface.
We thank @htibosch for their contribution.
+ Add FreeRTOS_get_tx_base() API to return the TCP Tx stream buffer pointer.
We thank @htibosch for their contribution.
+ Add FreeRTOS_InterfaceEPInSameSubnet_IPv6 API to find an IPv6 endpoint on
the given interface that is in the same subnet as the given IP address.
+ Add checks to prevent potential integer overflow in the buffer
allocation APIs.
+ Improve performance by removing redundant critical sections.
We thank @htibosch for their contribution.
+ Improve performance on 64-bit targets by correctly setting
ipBUFFER_PADDING to satisfy the architecture’s alignment requirements.
We thank @htibosch for their contribution.
+ Improve FreeRTOS_send() API performance by not iterating more times than
necessary when trying to send data.
We thank @htibosch for their contribution.
+ Update the Neighbour Discovery cache behavior to overwrite the oldest
entry when the cache is full. We thank @evpopov for their contribution.
+ Update the FreeRTOS_get_tx_head() API to create the TCP Tx stream buffer
if it wasn't already created for the given socket.
+ FreeRTOS_GetIPType is now always available, regardless of the value of
ipconfigUSE_TCP. We thank @HTRamsey for their contribution.
+ Improve tracing support by adding more trace macros.
We thank @HTRamsey for their contribution.
+ Add support for multiple endpoints in STM32Hxx Network Interface.
Earlier it was capable of handling upto 3 endpoints only.
+ Fix potential NULL pointer dereference when a packet from a subnet other
than the endpoint's subnet is received on an endpoint that has no gateway
configured. We thank @htibosch for their contribution.
+ Fix TCP zero-copy functionality by removing incorrect NULL check for
pvBuffer parameter in the FreeRTOS_Send API.
We thank @evpopov for their contribution.
+ Fix the network buffer leak in the Neighbour Discovery (ND) code.
We thank @htibosch for their contribution.
+ ARP requests are now sent only on the endpoint with IP address in the same
subnet as the ARP request’s target address. Earlier ARP requests were sent
over all the available endpoints.
We thank @evpopov for their contribution.
+ Neighbor Solicitation (NS) responses are now correctly sent on the same
endpoint on which the Neighbor Solicitation request is received.
Earlier, it could be sent out on a wrong interface when multiple IPv6
Link Local endpoints were present on different interfaces.
We thank @evpopov for their contribution.
+ Responses to mDNS/LLMNR/NBNS requests are now sent on the the same
endpoint on which the request was received. Earlier, it could be sent out
on a wrong endpoint. We thank @evpopov for their contribution.
+ Fix size calculation in the neighbor solicitation handling code to avoid a
buffer reallocation always. We thank @evpopov for their contribution.
+ Fix FreeRTOS_getaddrinfo_a API to use the address family supplied in
xHints parameter instead of always using IPv6.
We thank @evpopov for their contribution.
+ Fix IPv4 incoming packet filtering logic to correctly filter out unicast
packets not destined to the device, when
ipconfigETHERNET_DRIVER_FILTERS_FRAME_TYPES is enabled.
We thank @evpopov for their contribution.
+ Improve error handling in STM32H7xx Network Interface.
We thank @htibosch for their contribution.
+ Update the IPv4 packet filtering logic to correctly discard bad loopback
packets originating outside of the network.
+ Ensure that the hostname string in DNS resolution code is NULL terminated,
even when the destination buffer is not large enough to hold the complete
string. We thank @bjsowa for their contribution.
+ Fix the network down and up process to correctly restart DHCP/RA timers.
We thank @bjsowa for their contribution.
+ Fix SAME70 Network Interface to correctly release Tx semaphore when the
network interface fails to transmit.
We thank @evpopov for their contribution.
+ Update NXP1060 Network Interface to handle network cable disconnection.
We thank @microcris for their contribution.
+ Update the alignment specifier in TM4C Network Interface to make it
compatible with both CCS and GCC compilers.
We thank @jonathangjertsen for their contribution.
+ Fix minimum length check for ICMP/ping packets.
We thank @htibosch for their contribution.
+ Fix received packet length calculation in the SAM Network Interface.
We thank @htibosch for their contribution.
+ Remove obsolete structs xNetworkAddressing and xDefaultAddressing.
We thank @evpopov for their contribution.
+ Fix compilation with Clang 17 and updated log output.
We thank @Mixaill for their contribution.
+ Fix compiler warnings with the -Wpedantic option.
We thank @Mixaill for their contribution.
+ Fix compiler warnings in the SAM Network Interface.
We thank @Peter-Herrmann for their contribution.
+ Streamline the usage of const in stream buffer APIs.
We thank @HTRamsey for their contribution.
+ Debug logs, printed using FreeRTOS_debug_printf, are now correctly
guarded using the macro ipconfigHAS_DEBUG_PRINTF.
We thank @microcris for their contribution.
+ Add the LIBSLIRP Network Interface to be available in the CMakelists
Network Interface selection. We thank @bjsowa for their contribution.
+ Move static assert definition to a common header file to make it available
to all the source files. Also, remove redundant macro check definitions.
We thank @HTRamsey for their contribution.
+ Remove the xCheckLoopback function. It is no longer needed as we now
have a loopback interface. We thank @htiboschfor their contribution.

Changes between FreeRTOS-plus-TCP V4.0.0 and V3.1.0 released August 10, 2023
+ Unified code for both IPv4 and IPv6 protocols.
+ Multiple Interface and Multiple Endpoint support
Expand Down
7 changes: 1 addition & 6 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,15 +1,10 @@
## Introduction

This branch contains unified IPv4 and IPv6 functionalities.
Refer to the Getting started Guide (found [here](https://github.com/FreeRTOS/FreeRTOS-Plus-TCP/blob/main/GettingStarted.md)) for more details.

## FreeRTOS-Plus-TCP Library
FreeRTOS-Plus-TCP is a lightweight TCP/IP stack for FreeRTOS. It provides a familiar Berkeley sockets interface, making it as simple to use and learn as possible. FreeRTOS-Plus-TCP's features and RAM footprint are fully scalable, making FreeRTOS-Plus-TCP equally applicable to smaller lower throughput microcontrollers as well as larger higher throughput microprocessors.

This library has undergone static code analysis and checks for compliance with the [MISRA coding standard](https://www.misra.org.uk/). Any deviations from the MISRA C:2012 guidelines are documented under [MISRA Deviations](https://github.com/FreeRTOS/FreeRTOS-Plus-TCP/blob/main/MISRA.md). The library is validated for memory safety and data structure invariance through the [CBMC automated reasoning tool](https://www.cprover.org/cbmc/) for the functions that parse data originating from the network. The library is also protocol tested using Maxwell protocol tester for both IPv4 and IPv6.

## Getting started
The easiest way to use the 4.0.0 version of FreeRTOS-Plus-TCP is to refer the Getting started Guide (found [here](https://github.com/FreeRTOS/FreeRTOS-Plus-TCP/blob/main/GettingStarted.md))
The easiest way to use version 4.0.0 and later of FreeRTOS-Plus-TCP is to refer the Getting started Guide (found [here](https://github.com/FreeRTOS/FreeRTOS-Plus-TCP/blob/main/GettingStarted.md))
Another way is to start with the pre-configured demo application project (found in [this directory](https://github.com/FreeRTOS/FreeRTOS/tree/main/FreeRTOS-Plus/Demo/FreeRTOS_Plus_TCP_Minimal_Windows_Simulator)). That way you will have the correct FreeRTOS source files included, and the correct include paths configured. Once a demo application is building and executing you can remove the demo application files, and start to add in your own application source files. See the [FreeRTOS Kernel Quick Start Guide](https://www.freertos.org/FreeRTOS-quick-start-guide.html) for detailed instructions and other useful links.

Additionally, for FreeRTOS-Plus-TCP source code organization refer to the [Documentation](http://www.FreeRTOS.org/FreeRTOS-Plus/FreeRTOS_Plus_TCP/TCP_Networking_Tutorial.html), and [API Reference](https://freertos.org/FreeRTOS-Plus/FreeRTOS_Plus_TCP/FreeRTOS_TCP_API_Functions.html).
Expand Down
2 changes: 1 addition & 1 deletion docs/doxygen/config.doxyfile
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@ PROJECT_NAME = FreeRTOS-Plus-TCP
# could be handy for archiving the generated documentation or if some version
# control system is used.

PROJECT_NUMBER = V4.0.0
PROJECT_NUMBER = V4.1.0

# Using the PROJECT_BRIEF tag one can provide an optional one line description
# for a project that appears at the top of each page and should give viewer a
Expand Down
4 changes: 2 additions & 2 deletions manifest.yml
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
name: "FreeRTOS-Plus-TCP"
version: "V4.0.0"
version: "V4.1.0"
description:
"Thread safe FreeRTOS TCP/IP stack working on top of the FreeRTOS-Kernel to
implement the TCP/IP protocol. Suitable for microcontrollers."
license: "MIT"
dependencies:
- name: "FreeRTOS-Kernel"
version: "V10.6.1"
version: "V11.0.1"
license: "MIT"
repository:
type: "git"
Expand Down
Loading

0 comments on commit ddd8eb6

Please sign in to comment.