From patchwork Thu Feb 8 03:50:36 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Junxian Huang X-Patchwork-Id: 20084 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:a05:7301:168b:b0:106:860b:bbdd with SMTP id ma11csp2670649dyb; Wed, 7 Feb 2024 19:56:19 -0800 (PST) X-Google-Smtp-Source: AGHT+IEXVM/q/xnvPAlf98yvuahUVLAIMd9m2pYjRZfIPJP5cbORHhorTpitTgvf8hfWddb3PQZa X-Received: by 2002:a05:620a:2236:b0:785:8eb2:9312 with SMTP id n22-20020a05620a223600b007858eb29312mr6636133qkh.32.1707364578939; Wed, 07 Feb 2024 19:56:18 -0800 (PST) ARC-Seal: i=2; a=rsa-sha256; t=1707364578; cv=pass; d=google.com; s=arc-20160816; b=dQur14RL0sHf4Wc28ICD9FifJKtf5tSSdmuhq6bjj6fAWqi9V9n+ZnScFGSizaRrR1 mxfVO5tDyrnQdLrRng6tQ7IeMHVGnSgm2GGw4yLfgmAbxjTFcBLRABExPbkRSIexICH4 kSTe1KsZuSZRSXxUbSZucpyo4WYx+cR/vXXbw5M378hEGx+mAdfTSlRjopA042h6jFTd aKuWA5kNuu9tOmPVnIVZvXxMCTK7YAdzBkL2MODtTew8ZDJfhmKj4x/5ajxo+JXuiqLW G5QEHgk/+BUh/cncmC4B+OINgtLGraPzEeDl9WR9R1rNNJnZFbZ/cZtKA8DYqp8AZXq8 RLXQ== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=content-transfer-encoding:mime-version:list-unsubscribe :list-subscribe:list-id:precedence:message-id:date:subject:cc:to :from; bh=zQeafrKcdTfqz5qhblijUU40NlbfMfugTDSMblomlyw=; fh=oG4M6F5hx9xl00DIszABXnyMfb/0JsMwXSBiYFsU2Dc=; b=Yj6IEwwJUuEIk3i+AmYF9Ox0V6UBu2j8eRdRUdoclyqZH1XQnxcLEJi3s1Gg7UxCeY 43CSo1HanHRVsodY+RY178aLWzPTwA9Qc6Z7ecUIc2RCFnLywKOK/QHU8A34UDVOm8ma wr7vb5EUrd17sjoJ5dEjY66qztn7EZGKfpAAwcTIKeIA6gPm3PZ0NOBiuJ617vrQ5FmB Rwcxk278BqftwpaRGTHKFfcIK1oa3wm8VbmtQ3Qx/LPCoTfQtSunWBAr5vTYtHCMyOWs jF4lDk4wPfJWSqH+FSyYy5pUtRV/aQFvKtXqheDlLIXOILzADrkFj3V5KSmSZFyiMBE0 W8Xw==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; arc=pass (i=1 spf=pass spfdomain=hisilicon.com dmarc=pass fromdomain=hisilicon.com); spf=pass (google.com: domain of linux-kernel+bounces-57452-ouuuleilei=gmail.com@vger.kernel.org designates 2604:1380:45d1:ec00::1 as permitted sender) smtp.mailfrom="linux-kernel+bounces-57452-ouuuleilei=gmail.com@vger.kernel.org"; dmarc=fail (p=QUARANTINE sp=QUARANTINE dis=NONE) header.from=hisilicon.com X-Forwarded-Encrypted: i=2; AJvYcCULYVCikX17gWzDZ0e72k9T2KxrXJ3+f+gPX25T8nUjJKJyxZUoUrIKUxFsye4MZKZ62NTurr9bUJS9kdbyAlOX0D8Q6g== Received: from ny.mirrors.kernel.org (ny.mirrors.kernel.org. [2604:1380:45d1:ec00::1]) by mx.google.com with ESMTPS id vw26-20020a05620a565a00b00784076c5f89si2474607qkn.516.2024.02.07.19.56.18 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 07 Feb 2024 19:56:18 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel+bounces-57452-ouuuleilei=gmail.com@vger.kernel.org designates 2604:1380:45d1:ec00::1 as permitted sender) client-ip=2604:1380:45d1:ec00::1; Authentication-Results: mx.google.com; arc=pass (i=1 spf=pass spfdomain=hisilicon.com dmarc=pass fromdomain=hisilicon.com); spf=pass (google.com: domain of linux-kernel+bounces-57452-ouuuleilei=gmail.com@vger.kernel.org designates 2604:1380:45d1:ec00::1 as permitted sender) smtp.mailfrom="linux-kernel+bounces-57452-ouuuleilei=gmail.com@vger.kernel.org"; dmarc=fail (p=QUARANTINE sp=QUARANTINE dis=NONE) header.from=hisilicon.com Received: from smtp.subspace.kernel.org (wormhole.subspace.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ny.mirrors.kernel.org (Postfix) with ESMTPS id 9F0DE1C21FC7 for ; Thu, 8 Feb 2024 03:56:18 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 45C14364D2; Thu, 8 Feb 2024 03:54:55 +0000 (UTC) Received: from szxga06-in.huawei.com (szxga06-in.huawei.com [45.249.212.32]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 6094C2D054; Thu, 8 Feb 2024 03:54:48 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=45.249.212.32 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1707364493; cv=none; b=ureHA9Uc5gigyFYTxRBhNLD3d5HyyiM6RIGsiEAtnjTe8kENVFwm2FZPeTZ7sj0pVfiGMo7Anh2kKwWcL8u50063/XcPFBsg9g5BCv8SPG2x+Kj8w9cGQ9fyXgyo//yvKMCXJ4Cfu+cpq9/vWZJZdLzAN9rQU1z4SKlOARycOYU= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1707364493; c=relaxed/simple; bh=8gQe+a5VMwbGZUZID4MLAbdx2ZQzKKCTGHEnuvMsOOY=; h=From:To:CC:Subject:Date:Message-ID:MIME-Version:Content-Type; b=qLTwZJg2+9A7JpLGxT+rH5nnIWnGfDEg8viR2whN6Dsfc1FO7mMn/ghitwc/1TfztMUUKfVw0koJlPD0pRsh/mCVyr2JufYLqPK0gxzW4oZ4lSZVCOH+YelotzEuNkNIBnABUyjFHdIcCHKq7CRlPcmKVt2GGheSUogHdg5QuzU= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=quarantine dis=none) header.from=hisilicon.com; spf=pass smtp.mailfrom=hisilicon.com; arc=none smtp.client-ip=45.249.212.32 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=quarantine dis=none) header.from=hisilicon.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=hisilicon.com Received: from mail.maildlp.com (unknown [172.19.163.44]) by szxga06-in.huawei.com (SkyGuard) with ESMTP id 4TVjlt0jQNz1vtL0; Thu, 8 Feb 2024 11:54:18 +0800 (CST) Received: from kwepemi500006.china.huawei.com (unknown [7.221.188.68]) by mail.maildlp.com (Postfix) with ESMTPS id 82A1614051C; Thu, 8 Feb 2024 11:54:46 +0800 (CST) Received: from localhost.localdomain (10.67.165.2) by kwepemi500006.china.huawei.com (7.221.188.68) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2507.35; Thu, 8 Feb 2024 11:54:45 +0800 From: Junxian Huang To: , CC: , , , Subject: [PATCH v2 for-next 0/2] RDMA/hns: Support configuring congestion control algorithm with QP granularity Date: Thu, 8 Feb 2024 11:50:36 +0800 Message-ID: <20240208035038.94668-1-huangjunxian6@hisilicon.com> X-Mailer: git-send-email 2.30.0 Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 X-ClientProxiedBy: dggems705-chm.china.huawei.com (10.3.19.182) To kwepemi500006.china.huawei.com (7.221.188.68) X-getmail-retrieved-from-mailbox: INBOX X-GMAIL-THRID: 1790301520685934323 X-GMAIL-MSGID: 1790301520685934323 Commit 27c5fd271d8b ("RDMA/hns: The UD mode can only be configured with DCQCN") adds a restriction that only DCQCN is supported for UD QPs, but at the same time introduced other problem mistakenly. Patch #1 reverts the previous modification and fixes the algorithm issue for UD by configuring congestion control algorithm with QP granularity. Patch #2 adds support for userspace configuring congestion control algorithm with QP granularity. v1 -> v2: * Not only revert but also fix the UD algorithm issue in patch #1. Junxian Huang (1): RDMA/hns: Support userspace configuring congestion control algorithm with QP granularity Luoyouming (1): RDMA/hns: Fix mis-modifying default congestion control algorithm drivers/infiniband/hw/hns/hns_roce_device.h | 26 +++++--- drivers/infiniband/hw/hns/hns_roce_hw_v2.c | 18 ++---- drivers/infiniband/hw/hns/hns_roce_hw_v2.h | 3 +- drivers/infiniband/hw/hns/hns_roce_main.c | 3 + drivers/infiniband/hw/hns/hns_roce_qp.c | 71 +++++++++++++++++++++ include/uapi/rdma/hns-abi.h | 17 +++++ 6 files changed, 118 insertions(+), 20 deletions(-) --- 2.30.0