Article View: linux.kernel.netdev
Article #23510[PATCH net-next v10 1/8] net: bcmgenet: let the caller decide whether to start the PHY
From: Nicolai Buchwitz
Date: Fri, 27 Nov 2026 11:25
Date: Fri, 27 Nov 2026 11:25
59 lines
10091 bytes
10091 bytes
bcmgenet_netif_stop() already takes stop_phy, bcmgenet_netif_start() does
not. The MTU change in a later patch leaves the PHY running while the
datapath goes down and comes back, and phy_start() expects a stopped PHY.
Add the same parameter to the start side.
No functional change.
Signed-off-by: Nicolai Buchwitz <nb@tipi-net.de>
Reviewed-by: Florian Fainelli <florian.fainelli@broadcom.com>
---
drivers/net/ethernet/broadcom/genet/bcmgenet.c | 9 +++++----
1 file changed, 5 insertions(+), 4 deletions(-)
diff --git a/drivers/net/ethernet/broadcom/genet/bcmgenet.c b/drivers/net/ethernet/broadcom/genet/bcmgenet.c
index 1f2d85b37b0f..7e78db243442 100644
--- a/drivers/net/ethernet/broadcom/genet/bcmgenet.c
+++ b/drivers/net/ethernet/broadcom/genet/bcmgenet.c
@@ -3392,7 +3392,7 @@ static void bcmgenet_get_hw_addr(struct bcmgenet_priv *priv,
put_unaligned_be16(addr_tmp, &addr[4]);
}
-static void bcmgenet_netif_start(struct net_device *dev)
+static void bcmgenet_netif_start(struct net_device *dev, bool start_phy)
{
struct bcmgenet_priv *priv = netdev_priv(dev);
@@ -3409,7 +3409,8 @@ static void bcmgenet_netif_start(struct net_device *dev)
/* Monitor link interrupts now */
bcmgenet_link_intr_enable(priv);
- phy_start(dev->phydev);
+ if (start_phy)
+ phy_start(dev->phydev);
}
static int bcmgenet_open(struct net_device *dev)
@@ -3472,7 +3473,7 @@ static int bcmgenet_open(struct net_device *dev)
bcmgenet_phy_pause_set(dev, priv->rx_pause, priv->tx_pause);
- bcmgenet_netif_start(dev);
+ bcmgenet_netif_start(dev, true);
netif_tx_start_all_queues(dev);
@@ -4371,7 +4372,7 @@ static int bcmgenet_resume(struct device *d)
if (!device_may_wakeup(d))
phy_resume(dev->phydev);
- bcmgenet_netif_start(dev);
+ bcmgenet_netif_start(dev, true);
netif_device_attach(dev);
--
2.53.0
Technical Details
Message-ID:
<20261127-nb-genet-mtu-nn-v2-v10-1-749c7cc45d97@tipi-net.de>Path:
mbox-mo1.pugleaf.net!srv.newsdeef.eu!newsfeed.bofh.team!news.nntp4.net!nntp.xenet.de!news.neodome.net!usenet.network!.POSTED!vger.kernel.org!netdev+bounces-372683-linux-kernel-netdev=dewy.ruReferences:
<20261127-nb-genet-mtu-nn-v2-v10-0-749c7cc45d97@tipi-net.de>Show Full Headers
Complete Article Headers
Path: mbox-mo1.pugleaf.net!srv.newsdeef.eu!newsfeed.bofh.team!news.nntp4.net!nntp.xenet.de!news.neodome.net!usenet.network!.POSTED!vger.kernel.org!netdev+bounces-372683-linux-kernel-netdev=dewy.ru From: nb@tipi-net.de (Nicolai Buchwitz) Newsgroups: linux.kernel.netdev Subject: [PATCH net-next v10 1/8] net: bcmgenet: let the caller decide whether to start the PHY Date: Fri, 27 Nov 2026 12:25:11 +0100 Organization: Usenet Network Message-ID: <20261127-nb-genet-mtu-nn-v2-v10-1-749c7cc45d97@tipi-net.de> References: <20261127-nb-genet-mtu-nn-v2-v10-0-749c7cc45d97@tipi-net.de> MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: 7bit Injection-Info: usenet.network; logging-data="720626"; mail-complaints-to="abuse@usenet.network" Cancel-Lock: sha1:ny1kHV6N1AL3Lk88REJ/+Vkm/kI= sha256:YekoMfHuosRAvuKpF8iezcSJx2pqb7lSy2Jk59U15W8= sha1:VLckktAWH1K4fKAJKDt4LwrojHc= sha256:Wu1kXMPbhRv50zsZcr+PiGs/yxkU4p4a34e5ZT9ZDzc= 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 E7DCF125F52; Fri, 27 Nov 2026 14:26:19 +0300 (MSK) X-Virus-Scanned: Debian amavisd-new at usenet.network X-Spam-Flag: NO X-Spam-Score: -3.151 X-Spam-Status: No, score=-3.151 tagged_above=-9999 required=6.31 tests=[DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, HEADER_FROM_DIFFERENT_DOMAINS=0.249, 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=tipi-net.de 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 qOaYRbfJSKki; Fri, 27 Nov 2026 14:26:17 +0300 (MSK) X-Received-SPF: Pass (mailfrom) identity=mailfrom; client-ip=172.105.105.114; helo=tor.lore.kernel.org; envelope-from=netdev+bounces-372683-linux-kernel-netdev=dewy.ru@vger.kernel.org; receiver=<UNKNOWN> X-Authentication-Results: OpenDMARC; dmarc=none (p=none dis=none) header.from=tipi-net.de X-Received: from tor.lore.kernel.org (tor.lore.kernel.org [172.105.105.114]) by mail.dewy.ru (Postfix) with ESMTPS id EEB68125F51; Fri, 27 Nov 2026 14:26:08 +0300 (MSK) X-Received: from smtp.subspace.kernel.org (conduit.subspace.kernel.org [100.77.114.92]) by tor.lore.kernel.org (Postfix) with ESMTP id C6DBE395AB; Fri, 27 Nov 2026 11:25:55 +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=1795778745; b=uaalKdrb5fg5q+DXIFov4zlri9Rsv0oZf0qd1pMRmsAuARw7LDnYty/0soFfcQn6Osm6 ihidkrk6gQQ1Db2nFLd1WNfrSOZP+lACqXzF0sJGYoYZknAwJv0T3jsKviWTqWrD5I8Pd FJmlK18mpU0RRPzA6/BOtq3lxez73s6erLF7Izc19FMpZk/1Z6P/p5h6rt3em4QA/g2NP 9LO2yimq20dXP2DMpnhFbMYl5btBPOhSUKye2GlbHDQKlWDlY/ncXl/49bvmO3Jr+SaAL h8Ql3nmOTGt6fGCHKK97o7n88gFXXrVXLEFZNBZk/4D/NTt1jY2dqHcOPrrE+sW7IAQ== X-ARC-Message-Signature: i=2; d=subspace.kernel.org; s=arc20261015; a=rsa-sha256; c=relaxed/relaxed; t=1795778745; h=X-Original-To:Received:DMARC-Filter:Received:DKIM-Signature:From: Date:Subject:X-Mailing-List:List-Id:List-Post:List-Help: List-Subscribe:List-Unsubscribe:List-Owner:Precedence:MIME-Version: Content-Type:Content-Transfer-Encoding:Message-Id:References: In-Reply-To:To:Cc:X-Mailer:X-Last-TLS-Session-Version; bh=R9hsh39zB7uY3pBAEfmH5v5PeEQgnDlBlPnGXp1lH3g=; b=nSrZyfG9DWfqmPKJscI0pt3ij21/p/YzALwtuiLlsAcvyX9iHZK1N7mn7BOttwM0wE1J g8Gq46uUkkr1D6YMCseJIhezbooxAjHSE/vq4pjdmHpT6cPHktf/S4hsjq+RLSkSlk8s0 bJNZb8qWWwJn+374j9Ig+BORg97ifztjva+pIqjNSkcFQYtE0dJr68R7bTIbsOgwxgFL/ jgotJjJhhaMzDsaCVyoosa3+ly5h2w29TtzGfx+EPNXQC4gjeEPcbmjRkGuee060FJi/q NG/WIzuH+CAJ/3errG00aCyKIPc12HDdHo9uaJstW276Pk/ImBS69fQb1VLLCjNsI/A== X-ARC-Authentication-Results: i=2; smtp.subspace.kernel.org; dkim=pass header.d=tipi-net.de header.i=@tipi-net.de header.a=rsa-sha256 header.s=dkim header.b=yRy6tFFY; dmarc=none header.from=tipi-net.de; spf=pass smtp.mailfrom=tipi-net.de; 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 71928606A32E; Fri, 27 Nov 2026 11:25:45 +0000 (UTC) X-Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=tipi-net.de header.i=@tipi-net.de header.a=rsa-sha256 header.s=dkim header.b=yRy6tFFY X-Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.remote-ip=194.13.80.246 X-ARC-Seal: i=1; d=subspace.kernel.org; s=arc20261015; a=rsa-sha256; cv=none; t=1795778734; b=PGETcB1zFYjaeA5luylnyoKU+Rs3bcqmze+kDADYrSNCVL3+pH4n43lop7yfA66OoyWA 6Xjyc6iCxIOVVQb1+Rgkggwz5bhzJ/2zELyhy9J42GOglVHueS+8UjBUNGONevl3DVs1c 0hMNXYlcgt4ePwdGzXsy5RYRdsZwuagjkqEgHOSFvMMNe/kE17R9EpeaS/kPndHdAILRe y6PPF/gL25Cj9wSedQSzJxZr5W/ngXG6adA/BPAd08wuB2GBA2+yve3U43h1mgvqdvbvr u6kYevGVbiKIQ8403XGIxLWn9/1Inbo1LMrTGz0dCblamCJl+lHawEnsj5XoYNGfNLQ== X-ARC-Message-Signature: i=1; d=subspace.kernel.org; s=arc20261015; a=rsa-sha256; c=relaxed/relaxed; t=1795778734; h=DMARC-Filter:Received:DKIM-Signature:From:Date:Subject:MIME-Version: Content-Type:Content-Transfer-Encoding:Message-Id:References: In-Reply-To:To:Cc:X-Mailer:X-Last-TLS-Session-Version; bh=R9hsh39zB7uY3pBAEfmH5v5PeEQgnDlBlPnGXp1lH3g=; b=dNpGmasu1YlDptC6qUpKjCGpzPxFgOLL5UatKr6+i1/DrloolxVWjLcmkP2NVme32dOo e6jG2KnGZq8xc7JI6JytJnnfiJNiX65Jsh9ad6JqLv4dMOaskErjblCDRqD4yyBvj0N5E dmFBQd1RIHTD010DpzP07+zYS35Qs+BGKdnkRMV/UM3/tlrUnM72OzdpzNQ6zszyj4rYp 0gP1N3JeT/SvTr2X7QzovSGWiSOi0BpWdN0h7XMYH8XJXOb4DHhWWgGh7SgDY6nk0KQkJ Whe5VPZjp13dmnjTuctWIui4snQ6sTkgC70k+YxuHkdUn+eVbIF8O/ZnMYugx8vXyhg== X-ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=none header.from=tipi-net.de; spf=pass smtp.mailfrom=tipi-net.de; dkim=pass header.d=tipi-net.de header.i=@tipi-net.de header.a=rsa-sha256 header.s=dkim header.b=yRy6tFFY; arc=none smtp.remote-ip=194.13.80.246 X-Received: from mail.tipi-net.de (mail.tipi-net.de [194.13.80.246]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (prime256v1) server-digest SHA256) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 8D3CA606A31F; Fri, 27 Nov 2026 11:25:33 +0000 (UTC) X-DMARC-Filter: OpenDMARC Filter v1.4.2 smtp.subspace.kernel.org 8D3CA606A31F X-Authentication-Results: smtp.subspace.kernel.org; dmarc=none (p=none dis=none) header.from=tipi-net.de X-Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=tipi-net.de X-Received: from [127.0.0.1] (localhost [127.0.0.1]) by localhost (Mailerdaemon) with ESMTPSA id F0ACBA1C26; Fri, 27 Nov 2026 12:25:30 +0100 (CET) X-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=tipi-net.de; s=dkim; t=1795778731; h=from:subject:date:message-id:to:cc:mime-version:content-type: content-transfer-encoding:in-reply-to:references; bh=R9hsh39zB7uY3pBAEfmH5v5PeEQgnDlBlPnGXp1lH3g=; b=yRy6tFFYX0/oDaJlFVRQDAZD+K3MlDXT162leEk4INgXnLDB3uu8urlZEPK7nrwsG7gGLd a7IX/rE7wKbbhg08fjRlEDOluFKUTjfxXyoV0pna0mHXVXFdMMqu2gQGwxyZnjOsTGt8zJ B01A/rHe2pqjZrGuTs1nInRrwQtR9htm5LkFjzqUJgK54jclY4lM+5TQTbcacj8YR3SVQf eEMEBpZHxGV+vXbk1XI9fTPneu5CZaBm91+orIqm/gPlk5Fr4+pDvFcK7JUtBEsWSSmblb KlNTom/xB0G9nLurxKOAn15tYUN9h3a9rcD0nFAIk3KvY/cBak7XIiJbrBx2uw== 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 X-In-Reply-To: <20261127-nb-genet-mtu-nn-v2-v10-0-749c7cc45d97@tipi-net.de> X-Cc: Florian Fainelli <f.fainelli@gmail.com>, netdev@vger.kernel.org, linux-kernel@vger.kernel.org X-Mailer: b4 0.16.0 X-Last-TLS-Session-Version: TLSv1.3