From patchwork Tue Apr 25 01:02:40 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: "Zhijian Li (Fujitsu)" X-Patchwork-Id: 13222753 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 5A3F3C7618E for ; Tue, 25 Apr 2023 01:04:41 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229756AbjDYBEj (ORCPT ); Mon, 24 Apr 2023 21:04:39 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:50834 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S232473AbjDYBEi (ORCPT ); Mon, 24 Apr 2023 21:04:38 -0400 Received: from mail1.bemta37.messagelabs.com (mail1.bemta37.messagelabs.com [85.158.142.113]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 647A993E6; Mon, 24 Apr 2023 18:04:21 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=fujitsu.com; s=170520fj; t=1682384659; i=@fujitsu.com; bh=FMaqm65I6znwkEfqLF7qaD9JB/kh1YaaVo2inzzcgVI=; h=From:To:CC:Subject:Date:Message-ID:MIME-Version:Content-Type; b=jCtkZBr/Sl8Hte/EqYxAoeO9QvVeYsG3FvJpNoQZ+XeSYfHmnmlVARPeH7bTguEor 2//KgsgkAwn94SYRfZFcu5e9VpQFd1co9vvFhT8uonZ2pAVgr3if0Fd09qx+krAjWf UqORIktTG2K9foiD98gMMezO+pp07Y5KIoXKaw9EYeTGovNgCNWbGA6zZgwP3SrNee OydFmDo2ivy1kHbV9FjLX0AGrYmfPhYxb+1STqxa2Ed5IM52K/LcBBhCXhaKEjdS1e xzTLdwDHUWV1N+aGHArfD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nu CSu/f3OSlcpsC1/N8v6H1sr0j3fZd8sE3ROyPfbleZGVWuS2K2salViKMxINtZiLihMBOPyzd HMDAAA= X-Env-Sender: lizhijian@fujitsu.com X-Msg-Ref: server-12.tower-728.messagelabs.com!1682384657!373578!1 X-Originating-IP: [62.60.8.97] X-SYMC-ESS-Client-Auth: outbound-route-from=pass X-StarScan-Received: X-StarScan-Version: 9.104.2; banners=-,-,- X-VirusChecked: Checked Received: (qmail 15694 invoked from network); 25 Apr 2023 01:04:18 -0000 Received: from unknown (HELO n03ukasimr01.n03.fujitsu.local) (62.60.8.97) by server-12.tower-728.messagelabs.com with ECDHE-RSA-AES256-GCM-SHA384 encrypted SMTP; 25 Apr 2023 01:04:18 -0000 Received: from n03ukasimr01.n03.fujitsu.local (localhost [127.0.0.1]) by n03ukasimr01.n03.fujitsu.local (Postfix) with ESMTP id 7EEA810019D; Tue, 25 Apr 2023 02:04:17 +0100 (BST) Received: from R01UKEXCASM223.r01.fujitsu.local (R01UKEXCASM223 [10.182.185.121]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-SHA384 (256/256 bits)) (No client certificate requested) by n03ukasimr01.n03.fujitsu.local (Postfix) with ESMTPS id 723BC10019C; Tue, 25 Apr 2023 02:04:17 +0100 (BST) Received: from 0819309620d6.localdomain (10.167.234.230) by R01UKEXCASM223.r01.fujitsu.local (10.182.185.121) with Microsoft SMTP Server (TLS) id 15.0.1497.42; Tue, 25 Apr 2023 02:04:14 +0100 From: Li Zhijian To: , , CC: , , , , Li Zhijian Subject: [PATCH for-next v3 0/3] RDMA/rtrs: bugfix and cleanups Date: Tue, 25 Apr 2023 01:02:40 +0000 Message-ID: <1682384563-2-1-git-send-email-lizhijian@fujitsu.com> X-Mailer: git-send-email 1.8.3.1 MIME-Version: 1.0 X-Originating-IP: [10.167.234.230] X-ClientProxiedBy: G08CNEXCHPEKD07.g08.fujitsu.local (10.167.33.80) To R01UKEXCASM223.r01.fujitsu.local (10.182.185.121) X-Virus-Scanned: ClamAV using ClamSMTP Precedence: bulk List-ID: X-Mailing-List: linux-rdma@vger.kernel.org V3: - minor comments fixes and add tags V2: - Add new patch2 to fix a memory leak - rewrite original patch2 to patch3 by refactoring the cleanup path instead of introducing a new flag - Drop original patch3: RDMA/rtrs: Fix use-after-free in rtrs_clt_rdma_cm_handler The problem it tried to addressing doesn't appear after the new patch3 where it adjust the cleanup order It's trying to fix 1 issue triggered by the following script which connect/disconnect rnbd frequently. # cat rnbd-self.sh #!/bin/bash /root/rpma/tools/config_softroce.sh eth0 modprobe rnbd_server modprobe rnbd_client while true; do echo "sessname=xyz path=ip: device_path=/dev/nvme0n1" > /sys/devices/virtual/rnbd-client/ctl/map_device for i in /sys/block/rnbd*/rnbd/unmap_device do echo "normal" > $i done done Li Zhijian (3): RDMA/rtrs: remove duplicate cq_num assignment RDMA/rtrs: Fix the last iu->buf leak in err path RDMA/rtrs: Fix rxe_dealloc_pd warning drivers/infiniband/ulp/rtrs/rtrs-clt.c | 56 +++++++++++--------------- drivers/infiniband/ulp/rtrs/rtrs.c | 4 +- 2 files changed, 26 insertions(+), 34 deletions(-)