From: jamal <hadi@cyberus.ca>
To: David Miller <davem@davemloft.net>
Cc: netdev@vger.kernel.org, Thomas Graf <tgraf@suug.ch>
Subject: [PATCH 2/2][GENETLINK] add cmd dump completion
Date: Fri, 01 Dec 2006 06:33:48 -0500 [thread overview]
Message-ID: <1164972828.3562.11.camel@localhost> (raw)
[-- Attachment #1: Type: text/plain, Size: 108 bytes --]
Sorry, subject was a little messed in the previous one, but should
be fine going forward ..
cheers,
jamal
[-- Attachment #2: gnl-dec1-2 --]
[-- Type: text/plain, Size: 1681 bytes --]
[GENETLINK] add cmd dump completion
Remove assumption that generic netlink commands cannot have dump
completion callbacks.
Signed-off-by: Jamal Hadi Salim<hadi@cyberus.ca>
---
commit 7df98e8c6358e7e8483279904823b7bb7bcf8e50
tree 774cd008cbfb4f981e30064da301b8fc7f9476f6
parent 349e0e00396b79d8f2f9a41f6dc28dee9e7d3e3e
author Jamal Hadi Salim <hadi@cyberus.ca> Fri, 01 Dec 2006 06:14:20 -0500
committer Jamal Hadi Salim <hadi@cyberus.ca> Fri, 01 Dec 2006 06:14:20 -0500
include/net/genetlink.h | 2 ++
net/netlink/genetlink.c | 2 +-
2 files changed, 3 insertions(+), 1 deletions(-)
diff --git a/include/net/genetlink.h b/include/net/genetlink.h
index 7fd131c..adff4c8 100644
--- a/include/net/genetlink.h
+++ b/include/net/genetlink.h
@@ -53,6 +53,7 @@ struct genl_info
* @policy: attribute validation policy
* @doit: standard command callback
* @dumpit: callback for dumpers
+ * @done: completion callback for dumps
* @ops_list: operations list
*/
struct genl_ops
@@ -64,6 +65,7 @@ struct genl_ops
struct genl_info *info);
int (*dumpit)(struct sk_buff *skb,
struct netlink_callback *cb);
+ int (*done)(struct netlink_callback *cb);
struct list_head ops_list;
};
diff --git a/net/netlink/genetlink.c b/net/netlink/genetlink.c
index 50928da..96b6820 100644
--- a/net/netlink/genetlink.c
+++ b/net/netlink/genetlink.c
@@ -338,7 +338,7 @@ static int genl_rcv_msg(struct sk_buff *skb, struct nlmsghdr *nlh,
}
*errp = err = netlink_dump_start(genl_sock, skb, nlh,
- ops->dumpit, NULL);
+ ops->dumpit, ops->done);
if (err == 0)
skb_pull(skb, min(NLMSG_ALIGN(nlh->nlmsg_len),
skb->len));
next reply other threads:[~2006-12-01 11:33 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2006-12-01 11:33 jamal [this message]
2006-12-01 12:50 ` [PATCH 2/2][GENETLINK] add cmd dump completion Thomas Graf
2006-12-02 4:07 ` David Miller
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1164972828.3562.11.camel@localhost \
--to=hadi@cyberus.ca \
--cc=davem@davemloft.net \
--cc=netdev@vger.kernel.org \
--cc=tgraf@suug.ch \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).