summaryrefslogtreecommitdiff
path: root/kernel/network/ipv4.h
diff options
context:
space:
mode:
authorAnton Kling <anton@kling.gg>2024-10-06 11:12:16 +0200
committerAnton Kling <anton@kling.gg>2024-10-06 11:12:16 +0200
commitf18beba3cb3d85ed6e0f44fdff9256c50adcc5e1 (patch)
tree42e15026c9a0154269e5c7de71cd829866d6d564 /kernel/network/ipv4.h
parent6dc2637972f93dea8cc831d7ee225daefb74b8ab (diff)
Kernel/Networking: Modify outgoing packet in place
This avoids creation of new buffers and unnecessary memcpys. The old interface still exists for UDP but will be removed when I am less lazy. From testing it does not appear to have any performance improvement but this is most likely due to other bottlenecks as extra copies should always be worse.
Diffstat (limited to 'kernel/network/ipv4.h')
-rw-r--r--kernel/network/ipv4.h1
1 files changed, 1 insertions, 0 deletions
diff --git a/kernel/network/ipv4.h b/kernel/network/ipv4.h
index 7b44eb1..4d19ae9 100644
--- a/kernel/network/ipv4.h
+++ b/kernel/network/ipv4.h
@@ -2,3 +2,4 @@
void handle_ipv4(const u8 *payload, u32 packet_length);
void send_ipv4_packet(ipv4_t ip, u8 protocol, const u8 *payload, u16 length);
+void send_ipv4_packet2(ipv4_t ip, u8 protocol, u16 length);