From 6bf371cc35c11890ab18c32aabd11bf8a816e574 Mon Sep 17 00:00:00 2001 From: Anton Kling Date: Thu, 4 Jul 2024 23:03:16 +0200 Subject: TCP: Add back support for listening on a socket --- kernel/socket.h | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'kernel/socket.h') diff --git a/kernel/socket.h b/kernel/socket.h index 5ea71f5..bba63c5 100644 --- a/kernel/socket.h +++ b/kernel/socket.h @@ -6,6 +6,7 @@ typedef int socklen_t; #include #include #include +#include #include #include #include @@ -69,10 +70,14 @@ struct TcpConnection { u32 snd_nxt; u32 snd_max; u32 snd_wnd; + + struct list incoming_connections; }; struct TcpConnection *tcp_find_connection(ipv4_t src_ip, u16 src_port, ipv4_t dst_ip, u16 dst_port); +struct TcpConnection *tcp_connect_to_listen(ipv4_t src_ip, u16 src_port, + ipv4_t dst_ip, u16 dst_port); struct UdpConnection *udp_find_connection(ipv4_t src_ip, u16 src_port, u16 dst_port); -- cgit v1.2.3