Received: by 2002:a05:6a10:206:0:0:0:0 with SMTP id 6csp3318786pxj; Tue, 11 May 2021 01:32:53 -0700 (PDT) X-Google-Smtp-Source: ABdhPJzfItB0v5Jh/GnoouqiTltmV/t+s/kly8cVsDnQUzf+FfPDlGut64LlDljc9rkTxtqdXjBj X-Received: by 2002:a02:1c81:: with SMTP id c123mr26510130jac.42.1620721973264; Tue, 11 May 2021 01:32:53 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1620721973; cv=none; d=google.com; s=arc-20160816; b=JUYfTQfQOqoY9X1Uw40CMaNtvgtZwp/JQ0IyBrq/L6VtcK5Al3Bm0mIziTm4c6noDj BD69O40U7CLgoI866+7ySs6ALJoEzBoi8l+k4Gi2qMyBZvZQhdCloVbP+PkWv0jFaSQL H/Q14QAIB8axkCJv+ms6tRKsi3VP2A8t9OLKqUWNWNcvOx7GpTg6TsqPQ7kTeaW1vGEE f33Kf3SWYGaGVPAgmrLXHbzzo8oUG5CqvWGqknE3wa1OeYA+WDMKoMAw9AEaywheAn8p lzbK2RH9Dt92LjuteMpb6/Sfr/g8tKcp3wcBFJVQ0Z2c7IgGYqwSV38VP1GoVC9ME1U2 Yg5w== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :message-id:date:subject:cc:to:from:dkim-signature; bh=jw7kwwcL/FUuXrIOaa2Zoi0gEcQ4thMvputekPsm8oY=; b=VMSPIUrLGUNkZ/iVcKxsYXkgsIHqNcTotaPufa19CLbuV1LhfA47e7eEzp6IXDyO5h SqXaAFPh3k1adynK0Ko+mTKEkXEZDIhbe7sX62hBFk6bJsVSBsyL6MM29S02gUQTYbqb wQNcp7PfLpODes2uu2m7zpEQfzEnjahiGfsDUqp8U9KEbYuc4yeJTVFmVK/brLaS5dej 6+CjlLqd8g8o/ycrCs7F8qiZxGkNKFiTt0OlZHDN+smOqo14RvdBszTlQvAmfOfaoSmq q/yVgOahOr9ZKMIumX2bjZA8f+fa+/d9gZRkoYOsZXn7KczD5hgNGTZ2/39GLBP5mkfT k36A== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=th7AUjJH; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id q4si19048951jas.111.2021.05.11.01.32.41; Tue, 11 May 2021 01:32:53 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=th7AUjJH; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S231132AbhEKIcs (ORCPT + 99 others); Tue, 11 May 2021 04:32:48 -0400 Received: from mail.kernel.org ([198.145.29.99]:42534 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S230445AbhEKIci (ORCPT ); Tue, 11 May 2021 04:32:38 -0400 Received: by mail.kernel.org (Postfix) with ESMTPSA id E18DF61466; Tue, 11 May 2021 08:22:20 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1620721341; bh=yzu85/4xlJKPn9R7vpreP5xgNqD3/5JCWkDrOoww7go=; h=From:To:Cc:Subject:Date:From; b=th7AUjJHQVTN16usTH7cINOxzQbklOYV53+POmENCXBnQL65mOyauHx/4PKoudxYN ap93E4kXyZsIScrr/oeUC/OF91X7ZCihBKPdJqzM2B9++IlqSCNTsT3axL6wOJ8lvL pPHAyejU2GBCc35YfWUMRBoLX9ssYknar+Bpf54DKfX2wUqSJVMh25ess0CLTuITYd oCh0jHTEnuXX4s9e8hSm00zlZixAB/pp1ris6HD4hVyBsavI2cjvg4P8abrC8S6yoe TgwUWYuMW8NePVHXD0a1s4T9GuB66XBAmYMZEf7vW2h4H85+EZfp2Nrd8Eq+i+mUt9 M1dxHvrYROeig== From: Leon Romanovsky To: Doug Ledford , Jason Gunthorpe Cc: Leon Romanovsky , linux-kernel@vger.kernel.org, linux-rdma@vger.kernel.org, Mark Zhang , Sean Hefty Subject: [PATCH rdma-next v3 0/8] Fix memory corruption in CM Date: Tue, 11 May 2021 11:22:04 +0300 Message-Id: X-Mailer: git-send-email 2.31.1 MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Leon Romanovsky Changelog: v3: * Removed double unlock * Changes in cma_release flow v2: https://lore.kernel.org/lkml/cover.1619004798.git.leonro@nvidia.com * Included Jason's patches in this series v1: https://lore.kernel.org/linux-rdma/20210411122152.59274-1-leon@kernel.org * Squashed "remove mad_agent ..." patches to make sure that we don't need to check for the NULL argument. v0: https://lore.kernel.org/lkml/20210318100309.670344-1-leon@kernel.org ------------------------------------------------------------------------------- Hi, This series from Mark fixes long standing bug in CM migration logic, reported by Ryan [1]. Thanks [1] https://lore.kernel.org/linux-rdma/CAFMmRNx9cg--NUnZjFM8yWqFaEtsmAWV4EogKb3a0+hnjdtJFA@mail.gmail.com/ Jason Gunthorpe (4): IB/cm: Pair cm_alloc_response_msg() with a cm_free_response_msg() IB/cm: Split cm_alloc_msg() IB/cm: Call the correct message free functions in cm_send_handler() IB/cm: Tidy remaining cm_msg free paths Mark Zhang (4): Revert "IB/cm: Mark stale CM id's whenever the mad agent was unregistered" IB/cm: Simplify ib_cancel_mad() and ib_modify_mad() calls IB/cm: Improve the calling of cm_init_av_for_lap and cm_init_av_by_path IB/cm: Protect cm_dev, cm_ports and mad_agent with kref and lock drivers/infiniband/core/cm.c | 621 +++++++++++++++-------------- drivers/infiniband/core/mad.c | 17 +- drivers/infiniband/core/sa_query.c | 4 +- include/rdma/ib_mad.h | 27 +- 4 files changed, 346 insertions(+), 323 deletions(-) -- 2.31.1