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 75C4141C26; Tue, 7 Feb 2023 01:22:31 +0100 (CET) Received: from mails.dpdk.org (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 5D23240F18; Tue, 7 Feb 2023 01:22:31 +0100 (CET) Received: from mail-pj1-f42.google.com (mail-pj1-f42.google.com [209.85.216.42]) by mails.dpdk.org (Postfix) with ESMTP id 4E8D940ED9 for ; Tue, 7 Feb 2023 01:22:30 +0100 (CET) Received: by mail-pj1-f42.google.com with SMTP id hv11-20020a17090ae40b00b002307b580d7eso9438525pjb.3 for ; Mon, 06 Feb 2023 16:22:30 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=networkplumber-org.20210112.gappssmtp.com; s=20210112; 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=nqM9iBB6HmWs88PnCny4I09GaCypoIeRtv2BG5TNc9w=; b=MrwoIoql8ABoJmDW4rB5rz9+v2tUkuIQDTtHdS5RHqto8jMwz1rSNn50W11WlijyYD 8AugcjNr5FfNfZREWf3kcy9gRnSa2j8ZWhAPbEJ47B3ACu3M3YJtGSnNPRoO6gFM0fYt WCN+UGASI3ZII8yddGxrFhM6Tj7im9VeBwLHzV/maTrD2JTmmHM9mRZ46EAZf0zpHAZz tH1lQF5I1keKpJcyYuzKnxuz96l7ptGxinVVstoZgOYnJYjkwr4+OPUFZ5ljShCr6MMl IDy4oApYmmnjf17kNVWzH+zOYV42Ig4ktquzGUKdPk7A10Ix3ss1P4SU4Bym2Oro0hkF JvVA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; 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=nqM9iBB6HmWs88PnCny4I09GaCypoIeRtv2BG5TNc9w=; b=OM+25lER6VmXVtudgYtLZM4fcQ/wfM+M/jGdN6Ki9hIf6SCeSOx5LUjd4rPS1/48i8 jqaWi1m0wRcChTsQrUbuB6nSgaOBpkHAKtcKZeJubdbjWw1buoIfFhOvIewin7V4DwKk hZvhc5wKhp1w+0tjoSXGuL5mnwjcVUvASLPWBwBsswqwpPK+OsssNYEIat+sd9qnnuls 9cg+USoQ1ngs+pZV1BKYztjWVulePcc0rY1dsgXcQ+uKjbkzO8dPSV8u8kA7VWCs6xG4 c7S0ymN2m68iwYjgS8CjT7W25HM3D4OC0fAkQLAz7S6oi4nLzvXailZ7zGDajHUPAqF0 AzHg== X-Gm-Message-State: AO0yUKWfWQ0Pny2bRTjVBXT0MsIuvdyKran+Wy8/muPAdfEKh7PItMNt 8xNHl48jszQW8xitibHbmvUiKg== X-Google-Smtp-Source: AK7set9XMYcvIU6RkMlstr2eRt8KvhcL4aYtjo2hDAYcNY42wqbqPm3Ng5/t2skFjp10ZElpfKxAag== X-Received: by 2002:a17:90b:4b8d:b0:22c:9078:181 with SMTP id lr13-20020a17090b4b8d00b0022c90780181mr1654419pjb.33.1675729349490; Mon, 06 Feb 2023 16:22:29 -0800 (PST) Received: from hermes.local (204-195-120-218.wavecable.com. [204.195.120.218]) by smtp.gmail.com with ESMTPSA id p3-20020a17090b010300b0022c326ad011sm3618943pjz.46.2023.02.06.16.22.29 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 06 Feb 2023 16:22:29 -0800 (PST) Date: Mon, 6 Feb 2023 16:22:27 -0800 From: Stephen Hemminger To: Abdullah Sevincer Cc: dev@dpdk.org, jerinj@marvell.com Subject: Re: [PATCH v3] app/procinfo: display eventdev xstats for PMD data Message-ID: <20230206162227.2a8234c3@hermes.local> In-Reply-To: <20230206230505.3029148-1-abdullah.sevincer@intel.com> References: <20220409153056.1010236-1-timothy.mcdaniel@intel.com> <20230206230505.3029148-1-abdullah.sevincer@intel.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 Mon, 6 Feb 2023 17:05:05 -0600 Abdullah Sevincer wrote: > + > + size = (unsigned int)ret; /* number of names */ > + > + /* Get memory to hold stat names, IDs, and values */ > + > + xstats_names = malloc(sizeof(struct rte_event_dev_xstats_name) * size); > + ids = malloc(sizeof(unsigned int) * size); > + > + > + if (!xstats_names || !ids) > + rte_panic("unable to alloc memory for stats retrieval\n"); You might want to use calloc() here. Seems like lots of extra blank lines.