forked from Imagelibrary/rtems
Partial update from FreeBSD.
This commit is contained in:
@@ -1,5 +1,3 @@
|
|||||||
/* $Id$ */
|
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* if_ppp.h - Point-to-Point Protocol definitions.
|
* if_ppp.h - Point-to-Point Protocol definitions.
|
||||||
*
|
*
|
||||||
@@ -16,12 +14,25 @@
|
|||||||
* from this software without specific prior written permission.
|
* from this software without specific prior written permission.
|
||||||
* THIS SOFTWARE IS PROVIDED ``AS IS'' AND WITHOUT ANY EXPRESS OR
|
* THIS SOFTWARE IS PROVIDED ``AS IS'' AND WITHOUT ANY EXPRESS OR
|
||||||
* IMPLIED WARRANTIES, INCLUDING, WITHOUT LIMITATION, THE IMPLIED
|
* IMPLIED WARRANTIES, INCLUDING, WITHOUT LIMITATION, THE IMPLIED
|
||||||
* WARRANTIES OF MERCHANTIBILITY AND FITNESS FOR A PARTICULAR PURPOSE.
|
* WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
|
||||||
|
*
|
||||||
|
* $FreeBSD: src/sys/net/if_ppp.h,v 1.15 2005/01/07 01:45:34 imp Exp $
|
||||||
|
*/
|
||||||
|
|
||||||
|
/*
|
||||||
|
* $Id$
|
||||||
*/
|
*/
|
||||||
|
|
||||||
#ifndef _IF_PPP_H_
|
#ifndef _IF_PPP_H_
|
||||||
#define _IF_PPP_H_
|
#define _IF_PPP_H_
|
||||||
|
|
||||||
|
/*
|
||||||
|
* Packet sizes
|
||||||
|
*/
|
||||||
|
#define PPP_MTU 1500 /* Default MTU (size of Info field) */
|
||||||
|
#define PPP_MAXMRU 65000 /* Largest MRU we allow */
|
||||||
|
#define PPP_MAXMTU 16384 /* Largest MTU we allow */
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* Bit definitions for flags.
|
* Bit definitions for flags.
|
||||||
*/
|
*/
|
||||||
@@ -50,8 +61,8 @@
|
|||||||
*/
|
*/
|
||||||
#define SC_TIMEOUT 0x00000400 /* timeout is currently pending */
|
#define SC_TIMEOUT 0x00000400 /* timeout is currently pending */
|
||||||
#define SC_VJ_RESET 0x00000800 /* need to reset VJ decomp */
|
#define SC_VJ_RESET 0x00000800 /* need to reset VJ decomp */
|
||||||
#define SC_COMP_RUN 0x00001000 /* compressor has been inited */
|
#define SC_COMP_RUN 0x00001000 /* compressor has been initiated */
|
||||||
#define SC_DECOMP_RUN 0x00002000 /* decompressor has been inited */
|
#define SC_DECOMP_RUN 0x00002000 /* decompressor has been initiated */
|
||||||
#define SC_DC_ERROR 0x00004000 /* non-fatal decomp error detected */
|
#define SC_DC_ERROR 0x00004000 /* non-fatal decomp error detected */
|
||||||
#define SC_DC_FERROR 0x00008000 /* fatal decomp error detected */
|
#define SC_DC_FERROR 0x00008000 /* fatal decomp error detected */
|
||||||
#define SC_TBUSY 0x10000000 /* xmitter doesn't need a packet yet */
|
#define SC_TBUSY 0x10000000 /* xmitter doesn't need a packet yet */
|
||||||
|
|||||||
@@ -1,5 +1,3 @@
|
|||||||
/* $Id$ */
|
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* ppp_defs.h - PPP definitions.
|
* ppp_defs.h - PPP definitions.
|
||||||
*
|
*
|
||||||
@@ -25,6 +23,12 @@
|
|||||||
* ON AN "AS IS" BASIS, AND THE AUSTRALIAN NATIONAL UNIVERSITY HAS NO
|
* ON AN "AS IS" BASIS, AND THE AUSTRALIAN NATIONAL UNIVERSITY HAS NO
|
||||||
* OBLIGATION TO PROVIDE MAINTENANCE, SUPPORT, UPDATES, ENHANCEMENTS,
|
* OBLIGATION TO PROVIDE MAINTENANCE, SUPPORT, UPDATES, ENHANCEMENTS,
|
||||||
* OR MODIFICATIONS.
|
* OR MODIFICATIONS.
|
||||||
|
*
|
||||||
|
* $FreeBSD: src/sys/net/ppp_defs.h,v 1.8 2005/01/07 01:45:35 imp Exp $
|
||||||
|
*/
|
||||||
|
|
||||||
|
/*
|
||||||
|
* $Id$
|
||||||
*/
|
*/
|
||||||
|
|
||||||
#ifndef _PPP_DEFS_H_
|
#ifndef _PPP_DEFS_H_
|
||||||
@@ -35,21 +39,7 @@
|
|||||||
*/
|
*/
|
||||||
#define PPP_HDRLEN 4 /* octets for standard ppp header */
|
#define PPP_HDRLEN 4 /* octets for standard ppp header */
|
||||||
#define PPP_FCSLEN 2 /* octets for FCS */
|
#define PPP_FCSLEN 2 /* octets for FCS */
|
||||||
|
|
||||||
/*
|
|
||||||
* Packet sizes
|
|
||||||
*
|
|
||||||
* Note - lcp shouldn't be allowed to negotiate stuff outside these
|
|
||||||
* limits. See lcp.h in the pppd directory.
|
|
||||||
* (XXX - these constants should simply be shared by lcp.c instead
|
|
||||||
* of living in lcp.h)
|
|
||||||
*/
|
|
||||||
#define PPP_MTU 1500 /* Default MTU (size of Info field) */
|
|
||||||
#define PPP_MAXMTU 65535 - (PPP_HDRLEN + PPP_FCSLEN)
|
|
||||||
#define PPP_MINMTU 64
|
|
||||||
#define PPP_MRU 1500 /* default MRU = max length of info field */
|
#define PPP_MRU 1500 /* default MRU = max length of info field */
|
||||||
#define PPP_MAXMRU 65000 /* Largest MRU we allow */
|
|
||||||
#define PPP_MINMRU 128
|
|
||||||
|
|
||||||
#define PPP_ADDRESS(p) (((u_char *)(p))[0])
|
#define PPP_ADDRESS(p) (((u_char *)(p))[0])
|
||||||
#define PPP_CONTROL(p) (((u_char *)(p))[1])
|
#define PPP_CONTROL(p) (((u_char *)(p))[1])
|
||||||
@@ -92,20 +82,6 @@
|
|||||||
#define PPP_GOODFCS 0xf0b8 /* Good final FCS value */
|
#define PPP_GOODFCS 0xf0b8 /* Good final FCS value */
|
||||||
#define PPP_FCS(fcs, c) (((fcs) >> 8) ^ fcstab[((fcs) ^ (c)) & 0xff])
|
#define PPP_FCS(fcs, c) (((fcs) >> 8) ^ fcstab[((fcs) ^ (c)) & 0xff])
|
||||||
|
|
||||||
/*
|
|
||||||
* A 32-bit unsigned integral type.
|
|
||||||
*/
|
|
||||||
|
|
||||||
#if !defined(__BIT_TYPES_DEFINED__) && !defined(_BITYPES) \
|
|
||||||
&& !defined(__FreeBSD__) && (NS_TARGET < 40)
|
|
||||||
#ifdef UINT32_T
|
|
||||||
typedef UINT32_T u_int32_t;
|
|
||||||
#else
|
|
||||||
/*typedef unsigned int u_int32_t;*/
|
|
||||||
/*typedef unsigned short u_int16_t;*/
|
|
||||||
#endif
|
|
||||||
#endif
|
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* Extended asyncmap - allows any character to be escaped.
|
* Extended asyncmap - allows any character to be escaped.
|
||||||
*/
|
*/
|
||||||
|
|||||||
Reference in New Issue
Block a user