Received: by 2002:a05:6a10:206:0:0:0:0 with SMTP id 6csp579046pxj; Fri, 28 May 2021 10:20:47 -0700 (PDT) X-Google-Smtp-Source: ABdhPJxDFEZhE9MIHcru4mlBlM8J34KHemHuMSJasVwq1pwPb7nrrpsBSDD2obCAptFChwg5j2Sk X-Received: by 2002:a02:6c14:: with SMTP id w20mr9417272jab.76.1622222446954; Fri, 28 May 2021 10:20:46 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1622222446; cv=none; d=google.com; s=arc-20160816; b=NUt5iHgqQf2+rzfhNTCIVKRsYt2bnqMjccl7z/MGYAb0QFlUWoIpsYMToiarCJhoJw Kn4m61MM958UCsQSuD/u4CEr8ru7k9cq9ErEwqhFUDdKSlLD8Q2G3BV/B9lAOTIa5a0v rn+xeV4hWfzOuf18LMuYy6nqm9g+Fi8r44iP8MIHW2tm/Nx4TP5XZlUh5As5YezT/7hp OBwHtHBetc3VQFlCY9Bm0cmrdvSlWtVX+1qOhsq8+rAx5NfbNUm2UgAaPeXqH/qc6kHU Tuc+Ww3h/cTwwY5aKE1u/It5ST26g5XH+Pz3MQc5FogBn7k5YAcWX/mfipibF/p+hMxj Pi9Q== 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=6cDg1RXPGmWw0L+86ZDaBALRGmDDzfxkeGMCVHlpckk=; b=aQ5uHPo3cnfrjPQQveVSSoK+GZh1LQd9VqDk3ZYWs+xutjs+fVM1Lt9G649PeNrQ+Y eOQ0OUWtw7XiEthsXESXCI7YRP1pRCbiX2DyYrNy5tJhP3zFFpq/F561yN9hagPzaNUP hha/4MReFFyiHuB0EmaNrth2QY6ca/qGboh+LoHoWGsZRNn0kbg8AHltWYQ8nwXHkXGf T0xqhJcYaxExYU+z6dzJretGN/qNDXVmqiWnpkThFnIMyCnfPCYoqMbAnQX0BaeqCclG zMg6jd5cL1tOpQ9TOqTEDRZUQ1CCt2SwDw4TRZkgTlu83d48MRKZIQP1+NlMJM0qH48Y xANg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@lunn.ch header.s=20171124 header.b=xME48x3w; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id w3si6233444iow.99.2021.05.28.10.20.33; Fri, 28 May 2021 10:20:46 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@lunn.ch header.s=20171124 header.b=xME48x3w; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S235590AbhE1Qy1 (ORCPT + 99 others); Fri, 28 May 2021 12:54:27 -0400 Received: from vps0.lunn.ch ([185.16.172.187]:34250 "EHLO vps0.lunn.ch" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S236624AbhE1QyZ (ORCPT ); Fri, 28 May 2021 12:54:25 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lunn.ch; s=20171124; h=In-Reply-To:Content-Disposition:Content-Type:MIME-Version: References:Message-ID:Subject:Cc:To:From:Date:From:Sender:Reply-To:Subject: Date:Message-ID:To:Cc:MIME-Version:Content-Type:Content-Transfer-Encoding: Content-ID:Content-Description:Content-Disposition:In-Reply-To:References; bh=6cDg1RXPGmWw0L+86ZDaBALRGmDDzfxkeGMCVHlpckk=; b=xME48x3w0xYzMJ8PrIo2DbtAJ4 VE1m0PblhrI2CSrNE292WnptRwo6PNK5CWK4gbEXv58ytB3RoPXXPsV//bmWE8vMDc4cSGMwwReaH 0qW0sI86P/1gLiMFoM7oXLVpioMKsDQjYCK0gphnoyyhwSzPM2AlrqGl1kr5dpRuzMhI=; Received: from andrew by vps0.lunn.ch with local (Exim 4.94.2) (envelope-from ) id 1lmfix-006m6h-IV; Fri, 28 May 2021 18:52:39 +0200 Date: Fri, 28 May 2021 18:52:39 +0200 From: Andrew Lunn To: "Bajjuri, Praneeth" Cc: "Modi, Geet" , "David S . Miller" , Jakub Kicinski , "netdev@vger.kernel.org" , "linux-kernel@vger.kernel.org" Subject: Re: [EXTERNAL] Re: [PATCH] net: phy: dp83867: perform soft reset and retain established link Message-ID: References: <20210324010006.32576-1-praneeth@ti.com> <404285EC-BBF0-4482-8454-3289C7AF3084@ti.com> <3494dcf6-14ca-be2b-dbf8-dda2e208b70b@ti.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <3494dcf6-14ca-be2b-dbf8-dda2e208b70b@ti.com> Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Fri, May 28, 2021 at 11:32:15AM -0500, Bajjuri, Praneeth wrote: > Hi Andrew, > > On 3/31/2021 11:35 AM, Andrew Lunn wrote: > > > > as per datasheet: https://www.ti.com/lit/ds/symlink/dp83867cr.pdf > > > > > > > 8.6.26 Control Register (CTRL) > > > > do SW_RESTART to perform a reset not including the registers and is > > > > acceptable to do this if a link is already present. > > > > > > > > > I don't see any code here to determine if the like is present. What if > > > the cable is not plugged in? > > > > > > This API is primarily used for reset. Link Status is checked thru different > > > register. This shall not impact the cable plug in/out. With this change, it > > > will align with DP83822 driver API. > > > > So why is there the comment: > > > > > > and is > > > > acceptable to do this if a link is already present. > > > > That kind of says, it is not acceptable to do this if the link is not > > present. Which is why i'm asking. > > Does the feedback from Geet help in clarity you requested. > Ref: > https://lore.kernel.org/netdev/4838EA12-7BF4-4FF2-8305-7446C3498DDF@ti.com/ Not really. > and is > > > > acceptable to do this if a link is already present. There needs to be something to either: 1) Ensure there is link, so we known we are within acceptable behaviour. 2) Document what happens when there is no link, meaning we do something which is not acceptable. Is the magic smoke going to be released? Does the link die until the next reboot? Or despite it being unacceptable, nothing really happens, and it is not a problem? Andrew