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 D368FA00BE; Wed, 20 Apr 2022 17:52:52 +0200 (CEST) Received: from [217.70.189.124] (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 95406410FF; Wed, 20 Apr 2022 17:52:51 +0200 (CEST) Received: from mga07.intel.com (mga07.intel.com [134.134.136.100]) by mails.dpdk.org (Postfix) with ESMTP id 0BF9840C35; Wed, 20 Apr 2022 17:52:48 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1650469969; x=1682005969; h=message-id:date:subject:to:cc:references:from: in-reply-to:content-transfer-encoding:mime-version; bh=tqL7Jy4NpJZMhqJFCc+osCwlhJGr+90AFtGXySdDgKY=; b=jwZCG1a5yV0xgZjBOQxXa5Wyilw+RG5YTEppjuzjs4keUTWY5lB8+vlp 25ABsjjRhTUMT5I78dzuhLnDJQdHi+ahhIYbH/tZOhE6oN/1smVjnbXL3 G6ze0IChhKH9SGHMiICTaqxAWIZ+XGEgOSO74ExCV2WGfImxwhHZhuBHU c/G47GOXYDQrw6V5OFMk9OCV6/yIOyrxLA8GVWFeWZT0J88ZG7NL959Yr CUHW9VK3WaWTYg9EB+owsNh+oBqVwVhqSZw2+2K+omki0zzrdNTP3MhZQ F5Zl1ATK0UWyvdxdIhz1YREeU3OWA1J/QZxOrmqchYTKQzm0R8ccuCQjt w==; X-IronPort-AV: E=McAfee;i="6400,9594,10323"; a="326963060" X-IronPort-AV: E=Sophos;i="5.90,276,1643702400"; d="scan'208";a="326963060" Received: from orsmga008.jf.intel.com ([10.7.209.65]) by orsmga105.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 20 Apr 2022 08:32:53 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.90,276,1643702400"; d="scan'208";a="576639245" Received: from fmsmsx604.amr.corp.intel.com ([10.18.126.84]) by orsmga008.jf.intel.com with ESMTP; 20 Apr 2022 08:32:52 -0700 Received: from fmsmsx611.amr.corp.intel.com (10.18.126.91) by fmsmsx604.amr.corp.intel.com (10.18.126.84) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2308.27; Wed, 20 Apr 2022 08:32:52 -0700 Received: from fmsedg601.ED.cps.intel.com (10.1.192.135) by fmsmsx611.amr.corp.intel.com (10.18.126.91) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2308.27 via Frontend Transport; Wed, 20 Apr 2022 08:32:51 -0700 Received: from NAM11-BN8-obe.outbound.protection.outlook.com (104.47.58.173) by edgegateway.intel.com (192.55.55.70) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.1.2308.27; Wed, 20 Apr 2022 08:32:51 -0700 ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=M1gQFgcfDKulgheTLG1StKD0HQdea/EnuJ/6zct1TfzqfV7RdOgRbufPeOKsHpEwekYwB7MxHMUwo7w/k1UsAWbkTG0kgQIfwapFWqoO29Frtq/yO2j5EwTrslPTqSUmak6g3iqjRvHNXqVj2aU+d7nueLc9Ujwm+m6gimKEKBl+4LgvaDbEMxGrZMcMdLrkbsr8jBfjaTz1hBlK2jTBUd78mn+PVe2wleZf1gI2mSLtCZ8NLn1ZQxmGvNLDkmIkPSXRSDcQtiufjjYoZkqwiGsiQI0KqKkNRUdqB7uLK/OhPTi7GZACLJY8gLF2j2pCMb6fNvZgPUwmTCXVQvyILA== 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=YCp7uTPmtsVxr2SKIFV6lNiFCm9M3CEv7xsYdUr0R+s=; b=NQ2HKBNknbDZalBnBTN95VCfaYSuY5pwPxhz6a0quhyRa8PFThFwJLtFQaO8BXX3x5YNzuhzY9syqGBDod3xf08u3FCoDxi1c1pcMMNaKC4sYRl9YJRSn7fHNKWIYddo++bkAGolZe2neNRPJZDFSEQcyqrDh1sZJHHTP5hU/J+g9bKkpeGpHdN8jEi2TQQj8AMq3hbC88p+r/9U8FduY0JcG2DrQZ/jP8lR75qYepjtkw3i1PjJCSXVuNM7S2SC7oAbnpNsQRig3ADrfnNqwTrLr2MPx9Qi1gcJL3Ib28Y1Zo+hexHasyzdcAzfpFdQ6oRoXs8/7wq9x8DAfy+u0A== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=intel.com; dmarc=pass action=none header.from=intel.com; dkim=pass header.d=intel.com; arc=none Authentication-Results: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=intel.com; Received: from PH0PR11MB5093.namprd11.prod.outlook.com (2603:10b6:510:3e::23) by CH2PR11MB4471.namprd11.prod.outlook.com (2603:10b6:610:46::33) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.5164.20; Wed, 20 Apr 2022 15:32:49 +0000 Received: from PH0PR11MB5093.namprd11.prod.outlook.com ([fe80::28af:8ec5:1817:1af1]) by PH0PR11MB5093.namprd11.prod.outlook.com ([fe80::28af:8ec5:1817:1af1%3]) with mapi id 15.20.5164.025; Wed, 20 Apr 2022 15:32:49 +0000 Message-ID: <6c2ec2b9-eba3-25ea-155d-04049b3a0a11@intel.com> Date: Wed, 20 Apr 2022 16:32:44 +0100 User-Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:91.0) Gecko/20100101 Firefox/91.0 Thunderbird/91.7.0 Subject: Re: [PATCH] eal/linux: skip attaching to external memory chunk Content-Language: en-US To: Deepak Khandelwal CC: , References: <1649075577-67300-1-git-send-email-deepak.khandelwal@intel.com> From: "Burakov, Anatoly" In-Reply-To: <1649075577-67300-1-git-send-email-deepak.khandelwal@intel.com> Content-Type: text/plain; charset="UTF-8"; format=flowed Content-Transfer-Encoding: 7bit X-ClientProxiedBy: LO2P265CA0116.GBRP265.PROD.OUTLOOK.COM (2603:10a6:600:c::32) To PH0PR11MB5093.namprd11.prod.outlook.com (2603:10b6:510:3e::23) MIME-Version: 1.0 X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: beba4cb9-1205-4d30-700f-08da22e30673 X-MS-TrafficTypeDiagnostic: CH2PR11MB4471:EE_ X-Microsoft-Antispam-PRVS: X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: 5OvoBfyBpWFZJ8snNVO0XBZWhN4c40w9+7bYuxQZzIYkEXZxba4D2whNgWjQgHt8wDpdLCm1+aens1kr/incUewHn0L3sFE8Jaz+5mf/pRJ0rHLgrYBTOOiFJnMVup+h56bO9XQZ7FnFnPKTr/eLtxPH/+0SlCSzQ8ukueHMmzR+Eybe02eMrOEfh2nPXMtUGn8NHWySIrZiK63zHW12UfpJSup+DVt87a5kxnKTLHAaOXSDu9wGO9Ms+xrgN8Tnbc+Km2KaLkesu4v+AfUpPnn6dnNkTf6w6UqX1DMzVKjmMkKTLbExeWr4Th9Dp+n2KziyHCe7TTeO70pgMLEnpXPxpiQNpTPPY//zejQC4u7/UXVE5JrNLfiHhwKIuPA0siBbVccbh+Cs92V/ebHxTXl/tEtLopjlESEJooibHg1wn4DjT+o/eDQN6aXq5o7QW92dh7kH6ZP/AqQCeGdSzYhTdg9V5xoifZQVGRgjPMk14pUrl71fwpYoKTyaUu5xRqOBQOanptyrkMcP2CbeUFJPTGUqqDg1fS/W9ZQnlZitKyDnKG3zfI5a4CqmL/RCteBJe/LHtD4CpKlNTp6ceD25SCyx8PWV+R/SyRzYfjjtSPlFgborGnLdv6OHIuny8bwWuMN500i2wAavxGlTmWg03jkU9HkZTYMv3WpR6pEo4PK0rAkRqInoAriy0TpR781gJP3VnNoLwjra2DW8Z0hNDymhSR2vMfPxINzLgIw= X-Forefront-Antispam-Report: CIP:255.255.255.255; CTRY:; LANG:en; SCL:1; SRV:; IPV:NLI; SFV:NSPM; H:PH0PR11MB5093.namprd11.prod.outlook.com; PTR:; CAT:NONE; SFS:(13230001)(366004)(186003)(82960400001)(4326008)(5660300002)(6512007)(6666004)(6862004)(26005)(2906002)(316002)(6506007)(8936002)(53546011)(31686004)(83380400001)(36756003)(450100002)(66946007)(66556008)(8676002)(2616005)(6636002)(508600001)(86362001)(6486002)(37006003)(31696002)(66476007)(38100700002)(45980500001)(43740500002); DIR:OUT; SFP:1102; X-MS-Exchange-AntiSpam-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-MessageData-0: =?utf-8?B?RlV3Qm4vTjYzZG94VFBYb01zQXhweWpvRVNMOHNzMU5xVW8zd3UyRUU1N0NB?= =?utf-8?B?Rmp6YTFwSkpyWFBDbDFTUlhuYU9WOUo3S2w0bjhPdTBpQnFZdGVoVU5CbGM2?= =?utf-8?B?cjh4VytWTzlZVDlMSmxnUHlzRjBKVkRUQjdOTDI5czJFZGtsT3pGVGFRRzh4?= =?utf-8?B?bnJzRVVRWDV2OGYrYnBBb1dvaG5wQndEN0tkTVdzM2FyUEFyT2pUcGtvVEZM?= =?utf-8?B?OGVvdWtxeklnSGVSUjBOb1J5SXRnazV4bFI0NGkvMWFPbEhneEZBYkNaQndM?= =?utf-8?B?L2l5Z3IyS1lnQnZUb1B5Ri81bFJoc250MEpTQ2ZSaGhQSzFQeXRvdkQrRjRM?= =?utf-8?B?NDJGWFJhUGZqYytaeFo2UUtKTm1YZDZ2dHJCL1NqNXBwRnVUSUw3NFZxODZV?= =?utf-8?B?Nk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=?utf-8?B?K0xpU1N2eXhUVExrUW9aNEpxaU12WW55SlNmaDZJaWtJWGxnWmJXcklXN2tw?= =?utf-8?B?VHFvakVRLzNsOGJKUkhPNDdLcFBBOTZEVXZabVZOaTVoN2REWldoMnY2Tm40?= =?utf-8?Q?mMxppgI+HdQKLazc=3D?= X-MS-Exchange-CrossTenant-Network-Message-Id: beba4cb9-1205-4d30-700f-08da22e30673 X-MS-Exchange-CrossTenant-AuthSource: PH0PR11MB5093.namprd11.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 20 Apr 2022 15:32:49.0008 (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: UX8Zde01m/uYWAOB55ovD67aNKFN9n5s8EIg0oTK9lQnMO38SDNf6mWA25CusYtE9qInapKk383zAp34AjFETyX84nS9Uj0zKjKS+ESjp8A= X-MS-Exchange-Transport-CrossTenantHeadersStamped: CH2PR11MB4471 X-OriginatorOrg: intel.com X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dev-bounces@dpdk.org On 04-Apr-22 1:32 PM, Deepak Khandelwal wrote: > when secondary process is initialized(rte_eal_init), > external memroy segments should not be attached. > These segments will be attached by explicitly invoking > rte_malloc_heap_memory_attach API > > Fixes: ff3619d6244b ("malloc: allow attaching to external memory chunks") > Cc: stable@dpdk.org > > Signed-off-by: Deepak Khandelwal > Suggested-by: Anatoly Burakov > --- > lib/eal/linux/eal_memory.c | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > > diff --git a/lib/eal/linux/eal_memory.c b/lib/eal/linux/eal_memory.c > index ee1a9e6..18d2176 100644 > --- a/lib/eal/linux/eal_memory.c > +++ b/lib/eal/linux/eal_memory.c > @@ -1875,7 +1875,7 @@ void numa_error(char *where) > msl = &mcfg->memsegs[msl_idx]; > > /* skip empty memseg lists */ > - if (msl->memseg_arr.len == 0) > + if (msl->memseg_arr.len == 0 || msl->external) > continue; > > if (rte_fbarray_attach(&msl->memseg_arr)) { Actually, this needs to be implemented for BSD as well. Windows doesn't have support for secondary processes yet, so it's not applicable to Windows as far as i can tell. -- Thanks, Anatoly