[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [PATCH v2 4/7] hw/misc: Allwinner AXP-209 Emulation
From: |
Philippe Mathieu-Daudé |
Subject: |
Re: [PATCH v2 4/7] hw/misc: Allwinner AXP-209 Emulation |
Date: |
Sun, 18 Dec 2022 23:07:35 +0100 |
User-agent: |
Mozilla/5.0 (Macintosh; Intel Mac OS X 10.15; rv:102.0) Gecko/20100101 Thunderbird/102.5.1 |
On 18/12/22 22:19, Strahinja Jankovic wrote:
This patch adds minimal support for AXP-209 PMU.
Most important is chip ID since U-Boot SPL expects version 0x1. Besides
the chip ID register, reset values for two more registers used by A10
U-Boot SPL are covered.
Signed-off-by: Strahinja Jankovic <strahinja.p.jankovic@gmail.com>
---
hw/arm/Kconfig | 1 +
hw/misc/Kconfig | 4 +
hw/misc/allwinner-axp-209.c | 238 ++++++++++++++++++++++++++++++++++++
hw/misc/meson.build | 1 +
hw/misc/trace-events | 5 +
5 files changed, 249 insertions(+)
create mode 100644 hw/misc/allwinner-axp-209.c
diff --git a/hw/misc/Kconfig b/hw/misc/Kconfig
index 052fb54310..3855d937fd 100644
--- a/hw/misc/Kconfig
+++ b/hw/misc/Kconfig
@@ -180,4 +180,8 @@ config ALLWINNER_A10_CCM
config ALLWINNER_A10_DRAMC
bool
+config ALLWINNER_AXP_209
This controller is not specific to AllWinner. It can be plugged on any
i2c bus. Please rename it AXP209_PMU. Otherwise LGTM!
+ bool
+ depends on I2C
+
source macio/Kconfig
diff --git a/hw/misc/allwinner-axp-209.c b/hw/misc/allwinner-axp-209.c
new file mode 100644
index 0000000000..cf79175034
--- /dev/null
+++ b/hw/misc/allwinner-axp-209.c
@@ -0,0 +1,238 @@
+/*
+ * AXP-209 Emulation
+ *
+ * Copyright (C) 2022 Strahinja Jankovic <strahinja.p.jankovic@gmail.com>
- [PATCH v2 0/7] Enable Cubieboard A10 boot SPL from SD card, Strahinja Jankovic, 2022/12/18
- [PATCH v2 2/7] hw/misc: Allwinner A10 DRAM Controller Emulation, Strahinja Jankovic, 2022/12/18
- [PATCH v2 1/7] hw/misc: Allwinner-A10 Clock Controller Module Emulation, Strahinja Jankovic, 2022/12/18
- [PATCH v2 3/7] hw/i2c: Allwinner TWI/I2C Emulation, Strahinja Jankovic, 2022/12/18
- [PATCH v2 4/7] hw/misc: Allwinner AXP-209 Emulation, Strahinja Jankovic, 2022/12/18
- Re: [PATCH v2 4/7] hw/misc: Allwinner AXP-209 Emulation, Strahinja Jankovic, 2022/12/18
- Re: [PATCH v2 4/7] hw/misc: Allwinner AXP-209 Emulation,
Philippe Mathieu-Daudé <=
- Re: [PATCH v2 4/7] hw/misc: Allwinner AXP-209 Emulation, Strahinja Jankovic, 2022/12/18
- Re: [PATCH v2 4/7] hw/misc: Allwinner AXP-209 Emulation, Philippe Mathieu-Daudé, 2022/12/18
- Re: [PATCH v2 4/7] hw/misc: Allwinner AXP-209 Emulation, Strahinja Jankovic, 2022/12/18
- Re: [PATCH v2 4/7] hw/misc: Allwinner AXP-209 Emulation, Philippe Mathieu-Daudé, 2022/12/19
- Re: [PATCH v2 4/7] hw/misc: Allwinner AXP-209 Emulation, Strahinja Jankovic, 2022/12/19
[PATCH v2 7/7] docs/system/arm: Update Allwinner with TWI (I2C), Strahinja Jankovic, 2022/12/18
[PATCH v2 5/7] hw/arm: Add AXP-209 to Cubieboard, Strahinja Jankovic, 2022/12/18