Linux Kernel  3.7.1
 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Groups Pages
Macros | Functions | Variables
ndisc.c File Reference
#include <linux/module.h>
#include <linux/errno.h>
#include <linux/types.h>
#include <linux/socket.h>
#include <linux/sockios.h>
#include <linux/sched.h>
#include <linux/net.h>
#include <linux/in6.h>
#include <linux/route.h>
#include <linux/init.h>
#include <linux/rcupdate.h>
#include <linux/slab.h>
#include <linux/if_addr.h>
#include <linux/if_arp.h>
#include <linux/ipv6.h>
#include <linux/icmpv6.h>
#include <linux/jhash.h>
#include <net/sock.h>
#include <net/snmp.h>
#include <net/ipv6.h>
#include <net/protocol.h>
#include <net/ndisc.h>
#include <net/ip6_route.h>
#include <net/addrconf.h>
#include <net/icmp.h>
#include <net/netlink.h>
#include <linux/rtnetlink.h>
#include <net/flow.h>
#include <net/ip6_checksum.h>
#include <net/inet_common.h>
#include <linux/proc_fs.h>
#include <linux/netfilter.h>
#include <linux/netfilter_ipv6.h>

Go to the source code of this file.

Macros

#define pr_fmt(fmt)   "ICMPv6: " fmt
 
#define ND_DEBUG   1
 
#define ND_PRINTK(val, level, fmt,...)
 

Functions

struct ndisc_optionsndisc_parse_options (u8 *opt, int opt_len, struct ndisc_options *ndopts)
 
int ndisc_mc_map (const struct in6_addr *addr, char *buf, struct net_device *dev, int dir)
 
 EXPORT_SYMBOL (ndisc_mc_map)
 
struct sk_buffndisc_build_skb (struct net_device *dev, const struct in6_addr *daddr, const struct in6_addr *saddr, struct icmp6hdr *icmp6h, const struct in6_addr *target, int llinfo)
 
 EXPORT_SYMBOL (ndisc_build_skb)
 
void ndisc_send_skb (struct sk_buff *skb, struct net_device *dev, struct neighbour *neigh, const struct in6_addr *daddr, const struct in6_addr *saddr, struct icmp6hdr *icmp6h)
 
 EXPORT_SYMBOL (ndisc_send_skb)
 
void ndisc_send_ns (struct net_device *dev, struct neighbour *neigh, const struct in6_addr *solicit, const struct in6_addr *daddr, const struct in6_addr *saddr)
 
void ndisc_send_rs (struct net_device *dev, const struct in6_addr *saddr, const struct in6_addr *daddr)
 
void ndisc_send_redirect (struct sk_buff *skb, const struct in6_addr *target)
 
int ndisc_rcv (struct sk_buff *skb)
 
int __init ndisc_init (void)
 
void ndisc_cleanup (void)
 

Variables

struct neigh_table nd_tbl
 

Macro Definition Documentation

#define ND_DEBUG   1

Definition at line 76 of file ndisc.c.

#define ND_PRINTK (   val,
  level,
  fmt,
  ... 
)
Value:
do { \
if (val <= ND_DEBUG) \
net_##level##_ratelimited(fmt, ##__VA_ARGS__); \
} while (0)

Definition at line 78 of file ndisc.c.

#define pr_fmt (   fmt)    "ICMPv6: " fmt

Definition at line 30 of file ndisc.c.

Function Documentation

EXPORT_SYMBOL ( ndisc_mc_map  )
EXPORT_SYMBOL ( ndisc_build_skb  )
EXPORT_SYMBOL ( ndisc_send_skb  )
struct sk_buff* ndisc_build_skb ( struct net_device dev,
const struct in6_addr daddr,
const struct in6_addr saddr,
struct icmp6hdr icmp6h,
const struct in6_addr target,
int  llinfo 
)
read

Definition at line 373 of file ndisc.c.

void ndisc_cleanup ( void  )

Definition at line 1722 of file ndisc.c.

int __init ndisc_init ( void  )

Definition at line 1689 of file ndisc.c.

int ndisc_mc_map ( const struct in6_addr addr,
char buf,
struct net_device dev,
int  dir 
)

Definition at line 266 of file ndisc.c.

struct ndisc_options* ndisc_parse_options ( u8 opt,
int  opt_len,
struct ndisc_options ndopts 
)
read

Definition at line 202 of file ndisc.c.

int ndisc_rcv ( struct sk_buff skb)

Definition at line 1523 of file ndisc.c.

void ndisc_send_ns ( struct net_device dev,
struct neighbour neigh,
const struct in6_addr solicit,
const struct in6_addr daddr,
const struct in6_addr saddr 
)

Definition at line 556 of file ndisc.c.

void ndisc_send_redirect ( struct sk_buff skb,
const struct in6_addr target 
)

Definition at line 1355 of file ndisc.c.

void ndisc_send_rs ( struct net_device dev,
const struct in6_addr saddr,
const struct in6_addr daddr 
)

Definition at line 577 of file ndisc.c.

void ndisc_send_skb ( struct sk_buff skb,
struct net_device dev,
struct neighbour neigh,
const struct in6_addr daddr,
const struct in6_addr saddr,
struct icmp6hdr icmp6h 
)

Definition at line 436 of file ndisc.c.

Variable Documentation

Initial value:
= {
.family = AF_INET6,
.key_len = sizeof(struct in6_addr),
.hash = ndisc_hash,
.constructor = ndisc_constructor,
.pconstructor = pndisc_constructor,
.pdestructor = pndisc_destructor,
.proxy_redo = pndisc_redo,
.id = "ndisc_cache",
.parms = {
.tbl = &nd_tbl,
.base_reachable_time = ND_REACHABLE_TIME,
.retrans_time = ND_RETRANS_TIMER,
.gc_staletime = 60 * HZ,
.reachable_time = ND_REACHABLE_TIME,
.delay_probe_time = 5 * HZ,
.queue_len_bytes = 64*1024,
.ucast_probes = 3,
.mcast_probes = 3,
.anycast_delay = 1 * HZ,
.proxy_delay = (8 * HZ) / 10,
.proxy_qlen = 64,
},
.gc_interval = 30 * HZ,
.gc_thresh1 = 128,
.gc_thresh2 = 512,
.gc_thresh3 = 1024,
}

Definition at line 117 of file ndisc.c.