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 F00AEA0547 for ; Sun, 26 Sep 2021 23:18:36 +0200 (CEST) Received: from [217.70.189.124] (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id E1B104003F; Sun, 26 Sep 2021 23:18:36 +0200 (CEST) Received: from mail-io1-f43.google.com (mail-io1-f43.google.com [209.85.166.43]) by mails.dpdk.org (Postfix) with ESMTP id 0D30F4003F for ; Sun, 26 Sep 2021 23:18:35 +0200 (CEST) Received: by mail-io1-f43.google.com with SMTP id i62so4197846ioa.6 for ; Sun, 26 Sep 2021 14:18:34 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=broadcom.com; s=google; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=O/1IDpB6qoJ4OwILn+9sSuATT/0N5Zkfk7BlwBFYGAI=; b=fWW9GCg9+51yzaVRMeCSrReBphNxa1YecioghIgoWh5JQXakthFozGJBsgBZBkEl/F uPBaV6EqwlDwSBLKMsm7w5tVYYwQmUo20x5AWlmqEoZKcTdFAK1su2rQQysh9I6UFBaO TRQhDRQpAViIGv4pyNTvHs0SNkh+tlb2dUlI4= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=O/1IDpB6qoJ4OwILn+9sSuATT/0N5Zkfk7BlwBFYGAI=; b=c94kxReuOwgY8wkXdrtiEOcnDCywXdkkbwBW8WYvKOVZCXmdKdObc1szhUnEcjYi3S QjshezZw7TuiiB7+ebdSzO2GLlPtmBvXG33C+PFpFvF48K8qG9izUEyfTXEsRJgyy6b5 8PNts1kxbDQhsCy9VomGI0jOHKrWjioOZDCL8P3UQ9tnUmw6JlriC15aDz3F9w2td857 oNqlY6YqKNp7JyDNsRmZwI/nkERh8QTQiXLwqg0G8UVd0sXfx5gCMCk8kHwwaLkVf2ju +Ni3JhOW2f9S3cS5zQgpnmatFJVQftn3VhwJMp5cpvxgz9kaXK9HYEedSws0GkO1RIRY W1ew== X-Gm-Message-State: AOAM533MiQI9B4sbBUweWOZF9rKtbrnw/UMeQt+eu8OfNuPf82Ac7++S MJ9TacnmThXhyHVwrnONBc7TUZ4o4oW9WzJc/Qxs+yybAnY= X-Google-Smtp-Source: ABdhPJyG0qRFS8ZB2nmmgdNd6kisDAtHmNNH9XfwwAkAzxpp09Azhh0C2oN1b56+8H7x+FKx7TybCYyexQHk2qMOPLU= X-Received: by 2002:a6b:ec03:: with SMTP id c3mr18158656ioh.179.1632691114349; Sun, 26 Sep 2021 14:18:34 -0700 (PDT) MIME-Version: 1.0 References: <20210925005702.50971-1-ajit.khaparde@broadcom.com> In-Reply-To: <20210925005702.50971-1-ajit.khaparde@broadcom.com> From: Ajit Khaparde Date: Sun, 26 Sep 2021 14:18:18 -0700 Message-ID: To: dpdk-dev Cc: dpdk stable , Ferruh Yigit Content-Type: multipart/signed; protocol="application/pkcs7-signature"; micalg=sha-256; boundary="000000000000ea7e5805ccec8546" X-Content-Filtered-By: Mailman/MimeDel 2.1.29 Subject: Re: [dpdk-stable] [PATCH] net/bnxt: fix mem zone free for Tx and Rx rings X-BeenThere: stable@dpdk.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: patches for DPDK stable branches List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: stable-bounces@dpdk.org Sender: "stable" --000000000000ea7e5805ccec8546 Content-Type: text/plain; charset="UTF-8" On Fri, Sep 24, 2021 at 5:57 PM Ajit Khaparde wrote: > > The device cleanup logic was freeing most of the ring related memory, > but was not freeing up the mem zone associated with the rings. > This patch fixes the issue. > > Fixes: 2eb53b134aae ("net/bnxt: add initial Rx code") > Fixes: 6eb3cc2294fd ("net/bnxt: add initial Tx code") > Cc: stable@dpdk.org > > Signed-off-by: Ajit Khaparde > Reviewed-by: Lance Richardson > Reviewed-by: Somnath Kotur Patch applied to dpdk-next-net-brcm. > --- > drivers/net/bnxt/bnxt_rxr.c | 3 +++ > drivers/net/bnxt/bnxt_txr.c | 3 +++ > 2 files changed, 6 insertions(+) > > diff --git a/drivers/net/bnxt/bnxt_rxr.c b/drivers/net/bnxt/bnxt_rxr.c > index a40fa50138..4c1ee4294e 100644 > --- a/drivers/net/bnxt/bnxt_rxr.c > +++ b/drivers/net/bnxt/bnxt_rxr.c > @@ -1207,6 +1207,9 @@ void bnxt_free_rx_rings(struct bnxt *bp) > rte_free(rxq->cp_ring->cp_ring_struct); > rte_free(rxq->cp_ring); > > + rte_memzone_free(rxq->mz); > + rxq->mz = NULL; > + > rte_free(rxq); > bp->rx_queues[i] = NULL; > } > diff --git a/drivers/net/bnxt/bnxt_txr.c b/drivers/net/bnxt/bnxt_txr.c > index 47824334ae..9e45ddd7a8 100644 > --- a/drivers/net/bnxt/bnxt_txr.c > +++ b/drivers/net/bnxt/bnxt_txr.c > @@ -38,6 +38,9 @@ void bnxt_free_tx_rings(struct bnxt *bp) > rte_free(txq->cp_ring->cp_ring_struct); > rte_free(txq->cp_ring); > > + rte_memzone_free(txq->mz); > + txq->mz = NULL; > + > rte_free(txq); > bp->tx_queues[i] = NULL; > } > -- > 2.30.1 (Apple Git-130) > --000000000000ea7e5805ccec8546--