Lines Matching refs:rng
73 static void wait_for_irq(struct imx_rng *rng) in wait_for_irq() argument
79 rng->error = io_read32(rng->base.va + RNG_ESR); in wait_for_irq()
80 status = io_read32(rng->base.va + RNG_SR); in wait_for_irq()
88 static void irq_clear(struct imx_rng *rng) in irq_clear() argument
90 io_setbits32(rng->base.va + RNG_CR, in irq_clear()
92 io_setbits32(rng->base.va + RNG_CMD, in irq_clear()
96 static void irq_unmask(struct imx_rng *rng) in irq_unmask() argument
98 io_clrbits32(rng->base.va + RNG_CR, in irq_unmask()
102 static void rng_seed(struct imx_rng *rng) in rng_seed() argument
106 irq_clear(rng); in rng_seed()
108 irq_unmask(rng); in rng_seed()
110 io_setbits32(rng->base.va + RNG_CR, RNG_CR_AR); in rng_seed()
111 wait_for_irq(rng); in rng_seed()
112 irq_clear(rng); in rng_seed()
116 } while (rng->error); in rng_seed()