mirror of
https://github.com/lwip-tcpip/lwip.git
synced 2024-11-05 08:28:32 +00:00
PPP, PPPoS, disable TCPIP API if PPP_INPROC_MULTITHREADED is true
If PPP_INPROC_MULTITHREADED is true, then user does not what to use the TCPIP API. Disabling the TCPIP API helps the user to understand that PPP_INPROC_MULTITHREADED must not be used if he wish to use the TCPIP API.
This commit is contained in:
parent
121de4ef47
commit
e27ab3a24f
@ -103,10 +103,10 @@ struct pppos_pcb_s {
|
||||
ppp_pcb *pppos_create(struct netif *pppif, sio_fd_t fd,
|
||||
ppp_link_status_cb_fn link_status_cb, void *ctx_cb);
|
||||
|
||||
#if !NO_SYS
|
||||
#if !NO_SYS && !PPP_INPROC_MULTITHREADED
|
||||
/* Pass received raw characters to PPPoS to be decoded through lwIP TCPIP thread. */
|
||||
err_t pppos_input_tcpip(ppp_pcb *ppp, u_char *s, int l);
|
||||
#endif /* !NO_SYS */
|
||||
#endif /* !NO_SYS && !PPP_INPROC_MULTITHREADED */
|
||||
|
||||
/* PPP over Serial: this is the input function to be called for received data. */
|
||||
void pppos_input(ppp_pcb *ppp, u_char* data, int len);
|
||||
|
@ -70,9 +70,9 @@ static err_t pppos_netif_input(ppp_pcb *ppp, void *ctx, struct pbuf *p, u16_t pr
|
||||
#endif /* VJ_SUPPORT */
|
||||
|
||||
/* Prototypes for procedures local to this file. */
|
||||
#if !NO_SYS
|
||||
#if !NO_SYS && !PPP_INPROC_MULTITHREADED
|
||||
static err_t pppos_input_sys(struct pbuf *p, struct netif *inp);
|
||||
#endif /* !NO_SYS */
|
||||
#endif /* !NO_SYS && !PPP_INPROC_MULTITHREADED */
|
||||
#if PPP_INPROC_MULTITHREADED
|
||||
static void pppos_input_callback(void *arg);
|
||||
#endif /* PPP_INPROC_MULTITHREADED */
|
||||
@ -205,9 +205,9 @@ ppp_pcb *pppos_create(struct netif *pppif, sio_fd_t fd,
|
||||
|
||||
pppos->ppp = ppp;
|
||||
pppos->fd = fd;
|
||||
#if !NO_SYS
|
||||
#if !NO_SYS && !PPP_INPROC_MULTITHREADED
|
||||
ppp->netif->input = pppos_input_sys;
|
||||
#endif /* !NO_SYS */
|
||||
#endif /* !NO_SYS && !PPP_INPROC_MULTITHREADED */
|
||||
ppp_link_set_callbacks(ppp, &pppos_callbacks, pppos);
|
||||
return ppp;
|
||||
}
|
||||
@ -529,7 +529,7 @@ pppos_destroy(ppp_pcb *ppp, void *ctx)
|
||||
return ERR_OK;
|
||||
}
|
||||
|
||||
#if !NO_SYS
|
||||
#if !NO_SYS && !PPP_INPROC_MULTITHREADED
|
||||
/** Pass received raw characters to PPPoS to be decoded through lwIP TCPIP thread.
|
||||
*
|
||||
* @param pcb PPP descriptor index, returned by pppos_create()
|
||||
@ -567,7 +567,7 @@ static err_t pppos_input_sys(struct pbuf *p, struct netif *inp) {
|
||||
pbuf_free(p);
|
||||
return ERR_OK;
|
||||
}
|
||||
#endif /* !NO_SYS */
|
||||
#endif /* !NO_SYS && !PPP_INPROC_MULTITHREADED */
|
||||
|
||||
/** PPPoS input helper struct, must be packed since it is stored
|
||||
* to pbuf->payload, which might be unaligned. */
|
||||
|
Loading…
Reference in New Issue
Block a user