From 5d2a5f4a9d6a06508c9f751ba72a53c2419b969b Mon Sep 17 00:00:00 2001 From: Tobias Klauser Date: Mon, 16 Jan 2017 14:58:20 +0100 Subject: [PATCH] link/ipvti: Fix and add function prototypes in public header MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Add missing "_ipvti" part to function prototypes so they match the exported name. Also add the missing prototype for rtnl_link_is_ipvti(). This fixes the following GCC warnings when compiling with -Wmissing-prototypes: route/link/ipvti.c:281:5: warning: no previous prototype for ‘rtnl_link_is_ipvti’ [-Wmissing-prototypes] route/link/ipvti.c:369:10: warning: no previous prototype for ‘rtnl_link_ipvti_get_ikey’ [-Wmissing-prototypes] route/link/ipvti.c:403:10: warning: no previous prototype for ‘rtnl_link_ipvti_get_okey’ [-Wmissing-prototypes] route/link/ipvti.c:437:10: warning: no previous prototype for ‘rtnl_link_ipvti_get_local’ [-Wmissing-prototypes] route/link/ipvti.c:471:10: warning: no previous prototype for ‘rtnl_link_ipvti_get_remote’ [-Wmissing-prototypes] Also fix the corresponding names in documentation. Fixes: 8f6301426a00 ("ipvti: introduce vti tunnel support") Signed-off-by: Tobias Klauser --- doc/route.txt | 4 ++-- include/netlink/route/link/ipvti.h | 10 ++++++---- 2 files changed, 8 insertions(+), 6 deletions(-) diff --git a/doc/route.txt b/doc/route.txt index e1e15f1..fece917 100644 --- a/doc/route.txt +++ b/doc/route.txt @@ -1150,10 +1150,10 @@ extern int rtnl_link_ipvti_set_link(struct rtnl_link *link, uint32_t index); extern uint32_t rtnl_link_ipvti_get_link(struct rtnl_link *link); extern int rtnl_link_ipvti_set_ikey(struct rtnl_link *link, uint32_t ikey); -extern uint32_t rtnl_link_get_ikey(struct rtnl_link *link); +extern uint32_t rtnl_link_ipvti_get_ikey(struct rtnl_link *link); extern int rtnl_link_ipvti_set_okey(struct rtnl_link *link, uint32_t okey); -extern uint32_t rtnl_link_get_okey(struct rtnl_link *link) +extern uint32_t rtnl_link_ipvti_get_okey(struct rtnl_link *link) extern int rtnl_link_ipvti_set_local(struct rtnl_link *link, uint32_t addr); extern uint32_t rtnl_link_ipvti_get_local(struct rtnl_link *link); diff --git a/include/netlink/route/link/ipvti.h b/include/netlink/route/link/ipvti.h index a3e7bba..c97e57f 100644 --- a/include/netlink/route/link/ipvti.h +++ b/include/netlink/route/link/ipvti.h @@ -21,20 +21,22 @@ extern "C" { extern struct rtnl_link *rtnl_link_ipvti_alloc(void); extern int rtnl_link_ipvti_add(struct nl_sock *sk, const char *name); + extern int rtnl_link_is_ipvti(struct rtnl_link *link); + extern int rtnl_link_ipvti_set_link(struct rtnl_link *link, uint32_t index); extern uint32_t rtnl_link_ipvti_get_link(struct rtnl_link *link); extern int rtnl_link_ipvti_set_ikey(struct rtnl_link *link, uint32_t ikey); - extern uint32_t rtnl_link_get_ikey(struct rtnl_link *link); + extern uint32_t rtnl_link_ipvti_get_ikey(struct rtnl_link *link); extern int rtnl_link_ipvti_set_okey(struct rtnl_link *link, uint32_t okey); - extern uint32_t rtnl_link_get_okey(struct rtnl_link *link); + extern uint32_t rtnl_link_ipvti_get_okey(struct rtnl_link *link); extern int rtnl_link_ipvti_set_local(struct rtnl_link *link, uint32_t addr); - extern uint32_t rtnl_link_get_local(struct rtnl_link *link); + extern uint32_t rtnl_link_ipvti_get_local(struct rtnl_link *link); extern int rtnl_link_ipvti_set_remote(struct rtnl_link *link, uint32_t addr); - extern uint32_t rtnl_link_get_remote(struct rtnl_link *link); + extern uint32_t rtnl_link_ipvti_get_remote(struct rtnl_link *link); #ifdef __cplusplus }