mirror of
https://github.com/FreeRTOS/FreeRTOS-Kernel.git
synced 2025-04-19 21:11:57 -04:00
Fixes to FreeRTOS+UDP trace macro parameters and placements.
This commit is contained in:
parent
888733ef79
commit
e4f495012f
|
@ -70,7 +70,7 @@ port number. */
|
|||
|
||||
/* xWaitingPacketSemaphore is not created until the socket is bound, so can be
|
||||
tested to see if bind() has been called. */
|
||||
#define socketSOCKET_IS_BOUND( pxSocket ) ( ( uint32_t ) pxSocket->xWaitingPacketSemaphore )
|
||||
#define socketSOCKET_IS_BOUND( pxSocket ) ( ( portBASE_TYPE ) pxSocket->xWaitingPacketSemaphore )
|
||||
|
||||
/* If FreeRTOS_sendto() is called on a socket that is not bound to a port
|
||||
number then, depending on the FreeRTOSIPConfig.h settings, it might be that a
|
||||
|
|
|
@ -724,7 +724,7 @@ eIPEvent_t eMessage;
|
|||
/* This time can be used to send more than one type of message to the IP
|
||||
task. The message ID is stored in the ID of the timer. The strange
|
||||
casting is to avoid compiler warnings. */
|
||||
eMessage = ( eIPEvent_t ) ( ( int ) pvTimerGetTimerID( xTimer ) );
|
||||
eMessage = ( eIPEvent_t ) ( ( portBASE_TYPE ) pvTimerGetTimerID( xTimer ) );
|
||||
|
||||
prvSendEventToIPTask( eMessage );
|
||||
}
|
||||
|
@ -1298,7 +1298,7 @@ xARPPacket_t *pxARPPacket;
|
|||
|
||||
pxNetworkBuffer->xDataLength = sizeof( xARPPacket_t );
|
||||
|
||||
iptraceCREATING_ARP_REQUEST( ulIPAddress );
|
||||
iptraceCREATING_ARP_REQUEST( pxNetworkBuffer->ulIPAddress );
|
||||
}
|
||||
/*-----------------------------------------------------------*/
|
||||
|
||||
|
@ -1660,11 +1660,11 @@ uint16_t usLength, usReturn;
|
|||
xICMPHeader_t *pxICMPHeader;
|
||||
xIPHeader_t *pxIPHeader;
|
||||
|
||||
iptraceSENDING_PING_REPLY( pxIPHeader->ulSourceIPAddress );
|
||||
|
||||
pxICMPHeader = &( pxICMPPacket->xICMPHeader );
|
||||
pxIPHeader = &( pxICMPPacket->xIPHeader );
|
||||
|
||||
iptraceSENDING_PING_REPLY( pxIPHeader->ulSourceIPAddress );
|
||||
|
||||
/* The checksum can be checked here - but a ping reply should be
|
||||
returned even if the checksum is incorrect so the other end can
|
||||
tell that the ping was received - even if the ping reply contains
|
||||
|
|
|
@ -107,10 +107,10 @@ struct freertos_sockaddr
|
|||
#if ipconfigBYTE_ORDER == FREERTOS_LITTLE_ENDIAN
|
||||
|
||||
#define FreeRTOS_inet_addr_quick( ucOctet0, ucOctet1, ucOctet2, ucOctet3 ) \
|
||||
( ( ( uint32_t ) ( ucOctet3 ) ) << 24UL ) | \
|
||||
( ( ( uint32_t ) ( ucOctet2 ) ) << 16UL ) | \
|
||||
( ( ( uint32_t ) ( ucOctet1 ) ) << 8UL ) | \
|
||||
( ( uint32_t ) ( ucOctet0 ) )
|
||||
( ( ( ( uint32_t ) ( ucOctet3 ) ) << 24UL ) | \
|
||||
( ( ( uint32_t ) ( ucOctet2 ) ) << 16UL ) | \
|
||||
( ( ( uint32_t ) ( ucOctet1 ) ) << 8UL ) | \
|
||||
( ( uint32_t ) ( ucOctet0 ) ) )
|
||||
|
||||
#define FreeRTOS_inet_ntoa( ulIPAddress, pucBuffer ) \
|
||||
sprintf( ( char * ) ( pucBuffer ), "%d.%d.%d.%d", \
|
||||
|
@ -122,17 +122,17 @@ struct freertos_sockaddr
|
|||
#else /* ipconfigBYTE_ORDER */
|
||||
|
||||
#define FreeRTOS_inet_addr_quick( ucOctet0, ucOctet1, ucOctet2, ucOctet3 ) \
|
||||
( ( ( uint32_t ) ( ucOctet0 ) ) << 24UL ) | \
|
||||
( ( ( uint32_t ) ( ucOctet1 ) ) << 16UL ) | \
|
||||
( ( ( uint32_t ) ( ucOctet2 ) ) << 8UL ) | \
|
||||
( ( uint32_t ) ( ucOctet3 ) )
|
||||
( ( ( ( uint32_t ) ( ucOctet0 ) ) << 24UL ) | \
|
||||
( ( ( uint32_t ) ( ucOctet1 ) ) << 16UL ) | \
|
||||
( ( ( uint32_t ) ( ucOctet2 ) ) << 8UL ) | \
|
||||
( ( uint32_t ) ( ucOctet3 ) ) )
|
||||
|
||||
#define FreeRTOS_inet_ntoa( ulIPAddress, pucBuffer ) \
|
||||
sprintf( ( char * ) ( pucBuffer ), "%d.%d.%d.%d", \
|
||||
( ( ( ulIPAddress ) >> 24UL ) & 0xffUL ) ), \
|
||||
( ( ( ulIPAddress ) >> 24UL ) & 0xffUL ), \
|
||||
( ( ( ulIPAddress ) >> 16UL ) & 0xffUL ), \
|
||||
( ( ( ulIPAddress ) >> 8UL ) & 0xffUL ), \
|
||||
( ( ulIPAddress ) & 0xffUL )
|
||||
( ( ulIPAddress ) & 0xffUL ) )
|
||||
|
||||
#endif /* ipconfigBYTE_ORDER */
|
||||
|
||||
|
|
Loading…
Reference in a new issue