Sophie

Sophie

distrib > Fedora > 15 > i386 > by-pkgid > 495bbe94e5126512132d69685e96e0d7 > files > 17

fcoe-utils-1.0.18-2.fc15.src.rpm

From 16b009e33b6fecab11a856428ada98288724fcbb Mon Sep 17 00:00:00 2001
From: Nithin Sujir <nsujir@broadcom.com>
Date: Wed, 30 Mar 2011 08:56:59 +0000
Subject: [PATCH 08/16] fcoemon: Unexpected FLOGI after fcoe port is destroyed

When fcoeadm -d is performed, fcoemon sets fcoe_enable=0 on the
physical port being destroyed but not on the vlan port. If a link toggle
occurs at this time, two link events are received, one each for physical
and vlan interfaces. The physical interface event is ignored due to
fcoe_enable=0 but the vlan event is processed and CREATE is called
resulting in unexpected FLOGI. This also puts the physical and vlan
ports out of sync and a subsequent fcoeadm -d is not processed.

Signed-off-by: Nithin Nayak Sujir <nsujir@broadcom.com>
Signed-off-by: Robert Love <robert.w.love@intel.com>
Signed-off-by: Petr Sabata <psabata@redhat.com>
---
 fcoemon.c |    4 +++-
 1 files changed, 3 insertions(+), 1 deletions(-)

diff --git a/fcoemon.c b/fcoemon.c
index 74795e4..77b3fd5 100644
--- a/fcoemon.c
+++ b/fcoemon.c
@@ -2049,8 +2049,10 @@ static void fcm_fcoe_action(struct fcm_netif *ff, struct fcoe_port *p)
 			/* destroy all the VLANs */
 			vp = fcm_find_fcoe_port(p->ifname, FCP_REAL_IFNAME);
 			while (vp) {
-				if (vp->auto_created)
+				if (vp->auto_created) {
+					vp->fcoe_enable = 0;
 					fcp_set_next_action(vp, FCP_DESTROY_IF);
+				}
 				vp = fcm_find_next_fcoe_port(vp, p->ifname);
 			}
 			rc = SUCCESS;
-- 
1.7.4.4