summaryrefslogtreecommitdiffstats
path: root/include/linux/hw_random.h
diff options
context:
space:
mode:
authorAhmad Fatoum <a.fatoum@pengutronix.de>2024-03-13 11:56:27 +0100
committerSascha Hauer <s.hauer@pengutronix.de>2024-03-15 08:07:39 +0100
commit3140bcb3f7799ae492e295975f228bf1fd92cb01 (patch)
tree76e1ab22136a215bbd6a0f33332e4b1b02c5a824 /include/linux/hw_random.h
parent3aafb07324f65c3337217a392e70ba6ad0021875 (diff)
downloadbarebox-3140bcb3f7799ae492e295975f228bf1fd92cb01.tar.gz
barebox-3140bcb3f7799ae492e295975f228bf1fd92cb01.tar.xz
hw_random: add BCM2835 RNG driver
To enable proper hardening with stack protector, add support for the BCM2835 RNG. This has been tested on a Raspberry Pi 3B. Signed-off-by: Ahmad Fatoum <a.fatoum@pengutronix.de> Link: https://lore.barebox.org/20240313105631.686778-9-a.fatoum@pengutronix.de Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
Diffstat (limited to 'include/linux/hw_random.h')
-rw-r--r--include/linux/hw_random.h5
1 files changed, 5 insertions, 0 deletions
diff --git a/include/linux/hw_random.h b/include/linux/hw_random.h
index 4479428bc7..ff6d3bb582 100644
--- a/include/linux/hw_random.h
+++ b/include/linux/hw_random.h
@@ -52,4 +52,9 @@ static inline int hwrng_get_data(struct hwrng *rng, void *buffer, size_t size, i
void hwrng_unregister(struct hwrng *rng);
+static inline long hwrng_yield(struct hwrng *rng)
+{
+ return 0;
+}
+
#endif /* LINUX_HWRANDOM_H_ */