Skip to content

Commit

Permalink
Remove obsolete config structs
Browse files Browse the repository at this point in the history
This PR removes the xNetworkAddressing and xDefaultAddressing structs as they appear to be obsolete.
  • Loading branch information
rawalexe authored Sep 9, 2023
2 parents a91c311 + 0ebf0c2 commit b3289a7
Show file tree
Hide file tree
Showing 4 changed files with 0 additions and 25 deletions.
3 changes: 0 additions & 3 deletions source/FreeRTOS_DHCP.c
Original file line number Diff line number Diff line change
Expand Up @@ -56,9 +56,6 @@

#include "FreeRTOS_Routing.h"

/* The following define is temporary and serves to make the /single source
* code more similar to the /multi version. */

#define EP_DHCPData pxEndPoint->xDHCPData /**< Temporary define to make /single source similar to /multi version. */
#define EP_IPv4_SETTINGS pxEndPoint->ipv4_settings /**< Temporary define to make /single source similar to /multi version. */

Expand Down
8 changes: 0 additions & 8 deletions source/FreeRTOS_IP.c
Original file line number Diff line number Diff line change
Expand Up @@ -185,14 +185,6 @@ uint16_t usPacketIdentifier = 0U;
* reference. */
const MACAddress_t xBroadcastMACAddress = { { 0xff, 0xff, 0xff, 0xff, 0xff, 0xff } };

/** @brief Default values for the above struct in case DHCP
* does not lead to a confirmed request. */

/* MISRA Ref 8.9.1 [File scoped variables] */
/* More details at: https://github.com/FreeRTOS/FreeRTOS-Plus-TCP/blob/main/MISRA.md#rule-89 */
/* coverity[misra_c_2012_rule_8_9_violation] */
NetworkAddressingParameters_t xDefaultAddressing = { 0, 0, 0, 0, 0 };

/** @brief Used to ensure network down events cannot be missed when they cannot be
* posted to the network event queue because the network event queue is already
* full. */
Expand Down
5 changes: 0 additions & 5 deletions source/include/FreeRTOS_DHCP.h
Original file line number Diff line number Diff line change
Expand Up @@ -103,11 +103,6 @@
#define dhcpADDRESS_TYPE_ETHERNET ( 1U ) /**< Address type: ethernet opcode. */
#define dhcpETHERNET_ADDRESS_LENGTH ( 6U ) /**< Ethernet address length opcode. */

/* The following define is temporary and serves to make the /single source
* code more similar to the /multi version. TODO */
//#define EP_DHCPData xDHCPData /**< Temporary define to make /single source similar to /multi version. */
//#define EP_IPv4_SETTINGS xNetworkAddressing /**< Temporary define to make /single source similar to /multi version. */

/** @brief If a lease time is not received, use the default of two days (48 hours in ticks).
* Can not use pdMS_TO_TICKS() as integer overflow can occur. */
#define dhcpDEFAULT_LEASE_TIME ( ( 48UL * 60UL * 60UL ) * configTICK_RATE_HZ )
Expand Down
9 changes: 0 additions & 9 deletions source/include/FreeRTOS_IP_Private.h
Original file line number Diff line number Diff line change
Expand Up @@ -339,15 +339,6 @@ typedef union xUDPPacketHeader
extern UDPPacketHeader_t xDefaultPartUDPPacketHeader;


/* Structure that stores the netmask, gateway address and DNS server addresses. */
extern NetworkAddressingParameters_t xNetworkAddressing;

/* Structure that stores the defaults for netmask, gateway address and DNS.
* These values will be copied to 'xNetworkAddressing' in case DHCP is not used,
* and also in case DHCP does not lead to a confirmed request. */
/*lint -e9003*/
extern NetworkAddressingParameters_t xDefaultAddressing; /*lint !e9003 could define variable 'xDefaultAddressing' at block scope [MISRA 2012 Rule 8.9, advisory]. */

/* True when BufferAllocation_1.c was included, false for BufferAllocation_2.c */
extern const BaseType_t xBufferAllocFixedSize;

Expand Down

0 comments on commit b3289a7

Please sign in to comment.