lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date:   Wed, 12 Feb 2020 21:52:15 +0530
From:   PrasannaKumar Muralidharan <prasannatsmkumar@...il.com>
To:     Martin Kaiser <martin@...ser.cx>
Cc:     Herbert Xu <herbert@...dor.apana.org.au>,
        NXP Linux Team <linux-imx@....com>,
        "open list:HARDWARE RANDOM NUMBER GENERATOR CORE" 
        <linux-crypto@...r.kernel.org>,
        linux-arm-kernel@...ts.infradead.org,
        open list <linux-kernel@...r.kernel.org>,
        stable@...r.kernel.org
Subject: Re: [PATCH 1/6] hwrng: imx-rngc - fix an error path

Hi Martin,

On Tue, 28 Jan 2020 at 16:31, Martin Kaiser <martin@...ser.cx> wrote:
>
> Make sure that the rngc interrupt is masked if the rngc self test fails.
> Self test failure means that probe fails as well. Interrupts should be
> masked in this case, regardless of the error.
>
> Cc: stable@...r.kernel.org
> Fixes: 1d5449445bd0 ("hwrng: mx-rngc - add a driver for Freescale RNGC")
> Signed-off-by: Martin Kaiser <martin@...ser.cx>
> ---
>  drivers/char/hw_random/imx-rngc.c | 4 +++-
>  1 file changed, 3 insertions(+), 1 deletion(-)
>
> diff --git a/drivers/char/hw_random/imx-rngc.c b/drivers/char/hw_random/imx-rngc.c
> index 30cf00f8e9a0..0576801944fd 100644
> --- a/drivers/char/hw_random/imx-rngc.c
> +++ b/drivers/char/hw_random/imx-rngc.c
> @@ -105,8 +105,10 @@ static int imx_rngc_self_test(struct imx_rngc *rngc)
>                 return -ETIMEDOUT;
>         }
>
> -       if (rngc->err_reg != 0)
> +       if (rngc->err_reg != 0) {
> +               imx_rngc_irq_mask_clear(rngc);
>                 return -EIO;
> +       }
>
>         return 0;
>  }
> --
> 2.20.1
>

Looks good to me. You can add
Reviewed-by: PrasannaKumar Muralidharan <prasannatsmkumar@...il.com>

Regards,
PrasannaKumar

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