aboutsummaryrefslogtreecommitdiffstats
path: root/net/netlink
diff options
context:
space:
mode:
Diffstat (limited to 'net/netlink')
-rw-r--r--net/netlink/genetlink.c17
1 files changed, 8 insertions, 9 deletions
diff --git a/net/netlink/genetlink.c b/net/netlink/genetlink.c
index 0249a56a9aa..8903ef93db5 100644
--- a/net/netlink/genetlink.c
+++ b/net/netlink/genetlink.c
@@ -384,6 +384,13 @@ static void genl_rcv(struct sock *sk, int len)
384 * Controller 384 * Controller
385 **************************************************************************/ 385 **************************************************************************/
386 386
387static struct genl_family genl_ctrl = {
388 .id = GENL_ID_CTRL,
389 .name = "nlctrl",
390 .version = 0x1,
391 .maxattr = CTRL_ATTR_MAX,
392};
393
387static int ctrl_fill_info(struct genl_family *family, u32 pid, u32 seq, 394static int ctrl_fill_info(struct genl_family *family, u32 pid, u32 seq,
388 u32 flags, struct sk_buff *skb, u8 cmd) 395 u32 flags, struct sk_buff *skb, u8 cmd)
389{ 396{
@@ -392,8 +399,7 @@ static int ctrl_fill_info(struct genl_family *family, u32 pid, u32 seq,
392 void *hdr; 399 void *hdr;
393 int idx = 1; 400 int idx = 1;
394 401
395 hdr = genlmsg_put(skb, pid, seq, GENL_ID_CTRL, 0, flags, cmd, 402 hdr = genlmsg_put(skb, pid, seq, &genl_ctrl, flags, cmd);
396 family->version);
397 if (hdr == NULL) 403 if (hdr == NULL)
398 return -1; 404 return -1;
399 405
@@ -562,13 +568,6 @@ static struct genl_ops genl_ctrl_ops = {
562 .policy = ctrl_policy, 568 .policy = ctrl_policy,
563}; 569};
564 570
565static struct genl_family genl_ctrl = {
566 .id = GENL_ID_CTRL,
567 .name = "nlctrl",
568 .version = 0x1,
569 .maxattr = CTRL_ATTR_MAX,
570};
571
572static int __init genl_init(void) 571static int __init genl_init(void)
573{ 572{
574 int i, err; 573 int i, err;