linux-riscv.lists.infradead.org archive mirror
 help / color / mirror / Atom feed
From: David Abdurachmanov <david.abdurachmanov@gmail.com>
To: Anup Patel <Anup.Patel@wdc.com>
Cc: Anup Patel <anup@brainfault.org>,
	"linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>,
	Atish Patra <Atish.Patra@wdc.com>,
	Alistair Francis <Alistair.Francis@wdc.com>,
	Paul Walmsley <paul.walmsley@sifive.com>,
	Palmer Dabbelt <palmer@dabbelt.com>,
	"linux-riscv@lists.infradead.org"
	<linux-riscv@lists.infradead.org>, Christoph Hellwig <hch@lst.de>
Subject: Re: [PATCH] RISC-V: Enable SYSCON reboot and poweroff drivers
Date: Mon, 11 Nov 2019 16:05:40 +0200	[thread overview]
Message-ID: <CAEn-LTpLu0ht=_HpK11Sa=frSvQt_1Nz48M3XZero=CJPidxDg@mail.gmail.com> (raw)
In-Reply-To: <MN2PR04MB60612DF0F3191A8240F71F458D740@MN2PR04MB6061.namprd04.prod.outlook.com>

On Mon, Nov 11, 2019 at 3:43 PM Anup Patel <Anup.Patel@wdc.com> wrote:
>
> Correct Palmer's email address
>
> > -----Original Message-----
> > From: Anup Patel
> > Sent: Monday, November 11, 2019 7:05 PM
> > To: Palmer Dabbelt <palmer@sifive.com>; Paul Walmsley
> > <paul.walmsley@sifive.com>
> > Cc: Atish Patra <Atish.Patra@wdc.com>; Alistair Francis
> > <Alistair.Francis@wdc.com>; Christoph Hellwig <hch@lst.de>; Anup Patel
> > <anup@brainfault.org>; linux-riscv@lists.infradead.org; linux-
> > kernel@vger.kernel.org; Anup Patel <Anup.Patel@wdc.com>
> > Subject: [PATCH] RISC-V: Enable SYSCON reboot and poweroff drivers
> >
> > We can use SYSCON reboot and poweroff drivers for the SiFive test device
> > found on QEMU virt machine and SiFive SOCs.
> >
> > This patch enables SYSCON reboot and poweroff drivers in RV64 and RV32
> > defconfigs.
> >
> > Signed-off-by: Anup Patel <anup.patel@wdc.com>
> > ---
> >  arch/riscv/configs/defconfig      | 4 ++++
> >  arch/riscv/configs/rv32_defconfig | 4 ++++
> >  2 files changed, 8 insertions(+)
> >
> > diff --git a/arch/riscv/configs/defconfig b/arch/riscv/configs/defconfig
> > index 420a0dbef386..73a6ee31a7d2 100644
> > --- a/arch/riscv/configs/defconfig
> > +++ b/arch/riscv/configs/defconfig
> > @@ -63,6 +63,10 @@ CONFIG_HW_RANDOM_VIRTIO=y  CONFIG_SPI=y
> > CONFIG_SPI_SIFIVE=y  # CONFIG_PTP_1588_CLOCK is not set
> > +CONFIG_POWER_RESET=y

Why not to add

    select POWER_RESET

to arch/riscv/Kconfig ?

This seems to be a popular choice (?). I went this path recently while
enabling gpio-restart on SiFive Unleashed on a private branch.

