crypto: Add driver for JZ4780 PRNG
Subsystems (4)
v2 cover crypto: Add driver for JZ4780 PRNG
This patch series adds support of pseudo random number generator found in Ingenic's JZ4780 and X1000 SoC.
Based on Paul's review comments, add 'syscon' compatible in CGU node in jz4780.dtsi. jz4780-rng driver uses regmap exposed via syscon interface to access the RNG registers. CGU driver is not modified in this patch set as registers used by CGU driver and this driver are different.
PrasannaKumar Muralidharan (4):
crypto: jz4780-rng: Add JZ4780 PRNG devicetree binding documentation
crypto: jz4780-rng: Add Ingenic JZ4780 hardware PRNG driver
crypto: jz4780-rng: Add RNG node to jz4780.dtsi
crypto: jz4780-rng: Enable PRNG support in CI20 defconfig
.../bindings/crypto/ingenic,jz4780-rng.txt | 20 +++ MAINTAINERS | 5 + arch/mips/boot/dts/ingenic/jz4780.dtsi | 6 +- arch/mips/configs/ci20_defconfig | 5 + drivers/crypto/Kconfig | 19 +++ drivers/crypto/Makefile | 1 + drivers/crypto/jz4780-rng.c | 168 +++++++++++++++++++++ 7 files changed, 223 insertions(+), 1 deletion(-) create mode 100644 Documentation/devicetree/bindings/crypto/ingenic,jz4780-rng.txt create mode 100644 drivers/crypto/jz4780-rng.c
Signature · 1 line
2.10.0
PATCH v2 1/4 crypto: jz4780-rng: Add JZ4780 PRNG devicetree binding documentation
Add devicetree bindings for hardware pseudo random number generator present in Ingenic JZ4780 SoC.
---
Changes in v2:
* Add "syscon" in CGU node's compatible section
* Make RNG child node of CGU.
.../bindings/crypto/ingenic,jz4780-rng.txt | 20 ++++++++++++++++++++ 1 file changed, 20 insertions(+) create mode 100644 Documentation/devicetree/bindings/crypto/ingenic,jz4780-rng.txt
Documentation/devicetree/bindings/crypto/ingenic,jz4780-rng.txt new file +20 -0
@@ -0,0 +1,20 @@ +Ingenic jz4780 RNG driver + +Required properties: +- compatible : Should be "ingenic,jz4780-rng" + +Example: + +cgu: jz4780-cgu@10000000 { + compatible = "ingenic,jz4780-cgu", "syscon"; + reg = <0x10000000 0x100>; + + clocks = <&ext>, <&rtc>; + clock-names = "ext", "rtc"; + + #clock-cells = <1>; + + rng: rng@d8 { + compatible = "ingenic,jz480-rng"; + }; +};
Signature · 1 line
2.10.0
Rob Herring
maintainerRe: [PATCH v2 1/4] crypto: jz4780-rng: Add JZ4780 PRNG devicetree binding documentation
Quoted 10 lines · PrasannaKumar Muralidharan
Add devicetree bindings for hardware pseudo random number generator present in Ingenic JZ4780 SoC.
Signed-off-by PrasannaKumar Muralidharan <[email protected]>---
Changes in v2:
* Add "syscon" in CGU node's compatible section
* Make RNG child node of CGU..../bindings/crypto/ingenic,jz4780-rng.txt | 20 ++++++++++++++++++++
bindings/rng/ for RNG h/w.
Quoted 16 lines
1 file changed, 20 insertions(+) create mode 100644 Documentation/devicetree/bindings/crypto/ingenic,jz4780-rng.txtDocumentation/devicetree/bindings/crypto/ingenic,jz4780-rng.txt new file +7
-0@@ -0,0 +1,20 @@ +Ingenic jz4780 RNG driver + +Required properties: +- compatible : Should be "ingenic,jz4780-rng" + +Example: +
Documentation/devicetree/bindings/crypto/ingenic,jz4780-rng.txt line 17
Quoted 10 lines
Documentation/devicetree/bindings/crypto/ingenic,jz4780-rng.txt new file +10
-0+cgu: jz4780-cgu@10000000 { + compatible = "ingenic,jz4780-cgu", "syscon"; + reg = <0x10000000 0x100>; + + clocks = <&ext>, <&rtc>; + clock-names = "ext", "rtc"; + + #clock-cells = <1>; + + rng: rng@d8 {
unit-address requires reg property.
Quoted 6 lines
Documentation/devicetree/bindings/crypto/ingenic,jz4780-rng.txt new file +3
-0+ compatible = "ingenic,jz480-rng"; + }; +};Signature · 1 line
2.10.0
Re: [PATCH v2 1/4] crypto: jz4780-rng: Add JZ4780 PRNG devicetree binding documentation
Hi Rob,
Quoted 10 lines · Rob Herring
Quoted 9 lines · PrasannaKumar Muralidharan
Add devicetree bindings for hardware pseudo random number generator present in Ingenic JZ4780 SoC.
Signed-off-by PrasannaKumar Muralidharan <[email protected]>---
Changes in v2:
* Add "syscon" in CGU node's compatible section
* Make RNG child node of CGU.
Quoted 3 lines
Quoted 1 line
.../bindings/crypto/ingenic,jz4780-rng.txt | 20 ++++++++++++++++++++bindings/rng/ for RNG h/w.
There are two subsystem for dealing with RNG hw. Hw_random subsystem for true RNG (driver/char/hw_random) and crypto framework for pseudo RNG (crypto/ and drviers/crypto). This HW is pseudo RNG so I have placed the dt bindings in bindings/crypto as the driver itself is in drivers/crypto folder. I am wondering if there is any relation between driver folder and bindings folder. Can you please explain the folder relation? Should this be put in bindings/rng or bindings/crypto?
Quoted 21 lines
Quoted 21 lines
1 file changed, 20 insertions(+) create mode 100644 Documentation/devicetree/bindings/crypto/ingenic,jz4780-rng.txtDocumentation/devicetree/bindings/crypto/ingenic,jz4780-rng.txt new file +11
-0@@ -0,0 +1,20 @@ +Ingenic jz4780 RNG driver + +Required properties: +- compatible : Should be "ingenic,jz4780-rng" + +Example: + +cgu: jz4780-cgu@10000000 { + compatible = "ingenic,jz4780-cgu", "syscon"; + reg = <0x10000000 0x100>; +
Quoted 8 lines
Documentation/devicetree/bindings/crypto/ingenic,jz4780-rng.txt line 17
Quoted 6 lines
Documentation/devicetree/bindings/crypto/ingenic,jz4780-rng.txt new file +6
-0+ clocks = <&ext>, <&rtc>; + clock-names = "ext", "rtc"; + + #clock-cells = <1>; + + rng: rng@d8 {unit-address requires reg property.
The driver uses regmap to access the registers. In this case reg property is not useful. Is reg property still needed? If not, how should the node be declared?
Quoted 7 lines
Quoted 7 lines
Documentation/devicetree/bindings/crypto/ingenic,jz4780-rng.txt new file +3
-1+ compatible = "ingenic,jz480-rng"; + }; +}; --2.10.0
Thanks,
PrasannaKumar
A message that is not in the archive (sent off-list or not yet received): CANc+2y7pD7EkSS-9ky4YDxGjk3wGW1PVZje2UXMRuOQJA=S+HA-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org
Re: [PATCH v2 1/4] crypto: jz4780-rng: Add JZ4780 PRNG devicetree binding documentation
Quoted 17 lines · PrasannaKumar Muralidharan
Hi Rob,
Quoted 10 lines · Rob Herring
Quoted 9 lines · PrasannaKumar Muralidharan
Add devicetree bindings for hardware pseudo random number generator present in Ingenic JZ4780 SoC.
Signed-off-by PrasannaKumar Muralidharan <[email protected]>---
Changes in v2:
* Add "syscon" in CGU node's compatible section
* Make RNG child node of CGU.Quoted 3 lines
Quoted 1 line
.../bindings/crypto/ingenic,jz4780-rng.txt | 20 ++++++++++++++++++++bindings/rng/ for RNG h/w.
Quoted 7 lines
There are two subsystem for dealing with RNG hw.
Hw_randomsubsystem for true RNG (driver/char/hw_random) and crypto framework for pseudo RNG (crypto/and drviers/crypto). This HW is pseudo RNG so I have placed the dt bindings in bindings/crypto as the driver itself is indrivers/cryptofolder. I am wondering if there is any relation between driver folder and bindings folder. Can you please explain the folder relation? Should this be put in bindings/rng or bindings/crypto?
There's not a 1-1 relationship though obviously there's a lot of overlap. I'd still say this should go in bindings/rng.
Quoted 29 lines
Quoted 20 lines
Quoted 20 lines
1 file changed, 20 insertions(+) create mode 100644 Documentation/devicetree/bindings/crypto/ingenic,jz4780-rng.txtDocumentation/devicetree/bindings/crypto/ingenic,jz4780-rng.txt new file +11
-0@@ -0,0 +1,20 @@ +Ingenic jz4780 RNG driver + +Required properties: +- compatible : Should be "ingenic,jz4780-rng" + +Example: + +cgu: jz4780-cgu@10000000 { + compatible = "ingenic,jz4780-cgu", "syscon"; + reg = <0x10000000 0x100>; +Quoted 8 lines
Documentation/devicetree/bindings/crypto/ingenic,jz4780-rng.txt line 17
Quoted 6 lines
Documentation/devicetree/bindings/crypto/ingenic,jz4780-rng.txt new file +6
-0+ clocks = <&ext>, <&rtc>; + clock-names = "ext", "rtc"; + + #clock-cells = <1>; + + rng: rng@d8 {unit-address requires reg property.
Quoted 3 lines
The driver uses regmap to access the registers. In this case reg property is not useful. Is reg property still needed? If not, how should the node be declared?
What the driver (currently) does is irrelevant to the binding. Your choice is either add the reg property or name the node just "rng". Either is fine, but better to have more information than less IMO.
Rob
--
To unsubscribe from this list: send the line "unsubscribe devicetree" in the body of a message to [email protected] More majordomo info at http://vger.kernel.org/majordomo-info.html
PATCH v2 2/4 crypto: jz4780-rng: Add Ingenic JZ4780 hardware PRNG driver
In reply to PrasannaKumar MuralidharanJZ4780 SoC pseudo random number generator driver using crypto framework.
Adding a delay before reading RNG data and disabling RNG after reading data was suggested by Jeffery Walton.
---
Changes in v2:
* Fixed buffer overflow in generate function pointed out in Stephan's review
* Fold patch that had only MAINTAINERS file change with this patch
* Removed unnecessary comment in code
MAINTAINERS | 5 ++ drivers/crypto/Kconfig | 19 +++++ drivers/crypto/Makefile | 1 + drivers/crypto/jz4780-rng.c | 168 ++++++++++++++++++++++++++++++++++++++++++++ 4 files changed, 193 insertions(+) create mode 100644 drivers/crypto/jz4780-rng.c
MAINTAINERS +5 -0
@@ -6672,6 +6672,11 @@ L: [email protected] S: Maintained F: drivers/mtd/nand/jz4780_* +INGENIC JZ4780 PRNG DRIVER +M: PrasannaKumar Muralidharan <[email protected]> +S: Maintained +F: drivers/crypto/jz4780-rng.c + INOTIFY M: John McCutchan <[email protected]> M: Robert Love <[email protected]>
drivers/crypto/Kconfig +19 -0
@@ -599,6 +599,25 @@ config CRYPTO_DEV_IMGTEC_HASH hardware hash accelerator. Supporting MD5/SHA1/SHA224/SHA256 hashing algorithms. +config CRYPTO_DEV_JZ4780_RNG + tristate "JZ4780 HW pseudo random number generator support" + depends on MACH_JZ4780 || COMPILE_TEST + depends on HAS_IOMEM + select CRYPTO_RNG + select REGMAP + select SYSCON + select MFD_SYSCON + ---help--- + This driver provides kernel-side support through the + cryptographic API for the pseudo random number generator + hardware found in ingenic JZ4780 and X1000 SoC. MIPS + Creator CI20 uses JZ4780 SoC. + + To compile this driver as a module, choose M here: the + module will be called jz4780-rng. + + If unsure, say Y. + config CRYPTO_DEV_SUN4I_SS tristate "Support for Allwinner Security System cryptographic accelerator" depends on ARCH_SUNXI && !64BIT
drivers/crypto/Makefile +1 -0
@@ -13,6 +13,7 @@ obj-$(CONFIG_CRYPTO_DEV_GEODE) += geode-aes.o obj-$(CONFIG_CRYPTO_DEV_HIFN_795X) += hifn_795x.o obj-$(CONFIG_CRYPTO_DEV_IMGTEC_HASH) += img-hash.o obj-$(CONFIG_CRYPTO_DEV_IXP4XX) += ixp4xx_crypto.o +obj-$(CONFIG_CRYPTO_DEV_JZ4780_RNG) += jz4780-rng.o obj-$(CONFIG_CRYPTO_DEV_MV_CESA) += mv_cesa.o obj-$(CONFIG_CRYPTO_DEV_MARVELL_CESA) += marvell/ obj-$(CONFIG_CRYPTO_DEV_MEDIATEK) += mediatek/
drivers/crypto/jz4780-rng.c new file +168 -0
168 lines not on this page · raw message
Signature · 1 line
2.10.0
A message that is not in the archive (sent off-list or not yet received): 20170823025707.27888-1-prasannatsmkumar-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org
PATCH v2 3/4 crypto: jz4780-rng: Add RNG node to jz4780.dtsi
Add RNG node to jz4780 dtsi. This driver uses registers that are part of the register set used by Ingenic CGU driver. Make RNG node as child of CGU node.
---
Changes in v2:
* Add "syscon" in CGU node's compatible section
* Make RNG child node of CGU.
arch/mips/boot/dts/ingenic/jz4780.dtsi | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-)
arch/mips/boot/dts/ingenic/jz4780.dtsi +5 -1
@@ -35,13 +35,17 @@ }; cgu: jz4780-cgu@10000000 { - compatible = "ingenic,jz4780-cgu"; + compatible = "ingenic,jz4780-cgu", "syscon"; reg = <0x10000000 0x100>; clocks = <&ext>, <&rtc>; clock-names = "ext", "rtc"; #clock-cells = <1>; + + rng: rng@d8 { + compatible = "ingenic,jz480-rng"; + }; }; pinctrl: pin-controller@10010000 {
Signature · 6 lines
2.10.0 -- To unsubscribe from this list: send the line "unsubscribe devicetree" in the body of a message to [email protected] More majordomo info at http://vger.kernel.org/majordomo-info.html
Re: [PATCH v2 3/4] crypto: jz4780-rng: Add RNG node to jz4780.dtsi
Quoted 11 lines · PrasannaKumar Muralidharan
Add RNG node to jz4780 dtsi. This driver uses registers that are part of the register set used by Ingenic CGU driver. Make RNG node as child of CGU node.
Signed-off-by PrasannaKumar Muralidharan <[email protected]>---
Changes in v2:
* Add "syscon" in CGU node's compatible section
* Make RNG child node of CGU.arch/mips/boot/dts/ingenic/jz4780.dtsi | 6 +++++-
This barely touched arch/mips so probably should be funnelled along with the rest of the series:
Or I can take everything.
Ralf
PATCH v2 4/4 crypto: jz4780-rng: Enable PRNG support in CI20 defconfig
In reply to a message not in the archiveEnable PRNG driver support in MIPS Creator CI20 default config.
---
No changes in v2
arch/mips/configs/ci20_defconfig | 5 +++++ 1 file changed, 5 insertions(+)
arch/mips/configs/ci20_defconfig +5 -0
@@ -88,6 +88,11 @@ CONFIG_SERIAL_8250_RUNTIME_UARTS=5 CONFIG_SERIAL_8250_INGENIC=y CONFIG_SERIAL_OF_PLATFORM=y # CONFIG_HW_RANDOM is not set +CONFIG_CRYPTO_USER=y +CONFIG_CRYPTO_USER_API=y +CONFIG_CRYPTO_USER_API_RNG=y +CONFIG_CRYPTO_HW=y +CONFIG_CRYPTO_DEV_JZ4780_RNG=y CONFIG_I2C=y CONFIG_I2C_JZ4780=y CONFIG_GPIO_SYSFS=y
Signature · 6 lines
2.10.0 -- To unsubscribe from this list: send the line "unsubscribe devicetree" in the body of a message to [email protected] More majordomo info at http://vger.kernel.org/majordomo-info.html
A message that is not in the archive (sent off-list or not yet received): 20170823025707.27888-5-prasannatsmkumar-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org
Re: [PATCH v2 4/4] crypto: jz4780-rng: Enable PRNG support in CI20 defconfig
Hi PrasannaKumar,
Quoted 16 lines · PrasannaKumar Muralidharan
Enable PRNG driver support in MIPS Creator CI20 default config.
Signed-off-by PrasannaKumar Muralidharan <[email protected]>---
No changes in v2arch/mips/configs/ci20_defconfig | 5 +++++ 1 file changed, 5 insertions(+)arch/mips/configs/ci20_defconfig +0
-0@@ -88,6 +88,11 @@ CONFIG_SERIAL_8250_RUNTIME_UARTS=5 CONFIG_SERIAL_8250_INGENIC=y
arch/mips/configs/ci20_defconfig CONFIG_SERIAL_8250_RUNTIME_UARTS=5 · line 98
Quoted 10 lines
arch/mips/configs/ci20_defconfig +5
-0CONFIG_SERIAL_OF_PLATFORM=y # CONFIG_HW_RANDOM is not set +CONFIG_CRYPTO_USER=y +CONFIG_CRYPTO_USER_API=y +CONFIG_CRYPTO_USER_API_RNG=y +CONFIG_CRYPTO_HW=y +CONFIG_CRYPTO_DEV_JZ4780_RNG=y CONFIG_I2C=y CONFIG_I2C_JZ4780=y CONFIG_GPIO_SYSFS=y
You need to regenerate your defconfig as it is missing CONFIG_MFD_SYSCON.
Thanks,
Harvey
--
To unsubscribe from this list: send the line "unsubscribe devicetree" in the body of a message to [email protected] More majordomo info at http://vger.kernel.org/majordomo-info.html
A message that is not in the archive (sent off-list or not yet received): 9da7ab8b-aa81-e012-596c-54355758da83-1AXoQHu6uovQT0dZR+AlfA@public.gmane.org
Re: [PATCH v2 4/4] crypto: jz4780-rng: Enable PRNG support in CI20 defconfig
Hi Harvey,
Quoted 34 lines · Harvey Hunt
Hi PrasannaKumar,
Quoted 18 lines · PrasannaKumar Muralidharan
Enable PRNG driver support in MIPS Creator CI20 default config.
Signed-off-by PrasannaKumar Muralidharan <[email protected]>---
No changes in v2arch/mips/configs/ci20_defconfig | 5 +++++ 1 file changed, 5 insertions(+)arch/mips/configs/ci20_defconfig +0
-0@@ -88,6 +88,11 @@ CONFIG_SERIAL_8250_RUNTIME_UARTS=5 CONFIG_SERIAL_8250_INGENIC=yarch/mips/configs/ci20_defconfig CONFIG_SERIAL_8250_RUNTIME_UARTS=5 · line 98
Quoted 10 lines
arch/mips/configs/ci20_defconfig +5
-0CONFIG_SERIAL_OF_PLATFORM=y # CONFIG_HW_RANDOM is not set +CONFIG_CRYPTO_USER=y +CONFIG_CRYPTO_USER_API=y +CONFIG_CRYPTO_USER_API_RNG=y +CONFIG_CRYPTO_HW=y +CONFIG_CRYPTO_DEV_JZ4780_RNG=y CONFIG_I2C=y CONFIG_I2C_JZ4780=y CONFIG_GPIO_SYSFS=yYou need to regenerate your defconfig as it is missing
CONFIG_MFD_SYSCON.
Quoted 3 lines
Thanks,
Harvey
CONFIG_MFD_SYSCON gets selected when CONFIG_CRYPTO_DEV_JZ4780_RNG is selected. Please see the Kconfig changes. Given that should I add it in ci20_defconfig? If it is required I will add and send a new version.
Thanks,
PrasannaKumar
--
To unsubscribe from this list: send the line "unsubscribe devicetree" in the body of a message to [email protected] More majordomo info at http://vger.kernel.org/majordomo-info.html
Re: [PATCH v2 4/4] crypto: jz4780-rng: Enable PRNG support in CI20 defconfig
Hi PrasannaKumar,
Quoted 37 lines · PrasannaKumar Muralidharan
Hi Harvey,
Quoted 34 lines · Harvey Hunt
Hi PrasannaKumar,
Quoted 18 lines · PrasannaKumar Muralidharan
Enable PRNG driver support in MIPS Creator CI20 default config.
Signed-off-by PrasannaKumar Muralidharan <[email protected]>---
No changes in v2arch/mips/configs/ci20_defconfig | 5 +++++ 1 file changed, 5 insertions(+)arch/mips/configs/ci20_defconfig +0
-0@@ -88,6 +88,11 @@ CONFIG_SERIAL_8250_RUNTIME_UARTS=5 CONFIG_SERIAL_8250_INGENIC=yarch/mips/configs/ci20_defconfig CONFIG_SERIAL_8250_RUNTIME_UARTS=5 · line 98
Quoted 10 lines
arch/mips/configs/ci20_defconfig +5
-0CONFIG_SERIAL_OF_PLATFORM=y # CONFIG_HW_RANDOM is not set +CONFIG_CRYPTO_USER=y +CONFIG_CRYPTO_USER_API=y +CONFIG_CRYPTO_USER_API_RNG=y +CONFIG_CRYPTO_HW=y +CONFIG_CRYPTO_DEV_JZ4780_RNG=y CONFIG_I2C=y CONFIG_I2C_JZ4780=y CONFIG_GPIO_SYSFS=yYou need to regenerate your defconfig as it is missing
CONFIG_MFD_SYSCON.
Quoted 8 lines
Quoted 3 lines
Thanks,
Harvey
CONFIG_MFD_SYSCONgets selected whenCONFIG_CRYPTO_DEV_JZ4780_RNGis selected. Please see theKconfigchanges. Given that should I add it inci20_defconfig? If it is required I will add and send a new version.
Oops, I hadn't noticed that - just skimmed the patches before my morning coffee. :-)
It's fine as is, excuse the noise.
Quoted 4 lines
Thanks,
PrasannaKumar
Thanks,
Harvey
Re: [PATCH v2 4/4] crypto: jz4780-rng: Enable PRNG support in CI20 defconfig
Hi Harvey,
Quoted 55 lines · Harvey Hunt
Hi PrasannaKumar,
Quoted 42 lines · PrasannaKumar Muralidharan
Hi Harvey,
Quoted 38 lines · Harvey Hunt
Hi PrasannaKumar,
Quoted 19 lines · PrasannaKumar Muralidharan
Enable PRNG driver support in MIPS Creator CI20 default config.
Signed-off-by PrasannaKumar Muralidharan <[email protected]>---
No changes in v2arch/mips/configs/ci20_defconfig | 5 +++++ 1 file changed, 5 insertions(+)arch/mips/configs/ci20_defconfig +0
-0@@ -88,6 +88,11 @@ CONFIG_SERIAL_8250_RUNTIME_UARTS=5 CONFIG_SERIAL_8250_INGENIC=yarch/mips/configs/ci20_defconfig CONFIG_SERIAL_8250_RUNTIME_UARTS=5 · line 98
Quoted 10 lines
arch/mips/configs/ci20_defconfig +5
-0CONFIG_SERIAL_OF_PLATFORM=y # CONFIG_HW_RANDOM is not set +CONFIG_CRYPTO_USER=y +CONFIG_CRYPTO_USER_API=y +CONFIG_CRYPTO_USER_API_RNG=y +CONFIG_CRYPTO_HW=y +CONFIG_CRYPTO_DEV_JZ4780_RNG=y CONFIG_I2C=y CONFIG_I2C_JZ4780=y CONFIG_GPIO_SYSFS=yYou need to regenerate your defconfig as it is missing
CONFIG_MFD_SYSCON.Thanks,
Quoted 7 lines
Quoted 1 line
Harvey
CONFIG_MFD_SYSCONgets selected whenCONFIG_CRYPTO_DEV_JZ4780_RNGis selected. Please see theKconfigchanges. Given that should I add it inci20_defconfig? If it is required I will add and send a new version.
Quoted 4 lines
Oops, I hadn't noticed that - just skimmed the patches before my morning coffee. :-)
It's fine as is, excuse the noise.
No issues.
Quoted 10 lines
Quoted 5 lines
Thanks,
PrasannaKumarThanks,
Harvey
Regards,
PrasannaKumar
Quoted 25 lines · PrasannaKumar Muralidharan
This patch series adds support of pseudo random number generator found in Ingenic's JZ4780 and X1000 SoC.
Based on Paul's review comments, add 'syscon' compatible in CGU node in
jz4780.dtsi. jz4780-rng driver uses regmap exposed via syscon interface to access the RNG registers. CGU driver is not modified in this patch set as registers used by CGU driver and this driver are different.PrasannaKumar Muralidharan (4):
crypto: jz4780-rng: Add JZ4780 PRNG devicetree binding documentation
crypto: jz4780-rng: Add Ingenic JZ4780 hardware PRNG driver
crypto: jz4780-rng: Add RNG node tojz4780.dtsi
crypto: jz4780-rng: Enable PRNG support in CI20 defconfig.../bindings/crypto/ingenic,jz4780-rng.txt | 20 +++ MAINTAINERS | 5 + arch/mips/boot/dts/ingenic/jz4780.dtsi | 6 +- arch/mips/configs/ci20_defconfig | 5 + drivers/crypto/Kconfig | 19 +++ drivers/crypto/Makefile | 1 + drivers/crypto/jz4780-rng.c | 168 +++++++++++++++++++++ 7 files changed, 223 insertions(+), 1 deletion(-) create mode 100644 Documentation/devicetree/bindings/crypto/ingenic,jz4780-rng.txt create mode 100644 drivers/crypto/jz4780-rng.c
Quoted 3 lines
--
2.10.0
The rng node which is the child node of CGU is ignored so the driver's probe is not called at all. Realised that the tests were using crng instead of this. Don't know how to get this working. Will submit a new version once the issue is fixed.
Please do not take this patch series.
Thanks,
PrasannaKumar