mirror of
https://github.com/lwip-tcpip/lwip.git
synced 2025-03-13 16:18:55 +00:00
PPP, CORE, disable VJ is PPP IPV4 is compiled out
VJ compression is only supported for PPP IPv4, compile out VJ support if PPP IPv4 is not compiled.
This commit is contained in:
parent
00e8988b52
commit
a1c5415f8f
@ -2061,7 +2061,7 @@
|
||||
#ifndef VJ_SUPPORT
|
||||
#define VJ_SUPPORT 1
|
||||
#endif
|
||||
#if !PPPOS_SUPPORT
|
||||
#if !PPPOS_SUPPORT || !PPP_IPV4_SUPPORT
|
||||
#undef VJ_SUPPORT
|
||||
#define VJ_SUPPORT 0 /* VJ compression is only supported for PPPoS. */
|
||||
#endif /* !PPPOS_SUPPORT */
|
||||
|
@ -330,7 +330,12 @@ struct ppp_pcb_s {
|
||||
unsigned int ipcp_is_up :1; /* have called ipcp_up() */
|
||||
unsigned int if4_up :1; /* True when the IPv4 interface is up. */
|
||||
unsigned int proxy_arp_set :1; /* Have created proxy arp entry */
|
||||
#if VJ_SUPPORT
|
||||
unsigned int vj_enabled :1; /* Flag indicating VJ compression enabled. */
|
||||
#else
|
||||
unsigned int :1; /* 1 bit of padding */
|
||||
#endif /* VJ_SUPPORT */
|
||||
#else /* PPP_IPV4_SUPPORT */
|
||||
unsigned int :4; /* 4 bit of padding */
|
||||
#endif /* PPP_IPV4_SUPPORT */
|
||||
#if PPP_IPV6_SUPPORT
|
||||
@ -341,11 +346,6 @@ struct ppp_pcb_s {
|
||||
#endif /* PPP_IPV6_SUPPORT */
|
||||
unsigned int ask_for_local :1; /* request our address from peer */
|
||||
unsigned int lcp_echo_timer_running :1; /* set if a timer is running */
|
||||
#if VJ_SUPPORT
|
||||
unsigned int vj_enabled :1; /* Flag indicating VJ compression enabled. */
|
||||
#else
|
||||
unsigned int :1; /* 1 bit of padding */
|
||||
#endif /* VJ_SUPPORT */
|
||||
unsigned int :5; /* 5 bits of padding to round out to 16 bits */
|
||||
|
||||
u32_t last_xmit; /* Time of last transmission. */
|
||||
|
@ -431,7 +431,9 @@ int sifproxyarp(ppp_pcb *pcb, u32_t his_adr);
|
||||
int cifproxyarp(ppp_pcb *pcb, u32_t his_adr);
|
||||
int sdns(ppp_pcb *pcb, u32_t ns1, u32_t ns2);
|
||||
int cdns(ppp_pcb *pcb, u32_t ns1, u32_t ns2);
|
||||
#if VJ_SUPPORT
|
||||
int sifvjcomp(ppp_pcb *pcb, int vjcomp, int cidcomp, int maxcid);
|
||||
#endif /* VJ_SUPPORT */
|
||||
int sifup(ppp_pcb *pcb);
|
||||
int sifdown (ppp_pcb *pcb);
|
||||
#endif /* PPP_IPV4_SUPPORT */
|
||||
|
@ -1852,8 +1852,10 @@ static void ipcp_up(fsm *f) {
|
||||
}
|
||||
#endif /* Unused */
|
||||
|
||||
#if VJ_SUPPORT
|
||||
/* set tcp compression */
|
||||
sifvjcomp(pcb, ho->neg_vj, ho->cflag, ho->maxslotindex);
|
||||
#endif /* VJ_SUPPORT */
|
||||
|
||||
#if DEMAND_SUPPORT
|
||||
/*
|
||||
@ -2012,7 +2014,9 @@ static void ipcp_down(fsm *f) {
|
||||
pcb->ipcp_is_up = 0;
|
||||
np_down(pcb, PPP_IP);
|
||||
}
|
||||
#if VJ_SUPPORT
|
||||
sifvjcomp(pcb, 0, 0, 0);
|
||||
#endif /* VJ_SUPPORT */
|
||||
|
||||
#if PPP_STATS_SUPPORT
|
||||
print_link_stats(); /* _after_ running the notifiers and ip_down_hook(),
|
||||
|
@ -957,6 +957,7 @@ int cdns(ppp_pcb *pcb, u32_t ns1, u32_t ns2) {
|
||||
return 1;
|
||||
}
|
||||
|
||||
#if VJ_SUPPORT
|
||||
/********************************************************************
|
||||
*
|
||||
* sifvjcomp - config tcp header compression
|
||||
@ -967,6 +968,7 @@ int sifvjcomp(ppp_pcb *pcb, int vjcomp, int cidcomp, int maxcid) {
|
||||
}
|
||||
return 0;
|
||||
}
|
||||
#endif /* VJ_SUPPORT */
|
||||
|
||||
/*
|
||||
* sifup - Config the interface up and enable IP packets to pass.
|
||||
|
Loading…
x
Reference in New Issue
Block a user