patch-2.4.20 linux-2.4.20/net/bridge/br_stp.c

Next file: linux-2.4.20/net/core/dev.c
Previous file: linux-2.4.20/net/bridge/br_if.c
Back to the patch index
Back to the overall index

diff -urN linux-2.4.19/net/bridge/br_stp.c linux-2.4.20/net/bridge/br_stp.c
@@ -369,10 +369,19 @@
 static void br_make_forwarding(struct net_bridge_port *p)
 {
 	if (p->state == BR_STATE_BLOCKING) {
-		printk(KERN_INFO "%s: port %i(%s) entering %s state\n",
-		       p->br->dev.name, p->port_no, p->dev->name, "listening");
+		if (p->br->stp_enabled) {
+			printk(KERN_INFO "%s: port %i(%s) entering %s state\n",
+			       p->br->dev.name, p->port_no, p->dev->name,
+			       "listening");
 
-		p->state = BR_STATE_LISTENING;
+			p->state = BR_STATE_LISTENING;
+		} else {
+			printk(KERN_INFO "%s: port %i(%s) entering %s state\n",
+			       p->br->dev.name, p->port_no, p->dev->name,
+			       "learning");
+
+			p->state = BR_STATE_LEARNING;
+		}
 		br_timer_set(&p->forward_delay_timer, jiffies);
 	}
 }

FUNET's LINUX-ADM group, linux-adm@nic.funet.fi
TCL-scripts by Sam Shen (who was at: slshen@lbl.gov)