From nobody Mon Feb 9 22:18:52 2026 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 68AD8C761A6 for ; Mon, 27 Mar 2023 14:24:12 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S233006AbjC0OYL (ORCPT ); Mon, 27 Mar 2023 10:24:11 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:39044 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S232065AbjC0OXs (ORCPT ); Mon, 27 Mar 2023 10:23:48 -0400 Received: from metis.ext.pengutronix.de (metis.ext.pengutronix.de [IPv6:2001:67c:670:201:290:27ff:fe1d:cc33]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 87ED97D8C for ; Mon, 27 Mar 2023 07:22:14 -0700 (PDT) Received: from drehscheibe.grey.stw.pengutronix.de ([2a0a:edc0:0:c01:1d::a2]) by metis.ext.pengutronix.de with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1pgnja-0008Hi-L1; Mon, 27 Mar 2023 16:22:06 +0200 Received: from [2a0a:edc0:0:1101:1d::ac] (helo=dude04.red.stw.pengutronix.de) by drehscheibe.grey.stw.pengutronix.de with esmtp (Exim 4.94.2) (envelope-from ) id 1pgnjX-0076IH-SB; Mon, 27 Mar 2023 16:22:03 +0200 Received: from ore by dude04.red.stw.pengutronix.de with local (Exim 4.94.2) (envelope-from ) id 1pgnjW-00Fkj2-RP; Mon, 27 Mar 2023 16:22:02 +0200 From: Oleksij Rempel To: Wei Fang , "David S. Miller" , Eric Dumazet , Jakub Kicinski , Paolo Abeni , Andrew Lunn , Heiner Kallweit , Russell King Cc: Oleksij Rempel , kernel@pengutronix.de, linux-kernel@vger.kernel.org, netdev@vger.kernel.org, Shenwei Wang , Clark Wang , NXP Linux Team , Amit Cohen , Gal Pressman , Alexandru Tachici , Piergiorgio Beruto , Willem de Bruijn , Vladimir Oltean Subject: [PATCH net-next v2 3/8] net: phy: Add mac_supports_eee variable for EEE support and LPI handling Date: Mon, 27 Mar 2023 16:21:57 +0200 Message-Id: <20230327142202.3754446-4-o.rempel@pengutronix.de> X-Mailer: git-send-email 2.30.2 In-Reply-To: <20230327142202.3754446-1-o.rempel@pengutronix.de> References: <20230327142202.3754446-1-o.rempel@pengutronix.de> MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable X-SA-Exim-Connect-IP: 2a0a:edc0:0:c01:1d::a2 X-SA-Exim-Mail-From: ore@pengutronix.de X-SA-Exim-Scanned: No (on metis.ext.pengutronix.de); SAEximRunCond expanded to false X-PTX-Original-Recipient: linux-kernel@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Type: text/plain; charset="utf-8" This commit introduces a new variable, mac_supports_eee, to the PHY layer. This variable is used to indicate if a MAC provides EEE support or is responsible for Low Power Idle (LPI) handling. The mac_supports_eee variable should be used in conjunction with is_smart_eee_phy to make proper configuration decisions based on the capabilities of both the PHY and MAC. By adding the mac_supports_eee variable, PHY drivers and the PHYlib framework can better coordinate EEE and LPI management between the PHY and MAC. Signed-off-by: Oleksij Rempel --- include/linux/phy.h | 2 ++ 1 file changed, 2 insertions(+) diff --git a/include/linux/phy.h b/include/linux/phy.h index 6622b59ab5a1..573ad3fc2bf7 100644 --- a/include/linux/phy.h +++ b/include/linux/phy.h @@ -548,6 +548,7 @@ struct macsec_ops; * @is_on_sfp_module: Set true if PHY is located on an SFP module. * @mac_managed_pm: Set true if MAC driver takes of suspending/resuming PHY * @is_smart_eee_phy: Set true if PHY is a Smart EEE PHY + * @mac_supports_eee: Set true if MAC supports EEE * @state: State of the PHY for management purposes * @dev_flags: Device-specific flags used by the PHY driver. * @@ -644,6 +645,7 @@ struct phy_device { unsigned is_on_sfp_module:1; unsigned mac_managed_pm:1; unsigned is_smart_eee_phy:1; + unsigned mac_supports_eee:1; =20 unsigned autoneg:1; /* The most recently read link state */ --=20 2.30.2