From mboxrd@z Thu Jan 1 00:00:00 1970 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=-6.8 required=3.0 tests=DKIMWL_WL_HIGH,DKIM_SIGNED, DKIM_VALID,HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI,SIGNED_OFF_BY, SPF_HELO_NONE,SPF_PASS,USER_AGENT_GIT autolearn=unavailable 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 11A82C3F68F for ; Sat, 11 Jan 2020 09:56:15 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id D1E8D2077C for ; Sat, 11 Jan 2020 09:56:14 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1578736574; bh=TfKscB+YyGmraVZx/JDDwLL3JwcC8LoM23ldBIGOkXM=; h=From:To:Cc:Subject:Date:In-Reply-To:References:List-ID:From; b=Ba50HIdHjRaZZZAr9zMfbnGNXhuBrWjXQ1BVrP77fZp/1o4HfUUvAfmOc9Y/E7H9p LMRhTeUNnVbX6jXMmiFIl1KLr60pxWKZhITfYBT6KbamVEWPfsTX//NFVDnaH6iNSy KhqnnbpUZ3lTtOwa3Afw+nTtjO+mD+2TVvbo7uBE= Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1728931AbgAKJ4O (ORCPT ); Sat, 11 Jan 2020 04:56:14 -0500 Received: from mail.kernel.org ([198.145.29.99]:46990 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1728784AbgAKJ4N (ORCPT ); Sat, 11 Jan 2020 04:56:13 -0500 Received: from localhost (unknown [62.119.166.9]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id 4DDD42064C; Sat, 11 Jan 2020 09:56:10 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1578736573; bh=TfKscB+YyGmraVZx/JDDwLL3JwcC8LoM23ldBIGOkXM=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=U1fFDaGgYz1AdnE0C13mCZTa7ITNP8SQjY0kixpKHSnhyGc0HMOnKyIGz3rbPr0sm PP/kKQKejAGMwfehHW1IUOwaExwG4aF0Sx6aHoAZwSTQ+LLadgwgklKZnJg3zlgB3k Q9d4eY9fAnAyrNTN5k9tTDydodFlEtjzh+ZZQD88= From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, Chen-Yu Tsai , "David S. Miller" Subject: [PATCH 4.4 49/59] net: stmmac: dwmac-sunxi: Allow all RGMII modes Date: Sat, 11 Jan 2020 10:49:58 +0100 Message-Id: <20200111094849.595210115@linuxfoundation.org> X-Mailer: git-send-email 2.24.1 In-Reply-To: <20200111094835.417654274@linuxfoundation.org> References: <20200111094835.417654274@linuxfoundation.org> User-Agent: quilt/0.66 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Chen-Yu Tsai [ Upstream commit 52cc73e5404c7ba0cbfc50cb4c265108c84b3d5a ] Allow all the RGMII modes to be used. This would allow us to represent the hardware better in the device tree with RGMII_ID where in most cases the PHY's internal delay for both RX and TX are used. Fixes: af0bd4e9ba80 ("net: stmmac: sunxi platform extensions for GMAC in Allwinner A20 SoC's") Signed-off-by: Chen-Yu Tsai Signed-off-by: David S. Miller Signed-off-by: Greg Kroah-Hartman --- drivers/net/ethernet/stmicro/stmmac/dwmac-sunxi.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) --- a/drivers/net/ethernet/stmicro/stmmac/dwmac-sunxi.c +++ b/drivers/net/ethernet/stmicro/stmmac/dwmac-sunxi.c @@ -53,7 +53,7 @@ static int sun7i_gmac_init(struct platfo * rate, which then uses the auto-reparenting feature of the * clock driver, and enabling/disabling the clock. */ - if (gmac->interface == PHY_INTERFACE_MODE_RGMII) { + if (phy_interface_mode_is_rgmii(gmac->interface)) { clk_set_rate(gmac->tx_clk, SUN7I_GMAC_GMII_RGMII_RATE); clk_prepare_enable(gmac->tx_clk); gmac->clk_enabled = 1;