| 1 |
#ifndef _FIXUP_NETLINK_ROUTE_RTNL_H |
| 2 |
#define _FIXUP_NETLINK_ROUTE_RTNL_H |
| 3 |
|
| 4 |
#include <netlink/attr.h> |
| 5 |
|
| 6 |
struct rtnl_addr; |
| 7 |
struct rtnl_neigh; |
| 8 |
struct rtnl_route; |
| 9 |
struct rtnl_nexthop; |
| 10 |
|
| 11 |
static inline struct rtnl_neigh * |
| 12 |
rtnl_neigh_get(struct nl_cache *cache, int ifindex, struct nl_addr *dst) |
| 13 |
{ |
| 14 |
return NULL; |
| 15 |
} |
| 16 |
|
| 17 |
static inline struct rtnl_link *rtnl_link_get(struct nl_cache *cache, |
| 18 |
int ifindex) |
| 19 |
{ |
| 20 |
return NULL; |
| 21 |
} |
| 22 |
|
| 23 |
static void rtnl_neigh_put(struct rtnl_neigh *neigh) |
| 24 |
{ |
| 25 |
} |
| 26 |
|
| 27 |
static inline int rtnl_addr_get_family(struct rtnl_addr *addr) |
| 28 |
{ |
| 29 |
return -1; |
| 30 |
} |
| 31 |
|
| 32 |
static inline struct nl_addr *rtnl_neigh_get_lladdr(struct rtnl_neigh *neigh) |
| 33 |
{ |
| 34 |
return NULL; |
| 35 |
} |
| 36 |
|
| 37 |
static inline struct rtnl_neigh *rtnl_neigh_alloc(void) |
| 38 |
{ |
| 39 |
return NULL; |
| 40 |
} |
| 41 |
|
| 42 |
static inline void rtnl_neigh_set_ifindex(struct rtnl_neigh *neigh, int ifindex) |
| 43 |
{ |
| 44 |
} |
| 45 |
static inline int rtnl_neigh_set_dst(struct rtnl_neigh *neigh, |
| 46 |
struct nl_addr *addr) |
| 47 |
{ |
| 48 |
return -1; |
| 49 |
} |
| 50 |
|
| 51 |
static inline uint8_t rtnl_route_get_type(struct rtnl_route *route) |
| 52 |
{ |
| 53 |
return 0; |
| 54 |
} |
| 55 |
|
| 56 |
static inline struct nl_addr *rtnl_route_get_pref_src(struct rtnl_route *route) |
| 57 |
{ |
| 58 |
return NULL; |
| 59 |
} |
| 60 |
|
| 61 |
static inline struct rtnl_nexthop *rtnl_route_nexthop_n(struct rtnl_route *r, |
| 62 |
int n) |
| 63 |
{ |
| 64 |
return NULL; |
| 65 |
} |
| 66 |
|
| 67 |
static inline int rtnl_route_nh_get_ifindex(struct rtnl_nexthop *nh) |
| 68 |
{ |
| 69 |
return -1; |
| 70 |
} |
| 71 |
|
| 72 |
static inline struct nl_addr *rtnl_route_nh_get_gateway(struct rtnl_nexthop *nh) |
| 73 |
{ |
| 74 |
return NULL; |
| 75 |
} |
| 76 |
|
| 77 |
static inline int rtnl_link_alloc_cache(struct nl_sock *sk, int family, |
| 78 |
struct nl_cache **result) |
| 79 |
{ |
| 80 |
return -1; |
| 81 |
} |
| 82 |
|
| 83 |
static inline struct nl_addr *rtnl_link_get_addr(struct rtnl_link *link) |
| 84 |
{ |
| 85 |
return NULL; |
| 86 |
} |
| 87 |
|
| 88 |
static inline int rtnl_link_vlan_get_id(struct rtnl_link *link) |
| 89 |
{ |
| 90 |
return -1; |
| 91 |
} |
| 92 |
|
| 93 |
static inline void rtnl_link_put(struct rtnl_link *link) |
| 94 |
{ |
| 95 |
} |
| 96 |
|
| 97 |
static inline int rtnl_link_is_vlan(struct rtnl_link *link) |
| 98 |
{ |
| 99 |
return -1; |
| 100 |
} |
| 101 |
|
| 102 |
static inline int rtnl_route_alloc_cache(struct nl_sock *sk, int family, |
| 103 |
int flags, struct nl_cache **result) |
| 104 |
{ |
| 105 |
return -1; |
| 106 |
} |
| 107 |
|
| 108 |
static inline int rtnl_neigh_alloc_cache(struct nl_sock *sock, |
| 109 |
struct nl_cache **result) |
| 110 |
{ |
| 111 |
return -1; |
| 112 |
} |
| 113 |
|
| 114 |
#endif |