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 A29ACA034C; Thu, 24 Feb 2022 17:01:49 +0100 (CET) Received: from [217.70.189.124] (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 917E441156; Thu, 24 Feb 2022 17:01:49 +0100 (CET) Received: from mail-pf1-f177.google.com (mail-pf1-f177.google.com [209.85.210.177]) by mails.dpdk.org (Postfix) with ESMTP id D6CF44114D for ; Thu, 24 Feb 2022 17:01:48 +0100 (CET) Received: by mail-pf1-f177.google.com with SMTP id y11so2254129pfa.6 for ; Thu, 24 Feb 2022 08:01:48 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=networkplumber-org.20210112.gappssmtp.com; s=20210112; h=date:from:to:cc:subject:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=wfABh28KVF/fwDZYF+u6Iw7ojuVTfFoH2Fib47+gQII=; b=UDj3sTWuzmdb78/CBbh8SpguiFw3GSpKun6j0lyOZyIBhv2S+NMnXvdnUCMd6Y9bUR Hf3WYId3RNEQahUNd99cPGME50fDx/+zhznvE9u3r7i4L8yFo534O6a5VRcnojkNL5J7 uQdTjS85Q0bqfSUWPc1/WrwcNeyALnrez4CkeEUrx4fZ59qY2mHazeLln97T5extb9lI ImgfHnTvUBq2ObVCbX46GZ3tNlX8LWC3OqjmIxlmko19SDF5Bu/iXM9i8DtPOmCf9ldJ dEcuRKnieB2QJV8y5uH2c4eTqf5mLlwgVNrOPwZYLrMr9kz1lI9IJ7b7DNyDUOFq8YHC F8Ww== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:date:from:to:cc:subject:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=wfABh28KVF/fwDZYF+u6Iw7ojuVTfFoH2Fib47+gQII=; b=mPUkLmKXZBBbGXY21w7JWHwdYpEf6hsSR1L0mPQnIG72CJxj9QdynsJ0a56nPaLZbu CsN6uddXO7ehEut3FywMTbbVjeTxIHOLHPskySgPa3LwTh1SXlZ3fpUZWr1lcJ5Shanc G8GfX0DW1KCKvn+dzWvY+nJ8jiqBOfGVsQSshAGRuFC1BuXW87Fkzc5NDHCcOJ8NzEer 0xcmkRu2P2yHmup0FYQDhnnuWLBFseJMUFe+YGicMv9TjmVfZDDpycxldXZV4QLM8Hhq 5kyC8098xvn4s2GuCNNTJPulET+DkkBQNjFm6Fmi1hhuThW/00me42vlVzZlZj3K/SHx RQqw== X-Gm-Message-State: AOAM533c6yA17+fIUIYFAvSXOse2YyvXh82iVxokDsUSKo2kh3VMOLm5 SHfSenrN+hU4nwDrZfx25bPljWdbZ+Tse74y X-Google-Smtp-Source: ABdhPJwBl6V2HJda8xTwLJ3HIT/UCxRgvyeDRc/zoqzdJ6dzs8EeQqwcNJadKjBA+GsfeNQQtR/b5w== X-Received: by 2002:a05:6a00:84b:b0:4f2:a695:e356 with SMTP id q11-20020a056a00084b00b004f2a695e356mr3625367pfk.0.1645718508022; Thu, 24 Feb 2022 08:01:48 -0800 (PST) Received: from hermes.local (204-195-112-199.wavecable.com. [204.195.112.199]) by smtp.gmail.com with ESMTPSA id e17sm3630439pfv.219.2022.02.24.08.01.47 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 24 Feb 2022 08:01:47 -0800 (PST) Date: Thu, 24 Feb 2022 08:01:45 -0800 From: Stephen Hemminger To: Tianli Lai Cc: dev@dpdk.org Subject: Re: [PATCH] app/pdump: free mempool at cleanup resources Message-ID: <20220224080145.362f27ed@hermes.local> In-Reply-To: <1645704898-52464-1-git-send-email-laitianli@tom.com> References: <1645704898-52464-1-git-send-email-laitianli@tom.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 Thu, 24 Feb 2022 20:14:58 +0800 Tianli Lai wrote: > + if (pt->mp) { > + rte_mempool_free(pt->mp); > + pt->mp = NULL; Check for null is unnecessary here, rte_mempool_free(NULL) is nop.