Skip to content

Commit f4a0005

Browse files
Add pxFillInterfaceDescriptor definition to libslirp network interface for backward compatibility (#1210)
* Add pxFillInterfaceDescriptor definition to libslirp netif for backward compatibility * Fix formatting
1 parent e3412fb commit f4a0005

File tree

1 file changed

+18
-0
lines changed

1 file changed

+18
-0
lines changed

source/portable/NetworkInterface/libslirp/MBuffNetworkInterface.c

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -77,6 +77,9 @@ extern void vMBuffNetifBackendDeInit( void * pvBackendContext );
7777

7878
static void vNetifReceiveTask( void * pvParameters );
7979

80+
extern NetworkInterface_t * pxLibslirp_FillInterfaceDescriptor( BaseType_t xEMACIndex,
81+
NetworkInterface_t * pxInterface );
82+
8083
/**
8184
* @brief Initialize the MessageBuffer backed network interface.
8285
*
@@ -381,6 +384,21 @@ BaseType_t xGetPhyLinkStatus( NetworkInterface_t * pxNetif )
381384
return xResult;
382385
}
383386

387+
388+
#if ( ipconfigIPv4_BACKWARD_COMPATIBLE == 1 )
389+
390+
391+
/* Do not call the following function directly. It is there for downward compatibility.
392+
* The function FreeRTOS_IPInit() will call it to initialice the interface and end-point
393+
* objects. See the description in FreeRTOS_Routing.h. */
394+
NetworkInterface_t * pxFillInterfaceDescriptor( BaseType_t xEMACIndex,
395+
NetworkInterface_t * pxInterface )
396+
{
397+
return pxLibslirp_FillInterfaceDescriptor( xEMACIndex, pxInterface );
398+
}
399+
400+
#endif
401+
384402
NetworkInterface_t * pxLibslirp_FillInterfaceDescriptor( BaseType_t xEMACIndex,
385403
NetworkInterface_t * pxInterface )
386404
{

0 commit comments

Comments
 (0)