Received: by 2002:a05:7412:a9a2:b0:e2:908c:2ebd with SMTP id o34csp320526rdh; Thu, 26 Oct 2023 03:16:36 -0700 (PDT) X-Google-Smtp-Source: AGHT+IEUxzwO6xtmA4MBuD07JqCHg0/E+Q5bToZwNmEDG9qxYIYk4dHFa21Ouvgwx2ybJZAsXLrE X-Received: by 2002:a05:690c:108:b0:5a5:575:b222 with SMTP id bd8-20020a05690c010800b005a50575b222mr19588499ywb.23.1698315396228; Thu, 26 Oct 2023 03:16:36 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1698315396; cv=none; d=google.com; s=arc-20160816; b=BPrF66f60Ov0B3twmtZofPFIXKiueuDoAYO3ko5owRlRnM3bPp5yw6xLMgrzH7BAYz OGAKKjdifuvRMH+8E0ysW5abF8BfB6uVHp3ef0xtHeCpHiOwZKRFSYviDbpsj83RkuvW 8xSZAj+bmD/mMkGJXyWTqKMUbKcEbalkXqrmzX4EhOCPEGmZsIa6M5A3tUQp4V9gZfrk s6vY+9CJ0ik5NVCa9xkz9SxNySRCKGaMCiIh8hikMZUyGBoSYvoz9Dd8k8NwwsiU+MyI zY/Z5pEyEoR9GMrkDet3ekqC9bH37tR2edmRJB4+/127YlZr7YRtvEQyvPTD13gGXXNH Jw/w== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:in-reply-to:content-disposition:mime-version :references:message-id:subject:cc:to:from:date:dkim-signature; bh=Ftl20n7Zvm9uFVrOETdmfa+i0xyjkeR9W4TXv4C6nzs=; fh=a1W0X+7ipdMdAWLkx100F0Byi9pDJ9vmLyWw9IuN02Y=; b=0xHYNN7UeB6vvpmsn3btFXnOFRVNdUDDsqGpVldce0JmkuQObYjleq0LJkJrCStZjS dM+8LPxCmibk5LRBMnhRU2nkGDSi6WXM9xZB6W2yFjJEzPSyPMUrtnDf9eTRb7EKz9Kh s4wJzd/lGx8QNe1tlspm/kW7AZC5OdmKtPG6uNTVUyqSl38Q9iiEQIBzd8CMtg8dKbwZ 3TgD9FNFN5jk+eGjlyua2SMS1l2bGdh33Ne2nKa+LeFwvCt0W42+/0VVJ/5py6oHlTCL bLUzJq/RYuUuANxQVMGh++BbS9AGLAnQYwGQma4axp+RKcrUiquI87YLuea1QiGquhOY xzew== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@microchip.com header.s=mchp header.b=kaCMsmaY; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.33 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=QUARANTINE sp=QUARANTINE dis=NONE) header.from=microchip.com Return-Path: Received: from lipwig.vger.email (lipwig.vger.email. [23.128.96.33]) by mx.google.com with ESMTPS id r18-20020a81c312000000b005a7f5e20626si14025528ywk.176.2023.10.26.03.16.35 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 26 Oct 2023 03:16:36 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.33 as permitted sender) client-ip=23.128.96.33; Authentication-Results: mx.google.com; dkim=pass header.i=@microchip.com header.s=mchp header.b=kaCMsmaY; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.33 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=QUARANTINE sp=QUARANTINE dis=NONE) header.from=microchip.com Received: from out1.vger.email (depot.vger.email [IPv6:2620:137:e000::3:0]) by lipwig.vger.email (Postfix) with ESMTP id 83F1E80417FC; Thu, 26 Oct 2023 03:16:06 -0700 (PDT) X-Virus-Status: Clean X-Virus-Scanned: clamav-milter 0.103.10 at lipwig.vger.email Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S230365AbjJZKP6 (ORCPT + 99 others); Thu, 26 Oct 2023 06:15:58 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:42354 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229611AbjJZKP4 (ORCPT ); Thu, 26 Oct 2023 06:15:56 -0400 Received: from esa.microchip.iphmx.com (esa.microchip.iphmx.com [68.232.154.123]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id A5DEE195; Thu, 26 Oct 2023 03:15:51 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=microchip.com; i=@microchip.com; q=dns/txt; s=mchp; t=1698315353; x=1729851353; h=date:from:to:cc:subject:message-id:references: mime-version:in-reply-to; bh=RFivSlyyCN0/u7lSbSw417gmoKe6JNs1oDbyCj3MVR4=; b=kaCMsmaYekSE08V0cbsbKN4O6O1G4U19FHs/zynjndJufwtvI+ZZs6UO 54G1g1+AB5XSuFc8Y7XQW3588li782VIrRVGjRDQaQgXU7B/MW4+oZup3 U0c/7DrWXO/rxC18u0LuuD/NCbuutJ8UupJPzlVYamEKBkkZsGJwZvXd+ uGihGVtzMJI0b7TlwJG5U/QZNDGJblnirPRMUGbgJRRNmR9XhbW5QPPAB iceEoCG1a4mggEObgShgLScM3Xpq6sLZlfJSpVfSg9aVfv4i9Lve2tXQA LEA3k55gLndQXU2XOdsIlfbkslzWCHTV/i+exI+DHSMfI1XW+UPQoZgmG A==; X-CSE-ConnectionGUID: uV9XzKt9TfK6K5PKhz3XAg== X-CSE-MsgGUID: tkN/U9bESHWBxLYxXil25A== X-ThreatScanner-Verdict: Negative X-IronPort-AV: E=Sophos;i="6.03,253,1694761200"; d="scan'208";a="177802887" X-Amp-Result: SKIPPED(no attachment in message) Received: from unknown (HELO email.microchip.com) ([170.129.1.10]) by esa6.microchip.iphmx.com with ESMTP/TLS/ECDHE-RSA-AES128-GCM-SHA256; 26 Oct 2023 03:15:49 -0700 Received: from chn-vm-ex01.mchp-main.com (10.10.85.143) by chn-vm-ex04.mchp-main.com (10.10.85.152) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2507.21; Thu, 26 Oct 2023 03:15:47 -0700 Received: from localhost (10.10.85.11) by chn-vm-ex01.mchp-main.com (10.10.85.143) with Microsoft SMTP Server id 15.1.2507.21 via Frontend Transport; Thu, 26 Oct 2023 03:15:46 -0700 Date: Thu, 26 Oct 2023 15:44:40 +0530 From: Raju Lakkaraju To: "Russell King (Oracle)" CC: , , , , , , , Subject: Re: [PATCH net-next V1] net: pcs: xpcs: Add 2500BASE-X case in get state for XPCS drivers Message-ID: References: <20231026054305.336968-1-Raju.Lakkaraju@microchip.com> MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Disposition: inline In-Reply-To: X-Spam-Status: No, score=-0.9 required=5.0 tests=DKIMWL_WL_HIGH,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,HEADER_FROM_DIFFERENT_DOMAINS, MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS autolearn=unavailable autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lipwig.vger.email Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org X-Greylist: Sender passed SPF test, not delayed by milter-greylist-4.6.4 (lipwig.vger.email [0.0.0.0]); Thu, 26 Oct 2023 03:16:06 -0700 (PDT) Hi Russell King, Thank you for review the patch. The 10/26/2023 10:01, Russell King (Oracle) wrote: > EXTERNAL EMAIL: Do not click links or open attachments unless you know the content is safe > > On Thu, Oct 26, 2023 at 11:13:05AM +0530, Raju Lakkaraju wrote: > > + sts = xpcs_read(xpcs, MDIO_MMD_VEND2, DW_VR_MII_MMD_STS); > > + > > + state->link = !!(sts & DW_VR_MII_MMD_STS_LINK_STS); > > + if (!state->link) { > > + state->speed = SPEED_UNKNOWN; > > + state->pause = MLO_PAUSE_NONE; > > + state->duplex = DUPLEX_UNKNOWN; > > + return 0; > > + } > > You don't need this. If autoneg is enabled then these are initialised > prior to calling this by phylink using: > > state->speed = SPEED_UNKNOWN; > state->duplex = DUPLEX_UNKNOWN; > state->pause = MLO_PAUSE_NONE; > Ok. I will remove the change. Thanks, Raju > or if not using autoneg: > > state->speed = pl->link_config.speed; > state->duplex = pl->link_config.duplex; > state->pause = pl->link_config.pause; > > so you don't need to touch them if the link is down. > > -- > RMK's Patch system: https://www.armlinux.org.uk/developer/patches/ > FTTP is here! 80Mbps down 10Mbps up. Decent connectivity at last! -- -------- Thanks, Raju