PPP, remove useless ppp_init function

Simon says:

ppp_init() does not seem to be used. The only thing it does is calling
magic_init(), which is not required because it its called again later
from ppp_input().

Also, the time from startup is rather constant, so calling sys_jiffies()
from ppp_init() does not create a random number.
This commit is contained in:
Sylvain Rochet 2016-04-21 23:25:48 +02:00
parent 54f7cae12c
commit 15fbfb7363
3 changed files with 0 additions and 23 deletions

View File

@ -59,7 +59,6 @@
#include "lwip/nd6.h" #include "lwip/nd6.h"
#include "lwip/mld6.h" #include "lwip/mld6.h"
#include "lwip/api.h" #include "lwip/api.h"
#include "netif/ppp/ppp_impl.h"
/* Compile-time sanity checks for configuration errors. /* Compile-time sanity checks for configuration errors.
* These can be done independently of LWIP_DEBUG, without penalty. * These can be done independently of LWIP_DEBUG, without penalty.
@ -345,9 +344,6 @@ lwip_init(void)
#if LWIP_DNS #if LWIP_DNS
dns_init(); dns_init();
#endif /* LWIP_DNS */ #endif /* LWIP_DNS */
#if PPP_SUPPORT
ppp_init();
#endif
#if LWIP_TIMERS #if LWIP_TIMERS
sys_timeouts_init(); sys_timeouts_init();

View File

@ -378,13 +378,6 @@ struct pppd_stats {
* PPP private functions * PPP private functions
*/ */
/*
* Functions called from lwIP core.
*/
/* initialize the PPP subsystem */
int ppp_init(void);
/* /*
* Functions called from PPP link protocols. * Functions called from PPP link protocols.

View File

@ -561,18 +561,6 @@ err:
/*** PRIVATE FUNCTION DEFINITIONS ***/ /*** PRIVATE FUNCTION DEFINITIONS ***/
/************************************/ /************************************/
/* Initialize the PPP subsystem. */
int ppp_init(void) {
/*
* Initialize magic number generator now so that protocols may
* use magic numbers in initialization.
*/
magic_init();
return 0;
}
/* /*
* Create a new PPP control block. * Create a new PPP control block.
* *