diff options
author | Jonathan Herman <hermanjl@cs.unc.edu> | 2013-01-22 10:38:37 -0500 |
---|---|---|
committer | Jonathan Herman <hermanjl@cs.unc.edu> | 2013-01-22 10:38:37 -0500 |
commit | fcc9d2e5a6c89d22b8b773a64fb4ad21ac318446 (patch) | |
tree | a57612d1888735a2ec7972891b68c1ac5ec8faea /drivers/net/skfp/h/mbuf.h | |
parent | 8dea78da5cee153b8af9c07a2745f6c55057fe12 (diff) |
Diffstat (limited to 'drivers/net/skfp/h/mbuf.h')
-rw-r--r-- | drivers/net/skfp/h/mbuf.h | 50 |
1 files changed, 50 insertions, 0 deletions
diff --git a/drivers/net/skfp/h/mbuf.h b/drivers/net/skfp/h/mbuf.h new file mode 100644 index 00000000000..f2aadcda9e7 --- /dev/null +++ b/drivers/net/skfp/h/mbuf.h | |||
@@ -0,0 +1,50 @@ | |||
1 | /****************************************************************************** | ||
2 | * | ||
3 | * (C)Copyright 1998,1999 SysKonnect, | ||
4 | * a business unit of Schneider & Koch & Co. Datensysteme GmbH. | ||
5 | * | ||
6 | * This program is free software; you can redistribute it and/or modify | ||
7 | * it under the terms of the GNU General Public License as published by | ||
8 | * the Free Software Foundation; either version 2 of the License, or | ||
9 | * (at your option) any later version. | ||
10 | * | ||
11 | * The information in this file is provided "AS IS" without warranty. | ||
12 | * | ||
13 | ******************************************************************************/ | ||
14 | |||
15 | #ifndef _MBUF_ | ||
16 | #define _MBUF_ | ||
17 | |||
18 | #define M_SIZE 4504 | ||
19 | |||
20 | #ifndef MAX_MBUF | ||
21 | #define MAX_MBUF 4 | ||
22 | #endif | ||
23 | |||
24 | #ifndef NO_STD_MBUF | ||
25 | #define sm_next m_next | ||
26 | #define sm_off m_off | ||
27 | #define sm_len m_len | ||
28 | #define sm_data m_data | ||
29 | #define SMbuf Mbuf | ||
30 | #define mtod smtod | ||
31 | #define mtodoff smtodoff | ||
32 | #endif | ||
33 | |||
34 | struct s_mbuf { | ||
35 | struct s_mbuf *sm_next ; /* low level linked list */ | ||
36 | short sm_off ; /* offset in m_data */ | ||
37 | u_int sm_len ; /* len of data */ | ||
38 | #ifdef PCI | ||
39 | int sm_use_count ; | ||
40 | #endif | ||
41 | char sm_data[M_SIZE] ; | ||
42 | } ; | ||
43 | |||
44 | typedef struct s_mbuf SMbuf ; | ||
45 | |||
46 | /* mbuf head, to typed data */ | ||
47 | #define smtod(x,t) ((t)((x)->sm_data + (x)->sm_off)) | ||
48 | #define smtodoff(x,t,o) ((t)((x)->sm_data + (o))) | ||
49 | |||
50 | #endif /* _MBUF_ */ | ||