Article View: linux.kernel.netdev
Article #16540Re: [PATCH net-next v02 5/5] hinic3: Ensure that the value of max_qps is not changed
From: netdev-bot+sashiko
Date: Sun, 15 Nov 2026 04:56
Date: Sun, 15 Nov 2026 04:56
80 lines
10998 bytes
10998 bytes
Thank you for your contribution! Sashiko AI review found 1 potential
issue(s) to consider.
Critical: 0 ยท High: 0 ยท Medium: 1 ยท Low: 0
If you believe none of the issues are legitimate, please reply to each
issue of Medium severity or higher and explain why the AI is wrong.
If any of them are legitimate and you plan to respin, please let patchwork
know by including "pw-bot: cr" as a separate line at the end of your reply
(one such reply per series is enough).
- [Medium] The patch has a Fixes: tag, so it will be treated as a stable
bug fix.
--
hinic3: Ensure that the value of max_qps is not changed
This patch stops hinic3_try_to_enable_rss() from setting nic_dev->max_qps
to 1 when RSS setup fails. On that path it now sets only
nic_dev->q_params.num_qps to 1. It also changes the max_qps <= 1 check to
max_qps == 1.
> nic_dev->max_qps is used to allocate hardware resources. Therefore,
> it is assigned the value 1 only when its value is abnormal. In other
> scenarios, the value cannot be changed. However, the value of
> nic_dev->q_params.num_qps can be dynamically changed.
>
> Fixes: 1f3838b84a63 ("hinic3: Add Rss function")
[Severity: Medium]
Is this description accurate? The users of nic_dev->max_qps appear to
size only software arrays:
hinic3_alloc_txqs() -> nic_dev->txqs
hinic3_alloc_rxqs() -> nic_dev->rxqs
hinic3_init_intr_coalesce() -> nic_dev->intr_coalesce
hinic3_setup_num_qps() -> nic_dev->qps_msix_entries
The hardware queue capacity comes from nic_io->max_qps, which is set on
its own:
drivers/net/ethernet/huawei/hinic3/hinic3_nic_io.c:hinic3_init_nic_io() {
...
nic_io->max_qps = hinic3_func_max_qnum(hwdev);
...
}
The removed nic_dev->max_qps = 1 assignments never change that value.
What failure does the Fixes: tag refer to? hinic3_try_to_enable_rss() has
one caller, hinic3_sw_init(). It runs before hinic3_alloc_txrxqs(), and
before hinic3_setup_num_qps() at open time. So with the old code, every
array sized from max_qps was sized at 1 after an RSS failure, and the
sizes matched.
At open, hinic3_config_num_qps() also forces num_qps to 1 whenever RSS is
disabled:
drivers/net/ethernet/huawei/hinic3/hinic3_netdev_ops.c:hinic3_config_num_qps() {
...
if (!test_bit(HINIC3_RSS_ENABLE, &nic_dev->flags))
q_params->num_qps = 1;
...
}
So after an RSS failure the device runs one queue, both before and after
this patch.
The only visible change seems to be on the RSS failure path: the
per-queue software arrays are now sized for the hardware maximum instead
of 1.
Could the commit message name the symptom being fixed, or the later change
that needs max_qps to stay at the hardware capacity? If neither exists,
would this fit better in net-next as a cleanup without the Fixes: tag?
--
Sashiko AI review ยท https://netdev-ai.bots.linux.dev/sashiko/#/patchset/cover.1794371175.git.gongfan1%40huawei.com
Technical Details
Message-ID:
<179471861806.2199510.11943795385941858718@kernel.org>Path:
mbox-mo1.pugleaf.net!news-lax.pugleaf.net!usenet.blueworldhosting.com!diablo1.usenet.blueworldhosting.com!usenet.network!.POSTED!vger.kernel.org!netdev+bounces-363568-linux-kernel-netdev=dewy.ruReferences:
<f29963a1b343ec749f566decbbdb67e7e018860f.1794371175.git.gongfan1@huawei.com>Show Full Headers
Complete Article Headers
Path: mbox-mo1.pugleaf.net!news-lax.pugleaf.net!usenet.blueworldhosting.com!diablo1.usenet.blueworldhosting.com!usenet.network!.POSTED!vger.kernel.org!netdev+bounces-363568-linux-kernel-netdev=dewy.ru From: netdev-bot+sashiko@kernel.org Newsgroups: linux.kernel.netdev Subject: Re: [PATCH net-next v02 5/5] hinic3: Ensure that the value of max_qps is not changed Date: Sun, 15 Nov 2026 04:56:58 +0000 Organization: Usenet Network Message-ID: <179471861806.2199510.11943795385941858718@kernel.org> References: <f29963a1b343ec749f566decbbdb67e7e018860f.1794371175.git.gongfan1@huawei.com> MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: 8bit Injection-Info: usenet.network; logging-data="1732147"; mail-complaints-to="abuse@usenet.network" Cancel-Lock: sha1:Z+OR9OciCVc6nL/KplKk/PWeFo8= sha256:cUmZ/VHxHAADbO36JttIknL2UDU/JrqA8b3eJhA5Ndo= sha1:73xsw6hS/m9xVEOID6nlivtoIGQ= sha256:eUMwKpA3Cy/j2Ydg6PCagbLeBmbjaSaS53vTY7KmiDc= List-ID: <netdev.vger.kernel.org> X-Mailpost-Empty-Hdrs: X-Spam-Level X-Received: from localhost (localhost [127.0.0.1]) by mail.dewy.ru (Postfix) with ESMTP id 5287A125D3D; Sun, 15 Nov 2026 07:57:49 +0300 (MSK) X-Virus-Scanned: Debian amavisd-new at usenet.network X-Spam-Flag: NO X-Spam-Score: -3.501 X-Spam-Status: No, score=-3.501 tagged_above=-9999 required=6.31 tests=[DKIMWL_WL_HIGH=-0.001, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, MAILING_LIST_MULTI=-1, RCVD_IN_DNSWL_MED=-2.3, SPF_HELO_NONE=0.001, SPF_PASS=-0.001] autolearn=ham autolearn_force=no X-Authentication-Results: mail.dewy.ru (amavisd-new); dkim=pass (2048-bit key) header.d=kernel.org X-Received: from mail.dewy.ru ([127.0.0.1]) by localhost (mail.dewy.ru [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id XrL1RRzwe6RE; Sun, 15 Nov 2026 07:57:45 +0300 (MSK) X-Received-SPF: Pass (mailfrom) identity=mailfrom; client-ip=172.232.135.74; helo=sto.lore.kernel.org; envelope-from=netdev+bounces-363568-linux-kernel-netdev=dewy.ru@vger.kernel.org; receiver=<UNKNOWN> X-Authentication-Results: OpenDMARC; dmarc=pass (p=quarantine dis=none) header.from=kernel.org X-Received: from sto.lore.kernel.org (sto.lore.kernel.org [172.232.135.74]) by mail.dewy.ru (Postfix) with ESMTPS id 73BFE125D3B; Sun, 15 Nov 2026 07:57:37 +0300 (MSK) X-Received: from smtp.subspace.kernel.org (conduit.subspace.kernel.org [100.77.114.92]) by sto.lore.kernel.org (Postfix) with ESMTP id E696060D966; Sun, 15 Nov 2026 04:57:28 +0000 (UTC) X-Authentication-Results: smtp.subspace.kernel.org; arc=pass header.oldest-pass=0 smtp.remote-ip=127.0.0.1 X-ARC-Seal: i=2; d=subspace.kernel.org; s=arc20261015; a=rsa-sha256; cv=pass; t=1794718620; b=uIoz5L98YT9fAZBYz2MtcM+pSlbLCTpRDItgrZMUV3qAYL5tmuznCU8s7YGFQ1qlICey 4NQmJWmuAihWE8z4T99bKY8cIF5oBHmBrPJZU5v+VdA+w1clwaEj9X1KisrdLDPQ9OTT+ SkDdVt7OJ02H34PCFxteQMBX8e887C72qRxewFgsJXsFN5XC0io/12o+PpjiU1I/xXvPh IwkzzeqJYylnwgzRrKCGDMK9P5FMftV28Qbqz7589vdkugXmN/bGSzSYTSd8sjFCQaHEL KrPjFABQwW8jjobyHY1NH0XyEMGEPIGxMgcq5QsiYG2s+Nup272H6chPfAJ4AL3SIkw== X-ARC-Message-Signature: i=2; d=subspace.kernel.org; s=arc20261015; a=rsa-sha256; c=relaxed/relaxed; t=1794718620; h=X-Original-To:Received:Received:DKIM-Signature:Subject:From:To:Cc: Date:Message-ID:In-Reply-To:References:X-sashiko-severity: Content-Type:Content-Transfer-Encoding:X-Mailing-List:List-Id: List-Post:List-Help:List-Subscribe:List-Unsubscribe:List-Owner: Precedence:MIME-Version; bh=tI6zfMdxE7bLEfk7tQngRwcxVxwJBB6L+Hi89v7P2eQ=; b=JWm033YZLGqHc6gRbqR865e+v9poDP5OAgQNNQSJuHTzuO/NQ/wjEH56iQ/QEqZDbRC7 TJU4wlUW0RSDWFEZJCfG9RaBMYZJt7ESAF1ZVX7i5ZmC0woOwwzXF+L7l5FhXRe78u38R ilpuNhbZOG3mcYQpw31KzkEEfYNixugB72RM1HRXmJlHWtdce3Sdg+C3JMEhDaPiAtGcW m6MGKizVmErbk8fj3b9x3IoGvUIDSLXqWsSA8HjFyHYmjYxEjNrlFpwFG5nE8njaiZLoU M/NcW1LcDhgZx2Txkh9uMhLNzulrFT5rMt17gBh3IY6at/gQoFoJoPVHAJVB3QtZnVA== X-ARC-Authentication-Results: i=2; smtp.subspace.kernel.org; dkim=pass header.d=kernel.org header.i=@kernel.org header.a=rsa-sha256 header.s=k20260515 header.b=TYijmX9C; arc=pass header.oldest-pass=0 smtp.remote-ip=127.0.0.1 X-Received: from localhost.localdomain (localhost [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 9C4F460A2624; Sun, 15 Nov 2026 04:57:00 +0000 (UTC) X-Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.a=rsa-sha256 header.s=k20260515 header.b=TYijmX9C X-Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.remote-ip=100.103.45.18 X-ARC-Seal: i=1; d=subspace.kernel.org; s=arc20261015; a=rsa-sha256; cv=none; t=1794718619; b=EP+wLXe3LFye5Kd6EmIWo4ou0nsCgMx/RJ7NGE1nV/aUSA4064Uc7Fzv4ycaEUs5CGmf otuj7w+qxYLeIDcDMGb+yFox7kq/QwJNdXnpUPY/g6Du7eck4iQ7IxR9qWv3t1YzJVg8+ mrkTb3+OPm5TE+mGIf7AO7qKf/svz5VAVDQz9j9lT3fpMX69H54EOk/LmobyDL0HnoK7n W+KXeIjAlLlKbuuauiq5+ObTsuKjNpL3k0gb2SZ+SLtr+OrcIoTG5QPx5OUiSSkKaoZOR l4/cPAWt5ig3uQHGpqTQ7eh18lZXyzLdxskLTB7ea+FkGdh3rC6cpzpkSTHG7IB03ig== X-ARC-Message-Signature: i=1; d=subspace.kernel.org; s=arc20261015; a=rsa-sha256; c=relaxed/relaxed; t=1794718619; h=Received:DKIM-Signature:Subject:From:To:Cc:Date:Message-ID: In-Reply-To:References:X-sashiko-severity:Content-Type: Content-Transfer-Encoding:MIME-Version; bh=tI6zfMdxE7bLEfk7tQngRwcxVxwJBB6L+Hi89v7P2eQ=; b=e/xRFfmmfRlxLk74MbNZTAZG78kK4uZLmk/IhcPhEKQSyiLUdueyCVo69NuOKc7C+YVd I0lZLcoeBXJTa/xwyOaJlhWX22Tw1zLfa7tZk5SPbc2K+DfCAoMl6K7t2stefoBgGzA1X LehDl+hF++VOQ7qEwZ0SDbh5n+Nf5z8LQN2X2IZdG4KXu8ybQGdfQdCKDO7jhak0NcPFe +UOHjYf3gyNHQEmNxF5dApJ7QyZ54vmCJ8nqoRANMZaapzLjJDl+nsGI6Wfdy+fs5X7ZA bTKmcqlVdHZmBv5eDmjjHjXROkitaKAHsmOEnfdL9ZoPQYAlRmalg+E4hz32syo8/Cw== X-ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dkim=pass header.d=kernel.org header.i=@kernel.org header.a=rsa-sha256 header.s=k20260515 header.b=TYijmX9C; arc=none smtp.remote-ip=100.103.45.18 X-Received: from smtp.kernel.org (quasi.space.kernel.org [100.103.45.18]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (prime256v1)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id BD0C460A2613; Sun, 15 Nov 2026 04:56:59 +0000 (UTC) X-Received: by smtp.kernel.org (Postfix) with ESMTPSA id 8057C1F000CA; Sun, 15 Nov 2026 04:56:58 +0000 (UTC) X-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=kernel.org; s=k20260515; t=1794718619; bh=tI6zfMdxE7bLEfk7tQngRwcxVxwJBB6L+Hi89v7P2eQ=; h=Subject:From:To:Cc:Date:In-Reply-To:References; b=TYijmX9CknZ2FtlQaD0z4+LrV1K2wBSCGiihIVaXyzivKXJRyYRZZx5iar5COqbyW yKyTXgq+GQEqyd6fawtPodVS7PQCyE4vOOp0FxJD5A5MHm93ACyecQNMIe1aGCGoal JnptMkOmyZwL7zVuOcmWgXCzvl/hkdt0weB7SYHs2EBQPmiPrcti8H+ES67ZX3vZFn 545zKEmmMMvBOGGVsvhDItsHjaWLzqJc8+crHyZLMAO1g3bRUwgwcj8xyvNSeyeNr4 NWEY1UuMEhzMRhYlJeLbheOsct8lwYnHdL2Com7zJYTb+AXyTDMBRuwFEUHJAOlK/D j7JCMDTyXrryQ== X-Cc: wudi234@huawei.com, tengpeisen@huawei.com, netdev@vger.kernel.org, davem@davemloft.net, edumazet@google.com, kuba@kernel.org, pabeni@redhat.com, horms@kernel.org, andrew+netdev@lunn.ch, ioana.ciornei@nxp.com, maxime.chevallier@bootlin.com, mohsin.bashr@gmail.com, dimitri.daskalakis1@gmail.com, hramamurthy@google.com, larysa.zaremba@intel.com, vadim.fedorenko@linux.dev, linux-kernel@vger.kernel.org, linux-doc@vger.kernel.org, zhoushuai28@huawei.com, wulike1@huawei.com X-In-Reply-To: <f29963a1b343ec749f566decbbdb67e7e018860f.1794371175.git.gongfan1@huawei.com> X-sashiko-severity: Medium X-Mailing-List: netdev@vger.kernel.org X-List-Post: <mailto:netdev@vger.kernel.org> X-List-Help: <mailto:netdev+help@vger.kernel.org> X-List-Subscribe: <mailto:netdev+subscribe@vger.kernel.org> X-List-Unsubscribe: <mailto:netdev+unsubscribe@vger.kernel.org> X-List-Owner: <mailto:netdev+owner@vger.kernel.org> X-Precedence: list