diff options
author | Thomas Graf <tgraf@suug.ch> | 2007-03-23 02:30:55 -0400 |
---|---|---|
committer | David S. Miller <davem@sunset.davemloft.net> | 2007-04-26 01:27:33 -0400 |
commit | c702e8047fe74648f7852a9c1de781b0d5a98402 (patch) | |
tree | 24bd031d79f3d1159bc08704a51c84de01d712b0 /net/core | |
parent | ead592ba246dfcc643b3f0f0c8c03f7bc898a59f (diff) |
[NETLINK]: Directly return -EINTR from netlink_dump_start()
Now that all users of netlink_dump_start() use netlink_run_queue()
to process the receive queue, it is possible to return -EINTR from
netlink_dump_start() directly, therefore simplying the callers.
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/rtnetlink.c | 6 |
1 files changed, 1 insertions, 5 deletions
diff --git a/net/core/rtnetlink.c b/net/core/rtnetlink.c index 14241ada41a1..fa5f938b37ee 100644 --- a/net/core/rtnetlink.c +++ b/net/core/rtnetlink.c | |||
@@ -859,7 +859,6 @@ static int rtnetlink_rcv_msg(struct sk_buff *skb, struct nlmsghdr *nlh) | |||
859 | int min_len; | 859 | int min_len; |
860 | int family; | 860 | int family; |
861 | int type; | 861 | int type; |
862 | int err; | ||
863 | 862 | ||
864 | type = nlh->nlmsg_type; | 863 | type = nlh->nlmsg_type; |
865 | if (type > RTM_MAX) | 864 | if (type > RTM_MAX) |
@@ -888,10 +887,7 @@ static int rtnetlink_rcv_msg(struct sk_buff *skb, struct nlmsghdr *nlh) | |||
888 | if (dumpit == NULL) | 887 | if (dumpit == NULL) |
889 | return -EINVAL; | 888 | return -EINVAL; |
890 | 889 | ||
891 | err = netlink_dump_start(rtnl, skb, nlh, dumpit, NULL); | 890 | return netlink_dump_start(rtnl, skb, nlh, dumpit, NULL); |
892 | if (err == 0) | ||
893 | err = -EINTR; | ||
894 | return err; | ||
895 | } | 891 | } |
896 | 892 | ||
897 | memset(rta_buf, 0, (rtattr_max * sizeof(struct rtattr *))); | 893 | memset(rta_buf, 0, (rtattr_max * sizeof(struct rtattr *))); |