From: Florian Fainelli Subject: Re: [PATCH net-next v2] net: phy: remove parameter new_link from phy_mac_interrupt() Date: Thu, 11 Jan 2018 17:20:38 -0800 Message-ID: <7f9da022-98c8-50bd-ec64-395252ac5665@gmail.com> References: <265d0b95-874e-5d94-aa4e-3bcf9b2b396d@gmail.com> Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit Cc: "netdev@vger.kernel.org" To: Heiner Kallweit , Andrew Lunn , Doug Berger , David Miller Return-path: Received: from mail-wr0-f180.google.com ([209.85.128.180]:35121 "EHLO mail-wr0-f180.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S932783AbeALBUn (ORCPT ); Thu, 11 Jan 2018 20:20:43 -0500 Received: by mail-wr0-f180.google.com with SMTP id g38so754129wrd.2 for ; Thu, 11 Jan 2018 17:20:42 -0800 (PST) In-Reply-To: <265d0b95-874e-5d94-aa4e-3bcf9b2b396d@gmail.com> Content-Language: en-US Sender: netdev-owner@vger.kernel.org List-ID: On 01/10/2018 12:21 PM, Heiner Kallweit wrote: > I see two issues with parameter new_link: > > 1. It's not needed. See also phy_interrupt(), works w/o this parameter. > phy_mac_interrupt sets the state to PHY_CHANGELINK and triggers the > state machine which then calls phy_read_status. And phy_read_status > updates the link state. > > 2. phy_mac_interrupt is used in interrupt context and getting the link > state may sleep (at least when having to access the PHY registers > via MDIO bus). > > So let's remove it. > > Signed-off-by: Heiner Kallweit Reviewed-by: Florian Fainelli Tested-by: Florian Fainelli Thanks! -- Florian