From patchwork Mon Nov 9 12:16:27 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Maxime Coquelin X-Patchwork-Id: 83842 Return-Path: X-Original-To: patchwork@inbox.dpdk.org Delivered-To: patchwork@inbox.dpdk.org Received: from dpdk.org (dpdk.org [92.243.14.124]) by inbox.dpdk.org (Postfix) with ESMTP id ABA27A0527; Mon, 9 Nov 2020 13:16:45 +0100 (CET) Received: from [92.243.14.124] (localhost [127.0.0.1]) by dpdk.org (Postfix) with ESMTP id 1AA27593A; Mon, 9 Nov 2020 13:16:44 +0100 (CET) Received: from us-smtp-delivery-124.mimecast.com (us-smtp-delivery-124.mimecast.com [216.205.24.124]) by dpdk.org (Postfix) with ESMTP id 75EB1F90 for ; Mon, 9 Nov 2020 13:16:43 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1604924201; 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; bh=4du4Kdn8Vg8nDE2weMtXWQzLXW5tB01eMEm5GsqJGRw=; b=cPWlRCudlc+BJ+JvQtyEfn687anxFAzP75FzlcYye77h6wy81WrGEOhYkjDhiZWa/9Zooe 0vLyCcL5Dr7PThOtvRzFYVF2N5rL/yyb2k+4450DkhJwFoGzZn6YkZLWfYvtyK66erAtZ3 3AmMQtm2G77uJSMKizfaCozXcUaekHI= Received: from mimecast-mx01.redhat.com (mimecast-mx01.redhat.com [209.132.183.4]) (Using TLS) by relay.mimecast.com with ESMTP id us-mta-107-k74EsHrbNGWYR10qLl0qCA-1; Mon, 09 Nov 2020 07:16:39 -0500 X-MC-Unique: k74EsHrbNGWYR10qLl0qCA-1 Received: from smtp.corp.redhat.com (int-mx03.intmail.prod.int.phx2.redhat.com [10.5.11.13]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mimecast-mx01.redhat.com (Postfix) with ESMTPS id C85381868416; Mon, 9 Nov 2020 12:16:37 +0000 (UTC) Received: from localhost.localdomain (unknown [10.36.110.32]) by smtp.corp.redhat.com (Postfix) with ESMTP id D69906EF5C; Mon, 9 Nov 2020 12:16:32 +0000 (UTC) From: Maxime Coquelin To: dev@dpdk.org, xuan.ding@intel.com, stephen@networkplumber.org, thomas@monjalon.net, stable@dpdk.org, chenbo.xia@intel.com Cc: Maxime Coquelin Date: Mon, 9 Nov 2020 13:16:27 +0100 Message-Id: <20201109121630.251603-1-maxime.coquelin@redhat.com> MIME-Version: 1.0 X-Scanned-By: MIMEDefang 2.79 on 10.5.11.13 Authentication-Results: relay.mimecast.com; auth=pass smtp.auth=CUSA124A263 smtp.mailfrom=maxime.coquelin@redhat.com X-Mimecast-Spam-Score: 0 X-Mimecast-Originator: redhat.com Subject: [dpdk-dev] [PATCH v3 0/3] vhost: fix fd an memory leaks X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dev-bounces@dpdk.org Sender: "dev" This series fixes several leaks in Vhost-user requests handling. Thanks to Xuan Ding from Intel for reporting these issues. Changes in v3: - Remove the right closing of fds. (Chenbo) Changes in v2: - Fix typos in commit messages. (Chenbo) - Remove useless closing of fds in set_log_base. (Chenbo) Maxime Coquelin (3): vhost: fix error path when setting memory tables vhost: fix fd leak in dirty logging setup vhost: fix fd leak in kick setup lib/librte_vhost/vhost_user.c | 79 ++++++++++++++++++++++------------- 1 file changed, 50 insertions(+), 29 deletions(-)