The Netsukuku Project  0.0.9
An Alternative routing method
 All Data Structures Files Functions Variables Typedefs Enumerations Enumerator Macros
iptunnel.c File Reference
#include "includes.h"
#include "inet.h"
#include <linux/ip.h>
#include <linux/if_tunnel.h>
#include "libnetlink.h"
#include "ll_map.h"
#include "krnl_route.h"
#include "route.h"
#include "iptunnel.h"
#include "common.h"
Include dependency graph for iptunnel.c:

Macros

#define IP_DF   0x4000 /* Flag: "Don't Fragment" */
 

Functions

static int do_add (int cmd, inet_prefix *remote, inet_prefix *local, char *dev, char *tunl_prefix, int tunl_number)
 
int do_del (inet_prefix *remote, inet_prefix *local, char *dev, char *tunl_prefix, int tunl_number)
 
int tunnel_add (inet_prefix *remote, inet_prefix *local, char *dev, char *tunl_prefix, int tunl_number)
 
int tunnel_change (inet_prefix *remote, inet_prefix *local, char *dev, char *tunl_prefix, int tunl_number)
 
int tunnel_del (inet_prefix *remote, inet_prefix *local, char *dev, char *tunl_prefix, int tunl_number)
 
static int do_ioctl_get_ifindex (const char *dev)
 
static int do_get_ioctl (const char *basedev, struct ip_tunnel_parm *p)
 
static int do_add_ioctl (int cmd, const char *basedev, struct ip_tunnel_parm *p)
 
static int do_del_ioctl (const char *basedev, struct ip_tunnel_parm *p)
 
static int fill_tunnel_parm (int cmd, inet_prefix *remote, inet_prefix *local, char *dev, char *tunl_prefix, int tunl_number, struct ip_tunnel_parm *p)
 
int do_get (char *dev)
 
int tun_add_tunl (interface *ifs, char *tunl_prefix, u_char tunl_number)
 
int tun_del_tunl (interface *ifs, char *tunl_prefix, u_char tunl_number)
 
void init_tunnels_ifs (void)
 
int first_free_tunnel_if (void)
 
int set_tunnel_ip (char *tunl_prefix, int tunl_number, inet_prefix *tunl_ip)
 
int add_tunnel_if (inet_prefix *remote, inet_prefix *local, char *dev, char *tunl_prefix, int tunl_number, inet_prefix *tunl_ip)
 
int del_tunnel_if (inet_prefix *remote, inet_prefix *local, char *dev, char *tunl_prefix, int tunl_number)
 
void del_all_tunnel_ifs (inet_prefix *remote, inet_prefix *local, char *dev, char *tunl_prefix)
 

Macro Definition Documentation

#define IP_DF   0x4000 /* Flag: "Don't Fragment" */

Function Documentation

int add_tunnel_if ( inet_prefix remote,
inet_prefix local,
char *  dev,
char *  tunl_prefix,
int  tunl_number,
inet_prefix tunl_ip 
)

Here is the call graph for this function:

Here is the caller graph for this function:

void del_all_tunnel_ifs ( inet_prefix remote,
inet_prefix local,
char *  dev,
char *  tunl_prefix 
)

Here is the call graph for this function:

Here is the caller graph for this function:

int del_tunnel_if ( inet_prefix remote,
inet_prefix local,
char *  dev,
char *  tunl_prefix,
int  tunl_number 
)

Here is the call graph for this function:

Here is the caller graph for this function:

static int do_add ( int  cmd,
inet_prefix remote,
inet_prefix local,
char *  dev,
char *  tunl_prefix,
int  tunl_number 
)
static

Here is the call graph for this function:

Here is the caller graph for this function:

static int do_add_ioctl ( int  cmd,
const char *  basedev,
struct ip_tunnel_parm *  p 
)
static

Here is the call graph for this function:

Here is the caller graph for this function:

int do_del ( inet_prefix remote,
inet_prefix local,
char *  dev,
char *  tunl_prefix,
int  tunl_number 
)

Here is the call graph for this function:

Here is the caller graph for this function:

static int do_del_ioctl ( const char *  basedev,
struct ip_tunnel_parm *  p 
)
static

Here is the call graph for this function:

Here is the caller graph for this function:

int do_get ( char *  dev)

Here is the call graph for this function:

Here is the caller graph for this function:

static int do_get_ioctl ( const char *  basedev,
struct ip_tunnel_parm *  p 
)
static

Here is the caller graph for this function:

static int do_ioctl_get_ifindex ( const char *  dev)
static

Here is the call graph for this function:

Here is the caller graph for this function:

static int fill_tunnel_parm ( int  cmd,
inet_prefix remote,
inet_prefix local,
char *  dev,
char *  tunl_prefix,
int  tunl_number,
struct ip_tunnel_parm *  p 
)
static

Here is the call graph for this function:

Here is the caller graph for this function:

int first_free_tunnel_if ( void  )
void init_tunnels_ifs ( void  )

Here is the caller graph for this function:

int set_tunnel_ip ( char *  tunl_prefix,
int  tunl_number,
inet_prefix tunl_ip 
)

Here is the call graph for this function:

Here is the caller graph for this function:

int tun_add_tunl ( interface ifs,
char *  tunl_prefix,
u_char  tunl_number 
)

Here is the call graph for this function:

Here is the caller graph for this function:

int tun_del_tunl ( interface ifs,
char *  tunl_prefix,
u_char  tunl_number 
)

Here is the caller graph for this function:

int tunnel_add ( inet_prefix remote,
inet_prefix local,
char *  dev,
char *  tunl_prefix,
int  tunl_number 
)

Here is the call graph for this function:

Here is the caller graph for this function:

int tunnel_change ( inet_prefix remote,
inet_prefix local,
char *  dev,
char *  tunl_prefix,
int  tunl_number 
)

Here is the call graph for this function:

Here is the caller graph for this function:

int tunnel_del ( inet_prefix remote,
inet_prefix local,
char *  dev,
char *  tunl_prefix,
int  tunl_number 
)

Here is the call graph for this function:

Here is the caller graph for this function: