lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Date:   Wed, 2 Jun 2021 03:14:43 +0000
From:   Joakim Zhang <qiangqing.zhang@....com>
To:     Andrew Lunn <andrew@...n.ch>
CC:     "davem@...emloft.net" <davem@...emloft.net>,
        "kuba@...nel.org" <kuba@...nel.org>,
        "robh+dt@...nel.org" <robh+dt@...nel.org>,
        "hkallweit1@...il.com" <hkallweit1@...il.com>,
        "linux@...linux.org.uk" <linux@...linux.org.uk>,
        "f.fainelli@...il.com" <f.fainelli@...il.com>,
        dl-linux-imx <linux-imx@....com>,
        "netdev@...r.kernel.org" <netdev@...r.kernel.org>,
        "devicetree@...r.kernel.org" <devicetree@...r.kernel.org>,
        "linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>
Subject: RE: [PATCH net-next 1/4] dt-bindings: net: add dt binding for realtek
 rtl82xx phy


Hi Andrew,

> -----Original Message-----
> From: Andrew Lunn <andrew@...n.ch>
> Sent: 2021年6月2日 10:39
> To: Joakim Zhang <qiangqing.zhang@....com>
> Cc: davem@...emloft.net; kuba@...nel.org; robh+dt@...nel.org;
> hkallweit1@...il.com; linux@...linux.org.uk; f.fainelli@...il.com;
> dl-linux-imx <linux-imx@....com>; netdev@...r.kernel.org;
> devicetree@...r.kernel.org; linux-kernel@...r.kernel.org
> Subject: Re: [PATCH net-next 1/4] dt-bindings: net: add dt binding for realtek
> rtl82xx phy
> 
> > +properties:
> > +  rtl821x,clkout-disable:
> > +    description: Disable CLKOUT clock.
> > +    type: boolean
> > +
> > +  rtl821x,aldps-disable:
> > +    description: Disable ALDPS mode.
> > +    type: boolean
> 
> I think most of the problems are the ambiguity in the binding.
> 
> If rtl821x,clkout-disable is not present, should it enable the CLKOUT?
> That needs clear define here.
No, don't need to, CLKOUT clock default is enabled after PHY hardware reset. Add this property for users
request to disable this clock output. I will improve the description.

> Do we actually want a tristate here?
> 
>                 rtl821x,clkout = <true>;
> 
> means ensure the clock is outputting.
> 
>                 rtl821x,clkout = <false>;
> 
> means ensure the clock is not outputting.
I think it's unnecessary. A boolean type here is enough.

> And if the property is not in DT at all, leave the hardware alone, at either its
> default value, or whatever came before has set it to?
Seems not.
1. If enable CLKOUT in boot loader or keep the hardware default value (CLKOUT enabled), DT would work with this patch.
2. If disable CLKOUT in boot loader, with this patch, driver would enable this clock if this property is not in DT.

So, I need first read PHYCR2 register, if DT has property then disable the clock, if not, keep the original value?

However, for ALDPS mode, the hardware default value is disabled. The driver enable ALDPS by default which caused issue at my side. So need a property to disable it. 

We had better add a property like " rtl821x,aldps-enable", but It seems break the existing behavior.

Best Regards,
Joakim Zhang
>     Andrew

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