From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from EUR01-DB5-obe.outbound.protection.outlook.com (mail-db5eur01on0043.outbound.protection.outlook.com [104.47.2.43]) by dpdk.org (Postfix) with ESMTP id 726352C24; Thu, 3 May 2018 12:32:17 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=Mellanox.com; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version; bh=gbozHQnWJM+PgEUULuIx+aQ9sd0nQ24aNEpi7YOJDE8=; b=KLh4wdckupSYrtJVkZRBQY/+fn1nHo7gp1/jqS/iXdIblG2t9bIIcmpNq9oLG0pvA37V1M5wsRcV8QzDaUfrTgV1dDhg5/BkUT7ScwUjPlaqSlRwtI7TQmPRLFnoUyacaa4tu1/jEzHEEXP4w5CpcYfyouBYKA6H0J0JGOJhH7U= Authentication-Results: spf=none (sender IP is ) smtp.mailfrom=matan@mellanox.com; Received: from mellanox.com (37.142.13.130) by HE1PR0501MB2665.eurprd05.prod.outlook.com (2603:10a6:3:cb::19) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA384_P256) id 15.20.715.22; Thu, 3 May 2018 10:32:15 +0000 From: Matan Azrad To: Wenzhuo Lu , Jingjing Wu Cc: dev@dpdk.org, stable@dpdk.org Date: Thu, 3 May 2018 10:31:47 +0000 Message-Id: <1525343508-29487-6-git-send-email-matan@mellanox.com> X-Mailer: git-send-email 1.9.5 In-Reply-To: <1525343508-29487-1-git-send-email-matan@mellanox.com> References: <1525343508-29487-1-git-send-email-matan@mellanox.com> MIME-Version: 1.0 Content-Type: text/plain X-Originating-IP: [37.142.13.130] X-ClientProxiedBy: HE1PR08CA0058.eurprd08.prod.outlook.com (2603:10a6:7:2a::29) To HE1PR0501MB2665.eurprd05.prod.outlook.com (2603:10a6:3:cb::19) X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-HT: Tenant X-Microsoft-Antispam: UriScan:; BCL:0; PCL:0; RULEID:(7020095)(4652020)(5600026)(48565401081)(4534165)(4627221)(201703031133081)(201702281549075)(2017052603328)(7153060)(7193020); SRVR:HE1PR0501MB2665; X-Microsoft-Exchange-Diagnostics: 1; HE1PR0501MB2665; 3:46P8KDt3mqXYm7BHgPEvgJt65EXP15+HtG/uWNafX9j+AGZg+xhHp4c5CQPWtlmH4u+M/BQV9pW0sjzmkQ2NfpiddQWBS6Zt0sGDtb9FLiUe2hXqyMZQXCptQE1yFk5FFULUDB/32JnQ5Vbquh4dxdcTi2NWaxTVPqhp9ekkTwQhHN4IJoAjikmk6SZVMNaJwYDWnZ8hYvO410+Ga84kS3QlVNQe8UDhck3PWq8760ib90IwVhCA2SqEjO//Q3Yt; 25:co2lZZNifs43esrERN3nFfXh5x0ACTlBE8BfMWrh/w/vQZQZirrUxrMBXQfyFBJ+jbpze9KTP45glXWngj/V0W2PFvFQfcHsYYRYLImMsbnFRs4EkYedq6gjsuC+W0emBvcLx3jJyTMoAs7pFsi/8VyuXZwBXpH+6Fn+Cs8YnTiL8BIrg4hs/mf8JGw0At7xwrKPpGL5p8P5p/E1bodKi84cbV+AlXU8A7xyJ0ZXV/yIlqmdQU6/yE1YUWHDpeedZXxvEUpfcAVLz/ex9rNkjNEv5/RkoPLbt8bHr5WGzjvml0x5FolZoDoKHkZ/Cn6k2uPANB9PLjdSEFDu+k6FiQ==; 31:A7Aoya7+Ax5LGdfKPrQyRI1nWyZauw6S4uz0cZLmgNyrB+RcqV/RkxQCzWPvNnCuwJv7TocxwQr66NJrnkANjxNaqnwmJ+MqKTJ+mT5sFOculJl2RGnwGrr5r00lClgC3MlrJPXj9kU2x8ww5H/Es8MiLdEp4dbdcyylnhMOBObBfxyUkcaq1mkX0s6BckQSAMEAtUo0Fgkfs3vHTui5o00a9l8n8DXONrx/3bzwP+o= X-MS-TrafficTypeDiagnostic: HE1PR0501MB2665: X-Microsoft-Exchange-Diagnostics: 1; HE1PR0501MB2665; 20:jJJXzUCADb3rQOXG8RJb0s3LoFI9ZNIhr6sXk4acNWIcgq9hXOg6GCsJNl68mNqXKirQ2qF3iM9T0sGiQBr8oox2Oy65yFcQ+06VwZkVBeoPBGCII27orZQVAS1ig7WpGuslMyyMcx+VNdUfkN5L+C+l7hFDCtXet2Jk8wS6LKhMhVYfp87eUOFEDfbtz/q5oxI4f49v840kQ36wzhD/SgEuuJ55JvfbrDDqqdt9OU/hbJslIJbIGdkoUUdrFiRdv4QbA/94DqOQTfZyYx+R04P8ufaIGvvNqLmvaUEIcHp86btSr2a0eS5YtxrSYnol89w5yGXGczLDORrDTFIrAh0GFR/y1PJQIhScIpQPvFaDDOnY5qULlKvwON2bGgIM5b0um+TuCsIDWMg2s0F+BHkblggznN52XVUm2bx1i+ReVgn7lrpYDIdwBAi567yTT3k/qiharu1Tl+OI69biaDce0mK0bNqYI1jCQ86MfcrE3UYky5UcZC11Lkif74eZ; 4:E8Ba84U43Lc8CPQIYPOvJ2GKpjZ8GfcNa0oVa41O7qobg6/7ut4EXuByoubxtp9BGJCOxIjGq8I4w/PNwdvdEX0fiK6gn6qdQ0ob+rzDcuV925Ushd7E1p7LotASaKQQQqpfgetDGUo7dRFwGqreuyA5pgxjUdY1Y7uc9J4xhdITe33wcd0AzBaoAWkAXBLzXSCPzpv1nU/i1IgHkW6oE7MiEHUl/n9n0p7ygJwKcgNxUbwuPaGlf8jp6mEqRxdzwIi4rsZmu+azot1oDkALMA== X-Microsoft-Antispam-PRVS: X-Exchange-Antispam-Report-Test: UriScan:; X-Exchange-Antispam-Report-CFA-Test: BCL:0; PCL:0; RULEID:(8211001083)(6040522)(2401047)(8121501046)(5005006)(3002001)(3231254)(944501410)(52105095)(93006095)(93001095)(10201501046)(6055026)(6041310)(201703131423095)(201702281528075)(20161123555045)(201703061421075)(201703061406153)(20161123560045)(20161123562045)(20161123564045)(20161123558120)(6072148)(201708071742011); SRVR:HE1PR0501MB2665; BCL:0; PCL:0; RULEID:; SRVR:HE1PR0501MB2665; X-Forefront-PRVS: 066153096A X-Forefront-Antispam-Report: SFV:NSPM; SFS:(10009020)(366004)(346002)(376002)(39380400002)(39860400002)(396003)(189003)(199004)(97736004)(47776003)(316002)(52116002)(51416003)(36756003)(7696005)(86362001)(25786009)(16586007)(110136005)(68736007)(5660300001)(2906002)(8676002)(81166006)(81156014)(8936002)(66066001)(53936002)(3846002)(6666003)(26005)(305945005)(33026002)(11346002)(69596002)(186003)(106356001)(386003)(50226002)(486006)(55016002)(105586002)(4326008)(6116002)(7736002)(76176011)(446003)(478600001)(476003)(21086003)(59450400001)(48376002)(50466002)(2616005)(956004)(16526019); DIR:OUT; SFP:1101; SCL:1; SRVR:HE1PR0501MB2665; H:mellanox.com; FPR:; SPF:None; LANG:en; PTR:InfoNoRecords; MX:1; A:1; Received-SPF: None (protection.outlook.com: mellanox.com does not designate permitted sender hosts) X-Microsoft-Exchange-Diagnostics: =?us-ascii?Q?1; HE1PR0501MB2665; 23:sCN8gj8p3/IEJYgIexhJkOOx1OYx0Bpbiwrrtxh?= =?us-ascii?Q?52B0dD9aKBI2bI96P6T6Y2UVedmyFRycCwGwy+ieB5F6OsAQr8gjSb3mceGg?= =?us-ascii?Q?ZBXa6ZdLHIFo2zhGNwG5WjiYJGaeGtzbw5pCph0hgXsd4kHW70t+Go2cRb0X?= =?us-ascii?Q?kJwJ6VLeQqWD/KFfDatsIyb0xyJ/PK4ZwZvFV6aWRnLzNs5R/tyXgz1aLQ7J?= =?us-ascii?Q?kVAF2e5u179+ndA3NwpPq8CZ1lXqWUFYVo0+1Ic0UoqzSOWDvsPZa8LVBtsL?= =?us-ascii?Q?oNZbWHnpSrTaC+a3BneCl6bS/LrWBPHcEFlypw3S/0FjcjnboDx06DDUKxBk?= =?us-ascii?Q?8kXHp9Fwe3gkGeP97hqIRsJelbKvT9W+saYpYyWpY2bkeb6YV43mtrb9G2oE?= =?us-ascii?Q?upCo1Qo7dpEOklkgTXMa3+SAe9PJ3gRgthl40+/3IrjAfuKOs6COwuR2R7sY?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1lvhZZ4IaI+rPdvoRFNOhZomrr1Fx7DVGhsz6d7QhehKwv7TjwpnFbb8lRKGGrNxoszCJdUEv3zWEF/Mu9sYiIOfhBpxy3XiFpk2jcWtJD3lB71ejcNlGtLWLmNCU1IApM/sfizf2c6Vq7/UnNCygkNyHlRaefdI0MRgbLJqy8nr/chKuLvU9IcExFUgJs1M7w1yxecyfNH X-MS-Office365-Filtering-Correlation-Id: 2177159c-dd6c-4c7f-4ab9-08d5b0e12418 X-OriginatorOrg: Mellanox.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 03 May 2018 10:32:15.4682 (UTC) X-MS-Exchange-CrossTenant-Network-Message-Id: 2177159c-dd6c-4c7f-4ab9-08d5b0e12418 X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: a652971c-7d2e-4d9b-a6a4-d149256f461b X-MS-Exchange-Transport-CrossTenantHeadersStamped: HE1PR0501MB2665 Subject: [dpdk-dev] [PATCH 5/6] app/testpmd: fix removed device link status asking X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 03 May 2018 10:32:18 -0000 In the RMV device event callback, there is a call for the removed device stop operation which trigers a link status operation for the removed device. It may casue an error from the removed device PMD. Skip the link status operation in the above described case. Fixes: 284c908cc588 ("app/testpmd: request device removal interrupt") Cc: stable@dpdk.org Signed-off-by: Matan Azrad --- app/test-pmd/testpmd.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/app/test-pmd/testpmd.c b/app/test-pmd/testpmd.c index 35f97f0..33a9e96 100644 --- a/app/test-pmd/testpmd.c +++ b/app/test-pmd/testpmd.c @@ -2096,13 +2096,16 @@ struct pmd_test_command { static void rmv_event_callback(void *arg) { + int org_no_link_check = no_link_check; struct rte_eth_dev *dev; portid_t port_id = (intptr_t)arg; RTE_ETH_VALID_PORTID_OR_RET(port_id); dev = &rte_eth_devices[port_id]; + no_link_check = 1; stop_port(port_id); + no_link_check = org_no_link_check; close_port(port_id); printf("removing device %s\n", dev->device->name); if (rte_eal_dev_detach(dev->device)) -- 1.9.5