From patchwork Tue May 11 04:37:35 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Oleksij Rempel X-Patchwork-Id: 12250475 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-17.4 required=3.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,HEADER_FROM_DIFFERENT_DOMAINS,INCLUDES_CR_TRAILER, INCLUDES_PATCH,MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS,URIBL_BLOCKED, USER_AGENT_GIT autolearn=ham autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 49283C433B4 for ; Tue, 11 May 2021 10:31:38 +0000 (UTC) Received: from desiato.infradead.org (desiato.infradead.org [90.155.92.199]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id A883E61155 for ; Tue, 11 May 2021 10:31:37 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org A883E61155 Authentication-Results: mail.kernel.org; dmarc=none (p=none dis=none) header.from=pengutronix.de Authentication-Results: mail.kernel.org; spf=none smtp.mailfrom=linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=desiato.20200630; h=Sender:Content-Transfer-Encoding :Content-Type:List-Subscribe:List-Help:List-Post:List-Archive: List-Unsubscribe:List-Id:MIME-Version:References:In-Reply-To:Message-Id:Date: Subject:Cc:To:From:Reply-To:Content-ID:Content-Description:Resent-Date: Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:List-Owner; bh=zqtF7WZDgX1c6iRcsqC4EUCgsDoYHy4LQ3fI4YSkjHE=; b=XXVlkHTQ6neboFBhZTnuwu2Pc /hVoMhCp6KuGogPpXvPqIT0kEgAeJGYAY6kfDloJ2jog0Do7iu7BIgM7xXQ3veMIjEtkfAFTHyRxo v3DtlngVFk8or3a65YatUVTk/PMdKdUzWp2PX6RHBKqwtOkB+5EdmXP+lJq5G9wcpQU1gfSNtMMEQ EpUN3PLAM90ki3lAUPFYN7jr5U+08kV8oqlOYupxXeo66lkFrLe8/jqfIe4EbzdHR53gq5NsOVA78 MPGhk+qI1HyPH4dBEaRgCB6epXF9PB86u24h37l9xKM8g7L10KZLPiDM9Z6lBqL1Ps6LMBtuLUOg1 mzImCREYg==; Received: from localhost ([::1] helo=desiato.infradead.org) by desiato.infradead.org with esmtp (Exim 4.94 #2 (Red Hat Linux)) id 1lgPeY-00GwGd-2J; Tue, 11 May 2021 10:30:16 +0000 Received: from [2607:7c80:54:e::133] (helo=bombadil.infradead.org) by desiato.infradead.org with esmtps (Exim 4.94 #2 (Red Hat Linux)) id 1lgKAA-00GHlV-FG for linux-arm-kernel@desiato.infradead.org; Tue, 11 May 2021 04:38:32 +0000 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=infradead.org; s=bombadil.20210309; h=Content-Transfer-Encoding: MIME-Version:References:In-Reply-To:Message-Id:Date:Subject:Cc:To:From:Sender :Reply-To:Content-Type:Content-ID:Content-Description; bh=Mesi6foa+r3IfTgF+H7x5sSHmn7/297UpeVEh6uziEI=; b=Sm4KuwNyBMdM5fI+yo72ks633O qqQXTjnE5i4/7V7onkAxyfclVgBrNqaTqN/S9VSytRl+a7GKKZ64bd44SdLuCZf8XYK/vVzMY46KR Vbzt6gKGh30z87WEEt0aKrO9+wQCK+BWDCQkHjIany7h69mNbNhFyz6MNZoqJfhhQG9xaRPa59QZL jy2KcfFcEQU5a6ECzRPP5vTas45vu8Kud5GXbWZ3I5aHS/QV9NTbCaiI9SJ+IawipLPah+GaUFDj/ /grhukaQcP0OUak84PPoMQN4zZQ07LjxjxTJAuY7Jvsf9lGevfBOG2Syjvx/rqujlJZ6ndknogjw7 2OZdIEsg==; Received: from metis.ext.pengutronix.de ([2001:67c:670:201:290:27ff:fe1d:cc33]) by bombadil.infradead.org with esmtps (Exim 4.94 #2 (Red Hat Linux)) id 1lgKA8-009Igx-10 for linux-arm-kernel@lists.infradead.org; Tue, 11 May 2021 04:38:29 +0000 Received: from dude.hi.pengutronix.de ([2001:67c:670:100:1d::7]) by metis.ext.pengutronix.de with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1lgK9K-0005c7-38; Tue, 11 May 2021 06:37:38 +0200 Received: from ore by dude.hi.pengutronix.de with local (Exim 4.92) (envelope-from ) id 1lgK9J-0007ys-9N; Tue, 11 May 2021 06:37:37 +0200 From: Oleksij Rempel To: Shawn Guo , Sascha Hauer , Andrew Lunn , Florian Fainelli , Heiner Kallweit Cc: Oleksij Rempel , kernel@pengutronix.de, netdev@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org, linux-imx@nxp.com, Fabio Estevam , David Jander , Russell King , Philippe Schenker Subject: [PATCH v3 7/7] ARM: imx7d: remove Atheros AR8031 PHY fixup Date: Tue, 11 May 2021 06:37:35 +0200 Message-Id: <20210511043735.30557-8-o.rempel@pengutronix.de> X-Mailer: git-send-email 2.29.2 In-Reply-To: <20210511043735.30557-1-o.rempel@pengutronix.de> References: <20210511043735.30557-1-o.rempel@pengutronix.de> MIME-Version: 1.0 X-SA-Exim-Connect-IP: 2001:67c:670:100:1d::7 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-arm-kernel@lists.infradead.org X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20210510_213828_087963_47A0A6E4 X-CRM114-Status: GOOD ( 12.08 ) X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20210510_213828_087963_47A0A6E4 X-CRM114-Status: UNSURE ( 8.81 ) X-CRM114-Notice: Please train this message. X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org This fixup configures the IO voltage and disables the SmartEEE functionality. If this patch breaks your system, enable AT803X_PHY driver and configure the PHY by the device tree: phy-connection-type = "rgmii-id"; ethernet-phy@X { reg = <0xX>; qca,smarteee-tw-us-1g = <24>; vddio-supply = <&vddh>; vddio: vddio-regulator { regulator-name = "VDDIO"; regulator-min-microvolt = <1800000>; regulator-max-microvolt = <1800000>; }; vddh: vddh-regulator { regulator-name = "VDDH"; }; }; Signed-off-by: Oleksij Rempel Reviewed-by: Andrew Lunn --- arch/arm/mach-imx/mach-imx7d.c | 22 ---------------------- 1 file changed, 22 deletions(-) diff --git a/arch/arm/mach-imx/mach-imx7d.c b/arch/arm/mach-imx/mach-imx7d.c index 879c35929a13..ccf64ddf8b7e 100644 --- a/arch/arm/mach-imx/mach-imx7d.c +++ b/arch/arm/mach-imx/mach-imx7d.c @@ -14,25 +14,6 @@ #include "common.h" -static int ar8031_phy_fixup(struct phy_device *dev) -{ - u16 val; - - /* Set RGMII IO voltage to 1.8V */ - phy_write(dev, 0x1d, 0x1f); - phy_write(dev, 0x1e, 0x8); - - /* disable phy AR8031 SmartEEE function. */ - phy_write(dev, 0xd, 0x3); - phy_write(dev, 0xe, 0x805d); - phy_write(dev, 0xd, 0x4003); - val = phy_read(dev, 0xe); - val &= ~(0x1 << 8); - phy_write(dev, 0xe, val); - - return 0; -} - static int bcm54220_phy_fixup(struct phy_device *dev) { /* enable RXC skew select RGMII copper mode */ @@ -44,14 +25,11 @@ static int bcm54220_phy_fixup(struct phy_device *dev) return 0; } -#define PHY_ID_AR8031 0x004dd074 #define PHY_ID_BCM54220 0x600d8589 static void __init imx7d_enet_phy_init(void) { if (IS_BUILTIN(CONFIG_PHYLIB)) { - phy_register_fixup_for_uid(PHY_ID_AR8031, 0xffffffff, - ar8031_phy_fixup); phy_register_fixup_for_uid(PHY_ID_BCM54220, 0xffffffff, bcm54220_phy_fixup); }