From nobody Thu Nov 28 04:43:06 2024 Received: from relay7-d.mail.gandi.net (relay7-d.mail.gandi.net [217.70.183.200]) (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 31FE81AA79D; Fri, 4 Oct 2024 16:16:12 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=217.70.183.200 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1728058575; cv=none; b=XAP97wtAsDqK+FDVYlZwkDb7W02Hu8/J5l7SqKK7Vgm90giI76sa1SN/qe+xEiTgIRHUxzynyftVNofM8fSjJr/SQvam+SbpYDODJ2AUDv7jXOnEAqQIXWm/5KQq8gRnd7+Ec84tRtrgqifp7a2IfH08jnZ1RqftmhmqiJOLi+0= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1728058575; c=relaxed/simple; bh=MXRnTnSJrBb1vnWAX8AVE5zZEfy5t/0VU3LPcntsBkU=; h=From:To:Cc:Subject:Date:Message-ID:In-Reply-To:References: MIME-Version; b=HAw6PZEFp/WnbE20i6u4/0t3mfsAaSDGIz5dv8A5SUtS0wtirDfITxiQ/X17DKQ3xbe10VkvRfi8rVX0ME4pc8o/QNko90LrPCmKAxAxvA2ohITpPQAblap60HH1hvS6JiEeYx6/B4Gs4/Fn7ZDfcRWL5YZKtq1Nk17jkAnyOdE= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=reject dis=none) header.from=bootlin.com; spf=pass smtp.mailfrom=bootlin.com; dkim=pass (2048-bit key) header.d=bootlin.com header.i=@bootlin.com header.b=nQ2zjjAQ; arc=none smtp.client-ip=217.70.183.200 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=reject dis=none) header.from=bootlin.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=bootlin.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=bootlin.com header.i=@bootlin.com header.b="nQ2zjjAQ" Received: by mail.gandi.net (Postfix) with ESMTPSA id ACE122000A; Fri, 4 Oct 2024 16:16:10 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=bootlin.com; s=gm1; t=1728058571; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=WFvkoN0tzzAFwJQTN+9OZPcm7C12bxp5VehHzezOGxs=; b=nQ2zjjAQlt78dYOu0azZAA8LApDVs8sqGRzduRI0Q77ScZDM8EovGkfJup3Kt8KRk0SRDK FI35D4EVOm5eLhbjlxt7SrN9xB6Y/ldF72ZCCuDWhzjASUla+iNxbcAaODYABOELlZu0N4 HJUwdmPhjQm+iQHwZbs6oriIhb82MNfYTuRCowgg0frvQAOMxw+jhYajfL85RK7Z2Oe37l 3Cdxa9zyUQ5Lc4wU01d/Jd9lcDGMNu7AvZpP8/jEucICgW+oZ+obA2LWE2usGt8kX4lAXO PqSIvJeBoGo22TxqPFMJSke+eOfoTR876OO1S2hEDkNkMDNAXkS9jkgYSWIpsw== From: Maxime Chevallier To: davem@davemloft.net Cc: Maxime Chevallier , netdev@vger.kernel.org, linux-kernel@vger.kernel.org, thomas.petazzoni@bootlin.com, Andrew Lunn , Jakub Kicinski , Eric Dumazet , Paolo Abeni , Russell King , linux-arm-kernel@lists.infradead.org, Christophe Leroy , Herve Codina , Florian Fainelli , Heiner Kallweit , Vladimir Oltean , =?UTF-8?q?Marek=20Beh=C3=BAn?= , =?UTF-8?q?K=C3=B6ry=20Maincent?= , Oleksij Rempel Subject: [PATCH net-next v2 6/9] net: phy: marvell: mv88e1111 doesn't support isolate in SGMII mode Date: Fri, 4 Oct 2024 18:15:56 +0200 Message-ID: <20241004161601.2932901-7-maxime.chevallier@bootlin.com> X-Mailer: git-send-email 2.46.1 In-Reply-To: <20241004161601.2932901-1-maxime.chevallier@bootlin.com> References: <20241004161601.2932901-1-maxime.chevallier@bootlin.com> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable X-GND-Sasl: maxime.chevallier@bootlin.com Content-Type: text/plain; charset="utf-8" The 88e1111 datasheet indicates that it supports the isolate mode in GMII, RGMII and TBI modes, but doesn't mention what it does in the other modes. Testing showed that setting the isolate bit while the PHY is in SGMII mode has no effect. Reflect that behaviour in the .can_isolate() driver ops. Signed-off-by: Maxime Chevallier --- V2 : New patch drivers/net/phy/marvell.c | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/drivers/net/phy/marvell.c b/drivers/net/phy/marvell.c index 9964bf3dea2f..912b08d9c124 100644 --- a/drivers/net/phy/marvell.c +++ b/drivers/net/phy/marvell.c @@ -1092,6 +1092,14 @@ static int m88e1111_set_tunable(struct phy_device *p= hydev, } } =20 +static bool m88e1111_can_isolate(struct phy_device *phydev) +{ + if (phydev->interface =3D=3D PHY_INTERFACE_MODE_SGMII) + return false; + + return true; +} + static int m88e1011_get_downshift(struct phy_device *phydev, u8 *data) { int val, cnt, enable; @@ -3704,6 +3712,7 @@ static struct phy_driver marvell_drivers[] =3D { .set_tunable =3D m88e1111_set_tunable, .cable_test_start =3D m88e1111_vct_cable_test_start, .cable_test_get_status =3D m88e1111_vct_cable_test_get_status, + .can_isolate =3D m88e1111_can_isolate, }, { .phy_id =3D MARVELL_PHY_ID_88E1111_FINISAR, --=20 2.46.1