aboutsummaryrefslogtreecommitdiffstats
path: root/include/linux/rtnetlink.h
diff options
context:
space:
mode:
Diffstat (limited to 'include/linux/rtnetlink.h')
-rw-r--r--include/linux/rtnetlink.h13
1 files changed, 3 insertions, 10 deletions
diff --git a/include/linux/rtnetlink.h b/include/linux/rtnetlink.h
index 4a629ea70cc4..1fae30af91f3 100644
--- a/include/linux/rtnetlink.h
+++ b/include/linux/rtnetlink.h
@@ -574,13 +574,6 @@ extern int rtattr_parse(struct rtattr *tb[], int maxattr, struct rtattr *rta, in
574#define rtattr_parse_nested(tb, max, rta) \ 574#define rtattr_parse_nested(tb, max, rta) \
575 rtattr_parse((tb), (max), RTA_DATA((rta)), RTA_PAYLOAD((rta))) 575 rtattr_parse((tb), (max), RTA_DATA((rta)), RTA_PAYLOAD((rta)))
576 576
577struct rtnetlink_link
578{
579 int (*doit)(struct sk_buff *, struct nlmsghdr*, void *attr);
580 int (*dumpit)(struct sk_buff *, struct netlink_callback *cb);
581};
582
583extern struct rtnetlink_link * rtnetlink_links[NPROTO];
584extern int rtnetlink_send(struct sk_buff *skb, u32 pid, u32 group, int echo); 577extern int rtnetlink_send(struct sk_buff *skb, u32 pid, u32 group, int echo);
585extern int rtnl_unicast(struct sk_buff *skb, u32 pid); 578extern int rtnl_unicast(struct sk_buff *skb, u32 pid);
586extern int rtnl_notify(struct sk_buff *skb, u32 pid, u32 group, 579extern int rtnl_notify(struct sk_buff *skb, u32 pid, u32 group,
@@ -605,7 +598,7 @@ extern void __rta_fill(struct sk_buff *skb, int attrtype, int attrlen, const voi
605 598
606#define RTA_PUT_NOHDR(skb, attrlen, data) \ 599#define RTA_PUT_NOHDR(skb, attrlen, data) \
607({ RTA_APPEND(skb, RTA_ALIGN(attrlen), data); \ 600({ RTA_APPEND(skb, RTA_ALIGN(attrlen), data); \
608 memset(skb->tail - (RTA_ALIGN(attrlen) - attrlen), 0, \ 601 memset(skb_tail_pointer(skb) - (RTA_ALIGN(attrlen) - attrlen), 0, \
609 RTA_ALIGN(attrlen) - attrlen); }) 602 RTA_ALIGN(attrlen) - attrlen); })
610 603
611#define RTA_PUT_U8(skb, attrtype, value) \ 604#define RTA_PUT_U8(skb, attrtype, value) \
@@ -637,12 +630,12 @@ extern void __rta_fill(struct sk_buff *skb, int attrtype, int attrlen, const voi
637 RTA_PUT(skb, attrtype, 0, NULL); 630 RTA_PUT(skb, attrtype, 0, NULL);
638 631
639#define RTA_NEST(skb, type) \ 632#define RTA_NEST(skb, type) \
640({ struct rtattr *__start = (struct rtattr *) (skb)->tail; \ 633({ struct rtattr *__start = (struct rtattr *)skb_tail_pointer(skb); \
641 RTA_PUT(skb, type, 0, NULL); \ 634 RTA_PUT(skb, type, 0, NULL); \
642 __start; }) 635 __start; })
643 636
644#define RTA_NEST_END(skb, start) \ 637#define RTA_NEST_END(skb, start) \
645({ (start)->rta_len = ((skb)->tail - (unsigned char *) (start)); \ 638({ (start)->rta_len = skb_tail_pointer(skb) - (unsigned char *)(start); \
646 (skb)->len; }) 639 (skb)->len; })
647 640
648#define RTA_NEST_CANCEL(skb, start) \ 641#define RTA_NEST_CANCEL(skb, start) \