diff options
Diffstat (limited to 'net/netlink')
-rw-r--r-- | net/netlink/af_netlink.c | 7 | ||||
-rw-r--r-- | net/netlink/genetlink.c | 7 |
2 files changed, 8 insertions, 6 deletions
diff --git a/net/netlink/af_netlink.c b/net/netlink/af_netlink.c index 1823b7c63156..2cbf1682f63d 100644 --- a/net/netlink/af_netlink.c +++ b/net/netlink/af_netlink.c | |||
@@ -1426,7 +1426,12 @@ int netlink_dump_start(struct sock *ssk, struct sk_buff *skb, | |||
1426 | 1426 | ||
1427 | netlink_dump(sk); | 1427 | netlink_dump(sk); |
1428 | sock_put(sk); | 1428 | sock_put(sk); |
1429 | return 0; | 1429 | |
1430 | /* We successfully started a dump, by returning -EINTR we | ||
1431 | * signal the queue mangement to interrupt processing of | ||
1432 | * any netlink messages so userspace gets a chance to read | ||
1433 | * the results. */ | ||
1434 | return -EINTR; | ||
1430 | } | 1435 | } |
1431 | 1436 | ||
1432 | void netlink_ack(struct sk_buff *in_skb, struct nlmsghdr *nlh, int err) | 1437 | void netlink_ack(struct sk_buff *in_skb, struct nlmsghdr *nlh, int err) |
diff --git a/net/netlink/genetlink.c b/net/netlink/genetlink.c index 1b897bc92e61..fac2e7a6dbe4 100644 --- a/net/netlink/genetlink.c +++ b/net/netlink/genetlink.c | |||
@@ -323,11 +323,8 @@ static int genl_rcv_msg(struct sk_buff *skb, struct nlmsghdr *nlh) | |||
323 | if (ops->dumpit == NULL) | 323 | if (ops->dumpit == NULL) |
324 | return -EOPNOTSUPP; | 324 | return -EOPNOTSUPP; |
325 | 325 | ||
326 | err = netlink_dump_start(genl_sock, skb, nlh, | 326 | return netlink_dump_start(genl_sock, skb, nlh, |
327 | ops->dumpit, ops->done); | 327 | ops->dumpit, ops->done); |
328 | if (err == 0) | ||
329 | err = -EINTR; | ||
330 | return err; | ||
331 | } | 328 | } |
332 | 329 | ||
333 | if (ops->doit == NULL) | 330 | if (ops->doit == NULL) |