From mboxrd@z Thu Jan 1 00:00:00 1970 From: Florian Fainelli Subject: Re: [PATCH net-next 0/2] net: phy: replace PHY_HAS_INTERRUPT with a check for config_intr and ack_interrupt Date: Thu, 8 Nov 2018 14:34:41 -0800 Message-ID: <3401a6b0-e239-45fa-ea3d-63291f0d7526@gmail.com> References: <193e3970-8ce2-1221-357a-7b7f9f6aea76@gmail.com> <20181108223028.GI5259@lunn.ch> Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit Cc: David Miller , "netdev@vger.kernel.org" To: Andrew Lunn , Heiner Kallweit Return-path: Received: from mail-pg1-f196.google.com ([209.85.215.196]:33985 "EHLO mail-pg1-f196.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1728574AbeKIIMY (ORCPT ); Fri, 9 Nov 2018 03:12:24 -0500 Received: by mail-pg1-f196.google.com with SMTP id k1-v6so9485292pgq.1 for ; Thu, 08 Nov 2018 14:34:44 -0800 (PST) In-Reply-To: <20181108223028.GI5259@lunn.ch> Content-Language: en-US Sender: netdev-owner@vger.kernel.org List-ID: On 11/8/18 2:30 PM, Andrew Lunn wrote: > On Thu, Nov 08, 2018 at 10:54:50PM +0100, Heiner Kallweit wrote: >> Flag PHY_HAS_INTERRUPT is used only here for this small check. I think >> using interrupts isn't possible if a driver defines neither >> config_intr nor ack_interrupts callback. So we can replace checking >> flag PHY_HAS_INTERRUPT with checking for these callbacks. >> >> This allows to remove this flag from a lot of driver configs, let's >> start with the Realtek driver. > > Hi Heiner > > Ideally, we should do this to all the drivers, not just one. If we > leave PHY_HAS_INTERRUPT, people are going to use it. That then makes > the realtek driver then different to all the other drivers, and at > some point somebody will do something which breaks it because they > don't know the realtek driver is special. Agreed. -- Florian