Received: by 2002:ab2:710b:0:b0:1ef:a325:1205 with SMTP id z11csp145789lql; Sun, 10 Mar 2024 19:01:18 -0700 (PDT) X-Forwarded-Encrypted: i=3; AJvYcCVAiSd1gfHc/7l3UGPEB72HkleOBUiGO9tGXVkeaaZw8XZCSTTIe1vss7IFtchhKrfBItKB9ibqoDKwtHfMvaP34kDiiT2xf+fl2ceR1A== X-Google-Smtp-Source: AGHT+IE8eJe1TlCNgTPQdIh159zjoh8EB69DQ3RGNdl1RUTQ3GreuR1MuXVVOaE8hoayGSr3T0UT X-Received: by 2002:a05:6a20:1596:b0:19e:9143:2ab5 with SMTP id h22-20020a056a20159600b0019e91432ab5mr3498204pzj.25.1710122478377; Sun, 10 Mar 2024 19:01:18 -0700 (PDT) ARC-Seal: i=2; a=rsa-sha256; t=1710122478; cv=pass; d=google.com; s=arc-20160816; b=NtiUHltOctKFv1WRjD5plObY4g+v9mfK1FpVcEk9gI5t9zMrpaGfpoFmsxuN0JRbQZ /EO1HjDP5Rk8bZAruovNHaOnxCeYnr+I1bVbb3oEJ9PZmtE2DuP9rpFf9zEjoC2i+AoK eup2FX1+BGq4B64cH1qFUC8EmUecC526MOmdwI7oJP3wcSBvEURT5oyUrNv56nfn0cXN Pq764qckoqHEUCfwvk3KdSoYtHmRR084agMqYK1MOf1JfCTZCzNEm2/xQQxV11VhNh63 wj+l+f8TgyRVgcNXkixFcvOYIg4NarcloY5pPoKHk48XBzoe8ZoC5bipsM1BSao9Sh41 pmdg== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=content-transfer-encoding:in-reply-to:from:references:cc:to :content-language:subject:user-agent:mime-version:list-unsubscribe :list-subscribe:list-id:precedence:date:message-id; bh=hN6AYQiewAhjgtbScaj0yyzrZ0UEYK3mNqC7I9GIUpY=; fh=/0b1uayxl6xObb+ppBuwyrMHN3i6f8LQGamT2h+wQt8=; b=yog4fsmWIUHkSnVrV73ou0YXza2nWv/KzEZJSpDPYg0jY1StKjJMd7qEWrnv2zDMQ4 ALCeMLUsby5rH2AABeyBTfsekwS/GHfCqOjNe8kuIqu0SbdLGPFbAhSuXHUhtv4ANGr7 tpqY8AM4j4pa4qvCzadYgif83MfVB41r4Id3aqT3TpRP1yyAZqSJAAijlJ0vsqDhXI+x QdoeYN10rWotoiLtjIuZyv47mQFx6ft7Aq54Ml85SJzB8LzWcKOaqs+u85yq+fVt0RbT Nbi/N2S6eY4MHBn6fPow6Yk+jl/KnSExUAdkcbc4+Nbzzk8MBeZx7wNX95wzqpN7EVrN 8WUQ==; 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-98410-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45e3:2400::1 as permitted sender) smtp.mailfrom="linux-kernel+bounces-98410-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=fail (p=QUARANTINE sp=QUARANTINE dis=NONE) header.from=hisilicon.com Return-Path: Received: from sv.mirrors.kernel.org (sv.mirrors.kernel.org. [2604:1380:45e3:2400::1]) by mx.google.com with ESMTPS id t15-20020a63224f000000b005cfb2c44526si3993325pgm.862.2024.03.10.19.01.18 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sun, 10 Mar 2024 19:01:18 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel+bounces-98410-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45e3:2400::1 as permitted sender) client-ip=2604:1380:45e3:2400::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-98410-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45e3:2400::1 as permitted sender) smtp.mailfrom="linux-kernel+bounces-98410-linux.lists.archive=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 sv.mirrors.kernel.org (Postfix) with ESMTPS id C9F83280EEF for ; Mon, 11 Mar 2024 02:01:17 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 8E07E10FF; Mon, 11 Mar 2024 02:01:08 +0000 (UTC) Received: from szxga05-in.huawei.com (szxga05-in.huawei.com [45.249.212.191]) (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 326D4801; Mon, 11 Mar 2024 02:01:01 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=45.249.212.191 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1710122468; cv=none; b=OuAuKuRbW0ukEpwI34yUCGWk4FUuBChZQmmSoUMa4yDaH+WkoNZqmHrjO1Ddb0iEJ6wWp3iY9NT1ujJ039/wzxbYSv0543ju7+q38zQYQKw5t781pD2qh/5IoQkXgio7Xizkvo2arc8WRg/gKVJ5U8KvnYczgwV/6omsBRKK0sw= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1710122468; c=relaxed/simple; bh=wiQLkBh8niMqqh6Ln393H6ASZbM8ndGA41bmCEBbZZI=; h=Message-ID:Date:MIME-Version:Subject:To:CC:References:From: In-Reply-To:Content-Type; b=oLOQNq1HUwK2XWlqWtGkzF0aK1SgPfFL8ZDWs1gV8VTUwzCLUUBULsLZfBHVM233cYaESi9Of3u+XOraMYl//G6CSCZ8jUtx/qpovVNIShPXEhwZojguiI7Mvo50GTyCS6v8vBF/iNXo7SpUF9izh/0YKrwEglGd2eSANUTwcy4= 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.191 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.88.234]) by szxga05-in.huawei.com (SkyGuard) with ESMTP id 4TtKgS0NWfz1h1rd; Mon, 11 Mar 2024 09:58:28 +0800 (CST) Received: from kwepemi500006.china.huawei.com (unknown [7.221.188.68]) by mail.maildlp.com (Postfix) with ESMTPS id 0C5F61402E1; Mon, 11 Mar 2024 10:00:53 +0800 (CST) Received: from [10.67.120.168] (10.67.120.168) by kwepemi500006.china.huawei.com (7.221.188.68) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.1.2507.35; Mon, 11 Mar 2024 10:00:52 +0800 Message-ID: Date: Mon, 11 Mar 2024 10:00:51 +0800 Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 User-Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:102.0) Gecko/20100101 Thunderbird/102.1.0 Subject: Re: [PATCH for-next] RDMA/hns: Support congestion control algorithm parameter configuration Content-Language: en-US To: Leon Romanovsky CC: , , , References: <20240308105443.1130283-1-huangjunxian6@hisilicon.com> <20240310100027.GC12921@unreal> From: Junxian Huang In-Reply-To: <20240310100027.GC12921@unreal> Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: 7bit X-ClientProxiedBy: dggems704-chm.china.huawei.com (10.3.19.181) To kwepemi500006.china.huawei.com (7.221.188.68) On 2024/3/10 18:00, Leon Romanovsky wrote: > On Fri, Mar 08, 2024 at 06:54:43PM +0800, Junxian Huang wrote: >> From: Chengchang Tang >> >> hns RoCE supports 4 congestion control algorithms. Each algorihm >> involves multiple parameters. Add port sysfs directory for each >> algorithm to allow modifying their parameters. > > Unless Jason changed his position after this rewrite [1], we don't allow > any custom driver sysfs code. > > [1] https://lore.kernel.org/all/cover.1623427137.git.leonro@nvidia.com/ > I didn't quite get the reason from [1], could you please explain it? And it would be helpful if you could give us a hint about any other proper ways to do the algorithm parameter configuration. Thanks, Junxian >> >> Signed-off-by: Chengchang Tang >> Signed-off-by: Junxian Huang >> --- >> drivers/infiniband/hw/hns/Makefile | 2 +- >> drivers/infiniband/hw/hns/hns_roce_device.h | 20 ++ >> drivers/infiniband/hw/hns/hns_roce_hw_v2.c | 59 ++++ >> drivers/infiniband/hw/hns/hns_roce_hw_v2.h | 132 ++++++++ >> drivers/infiniband/hw/hns/hns_roce_main.c | 3 + >> drivers/infiniband/hw/hns/hns_roce_sysfs.c | 346 ++++++++++++++++++++ >> 6 files changed, 561 insertions(+), 1 deletion(-) >> create mode 100644 drivers/infiniband/hw/hns/hns_roce_sysfs.c > > Thanks