Received: by 2002:a05:6358:7058:b0:131:369:b2a3 with SMTP id 24csp10791675rwp; Fri, 21 Jul 2023 05:11:51 -0700 (PDT) X-Google-Smtp-Source: APBJJlH7NTtJQ2zySfLHj0U/vtnGmQ/bE9sHeAk/wTcB2x8mBECkgTDqWB0E44EIG+sHfr3hG7h2 X-Received: by 2002:a05:6a00:b8d:b0:682:4c1c:a0fc with SMTP id g13-20020a056a000b8d00b006824c1ca0fcmr2223416pfj.19.1689941510900; Fri, 21 Jul 2023 05:11:50 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1689941510; cv=none; d=google.com; s=arc-20160816; b=mgKRtG8kny2kTN6Spko9O3sbbRN9KtYfbiImzXhRy3kYmGYRT5Eosph0B7sXgLPfy9 Fa8B0U8FpKAXWgGZrVEMX3BObH20kLYAKoyv1ppMEbJDDd5eXAfUyEq0NAytOwzOde+h mkJmNQvapbj+IV3TGJBH4Ubic6cyhAEa9soYpFZc57Mj4CiSZDcR/CyYU/ERH/QkOOnC YSAE4DHXjd+0Ojnyenk9gIGOYRoUculIZSqGjQsJC7Gb85kT9j/nJK8wVsMmPhc+wZZ9 7YhQx5QORB05IX+FlWSaHQO15/KcCGQABsgjDqWH50Him7RzFDBZHZC2meSKCschbUaE xHSg== 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-disposition :mime-version:references:message-id:subject:cc:to:from:date :dkim-signature; bh=DuaxoszqcDy6m6GIyAZxffUkYx6a4MOf8Tdr9C+qdMo=; fh=Wg0BpsE0hPD224Peo/9nern1WqckwEDxDMlDM9dXddI=; b=GBn1GysLrn8AtK763H/DZk55qb6FGTVY+LA7cnD0WRYzR5EhpIgnZYe3qiQzQVuViz EXhqWSsir3NKSvCmX7cPcsJQWIX7aJni55zvJQU/zIDHACGvYcWah3HsNzyPgIV+cJ1N cMUTV0B6WF5xtJfmj3LW671uKHR0nqY6VFG8+bCwAGWlvhtCc4EZcpFTr++kHn1A2elc 8RNJVJ0BJpmIh2cy3FVsZViXouKMhAQcjjQEx9o7rPipcUEunxbf42aBf3ZfYN0NrVFt xLSPQzwcRhgzlSBfe7/dJZAv3MsbPrD8f7YtnDLo/G9rlssyp9zIO9ytL0h56RWK9nCa hnmA== ARC-Authentication-Results: i=1; mx.google.com; dkim=fail (test mode) header.i=@armlinux.org.uk header.s=pandora-2019 header.b=PcDg7xHy; 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 be6-20020a056a001f0600b00660b5630908si2851672pfb.269.2023.07.21.05.11.38; Fri, 21 Jul 2023 05:11:50 -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=PcDg7xHy; 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 S230411AbjGUL5F (ORCPT + 99 others); Fri, 21 Jul 2023 07:57:05 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:50250 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229493AbjGUL5E (ORCPT ); Fri, 21 Jul 2023 07:57:04 -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 194EC2130; Fri, 21 Jul 2023 04:57:03 -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-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=DuaxoszqcDy6m6GIyAZxffUkYx6a4MOf8Tdr9C+qdMo=; b=PcDg7xHyCdW+6u3XgD5Oov1oGs VxmWWh6LQUoq/9BFjT4AjfSsFguIOoDOIrriM6RmIqeCRfv5aU5zSOlttG4Uddd+fwNxn+XX4pQ13 TJ/pSp0UMKzAbHnNpG9nbSlQjXBH/ayqFEf5EhEX8/dWB1itFFvmBxWJ/aMV/hFJ3SS5YgWZ+0fxF zfK1JD7Py5UafUIAk9YPVXFvkqbdvt8ZzOtV/jMBBwKBgoVmVz5jLYi1oJHxnqCPjoVjfprZ+WPbw qhhBsqTC0606IfyTMKgNs1kFVXVhHXnOmYerT9KNIJymIhJJQURePa83r6a46I2KpTm+YeNcILBLv S6lKdyCA==; Received: from shell.armlinux.org.uk ([fd8f:7570:feb6:1:5054:ff:fe00:4ec]:48510) by pandora.armlinux.org.uk with esmtpsa (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.96) (envelope-from ) id 1qMokm-0003ry-2D; Fri, 21 Jul 2023 12:57:00 +0100 Received: from linux by shell.armlinux.org.uk with local (Exim 4.94.2) (envelope-from ) id 1qMokm-00066i-CJ; Fri, 21 Jul 2023 12:57:00 +0100 Date: Fri, 21 Jul 2023 12:57:00 +0100 From: "Russell King (Oracle)" To: Raju Lakkaraju Cc: netdev@vger.kernel.org, davem@davemloft.net, kuba@kernel.org, linux-kernel@vger.kernel.org, bryan.whitehead@microchip.com, andrew@lunn.ch, UNGLinuxDriver@microchip.com Subject: Re: [PATCH net-next 5/7] net: lan743x: Add support to the Phylink framework Message-ID: References: <20230721060019.2737-1-Raju.Lakkaraju@microchip.com> <20230721060019.2737-6-Raju.Lakkaraju@microchip.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline 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,RCVD_IN_DNSWL_BLOCKED, SPF_HELO_NONE,SPF_NONE,T_SCC_BODY_TEXT_LINE,URIBL_BLOCKED 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 Fri, Jul 21, 2023 at 09:49:06AM +0100, Russell King (Oracle) wrote: > On Fri, Jul 21, 2023 at 11:30:17AM +0530, Raju Lakkaraju wrote: > > +static void lan743x_phylink_mac_config(struct phylink_config *config, > > + unsigned int link_an_mode, > > + const struct phylink_link_state *state) > > +{ > > + struct net_device *netdev = to_net_dev(config->dev); > > + struct lan743x_adapter *adapter = netdev_priv(netdev); > > + bool status; > > + int ret; > > + > > + lan743x_mac_cfg_update(adapter, state->link, state->speed, > > + state->advertising); > > Please, no new state->speed users in mac_config(). I have just submitted a patch series that results in state->speed always being set to SPEED_UNKNOWN when this function is called to prevent future uses of this struct member. > > + adapter->phylink_config.dev = &netdev->dev; > > + adapter->phylink_config.type = PHYLINK_NETDEV; > > + adapter->phylink_config.mac_managed_pm = true; > > + /* This driver makes use of state->speed in mac_config */ > > + adapter->phylink_config.legacy_pre_march2020 = true; > > Sorry, but no new users of legacy features. ... and which totally strips out the legacy phylink code, which I've been wanting to remove for the last three years. -- RMK's Patch system: https://www.armlinux.org.uk/developer/patches/ FTTP is here! 80Mbps down 10Mbps up. Decent connectivity at last!