[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[PULL 01/21] fsl-imx6: Add SNVS support for i.MX6 boards
|
From: |
Peter Maydell |
|
Subject: |
[PULL 01/21] fsl-imx6: Add SNVS support for i.MX6 boards |
|
Date: |
Tue, 30 May 2023 14:26:00 +0100 |
From: Vitaly Cheptsov <cheptsov@ispras.ru>
SNVS is supported on both i.MX6 and i.MX6UL and is needed
to support shutdown on the board.
Cc: Peter Maydell <peter.maydell@linaro.org> (odd fixer:SABRELITE / i.MX6)
Cc: Jean-Christophe Dubois <jcd@tribudubois.net> (reviewer:SABRELITE / i.MX6)
Cc: qemu-arm@nongnu.org (open list:SABRELITE / i.MX6)
Cc: qemu-devel@nongnu.org (open list:All patches CC here)
Signed-off-by: Vitaly Cheptsov <cheptsov@ispras.ru>
Message-id: 20230515095015.66860-1-cheptsov@ispras.ru
Reviewed-by: Peter Maydell <peter.maydell@linaro.org>
Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
---
include/hw/arm/fsl-imx6.h | 2 ++
hw/arm/fsl-imx6.c | 8 ++++++++
2 files changed, 10 insertions(+)
diff --git a/include/hw/arm/fsl-imx6.h b/include/hw/arm/fsl-imx6.h
index 83291457cf2..5b4d48da084 100644
--- a/include/hw/arm/fsl-imx6.h
+++ b/include/hw/arm/fsl-imx6.h
@@ -21,6 +21,7 @@
#include "hw/cpu/a9mpcore.h"
#include "hw/misc/imx6_ccm.h"
#include "hw/misc/imx6_src.h"
+#include "hw/misc/imx7_snvs.h"
#include "hw/watchdog/wdt_imx2.h"
#include "hw/char/imx_serial.h"
#include "hw/timer/imx_gpt.h"
@@ -59,6 +60,7 @@ struct FslIMX6State {
A9MPPrivState a9mpcore;
IMX6CCMState ccm;
IMX6SRCState src;
+ IMX7SNVSState snvs;
IMXSerialState uart[FSL_IMX6_NUM_UARTS];
IMXGPTState gpt;
IMXEPITState epit[FSL_IMX6_NUM_EPITS];
diff --git a/hw/arm/fsl-imx6.c b/hw/arm/fsl-imx6.c
index 00dafe3f62d..4fa7f0b95ed 100644
--- a/hw/arm/fsl-imx6.c
+++ b/hw/arm/fsl-imx6.c
@@ -53,6 +53,8 @@ static void fsl_imx6_init(Object *obj)
object_initialize_child(obj, "src", &s->src, TYPE_IMX6_SRC);
+ object_initialize_child(obj, "snvs", &s->snvs, TYPE_IMX7_SNVS);
+
for (i = 0; i < FSL_IMX6_NUM_UARTS; i++) {
snprintf(name, NAME_SIZE, "uart%d", i + 1);
object_initialize_child(obj, name, &s->uart[i], TYPE_IMX_SERIAL);
@@ -390,6 +392,12 @@ static void fsl_imx6_realize(DeviceState *dev, Error
**errp)
qdev_get_gpio_in(DEVICE(&s->a9mpcore),
FSL_IMX6_ENET_MAC_1588_IRQ));
+ /*
+ * SNVS
+ */
+ sysbus_realize(SYS_BUS_DEVICE(&s->snvs), &error_abort);
+ sysbus_mmio_map(SYS_BUS_DEVICE(&s->snvs), 0, FSL_IMX6_SNVSHP_ADDR);
+
/*
* Watchdog
*/
--
2.34.1
- [PULL 15/21] target/arm: Explicitly select short-format FSR for M-profile, (continued)
- [PULL 15/21] target/arm: Explicitly select short-format FSR for M-profile, Peter Maydell, 2023/05/30
- [PULL 18/21] arm/Kconfig: Make TCG dependence explicit, Peter Maydell, 2023/05/30
- [PULL 03/21] hw/arm/smmuv3: Update translation config to hold stage-2, Peter Maydell, 2023/05/30
- [PULL 08/21] hw/arm/smmuv3: Add VMID to TLB tagging, Peter Maydell, 2023/05/30
- [PULL 10/21] hw/arm/smmuv3: Add stage-2 support in iova notifier, Peter Maydell, 2023/05/30
- [PULL 11/21] hw/arm/smmuv3: Add knob to choose translation stage and enable stage-2, Peter Maydell, 2023/05/30
- [PULL 17/21] arm/Kconfig: Keep Kconfig default entries in default.mak as documentation, Peter Maydell, 2023/05/30
- [PULL 13/21] hw/arm/xlnx-zynqmp: fix unsigned error when checking the RPUs number, Peter Maydell, 2023/05/30
- [PULL 02/21] hw/arm/smmuv3: Add missing fields for IDR0, Peter Maydell, 2023/05/30
- [PULL 12/21] hw/dma/xilinx_axidma: Check DMASR.HALTED to prevent infinite loop., Peter Maydell, 2023/05/30
- [PULL 01/21] fsl-imx6: Add SNVS support for i.MX6 boards,
Peter Maydell <=
- [PULL 09/21] hw/arm/smmuv3: Add CMDs related to stage-2, Peter Maydell, 2023/05/30
- [PULL 19/21] Update copyright dates to 2023, Peter Maydell, 2023/05/30
- [PULL 06/21] hw/arm/smmuv3: Parse STE config for stage-2, Peter Maydell, 2023/05/30
- [PULL 05/21] hw/arm/smmuv3: Add page table walk for stage-2, Peter Maydell, 2023/05/30
- [PULL 14/21] tests/qtest: Run arm-specific tests only if the required machine is available, Peter Maydell, 2023/05/30
- [PULL 20/21] hw/arm/sbsa-ref: add GIC node into DT, Peter Maydell, 2023/05/30
- [PULL 21/21] docs: sbsa: correct graphics card name, Peter Maydell, 2023/05/30
- [PULL 16/21] target/arm: Explain why we need to select ARM_V7M, Peter Maydell, 2023/05/30
- [PULL 07/21] hw/arm/smmuv3: Make TLB lookup work for stage-2, Peter Maydell, 2023/05/30
- Re: [PULL 00/21] target-arm queue, Richard Henderson, 2023/05/30