[ source navigation ] [ diff markup ] [ identifier search ] [ freetext search ] [ file search ] [ list types ] [ track identifier ]

FreeBSD/Linux Kernel Cross Reference
sys/net/if_pppvar.h

Version: -  FREEBSD  -  FREEBSD10  -  FREEBSD9  -  FREEBSD92  -  FREEBSD91  -  FREEBSD90  -  FREEBSD8  -  FREEBSD82  -  FREEBSD81  -  FREEBSD80  -  FREEBSD7  -  FREEBSD74  -  FREEBSD73  -  FREEBSD72  -  FREEBSD71  -  FREEBSD70  -  FREEBSD6  -  FREEBSD64  -  FREEBSD63  -  FREEBSD62  -  FREEBSD61  -  FREEBSD60  -  FREEBSD5  -  FREEBSD55  -  FREEBSD54  -  FREEBSD53  -  FREEBSD52  -  FREEBSD51  -  FREEBSD50  -  FREEBSD4  -  FREEBSD3  -  FREEBSD22  -  cheribsd  -  linux-2.6  -  linux-2.4.22  -  MK83  -  MK84  -  PLAN9  -  DFBSD  -  NETBSD  -  NETBSD5  -  NETBSD4  -  NETBSD3  -  NETBSD20  -  OPENBSD  -  xnu-517  -  xnu-792  -  xnu-792.6.70  -  xnu-1228  -  xnu-1456.1.26  -  xnu-1699.24.8  -  xnu-2050.18.24  -  OPENSOLARIS  -  minix-3-1-1  -  FREEBSD-LIBC  -  FREEBSD8-LIBC  -  FREEBSD7-LIBC  -  FREEBSD6-LIBC  -  GLIBC27 
SearchContext: -  none  -  3  -  10 

    1 /*
    2  * if_pppvar.h - private structures and declarations for PPP.
    3  *
    4  * Copyright (c) 1994 The Australian National University.
    5  * All rights reserved.
    6  *
    7  * Permission to use, copy, modify, and distribute this software and its
    8  * documentation is hereby granted, provided that the above copyright
    9  * notice appears in all copies.  This software is provided without any
   10  * warranty, express or implied. The Australian National University
   11  * makes no representations about the suitability of this software for
   12  * any purpose.
   13  *
   14  * IN NO EVENT SHALL THE AUSTRALIAN NATIONAL UNIVERSITY BE LIABLE TO ANY
   15  * PARTY FOR DIRECT, INDIRECT, SPECIAL, INCIDENTAL, OR CONSEQUENTIAL DAMAGES
   16  * ARISING OUT OF THE USE OF THIS SOFTWARE AND ITS DOCUMENTATION, EVEN IF
   17  * THE AUSTRALIAN NATIONAL UNIVERSITY HAVE BEEN ADVISED OF THE POSSIBILITY
   18  * OF SUCH DAMAGE.
   19  *
   20  * THE AUSTRALIAN NATIONAL UNIVERSITY SPECIFICALLY DISCLAIMS ANY WARRANTIES,
   21  * INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY
   22  * AND FITNESS FOR A PARTICULAR PURPOSE.  THE SOFTWARE PROVIDED HEREUNDER IS
   23  * ON AN "AS IS" BASIS, AND THE AUSTRALIAN NATIONAL UNIVERSITY HAS NO
   24  * OBLIGATION TO PROVIDE MAINTENANCE, SUPPORT, UPDATES, ENHANCEMENTS,
   25  * OR MODIFICATIONS.
   26  *
   27  * Copyright (c) 1989 Carnegie Mellon University.
   28  * All rights reserved.
   29  *
   30  * Redistribution and use in source and binary forms are permitted
   31  * provided that the above copyright notice and this paragraph are
   32  * duplicated in all such forms and that any documentation,
   33  * advertising materials, and other materials related to such
   34  * distribution and use acknowledge that the software was developed
   35  * by Carnegie Mellon University.  The name of the
   36  * University may not be used to endorse or promote products derived
   37  * from this software without specific prior written permission.
   38  * THIS SOFTWARE IS PROVIDED ``AS IS'' AND WITHOUT ANY EXPRESS OR
   39  * IMPLIED WARRANTIES, INCLUDING, WITHOUT LIMITATION, THE IMPLIED
   40  * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
   41  *
   42  * $FreeBSD: src/sys/net/if_pppvar.h,v 1.13.2.1 1999/08/29 16:28:22 peter Exp $
   43  */
   44 
   45 /*
   46  * Supported network protocols.  These values are used for
   47  * indexing sc_npmode.
   48  */
   49 #define NP_IP   0               /* Internet Protocol */
   50 #define NUM_NP  1               /* Number of NPs. */
   51 
   52 /*
   53  * Structure describing each ppp unit.
   54  */
   55 struct ppp_softc {
   56         struct  ifnet sc_if;            /* network-visible interface */
   57 /*hi*/  u_int   sc_flags;               /* control/status bits; see if_ppp.h */
   58         struct  callout_handle sc_ch;   /* Used for scheduling timeouts */
   59         void    *sc_devp;               /* pointer to device-dep structure */
   60         void    (*sc_start) __P((struct ppp_softc *));  /* start output proc */
   61         void    (*sc_ctlp) __P((struct ppp_softc *)); /* rcvd control pkt */
   62         void    (*sc_relinq) __P((struct ppp_softc *)); /* relinquish ifunit */
   63         void    (*sc_setmtu) __P((struct ppp_softc *)); /* set mtu */
   64         short   sc_mru;                 /* max receive unit */
   65         pid_t   sc_xfer;                /* used in transferring unit */
   66 /*hi*/  struct  ifqueue sc_rawq;        /* received packets */
   67 /*net*/ struct  ifqueue sc_inq;         /* queue of input packets for daemon */
   68 /*net*/ struct  ifqueue sc_fastq;       /* interactive output packet q */
   69         struct  mbuf *sc_npqueue;       /* output packets not to be sent yet */
   70         struct  mbuf **sc_npqtail;      /* ptr to last next ptr in npqueue */
   71         struct  pppstat sc_stats;       /* count of bytes/pkts sent/rcvd */
   72         enum    NPmode sc_npmode[NUM_NP]; /* what to do with each NP */
   73         struct  compressor *sc_xcomp;   /* transmit compressor */
   74         void    *sc_xc_state;           /* transmit compressor state */
   75         struct  compressor *sc_rcomp;   /* receive decompressor */
   76         void    *sc_rc_state;           /* receive decompressor state */
   77         time_t  sc_last_sent;           /* time (secs) last NP pkt sent */
   78         time_t  sc_last_recv;           /* time (secs) last NP pkt rcvd */
   79 #ifdef PPP_FILTER
   80         struct  bpf_program sc_pass_filt;   /* filter for packets to pass */
   81         struct  bpf_program sc_active_filt; /* filter for "non-idle" packets */
   82 #endif /* PPP_FILTER */
   83 #ifdef  VJC
   84         struct  slcompress *sc_comp;    /* vjc control buffer */
   85 #endif
   86 
   87         /* Device-dependent part for async lines. */
   88         ext_accm sc_asyncmap;           /* async control character map */
   89         u_long  sc_rasyncmap;           /* receive async control char map */
   90         struct  mbuf *sc_outm;          /* mbuf chain currently being output */
   91         struct  mbuf *sc_m;             /* pointer to input mbuf chain */
   92         struct  mbuf *sc_mc;            /* pointer to current input mbuf */
   93         char    *sc_mp;                 /* ptr to next char in input mbuf */
   94         short   sc_ilen;                /* length of input packet so far */
   95         u_short sc_fcs;                 /* FCS so far (input) */
   96         u_short sc_outfcs;              /* FCS so far for output packet */
   97         u_char  sc_rawin[16];           /* chars as received */
   98         int     sc_rawin_count;         /* # in sc_rawin */
   99 };
  100 
  101 extern struct ppp_softc ppp_softc[NPPP];
  102 
  103 struct  ppp_softc *pppalloc __P((pid_t pid));
  104 void    pppdealloc __P((struct ppp_softc *sc));
  105 int     pppioctl __P((struct ppp_softc *sc, u_long cmd, caddr_t data,
  106                       int flag, struct proc *p));
  107 int     pppoutput __P((struct ifnet *ifp, struct mbuf *m0,
  108                        struct sockaddr *dst, struct rtentry *rtp));
  109 void    ppp_restart __P((struct ppp_softc *sc));
  110 void    ppppktin __P((struct ppp_softc *sc, struct mbuf *m, int lost));
  111 struct  mbuf *ppp_dequeue __P((struct ppp_softc *sc));

Cache object: 642104e1138a871344907875fd941a1f


[ source navigation ] [ diff markup ] [ identifier search ] [ freetext search ] [ file search ] [ list types ] [ track identifier ]


This page is part of the FreeBSD/Linux Linux Kernel Cross-Reference, and was automatically generated using a modified version of the LXR engine.