mbox series

[0/3] Pine64+ specific hacks for RTL8211E Ethernet PHY

Message ID 20191001082912.12905-1-icenowy@aosc.io
Headers show
Series Pine64+ specific hacks for RTL8211E Ethernet PHY | expand

Message

Icenowy Zheng Oct. 1, 2019, 8:29 a.m. UTC
There're some Pine64+ boards known to have broken RTL8211E chips, and
a hack is given by Pine64+, which is said to be from Realtek.

This patchset adds the hack.

The hack is taken from U-Boot, and it contains magic numbers without
any document.

Icenowy Zheng (3):
  dt-bindings: add binding for RTL8211E Ethernet PHY
  net: phy: realtek: add config hack for broken RTL8211E on Pine64+
    boards
  arm64: allwinner: a64: dts: apply hack for RTL8211E on Pine64+

 .../bindings/net/realtek,rtl8211e.yaml        | 23 +++++++++++++++++++
 .../dts/allwinner/sun50i-a64-pine64-plus.dts  |  1 +
 drivers/net/phy/realtek.c                     | 14 +++++++++++
 3 files changed, 38 insertions(+)
 create mode 100644 Documentation/devicetree/bindings/net/realtek,rtl8211e.yaml

Comments

David Miller Oct. 1, 2019, 4:06 p.m. UTC | #1
From: Icenowy Zheng <icenowy@aosc.io>
Date: Tue,  1 Oct 2019 16:29:09 +0800

> There're some Pine64+ boards known to have broken RTL8211E chips, and
> a hack is given by Pine64+, which is said to be from Realtek.
> 
> This patchset adds the hack.
> 
> The hack is taken from U-Boot, and it contains magic numbers without
> any document.

Please contact Realtek and try to get an explanation about this.

I understand that eventually we may not get a proper explanation
but I really want you to put forth real effort to nail down whats
going on here before I even consider these patches seriously.

Thank you.
Icenowy Zheng Oct. 1, 2019, 4:08 p.m. UTC | #2
于 2019年10月2日 GMT+08:00 上午12:06:51, David Miller <davem@davemloft.net> 写到:
>From: Icenowy Zheng <icenowy@aosc.io>
>Date: Tue,  1 Oct 2019 16:29:09 +0800
>
>> There're some Pine64+ boards known to have broken RTL8211E chips, and
>> a hack is given by Pine64+, which is said to be from Realtek.
>> 
>> This patchset adds the hack.
>> 
>> The hack is taken from U-Boot, and it contains magic numbers without
>> any document.
>
>Please contact Realtek and try to get an explanation about this.

Sorry, but Realtek never shows any idea to add more infomation about this.

These hacks had existed and worked for years.

>
>I understand that eventually we may not get a proper explanation
>but I really want you to put forth real effort to nail down whats
>going on here before I even consider these patches seriously.
>
>Thank you.
>
>_______________________________________________
>linux-arm-kernel mailing list
>linux-arm-kernel@lists.infradead.org
>http://lists.infradead.org/mailman/listinfo/linux-arm-kernel
David Miller Oct. 1, 2019, 4:30 p.m. UTC | #3
From: Icenowy Zheng <icenowy@aosc.io>
Date: Wed, 02 Oct 2019 00:08:39 +0800

> 
> 
> 于 2019年10月2日 GMT+08:00 上午12:06:51, David Miller <davem@davemloft.net> 写到:
>>From: Icenowy Zheng <icenowy@aosc.io>
>>Date: Tue,  1 Oct 2019 16:29:09 +0800
>>
>>> There're some Pine64+ boards known to have broken RTL8211E chips, and
>>> a hack is given by Pine64+, which is said to be from Realtek.
>>> 
>>> This patchset adds the hack.
>>> 
>>> The hack is taken from U-Boot, and it contains magic numbers without
>>> any document.
>>
>>Please contact Realtek and try to get an explanation about this.
> 
> Sorry, but Realtek never shows any idea to add more infomation about this.
> 
> These hacks had existed and worked for years.

Have you actually tried to communicate with an appropriate contact yourself?

