]> xenbits.xensource.com Git - unikraft/libs/lwip.git/commitdiff
include: Expose LwIP's RAW protocol
authorEthan Cotterell <e.cotterell@lancaster.ac.uk>
Thu, 29 Apr 2021 14:50:41 +0000 (15:50 +0100)
committerSimon Kuenzer <simon@unikraft.io>
Fri, 24 Nov 2023 15:42:56 +0000 (16:42 +0100)
This commit optionalizes LwIP's "RAW" protocol, making it available to
use within Unikraft when enabled.

Signed-off-by: Ethan Cotterell <e.cotterell@lancs.ac.uk>
Signed-off-by: Alexander Jung <a.jung@lancs.ac.uk>
Reviewed-by: Simon Kuenzer <simon@unikraft.io>
Approved-by: Simon Kuenzer <simon@unikraft.io>
GitHub-Closes: #2

Config.uk
include/lwipopts.h

index 21b529a73892ee2993816c7e6e1ccd6eaad35139..fd346c14cb06d2e36cc39984b7530ecf6c82f954 100644 (file)
--- a/Config.uk
+++ b/Config.uk
@@ -214,6 +214,13 @@ config LWIP_UDP
        bool "UDP support"
        default y
 
+config LWIP_RAW
+       bool "RAW support"
+       default n
+       help
+               Enable the RAW address family (AF_RAW).  This option allows an
+               application to be able to hook into the IP layer itself.
+
 menuconfig LWIP_TCP
        bool "TCP support"
        default y
index bedd17c7b458952cacf19443d6364392c1ead62b..608d6a7c5f51f0fa20cbd053a2ff8ce6d151247a 100644 (file)
@@ -131,6 +131,15 @@ void sys_free(void *ptr);
 #define IP_REASS_MAX_PBUFS CONFIG_LWIP_IP_REASS_MAX_PBUFS
 #endif
 
+/**
+ * RAW support
+ */
+#if CONFIG_LWIP_RAW
+#define LWIP_RAW 1
+#else
+#define LWIP_RAW 0
+#endif
+
 /**
  * UDP options
  */