From mboxrd@z Thu Jan 1 00:00:00 1970 From: Phil Elwell Subject: Re: [PATCH] lan78xx: Don't reset the interface on open Date: Tue, 10 Apr 2018 15:33:55 +0100 Message-ID: References: <1523362705-30032-1-git-send-email-phil@raspberrypi.org> Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit To: Nisar.Sayed@microchip.com, Woojung.Huh@microchip.com, UNGLinuxDriver@microchip.com, agraf@suse.de, tbogendoerfer@suse.de, netdev@vger.kernel.org, linux-usb@vger.kernel.org, linux-kernel@vger.kernel.org Return-path: In-Reply-To: Content-Language: en-US Sender: linux-kernel-owner@vger.kernel.org List-Id: netdev.vger.kernel.org Hi Nisar, On 10/04/2018 15:16, Nisar.Sayed@microchip.com wrote: > Thanks Phil, for identifying the issues. > >> - ret = lan78xx_reset(dev); >> - if (ret < 0) >> - goto done; >> - >> phy_start(net->phydev); >> >> netif_dbg(dev, ifup, dev->net, "phy initialised successfully"); >> -- > > You may need to start the interrupts before "phy_start" instead of suppressing call to "lan78xx_reset". > > + if (dev->domain_data.phyirq > 0) > + phy_start_interrupts(dev->net->phydev); Shouldn't phy_connect_direct, called from lan78xx_phy_init, already have enabled interrupts for us? This patch addresses two problems - time wasted by renegotiating the link after the reset and the missed interrupt - and I'd like both to be fixed. Unless you can come up with a good reason for performing the reset from the open handler I think it should be removed. Phil