@@ -204,14 +204,17 @@ static void hand_tx_errors( void );
204204static uint16_t prvGenerateCRC16 ( const uint8_t * pucAddress );
205205static void prvAddMulticastMACAddress ( const uint8_t * ucMacAddress );
206206
207+ /* Checks IP queue, buffers, and semaphore and logs diagnostic info if configured */
208+ static void vCheckBuffersAndQueue ( void );
209+
210+ /* return 'puc_buffer' to the pool of transmission buffers. */
211+ void returnTxBuffer ( uint8_t * puc_buffer );
212+
207213/*-----------------------------------------------------------*/
208214
209215/* A copy of PHY register 1: 'PHY_REG_01_BMSR' */
210216static BaseType_t xGMACSwitchRequired ;
211217
212- /* LLMNR multicast address. */
213- static const uint8_t llmnr_mac_address [] = { 0x01 , 0x00 , 0x5E , 0x00 , 0x00 , 0xFC };
214-
215218/* The GMAC object as defined by the ASF drivers. */
216219static gmac_device_t gs_gmac_dev ;
217220
@@ -454,8 +457,6 @@ static BaseType_t xPHY_Write( BaseType_t xAddress,
454457
455458static BaseType_t prvSAM_NetworkInterfaceInitialise ( NetworkInterface_t * pxInterface )
456459{
457- const TickType_t x5_Seconds = 5000UL ;
458-
459460 if ( xEMACTaskHandle == NULL )
460461 {
461462 prvGMACInit ( pxInterface );
@@ -673,9 +674,7 @@ static BaseType_t prvSAM_NetworkInterfaceOutput( NetworkInterface_t * pxInterfac
673674
674675static BaseType_t prvGMACInit ( NetworkInterface_t * pxInterface )
675676{
676- uint32_t ncfgr ;
677677 NetworkEndPoint_t * pxEndPoint ;
678- BaseType_t xEntry = 1 ;
679678
680679 gmac_options_t gmac_option ;
681680
@@ -1065,7 +1064,7 @@ volatile UBaseType_t uxLastMinBufferCount = 0;
10651064volatile UBaseType_t uxCurrentSemCount ;
10661065volatile UBaseType_t uxLowestSemCount ;
10671066
1068- void vCheckBuffersAndQueue ( void )
1067+ static void vCheckBuffersAndQueue ( void )
10691068{
10701069 static UBaseType_t uxCurrentCount ;
10711070
@@ -1126,14 +1125,14 @@ void vNetworkInterfaceAllocateRAMToBuffers( NetworkBufferDescriptor_t pxNetworkB
11261125static void prvEMACHandlerTask ( void * pvParameters )
11271126{
11281127 UBaseType_t uxCount ;
1129- UBaseType_t uxLowestSemCount = GMAC_TX_BUFFERS + 1 ;
1128+
1129+ uxLowestSemCount = GMAC_TX_BUFFERS + 1 ;
11301130
11311131 #if ( ipconfigZERO_COPY_TX_DRIVER != 0 )
11321132 NetworkBufferDescriptor_t * pxBuffer ;
11331133 #endif
11341134 uint8_t * pucBuffer ;
11351135 BaseType_t xResult = 0 ;
1136- uint32_t xStatus ;
11371136 const TickType_t ulMaxBlockTime = pdMS_TO_TICKS ( EMAC_MAX_BLOCK_TIME_MS );
11381137 uint32_t ulISREvents = 0U ;
11391138
0 commit comments