diff options
Diffstat (limited to 'net/ipv6/ip6mr.c')
| -rw-r--r-- | net/ipv6/ip6mr.c | 13 |
1 files changed, 8 insertions, 5 deletions
diff --git a/net/ipv6/ip6mr.c b/net/ipv6/ip6mr.c index 0eb4038a4d63..8737400af0a0 100644 --- a/net/ipv6/ip6mr.c +++ b/net/ipv6/ip6mr.c | |||
| @@ -2349,13 +2349,14 @@ int ip6mr_get_route(struct net *net, | |||
| 2349 | } | 2349 | } |
| 2350 | 2350 | ||
| 2351 | static int ip6mr_fill_mroute(struct mr6_table *mrt, struct sk_buff *skb, | 2351 | static int ip6mr_fill_mroute(struct mr6_table *mrt, struct sk_buff *skb, |
| 2352 | u32 portid, u32 seq, struct mfc6_cache *c, int cmd) | 2352 | u32 portid, u32 seq, struct mfc6_cache *c, int cmd, |
| 2353 | int flags) | ||
| 2353 | { | 2354 | { |
| 2354 | struct nlmsghdr *nlh; | 2355 | struct nlmsghdr *nlh; |
| 2355 | struct rtmsg *rtm; | 2356 | struct rtmsg *rtm; |
| 2356 | int err; | 2357 | int err; |
| 2357 | 2358 | ||
| 2358 | nlh = nlmsg_put(skb, portid, seq, cmd, sizeof(*rtm), NLM_F_MULTI); | 2359 | nlh = nlmsg_put(skb, portid, seq, cmd, sizeof(*rtm), flags); |
| 2359 | if (nlh == NULL) | 2360 | if (nlh == NULL) |
| 2360 | return -EMSGSIZE; | 2361 | return -EMSGSIZE; |
| 2361 | 2362 | ||
| @@ -2423,7 +2424,7 @@ static void mr6_netlink_event(struct mr6_table *mrt, struct mfc6_cache *mfc, | |||
| 2423 | if (skb == NULL) | 2424 | if (skb == NULL) |
| 2424 | goto errout; | 2425 | goto errout; |
| 2425 | 2426 | ||
| 2426 | err = ip6mr_fill_mroute(mrt, skb, 0, 0, mfc, cmd); | 2427 | err = ip6mr_fill_mroute(mrt, skb, 0, 0, mfc, cmd, 0); |
| 2427 | if (err < 0) | 2428 | if (err < 0) |
| 2428 | goto errout; | 2429 | goto errout; |
| 2429 | 2430 | ||
| @@ -2462,7 +2463,8 @@ static int ip6mr_rtm_dumproute(struct sk_buff *skb, struct netlink_callback *cb) | |||
| 2462 | if (ip6mr_fill_mroute(mrt, skb, | 2463 | if (ip6mr_fill_mroute(mrt, skb, |
| 2463 | NETLINK_CB(cb->skb).portid, | 2464 | NETLINK_CB(cb->skb).portid, |
| 2464 | cb->nlh->nlmsg_seq, | 2465 | cb->nlh->nlmsg_seq, |
| 2465 | mfc, RTM_NEWROUTE) < 0) | 2466 | mfc, RTM_NEWROUTE, |
| 2467 | NLM_F_MULTI) < 0) | ||
| 2466 | goto done; | 2468 | goto done; |
| 2467 | next_entry: | 2469 | next_entry: |
| 2468 | e++; | 2470 | e++; |
| @@ -2476,7 +2478,8 @@ next_entry: | |||
| 2476 | if (ip6mr_fill_mroute(mrt, skb, | 2478 | if (ip6mr_fill_mroute(mrt, skb, |
| 2477 | NETLINK_CB(cb->skb).portid, | 2479 | NETLINK_CB(cb->skb).portid, |
| 2478 | cb->nlh->nlmsg_seq, | 2480 | cb->nlh->nlmsg_seq, |
| 2479 | mfc, RTM_NEWROUTE) < 0) { | 2481 | mfc, RTM_NEWROUTE, |
| 2482 | NLM_F_MULTI) < 0) { | ||
| 2480 | spin_unlock_bh(&mfc_unres_lock); | 2483 | spin_unlock_bh(&mfc_unres_lock); |
| 2481 | goto done; | 2484 | goto done; |
| 2482 | } | 2485 | } |
