From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail-lf0-f65.google.com (mail-lf0-f65.google.com [209.85.215.65]) by dpdk.org (Postfix) with ESMTP id 866CF1B6C1 for ; Tue, 15 May 2018 19:20:07 +0200 (CEST) Received: by mail-lf0-f65.google.com with SMTP id p85-v6so1386038lfg.7 for ; Tue, 15 May 2018 10:20:07 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=3tRsYd5fHp+rY8uUUtB5nfqQ5nWoTo8s2gyp3CZgUVE=; b=KqNYtlkaP8jNjGteEBBwgdjC8JrwjU7YMki4VSfGd3wgSm2wnaOgDypg0AbIU0S+ba v1FakeZsVIWwC2GOJEomTc+36nX9mjf1HIOtRSwMedyk3OPUN7PJrMGHi9HuVRdIr+jj RsNRLYS2mn1wZ0J4j/t6K3fq7fc0sbhRE13Mii4FHqJIJfQnZtx8gGYAygGVGnfUAn8B UXmSpr23ZF5k9ZTYO9Vv3lWh2uV3RKJVbOBiw4qk3fz/5S1h0CDsJwPLQ6RtDrGbP4ss GqDNsF6G8IGKeu1oFAnTHRlAYh/7/iBFol3ITlB5fIL9KeZXx0BfHg2XxdxyJtGV5Jp1 lRIw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references; bh=3tRsYd5fHp+rY8uUUtB5nfqQ5nWoTo8s2gyp3CZgUVE=; b=W7pt9fx03fUIPbZzSuqGh2P1xd8RbK2AVWT5yvIGC+SsTKqPKKVCRHXQZwHwJbK55S ntlEigF+zQohWR/GVDLXVKGbMvtZDirEFNw5MxVw5J5FCrD4cF/8jubghdfVH4ujWeUv shZjucOpcSMk6I4jWkHQcHh4XcTPdCIrC7CdJ+mRfnwF1NZWt3WhSWROtBYAVU4Ui/9w CMUfm6esKt5i3dzlL9NizaEaY/j7PI/mns7mssDZ51LyrkRD52UijMHc3N26xc5nk9ac 98HoWmSgefBqV2We9Z+EjeTRhf4bRxHxn9wlxuO6Djuj5aHqgGKFPnf2DKMvr52jiBPw UX5w== X-Gm-Message-State: ALKqPwf5zchEdsu9Q5MAyL7bbTk7j39+Qi4mZTqDJKrWToyVKyN7h5I8 +g6eNMKnTgmE2Uu1UtD8RPY= X-Google-Smtp-Source: AB8JxZplU4WYf8RHZP4j3824i2Dp3dkcPEKUkRHTfrSHb7Nm8EpfigbUt94b1Wt/1W0IChmB5M02Fg== X-Received: by 2002:a19:180a:: with SMTP id o10-v6mr13075308lfi.18.1526404806769; Tue, 15 May 2018 10:20:06 -0700 (PDT) Received: from localhost ([2a00:23c5:be9a:5200:ce4c:82c0:d567:ecbb]) by smtp.gmail.com with ESMTPSA id f70-v6sm133416lfi.2.2018.05.15.10.20.05 (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256); Tue, 15 May 2018 10:20:05 -0700 (PDT) From: luca.boccassi@gmail.com To: Matan Azrad Cc: Bernard Iremonger , dpdk stable Date: Tue, 15 May 2018 18:19:15 +0100 Message-Id: <20180515171933.12882-14-luca.boccassi@gmail.com> X-Mailer: git-send-email 2.14.2 In-Reply-To: <20180515171933.12882-1-luca.boccassi@gmail.com> References: <20180501104509.17238-46-luca.boccassi@gmail.com> <20180515171933.12882-1-luca.boccassi@gmail.com> Subject: [dpdk-stable] patch 'app/testpmd: fix slave port detection' has been queued to LTS release 16.11.7 X-BeenThere: stable@dpdk.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: patches for DPDK stable branches List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 15 May 2018 17:20:07 -0000 Hi, FYI, your patch has been queued to LTS release 16.11.7 Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet. It will be pushed if I get no objections before 05/16/18. So please shout if anyone has objections. Thanks. Luca Boccassi --- >>From 07a97d39c9b85868a66b27eb3fd6b3a0e815db8e Mon Sep 17 00:00:00 2001 From: Matan Azrad Date: Wed, 28 Mar 2018 11:17:53 +0000 Subject: [PATCH] app/testpmd: fix slave port detection [ upstream commit b8b8b344cb44bea46ac1d2037e8e5f1e742319f6 ] Testpmd allows to create and control bonding devices by run time command lines using the bonding PMD API. Some bonding device slaves operations (close, stop, etc) should not be used by the application and must be managed by the bonding PMD. Thus, Testpmd manages slave flags to prevent the special operations calls and when a slave is added to bonding device by a run time command line, the flag is set. There is one more way to define the slaves for a bonding device using EAL command line and Testpmd doesn't set the slave flag in this case what causes to the special operations to be called by Testpmd. Add one more check to detect bonding slave device. Fixes: 41b05095c4d1 ("app/testpmd: fix bonding start") Fixes: 0e545d3047fe ("app/testpmd: check stopping port is not in bonding") Signed-off-by: Matan Azrad Acked-by: Bernard Iremonger --- app/test-pmd/testpmd.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/app/test-pmd/testpmd.c b/app/test-pmd/testpmd.c index 9de01fed2..9313d0bbc 100644 --- a/app/test-pmd/testpmd.c +++ b/app/test-pmd/testpmd.c @@ -1857,7 +1857,10 @@ uint8_t port_is_bonding_slave(portid_t slave_pid) struct rte_port *port; port = &ports[slave_pid]; - return port->slave_flag; + if ((rte_eth_devices[slave_pid].data->dev_flags & + RTE_ETH_DEV_BONDED_SLAVE) || (port->slave_flag == 1)) + return 1; + return 0; } const uint16_t vlan_tags[] = { -- 2.14.2