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

esp_psram: fix compile error for SPI PSRAM 2T mode (IDFGH-9149) #10546

Closed
wants to merge 1 commit into from

Conversation

yn386
Copy link
Contributor

@yn386 yn386 commented Jan 15, 2023

The following compile error occurred when SPI PSRAM 2T mode was enabled.

/opt/esp-idf/components/esp_psram/esp32/esp_psram_impl_quad.c: In function 'psram_2t_mode_enable':
/opt/esp-idf/components/esp_psram/esp32/esp_psram_impl_quad.c:593:5: error: implicit declaration of function 'GPIO_OUTPUT_SET'; did you mean 'GPIO_OUT_REG'? [-Werror=implicit-function-declaration]
  593 |     GPIO_OUTPUT_SET(D0WD_PSRAM_CS_IO, 1);
      |     ^~~~~~~~~~~~~~~
      |     GPIO_OUT_REG
cc1: some warnings being treated as errors

GPIO_OUTPUT_SET is defined here:

#define GPIO_OUTPUT_SET(gpio_no, bit_value) \
((gpio_no < 32) ? gpio_output_set(bit_value<<gpio_no, (bit_value ? 0 : 1)<<gpio_no, 1<<gpio_no,0) : \
gpio_output_set_high(bit_value<<(gpio_no - 32), (bit_value ? 0 : 1)<<(gpio_no - 32), 1<<(gpio_no -32),0))

but esp_psram_impl_quad.c does not include esp32/rom/gpio.h.

This PR fixes this compile error by including esp32/rom/gpio.h in esp_psram_impl_quad.c.

@CLAassistant
Copy link

CLAassistant commented Jan 15, 2023

CLA assistant check
All committers have signed the CLA.

@github-actions github-actions bot changed the title esp_psram: fix compile error for SPI PSRAM 2T mode esp_psram: fix compile error for SPI PSRAM 2T mode (IDFGH-9149) Jan 15, 2023
@espressif-bot espressif-bot added the Status: Opened Issue is new label Jan 15, 2023
@Alvin1Zhang
Copy link
Collaborator

Thanks for your contribution.

@suda-morris
Copy link
Collaborator

sha=fe068f9e001811077729715a2ba96632d4272bb0

@suda-morris suda-morris added the PR-Sync-Merge Pull request sync as merge commit label Jan 16, 2023
@espressif-bot espressif-bot added Status: Reviewing Issue is being reviewed Resolution: NA Issue resolution is unavailable Status: Done Issue is done internally Resolution: Done Issue is done internally and removed Status: Opened Issue is new Status: Reviewing Issue is being reviewed Resolution: NA Issue resolution is unavailable labels Feb 16, 2023
@AxelLin
Copy link
Contributor

AxelLin commented Apr 14, 2023

Merged in 4a09c18, why this PR is still in OPEN state?

@mahavirj mahavirj closed this Apr 17, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
PR-Sync-Merge Pull request sync as merge commit Resolution: Done Issue is done internally Status: Done Issue is done internally
Projects
None yet
Development

Successfully merging this pull request may close these issues.

8 participants