* [PATCH]: garp: retry sending JoinIn messages after allocation failures
@ 2008-07-15 13:02 Patrick McHardy
2008-07-17 3:52 ` David Miller
0 siblings, 1 reply; 2+ messages in thread
From: Patrick McHardy @ 2008-07-15 13:02 UTC (permalink / raw)
To: David S. Miller; +Cc: Linux Netdev List
[-- Attachment #1: Type: text/plain, Size: 0 bytes --]
[-- Attachment #2: 01.diff --]
[-- Type: text/x-diff, Size: 997 bytes --]
commit ca42e467171a856e008b754b72c3446b70a7c48d
Author: Patrick McHardy <kaber@trash.net>
Date: Tue Jul 15 15:00:44 2008 +0200
garp: retry sending JoinIn messages after allocation failures
Increase reliability by retrying to send JoinIn messages after memory
allocation failures on each TRANSMIT_PDU event until it succeeds.
Signed-off-by: Patrick McHardy <kaber@trash.net>
diff --git a/net/802/garp.c b/net/802/garp.c
index 3b78f7b..1dcb066 100644
--- a/net/802/garp.c
+++ b/net/802/garp.c
@@ -323,7 +323,10 @@ static void garp_attr_event(struct garp_applicant *app,
case GARP_ACTION_NONE:
break;
case GARP_ACTION_S_JOIN_IN:
- garp_pdu_append_attr(app, attr, GARP_JOIN_IN);
+ /* When appending the attribute fails, don't update state in
+ * order to retry on next TRANSMIT_PDU event. */
+ if (garp_pdu_append_attr(app, attr, GARP_JOIN_IN) < 0)
+ return;
break;
case GARP_ACTION_S_LEAVE_EMPTY:
garp_pdu_append_attr(app, attr, GARP_LEAVE_EMPTY);
^ permalink raw reply related [flat|nested] 2+ messages in thread
* Re: [PATCH]: garp: retry sending JoinIn messages after allocation failures
2008-07-15 13:02 [PATCH]: garp: retry sending JoinIn messages after allocation failures Patrick McHardy
@ 2008-07-17 3:52 ` David Miller
0 siblings, 0 replies; 2+ messages in thread
From: David Miller @ 2008-07-17 3:52 UTC (permalink / raw)
To: kaber; +Cc: netdev
From: Patrick McHardy <kaber@trash.net>
Date: Tue, 15 Jul 2008 15:02:51 +0200
> garp: retry sending JoinIn messages after allocation failures
>
> Increase reliability by retrying to send JoinIn messages after memory
> allocation failures on each TRANSMIT_PDU event until it succeeds.
>
> Signed-off-by: Patrick McHardy <kaber@trash.net>
Applied, thanks Patrick.
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2008-07-17 3:52 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2008-07-15 13:02 [PATCH]: garp: retry sending JoinIn messages after allocation failures Patrick McHardy
2008-07-17 3:52 ` David Miller
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).