Updated patches for esp-idf 5.0
This commit is contained in:
parent
0f8febbf49
commit
192163966e
@ -8,8 +8,8 @@ ADD . /app
|
||||
|
||||
# Apply patches
|
||||
RUN cd /opt/esp/idf && \
|
||||
patch --ignore-whitespace -p1 -i "/app/tools/patches/panic-hook (esp-idf 4.x).diff" && \
|
||||
patch --ignore-whitespace -p1 -i "/app/tools/patches/sdcard-fix (esp-idf 4.x).diff"
|
||||
patch --ignore-whitespace -p1 -i "/app/tools/patches/panic-hook (esp-idf 5).diff" && \
|
||||
patch --ignore-whitespace -p1 -i "/app/tools/patches/sdcard-fix (esp-idf 5).diff"
|
||||
|
||||
# Build
|
||||
SHELL ["/bin/bash", "-c"]
|
||||
|
||||
24
tools/patches/panic-hook (esp-idf 5).diff
Normal file
24
tools/patches/panic-hook (esp-idf 5).diff
Normal file
@ -0,0 +1,24 @@
|
||||
diff --git a/components/esp_system/panic.c b/components/esp_system/panic.c
|
||||
index f320c28dca..665aea98a3 100644
|
||||
--- a/components/esp_system/panic.c
|
||||
+++ b/components/esp_system/panic.c
|
||||
@@ -66,6 +66,11 @@ static wdt_hal_context_t rtc_wdt_ctx = {.inst = WDT_RWDT, .rwdt_dev = &RTCCNTL};
|
||||
|
||||
#if !CONFIG_ESP_SYSTEM_PANIC_SILENT_REBOOT
|
||||
|
||||
+void __attribute__((weak)) esp_panic_putchar_hook(char c)
|
||||
+{
|
||||
+ // nothing
|
||||
+}
|
||||
+
|
||||
#if CONFIG_ESP_CONSOLE_UART
|
||||
static uart_hal_context_t s_panic_uart = { .dev = CONFIG_ESP_CONSOLE_UART_NUM == 0 ? &UART0 :&UART1 };
|
||||
|
||||
@@ -118,6 +123,7 @@ void panic_print_char(const char c)
|
||||
#if CONFIG_ESP_CONSOLE_USB_SERIAL_JTAG || CONFIG_ESP_CONSOLE_SECONDARY_USB_SERIAL_JTAG
|
||||
panic_print_char_usb_serial_jtag(c);
|
||||
#endif
|
||||
+ esp_panic_putchar_hook(c);
|
||||
}
|
||||
|
||||
void panic_print_str(const char *str)
|
||||
12
tools/patches/sdcard-fix (esp-idf 5).diff
Normal file
12
tools/patches/sdcard-fix (esp-idf 5).diff
Normal file
@ -0,0 +1,12 @@
|
||||
diff --git a/components/driver/sdspi_host.c b/components/driver/sdspi_host.c
|
||||
index 9a80188..4f35fbb 100644
|
||||
--- a/components/driver/sdspi_host.c
|
||||
+++ b/components/driver/sdspi_host.c
|
||||
@@ -458,6 +458,7 @@ esp_err_t sdspi_host_start_command(sdspi_dev_handle_t handle, sdspi_hw_cmd_t *cm
|
||||
const bool multi_block = flags & SDSPI_CMD_FLAG_MULTI_BLK;
|
||||
//send stop transmission token only when multi-block write and non-SDIO mode
|
||||
const bool stop_transmission = multi_block && !(flags & SDSPI_CMD_FLAG_RSP_R5);
|
||||
+ go_idle_clockout(slot);
|
||||
if (flags & SDSPI_CMD_FLAG_WRITE) {
|
||||
ret = start_command_write_blocks(slot, cmd, data, data_size, multi_block, stop_transmission);
|
||||
} else {
|
||||
Loading…
x
Reference in New Issue
Block a user