Received: by 2002:a05:6358:1087:b0:cb:c9d3:cd90 with SMTP id j7csp7136891rwi; Mon, 24 Oct 2022 10:14:51 -0700 (PDT) X-Google-Smtp-Source: AMsMyM69YgHurcfBqLfE6SNdPs2STaYYjrSNPa00sDTx8rkBR3/MDOU+6eAMlShBZh/zM5ocdayo X-Received: by 2002:a17:902:ea09:b0:186:a604:d7e4 with SMTP id s9-20020a170902ea0900b00186a604d7e4mr6725273plg.120.1666631691243; Mon, 24 Oct 2022 10:14:51 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1666631691; cv=none; d=google.com; s=arc-20160816; b=K2yopvRlOWk9s9byBD+iCfpo8WYxWCeefcTES3xHsX3ACbmEEgkts0UOP4ih7geSZj Rm9tmGc1Kz0XtNjEpS30pGVzLG2qhfUvH4XN2QMQCl4iJeyfpX+tFvAH1rZqd1to0u3E v0ijEirZAGZGsAoDtzGq15NNEd3PO4rP76sZAAUDhtR+FDmO4OPVXbyotus6qsajw/fJ qZWuKgbI2va4S95magt7yGQhYLT/UOW/tGPgrmcK5jxGNwdBP0q++oyCEnAWr/a0GILb Ck/BBtbrrYeJbK1QGslZlDk8uTKqZD8GXT6g924I5bZR2oFnXgmtLg9eBmsOLeC7TSgz OXIA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:in-reply-to:content-transfer-encoding :content-disposition:mime-version:references:message-id:subject:cc :to:from:date:dkim-signature; bh=BrxfrDUbPsUFpThWqA9RSxt3bESyLFU8TgRiCKoKos4=; b=x1nbCyCtP3Np5bTnX7JAJc6sTOBvzrOz5qzEuOtTa6LbLFfLx01oayBHPScAHK2dFo nsWZWP6riD5JNgmwgvoBRXd7NMCGwWYQpna5X7/XagImXrgwrn5jrrlgo9R7rVJsm8gy LfAq5dnQWC+qC6ee3mMX4/MYos9TBqGmvgyplmhCKPslFbF3PMk+wQBJCQI8B4R++Exx V0dxuwqFUEAHpMlwXm4L4XYXJ14s2D6sYnxCi3Rj3WXq9R9JG8Cf5f+9FRDV7NnK3RT5 k56BBHqx9tP6zlpl7CkicI93jEcZL8tRWSLwInVmLar8XzCphTdggbxDUXz828YgAKAg Pr6A== ARC-Authentication-Results: i=1; mx.google.com; dkim=fail (test mode) header.i=@armlinux.org.uk header.s=pandora-2019 header.b=hUFyDn4i; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=armlinux.org.uk Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id ja4-20020a170902efc400b001787f199d85si90197plb.54.2022.10.24.10.14.39; Mon, 24 Oct 2022 10:14:51 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=fail (test mode) header.i=@armlinux.org.uk header.s=pandora-2019 header.b=hUFyDn4i; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=armlinux.org.uk Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S232810AbiJXQmj (ORCPT + 99 others); Mon, 24 Oct 2022 12:42:39 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:35414 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S231881AbiJXQlr (ORCPT ); Mon, 24 Oct 2022 12:41:47 -0400 Received: from pandora.armlinux.org.uk (pandora.armlinux.org.uk [IPv6:2001:4d48:ad52:32c8:5054:ff:fe00:142]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id A9AC080EA5; Mon, 24 Oct 2022 08:28:52 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=armlinux.org.uk; s=pandora-2019; h=Sender:In-Reply-To: Content-Transfer-Encoding:Content-Type:MIME-Version:References:Message-ID: Subject:Cc:To:From:Date:Reply-To: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=BrxfrDUbPsUFpThWqA9RSxt3bESyLFU8TgRiCKoKos4=; b=hUFyDn4iEM2Umosu5AGmbJVVWt Gd8sS4dlaaccEMpfxIA+FTJfDLsCW3BaDAKG3WhFItnfHCxaubrTdZcHF8xD8CMyGl3OmKYss13IE cf7PvX1v+ed7wIBYbKJjEjVdhn9MaeL34ZUWWMpOrhVUUo9bZHo4GVCsmH33ynRef9Y1jXHk6l4fg G8iouAdGGN7jn0NThsBLmMWXfD+Xc0Zq7a7DnyNRFXx9xAcR78IQiUioEthdkXoKBCJEAQ2fpzM3Y CHABnGcBjLNwmN00otsMN4Yv0UHBCNvxhe1dp3ZPOwFbs7nuc1SQJMrsZ+/bVPXsQK4n67mIGfEfg ncRzNHSA==; Received: from shell.armlinux.org.uk ([fd8f:7570:feb6:1:5054:ff:fe00:4ec]:34932) by pandora.armlinux.org.uk with esmtpsa (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.94.2) (envelope-from ) id 1omysw-0003Fd-7H; Mon, 24 Oct 2022 15:57:02 +0100 Received: from linux by shell.armlinux.org.uk with local (Exim 4.94.2) (envelope-from ) id 1omysk-0007DB-GY; Mon, 24 Oct 2022 15:56:50 +0100 Date: Mon, 24 Oct 2022 15:56:50 +0100 From: "Russell King (Oracle)" To: Frank Wunderlich Cc: Frank Wunderlich , linux-mediatek@lists.infradead.org, Alexander Couzens , Felix Fietkau , John Crispin , Sean Wang , Mark Lee , "David S. Miller" , Eric Dumazet , Jakub Kicinski , Paolo Abeni , Matthias Brugger , netdev@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org Subject: Re: Re: Re: Re: [PATCH v2] net: mtk_sgmii: implement mtk_pcs_ops Message-ID: References: MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: Sender: Russell King (Oracle) X-Spam-Status: No, score=-2.1 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,SPF_HELO_NONE,SPF_NONE autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Mon, Oct 24, 2022 at 04:45:40PM +0200, Frank Wunderlich wrote: > Hi > > Gesendet: Montag, 24. Oktober 2022 um 11:27 Uhr > > Von: "Russell King (Oracle)" > > > Here's the combined patch for where I would like mtk_sgmii to get to. > > > > It looks like this PCS is similar to what we know as pcs-lynx.c, but > > there do seem to be differences - the duplex bit for example appears > > to be inverted. > > > > Please confirm whether this still works for you, thanks. > > basicly Patch works, but i get some (1-50) retransmitts on iperf3 on first interval in tx-mode (on r3 without -R), other 9 are clean. reverse mode is mostly clean. > run iperf3 multiple times, every first interval has retransmitts. same for gmac0 (fixed-link 2500baseX) > > i notice that you have changed the timer again to 10000000 for 1000/2500baseX...maybe use here the default value too like the older code does? You obviously missed my explanation. I will instead quote the 802.3 standard which covers 1000base-X: 37.3.1.4 Timers link_timer Timer used to ensure Auto-Negotiation protocol stability and register read/write by the management interface. Duration: 10 ms, tolerance +10 ms, –0 s. For SGMII, the situation is different. Here is what the SGMII specification says: The link_timer inside the Auto-Negotiation has been changed from 10 msec to 1.6 msec to ensure a prompt update of the link status. So, 10ms is correct for 1000base-X, and 1.6ms correct for SGMII. However, feel free to check whether changing it solves that issue, but also check whether it could be some ARP related issue - remember, if two endpoints haven't communicated, they need to ARP to get the other end's ethernet addresses which adds extra latency, and may result in some packet loss in high packet queuing rate situations. -- RMK's Patch system: https://www.armlinux.org.uk/developer/patches/ FTTP is here! 40Mbps down 10Mbps up. Decent connectivity at last!