From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail-wm0-f66.google.com (mail-wm0-f66.google.com [74.125.82.66]) by dpdk.org (Postfix) with ESMTP id A1EEA1B74A for ; Tue, 24 Oct 2017 09:34:38 +0200 (CEST) Received: by mail-wm0-f66.google.com with SMTP id 78so11324178wmb.1 for ; Tue, 24 Oct 2017 00:34:38 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=6wind-com.20150623.gappssmtp.com; s=20150623; h=from:date:to:cc:subject:message-id:references:mime-version :content-disposition:content-transfer-encoding:in-reply-to :user-agent; bh=X58mTiT+6yyCrH9r5IbWs7lU4y8exblqwVVfaQWCox8=; b=DcsF1/XHMVyrWVGQVk6wiJkdSpTl4cST+sWMnC9GJHai+kT4QTFKqO3N20GVWdvzod rgRyi56x0E5RsfBtJWxGxSyKJ6mnme8uyU0C5XlijsPHmCC7fsfWYgkVj+QgUYfv/vKq 2rqOa/HmNoArlMG5ELTK2iC4ng3LWsZF5HKU8mBQe1kwloY9TN0l6tvuEUIj+mkdbLP3 uRTuj1FSnllfpwRqHK+ZzWnWYp9lOLv0FKfwRwd9gcLiui2L/gq6e2Upco3XX3kfP8CF kddtNuQRj5BT5R6RloLvlAXbs/dwuIQWw8EA+OiLkBs5qaxge4EhFv16mGkKL4tYko7+ d9tw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:date:to:cc:subject:message-id:references :mime-version:content-disposition:content-transfer-encoding :in-reply-to:user-agent; bh=X58mTiT+6yyCrH9r5IbWs7lU4y8exblqwVVfaQWCox8=; b=VqFaRdtRC972eljS/qZVDzx/kq7bQuWd5sN+ULNRIOWAtVzA/Zo4nHGOjxNPW5CebP JkPnGQehE7K6XFzXBOaqt6v3ujbt+sExUl8nMfNFU78IIvbouekM8P7P7eSEUKxcursJ GhZMOShMC5KZQRheosCKTwsTV33GPV68hF6J6/TPI1oSNqdCzbYihhfuuZs2IqMtz8G8 ueiRTSid8nFuVfaUr/J7Z4IvhbLXfQILlQNCkEwyVwIXXkxfC3a/RyomhCWHTSrFNOAE TxfxVHPJeI75kt/Eml2GTHdFM7i4zUdLlRVGFM4gh1UY7xc7prJqyRQKlWfGyBTOPjEL DZSg== X-Gm-Message-State: AMCzsaWvBOQBFIr6ilW8ApdnwVBEjNqp1bmJnsbMlex0oEqERZ9yxMeq 4zXgKK9P1vSxcVLTwlNQ7aWL+YyArQ== X-Google-Smtp-Source: ABhQp+QqWxFZBaV6Fz+WPeNmJIvIBamdazrWsTPsIegfbfomuu5c7kLhpXBM3FlM3YsnVdz+R0Apmg== X-Received: by 10.80.215.209 with SMTP id m17mr5722516edj.63.1508830478336; Tue, 24 Oct 2017 00:34:38 -0700 (PDT) Received: from laranjeiro-vm (host.78.145.23.62.rev.coltfrance.com. [62.23.145.78]) by smtp.gmail.com with ESMTPSA id x7sm7081745edi.6.2017.10.24.00.34.37 (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256); Tue, 24 Oct 2017 00:34:37 -0700 (PDT) From: "=?iso-8859-1?Q?N=E9lio?= Laranjeiro" X-Google-Original-From: =?iso-8859-1?Q?N=E9lio?= Laranjeiro Date: Tue, 24 Oct 2017 09:34:34 +0200 To: Yongseok Koh , dev@dpdk.org Cc: Adrien Mazarguil Message-ID: <20171024073434.5cbsrnzw7pjrjswm@laranjeiro-vm> References: <20171023192544.GA19386@yongseok-MBP.local> <20171024071142.3wsybjacfoa6i453@laranjeiro-vm> MIME-Version: 1.0 Content-Type: text/plain; charset=iso-8859-1 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: <20171024071142.3wsybjacfoa6i453@laranjeiro-vm> User-Agent: NeoMutt/20170113 (1.7.2) Subject: Re: [dpdk-dev] [PATCH v2 6/7] net/mlx5: fix reception when VLAN is added 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: Tue, 24 Oct 2017 07:34:38 -0000 On Tue, Oct 24, 2017 at 09:11:42AM +0200, Nélio Laranjeiro wrote: > On Mon, Oct 23, 2017 at 12:25:45PM -0700, Yongseok Koh wrote: > > On Mon, Oct 23, 2017 at 04:49:56PM +0200, Nelio Laranjeiro wrote: > > > @@ -261,75 +284,59 @@ priv_dev_traffic_enable(struct priv *priv, struct rte_eth_dev *dev) > > > }; > > > > > > claim_zero(mlx5_ctrl_flow(dev, &promisc, &promisc)); > > > - } else if (dev->data->all_multicast) { > > > + return 0; > > > + } > > > + if (dev->data->all_multicast) { > > > struct rte_flow_item_eth multicast = { > > > .dst.addr_bytes = "\x01\x00\x00\x00\x00\x00", > > > - .src.addr_bytes = "\x01\x00\x00\x00\x00\x00", > > > + .src.addr_bytes = "\x00\x00\x00\x00\x00\x00", > > > .type = 0, > > > }; > > > > > > claim_zero(mlx5_ctrl_flow(dev, &multicast, &multicast)); > > > > Just curious. No need to consider VLAN for multicast here? > > According to the lib documentation no [1] > > "Enable the receipt of any multicast frame by an Ethernet device" > > > [...] > > These (bcast and ipv6_multi_mask) can be duplicated multiple times if there are > > multiple MAC addrs, is that intended? > > There is in fact an issue in this series, it does not match my final code. > > I'll send a v3. > > [1] http://dpdk.org/browse/dpdk/tree/lib/librte_ether/rte_ethdev.h#n2304 I've wrongly read your last comment, the patch is correct, it won't add multiple time the broadcast multicast, it will add one per expected VLAN. Example: testpmd> set promisc all off testpmd> set allmulti all off testpmd> rx_vlan add 0 1330 testpmd> rx_vlan add 0 1331 Will cause this code to add a broadcast flow with VLAN TCI 1330 and another broadcast flow with VLAN TCI 1331, others won't be received. The user will only receive broadcast packets with VLAN TCI 1330 and 1331. It is what he expects. In case not VLAN is configured, the broadcast and muilticast flow insertion are under the condition: "if (!dev->data->all_multicast && !vlan_filter_n)" Thanks, -- Nélio Laranjeiro 6WIND