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.3 required=3.0 tests=DKIMWL_WL_HIGH,DKIM_SIGNED, DKIM_VALID,HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI,SPF_HELO_NONE, SPF_PASS,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 0EC76C4BA24 for ; Wed, 26 Feb 2020 19:12:40 +0000 (UTC) Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (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 D3AE120656 for ; Wed, 26 Feb 2020 19:12:39 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (2048-bit key) header.d=lists.infradead.org header.i=@lists.infradead.org header.b="O7hV4EhD"; dkim=fail reason="signature verification failed" (2048-bit key) header.d=armlinux.org.uk header.i=@armlinux.org.uk header.b="wN0aYjMT" DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org D3AE120656 Authentication-Results: mail.kernel.org; dmarc=fail (p=none dis=none) header.from=armlinux.org.uk Authentication-Results: mail.kernel.org; spf=none smtp.mailfrom=linux-arm-kernel-bounces+infradead-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=bombadil.20170209; h=Sender: Content-Transfer-Encoding:Content-Type:Cc:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:In-Reply-To:MIME-Version:References: Message-ID:Subject:To:From:Date:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=llRoo0JItnRXLynFqSM/X1FGoyYCIY41Z16FL7jpHt0=; b=O7hV4EhDxKrh0X 2h5VMoY8RnSUQn4Q2p9aG2bK0g0GUmjjFaa3H999+lnfybO59fObLcZv+wxR5mqWsVoKozbmmGuSd ICVQFpbGpwxYyr6pxeJd4kSCh0jQORek6ycIPiEEFuzajDnA8U1WkmtyOdpXcArbFeS4Y09UzAYW1 e0jhz8YFojVXRf0txAA1/dC8LnGBJeKOg1l5OSyCGXCjN3WAbQn98e7mMSVwFsenysxURoD0qedtv txBLDP2+oOauj56UaX4eyUI+wU2eLyM3em+07jewj7l5k1vP62yclCkFvElmReHw2SfvjV35T67CK 0EuIxLia6sC0bRsZBLUg==; Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.92.3 #3 (Red Hat Linux)) id 1j726i-0007T2-LY; Wed, 26 Feb 2020 19:12:32 +0000 Received: from pandora.armlinux.org.uk ([2001:4d48:ad52:3201:214:fdff:fe10:1be6]) by bombadil.infradead.org with esmtps (Exim 4.92.3 #3 (Red Hat Linux)) id 1j726e-0007Rc-Oz; Wed, 26 Feb 2020 19:12:30 +0000 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-Type: MIME-Version:References: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:List-Id: List-Help:List-Unsubscribe:List-Subscribe:List-Post:List-Owner:List-Archive; bh=KcpXKrnA+tSfLVsLB+Y3FGpvlq2JJa1WqGuNDRsLFVI=; b=wN0aYjMTZnoSDpDhzYIt38EqZ RJf1TJ5E/4mJ7s2PkotL8Y9CcARYlFdLFBhJjHRgQbIO/5Ji4MKvPuToTgdMQSVZaBpewmgISApvn hoitaH94VzMNRiKYpmU5JELCdxM/6krlabZlxq8GsuMnMbEC+YGGf03ukVz5HXolo+reNStySqmDb fBDYKr+Hr7kd+lbHivf4/VbIUkNapTWXz50IuZqT7s59Bzwnylte2jS600ebdyS68R5ngkl1ST3GE QEsruSikfBoyALG0il3MrgKBvRV/HfC296Dar4JHNwzc4R1VVd4Ln7DzNJofB0XNL8X+PD9bkXvqD rWi72JvXw==; Received: from shell.armlinux.org.uk ([2002:4e20:1eda:1:5054:ff:fe00:4ec]:53150) by pandora.armlinux.org.uk with esmtpsa (TLSv1.2:ECDHE-RSA-AES256-GCM-SHA384:256) (Exim 4.90_1) (envelope-from ) id 1j726A-00011K-VO; Wed, 26 Feb 2020 19:11:59 +0000 Received: from linux by shell.armlinux.org.uk with local (Exim 4.92) (envelope-from ) id 1j7263-0000EC-U4; Wed, 26 Feb 2020 19:11:51 +0000 Date: Wed, 26 Feb 2020 19:11:51 +0000 From: Russell King - ARM Linux admin To: Ioana Ciornei Subject: Re: [PATCH net-next v2 1/8] net: phylink: propagate resolved link config via mac_link_up() Message-ID: <20200226191151.GH25745@shell.armlinux.org.uk> References: <20200226102312.GX25745@shell.armlinux.org.uk> <20200226115549.GZ25745@shell.armlinux.org.uk> <20200226133614.GA25745@shell.armlinux.org.uk> MIME-Version: 1.0 Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.10.1 (2018-07-13) X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20200226_111228_816204_10A2BC86 X-CRM114-Status: GOOD ( 19.44 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Andrew Lunn , Linux Doc Mailing List , Thomas Petazzoni , "linux-stm32@st-md-mailman.stormreply.com" , Florian Fainelli , Ioana Ciocoi Radulescu , Jonathan Corbet , Michal Simek , Jose Abreu , Jakub Kicinski , Mark Lee , Sean Wang , Alexandre Torgue , Hauke Mehrtens , Radhey Shyam Pandey , "moderated list:ARM/Mediatek SoC support" , John Crispin , Matthias Brugger , Giuseppe Cavallaro , "moderated list:ARM/Mediatek SoC support" , netdev , Vivien Didelot , Maxime Coquelin , Felix Fietkau , Vladimir Oltean , "David S. Miller" , Heiner Kallweit Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+infradead-linux-arm-kernel=archiver.kernel.org@lists.infradead.org On Wed, Feb 26, 2020 at 06:32:55PM +0000, Ioana Ciornei wrote: > > Subject: Re: [PATCH net-next v2 1/8] net: phylink: propagate resolved link config > > via mac_link_up() > > > > On Wed, 26 Feb 2020 at 20:21, Vladimir Oltean wrote: > > > > > > On Wed, 26 Feb 2020 at 15:36, Russell King - ARM Linux admin > > > wrote: > > > > > > > > > > > > dpaa2 is complicated by the firmware, and that we can't switch the > > > > interface mode between (SGMII,1000base-X) and 10G. > > > > > > > > If the firmware is in "DPMAC_LINK_TYPE_PHY" mode, it expects to be > > > > told the current link parameters via the dpmac_set_link_state() call > > > > - it isn't clear whether that needs to be called for other modes > > > > with the up/down state (firmware API documentation is poor.) > > > > > > > > > > With PCS control in Linux, I am pretty sure that you don't want > > > anything other than DPMAC_LINK_TYPE_PHY anyway. > > > Basically in DPMAC_LINK_TYPE_FIXED, the MC firmware is in control of > > > the PCS and polls its link state to emit link notifications to objects > > > connected to the DPMAC. So Linux control of PCS would class with > > > > s/class/clash/ > > > > > firmware control of the PCS, leading to undesirable side-effects to > > > say the least. > > > If the DPMAC object is in DPMAC_LINK_TYPE_FIXED, the dpaa2-eth in fact > does not even connect to a phy so all the phylink interaction is not happening. > As Vladimir said, in this case it's the MC firmware's job to poll the PCS and > notify any connected objects of a link change. Please see the patches I've referred Vladimir to, specifically this: if (attr.link_type == DPMAC_LINK_TYPE_PHY) { /* FIXME: how do we know whether this DPMAC has a PCS? */ err = dpaa2_pcs_create(mac, attr.id); if (err) goto err_phylink_destroy; phylink_add_pcs(mac->phylink, &dpaa2_pcs_phylink_ops); } Hence, if we are not in DPMAC_LINK_TYPE_PHY, then we never talk to the PCS, thereby satisfying the requirements of the firmware not to touch the PCS if it's in FIXED mode. It seems this is becoming a storm in a tea cup. Please stop. -- 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 _______________________________________________ linux-arm-kernel mailing list linux-arm-kernel@lists.infradead.org http://lists.infradead.org/mailman/listinfo/linux-arm-kernel