๐Ÿš€ go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: linux.kernel.netdev
Article #27542

Re: [PATCH net v2 1/5] ionic: fix devcmds racing the BAR unmap on PCI reset

#27542
From: netdev-bot+sashiko
Date: Sat, 05 Dec 2026 23:06
48 lines
9804 bytes
Thank you for your contribution! Sashiko AI review found more severe
issue(s) in other patches of this series. This mail is only an FYI, in case
you want to address the nit picks below when you respin.

Low priority / nit picks for your consideration:

- [Low] ionic: commit message omits ionic_vf_start() fix and misstates
  callers

--

> diff --git a/drivers/net/ethernet/pensando/ionic/ionic_dev.c b/drivers/net/ethernet/pensando/ionic/ionic_dev.c
> --- a/drivers/net/ethernet/pensando/ionic/ionic_dev.c
> +++ b/drivers/net/ethernet/pensando/ionic/ionic_dev.c
> @@ -811,8 +813,10 @@ void ionic_vf_start(struct ionic *ionic)
>  	if (!(ionic->ident.dev.capabilities & cpu_to_le64(IONIC_DEV_CAP_VF_CTRL)))
>  		return;
>  
> +	mutex_lock(&ionic->dev_cmd_lock);
>  	ionic_dev_cmd_go(&ionic->idev, &cmd);
>  	ionic_dev_cmd_wait(ionic, DEVCMD_TIMEOUT);
> +	mutex_unlock(&ionic->dev_cmd_lock);
>  }
>  
>  /* LIF commands */

[Severity: Low]
The ionic_vf_start() hunk does more than apply the new rule. Before
this patch, ionic_vf_start() issued IONIC_CMD_VF_CTRL through
ionic_dev_cmd_go() and ionic_dev_cmd_wait() without dev_cmd_lock.
That let it interleave with any other devcmd, whether or not a reset
was in progress. This is a separate fix, and the commit message does
not mention it. Could you call it out in the changelog? Is the
existing Fixes: list right for it, or does it need its own tag?

The changelog also says the identify and port setup devcmds "run only
from probe and recovery". That is not quite accurate:
ionic_port_identify() is also called from ionic_link_status_check()
on link-up.

If I read it right, that path is still safe. It takes dev_cmd_lock,
and ionic_dev_teardown() destroys ionic->wq before ionic_clear_pci()
runs. Please have the changelog give that reasoning instead of
claiming these devcmds never run outside probe and recovery.

-- 
Sashiko AI review ยท https://netdev-ai.bots.linux.dev/sashiko/#/patchset/20261204-b4-pr60-v2-0-9e0b5408a68e%40amd.com
Technical Details
Message-ID: <179651196647.3148.12451569579359333936@kernel.org>
Path: mbox-mo1.pugleaf.net!news-can.pugleaf.net!usenet.blueworldhosting.com!diablo1.usenet.blueworldhosting.com!usenet.network!.POSTED!vger.kernel.org!netdev+bounces-378175-linux-kernel-netdev=dewy.ru
References: <20261204-b4-pr60-v2-1-9e0b5408a68e@amd.com>

Show Full Headers
Complete Article Headers
Path: mbox-mo1.pugleaf.net!news-can.pugleaf.net!usenet.blueworldhosting.com!diablo1.usenet.blueworldhosting.com!usenet.network!.POSTED!vger.kernel.org!netdev+bounces-378175-linux-kernel-netdev=dewy.ru
From: netdev-bot+sashiko@kernel.org
Newsgroups: linux.kernel.netdev
Subject: Re: [PATCH net v2 1/5] ionic: fix devcmds racing the BAR unmap on PCI reset
Date: Sat, 05 Dec 2026 23:06:06 +0000
Organization: Usenet Network
Message-ID: <179651196647.3148.12451569579359333936@kernel.org>
References: <20261204-b4-pr60-v2-1-9e0b5408a68e@amd.com>
MIME-Version: 1.0
Content-Type: text/plain; charset="utf-8"
Content-Transfer-Encoding: 8bit
Injection-Info: usenet.network;
	logging-data="3139758"; mail-complaints-to="abuse@usenet.network"
