Lines Matching refs:sr
104 u32 sr = readl_relaxed(priv->base + RNG_SR); in stm32_rng_conceal_seed_error_cond_reset() local
108 if (sr & RNG_SR_SECS) { in stm32_rng_conceal_seed_error_cond_reset()
114 writel_relaxed(sr & ~RNG_SR_SEIS, priv->base + RNG_SR); in stm32_rng_conceal_seed_error_cond_reset()
121 dev_err(dev, "%s: timeout %x\n", __func__, sr); in stm32_rng_conceal_seed_error_cond_reset()
129 err = readl_relaxed_poll_timeout_atomic(priv->base + RNG_SR, sr, !(sr & RNG_SR_SECS), 10, in stm32_rng_conceal_seed_error_cond_reset()
132 dev_err(dev, "%s: timeout %x\n", __func__, sr); in stm32_rng_conceal_seed_error_cond_reset()
158 u32 sr = readl_relaxed(priv->base + RNG_SR); in stm32_rng_conceal_seed_error_sw_reset() local
160 writel_relaxed(sr & ~RNG_SR_SEIS, priv->base + RNG_SR); in stm32_rng_conceal_seed_error_sw_reset()
189 u32 sr; in stm32_rng_read() local
199 sr = readl_relaxed(priv->base + RNG_SR); in stm32_rng_read()
204 if (!sr && wait) { in stm32_rng_read()
207 sr, sr, in stm32_rng_read()
210 dev_err(priv->dev, "%s: timeout %x!\n", __func__, sr); in stm32_rng_read()
213 } else if (!sr) { in stm32_rng_read()
218 if (sr != RNG_SR_DRDY) { in stm32_rng_read()
219 if (sr & RNG_SR_SEIS) { in stm32_rng_read()
231 if (WARN_ONCE((sr & RNG_SR_CEIS), "RNG clock too slow - %x\n", sr)) in stm32_rng_read()