diff options
Diffstat (limited to 'include/linux/netlink.h')
-rw-r--r-- | include/linux/netlink.h | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/include/linux/netlink.h b/include/linux/netlink.h index 7c1f3b1d2ee5..fb0713b6ffaf 100644 --- a/include/linux/netlink.h +++ b/include/linux/netlink.h | |||
@@ -178,6 +178,7 @@ extern struct sock *netlink_kernel_create(struct net *net, | |||
178 | void (*input)(struct sk_buff *skb), | 178 | void (*input)(struct sk_buff *skb), |
179 | struct mutex *cb_mutex, | 179 | struct mutex *cb_mutex, |
180 | struct module *module); | 180 | struct module *module); |
181 | extern void netlink_kernel_release(struct sock *sk); | ||
181 | extern int netlink_change_ngroups(struct sock *sk, unsigned int groups); | 182 | extern int netlink_change_ngroups(struct sock *sk, unsigned int groups); |
182 | extern void netlink_clear_multicast_users(struct sock *sk, unsigned int group); | 183 | extern void netlink_clear_multicast_users(struct sock *sk, unsigned int group); |
183 | extern void netlink_ack(struct sk_buff *in_skb, struct nlmsghdr *nlh, int err); | 184 | extern void netlink_ack(struct sk_buff *in_skb, struct nlmsghdr *nlh, int err); |
@@ -192,7 +193,7 @@ extern int netlink_unregister_notifier(struct notifier_block *nb); | |||
192 | /* finegrained unicast helpers: */ | 193 | /* finegrained unicast helpers: */ |
193 | struct sock *netlink_getsockbyfilp(struct file *filp); | 194 | struct sock *netlink_getsockbyfilp(struct file *filp); |
194 | int netlink_attachskb(struct sock *sk, struct sk_buff *skb, int nonblock, | 195 | int netlink_attachskb(struct sock *sk, struct sk_buff *skb, int nonblock, |
195 | long timeo, struct sock *ssk); | 196 | long *timeo, struct sock *ssk); |
196 | void netlink_detachskb(struct sock *sk, struct sk_buff *skb); | 197 | void netlink_detachskb(struct sock *sk, struct sk_buff *skb); |
197 | int netlink_sendskb(struct sock *sk, struct sk_buff *skb); | 198 | int netlink_sendskb(struct sock *sk, struct sk_buff *skb); |
198 | 199 | ||
@@ -218,7 +219,7 @@ struct netlink_callback | |||
218 | int (*dump)(struct sk_buff * skb, struct netlink_callback *cb); | 219 | int (*dump)(struct sk_buff * skb, struct netlink_callback *cb); |
219 | int (*done)(struct netlink_callback *cb); | 220 | int (*done)(struct netlink_callback *cb); |
220 | int family; | 221 | int family; |
221 | long args[5]; | 222 | long args[6]; |
222 | }; | 223 | }; |
223 | 224 | ||
224 | struct netlink_notify | 225 | struct netlink_notify |
@@ -245,7 +246,7 @@ __nlmsg_put(struct sk_buff *skb, u32 pid, u32 seq, int type, int len, int flags) | |||
245 | } | 246 | } |
246 | 247 | ||
247 | #define NLMSG_NEW(skb, pid, seq, type, len, flags) \ | 248 | #define NLMSG_NEW(skb, pid, seq, type, len, flags) \ |
248 | ({ if (skb_tailroom(skb) < (int)NLMSG_SPACE(len)) \ | 249 | ({ if (unlikely(skb_tailroom(skb) < (int)NLMSG_SPACE(len))) \ |
249 | goto nlmsg_failure; \ | 250 | goto nlmsg_failure; \ |
250 | __nlmsg_put(skb, pid, seq, type, len, flags); }) | 251 | __nlmsg_put(skb, pid, seq, type, len, flags); }) |
251 | 252 | ||