OpenCores
URL https://opencores.org/ocsvn/openrisc/openrisc/trunk

Subversion Repositories openrisc

[/] [openrisc/] [trunk/] [rtos/] [ecos-2.0/] [packages/] [net/] [tcpip/] [v2_0/] [include/] [net/] [if_gif.h] - Blame information for rev 773

Go to most recent revision | Details | Compare with Previous | View Log

Line No. Rev Author Line
1 27 unneback
//==========================================================================
2
//
3
//      include/net/if_gif.h
4
//
5
//      
6
//
7
//==========================================================================
8
//####BSDCOPYRIGHTBEGIN####
9
//
10
// -------------------------------------------
11
//
12
// Portions of this software may have been derived from OpenBSD or other sources,
13
// and are covered by the appropriate copyright disclaimers included herein.
14
//
15
// -------------------------------------------
16
//
17
//####BSDCOPYRIGHTEND####
18
//==========================================================================
19
//#####DESCRIPTIONBEGIN####
20
//
21
// Author(s):    gthomas
22
// Contributors: gthomas
23
// Date:         2000-01-10
24
// Purpose:      
25
// Description:  
26
//              
27
//
28
//####DESCRIPTIONEND####
29
//
30
//==========================================================================
31
 
32
 
33
/*      $OpenBSD: if_gif.h,v 1.1 1999/12/08 06:50:18 itojun Exp $       */
34
 
35
/*
36
 * Copyright (C) 1995, 1996, 1997, and 1998 WIDE Project.
37
 * All rights reserved.
38
 *
39
 * Redistribution and use in source and binary forms, with or without
40
 * modification, are permitted provided that the following conditions
41
 * are met:
42
 * 1. Redistributions of source code must retain the above copyright
43
 *    notice, this list of conditions and the following disclaimer.
44
 * 2. Redistributions in binary form must reproduce the above copyright
45
 *    notice, this list of conditions and the following disclaimer in the
46
 *    documentation and/or other materials provided with the distribution.
47
 * 3. Neither the name of the project nor the names of its contributors
48
 *    may be used to endorse or promote products derived from this software
49
 *    without specific prior written permission.
50
 *
51
 * THIS SOFTWARE IS PROVIDED BY THE PROJECT AND CONTRIBUTORS ``AS IS'' AND
52
 * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
53
 * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
54
 * ARE DISCLAIMED.  IN NO EVENT SHALL THE PROJECT OR CONTRIBUTORS BE LIABLE
55
 * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
56
 * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
57
 * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
58
 * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
59
 * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
60
 * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
61
 * SUCH DAMAGE.
62
 */
63
 
64
/*
65
 * if_gif.h
66
 */
67
 
68
#ifndef _NET_IF_GIF_H_
69
#define _NET_IF_GIF_H_
70
 
71
 
72
#if (defined(__FreeBSD__) && __FreeBSD__ >= 3) || defined(__NetBSD__)
73
#if defined(_KERNEL) && !defined(_LKM)
74
#include "opt_inet.h"
75
#endif
76
#endif
77
 
78
#include <netinet/in.h>
79
/* xxx sigh, why route have struct route instead of pointer? */
80
 
81
struct gif_softc {
82
        struct ifnet    gif_if;    /* common area */
83
        struct sockaddr *gif_psrc; /* Physical src addr */
84
        struct sockaddr *gif_pdst; /* Physical dst addr */
85
        union {
86
                struct route  gifscr_ro;    /* xxx */
87
#ifdef INET6
88
                struct route_in6 gifscr_ro6; /* xxx */
89
#endif
90
        } gifsc_gifscr;
91
        int             gif_flags;
92
};
93
 
94
#define gif_ro gifsc_gifscr.gifscr_ro
95
#ifdef INET6
96
#define gif_ro6 gifsc_gifscr.gifscr_ro6
97
#endif
98
 
99
#define GIFF_INUSE      0x1     /* gif is in use */
100
 
101
#define GIF_MTU         (1280)  /* Default MTU */
102
#define GIF_MTU_MIN     (1280)  /* Minimum MTU */
103
#define GIF_MTU_MAX     (8192)  /* Maximum MTU */
104
 
105
extern int ngif;
106
extern struct gif_softc *gif;
107
 
108
/* Prototypes */
109
void gif_input __P((struct mbuf *, int, struct ifnet *));
110
int gif_output __P((struct ifnet *, struct mbuf *,
111
                    struct sockaddr *, struct rtentry *));
112
#if defined(__FreeBSD__) && __FreeBSD__ < 3
113
int gif_ioctl __P((struct ifnet *, int, caddr_t));
114
#else
115
int gif_ioctl __P((struct ifnet *, u_long, caddr_t));
116
#endif
117
 
118
#endif /* _NET_IF_GIF_H_ */

powered by: WebSVN 2.1.0

© copyright 1999-2024 OpenCores.org, equivalent to Oliscience, all rights reserved. OpenCores®, registered trademark.