aboutsummaryrefslogtreecommitdiffstats
path: root/net/core
diff options
context:
space:
mode:
authorThomas Graf <tgraf@suug.ch>2005-06-19 01:53:48 -0400
committerDavid S. Miller <davem@davemloft.net>2005-06-19 01:53:48 -0400
commit1797754ea7ee5e0d859b0a32506ff999f8d5fb71 (patch)
treea35d05f9106d903412a6fff714be38427fc4d0fa /net/core
parentaf0d114176720c2100dfa624ab433796d333d730 (diff)
[NETLINK]: Introduce NLMSG_NEW macro to better handle netlink flags
Introduces a new macro NLMSG_NEW which extends NLMSG_PUT but takes a flags argument. NLMSG_PUT stays there for compatibility but now calls NLMSG_NEW with flags == 0. NLMSG_PUT_ANSWER is renamed to NLMSG_NEW_ANSWER which now also takes a flags argument. Also converts the users of NLMSG_PUT_ANSWER to use NLMSG_NEW_ANSWER and fixes the two direct users of __nlmsg_put to either provide the flags or use NLMSG_NEW(_ANSWER). Signed-off-by: Thomas Graf <tgraf@suug.ch> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net/core')
-rw-r--r--net/core/neighbour.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/net/core/neighbour.c b/net/core/neighbour.c
index 2296a145fb78..0fb742e228cc 100644
--- a/net/core/neighbour.c
+++ b/net/core/neighbour.c
@@ -1590,8 +1590,8 @@ static int neightbl_fill_info(struct neigh_table *tbl, struct sk_buff *skb,
1590 struct nlmsghdr *nlh; 1590 struct nlmsghdr *nlh;
1591 struct ndtmsg *ndtmsg; 1591 struct ndtmsg *ndtmsg;
1592 1592
1593 nlh = NLMSG_PUT_ANSWER(skb, cb, RTM_NEWNEIGHTBL, sizeof(struct ndtmsg)); 1593 nlh = NLMSG_NEW_ANSWER(skb, cb, RTM_NEWNEIGHTBL, sizeof(struct ndtmsg),
1594 nlh->nlmsg_flags |= NLM_F_MULTI; 1594 NLM_F_MULTI);
1595 1595
1596 ndtmsg = NLMSG_DATA(nlh); 1596 ndtmsg = NLMSG_DATA(nlh);
1597 1597
@@ -1675,8 +1675,8 @@ static int neightbl_fill_param_info(struct neigh_table *tbl,
1675 struct ndtmsg *ndtmsg; 1675 struct ndtmsg *ndtmsg;
1676 struct nlmsghdr *nlh; 1676 struct nlmsghdr *nlh;
1677 1677
1678 nlh = NLMSG_PUT_ANSWER(skb, cb, RTM_NEWNEIGHTBL, sizeof(struct ndtmsg)); 1678 nlh = NLMSG_NEW_ANSWER(skb, cb, RTM_NEWNEIGHTBL, sizeof(struct ndtmsg),
1679 nlh->nlmsg_flags |= NLM_F_MULTI; 1679 NLM_F_MULTI);
1680 1680
1681 ndtmsg = NLMSG_DATA(nlh); 1681 ndtmsg = NLMSG_DATA(nlh);
1682 1682