comparison packages/net/tcpip/current/include/netdev.h @ 97:ced4577552cd ecos-sw-2000-06-06

Merge from eCos master repository on 2000-06-06-08:44:00-BST
author jlarmour
date Tue, 06 Jun 2000 08:39:36 +0000
parents
children 84e4bde58b26
comparison
equal deleted inserted replaced
96:b15c60e34c84 97:ced4577552cd
1 //==========================================================================
2 //
3 // include/netdev.h
4 //
5 // Network device description
6 //
7 //==========================================================================
8 //####COPYRIGHTBEGIN####
9 //
10 // -------------------------------------------
11 // The contents of this file are subject to the Red Hat eCos Public License
12 // Version 1.1 (the "License"); you may not use this file except in
13 // compliance with the License. You may obtain a copy of the License at
14 // http://www.redhat.com/
15 //
16 // Software distributed under the License is distributed on an "AS IS"
17 // basis, WITHOUT WARRANTY OF ANY KIND, either express or implied. See the
18 // License for the specific language governing rights and limitations under
19 // the License.
20 //
21 // The Original Code is eCos - Embedded Configurable Operating System,
22 // released September 30, 1998.
23 //
24 // The Initial Developer of the Original Code is Red Hat.
25 // Portions created by Red Hat are
26 // Copyright (C) 1998, 1999, 2000 Red Hat, Inc.
27 // All Rights Reserved.
28 // -------------------------------------------
29 //
30 //####COPYRIGHTEND####
31 //####BSDCOPYRIGHTBEGIN####
32 //
33 // -------------------------------------------
34 //
35 // Portions of this software may have been derived from OpenBSD or other sources,
36 // and are covered by the appropriate copyright disclaimers included herein.
37 //
38 // -------------------------------------------
39 //
40 //####BSDCOPYRIGHTEND####
41 //==========================================================================
42 //#####DESCRIPTIONBEGIN####
43 //
44 // Author(s): gthomas
45 // Contributors: gthomas
46 // Date: 2000-01-10
47 // Purpose:
48 // Description:
49 //
50 //
51 //####DESCRIPTIONEND####
52 //
53 //==========================================================================
54
55 // Network device support
56
57 typedef struct cyg_netdevtab_entry {
58 const char *name;
59 bool (*init)(struct cyg_netdevtab_entry *tab);
60 void *device_instance; // Local data, instance specific
61 unsigned long status;
62 } cyg_netdevtab_entry_t;
63
64 #define CYG_NETDEVTAB_STATUS_AVAIL 0x0001
65
66 extern cyg_netdevtab_entry_t __NETDEVTAB__[], __NETDEVTAB_END__;
67
68 #define NETDEVTAB_ENTRY(_l,_name,_init,_instance) \
69 static bool _init(struct cyg_netdevtab_entry *tab); \
70 cyg_netdevtab_entry_t _l __attribute__ ((section(".netdevtab"))) = { \
71 _name, \
72 _init, \
73 _instance \
74 };