From mboxrd@z Thu Jan  1 00:00:00 1970
Return-Path: <dev-bounces@dpdk.org>
Received: from mails.dpdk.org (mails.dpdk.org [217.70.189.124])
	by inbox.dpdk.org (Postfix) with ESMTP id 03546A00C5;
	Fri, 11 Feb 2022 13:29:38 +0100 (CET)
Received: from [217.70.189.124] (localhost [127.0.0.1])
	by mails.dpdk.org (Postfix) with ESMTP id D0FEB42740;
	Fri, 11 Feb 2022 13:29:38 +0100 (CET)
Received: from mga09.intel.com (mga09.intel.com [134.134.136.24])
 by mails.dpdk.org (Postfix) with ESMTP id 9964641144
 for <dev@dpdk.org>; Fri, 11 Feb 2022 13:29:37 +0100 (CET)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple;
 d=intel.com; i=@intel.com; q=dns/txt; s=Intel;
 t=1644582577; x=1676118577;
 h=message-id:date:to:cc:references:from:subject:
 in-reply-to:content-transfer-encoding:mime-version;
 bh=LqdyeifNoKWGgA/fcWrAQN5J/lHU3Jr9NnkDZamwfvs=;
 b=Cz3SAadYdZUynUaCwc2ljApybyuLKR6FX4VI/iZh/0APiNxmBHwR7STm
 XboHU+mvGwUpSjraLmj//HhQQrsrvJ9Z0B3o9ywGs99pqiH3q9VhnfCsb
 HErt6k+7b5qmI2hce3oNdrxGRm+Iw8Td9SXXxVHUATg4C+nAg6lacTPRK
 tCR4zYSkm5HkceU9d2Xco1ymRKDPmmGwWEcxhAVDEOHl/xOTdFPAX7gZZ
 XQwbS8FxSjZ2wSvRl/qskxeXInYGnGwaZ7BlpoFWerDvSScsRCvnA72or
 IXXuutSBDRIv3ODqlrwPS1Ecf7CDtJ86zDSplhJ1mcb6RqcCol93BCd8f Q==;
X-IronPort-AV: E=McAfee;i="6200,9189,10254"; a="249472465"
X-IronPort-AV: E=Sophos;i="5.88,360,1635231600"; d="scan'208";a="249472465"
Received: from orsmga003.jf.intel.com ([10.7.209.27])
 by orsmga102.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384;
 11 Feb 2022 04:29:36 -0800
X-ExtLoop1: 1
X-IronPort-AV: E=Sophos;i="5.88,360,1635231600"; d="scan'208";a="483351426"
Received: from orsmsx603.amr.corp.intel.com ([10.22.229.16])
 by orsmga003.jf.intel.com with ESMTP; 11 Feb 2022 04:29:36 -0800
