]>
Commit | Line | Data |
---|---|---|
acddc0ed | 1 | // SPDX-License-Identifier: MIT |
ca10883e DS |
2 | /* |
3 | Copyright (c) 2007, 2008 by Juliusz Chroboczek | |
ca10883e DS |
4 | */ |
5 | ||
6 | #ifndef BABEL_KERNEL_H | |
7 | #define BABEL_KERNEL_H | |
8 | ||
9 | #include <netinet/in.h> | |
10 | #include "babel_main.h" | |
11 | #include "if.h" | |
12 | ||
13 | #define KERNEL_INFINITY 0xFFFF | |
14 | ||
e8c8f2e0 DS |
15 | enum babel_kernel_routes { |
16 | ROUTE_FLUSH, | |
17 | ROUTE_ADD, | |
18 | ROUTE_MODIFY, | |
19 | }; | |
ca10883e DS |
20 | |
21 | int kernel_interface_operational(struct interface *interface); | |
22 | int kernel_interface_mtu(struct interface *interface); | |
23 | int kernel_interface_wireless(struct interface *interface); | |
e8c8f2e0 DS |
24 | int kernel_route(enum babel_kernel_routes operation, const unsigned char *dest, |
25 | unsigned short plen, const unsigned char *gate, int ifindex, | |
26 | unsigned int metric, const unsigned char *newgate, | |
27 | int newifindex, unsigned int newmetric); | |
edb1d4a0 | 28 | int if_eui64(int ifindex, unsigned char *eui); |
c392d9f4 | 29 | void gettime(struct timeval *tv); |
ca10883e DS |
30 | int read_random_bytes(void *buf, size_t len); |
31 | ||
32 | #endif /* BABEL_KERNEL_H */ |