From patchwork Tue Mar 5 12:47:08 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Nitin Katiyar X-Patchwork-Id: 1051724 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Authentication-Results: ozlabs.org; spf=pass (mailfrom) smtp.mailfrom=openvswitch.org (client-ip=140.211.169.12; helo=mail.linuxfoundation.org; envelope-from=ovs-dev-bounces@openvswitch.org; receiver=) Authentication-Results: ozlabs.org; dmarc=fail (p=none dis=none) header.from=ericsson.com Authentication-Results: ozlabs.org; dkim=fail reason="signature verification failed" (1024-bit key; unprotected) header.d=ericsson.com header.i=@ericsson.com header.b="QDZvo8Tl"; dkim=fail reason="signature verification failed" (1024-bit key; unprotected) header.d=ericsson.com header.i=@ericsson.com header.b="K2Ivclr9"; dkim-atps=neutral Received: from mail.linuxfoundation.org (mail.linuxfoundation.org [140.211.169.12]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id 44DH7Q6hN7z9s3q for ; Wed, 6 Mar 2019 00:00:34 +1100 (AEDT) Received: from mail.linux-foundation.org (localhost [127.0.0.1]) by mail.linuxfoundation.org (Postfix) with ESMTP id 01D93F5AF; Tue, 5 Mar 2019 13:00:04 +0000 (UTC) X-Original-To: ovs-dev@openvswitch.org Delivered-To: ovs-dev@mail.linuxfoundation.org Received: from smtp1.linuxfoundation.org (smtp1.linux-foundation.org [172.17.192.35]) by mail.linuxfoundation.org (Postfix) with ESMTPS id 71BD4F59B for ; Tue, 5 Mar 2019 12:47:19 +0000 (UTC) X-Greylist: domain auto-whitelisted by SQLgrey-1.7.6 Received: from sesbmg23.ericsson.net (sesbmg23.ericsson.net [193.180.251.37]) by smtp1.linuxfoundation.org (Postfix) with ESMTPS id 039722D4 for ; Tue, 5 Mar 2019 12:47:16 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; d=ericsson.com; s=mailgw201801; c=relaxed/relaxed; q=dns/txt; i=@ericsson.com; t=1551790035; x=1554382035; h=From:Sender:Reply-To:Subject:Date:Message-ID:To:CC:MIME-Version:Content-Type: Content-Transfer-Encoding:Content-ID:Content-Description:Resent-Date:Resent-From: Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:In-Reply-To:References:List-Id: List-Help:List-Unsubscribe:List-Subscribe:List-Post:List-Owner:List-Archive; bh=uVCLH8SMyLIH29dlq/bSpAkXIx6jXk5LY+oAHAFenvM=; b=QDZvo8TleLmAE6DkOAbWnZJl1jRTBC5KoRroDKqT+efJBtiP/DICJmmtezH1nFeH 9JqB4d9vgmUzxDpYew558YdzGzIYOgrh0BGAGmvxmtL4fraDHSLT+DGnaAe/6JQ9 +cSZG5Vdn2+ggXmgIIinqy1eYOShCK3lU4NIiA6U1sw=; X-AuditID: c1b4fb25-209009e000005ff7-13-5c7e6fce695f Received: from ESESSMB501.ericsson.se (Unknown_Domain [153.88.183.119]) by sesbmg23.ericsson.net (Symantec Mail Security) with SMTP id 90.BB.24567.ECF6E7C5; Tue, 5 Mar 2019 13:47:10 +0100 (CET) Received: from ESESSMR505.ericsson.se (153.88.183.127) by ESESSMB501.ericsson.se (153.88.183.162) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256_P256) id 15.1.1466.3; Tue, 5 Mar 2019 13:47:10 +0100 Received: from ESESSMB501.ericsson.se (153.88.183.162) by ESESSMR505.ericsson.se (153.88.183.127) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256_P256) id 15.1.1466.3; Tue, 5 Mar 2019 13:47:10 +0100 Received: from EUR02-HE1-obe.outbound.protection.outlook.com (153.88.183.157) by ESESSMB501.ericsson.se (153.88.183.162) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256_P256) id 15.1.1466.3 via Frontend Transport; Tue, 5 Mar 2019 13:47:10 +0100 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=ericsson.com; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=uVCLH8SMyLIH29dlq/bSpAkXIx6jXk5LY+oAHAFenvM=; b=K2Ivclr9jLqI4/E/W8yVbXpLCmMZBOzWy2d+PUPxwcEEog4qy8Fnv2lprrj8IX6DZqwaShUldj5c8zTFN8qH6dYJW09nCibR7AuH6WWHrPvXUzr98ddso+fS/E6MHc/Y245bWY0cZoxUbmToTl8NjyI0nPTxinogOcD8OWC+BZM= Received: from HE1PR0702MB3626.eurprd07.prod.outlook.com (52.133.6.24) by HE1PR0702MB3564.eurprd07.prod.outlook.com (52.133.6.11) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.1686.15; Tue, 5 Mar 2019 12:47:09 +0000 Received: from HE1PR0702MB3626.eurprd07.prod.outlook.com ([fe80::b049:e8c6:251c:5ed7]) by HE1PR0702MB3626.eurprd07.prod.outlook.com ([fe80::b049:e8c6:251c:5ed7%4]) with mapi id 15.20.1686.016; Tue, 5 Mar 2019 12:47:09 +0000 From: Nitin Katiyar To: "ovs-dev@openvswitch.org" Thread-Topic: [PATCH v5 1/2] Avoid packet drop on LACP bond after link up Thread-Index: AQHU01GLXA35nYFkCE2tT/ROT8uiFw== Date: Tue, 5 Mar 2019 12:47:08 +0000 Message-ID: <1551818911-10884-1-git-send-email-nitin.katiyar@ericsson.com> Accept-Language: en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: x-originating-ip: [125.16.213.150] x-mailer: git-send-email 1.9.1 x-clientproxiedby: BMXPR01CA0006.INDPRD01.PROD.OUTLOOK.COM (2603:1096:b00:d::16) To HE1PR0702MB3626.eurprd07.prod.outlook.com (2603:10a6:7:8c::24) authentication-results: spf=none (sender IP is ) smtp.mailfrom=nitin.katiyar@ericsson.com; x-ms-exchange-messagesentrepresentingtype: 1 x-ms-publictraffictype: Email x-ms-office365-filtering-correlation-id: dae0d555-fda6-4e1b-4e1d-08d6a168add4 x-microsoft-antispam: BCL:0; PCL:0; RULEID:(2390118)(7020095)(4652040)(8989299)(4534185)(7168020)(4627221)(201703031133081)(201702281549075)(8990200)(5600127)(711020)(4605104)(2017052603328)(7153060)(7193020); SRVR:HE1PR0702MB3564; x-ms-traffictypediagnostic: HE1PR0702MB3564: x-microsoft-exchange-diagnostics: =?iso-8859-1?Q?1; HE1PR0702MB3564; 23:4kPgEnndpsu4t9gtdJA3XCtqUeNi2FKJz4uKJ?= =?iso-8859-1?q?53+xO+OI5/PrsFxqR9UOX9u6e?= =?iso-8859-1?q?uSlLbYDTcXGdS5+MtVS97Lx/zcW/AsbuEi+ucUoPRFFYZMIQBy1?= =?iso-8859-1?q?jAWUE8Fj4R9i/GYsVmFJMWh8SW3P82KqtLetiyFHltlBLTZUCF/?= =?iso-8859-1?q?IduCQYeeP3PsjvJz44TJ830IYHx6TIZcQdKSwUV8n9nQ1TqoOBB?= =?iso-8859-1?q?LYwdX3xP0EnfAAwLqVV1G8vH0b1ygTXg2ojGHCAZdRyeAvOzlSk?= =?iso-8859-1?q?RSC/jh9TY/FPqI2hPEERxkdpdklZ7ItwLI1wARBHL3hZUUMr0O/?= =?iso-8859-1?q?mvDxbP6pSeMjxjxkNYPDrsA5fvKT6WtPY77eu8XhWpVm7GP4Ws1?= =?iso-8859-1?q?j1wfpme1ODHPjTPyyWe5yfiLA7RnMMiVIpHlI33l4TjXd8KEriD?= =?iso-8859-1?q?/klKky6BMISuah1UfMhWedNXV/P4xmqKE/5SdzLw1K1C04fTuk4?= =?iso-8859-1?q?71kOQv6bv7bv/10+yoGIuwZVZaIJ27W+n48ulQuUhgomPNRPIbu?= =?iso-8859-1?q?U0VQpNHWpvhZdFmdl9D9cCHIm/eqm9RdjTSdQFCVuR/Yc4X7ad9?= =?iso-8859-1?q?yVrAS+Xdjsd9RYDmLOA4jbiWcZN3twrqONbMpr6FOIBc0C1IEaw?= =?iso-8859-1?q?K6FtmqB1qwdRuZhWYCLWZpLnmsJRz8Kki0nATmtkYRcTO6r7Tl+?= =?iso-8859-1?q?2ut4ru9Z+txYYZ+krLdDnxE7wdKzGwhM0ZXSCntRPa8lFa2dID8?= =?iso-8859-1?q?QZ+26A2BdxBHlf8Nn7UggkJW7ft3TEuCroHbIZSffY2ETzyUY2V?= =?iso-8859-1?q?ws/KBT7J8jpy4dn67/IhS0mgb38C5A/IHVpbGDU3yFLYFnHJGV4?= =?iso-8859-1?q?UuGbFWLPZH4MsjqqFe4zPmdQfhHN1RUMiOjRN0SocAIXVHcXJsS?= =?iso-8859-1?q?G0YhFEQg14KmDdBXHmduaSxJRpdm8pjyK9KGRyshiknmWOELDv2?= =?iso-8859-1?q?at2AHQPY9I7tFD1KzlwrKZe5mGG1O2OVe4uInKTQbB0WTH1AhwG?= =?iso-8859-1?q?AzXg095eR8XwjC6KKbTxjwciR+Eb4PXJVuQl5neYJpAwgYfKulY?= =?iso-8859-1?q?JBOBVofHoyezXlDkF4oVSvt5XWVK5DsYkR+LtUDICYKWfAuY6Lu?= =?iso-8859-1?q?B7Dg9lN15QoTgTLKpcTQdiMG0MeZOjU2A7E3i/1OdguPro6Mhe3?= =?iso-8859-1?q?/GixgmFZ1Y53PNMdeFmgz/jta88+A4U++SEJAnzV39iqST5fjVR?= =?iso-8859-1?q?2aa/M0ki2RxXwvEV4e0/Pb7S7EPW5fTIHFmvi+65HvQnFWNIOQ9?= =?iso-8859-1?q?4S3NmeStbk+0yKZ8JB2IEE/w=3D?= x-microsoft-antispam-prvs: x-forefront-prvs: 0967749BC1 x-forefront-antispam-report: SFV:NSPM; SFS:(10009020)(366004)(39860400002)(346002)(136003)(396003)(376002)(199004)(189003)(26005)(86362001)(476003)(5640700003)(6506007)(7736002)(386003)(305945005)(97736004)(5660300002)(81166006)(8936002)(68736007)(50226002)(486006)(8676002)(81156014)(2616005)(66066001)(44832011)(53936002)(186003)(3846002)(52116002)(14444005)(54906003)(36756003)(6916009)(105586002)(6512007)(316002)(256004)(25786009)(106356001)(99286004)(71200400001)(71190400001)(6436002)(2501003)(14454004)(2906002)(4326008)(478600001)(2351001)(102836004)(55236004)(6116002)(6486002); DIR:OUT; SFP:1101; SCL:1; SRVR:HE1PR0702MB3564; H:HE1PR0702MB3626.eurprd07.prod.outlook.com; FPR:; SPF:None; LANG:en; PTR:InfoNoRecords; A:1; MX:1; received-spf: None (protection.outlook.com: ericsson.com does not designate permitted sender hosts) x-ms-exchange-senderadcheck: 1 x-microsoft-antispam-message-info: 5YRo/RphtKAEgtVWj5I7EMav9FlBEXACshU1rIGgffLVxufvkXMEbNPcWWXt4uU0LrDmWVLvf0/4p74DCuI4bq917qGS/Xa+/LwFK0ylf/qqfbaqiCPHY9sSr9KHxj7BliOjR3vTpJiiQvjmr6BlbeqKSIA188bz/ejUNQxo1XcFLyOC4KsmW/axDjD/VxTlkKRgNvizNd7WTO1XJtpDV1KjWMFjIpQ3espQ+Fem9BZTE1NPG2qX1eodmmi99szSRZ8Aq0zF5n2oW6x1ud7oMSxOqSdYrl/rRBx2pDSXLqVvL2mU6uissC1bpjVGENmjfmFAaug3LxeNUqewasIzDT2jlJ/3aTuJwmlvZVM95mSEDEm3rRgng2I/dstQ415U8wXyQ6dPiTXUbt7zKLWWWGrGv40P78Q6jJo9vHqDSnc= MIME-Version: 1.0 X-MS-Exchange-CrossTenant-Network-Message-Id: dae0d555-fda6-4e1b-4e1d-08d6a168add4 X-MS-Exchange-CrossTenant-originalarrivaltime: 05 Mar 2019 12:47:08.8519 (UTC) X-MS-Exchange-CrossTenant-fromentityheader: Hosted X-MS-Exchange-CrossTenant-id: 92e84ceb-fbfd-47ab-be52-080c6b87953f X-MS-Exchange-CrossTenant-mailboxtype: HOSTED X-MS-Exchange-Transport-CrossTenantHeadersStamped: HE1PR0702MB3564 X-OriginatorOrg: ericsson.com X-Brightmail-Tracker: H4sIAAAAAAAAA+NgFupgleLIzCtJLcpLzFFi42KZGbG9XPdyfl2Mwa4LghZP3z5mtJj76Tmj A5PHzll32T2e3fzPGMAUxWWTkpqTWZZapG+XwJWx+MsOtoKpNhVn22ezNzC+1+li5OSQEDCR 2HHgI2MXIxeHkMARRom/yxtYIZyvjBJH+7Yzwzn/1x9ig3AWM0m8fLUArIdFYAKzxI1djewQ mUlMEruvT4Qa8JRRYs+G9awga9gEDCS2X5zEDmKLCJhLnPhwDsxmFsiU+HdqDSOILSzgIjH7 7CGoGk+Jd7vesEHYehI3711nAbFZBFQkTq3czwRi8wp4SezcfhtsPqOAmMT3U2uYIGaKS9x6 Mp8J4j0BiSV7zjND2KISLx//Y4WwlSQurlnMDmHLSSxefRnsNwmBaYwSt2edYYQYGivx7vFT qAYdibPXnzBC2LISl+Z3Q9m+Eqfn/IVqfsIo8WzRJriG811X2SES73glfv59zAaRyJeYPeUo UDcHkC0j8f4L+wRG/VlIDoew9SRuTJ3CBmFrSyxb+Jp5FtjTghInZz5hWcDIsopRtDi1OCk3 3chYL7UoM7m4OD9PLy+1ZBMjMH0c3PJbdQfj5TeOhxgFOBiVeHiPZtfFCLEmlhVX5h5ilOBg VhLh/SMOFOJNSaysSi3Kjy8qzUktPsQozcGiJM77R0gwRkggPbEkNTs1tSC1CCbLxMEp1cDI MtnIIlP/f/LMF4/ibvmn9btW3IxgF1DVU7lov2mJ2ytTnaCH36fXLv2UJinyVGbj1/kHhWum bIxQ8fy+vU7p6rq+eR+2Fu+XV43av+LR9HO6+tFKqS+vV0+/oNqR5Jzr8iLHg/PO6smbIjoi W/UYNT6f+GXYx7300Le9F/wkxaedETmUtcBLiaU4I9FQi7moOBEA2onL2RsDAAA= X-Spam-Status: No, score=-4.3 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, RCVD_IN_DNSWL_MED autolearn=ham version=3.3.1 X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on smtp1.linux-foundation.org Cc: Manohar Krishnappa Chidambaraswamy , Nitin Katiyar Subject: [ovs-dev] [PATCH v5 1/2] Avoid packet drop on LACP bond after link up X-BeenThere: ovs-dev@openvswitch.org X-Mailman-Version: 2.1.12 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: ovs-dev-bounces@openvswitch.org Errors-To: ovs-dev-bounces@openvswitch.org Problem: ======== During port DOWN->UP of link (slave) in a LACP bond, after receiving the LACP PDU with SYNC set for both actor and partner, the bond-slave remains "disabled" until OVS main thread runs LACP state machine and eventually "enables" the bond-slave. With this, we have observed delays in the order of 350ms and packets are dropped in OVS due to bond-admissibility check (packets received on slave in "disabled" state are dropped). Fix: ==== When a LACP PDU is received, evaluate whether LACP slave can be enabled (slave_may_enable()) and set LACP slave's may_enable from the datapath thread itself. When may_enable = TRUE, it means L1 state is UP and LACP-SYNC is done and it is waiting for the main thread to enable the slave. Relax the check in bond_check_admissibility() to check for both "enable" and "may_enable" of the LACP slave. This would avoid dropping of packets until the main thread enables the slave from bundle_run(). Signed-off-by: Manohar Krishnappa Chidambaraswamy Co-authored-by: Manohar Krishnappa Chidambaraswamy Signed-off-by: Nitin Katiyar --- lib/lacp.c | 10 +++++++++- lib/lacp.h | 2 +- ofproto/bond.c | 22 +++++++++++++++++++--- ofproto/ofproto-dpif-xlate.c | 10 +++++++++- 4 files changed, 38 insertions(+), 6 deletions(-) diff --git a/lib/lacp.c b/lib/lacp.c index d6b36aa..e768012 100644 --- a/lib/lacp.c +++ b/lib/lacp.c @@ -154,6 +154,7 @@ static struct slave *slave_lookup(const struct lacp *, const void *slave) OVS_REQUIRES(mutex); static bool info_tx_equal(struct lacp_info *, struct lacp_info *) OVS_REQUIRES(mutex); +static bool slave_may_enable__(struct slave *slave) OVS_REQUIRES(mutex); static unixctl_cb_func lacp_unixctl_show; static unixctl_cb_func lacp_unixctl_show_stats; @@ -324,7 +325,7 @@ lacp_is_active(const struct lacp *lacp) OVS_EXCLUDED(mutex) /* Processes 'packet' which was received on 'slave_'. This function should be * called on all packets received on 'slave_' with Ethernet Type ETH_TYPE_LACP. */ -void +bool lacp_process_packet(struct lacp *lacp, const void *slave_, const struct dp_packet *packet) OVS_EXCLUDED(mutex) @@ -333,6 +334,7 @@ lacp_process_packet(struct lacp *lacp, const void *slave_, const struct lacp_pdu *pdu; long long int tx_rate; struct slave *slave; + bool lacp_may_enable = false; lacp_lock(); slave = slave_lookup(lacp, slave_); @@ -362,8 +364,14 @@ lacp_process_packet(struct lacp *lacp, const void *slave_, slave->partner = pdu->actor; } + /* Evaluate may_enable here to avoid dropping of packets till main thread + * sets may_enable to true. */ + lacp_may_enable = slave_may_enable__(slave); + out: lacp_unlock(); + + return lacp_may_enable; } /* Returns the lacp_status of the given 'lacp' object (which may be NULL). */ diff --git a/lib/lacp.h b/lib/lacp.h index f35cff5..0dfaef0 100644 --- a/lib/lacp.h +++ b/lib/lacp.h @@ -46,7 +46,7 @@ struct lacp *lacp_ref(const struct lacp *); void lacp_configure(struct lacp *, const struct lacp_settings *); bool lacp_is_active(const struct lacp *); -void lacp_process_packet(struct lacp *, const void *slave, +bool lacp_process_packet(struct lacp *, const void *slave, const struct dp_packet *packet); enum lacp_status lacp_status(const struct lacp *); diff --git a/ofproto/bond.c b/ofproto/bond.c index d2a8b1f..c5d5f2c 100644 --- a/ofproto/bond.c +++ b/ofproto/bond.c @@ -794,6 +794,7 @@ bond_check_admissibility(struct bond *bond, const void *slave_, { enum bond_verdict verdict = BV_DROP; struct bond_slave *slave; + static struct vlog_rate_limit rl = VLOG_RATE_LIMIT_INIT(1, 5); ovs_rwlock_rdlock(&rwlock); slave = bond_slave_lookup(bond, slave_); @@ -811,7 +812,11 @@ bond_check_admissibility(struct bond *bond, const void *slave_, * drop all incoming traffic except if lacp_fallback_ab is enabled. */ switch (bond->lacp_status) { case LACP_NEGOTIATED: - verdict = slave->enabled ? BV_ACCEPT : BV_DROP; + /* To reduce packet-drops due to delay in enabling of slave (post + * LACP-SYNC), from main thread, check for may_enable as well. + * When may_enable is TRUE, it means LACP is UP and waiting for the + * main thread to run LACP state machine and enable the slave. */ + verdict = (slave->enabled || slave->may_enable) ? BV_ACCEPT : BV_DROP; goto out; case LACP_CONFIGURED: if (!bond->lacp_fallback_ab) { @@ -847,8 +852,6 @@ bond_check_admissibility(struct bond *bond, const void *slave_, /* Drop all packets which arrive on backup slaves. This is similar to * how Linux bonding handles active-backup bonds. */ if (bond->active_slave != slave) { - static struct vlog_rate_limit rl = VLOG_RATE_LIMIT_INIT(1, 5); - VLOG_DBG_RL(&rl, "active-backup bond received packet on backup" " slave (%s) destined for " ETH_ADDR_FMT, slave->name, ETH_ADDR_ARGS(eth_dst)); @@ -870,6 +873,19 @@ bond_check_admissibility(struct bond *bond, const void *slave_, OVS_NOT_REACHED(); out: + if (slave && (verdict != BV_ACCEPT)) { + VLOG_DBG_RL(&rl, "slave (%s): Admissibility verdict is to drop pkt %s." + "active slave: %s, may_enable: %s enable: %s " + "LACP status:%d", + slave->name, + (verdict == BV_DROP_IF_MOVED) ? + "as different port is learned" : "", + (bond->active_slave == slave) ? "true" : "false", + slave->may_enable ? "true" : "false", + slave->enabled ? "true" : "false", + bond->lacp_status); + } + ovs_rwlock_unlock(&rwlock); return verdict; diff --git a/ofproto/ofproto-dpif-xlate.c b/ofproto/ofproto-dpif-xlate.c index c4014d7..8f44566 100644 --- a/ofproto/ofproto-dpif-xlate.c +++ b/ofproto/ofproto-dpif-xlate.c @@ -3307,6 +3307,7 @@ process_special(struct xlate_ctx *ctx, const struct xport *xport) const struct xbridge *xbridge = ctx->xbridge; const struct dp_packet *packet = ctx->xin->packet; enum slow_path_reason slow; + bool lacp_may_enable; if (!xport) { slow = 0; @@ -3327,7 +3328,14 @@ process_special(struct xlate_ctx *ctx, const struct xport *xport) } else if (xport->xbundle && xport->xbundle->lacp && flow->dl_type == htons(ETH_TYPE_LACP)) { if (packet) { - lacp_process_packet(xport->xbundle->lacp, xport->ofport, packet); + lacp_may_enable = lacp_process_packet(xport->xbundle->lacp, + xport->ofport, packet); + /* Update LACP status in bond-slave to avoid packet-drops until + * LACP state machine is run by the main thread. */ + if (xport->xbundle->bond && lacp_may_enable) { + bond_slave_set_may_enable(xport->xbundle->bond, xport->ofport, + lacp_may_enable); + } } slow = SLOW_LACP; } else if ((xbridge->stp || xbridge->rstp) &&