Received: from orsmsx607.amr.corp.intel.com (10.22.229.20) by
 ORSMSX603.amr.corp.intel.com (10.22.229.16) with Microsoft SMTP Server
 (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id
 15.1.2308.20; Fri, 11 Feb 2022 04:29:36 -0800
Received: from orsmsx610.amr.corp.intel.com (10.22.229.23) by
 ORSMSX607.amr.corp.intel.com (10.22.229.20) with Microsoft SMTP Server
 (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id
 15.1.2308.20; Fri, 11 Feb 2022 04:29:36 -0800
Received: from orsedg603.ED.cps.intel.com (10.7.248.4) by
 orsmsx610.amr.corp.intel.com (10.22.229.23) with Microsoft SMTP Server
 (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id
 15.1.2308.20 via Frontend Transport; Fri, 11 Feb 2022 04:29:36 -0800
Received: from NAM02-DM3-obe.outbound.protection.outlook.com (104.47.56.42) by
 edgegateway.intel.com (134.134.137.100) with Microsoft SMTP Server
 (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id
 15.1.2308.20; Fri, 11 Feb 2022 04:29:35 -0800
ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none;
 b=cPQUmV0ztNEK3Qfkf0Zz9dBiIWnm43m3RFrTdQ/RAO5zLHeGR3lGIkJ0YgtNPFTGYdZ+t5ceyk4Ms4KgRnvJWna37ohesCtccsSeZah7WhEWoEFOLiDXPEiuEeaj6Sz6aIbMbcB7E58WrqYPswK188SOaP/ozmg5TBBkSJ19sT+MdIlLplqs6y2m+njUMWgju2IzC54i0zkapOWSLVBrTq/YFuuNuY45A1fX8X4mJfVAM9qnmSlRffxgK7z4E5G3xGizU0vqCj1U+Hli8FfF3oWwKHPpG9aonHB0OHr2D/KCZjQPOBUQgHHPD9vuYobNxJGw5b5oLWilU0Nkjrk1qg==
ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; 
 s=arcselector9901;
 h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1;
 bh=5utUCQnz9m6ExB8lgI+dIaVl3RRTWQMA6n7zX76kszo=;
 b=WRC7Ffe20Jz5lHkLnL5YAFOZ8JomjMeO0fGLmFWnRASBIaEovwY6ZurXGsYglQoZvhzhen2R9DHyYw9Ixi/PI8F7cf2sREQWdoqQ4woEJ5eWd15yjj8R6wBfqBoPmou2NWabp7HYTLzxeI8bkWu3/ME8E/oH4Qa6Mtbdp/gZSRRMEzuAbtOyhjlvcr4QCS9fuNZOtCu58sWvr1TXsMlnss4xX4fIgUxtdcOLKSSuzhFbJ0BBj7u5xEs09r+uR3AJK3H/RRcZ5w12dzT3wKZQ80OnFY9IEzlWy6nKHYI5GYU/K694jEGZCF8gnvIj05rRgU53UBvQZo8HUxn6+V3ngA==
ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=none; dmarc=none;
 dkim=none; arc=none
Authentication-Results: dkim=none (message not signed)
 header.d=none;dmarc=none action=none header.from=intel.com;
Received: from PH0PR11MB5000.namprd11.prod.outlook.com (2603:10b6:510:41::19)
 by BN9PR11MB5403.namprd11.prod.outlook.com (2603:10b6:408:11c::21)
 with Microsoft SMTP Server (version=TLS1_2,
 cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.4975.11; Fri, 11 Feb
 2022 12:29:34 +0000
Received: from PH0PR11MB5000.namprd11.prod.outlook.com
 ([fe80::98be:5506:5020:28a2]) by PH0PR11MB5000.namprd11.prod.outlook.com
 ([fe80::98be:5506:5020:28a2%4]) with mapi id 15.20.4975.011; Fri, 11 Feb 2022
 12:29:34 +0000
Message-ID: <452f86bf-826a-20c8-93dc-1b8dfee1febe@intel.com>
Date: Fri, 11 Feb 2022 12:29:28 +0000
Content-Language: en-US
To: "Loftus, Ciara" <ciara.loftus@intel.com>, "dev@dpdk.org" <dev@dpdk.org>
CC: "stephen@networkplumber.org" <stephen@networkplumber.org>, "Burakov,
 Anatoly" <anatoly.burakov@intel.com>, "Singh, Aman Deep"
 <aman.deep.singh@intel.com>
References: <20220208134800.52142-1-ciara.loftus@intel.com>
 <20220209094808.41464-1-ciara.loftus@intel.com>
 <d5d02056-b130-92a8-85d2-b9253e1cd1ea@intel.com>
 <PH0PR11MB4791799CDD0CF7D0047B62748E2F9@PH0PR11MB4791.namprd11.prod.outlook.com>
 <daeb5710-6541-6743-3ba0-66e201b3a5be@intel.com>
 <PH0PR11MB4791786D25C6AB5E63E0A5888E2F9@PH0PR11MB4791.namprd11.prod.outlook.com>
 <7f0c4a88-3477-a53d-7510-875e3d3789f1@intel.com>
 <PH0PR11MB4791309806A6C2921CCE9C278E309@PH0PR11MB4791.namprd11.prod.outlook.com>
 <PH0PR11MB47914EB5A3203A45878473678E309@PH0PR11MB4791.namprd11.prod.outlook.com>
From: Ferruh Yigit <ferruh.yigit@intel.com>
Subject: Re: [PATCH v4] net/af_xdp: re-enable secondary process support
X-User: ferruhy
In-Reply-To: <PH0PR11MB47914EB5A3203A45878473678E309@PH0PR11MB4791.namprd11.prod.outlook.com>
Content-Type: text/plain; charset="UTF-8"; format=flowed
Content-Transfer-Encoding: 7bit
X-ClientProxiedBy: LO2P265CA0006.GBRP265.PROD.OUTLOOK.COM
 (2603:10a6:600:62::18) To PH0PR11MB5000.namprd11.prod.outlook.com
 (2603:10b6:510:41::19)
MIME-Version: 1.0
X-MS-PublicTrafficType: Email
X-MS-Office365-Filtering-Correlation-Id: 54bfbd22-fe4f-4f54-5117-08d9ed5a28d1
X-MS-TrafficTypeDiagnostic: BN9PR11MB5403:EE_
X-Microsoft-Antispam-PRVS: <BN9PR11MB5403BA3A9A7BE6365D4A08D995309@BN9PR11MB5403.namprd11.prod.outlook.com>
X-MS-Oob-TLC-OOBClassifiers: OLM:972;
X-MS-Exchange-SenderADCheck: 1
X-MS-Exchange-AntiSpam-Relay: 0
X-Microsoft-Antispam: BCL:0;
X-Microsoft-Antispam-Message-Info: 6Cw6BIXbezlyTiMafjWeR9nhBhve4HttRO7OzDg5CxxwYIGIbzK7AiEW6/qqqxtXNFtEpJUeSr1+4Uox6kIAOYKqwyd/Gb8Vi19OduAZfyNv5EiiYzOdxCnEXatZ3HVFzR9JFrLoO94JGhP2FNABI42Mfuh6w3+AHGeY2KhBTDs18bXjiftNfwF5Lsdt0mAKS3Tzy2GeARbBeLBFChtxZi6U5oz43fc3hih+JqjtwGaQ1iulyYVPMxuf9MzKjhYGSMhtr1E3jbXhcLpderG2UYGDXFWBkSqUevqhHWJL9jeSD25HIrnSeh9nQD5loom2gxtrJoJijWBMGg/qp9y/7YLgiTmIImlxovN/QvOrRExXs0DonuVCym+RhFSdEEWn+hZt1OzowPM7SSiqLmtYYRnX7cD5mABzna3FAwnviJ6QeygMyqjmW1QmBsSJjCKdt/cHgiqHw1vU9cDS55h7Ayi15fo1N4LMPY+KKiDS51kJdA2knOWGc+vheOUx+RYaF/xR4jyjcOuUeT3H4Y5i/pFpKDid4GAcbq1c9vKAz1XAMZ6CGjv+YRDGRZZQ27xTm9MlvlZbjHjOrY2jHf2/oZy8fi+gHQS3MbnFXhEId6zB+6X27E5z4WQHgwZjFM7xRsFI608kbqcgB+22DwPE7pxypxMicKRzb+PHSDUOWugcGPhbrpiMckaxlBdcMpPVCaiXn0dlGNfudt4VaB68aP5aFxt5lMTVZv43+EtpL1ihyggI9rD3qk2ebpaDTg6s/XGUx6xUVEG+FBo/FP/OWWBBrBUIFBPt+VqW0/5d9LDQFjRJrzIl4Iqi2IgHXbk98bSa0zOYfbJNyaJyBUqkhA==
X-Forefront-Antispam-Report: CIP:255.255.255.255; CTRY:; LANG:en; SCL:1; SRV:;
 IPV:NLI; SFV:NSPM; H:PH0PR11MB5000.namprd11.prod.outlook.com; PTR:; CAT:NONE;
 SFS:(13230001)(366004)(84040400005)(55236004)(8936002)(316002)(110136005)(54906003)(26005)(66556008)(4326008)(8676002)(31696002)(66946007)(86362001)(38100700002)(6506007)(53546011)(107886003)(82960400001)(2616005)(6512007)(186003)(66476007)(36756003)(6486002)(966005)(508600001)(83380400001)(44832011)(31686004)(2906002)(5660300002)(6666004)(45980500001);
 DIR:OUT; SFP:1102; 
X-MS-Exchange-AntiSpam-MessageData-ChunkCount: 1
X-MS-Exchange-AntiSpam-MessageData-0: =?utf-8?B?elRJS1dCRnNaUDRldGFscnp5djBCZjFUTEpHZWdXZ3RNMTQ3TUN4eFRrazlS?=
 =?utf-8?B?bVZmTzhKN2UzSGpqQTZ0NFR5R2pRY0haSVNRQU1oYjQzL1l5cHNyVC8rQmR1?=
 =?utf-8?B?RmU0Q0c5S1BFRHE5WjJpYkN3OVRBOWx3WEF3K1phSWpNSHBNdnVZOW9ZNTVt?=
 =?utf-8?B?dmxmUCtMWnpDbnhLTDdnMHhwaWM3Q0lld1h6aHpoOXBxVkdkNHdkNVVFVDIw?=
 =?utf-8?B?YWhSQ0dJaEg3R3kxVUd2cTg0NVRoVEhGTVdKM1JjQVUxQWtBeXVVSzR0S1dH?=
 =?utf-8?B?RzlyNi9sWGQ3SHZFY2YxZS8xRW51eStHS2RLeXErVW9vU2tQRGIrdm5yR1pN?=
 =?utf-8?B?dlNzMVMrRXZ4Z0ZmM21sVmoyYnYxdUNSenZjYjFreEpRVFM0dGNVYkY0aDBZ?=
 =?utf-8?B?TTdZd0VOTExXRlAxWXBDUkJVbzBodFhFdWpmV1lBMzJ2MVJMdFZONHR0bzNq?=
 =?utf-8?B?R3RnUEhZc0liVHdUYjBKNG5WRkhSREUvRjIyeExKVzBzSDVV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exchange-CrossTenant-AuthSource: PH0PR11MB5000.namprd11.prod.outlook.com
X-MS-Exchange-CrossTenant-AuthAs: Internal
X-MS-Exchange-CrossTenant-OriginalArrivalTime: 11 Feb 2022 12:29:34.0246 (UTC)
X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted
X-MS-Exchange-CrossTenant-Id: 46c98d88-e344-4ed4-8496-4ed7712e255d
X-MS-Exchange-CrossTenant-MailboxType: HOSTED
X-MS-Exchange-CrossTenant-UserPrincipalName: vVTboXOzW/F39XwRYk40oQ9NBgOWHCdJc0a3wcji/rIeMDxP9A1lfbWsto7NQvZ8eA7C2QF5p4pSwKoez30efQ==
X-MS-Exchange-Transport-CrossTenantHeadersStamped: BN9PR11MB5403
X-OriginatorOrg: intel.com
X-BeenThere: dev@dpdk.org
X-Mailman-Version: 2.1.29
Precedence: list
List-Id: DPDK patches and discussions <dev.dpdk.org>
List-Unsubscribe: <https://mails.dpdk.org/options/dev>,
 <mailto:dev-request@dpdk.org?subject=unsubscribe>
List-Archive: <http://mails.dpdk.org/archives/dev/>
List-Post: <mailto:dev@dpdk.org>
List-Help: <mailto:dev-request@dpdk.org?subject=help>
List-Subscribe: <https://mails.dpdk.org/listinfo/dev>,
 <mailto:dev-request@dpdk.org?subject=subscribe>
Errors-To: dev-bounces@dpdk.org

On 2/11/2022 9:26 AM, Loftus, Ciara wrote:
>>>
>>> On 2/10/2022 5:47 PM, Loftus, Ciara wrote:
>>>>> Subject: Re: [PATCH v4] net/af_xdp: re-enable secondary process
>> support
>>>>>
>>>>> On 2/10/2022 3:40 PM, Loftus, Ciara wrote:
>>>>>>> Subject: Re: [PATCH v4] net/af_xdp: re-enable secondary process
>>> support
>>>>>>>
>>>>>>> On 2/9/2022 9:48 AM, Ciara Loftus wrote:
>>>>>>>> Secondary process support had been disabled for the AF_XDP PMD
>>>>>>> because
>>>>>>>> there was no logic in place to share the AF_XDP socket file
>> descriptors
>>>>>>>> between the processes. This commit introduces this logic using the
>>> IPC
>>>>>>>> APIs.
>>>>>>>>
>>>>>>>> Rx and Tx are disabled in the secondary process due to memory
>>> mapping
>>>>> of
>>>>>>>> the AF_XDP rings being assigned by the kernel in the primary
>> process
>>>>> only.
>>>>>>>> However other operations including retrieval of stats are permitted.
>>>>>>>>
>>>>>>>> Signed-off-by: Ciara Loftus <ciara.loftus@intel.com>
>>>>>>>>
>>>>>>>
>>>>>>> Hi Ciara,
>>>>>>>
>>>>>>> When I tried to test the patch getting following error [1], it doesn't
>> look
>>>>>>> related to this patch but can you help to fix the issue, thanks.
>>>>>>>
>>>>>>> [1]
>>>>>>> libxdp: Couldn't find a BPF file with name xsk_def_xdp_prog.o
>>>>>>> xsk_configure(): Failed to create xsk socket.
>>>>>>> eth_rx_queue_setup(): Failed to configure xdp socket
>>>>>>> Fail to configure port 2 rx queues
>>>>>>> EAL: Error - exiting with code: 1
>>>>>>
>>>>>>
>>>>>> Hi Ferruh,
>>>>>>
>>>>>> This file should be generated when libxdp is compiled.
>>>>>> Mine is located @ /usr/local/lib/bpf/xsk_def_xdp_prog.o
>>>>>> Can you check if that file is there for you? It could be in
>>>>> /usr/local/lib64/bpf/ on your machine.
>>>>>> What kernel are you running on?
>>>>>>
>>>>>
>>>>> It is in: /usr/local/lib64/bpf/xsk_def_xdp_prog.o
>>>>>
>>>>> I had to compile libxdp from source because OS package version was old
>>>>> to work with af_xdp.
>>>>> Is something required to point location of this file to af_xdp PMD?
>>>>>
>>>>> I run kernel:
>>>>> 5.15.16-200.fc35.x86_64
>>>>
>>>> I read through the libxdp code to figure out what happens when
>> searching
>>> for the file:
>>>> https://github.com/xdp-project/xdp-
>>> tools/blob/v1.2.2/lib/libxdp/libxdp.c#L1055
>>>>
>>>> secure_getenv(XDP_OBJECT_ENVVAR) is called which according to the
>>> README "defaults to /usr/lib/bpf (or /usr/lib64/bpf on systems using a split
>>> library path)".
>>>> If that fails, BPF_OBJECT_PATH will be searched, which points to
>>> /usr/lib/bpf
>>>>
>>>> I discovered that on my system the getenv() call fails, but the file is
>>> eventually found because luckily BPF_OBJECT_PATH points to the
>>> appropriate place for me (lib):
>>>> https://github.com/xdp-project/xdp-tools/blob/v1.2.2/lib/util/util.h#L24
>>>> I suspect the same failure is happening for you, but since
>>> BPF_OBJECT_PATH points to lib and not lib64, the file is not found.
>>>> As a temporary measure can you create a symlink in /usr/local/lib/bpf/ to
>>> point to /usr/local/lib/bpf/xsk_def_xdp_prog.o
>>>> I will investigate the libxdp issue further. Maybe a change is needed in
>> the
>>> library. If a change or setup recommendation is needed in DPDK I will
>> create a
>>> patch.
>>>>
>>>
>>>
>>> I don't have XDP_OBJECT_ENVVAR or BPF_OBJECT_PATH environment
>>> variables set,
>>> if they should be we should document them.
>>>
>>> When I created '/usr/local/lib/bpf/' link, the BPF file found.
>>> This should be clarified/documented for users.
>>
>> Ok. Ideally we shouldn't have to create the symlink. I will look for a better
>> solution and submit a patch.
>> The symlink might be a temporary solution if another solution is not found.
> 
> Can you please try setting the environment variable LIBXDP_OBJECT_PATH=/usr/local/lib64/bpf/
> And see if your test works without the symlink?
> This worked for me and the getenv succeeded.
> If it works for you too, I'll create a patch for the docs instructing users to do the same.
> 

I confirm it works, and +1 to document it.


btw, when this environment variable is not set (and no symlink), af_xdp fails
and testpmd crashes. I think af_xdp failure shouldn't cause a crash in testpmd,
most probably some error checks are needed in the af_xdp driver.

> Thanks,
> Ciara
> 
>>
>>>
>>>
>>> And still observing following two:
>>>
>>> 1) I don't know what following log means:
>>> Configuring Port 2 (socket 0)
>>> libbpf: elf: skipping unrecognized data section(7) .xdp_run_config
>>> libbpf: elf: skipping unrecognized data section(8) xdp_metadata
>>> libxdp: XDP flag not supported by libxdp.
>>> libbpf: elf: skipping unrecognized data section(8) xdp_metadata
>>> libbpf: elf: skipping unrecognized data section(8) xdp_metadata
>>
>> I reported this and a patch was submitted to libbpf to demote those logs:
>> https://www.spinics.net/lists/bpf/msg49140.html
>> It looks like the patch never made it. I'll chase it up.
>> Anyway, the logs can be ignored as they are not errors.
>>
>>>
>>> 2) When I try to create two af_xdp interface, I only got one:
>>> "--vdev net_af_xdp,iface=enp24s0f1 --vdev net_af_xdp,iface=enp24s0f0"
>>
>> This is also expected as you haven't given each vdev a unique name. Try:
>> "--vdev net_af_xdp0,iface=enp24s0f1 --vdev net_af_xdp1,iface=enp24s0f0"
>>
>> Thank you for the testing.
>>
>> Ciara
>>
>>>
>>>
>>> Thanks,
>>> ferruh