diff mbox series

[v2,10/15] rng: rockchip: Use same compatible as linux

Message ID 20240217002304.2141064-11-jonas@kwiboo.se
State Accepted
Commit 1bc79dce57af1ea5b56d0ea465c3bc596f7a6be1
Delegated to: Kever Yang
Headers show
Series rockchip: rk3328: Update defconfigs, DTs and enable boot from SPI | expand

Commit Message

Jonas Karlman Feb. 17, 2024, 12:22 a.m. UTC
Replace the rockchip,cryptov1-rng compatible with compatibles used in
the linux device tree for RK3288, RK3328 and RK3399 to ease sync of SoC
device tree from linux.

Signed-off-by: Jonas Karlman <jonas@kwiboo.se>
Reviewed-by: Heinrich Schuchardt <xypron.glpk@gmx.de>
---
v2:
- No change
- Collect r-b tag
---
 arch/arm/dts/rk3328-u-boot.dtsi |  2 +-
 arch/arm/dts/rk3399-u-boot.dtsi |  2 +-
 drivers/rng/rockchip_rng.c      | 10 +++++++++-
 3 files changed, 11 insertions(+), 3 deletions(-)

Comments

Kever Yang March 14, 2024, 3:33 a.m. UTC | #1
On 2024/2/17 08:22, Jonas Karlman wrote:
> Replace the rockchip,cryptov1-rng compatible with compatibles used in
> the linux device tree for RK3288, RK3328 and RK3399 to ease sync of SoC
> device tree from linux.
>
> Signed-off-by: Jonas Karlman <jonas@kwiboo.se>
> Reviewed-by: Heinrich Schuchardt <xypron.glpk@gmx.de>
Reviewed-by: Kever Yang <kever.yang@rock-chips.com>

Thanks,
- Kever
> ---
> v2:
> - No change
> - Collect r-b tag
> ---
>   arch/arm/dts/rk3328-u-boot.dtsi |  2 +-
>   arch/arm/dts/rk3399-u-boot.dtsi |  2 +-
>   drivers/rng/rockchip_rng.c      | 10 +++++++++-
>   3 files changed, 11 insertions(+), 3 deletions(-)
>
> diff --git a/arch/arm/dts/rk3328-u-boot.dtsi b/arch/arm/dts/rk3328-u-boot.dtsi
> index 687c16da5135..ea34bf6b78bb 100644
> --- a/arch/arm/dts/rk3328-u-boot.dtsi
> +++ b/arch/arm/dts/rk3328-u-boot.dtsi
> @@ -28,7 +28,7 @@
>   	};
>   
>   	rng: rng@ff060000 {
> -		compatible = "rockchip,cryptov1-rng";
> +		compatible = "rockchip,rk3328-crypto";
>   		reg = <0x0 0xff060000 0x0 0x4000>;
>   		status = "okay";
>   	};
> diff --git a/arch/arm/dts/rk3399-u-boot.dtsi b/arch/arm/dts/rk3399-u-boot.dtsi
> index 3423b882c437..87b173e59579 100644
> --- a/arch/arm/dts/rk3399-u-boot.dtsi
> +++ b/arch/arm/dts/rk3399-u-boot.dtsi
> @@ -30,7 +30,7 @@
>   	};
>   
>   	rng: rng@ff8b8000 {
> -		compatible = "rockchip,cryptov1-rng";
> +		compatible = "rockchip,rk3399-crypto";
>   		reg = <0x0 0xff8b8000 0x0 0x1000>;
>   		status = "okay";
>   	};
> diff --git a/drivers/rng/rockchip_rng.c b/drivers/rng/rockchip_rng.c
> index 705b424cf3dd..e82b5572fec5 100644
> --- a/drivers/rng/rockchip_rng.c
> +++ b/drivers/rng/rockchip_rng.c
> @@ -302,7 +302,15 @@ static const struct dm_rng_ops rockchip_rng_ops = {
>   
>   static const struct udevice_id rockchip_rng_match[] = {
>   	{
> -		.compatible = "rockchip,cryptov1-rng",
> +		.compatible = "rockchip,rk3288-crypto",
> +		.data = (ulong)&rk_cryptov1_soc_data,
> +	},
> +	{
> +		.compatible = "rockchip,rk3328-crypto",
> +		.data = (ulong)&rk_cryptov1_soc_data,
> +	},
> +	{
> +		.compatible = "rockchip,rk3399-crypto",
>   		.data = (ulong)&rk_cryptov1_soc_data,
>   	},
>   	{
diff mbox series

Patch

diff --git a/arch/arm/dts/rk3328-u-boot.dtsi b/arch/arm/dts/rk3328-u-boot.dtsi
index 687c16da5135..ea34bf6b78bb 100644
--- a/arch/arm/dts/rk3328-u-boot.dtsi
+++ b/arch/arm/dts/rk3328-u-boot.dtsi
@@ -28,7 +28,7 @@ 
 	};
 
 	rng: rng@ff060000 {
-		compatible = "rockchip,cryptov1-rng";
+		compatible = "rockchip,rk3328-crypto";
 		reg = <0x0 0xff060000 0x0 0x4000>;
 		status = "okay";
 	};
diff --git a/arch/arm/dts/rk3399-u-boot.dtsi b/arch/arm/dts/rk3399-u-boot.dtsi
index 3423b882c437..87b173e59579 100644
--- a/arch/arm/dts/rk3399-u-boot.dtsi
+++ b/arch/arm/dts/rk3399-u-boot.dtsi
@@ -30,7 +30,7 @@ 
 	};
 
 	rng: rng@ff8b8000 {
-		compatible = "rockchip,cryptov1-rng";
+		compatible = "rockchip,rk3399-crypto";
 		reg = <0x0 0xff8b8000 0x0 0x1000>;
 		status = "okay";
 	};
diff --git a/drivers/rng/rockchip_rng.c b/drivers/rng/rockchip_rng.c
index 705b424cf3dd..e82b5572fec5 100644
--- a/drivers/rng/rockchip_rng.c
+++ b/drivers/rng/rockchip_rng.c
@@ -302,7 +302,15 @@  static const struct dm_rng_ops rockchip_rng_ops = {
 
 static const struct udevice_id rockchip_rng_match[] = {
 	{
-		.compatible = "rockchip,cryptov1-rng",
+		.compatible = "rockchip,rk3288-crypto",
+		.data = (ulong)&rk_cryptov1_soc_data,
+	},
+	{
+		.compatible = "rockchip,rk3328-crypto",
+		.data = (ulong)&rk_cryptov1_soc_data,
+	},
+	{
+		.compatible = "rockchip,rk3399-crypto",
 		.data = (ulong)&rk_cryptov1_soc_data,
 	},
 	{