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=-0.5 required=3.0 tests=DKIM_INVALID,DKIM_SIGNED, HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS, URIBL_BLOCKED autolearn=no 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 6A486C2BA83 for ; Fri, 7 Feb 2020 21:02:16 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id 32ACE20720 for ; Fri, 7 Feb 2020 21:02:16 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=fail reason="signature verification failed" (1024-bit key) header.d=lunn.ch header.i=@lunn.ch header.b="SPcJOp49" Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727305AbgBGVCP (ORCPT ); Fri, 7 Feb 2020 16:02:15 -0500 Received: from vps0.lunn.ch ([185.16.172.187]:38600 "EHLO vps0.lunn.ch" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727012AbgBGVCP (ORCPT ); Fri, 7 Feb 2020 16:02:15 -0500 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lunn.ch; s=20171124; h=In-Reply-To:Content-Type:MIME-Version:References:Message-ID: Subject:Cc:To:From:Date:Sender:Reply-To:Content-Transfer-Encoding:Content-ID: Content-Description:Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc :Resent-Message-ID:List-Id:List-Help:List-Unsubscribe:List-Subscribe: List-Post:List-Owner:List-Archive; bh=kCPIBb7PRdtHNTGbHTeczBnKti7EH8CesgLtB7yonEM=; b=SPcJOp49GCMyk+QIC1kQEa9LB2 xKp2Vy3Dayy9aWD9J01ng8CWjZ+jobdf6MqFo+/t1qNzS+ARIssCAsKhiUPC23Pf6M33EB55wbPax gZ5WeXHNXrwCZMXAtI05S1Vmbn7cY63rB0F7GaPASn4naCFieLmE9jl4y/Ur0iXBj7Fo=; Received: from andrew by vps0.lunn.ch with local (Exim 4.93) (envelope-from ) id 1j0AlN-0005Q5-M8; Fri, 07 Feb 2020 22:02:09 +0100 Date: Fri, 7 Feb 2020 22:02:09 +0100 From: Andrew Lunn To: Tim Harvey Cc: netdev@vger.kernel.org, linux-kernel@vger.kernel.org, rrichter@marvell.com, linux-arm-kernel@lists.infradead.org, davem@davemloft.net, sgoutham@marvell.com Subject: Re: [PATCH] net: thunderx: use proper interface type for RGMII Message-ID: <20200207210209.GD19213@lunn.ch> References: <1581108026-28170-1-git-send-email-tharvey@gateworks.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <1581108026-28170-1-git-send-email-tharvey@gateworks.com> Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Fri, Feb 07, 2020 at 12:40:26PM -0800, Tim Harvey wrote: > The configuration of the OCTEONTX XCV_DLL_CTL register via > xcv_init_hw() is such that the RGMII RX delay is bypassed > leaving the RGMII TX delay enabled in the MAC: > > /* Configure DLL - enable or bypass > * TX no bypass, RX bypass > */ > cfg = readq_relaxed(xcv->reg_base + XCV_DLL_CTL); > cfg &= ~0xFF03; > cfg |= CLKRX_BYP; > writeq_relaxed(cfg, xcv->reg_base + XCV_DLL_CTL); > > This would coorespond to a interface type of PHY_INTERFACE_MODE_RGMII_RXID > and not PHY_INTERFACE_MODE_RGMII. > > Fixing this allows RGMII PHY drivers to do the right thing (enable > RX delay in the PHY) instead of erroneously enabling both delays in the > PHY. Hi Tim This seems correct. But how has it worked in the past? Does this suggest there is PHY driver out there which is doing the wrong thing when passed PHY_INTERFACE_MODE_RGMII? Reviewed-by: Andrew Lunn Andrew