1
0
mirror of https://github.com/RIOT-OS/RIOT.git synced 2024-12-29 04:50:03 +01:00
RIOT/pkg/esp32_sdk/patches/0021-spi_flash-changes-for-RIOT-for-esp32s3.patch
Gunar Schorcht ca34e970f1 pkg/esp32_sdk: additional patches required for ESP32-S3
The patches include the following changes:
- define ARRAY_SIZE in `component/spi_flash/spi_flash_timing_tuning.c` only if it is not yet defined by RIOT macros
- add alternative implementations for`spi_flash_disable_interrupts_caches_and_other_cpu` and `spi_flash_enable_interrupts_caches_and_other_cpu` if compiled for RIOT
- fix the undefined reference to `rtc_gpio_force_hold_en_all` in `components/driver/gpio.c`
- rename the bootloader patch to fix the serial number
2022-08-08 08:18:08 +02:00

28 lines
938 B
Diff

From 1cb888fc95a0374523e164d513952681e4e5847c Mon Sep 17 00:00:00 2001
From: Gunar Schorcht <gunar@schorcht.net>
Date: Fri, 8 Apr 2022 16:45:44 +0200
Subject: [PATCH 21/23] spi_flash: changes for RIOT for esp32s3
Define ARRAY_SIZE in `component/spi_flash/spi_flash_timing_tuning.c` only if it is not yet defined by RIOT macros.
---
components/spi_flash/spi_flash_timing_tuning.c | 2 ++
1 file changed, 2 insertions(+)
diff --git a/components/spi_flash/spi_flash_timing_tuning.c b/components/spi_flash/spi_flash_timing_tuning.c
index 8b2efd1450..de8a0a60e9 100644
--- a/components/spi_flash/spi_flash_timing_tuning.c
+++ b/components/spi_flash/spi_flash_timing_tuning.c
@@ -20,7 +20,9 @@
#include "esp32s3/rom/cache.h"
#endif
+#ifndef ARRAY_SIZE
#define ARRAY_SIZE(arr) (sizeof(arr)/sizeof(*(arr)))
+#endif
#if SPI_TIMING_FLASH_NEEDS_TUNING || SPI_TIMING_PSRAM_NEEDS_TUNING
const static char *TAG = "MSPI Timing";
--
2.17.1