1
0
mirror of https://github.com/RIOT-OS/RIOT.git synced 2025-12-19 03:23:49 +01:00
RIOT/pkg/esp32_sdk/patches/0038-hal-esp32c6-gspi_flash_ll-fix-signed-unsigned-compar.patch
2025-07-28 19:14:22 +02:00

27 lines
1.1 KiB
Diff

From 686ebb0788c6a4e35d2296211010b4caccf290d7 Mon Sep 17 00:00:00 2001
From: Gunar Schorcht <gunar@schorcht.net>
Date: Mon, 21 Apr 2025 00:07:42 +0200
Subject: [PATCH 38/40] hal/esp32c6/gspi_flash_ll: fix signed/unsigned
comparison
---
components/hal/esp32c6/include/hal/gpspi_flash_ll.h | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/components/hal/esp32c6/include/hal/gpspi_flash_ll.h b/components/hal/esp32c6/include/hal/gpspi_flash_ll.h
index 73d64db653..3345eb2de2 100644
--- a/components/hal/esp32c6/include/hal/gpspi_flash_ll.h
+++ b/components/hal/esp32c6/include/hal/gpspi_flash_ll.h
@@ -85,7 +85,7 @@ static inline void gpspi_flash_ll_get_buffer_data(spi_dev_t *dev, void *buffer,
} else {
// Otherwise, slow(er) path copies word by word
int copy_len = read_len;
- for (int i = 0; i < (read_len + 3) / 4; i++) {
+ for (unsigned i = 0; i < (read_len + 3) / 4; i++) {
int word_len = MIN(sizeof(uint32_t), copy_len);
uint32_t word = dev->data_buf[i].buf;
memcpy(buffer, &word, word_len);
--
2.34.1