Patchwork [Open-FCoE] FIPVLAN: Really break out of the recv_loop upon fip_recv error

login
register
mail settings
Submitter Eddie Wai
Date March 5, 2014, 6:42 a.m.
Message ID <1394001748-22869-1-git-send-email-eddie.wai@broadcom.com>
Download mbox | patch
Permalink /patch/143/
State Accepted
Headers show

Comments

Eddie Wai - March 5, 2014, 6:42 a.m.
This patch adds additional code to break out of the recv_loop's while
loop upon fip_recv error.  This completes the fix from
commit 78ea81aaef57b5b40fdc86335a7e6a432a72ad48.

Without this, we have seen cases where the recv_loop gets
stuck looping indefinitely.


Signed-off-by: Eddie Wai <eddie.wai@broadcom.com>
---
 fipvlan.c |    2 ++
 1 files changed, 2 insertions(+), 0 deletions(-)

Patch

diff --git a/fipvlan.c b/fipvlan.c
index 1b8492d..cc71412 100644
--- a/fipvlan.c
+++ b/fipvlan.c
@@ -792,6 +792,8 @@  static void recv_loop(int timeout)
 					break;
 			}
 		}
+		if (i < pfd_len)
+			break;
 	}
 }