#include <linux/clk.h>
#include <linux/clkdev.h>
#include <linux/err.h>
#include <linux/hw_random.h>
#include <linux/io.h>
#include <linux/kernel.h>
#include <linux/mod_devicetable.h>
#include <linux/module.h>
#include <linux/platform_device.h>
#include <linux/slab.h>
#define RNGCON …
#define TRNGEN …
#define TRNGMOD …
#define RNGSEED1 …
#define RNGSEED2 …
#define RNGRCNT …
#define RCNT_MASK …
struct pic32_rng { … };
#define RNG_TIMEOUT …
static int pic32_rng_init(struct hwrng *rng)
{ … }
static int pic32_rng_read(struct hwrng *rng, void *buf, size_t max,
bool wait)
{ … }
static void pic32_rng_cleanup(struct hwrng *rng)
{ … }
static int pic32_rng_probe(struct platform_device *pdev)
{ … }
static const struct of_device_id pic32_rng_of_match[] __maybe_unused = …;
MODULE_DEVICE_TABLE(of, pic32_rng_of_match);
static struct platform_driver pic32_rng_driver = …;
module_platform_driver(…) …;
MODULE_LICENSE(…) …;
MODULE_AUTHOR(…) …;
MODULE_DESCRIPTION(…) …;