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

drivers: qspi: added operation timeout #66711

Merged
merged 1 commit into from
Jan 9, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 9 additions & 0 deletions drivers/flash/Kconfig.nordic_qspi_nor
Original file line number Diff line number Diff line change
Expand Up @@ -50,4 +50,13 @@ config NORDIC_QSPI_NOR_XIP
QSPI NOR flash chip is executed until the driver has been setup.
This will also disable power management for the QSPI NOR flash chip.

config NORDIC_QSPI_NOR_TIMEOUT_MS
int "Timeout for QSPI operations (ms)"
default 500
help
The QSPI peripheral operation timeout in milliseconds.
Primarily intended for long running operations such as
a flash sector erase. The 500 ms default allows for
most typical NOR flash chips to erase a sector.

endif # NORDIC_QSPI_NOR
1 change: 1 addition & 0 deletions drivers/flash/nrf_qspi_nor.c
Original file line number Diff line number Diff line change
Expand Up @@ -1382,6 +1382,7 @@ static const struct qspi_nor_config qspi_nor_dev_config = {
.sck_delay = DT_INST_PROP(0, sck_delay),
.spi_mode = INST_0_SPI_MODE,
},
.nrfx_cfg.timeout = CONFIG_NORDIC_QSPI_NOR_TIMEOUT_MS,

.size = INST_0_BYTES,
.id = DT_INST_PROP(0, jedec_id),
Expand Down
Loading