[..]
arch/arm/mach-exynos/Kconfig:   select POWER_RESET
arch/arm/mach-exynos/Kconfig:   select POWER_RESET_SYSCON
arch/arm/mach-exynos/Kconfig:   select POWER_RESET_SYSCON_POWEROFF
arch/arm/mach-gemini/Kconfig:   select POWER_RESET
arch/arm/mach-gemini/Kconfig:   select POWER_RESET_GEMINI_POWEROFF
arch/arm/mach-gemini/Kconfig:   select POWER_RESET_SYSCON
arch/arm/mach-hisi/Kconfig:     select POWER_RESET
arch/arm/mach-hisi/Kconfig:     select POWER_RESET_HISI
arch/arm/mach-integrator/Kconfig:       select POWER_RESET
arch/arm/mach-integrator/Kconfig:       select POWER_RESET_VERSATILE
arch/arm/mach-realview/Kconfig: select POWER_RESET
arch/arm/mach-realview/Kconfig: select POWER_RESET_VERSATILE
arch/arm/mach-versatile/Kconfig:        select POWER_RESET
arch/arm/mach-versatile/Kconfig:        select POWER_RESET_VERSATILE
arch/arm/mach-vexpress/Kconfig: select POWER_RESET
arch/arm/mach-vexpress/Kconfig: select POWER_RESET_VEXPRESS
arch/arm64/Kconfig:     select POWER_RESET
[..]

> > +CONFIG_POWER_RESET_SYSCON=y
> > +CONFIG_POWER_RESET_SYSCON_POWEROFF=y
> > +CONFIG_SYSCON_REBOOT_MODE=y
> >  CONFIG_DRM=y
> >  CONFIG_DRM_RADEON=y
> >  CONFIG_DRM_VIRTIO_GPU=y
> > diff --git a/arch/riscv/configs/rv32_defconfig
> > b/arch/riscv/configs/rv32_defconfig
> > index 87ee6e62b64b..1429e1254295 100644
> > --- a/arch/riscv/configs/rv32_defconfig
> > +++ b/arch/riscv/configs/rv32_defconfig
> > @@ -61,6 +61,10 @@ CONFIG_VIRTIO_CONSOLE=y
> > CONFIG_HW_RANDOM=y  CONFIG_HW_RANDOM_VIRTIO=y  #
> > CONFIG_PTP_1588_CLOCK is not set
> > +CONFIG_POWER_RESET=y
> > +CONFIG_POWER_RESET_SYSCON=y
> > +CONFIG_POWER_RESET_SYSCON_POWEROFF=y
> > +CONFIG_SYSCON_REBOOT_MODE=y
> >  CONFIG_DRM=y
> >  CONFIG_DRM_RADEON=y
> >  CONFIG_DRM_VIRTIO_GPU=y
> > --
> > 2.17.1
>
>
> _______________________________________________
> linux-riscv mailing list
> linux-riscv@lists.infradead.org
> http://lists.infradead.org/mailman/listinfo/linux-riscv

_______________________________________________
linux-riscv mailing list
linux-riscv@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-riscv

  reply	other threads:[~2019-11-11 14:06 UTC|newest]

Thread overview: 14+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-11-11 13:34 [PATCH] RISC-V: Enable SYSCON reboot and poweroff drivers Anup Patel
2019-11-11 13:43 ` Anup Patel
2019-11-11 14:05   ` David Abdurachmanov [this message]
2019-11-11 14:08 ` Andreas Schwab
2019-11-11 14:21   ` Anup Patel
2019-11-11 14:32     ` Andreas Schwab
2019-11-11 16:51       ` Anup Patel
2019-11-11 16:55         ` Andreas Schwab
2019-11-11 16:59           ` Christoph Hellwig
2019-11-11 17:01           ` David Abdurachmanov
2019-11-11 17:05             ` Andreas Schwab
2019-11-11 17:06 ` Paul Walmsley
2019-11-12  4:19   ` Anup Patel
2019-11-23  3:03 ` Paul Walmsley

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to='CAEn-LTpLu0ht=_HpK11Sa=frSvQt_1Nz48M3XZero=CJPidxDg@mail.gmail.com' \
    --to=david.abdurachmanov@gmail.com \
    --cc=Alistair.Francis@wdc.com \
    --cc=Anup.Patel@wdc.com \
    --cc=Atish.Patra@wdc.com \
    --cc=anup@brainfault.org \
    --cc=hch@lst.de \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-riscv@lists.infradead.org \
    --cc=palmer@dabbelt.com \
    --cc=paul.walmsley@sifive.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).