[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [PATCH v2] Use named constants in BCM props
From: |
Philippe Mathieu-Daudé |
Subject: |
Re: [PATCH v2] Use named constants in BCM props |
Date: |
Tue, 13 Jun 2023 00:30:53 +0200 |
User-agent: |
Mozilla/5.0 (Macintosh; Intel Mac OS X 10.15; rv:102.0) Gecko/20100101 Thunderbird/102.11.2 |
On 12/6/23 13:59, Sergey Kambalin wrote:
ping
- PI_FIRMWARE_*_RATE constsnts were moved to raspberrypi-fw-defs.h
(seems more suitable place for them)
- inclusion of "qemu/osdep.h" has been removed
- year in copyright header has been updated
Signed-off-by: Sergey Kambalin <sergey.kambalin@auriga.com>
---
hw/misc/bcm2835_property.c | 120 ++++++++++---------
include/hw/arm/raspi_platform.h | 6 +
include/hw/misc/raspberrypi-fw-defs.h | 163 ++++++++++++++++++++++++++
3 files changed, 236 insertions(+), 53 deletions(-)
create mode 100644 include/hw/misc/raspberrypi-fw-defs.h
diff --git a/include/hw/arm/raspi_platform.h b/include/hw/arm/raspi_platform.h
index 4a56dd4b89..92a317950a 100644
--- a/include/hw/arm/raspi_platform.h
+++ b/include/hw/arm/raspi_platform.h
@@ -170,4 +170,10 @@
#define INTERRUPT_ILLEGAL_TYPE0 6
#define INTERRUPT_ILLEGAL_TYPE1 7
+/* Clock rates */
+#define RPI_FIRMWARE_EMMC_CLK_RATE 50000000
OK.
+#define RPI_FIRMWARE_UART_CLK_RATE 3000000
OK.
+#define RPI_FIRMWARE_CORE_CLK_RATE 350000000
Seems VC4 frequency range, adapted for raspi3 (BCM2837).
IIUC the VC6 (raspi4) is clocked at 500MHz.
+#define RPI_FIRMWARE_DEFAULT_CLK_RATE 700000000
Seems VC4 freq for raspi1 (BCM2835)
Likely we don't want to use a default, but the correct per-soc
value...