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, 20 Jan 2021 06:34:44 +0900
From:   Stafford Horne <shorne@...il.com>
To:     Geert Uytterhoeven <geert@...ux-m68k.org>
Cc:     Karol Gugala <kgugala@...micro.com>,
        Mateusz Holenko <mholenko@...micro.com>,
        Gabriel Somlo <gsomlo@...il.com>,
        linux-riscv@...ts.infradead.org, linux-kernel@...r.kernel.org
Subject: Re: [PATCH v4] drivers/soc/litex: Add restart handler

On Tue, Jan 19, 2021 at 09:09:38AM +0100, Geert Uytterhoeven wrote:
> Let the LiteX SoC Controller register a restart handler, which resets
> the LiteX SoC by writing 1 to CSR_CTRL_RESET_ADDR.
> 
> Signed-off-by: Geert Uytterhoeven <geert@...ux-m68k.org>

Thanks, this looks good to me, queued to my linux-next branch.

-Stafford

> @@ -66,8 +71,19 @@ static int litex_check_csr_access(void __iomem *reg_addr)
>  
>  struct litex_soc_ctrl_device {
>  	void __iomem *base;
> +	struct notifier_block reset_nb;
>  };
>  
> +static int litex_reset_handler(struct notifier_block *this, unsigned long mode,
> +			       void *cmd)
> +{
> +	struct litex_soc_ctrl_device *soc_ctrl_dev =
> +		container_of(this, struct litex_soc_ctrl_device, reset_nb);

Nice.

> +	litex_write32(soc_ctrl_dev->base + RESET_REG_OFF, RESET_REG_VALUE);
> +	return NOTIFY_DONE;
> +}
> +

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