casaroli commented on code in PR #21480: URL: https://github.com/apache/nuttx/pull/21480#discussion_r4634613977
########## boards/xtensa/esp32s3/esp32s3-r8/Kconfig: ########## @@ -0,0 +1,66 @@ +# Review Comment: This Kconfig has no license header; since a7bce1df393 every other board Kconfig under boards/xtensa has one. Fix: add the same ASF header as boards/xtensa/esp32s3/esp32s3-eye/Kconfig. ########## boards/xtensa/esp32s3/esp32s3-r8/Kconfig: ########## @@ -0,0 +1,66 @@ +# +# For a description of the syntax of this configuration file, +# see the file kconfig-language.txt in the NuttX tools repository. +# + +if ARCH_BOARD_ESP32S3_R8 + +config ESP32S3_STORAGE_MTD_OFFSET + hex "Storage MTD base address in SPI Flash" + default 0x180000 + depends on ESP32S3_MTD + ---help--- + MTD base address in SPI Flash. + +config ESP32S3_STORAGE_MTD_SIZE + hex "Storage MTD size in SPI Flash" + default 0x100000 + range 0x0 0x400000 if ESP32S3_FLASH_4M + range 0x0 0x800000 if ESP32S3_FLASH_8M + range 0x0 0x1000000 if ESP32S3_FLASH_16M + range 0x0 0x2000000 if ESP32S3_FLASH_32M + depends on ESP32S3_MTD + ---help--- + MTD size in SPI Flash. + +choice ESP32S3_SPIFLASH_FS + prompt "Mount SPI Flash MTD on bring-up" + default ESP32S3_SPIFLASH_SMARTFS + depends on ESP32S3_MTD + optional Review Comment: This file copies the `ESP32S3_STORAGE_MTD_*` options and the `ESP32S3_SPIFLASH_FS` choice from boards/xtensa/esp32s3/common/Kconfig, and adds `optional` to the choice. A named choice is shared, so the choice becomes optional for every ESP32-S3 board and its default SmartFS is no longer selected. This is the xtensa-03 failure: esp32s3-devkit:spiflash, kernel_n8r2 and kernel_oct lose `CONFIG_NSH_DISABLE_LOSMART=y` because `MTD_SMART` and `FS_SMARTFS` are now off, so these configs mount no file system on the SPI flash. Without line 30, esp32s3-devkit:spiflash normalizes again with `CONFIG_ESP32S3_SPIFLASH_SMARTFS=y`. Fix: delete lines 8-54 (everything except `ESP32S3_R8_LCD`); the common Kconfig already provides these options. ########## boards/xtensa/esp32s3/esp32s3-r8/configs/nsh/defconfig: ########## @@ -0,0 +1,56 @@ +# +# This file is autogenerated: PLEASE DO NOT EDIT IT. +# +# You can use "make menuconfig" to make any modifications to the installed .config file. +# You can then do "make savedefconfig" to generate a new defconfig file that includes your +# modifications. +# +# CONFIG_ARCH_LEDS is not set +# CONFIG_NSH_ARGCAT is not set +# CONFIG_NSH_CMDOPT_HEXDUMP is not set +CONFIG_ARCH="xtensa" +CONFIG_ARCH_BOARD="esp32s3-r8" +CONFIG_ARCH_BOARD_COMMON=y +CONFIG_ARCH_BOARD_ESP32S3_R8=y +CONFIG_ARCH_CHIP="esp32s3" +CONFIG_ARCH_CHIP_ESP32S3=y +CONFIG_ARCH_CHIP_ESP32S3WROOM2N32R8V=y Review Comment: All seven defconfigs select `CONFIG_ARCH_CHIP_ESP32S3WROOM2N32R8V` (32 MB octal flash) but keep the default DIO flash mode. On an octal flash chip `esp32s3_start.c:580` prints "Octal Flash chip detected! Select CONFIG_ESP32S3_FLASH_MODE_OCT on menuconfig" and aborts, so these images do not boot on that module. The new documentation page also says "8 MB flash", which is not the N32R8V. Fix: if the board has the WROOM-2-N32R8V, add `CONFIG_ESP32S3_FLASH_MODE_OCT=y` to every defconfig and say "32 MB octal flash" in index.rst; if not, select the real module. Please add the boot log of each config to the Testing section. ########## boards/xtensa/esp32s3/esp32s3-r8/src/Make.defs: ########## @@ -0,0 +1,51 @@ +############################################################################ +# boards/xtensa/esp32s3/esp32s3-r8/src/Make.defs +# +# SPDX-License-Identifier: Apache-2.0 +# +# Licensed to the Apache Software Foundation (ASF) under one or more +# contributor license agreements. See the NOTICE file distributed with +# this work for additional information regarding copyright ownership. The +# ASF licenses this file to you under the Apache License, Version 2.0 (the +# "License"); you may not use this file except in compliance with the +# License. You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, WITHOUT +# WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the +# License for the specific language governing permissions and limitations +# under the License. +# +############################################################################ + +CSRCS = esp32s3_boot.c esp32s3_bringup.c + +ifeq ($(CONFIG_BOARDCTL_RESET),y) +CSRCS += esp32s3_reset.c +endif + +ifeq ($(CONFIG_ARCH_BUTTONS),y) +CSRCS += esp32s3_buttons.c +endif + +ifeq ($(CONFIG_DEV_GPIO),y) +CSRCS += esp32s3_gpio.c +endif + +ifeq ($(CONFIG_ESP32S3_SPI),y) +CSRCS += esp32s3_board_spi.c +endif + +ifeq ($(CONFIG_ESP32S3_R8_LCD),y) +CSRCS += esp32s3_board_lcd.c +endif + +DEPPATH += --dep-path board +VPATH += :board +CFLAGS += ${INCDIR_PREFIX}$(TOPDIR)$(DELIM)arch$(DELIM)$(CONFIG_ARCH)$(DELIM)src$(DELIM)board$(DELIM)board + +ifeq ($(CONFIG_ESP32S3_R8_TOUCHSCREEN),y) Review Comment: The touchscreen, IMU and audio support was removed, but this line still adds esp32s3_touchscreen.c for CONFIG_ESP32S3_R8_TOUCHSCREEN (neither exists now), include/board.h:58-73 still has the ES8311/ES7210 defines, the board help in boards/Kconfig still says "a touchscreen, an IMU and audio codecs", and the PR body still lists them. Fix: remove these leftovers and update the board help and the PR body. -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: [email protected] For queries about this service, please contact Infrastructure at: [email protected]
