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 6C592A0547 for ; Tue, 31 Aug 2021 12:00:11 +0200 (CEST) Received: from [217.70.189.124] (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 4D88F40141; Tue, 31 Aug 2021 12:00:11 +0200 (CEST) Received: from us-smtp-delivery-124.mimecast.com (us-smtp-delivery-124.mimecast.com [170.10.129.124]) by mails.dpdk.org (Postfix) with ESMTP id 1856C40141 for ; Tue, 31 Aug 2021 12:00:09 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1630404009; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=2wpvQkliXf64oftf9CYMOEhxJEI1iP4rYx2Qg9PUMU8=; b=U1hQVN43kzFw111Ff6vIRqDsUqwmBRUOoe0k07OnbHNr4FwD+4MEts/lZKXN0DfW8Zv25R 60dcdFL47xCEpkTCzx/f5x17bAufVjebZ/fwhvVo+yqWl5hXcdk9X3u/b7tH8Zk32AfnuR kXS/B4xBdpvrk7uOexX3c6HTDN1U83w= Received: from mail-wm1-f70.google.com (mail-wm1-f70.google.com [209.85.128.70]) (Using TLS) by relay.mimecast.com with ESMTP id us-mta-15-oWevoa4hPJ-wsa338WX1sA-1; Tue, 31 Aug 2021 06:00:08 -0400 X-MC-Unique: oWevoa4hPJ-wsa338WX1sA-1 Received: by mail-wm1-f70.google.com with SMTP id c2-20020a7bc8420000b0290238db573ab7so1032805wml.5 for ; Tue, 31 Aug 2021 03:00:07 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:to:cc:references:from:subject:message-id:date :user-agent:mime-version:in-reply-to:content-language :content-transfer-encoding; bh=2wpvQkliXf64oftf9CYMOEhxJEI1iP4rYx2Qg9PUMU8=; b=NZhEAeXNq0DzNun3V0D/S1xoYy9+I0bpAxgxT9eQKsQsAF3feOLuxQR8g8JFhJD9hk 5OZmRdeLyj9HPvlR5gKovVoRQY6viBiZzShEPwxfqqSNmtcZbdGIVjHAIEN+n9ffVoGV DBolkEQmvZ24yZfFqQ7+W3w3/8F/N+yg/Zqh3zkj/YTD10po6sTww/Shy8MIDjqHQ05a hlTBE6FdrmNjui8mck8PI80qrlRUfi+Dp/anJMNlP0pSX03R8J7D4OSLiHwpN27pltHB 9rnQJn8FW4LmbqoS2Cf7dub+mXNuWnH24hTEfwCQXiafCthrCojFMIDI7P3ZWlci3B/K 5K1w== X-Gm-Message-State: AOAM531NfpJl5lDF+9mP9ScL4sNRfOjyufXYZdDyB0RhnNT4ry+/sDUH d5viLvYxKbj2n8Dm9Nq+b1e5qvQEi+X5GDq0+/HR/P9LmWVcdMh/xxwptRm5t2i6ip7jFGu+UiR HOSSWds49pwkrnYL6iXVt8OyLEaMROliXEpfqylXvrrNHBFJbUOu/n7FsdP0= X-Received: by 2002:a1c:1f49:: with SMTP id f70mr3185018wmf.13.1630404006630; Tue, 31 Aug 2021 03:00:06 -0700 (PDT) X-Google-Smtp-Source: ABdhPJxViR9oHD6uLQ/9n5mP8F+rCyVtyEy0CuKXkCGoPDKszzv5Il/vocDcKIgtfit5y9oAo+3Oug== X-Received: by 2002:a1c:1f49:: with SMTP id f70mr3184992wmf.13.1630404006366; Tue, 31 Aug 2021 03:00:06 -0700 (PDT) Received: from [192.168.0.36] ([78.18.17.175]) by smtp.gmail.com with ESMTPSA id q14sm11300177wrc.31.2021.08.31.03.00.05 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Tue, 31 Aug 2021 03:00:05 -0700 (PDT) To: Qiming Chen , dev@dpdk.org Cc: haiyue.wang@intel.com, stable@dpdk.org References: <20210831032805.5520-1-chenqiming_huawei@163.com> <20210831080630.5719-1-chenqiming_huawei@163.com> From: Kevin Traynor Message-ID: <32c26bad-9da6-baa0-e810-b3efa1d729fd@redhat.com> Date: Tue, 31 Aug 2021 11:00:04 +0100 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:78.0) Gecko/20100101 Thunderbird/78.11.0 MIME-Version: 1.0 In-Reply-To: <20210831080630.5719-1-chenqiming_huawei@163.com> Authentication-Results: relay.mimecast.com; auth=pass smtp.auth=CUSA124A263 smtp.mailfrom=ktraynor@redhat.com X-Mimecast-Spam-Score: 0 X-Mimecast-Originator: redhat.com Content-Type: text/plain; charset=utf-8 Content-Language: en-US Content-Transfer-Encoding: 8bit Subject: Re: [dpdk-stable] [dpdk-dev] [PATCH v2] net/ixgbe: fix mbuf leak 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" On 31/08/2021 09:06, Qiming Chen wrote: > A local test found that repeated port start and stop operations during > the continuous SSE vector bufflist receiving process will cause the mbuf > resource to run out. The final positioning is when the port is stopped, > the mbuf of the pkt_first_seg pointer is not released. Resources leak. > The patch scheme is to judge whether the pointer is empty when the port > is stopped, and release the corresponding mbuf if it is not empty. > > Fixes: abf7275bbaa2 ("ixgbe: move to drivers/net/") That is a file rename, it should be when the functionality was introduced, so in this case: Fixes: af75078fece3 ("first public release") > Cc: stable@dpdk.org > > Signed-off-by: Qiming Chen > --- > v2: > Sync to stable@dpdk.org > --- > drivers/net/ixgbe/ixgbe_rxtx.c | 4 ++++ > 1 file changed, 4 insertions(+) > > diff --git a/drivers/net/ixgbe/ixgbe_rxtx.c b/drivers/net/ixgbe/ixgbe_rxtx.c > index c814a28cb4..bfdfd5e755 100644 > --- a/drivers/net/ixgbe/ixgbe_rxtx.c > +++ b/drivers/net/ixgbe/ixgbe_rxtx.c > @@ -2981,6 +2981,10 @@ ixgbe_reset_rx_queue(struct ixgbe_adapter *adapter, struct ixgbe_rx_queue *rxq) > rxq->rx_free_trigger = (uint16_t)(rxq->rx_free_thresh - 1); > rxq->rx_tail = 0; > rxq->nb_rx_hold = 0; > + > + if (rxq->pkt_first_seg != NULL) > + rte_pktmbuf_free(rxq->pkt_first_seg); > + > rxq->pkt_first_seg = NULL; > rxq->pkt_last_seg = NULL; > >