If not, I am asking you to do so.
Icenowy Zheng Oct. 1, 2019, 4:31 p.m. UTC | #4
于 2019年10月2日 GMT+08:00 上午12:30:00, David Miller <davem@davemloft.net> 写到:
>From: Icenowy Zheng <icenowy@aosc.io>
>Date: Wed, 02 Oct 2019 00:08:39 +0800
>
>> 
>> 
>> 于 2019年10月2日 GMT+08:00 上午12:06:51, David Miller <davem@davemloft.net>
>写到:
>>>From: Icenowy Zheng <icenowy@aosc.io>
>>>Date: Tue,  1 Oct 2019 16:29:09 +0800
>>>
>>>> There're some Pine64+ boards known to have broken RTL8211E chips,
>and
>>>> a hack is given by Pine64+, which is said to be from Realtek.
>>>> 
>>>> This patchset adds the hack.
>>>> 
>>>> The hack is taken from U-Boot, and it contains magic numbers
>without
>>>> any document.
>>>
>>>Please contact Realtek and try to get an explanation about this.
>> 
>> Sorry, but Realtek never shows any idea to add more infomation about
>this.
>> 
>> These hacks had existed and worked for years.
>
>Have you actually tried to communicate with an appropriate contact
>yourself?
>
>If not, I am asking you to do so.

I have tried to ask via TL Lim from Pine64, because I have no way
to communicate directly to Realtek. However TL cannot get anything
more from Realtek.

>
>_______________________________________________
>linux-arm-kernel mailing list
>linux-arm-kernel@lists.infradead.org
>http://lists.infradead.org/mailman/listinfo/linux-arm-kernel
David Miller Oct. 1, 2019, 4:41 p.m. UTC | #5
From: Icenowy Zheng <icenowy@aosc.io>
Date: Wed, 02 Oct 2019 00:31:25 +0800

> I have tried to ask via TL Lim from Pine64, because I have no way
> to communicate directly to Realtek. However TL cannot get anything
> more from Realtek.

We have several Realtek developers who post here as part of maintaining
the upstream copy of their drivers, and upstream developers of other
Realtek parts who sometimes interact with Realtek.

Be creative and work with these people to try to get to the right
people.

Please stop making excuses and do the right thing.

Thank you.
Florian Fainelli Oct. 1, 2019, 4:47 p.m. UTC | #6
On 10/1/19 1:29 AM, Icenowy Zheng wrote:
> There're some Pine64+ boards known to have broken RTL8211E chips, and
> a hack is given by Pine64+, which is said to be from Realtek.
> 
> This patchset adds the hack.
> 
> The hack is taken from U-Boot, and it contains magic numbers without
> any document.

Such hacks are the very reason why PHY fixups exists, please investigate
working with Realtek first to understand how to make this hack less of a
hack so it is understood what it does and you can either add proper
infrastructure to the realtek PHY driver to perform that hack, or if
that is not an option, register a board specific fixup.

> 
> Icenowy Zheng (3):
>   dt-bindings: add binding for RTL8211E Ethernet PHY
>   net: phy: realtek: add config hack for broken RTL8211E on Pine64+
>     boards
>   arm64: allwinner: a64: dts: apply hack for RTL8211E on Pine64+
> 
>  .../bindings/net/realtek,rtl8211e.yaml        | 23 +++++++++++++++++++
>  .../dts/allwinner/sun50i-a64-pine64-plus.dts  |  1 +
>  drivers/net/phy/realtek.c                     | 14 +++++++++++
>  3 files changed, 38 insertions(+)
>  create mode 100644 Documentation/devicetree/bindings/net/realtek,rtl8211e.yaml
>
Andrew Lunn Oct. 1, 2019, 4:52 p.m. UTC | #7
On Tue, Oct 01, 2019 at 09:47:08AM -0700, Florian Fainelli wrote:
> On 10/1/19 1:29 AM, Icenowy Zheng wrote:
> > There're some Pine64+ boards known to have broken RTL8211E chips, and
> > a hack is given by Pine64+, which is said to be from Realtek.
> > 
> > This patchset adds the hack.
> > 
> > The hack is taken from U-Boot, and it contains magic numbers without
> > any document.
> 
> Such hacks are the very reason why PHY fixups exists, please investigate
> working with Realtek first to understand how to make this hack less of a
> hack so it is understood what it does and you can either add proper
> infrastructure to the realtek PHY driver to perform that hack, or if
> that is not an option, register a board specific fixup.

Hi Icenowy

It would also be nice to know if only Pine64 has these bad PHYs, or if
they were in the general distribution chain and other boards might
have them as well.

     Andrew