Skip to content

Commit

Permalink
drivers: entropy: Add support for TRNG to entropy driver
Browse files Browse the repository at this point in the history
add support TRNG to entropy driver for Renesas RA

Signed-off-by: Danh Doan <[email protected]>
  • Loading branch information
Danh Doan authored and khoa-nguyen-18 committed Dec 18, 2024
1 parent 27931b2 commit a417f88
Show file tree
Hide file tree
Showing 4 changed files with 17 additions and 1 deletion.
2 changes: 1 addition & 1 deletion drivers/entropy/Kconfig.renesas_ra
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ config ENTROPY_RENESAS_RA
bool "Renesas RA TRNG driver"
default y
depends on DT_HAS_RENESAS_RA_RSIP_E51A_TRNG_ENABLED || DT_HAS_RENESAS_RA_SCE7_RNG_ENABLED \
|| DT_HAS_RENESAS_RA_SCE5_RNG_ENABLED
|| DT_HAS_RENESAS_RA_SCE5_RNG_ENABLED || DT_HAS_RENESAS_RA_TRNG_ENABLED
select ENTROPY_HAS_DRIVER
select USE_RA_FSP_SCE
help
Expand Down
1 change: 1 addition & 0 deletions drivers/entropy/entropy_renesas_ra.c
Original file line number Diff line number Diff line change
Expand Up @@ -50,3 +50,4 @@ static int entropy_renesas_ra_init(const struct device *dev)
DT_FOREACH_STATUS_OKAY(renesas_ra_rsip_e51a_trng, RENESAS_RA_ENTROPY_INIT)
DT_FOREACH_STATUS_OKAY(renesas_ra_sce5_rng, RENESAS_RA_ENTROPY_INIT)
DT_FOREACH_STATUS_OKAY(renesas_ra_sce7_rng, RENESAS_RA_ENTROPY_INIT)
DT_FOREACH_STATUS_OKAY(renesas_ra_trng, RENESAS_RA_ENTROPY_INIT)
8 changes: 8 additions & 0 deletions dts/bindings/rng/renesas,ra-trng.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
# Copyright (c) 2024 Renesas Electronics Corporation
# SPDX-License-Identifier: Apache-2.0

description: Renesas RA TRNG

compatible: "renesas,ra-trng"

include: base.yaml
7 changes: 7 additions & 0 deletions modules/Kconfig.renesas_fsp
Original file line number Diff line number Diff line change
Expand Up @@ -73,6 +73,13 @@ config HAS_RENESAS_RA_SCE5
help
Includes SCE5 implementation for SCE driver

config HAS_RENESAS_RA_TRNG
bool
default y
depends on DT_HAS_RENESAS_RA_TRNG_ENABLED
help
Includes TRNG implementation for SCE driver

endif

config USE_RA_FSP_SPI_B
Expand Down

0 comments on commit a417f88

Please sign in to comment.