[PATCH v3 32/38] ppc: qemu: Enable support for power off via GPIO

Bin Meng bmeng.cn at gmail.com
Thu Feb 25 10:22:53 CET 2021


The QEMU ppce500 target provides the power off functionality via
the GPIO pin#0, and we can support this using the sysreset gpio
poweroff driver. Let's enable it.

Signed-off-by: Bin Meng <bmeng.cn at gmail.com>
Reviewed-by: Priyanka Jain <priyanka.jain at nxp.com>

---

(no changes since v2)

Changes in v2:
- new patch: ppc: qemu: Enable support for power off via GPIO

 configs/qemu-ppce500_defconfig | 6 +++++-
 1 file changed, 5 insertions(+), 1 deletion(-)

diff --git a/configs/qemu-ppce500_defconfig b/configs/qemu-ppce500_defconfig
index c5e2ad3..8798db6 100644
--- a/configs/qemu-ppce500_defconfig
+++ b/configs/qemu-ppce500_defconfig
@@ -1,7 +1,6 @@
 CONFIG_PPC=y
 CONFIG_SYS_TEXT_BASE=0xf01000
 CONFIG_ENV_SIZE=0x2000
-CONFIG_DM_GPIO=y
 CONFIG_MPC85xx=y
 # CONFIG_CMD_ERRATA is not set
 CONFIG_TARGET_QEMU_PPCE500=y
@@ -18,6 +17,7 @@ CONFIG_CMD_GREPENV=y
 CONFIG_CMD_DM=y
 CONFIG_CMD_GPIO=y
 CONFIG_CMD_PCI=y
+CONFIG_CMD_POWEROFF=y
 CONFIG_CMD_DHCP=y
 CONFIG_CMD_PING=y
 # CONFIG_CMD_HASH is not set
@@ -38,6 +38,10 @@ CONFIG_DM_PCI=y
 CONFIG_PCI_MPC85XX=y
 CONFIG_DM_SERIAL=y
 CONFIG_SYS_NS16550=y
+CONFIG_SYSRESET=y
+# CONFIG_SYSRESET_CMD_RESET is not set
+CONFIG_SYSRESET_CMD_POWEROFF=y
+CONFIG_POWEROFF_GPIO=y
 CONFIG_VIRTIO_PCI=y
 CONFIG_VIRTIO_NET=y
 CONFIG_VIRTIO_BLK=y
-- 
2.7.4



More information about the U-Boot mailing list