Page Menu
Home
FreeBSD
Search
Configure Global Search
Log In
Files
F109388201
D43245.diff
No One
Temporary
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Flag For Later
Award Token
Size
1 KB
Referenced Files
None
Subscribers
None
D43245.diff
View Options
diff --git a/sys/netinet/tcp.h b/sys/netinet/tcp.h
--- a/sys/netinet/tcp.h
+++ b/sys/netinet/tcp.h
@@ -80,18 +80,23 @@
};
static __inline uint16_t
-tcp_get_flags(const struct tcphdr *th)
+__tcp_get_flags(const struct tcphdr *th)
{
- return (((uint16_t)th->th_x2 << 8) | th->th_flags);
+ return (((uint16_t)th->th_x2 << 8) | th->th_flags);
}
static __inline void
-tcp_set_flags(struct tcphdr *th, uint16_t flags)
+__tcp_set_flags(struct tcphdr *th, uint16_t flags)
{
- th->th_x2 = (flags >> 8) & 0x0f;
- th->th_flags = flags & 0xff;
+ th->th_x2 = (flags >> 8) & 0x0f;
+ th->th_flags = flags & 0xff;
}
+#ifdef _KERNEL
+#define tcp_get_flags(th) __tcp_get_flags(th)
+#define tcp_set_flags(th, flags) __tcp_set_flags(th, flags)
+#endif
+
#define PADTCPOLEN(len) ((((len) / 4) + !!((len) % 4)) * 4)
#define TCPOPT_EOL 0
@@ -455,7 +460,7 @@
int enable;
uint8_t psk[TCP_FASTOPEN_PSK_LEN];
};
-#endif
+
#define TCP_FUNCTION_NAME_LEN_MAX 32
struct tcp_function_set {
@@ -542,4 +547,5 @@
#define TCP_REUSPORT_LB_NUMA_NODOM (-2) /* remove numa binding */
#define TCP_REUSPORT_LB_NUMA_CURDOM (-1) /* bind to current domain */
+#endif /* __BSD_VISIBLE */
#endif /* !_NETINET_TCP_H_ */
File Metadata
Details
Attached
Mime Type
text/plain
Expires
Wed, Feb 5, 10:14 AM (21 h, 41 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
16472368
Default Alt Text
D43245.diff (1 KB)
Attached To
Mode
D43245: tcp: limit namespace for tcp_[gs]et_flags
Attached
Detach File
Event Timeline
Log In to Comment