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] [thread-next>] [day] [month] [year] [list]
Date:   Mon, 5 Apr 2021 13:03:46 +0200
From:   Johan Jonker <jbx6244@...il.com>
To:     Tianling Shen <cnsztl@...il.com>, Rob Herring <robh+dt@...nel.org>,
        Heiko Stuebner <heiko@...ech.de>,
        David Bauer <mail@...id-bauer.net>,
        Robin Murphy <robin.murphy@....com>,
        Chen-Yu Tsai <wens@...nel.org>
Cc:     devicetree@...r.kernel.org, linux-arm-kernel@...ts.infradead.org,
        linux-rockchip@...ts.infradead.org, linux-kernel@...r.kernel.org
Subject: Re: [PATCH v2] rockchip: enabled LAN port on NanoPi R2S

Hi Tianling,

On 4/5/21 11:34 AM, Tianling Shen wrote:
> From: David Bauer <mail@...id-bauer.net>
> 
> Enable the USB3 port on the FriendlyARM NanoPi R2S.
> This is required for the USB3 attached LAN port to work.
> 
> Signed-off-by: David Bauer <mail@...id-bauer.net>
> [added device node for USB Ethernet controller]
> Signed-off-by: Tianling Shen <cnsztl@...il.com>
> ---
>  .../boot/dts/rockchip/rk3328-nanopi-r2s.dts   | 32 +++++++++++++++++++
>  1 file changed, 32 insertions(+)
> 
> diff --git a/arch/arm64/boot/dts/rockchip/rk3328-nanopi-r2s.dts b/arch/arm64/boot/dts/rockchip/rk3328-nanopi-r2s.dts
> index faf496d789cf..18936b393d9d 100644
> --- a/arch/arm64/boot/dts/rockchip/rk3328-nanopi-r2s.dts
> +++ b/arch/arm64/boot/dts/rockchip/rk3328-nanopi-r2s.dts
> @@ -13,6 +13,10 @@
>  	model = "FriendlyElec NanoPi R2S";
>  	compatible = "friendlyarm,nanopi-r2s", "rockchip,rk3328";
>  
> +	aliases {
> +		ethernet1 = &r8153;
> +	};
> +
>  	chosen {
>  		stdout-path = "serial2:1500000n8";
>  	};
> @@ -37,6 +41,16 @@
>  		};
>  	};
>  

> +	vcc_rtl8153: vcc-rtl8153-regulator {

sort nodename

> +		compatible = "regulator-fixed";
> +		gpio = <&gpio2 RK_PC6 GPIO_ACTIVE_HIGH>;
> +		pinctrl-names = "default";
> +		pinctrl-0 = <&rtl8153_en_drv>;
> +		regulator-always-on;

> +		regulator-name = "vcc_rtl8153";

exception to the sort rule
sort regulator-name above all other regulator properties

> +		enable-active-high;

sort

----
Heiko's sort rules:

compatible
reg
interrupts
[alphabetical]
status [if needed]

----

> +	};
> +
>  	leds {
>  		compatible = "gpio-leds";
>  		pinctrl-0 = <&lan_led_pin>,  <&sys_led_pin>, <&wan_led_pin>;
> @@ -265,6 +279,12 @@
>  			};
>  		};
>  	};
> +
> +	usb {
> +		rtl8153_en_drv: rtl8153-en-drv {
> +			rockchip,pins = <2 RK_PC6 RK_FUNC_GPIO &pcfg_pull_none>;
> +		};
> +	};
>  };
>  
>  &io_domains {
> @@ -364,6 +384,18 @@
>  	dr_mode = "host";
>  };
>  
> +&usbdrd3 {
> +	dr_mode = "host";
> +	status = "okay";
> +

> +	r8153: usb-eth@2 {

With YAML undocumented additional properties and nodes generate
notifications.
We need a change in the documents below for that.
rockchip,dwc3.yaml > usb-drd.yaml > usb.yaml

Is there a standard for the usb-eth nodename?

> +		compatible = "realtek,rtl8153";

Since a while Rob has improved has scripts.
There's no escape anymore.
Add a YAML document to this serie for "realtek,rtl8153".

Improve checking for undocumented compatible strings
https://github.com/devicetree-org/dt-schema/commit/93e7ada8d53af099074cb5d53f7caa12835784e0

> +		reg = <2>;

Why 2 ?

> +

> +		local-mac-address = [ 00 00 00 00 00 00 ]; /* Filled in by U-Boot */

This is a private property.
In a generic dts that's up to the user.

> +	};
> +};
> +
>  &usb_host0_ehci {
>  	status = "okay";
>  };
> 

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