[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date: Wed, 12 Dec 2018 13:10:13 +0000
From: Claudiu Manoil <claudiu.manoil@....com>
To: Andrew Lunn <andrew@...n.ch>,
"jocke@...inera.com" <joakim.tjernlund@...inera.com>
CC: "netdev @ vger . kernel . org" <netdev@...r.kernel.org>,
Florian Fainelli <f.fainelli@...il.com>
Subject: RE: [PATCHv2] gianfar: Add gfar_change_carrier() for Fixed PHYs
>-----Original Message-----
>From: Andrew Lunn <andrew@...n.ch>
>Sent: Wednesday, December 12, 2018 2:43 PM
>To: jocke@...inera.com <joakim.tjernlund@...inera.com>
>Cc: netdev @ vger . kernel . org <netdev@...r.kernel.org>; Claudiu Manoil
><claudiu.manoil@....com>; Florian Fainelli <f.fainelli@...il.com>
>Subject: Re: [PATCHv2] gianfar: Add gfar_change_carrier() for Fixed PHYs
>
>On Wed, Dec 12, 2018 at 01:33:08PM +0100, Joakim Tjernlund wrote:
>> This allows to control carrier from /sys/class/net/ethX/carrier for
>> Fixed PHYs.
>>
>> Signed-off-by: Joakim Tjernlund <joakim.tjernlund@...inera.com>
>> ---
>> v2 - Only allow carrier changes for Fixed PHYs
>>
>> Florian: I have reimpl. this as I think you meant by registering
>> a Fixed PHY callback.
>> Andrew: Are happy with this as well?
>
>Hi Joakim
>
>The basic idea is O.K.
>
>>
>> If this is OK I will sent the other 2 drivers.
>
>Rather than replicating the code three times, how about putting all
>the code in the fixed phy driver, exporting a fixed_phy_change_carrier
>function which can be assigned to the .ndo.
>
I agree with Andrew on this. This code is not device (eTSEC) specific, it is generic
and only uses the gianfar driver to get a reference to its net_device.
Thanks,
Claudiu
Powered by blists - more mailing lists