From 89eb41797dca9d667b380ef5117bf185303633e9 Mon Sep 17 00:00:00 2001 From: zhanghongyu Date: Thu, 13 Apr 2023 23:33:56 +0800 Subject: [PATCH] route: add struct in6_rtmsg definition adapts to third-party code compilation. in the process of porting ConnMan, we encounter some situations where the structure is not defined, or the returned data types do not match the expectations. Refer to the common implementation of other systems and add relevant definitions. Signed-off-by: zhanghongyu --- include/net/route.h | 15 +++++++++++++++ 1 file changed, 15 insertions(+) diff --git a/include/net/route.h b/include/net/route.h index 74167da96dc..0564dde8f2a 100644 --- a/include/net/route.h +++ b/include/net/route.h @@ -28,6 +28,7 @@ #include #include +#include #include @@ -57,6 +58,20 @@ struct rtentry FAR char *rt_dev; /* Forcing the device at add. */ }; +struct in6_rtmsg +{ + struct in6_addr rtmsg_dst; + struct in6_addr rtmsg_src; + struct in6_addr rtmsg_gateway; + uint32_t rtmsg_type; + uint16_t rtmsg_dst_len; + uint16_t rtmsg_src_len; + uint32_t rtmsg_metric; + unsigned long int rtmsg_info; + uint32_t rtmsg_flags; + int rtmsg_ifindex; +}; + /**************************************************************************** * Public Data ****************************************************************************/