Cancel-Lock: sha1:giNUrVd2jpYMr8b1JYUpR1mvA1c= sha256:UPBL0ng5Sp7ytVu5JL3gv62VD057FIJvpuFHf2nHGRE=
	sha1:ObwxjbLRNMDYJmVKInR9xMY+4KA= sha256:EatLMjpBNTl+saPR0U6HvzigCa6g+FtFURbWS6kR/RQ=
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 38124117EE9; Sun,  6 Dec 2026 02:06:41 +0300 (MSK)
X-Virus-Scanned: Debian amavisd-new at usenet.network
X-Spam-Flag: NO
X-Spam-Score: -3.539
X-Spam-Status: No, score=-3.539 tagged_above=-9999 required=6.31
	tests=[DCC_REPUT_70_89=0.1, DKIMWL_WL_HIGH=-0.14, 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, URIBL_BLOCKED=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 ZNi7aUjIRRFs;
	Sun,  6 Dec 2026 02:06:38 +0300 (MSK)
X-Received-SPF: Pass (mailfrom) identity=mailfrom; client-ip=172.234.253.10; helo=sea.lore.kernel.org; envelope-from=netdev+bounces-378175-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 sea.lore.kernel.org (sea.lore.kernel.org [172.234.253.10])
	by mail.dewy.ru (Postfix) with ESMTPS id 28D3710E0E9; Sun,  6 Dec 2026 02:06:29 +0300 (MSK)
X-Received: from smtp.subspace.kernel.org (conduit.subspace.kernel.org [100.77.114.92])
	by sea.lore.kernel.org (Postfix) with ESMTP id 13C9632AD7; Sat,  5 Dec 2026 23:06:20 +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=1796511978;
	b=rgYdB87RIwdUPEwL9gBvh5p1ZnKzFSzBZSrfIROfCFncCafSvq8ySgx+oV92leizT809
	 xVBu2djWEnnQk1qp7sS1gLxORCYIm1b/0LjjLAv/n0aH8tiGg/bzOeyd+vSX2IScSPrRv
	 kulCA+VHNxyOYWhRcU1M9J5B1+Lf/sFUPr43biVPAMZbXV/ISrig/JIzRUuASQSrfnlHt
	 9aPJ32G7K3XfEiqZSIt5/GlRSIFj/uEFUHwg547dNhvcZbdR9DF1tATnWTzkFqpk9obAo
	 HfSONy8PlbbEHvBJMas9RGJZctHzbiuUth8iTz+cHyFB5EvPLcySzJIp5E5K5M7E1fg==
X-ARC-Message-Signature: i=2; d=subspace.kernel.org; s=arc20261015;
	a=rsa-sha256; c=relaxed/relaxed; t=1796511978;
	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=N9YyGyAVj0bupkx8GHdo3TNjfYqLWTPraan57/5Pa7g=;
	b=2EW3AQmJRLzLeT8e3ywyQanwJg7gSR76QxhmnGe+z2AsHQmC7ArhE0KYRuLFvdF/v9BL
	 mE8UGZqVCaNhoUPximwqUojfsQffCBfTfJH0B2/PQAp/deJir4ccLnpdna647r2uPnuXi
	 MqzTX61GO5ZQDqTXZHqHjvZVFWXmvM8fXP/LCPCeJtdE1jts/Ub6PG5pArEHAXeQYebZs
	 0qLcPXB04+9s9LV56+3B2bG8Sj8JxSXGL2NqdveUCxYyWd0Z6k+l6SFEoW0h0acmcLjAW
	 iP2j629nTaOw1oEcFhGqmWTSLp/LCpIjCOkJqTomaR+JWSXVeSVnAzwN9AlyTlub5sQ==
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=E7yPElqQ;
	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 D633B606A339;
	Sat,  5 Dec 2026 23:06:18 +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=E7yPElqQ
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=1796511968;
	b=4NHaNUsrSuT/FEFh1WFj6r2tdEChxWcoPVvztkfCBl3nQYm/1AqJIQCo62x2f/ya8iX3
	 39DTzkLfS08CwEZJcOoIBHD9m6fJklTGNB0hKW9DyjeOj0uixbW7grpV181jmjPZEYZf2
	 UjWlMbgpgPhCVEZBbFd5Jzpn8q/je5J9ErDAs1WXiZYaAz6/HASm+gTJfqIC8PT4dUwY3
	 UoikOgzij60+ukS41bow1vKH/KofA4F+dLV/FkznFqHtbnPnpS5p3e3eW8tw2g/5HU3uB
	 lV7bjI2l0dNYhDUFZRqONiHRKdCRklOULu/pE+euVUMOdVQJJzAr/XG4xDIwPLXtVlg==
X-ARC-Message-Signature: i=1; d=subspace.kernel.org; s=arc20261015;
	a=rsa-sha256; c=relaxed/relaxed; t=1796511968;
	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=N9YyGyAVj0bupkx8GHdo3TNjfYqLWTPraan57/5Pa7g=;
	b=2fgGA/8euKU1lD5oqwEJOVcqNFsbRGu0+w7xNYobAizdIUhOj7NjhfljtnZjFYuqd1Ox
	 737vwmYMeUDk+rpgFHPgSBEYQzUUvkymvxLvm5Du1AvbOmDk/sWTe3N+e2WfTpl5/VsVo
	 yQ+o/12tG6KAv1CDtB69EsKQd6rTFNowywIZKCcA+O0e0NKUOkfnbDQPzYXJJB6rnbs2o
	 P5JfJKogZbK0Z5hknaDCkXnfMyrOigphJgYbegYQy1CBdHm41TcqB9ZOmnxzyAytl4ITU
	 g946VDWo8n51RHkFhpRA6K3YZt8vBnrT19WsV91MHX2LrAEXuasOR7THurc5KxxhKAg==
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=E7yPElqQ;
	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 EFCAA606A31F;
	Sat,  5 Dec 2026 23:06:07 +0000 (UTC)
X-Received: by smtp.kernel.org (Postfix) with ESMTPSA id E9D2A1F00936;
	Sat,  5 Dec 2026 23:06:06 +0000 (UTC)
X-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=kernel.org;
	s=k20260515; t=1796511967;
	bh=N9YyGyAVj0bupkx8GHdo3TNjfYqLWTPraan57/5Pa7g=;
	h=Subject:From:To:Cc:Date:In-Reply-To:References;
	b=E7yPElqQh24VWCSWQY0vXqCRV5J+/MJlzoYv7VL6mPtBEsn2zaZxEF5pJDuQwr4fI
	 GK4FVM47zRAz8VXZ/Zqi1JNdkL9VF6Xe9DZDn7/tuMEI6ORCRlQJuwaRMceJ8KVeB8
	 eIr1OX0z5guqXi8M/B8LDMJBv79jLFN4CgjAjxxWAEhFh0/dORhwyvgjYD4SmTl8Y8
	 x8DnvulzsSumiFSb0Z92+AdQ7myAig+1vCYOFwjVWi9T97u55/yewNaf1T3ee8UalO
	 PqLPGFiVVdUlhyRGBsa1ZirB9mm27xWRjNM/+NGi9uajytsX3PvHKXnVVET2O0fEh5
	 AgOLBPtzkrXCw==
X-Cc: brett.creeley@amd.com, andrew+netdev@lunn.ch, davem@davemloft.net,
 edumazet@kernel.org, kuba@kernel.org, pabeni@redhat.com,
 richardcochran@gmail.com, netdev@vger.kernel.org,
 linux-kernel@vger.kernel.org, eric.joyner@amd.com, abhijit.gangurde@amd.com,
 allen.hubbe@amd.com
X-In-Reply-To: <20261204-b4-pr60-v2-1-9e0b5408a68e@amd.com>
X-sashiko-severity: Low
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