diff options
author | Álvaro Fernández Rojas <noltari@gmail.com> | 2020-03-16 20:41:03 +0100 |
---|---|---|
committer | Álvaro Fernández Rojas <noltari@gmail.com> | 2020-03-16 21:24:23 +0100 |
commit | 0f6d04457a64f2393b05f662dc8d381ea1963c66 (patch) | |
tree | 2d6a3c82d5e6d02b030b16df66da8bf9209b02ec /target/linux/bcm27xx/patches-5.4/950-0429-hwrng-iproc-rng200-Correct-SoC-name.patch | |
parent | d890f85e59617228b1e76e8cf45a9309904d9124 (diff) | |
download | upstream-0f6d04457a64f2393b05f662dc8d381ea1963c66.tar.gz upstream-0f6d04457a64f2393b05f662dc8d381ea1963c66.tar.bz2 upstream-0f6d04457a64f2393b05f662dc8d381ea1963c66.zip |
bcm27xx: sync 5.4 patches with RPi Foundation
Signed-off-by: Álvaro Fernández Rojas <noltari@gmail.com>
Diffstat (limited to 'target/linux/bcm27xx/patches-5.4/950-0429-hwrng-iproc-rng200-Correct-SoC-name.patch')
-rw-r--r-- | target/linux/bcm27xx/patches-5.4/950-0429-hwrng-iproc-rng200-Correct-SoC-name.patch | 67 |
1 files changed, 67 insertions, 0 deletions
diff --git a/target/linux/bcm27xx/patches-5.4/950-0429-hwrng-iproc-rng200-Correct-SoC-name.patch b/target/linux/bcm27xx/patches-5.4/950-0429-hwrng-iproc-rng200-Correct-SoC-name.patch new file mode 100644 index 0000000000..f4e93308b1 --- /dev/null +++ b/target/linux/bcm27xx/patches-5.4/950-0429-hwrng-iproc-rng200-Correct-SoC-name.patch @@ -0,0 +1,67 @@ +From 5eafa5065b2ea2c8d1634f045b85b982393d808a Mon Sep 17 00:00:00 2001 +From: Phil Elwell <phil@raspberrypi.com> +Date: Fri, 31 Jan 2020 09:36:57 +0000 +Subject: [PATCH] hwrng: iproc-rng200: Correct SoC name + +The Pi 4 SoC is called BCM2711, not BCM2838. + +Fixes: "hwrng: iproc-rng200: Add BCM2838 support" + +Signed-off-by: Phil Elwell <phil@raspberrypi.com> +--- + drivers/char/hw_random/Kconfig | 2 +- + drivers/char/hw_random/iproc-rng200.c | 11 +++++------ + 2 files changed, 6 insertions(+), 7 deletions(-) + +--- a/drivers/char/hw_random/Kconfig ++++ b/drivers/char/hw_random/Kconfig +@@ -94,7 +94,7 @@ config HW_RANDOM_IPROC_RNG200 + default HW_RANDOM + ---help--- + This driver provides kernel-side support for the RNG200 +- hardware found on the Broadcom iProc, BCM2838 and STB SoCs. ++ hardware found on the Broadcom iProc, BCM2711 and STB SoCs. + + To compile this driver as a module, choose M here: the + module will be called iproc-rng200 +--- a/drivers/char/hw_random/iproc-rng200.c ++++ b/drivers/char/hw_random/iproc-rng200.c +@@ -174,7 +174,7 @@ static int iproc_rng200_init(struct hwrn + return 0; + } + +-static int bcm2838_rng200_read(struct hwrng *rng, void *buf, size_t max, ++static int bcm2711_rng200_read(struct hwrng *rng, void *buf, size_t max, + bool wait) + { + struct iproc_rng200_dev *priv = to_rng_priv(rng); +@@ -211,7 +211,7 @@ static int bcm2838_rng200_read(struct hw + return num_words * sizeof(u32); + } + +-static int bcm2838_rng200_init(struct hwrng *rng) ++static int bcm2711_rng200_init(struct hwrng *rng) + { + struct iproc_rng200_dev *priv = to_rng_priv(rng); + uint32_t val; +@@ -271,9 +271,9 @@ static int iproc_rng200_probe(struct pla + priv->rng.name = pdev->name; + priv->rng.cleanup = iproc_rng200_cleanup; + +- if (of_device_is_compatible(dev->of_node, "brcm,bcm2838-rng200")) { +- priv->rng.init = bcm2838_rng200_init; +- priv->rng.read = bcm2838_rng200_read; ++ if (of_device_is_compatible(dev->of_node, "brcm,bcm2711-rng200")) { ++ priv->rng.init = bcm2711_rng200_init; ++ priv->rng.read = bcm2711_rng200_read; + } else { + priv->rng.init = iproc_rng200_init; + priv->rng.read = iproc_rng200_read; +@@ -296,7 +296,6 @@ static const struct of_device_id iproc_r + { .compatible = "brcm,bcm7211-rng200", }, + { .compatible = "brcm,bcm7278-rng200", }, + { .compatible = "brcm,iproc-rng200", }, +- { .compatible = "brcm,bcm2838-rng200"}, + {}, + }; + MODULE_DEVICE_TABLE(of, iproc_rng200_of_match); |