mirror of
https://git.savannah.nongnu.org/git/lwip.git
synced 2026-05-20 15:17:05 +08:00
PPP, using err_t return code instead of PPPERR_
Standardised PPP API to follow lwIP already used return codes. PPPERR_ are now used only on link status callback.
This commit is contained in:
@@ -44,7 +44,7 @@ struct pppapi_msg_msg {
|
||||
#if !LWIP_TCPIP_CORE_LOCKING
|
||||
sys_sem_t sem;
|
||||
#endif /* !LWIP_TCPIP_CORE_LOCKING */
|
||||
int err;
|
||||
err_t err;
|
||||
ppp_pcb *ppp;
|
||||
union {
|
||||
struct {
|
||||
@@ -133,10 +133,10 @@ ppp_pcb *pppapi_pppol2tp_create(struct netif *pppif, struct netif *netif, ip_add
|
||||
u8_t *secret, u8_t secret_len,
|
||||
ppp_link_status_cb_fn link_status_cb, void *ctx_cb);
|
||||
#endif /* PPPOL2TP_SUPPORT */
|
||||
int pppapi_open(ppp_pcb *pcb, u16_t holdoff);
|
||||
int pppapi_close(ppp_pcb *pcb);
|
||||
err_t pppapi_open(ppp_pcb *pcb, u16_t holdoff);
|
||||
err_t pppapi_close(ppp_pcb *pcb);
|
||||
void pppapi_sighup(ppp_pcb *pcb);
|
||||
int pppapi_free(ppp_pcb *pcb);
|
||||
err_t pppapi_free(ppp_pcb *pcb);
|
||||
err_t pppapi_ioctl(ppp_pcb *pcb, int cmd, void *arg);
|
||||
#if LWIP_NETIF_STATUS_CALLBACK
|
||||
void pppapi_set_netif_statuscallback(ppp_pcb *pcb, netif_status_callback_fn status_callback);
|
||||
|
||||
@@ -464,14 +464,14 @@ void ppp_set_notify_phase_callback(ppp_pcb *pcb, ppp_notify_phase_cb_fn notify_p
|
||||
* Holdoff is the time to wait (in seconds) before initiating
|
||||
* the connection.
|
||||
*/
|
||||
int ppp_open(ppp_pcb *pcb, u16_t holdoff);
|
||||
err_t ppp_open(ppp_pcb *pcb, u16_t holdoff);
|
||||
|
||||
/*
|
||||
* Initiate the end of a PPP connection.
|
||||
* Any outstanding packets in the queues are dropped.
|
||||
* Return 0 on success, an error code on failure.
|
||||
*/
|
||||
int ppp_close(ppp_pcb *pcb);
|
||||
err_t ppp_close(ppp_pcb *pcb);
|
||||
|
||||
/*
|
||||
* Indicate to the PPP stack that the line has disconnected.
|
||||
@@ -488,7 +488,7 @@ void ppp_sighup(ppp_pcb *pcb);
|
||||
*
|
||||
* Return 0 on success, an error code on failure.
|
||||
*/
|
||||
int ppp_free(ppp_pcb *pcb);
|
||||
err_t ppp_free(ppp_pcb *pcb);
|
||||
|
||||
/*
|
||||
* Get and set parameters for the given connection.
|
||||
|
||||
Reference in New Issue
Block a user