Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Allows QIO and QOUT flash modes #337

Merged
merged 1 commit into from
Oct 11, 2024

Conversation

wmrsouza
Copy link
Collaborator

@wmrsouza wmrsouza commented Sep 11, 2024

Allows QIO and QOUT flash modes to work in:

  • esp32s2
  • esp32s3
  • esp32c2
  • esp32c3
  • esp32c6

@EricNRS
Copy link
Contributor

EricNRS commented Sep 12, 2024

@wmrsouza - thanks for taking a look at this issue. I had tried enabling the flash wrap back in June and ran into a problem with the flash chip ID functionality. Has that been fixed, now? See zephyrproject-rtos/zephyr#73677 (comment) for details on the issue I ran into.

@wmrsouza
Copy link
Collaborator Author

Unfortunately, it's not fixed yet. I'm debugging the issue and will open this PR for review once it's working.

@wmrsouza wmrsouza force-pushed the bugfix/QIO_mode branch 2 times, most recently from f4d2503 to c6a4556 Compare September 30, 2024 20:44
@wmrsouza wmrsouza marked this pull request as ready for review October 8, 2024 19:38
@wmrsouza wmrsouza changed the title bugfix: esp32s3: allows QIO flash mode bugfix: esp32s3: allows QIO and QOUT flash modes Oct 8, 2024
@wmrsouza
Copy link
Collaborator Author

wmrsouza commented Oct 8, 2024

@EricNRS

@@ -5,6 +5,8 @@ if(CONFIG_SOC_SERIES_ESP32S3)
zephyr_compile_options(-fstrict-volatile-bitfields)
zephyr_compile_definitions_ifndef(CONFIG_MCUBOOT CONFIG_APP_BUILD_USE_FLASH_SECTIONS)
zephyr_compile_definitions_ifdef(CONFIG_MCUBOOT BOOTLOADER_BUILD)
zephyr_compile_definitions_ifdef(CONFIG_ESP_SIMPLE_BOOT AND CONFIG_ESPTOOLPY_FLASHMODE_QIO BOOTLOADER_BUILD)
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I this case why not just leaving BOOTLOADER_BUILD enabled?
zephyr_compile_definitions_ifdef(CONFIG_ESP_SIMPLE_BOOT BOOTLOADER_BUILD)

@sylvioalves
Copy link
Collaborator

@wmrsouza, move Fixes #73677 to Zephyr's PR instead.

@@ -145,7 +147,7 @@ if(CONFIG_SOC_SERIES_ESP32S3)
../../components/spi_flash/spi_flash_hpm_enable.c
../../components/spi_flash/spi_flash_os_func_noos.c
../../components/spi_flash/spi_flash_os_func_app.c
# todo: ../../components/spi_flash/spi_flash_wrap.c
../../components/spi_flash/spi_flash_wrap.c
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks like this is the only change in this commit which I had tried back in June (see zephyrproject-rtos/zephyr#73677 (comment)). If this works now, then it seems that the root cause was fixed in some other changes that have already been merged.

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

In fact, this change will only fix the issue together with this other PR being merged on the Zephyr side:
zephyrproject-rtos/zephyr#79286

@wmrsouza wmrsouza force-pushed the bugfix/QIO_mode branch 4 times, most recently from a4f5cfe to a3ed4dc Compare October 10, 2024 12:21
@wmrsouza wmrsouza changed the title bugfix: esp32s3: allows QIO and QOUT flash modes bugfix: esp32: allows QIO and QOUT flash modes Oct 10, 2024
Changes to allow QIO and QOUT flash mode to work in:
- esp32s2
- esp32s3
- esp32c2
- esp32c3
- esp32c6

Signed-off-by: Marcio Ribeiro <marcio.ribeiro@espressif.com>
@wmrsouza wmrsouza changed the title bugfix: esp32: allows QIO and QOUT flash modes Allows QIO and QOUT flash modes Oct 11, 2024
@sylvioalves sylvioalves merged commit 61a002a into zephyrproject-rtos:zephyr Oct 11, 2024
@wmrsouza wmrsouza deleted the bugfix/QIO_mode branch October 29, 2024 13:38
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants