From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mails.dpdk.org (mails.dpdk.org [217.70.189.124]) by inbox.dpdk.org (Postfix) with ESMTP id 779E9A0A02 for ; Thu, 14 Jan 2021 19:11:16 +0100 (CET) Received: from [217.70.189.124] (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id E7B82140D6D; Thu, 14 Jan 2021 19:11:15 +0100 (CET) Received: from mx0a-001b2d01.pphosted.com (mx0b-001b2d01.pphosted.com [148.163.158.5]) by mails.dpdk.org (Postfix) with ESMTP id 53E4D140D6C for ; Thu, 14 Jan 2021 19:11:14 +0100 (CET) Received: from pps.filterd (m0098414.ppops.net [127.0.0.1]) by mx0b-001b2d01.pphosted.com (8.16.0.42/8.16.0.42) with SMTP id 10EI1jWT096939 for ; Thu, 14 Jan 2021 13:11:13 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=ibm.com; h=subject : to : references : from : message-id : date : mime-version : in-reply-to : content-type : content-transfer-encoding; s=pp1; bh=jtqjJwTgJRB3cX/G3ZGuixS7cCfda4kKRjYRH6BsJN0=; b=QrefknFdBlY1JUXwJ2Ogwf0VsPuR51+qMXHP+Cqrq9aBAP3JMa512moGZxRLOyazHtnm xwPgjsZU/N3o8scRbyxacsFiVJgUdFEuTck8JCG2wZPvP+/Dg7VwtegKoLQNCwL29Ba/ BqBSNvEaEKnoDOiWMPnY2OFvmTKjaF8Q1BtsawPp9D0TAkyqc+hI1U2Zx7yDyY3L+ThR 5tLgOBO3jWbTtfWmNPLg7MQ2L4U0S9mKu5WNaobFgHQTmQzXJtZp6CbPVLvgL/RM4mQr 2zLAKfh2CnC4kUrdsXxGbvNyRdTqdOFcigTm56OWRAgeJlm8ZIuxIVp6U/xyxE7vQ7zx Zg== Received: from ppma01wdc.us.ibm.com (fd.55.37a9.ip4.static.sl-reverse.com [169.55.85.253]) by mx0b-001b2d01.pphosted.com with ESMTP id 362tnt8p9t-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT) for ; Thu, 14 Jan 2021 13:11:13 -0500 Received: from pps.filterd (ppma01wdc.us.ibm.com [127.0.0.1]) by ppma01wdc.us.ibm.com (8.16.0.42/8.16.0.42) with SMTP id 10EI7PUY027010 for ; Thu, 14 Jan 2021 18:11:12 GMT Received: from b03cxnp07028.gho.boulder.ibm.com (b03cxnp07028.gho.boulder.ibm.com [9.17.130.15]) by ppma01wdc.us.ibm.com with ESMTP id 35y449f2fd-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT) for ; Thu, 14 Jan 2021 18:11:12 +0000 Received: from b03ledav003.gho.boulder.ibm.com (b03ledav003.gho.boulder.ibm.com [9.17.130.234]) by b03cxnp07028.gho.boulder.ibm.com (8.14.9/8.14.9/NCO v10.0) with ESMTP id 10EIBB5017826136 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK) for ; Thu, 14 Jan 2021 18:11:11 GMT Received: from b03ledav003.gho.boulder.ibm.com (unknown [127.0.0.1]) by IMSVA (Postfix) with ESMTP id C4C776A051 for ; Thu, 14 Jan 2021 18:11:11 +0000 (GMT) Received: from b03ledav003.gho.boulder.ibm.com (unknown [127.0.0.1]) by IMSVA (Postfix) with ESMTP id A03236A047 for ; Thu, 14 Jan 2021 18:11:11 +0000 (GMT) Received: from Davids-MBP.randomparity.org (unknown [9.163.92.50]) by b03ledav003.gho.boulder.ibm.com (Postfix) with ESMTP for ; Thu, 14 Jan 2021 18:11:11 +0000 (GMT) To: users@dpdk.org References: From: David Christensen Message-ID: <29972d41-cb42-bdd2-46d8-2ee82cdc9c3a@linux.vnet.ibm.com> Date: Thu, 14 Jan 2021 10:11:11 -0800 User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.16; rv:78.0) Gecko/20100101 Thunderbird/78.6.1 MIME-Version: 1.0 In-Reply-To: Content-Type: text/plain; charset=utf-8; format=flowed Content-Language: en-US Content-Transfer-Encoding: 8bit X-TM-AS-GCONF: 00 X-Proofpoint-Virus-Version: vendor=fsecure engine=2.50.10434:6.0.343, 18.0.737 definitions=2021-01-14_06:2021-01-14, 2021-01-14 signatures=0 X-Proofpoint-Spam-Details: rule=outbound_notspam policy=outbound score=0 bulkscore=0 malwarescore=0 impostorscore=0 phishscore=0 adultscore=0 priorityscore=1501 clxscore=1011 lowpriorityscore=0 mlxlogscore=915 suspectscore=0 mlxscore=0 spamscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.12.0-2009150000 definitions=main-2101140102 Subject: Re: [dpdk-users] Fwd: use VF in promiscuous mode in dpdk to receive all traffic received by PF X-BeenThere: users@dpdk.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: DPDK usage discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: users-bounces@dpdk.org Sender: "users" On 1/13/21 9:59 PM, Myth Ren wrote: > Hi, all > is it possible we are mirror traffic from switch/router to PF, then a > program based on DPDK > read packet from a VF related to the PF, presume we are mirror the traffic > from PF to the VF (promiscuous), > while the PF device still managed by the kernel driver(if it's possible), > or managed by UIO driver. > at least, restart the DPDK based program will not influence the PF device > state. You should be specific about the NIC/PMD you're using here. One use case for PF/VF is that the PF will run in the host operating system and the VF will be passed-through to a virtual machine. Because of this, NICs will often support a feature to actively prevent a VF from snooping on the traffic seen by the PF for security, limiting it to only broadcast/multicast traffic and unicast traffic with a matching MAC address. The ability for a VF to enable promiscuous mode and see PF traffic, if it is supported on the NIC, is likely to be NIC/PMD specific implementation. And why the need for a VF in the first place? If the switch/router is external to the box and forwarding traffic into the PF, why not just catch the traffic from the PF? You'll need a second PF anyway to send the traffic onward (like a bump-in-the-wire implementation), unless you're mangling the packets for some reason to change their address, adding a VLAN or other tag, etc. A drawing of what you're trying to implement would be useful here. Dave