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 6EE914298A; Wed, 19 Apr 2023 16:42:39 +0200 (CEST) Received: from mails.dpdk.org (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 01CD440A79; Wed, 19 Apr 2023 16:42:39 +0200 (CEST) Received: from mail-pj1-f48.google.com (mail-pj1-f48.google.com [209.85.216.48]) by mails.dpdk.org (Postfix) with ESMTP id 75EEE4021F for ; Wed, 19 Apr 2023 16:42:37 +0200 (CEST) Received: by mail-pj1-f48.google.com with SMTP id h24-20020a17090a9c1800b002404be7920aso619578pjp.5 for ; Wed, 19 Apr 2023 07:42:37 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=networkplumber-org.20221208.gappssmtp.com; s=20221208; t=1681915356; x=1684507356; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:subject:cc:to:from:date:from:to:cc:subject:date :message-id:reply-to; bh=QujMnk8XgqpyCe8niKBoFpYHp2WIUK7Je/Yd0CtyIHo=; b=XOnh0cMYqCO+JdGMDvSOk5BdYbgnfWj6wi4cvl6sIHrgbI16r0zOFlCFj6RAkCN2wN euhhtO2Re5nNsM3YwaTPONh2A9Lm0ski6X2xB4CoXFplSV5mc1ZLoaEFkfCK6xBOqCML Q8GgujE/iVsOFarokXrR4osGMqHLx92QT0MLGCVI9ximVqGLFysEGpCiZw78uB8P4Fml Phux1g/Q6MNl+NbSzHAGNSjxJ3TZHADavxYTjutpZsZbABA/SxyVHNZkshrcQDsd8Tvi hcJjLk+XY+pD8EYicXfksaJ3fooxMvCl2/Mf2etrci0hkvaMB0/bZdyWPlV7+P+JI7fC cK3g== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1681915356; x=1684507356; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:subject:cc:to:from:date:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=QujMnk8XgqpyCe8niKBoFpYHp2WIUK7Je/Yd0CtyIHo=; b=gmXTpG9+1uU8jJ46LKO0XtBHxga9Cg1qqwmBFetZmNl0BQ0ETQIHbBNLD478gE8ifV /Cwpc5f5fNUXyax/AsmhmnwpSHMO95/9y3+S+puwUazspMsTwPuPLkReT8RDpENP5Q38 iwWM9UxsXURNfyKampztYRq8SJFEbToLV/UNwOpT0RwkCVN61M2LDSY84H5tcYlosQmV Cgo37hhgCEt4psfp8UT0zxYbRqR8Feogh5xrlsxoZbOMG8UJA/0fx2VBRfhDyvKTGvI+ ATXD/FXAWUguEbFs7ZfWIr00oOr68NEWxfQe9+IfOedUmkRNCZ8FBQ2KESM0Sam5ooyb GRyg== X-Gm-Message-State: AAQBX9fgXiQs/WCfuRaVmFPkfXp8ZZY3/sq8kinb6wkWDykt5/shud63 c+q1jtw/eFjZQi/mrHKGcHum2g== X-Google-Smtp-Source: AKy350boGaHGiBGsoQOA7GdsiTxzAwqXrUMOewmUhmTyPFWeAHRVo8U7W9sNifzaXF+X+OR2durinw== X-Received: by 2002:a05:6a20:1f20:b0:f0:2084:4cab with SMTP id dn32-20020a056a201f2000b000f020844cabmr3282268pzb.36.1681915356612; Wed, 19 Apr 2023 07:42:36 -0700 (PDT) Received: from hermes.local (204-195-120-218.wavecable.com. [204.195.120.218]) by smtp.gmail.com with ESMTPSA id l15-20020a62be0f000000b006259e883ee9sm11082504pff.189.2023.04.19.07.42.35 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 19 Apr 2023 07:42:36 -0700 (PDT) Date: Wed, 19 Apr 2023 07:42:33 -0700 From: Stephen Hemminger To: Ophir Munk Cc: , Bruce Richardson , "Devendra Singh Rawat" , Alok Prasad , Ophir Munk , Matan Azrad , "Thomas Monjalon" , Lior Margalit Subject: Re: [RFC] lib: set/get max memzone segments Message-ID: <20230419074233.75bc7f47@hermes.local> In-Reply-To: <20230419083634.2027689-1-ophirmu@nvidia.com> References: <20230419083634.2027689-1-ophirmu@nvidia.com> MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit 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 Wed, 19 Apr 2023 11:36:34 +0300 Ophir Munk wrote: > +int ecore_mz_mapping_alloc(void) > +{ > + ecore_mz_mapping = rte_malloc("ecore_mz_map", 0, > + rte_memzone_max_get() * sizeof(struct rte_memzone *)); Why not use rte_calloc(), and devices should be using NUMA aware allocation to put the memzone on same NUMA node as the PCI device.