Nut/OS  5.0.5
API Reference
pppdebug.c File Reference

PPP debug helper functions. More...

#include <net/netdebug.h>
#include <sys/types.h>
#include <dev/ahdlc.h>
#include <arpa/inet.h>
#include <netinet/ppp_fsm.h>
#include <netinet/if_ppp.h>
#include <netinet/in.h>
Include dependency graph for pppdebug.c:

Functions

void NutDumpLcpOption (FILE *stream, NETBUF *nb)
void NutDumpLcp (FILE *stream, NETBUF *nb)
void NutDumpPapOption (FILE *stream, NETBUF *nb)
void NutDumpPap (FILE *stream, NETBUF *nb)
void NutDumpIpcpOption (FILE *stream, NETBUF *nb)
void NutDumpIpcp (FILE *stream, NETBUF *nb)
void NutDumpPpp (FILE *stream, NETBUF *nb)
void NutTracePPP (FILE *stream, uint8_t flags)
 Control PPP tracing.

Variables

FILE__ppp_trs
 PPP trace output stream.
uint_fast8_t __ppp_trf
 PPP trace flags.

Detailed Description

PPP debug helper functions.

 * $Id: pppdebug.c 3686 2011-12-04 14:20:38Z haraldkipp $
 * 

Function Documentation

void NutDumpLcpOption ( FILE stream,
NETBUF nb 
)

References fprintf(), fputs(), LCP_ACCOMPRESSION, LCP_ASYNCMAP, LCP_AUTHTYPE, LCP_MAGICNUMBER, LCP_MRU, LCP_PCOMPRESSION, _NETBUF::nb_ap, _NETBUF::nb_dl, ntohl, ntohs, _NBDATA::sz, XCPOPT::ul, XCPOPT::us, _NBDATA::vp, XCPOPT::xcpo_, XCPOPT::xcpo_len, and XCPOPT::xcpo_type.

Referenced by NutDumpLcp().

Here is the call graph for this function:

void NutDumpLcp ( FILE stream,
NETBUF nb 
)

References fprintf(), fputs(), fputs_P, LCP_DRQ, LCP_ERP, LCP_ERQ, LCP_PROTREJ, _NETBUF::nb_ap, _NETBUF::nb_dl, _NETBUF::nb_nw, ntohs, NutDumpLcpOption(), _NBDATA::sz, _NBDATA::vp, xcphdr::xch_code, xcphdr::xch_id, xcphdr::xch_len, XCP_CODEREJ, XCP_CONFACK, XCP_CONFNAK, XCP_CONFREJ, XCP_CONFREQ, XCP_TERMACK, and XCP_TERMREQ.

Referenced by NutDumpPpp().

Here is the call graph for this function:

void NutDumpPapOption ( FILE stream,
NETBUF nb 
)

References fprintf(), fputc(), fputs(), _NETBUF::nb_ap, _NETBUF::nb_dl, _NBDATA::sz, and _NBDATA::vp.

Referenced by NutDumpPap().

Here is the call graph for this function:

void NutDumpPap ( FILE stream,
NETBUF nb 
)

References fprintf(), fputs(), fputs_P, _NETBUF::nb_dl, _NETBUF::nb_nw, ntohs, NutDumpPapOption(), _NBDATA::sz, _NBDATA::vp, xcphdr::xch_code, xcphdr::xch_id, xcphdr::xch_len, XCP_CONFACK, XCP_CONFNAK, and XCP_CONFREQ.

Referenced by NutDumpPpp().

Here is the call graph for this function:

void NutDumpIpcpOption ( FILE stream,
NETBUF nb 
)

References fprintf(), fputs(), inet_ntoa(), IPCP_ADDR, IPCP_COMPRESSTYPE, IPCP_MS_DNS1, IPCP_MS_DNS2, _NETBUF::nb_ap, _NETBUF::nb_dl, _NBDATA::sz, XCPOPT::ul, _NBDATA::vp, XCPOPT::xcpo_, XCPOPT::xcpo_len, and XCPOPT::xcpo_type.

Referenced by NutDumpIpcp().

Here is the call graph for this function:

void NutDumpIpcp ( FILE stream,
NETBUF nb 
)

References fprintf(), fputs(), fputs_P, _NETBUF::nb_dl, _NETBUF::nb_nw, ntohs, NutDumpIpcpOption(), _NBDATA::sz, _NBDATA::vp, xcphdr::xch_code, xcphdr::xch_id, xcphdr::xch_len, XCP_CODEREJ, XCP_CONFACK, XCP_CONFNAK, XCP_CONFREJ, XCP_CONFREQ, XCP_TERMACK, and XCP_TERMREQ.

Referenced by NutDumpPpp().

Here is the call graph for this function:

void NutDumpPpp ( FILE stream,
NETBUF nb 
)

References ppp_header::address, AHDLC_ALLSTATIONS, fprintf(), fputs(), _NETBUF::nb_ap, _NETBUF::nb_dl, _NETBUF::nb_nw, _NETBUF::nb_tp, ntohs, NutDumpIpcp(), NutDumpLcp(), NutDumpPap(), PPP_IP, PPP_IPCP, PPP_LCP, PPP_PAP, ppp_header::prot_type, _NBDATA::sz, and _NBDATA::vp.

Referenced by NutPppInput(), and NutPppOutput().

Here is the call graph for this function:

void NutTracePPP ( FILE stream,
uint8_t  flags 
)

Control PPP tracing.

Parameters:
streamPointer to a previously opened stream or null to disable trace output.
flagsFlags to enable specific traces.

References __ppp_trf, and __ppp_trs.

Referenced by main().


Variable Documentation