0001
0002
0003
0004
0005
0006
0007
0008
0009
0010
0011 #ifndef _MBUF_
0012 #define _MBUF_
0013
0014 #define M_SIZE 4504
0015
0016 #ifndef MAX_MBUF
0017 #define MAX_MBUF 4
0018 #endif
0019
0020 #ifndef NO_STD_MBUF
0021 #define sm_next m_next
0022 #define sm_off m_off
0023 #define sm_len m_len
0024 #define sm_data m_data
0025 #define SMbuf Mbuf
0026 #define mtod smtod
0027 #define mtodoff smtodoff
0028 #endif
0029
0030 struct s_mbuf {
0031 struct s_mbuf *sm_next ;
0032 short sm_off ;
0033 u_int sm_len ;
0034 #ifdef PCI
0035 int sm_use_count ;
0036 #endif
0037 char sm_data[M_SIZE] ;
0038 } ;
0039
0040 typedef struct s_mbuf SMbuf ;
0041
0042
0043 #define smtod(x,t) ((t)((x)->sm_data + (x)->sm_off))
0044 #define smtodoff(x,t,o) ((t)((x)->sm_data + (o)))
0045
0046 #endif