151 |
|
|
152 |
#define TCP_MSL 60000 /* The maximum segment lifetime in microseconds */ |
#define TCP_MSL 60000 /* The maximum segment lifetime in microseconds */ |
153 |
|
|
154 |
#include "arch/bpstruct.h" |
#ifdef PACK_STRUCT_USE_INCLUDES |
155 |
|
# include "arch/bpstruct.h" |
156 |
|
#endif |
157 |
PACK_STRUCT_BEGIN |
PACK_STRUCT_BEGIN |
158 |
struct tcp_hdr { |
struct tcp_hdr { |
159 |
PACK_STRUCT_FIELD(u16_t src); |
PACK_STRUCT_FIELD(u16_t src); |
166 |
PACK_STRUCT_FIELD(u16_t urgp); |
PACK_STRUCT_FIELD(u16_t urgp); |
167 |
} PACK_STRUCT_STRUCT; |
} PACK_STRUCT_STRUCT; |
168 |
PACK_STRUCT_END |
PACK_STRUCT_END |
169 |
#include "arch/epstruct.h" |
#ifdef PACK_STRUCT_USE_INCLUDES |
170 |
|
# include "arch/epstruct.h" |
171 |
|
#endif |
172 |
|
|
173 |
#define TCPH_OFFSET(hdr) (NTOHS((hdr)->_offset_flags) >> 8) |
#define TCPH_OFFSET(hdr) (NTOHS((hdr)->_offset_flags) >> 8) |
174 |
#define TCPH_FLAGS(hdr) (NTOHS((hdr)->_offset_flags) & 0xff) |
#define TCPH_FLAGS(hdr) (NTOHS((hdr)->_offset_flags) & 0xff) |