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=-2.0 required=3.0 tests=DKIM_INVALID,DKIM_SIGNED, HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS, URIBL_BLOCKED,USER_AGENT_SANE_1 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 A8B62C34022 for ; Mon, 17 Feb 2020 15:54:02 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id 50A25206F4 for ; Mon, 17 Feb 2020 15:54:02 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=fail reason="signature verification failed" (2048-bit key) header.d=armlinux.org.uk header.i=@armlinux.org.uk header.b="H+YG8O1C" Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1729550AbgBQPyB (ORCPT ); Mon, 17 Feb 2020 10:54:01 -0500 Received: from pandora.armlinux.org.uk ([78.32.30.218]:38406 "EHLO pandora.armlinux.org.uk" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727553AbgBQPyB (ORCPT ); Mon, 17 Feb 2020 10:54:01 -0500 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=armlinux.org.uk; s=pandora-2019; h=Sender:Content-Type:MIME-Version: Message-ID:Subject:Cc:To:From:Date:Reply-To:Content-Transfer-Encoding: Content-ID:Content-Description:Resent-Date:Resent-From:Resent-Sender: Resent-To:Resent-Cc:Resent-Message-ID:In-Reply-To:References:List-Id: List-Help:List-Unsubscribe:List-Subscribe:List-Post:List-Owner:List-Archive; bh=5j4JuUqMT93hmtsiWVXppr1iNJA7Bbq53PUZ4dpqUJI=; b=H+YG8O1C5qTaQP8R2V/PShOhA uI+TEeehepFLlsPbRFF8QHe2o5U9uPEpnjS9AO410LIIz99H/xAlGlZKMmopUNxJ8Be6h4gK3IUfX VJSjWSjW3zvxRO1xfYlNEPoM8r2JUgg2ATJbQ93te+SxOB9XaE0+wqFIwm1iQjSdq0MPOL5PIzfJ2 jdXBHmZ3usDof20TmW3yuztR6QGcmgKEaQrIlN15otpQ2RDaUSLmDarOK04oJ1orwBGevLzYrIMXC S4lkXd+sEpK3h0Y9JYWRq3nTPPyhUYL5OEZ5C/PuitheMZwpaGymtvGzs3mvUduyKY8wphSgm97Be 4jOkhnAbA==; Received: from shell.armlinux.org.uk ([2001:4d48:ad52:3201:5054:ff:fe00:4ec]:41576) by pandora.armlinux.org.uk with esmtpsa (TLSv1.2:ECDHE-RSA-AES256-GCM-SHA384:256) (Exim 4.90_1) (envelope-from ) id 1j3iiU-0001hR-Bw; Mon, 17 Feb 2020 15:53:50 +0000 Received: from linux by shell.armlinux.org.uk with local (Exim 4.92) (envelope-from ) id 1j3iiQ-0006QY-8q; Mon, 17 Feb 2020 15:53:46 +0000 Date: Mon, 17 Feb 2020 15:53:46 +0000 From: Russell King - ARM Linux admin To: Andrew Lunn , Florian Fainelli , Heiner Kallweit Cc: "David S. Miller" , netdev@vger.kernel.org Subject: [PATCH net-next 0/4] phylib: add hardware resolved pause mode support for marvell PHYs Message-ID: <20200217155346.GW25745@shell.armlinux.org.uk> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline User-Agent: Mutt/1.10.1 (2018-07-13) Sender: netdev-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: netdev@vger.kernel.org Hi, Marvell PHYs provide a register that gives us the resolution results for speed, duplex and the pause enablement status. This series adds support for using this, and passing it through phylib via the newly introduced phy_get_pause() interface. In order to do this, we need to read the copper PHY results from the correct register; now that I have access to the Marvell documentation, this becomes much easier for the 88x3310 PHY. I also find that the code in the marvell 1G driver does not correctly check that the resolved state in the status register is valid prior to using it, so there is a patch for that too; I don't deem it important enough for it to be sent via the -net tree, which would add additional dependency complexity for this series. drivers/net/phy/marvell.c | 46 +++++++++++++- drivers/net/phy/marvell10g.c | 147 ++++++++++++++++++++++++++++--------------- drivers/net/phy/phy_device.c | 6 ++ include/linux/phy.h | 9 +++ 4 files changed, 154 insertions(+), 54 deletions(-) -- RMK's Patch system: https://www.armlinux.org.uk/developer/patches/ FTTC broadband for 0.8mile line in suburbia: sync at 12.1Mbps down 622kbps up According to speedtest.net: 11.9Mbps down 500kbps up