All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] ipv6: Allow inet6_dump_addr() to handle more than 64 addresses
@ 2009-11-09 17:40 Eric Dumazet
  2009-11-11  6:33 ` David Miller
  0 siblings, 1 reply; 2+ messages in thread
From: Eric Dumazet @ 2009-11-09 17:40 UTC (permalink / raw)
  To: David S. Miller; +Cc: Linux Netdev List

Apparently, inet6_dump_addr() is not able to handle more than
64 ipv6 addresses per device. We must break from inner loops
in case skb is full, or else cursor is put at the end of list.

Signed-off-by: Eric Dumazet <eric.dumazet@gmail.com>
---
 net/ipv6/addrconf.c |    6 ++++++
 1 files changed, 6 insertions(+)

diff --git a/net/ipv6/addrconf.c b/net/ipv6/addrconf.c
index 024bba3..1b072fe 100644
--- a/net/ipv6/addrconf.c
+++ b/net/ipv6/addrconf.c
@@ -3519,6 +3519,8 @@ static int inet6_dump_addr(struct sk_buff *skb, struct netlink_callback *cb,
 							cb->nlh->nlmsg_seq,
 							RTM_NEWADDR,
 							NLM_F_MULTI);
+				if (err <= 0)
+					break;
 			}
 			break;
 		case MULTICAST_ADDR:
@@ -3532,6 +3534,8 @@ static int inet6_dump_addr(struct sk_buff *skb, struct netlink_callback *cb,
 							  cb->nlh->nlmsg_seq,
 							  RTM_GETMULTICAST,
 							  NLM_F_MULTI);
+				if (err <= 0)
+					break;
 			}
 			break;
 		case ANYCAST_ADDR:
@@ -3545,6 +3549,8 @@ static int inet6_dump_addr(struct sk_buff *skb, struct netlink_callback *cb,
 							  cb->nlh->nlmsg_seq,
 							  RTM_GETANYCAST,
 							  NLM_F_MULTI);
+				if (err <= 0)
+					break;
 			}
 			break;
 		default:

^ permalink raw reply related	[flat|nested] 2+ messages in thread

* Re: [PATCH] ipv6: Allow inet6_dump_addr() to handle more than 64 addresses
  2009-11-09 17:40 [PATCH] ipv6: Allow inet6_dump_addr() to handle more than 64 addresses Eric Dumazet
@ 2009-11-11  6:33 ` David Miller
  0 siblings, 0 replies; 2+ messages in thread
From: David Miller @ 2009-11-11  6:33 UTC (permalink / raw)
  To: eric.dumazet; +Cc: netdev

From: Eric Dumazet <eric.dumazet@gmail.com>
Date: Mon, 09 Nov 2009 18:40:17 +0100

> Apparently, inet6_dump_addr() is not able to handle more than
> 64 ipv6 addresses per device. We must break from inner loops
> in case skb is full, or else cursor is put at the end of list.
> 
> Signed-off-by: Eric Dumazet <eric.dumazet@gmail.com>

Applied to net-next-2.6

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2009-11-11  6:33 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2009-11-09 17:40 [PATCH] ipv6: Allow inet6_dump_addr() to handle more than 64 addresses Eric Dumazet
2009-11-11  6:33 ` David Miller

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.