drivers: flash: add Nordic JEDEC QSPI NOR flash driver
Most JEDEC NOR flash devices uses not only typical SPI mode
(MISO,MOSI,SCK and CS), but also QSPI mode (IO0,IO1,IO2,IO3,SCK and CS).
QSPI mode uses more data lines and as a result provide higher
throughput. If this were not enough, Nordic chips provide
hardware acceleration for read/write/erase functions, what
gives significant performance boost.
It does a lot of things "behind the scene", i.e when user has written
some data to the flash and would like to read them back, it has to wait
until the flash is ready by reading WIP bit in Status Register.
This driver does it automatically.
Signed-off-by: Kamil Lazowski <Kamil.Lazowski@nordicsemi.no>
2019-12-19 13:33:37 +01:00
|
|
|
# Copyright (c) 2019 Nordic Semiconductor ASA
|
|
|
|
# SPDX-License-Identifier: Apache-2.0
|
|
|
|
|
|
|
|
description: |
|
|
|
|
QSPI NOR flash supporting the JEDEC CFI interface.
|
|
|
|
|
|
|
|
compatible: "nordic,qspi-nor"
|
|
|
|
|
|
|
|
include: [base.yaml, "jedec,spi-nor-common.yaml"]
|
|
|
|
|
|
|
|
on-bus: qspi
|
|
|
|
|
|
|
|
properties:
|
|
|
|
reg:
|
|
|
|
required: true
|
|
|
|
|
2020-06-27 16:57:27 +02:00
|
|
|
jedec-id:
|
|
|
|
required: true
|
|
|
|
|
|
|
|
size:
|
2022-01-07 13:09:18 +01:00
|
|
|
type: int
|
|
|
|
description: |
|
|
|
|
The size in bits. Set this or size-in-bytes, but not both.
|
|
|
|
|
|
|
|
size-in-bytes:
|
|
|
|
type: int
|
|
|
|
description: |
|
|
|
|
The size in bytes. Set this or size, but not both.
|
2020-06-27 16:57:27 +02:00
|
|
|
|
2020-12-29 18:48:39 +01:00
|
|
|
# Match original driver NORDIC_QSPI_NOR_QE_BIT Kconfig default.
|
|
|
|
quad-enable-requirements:
|
|
|
|
default: "S1B6"
|
|
|
|
|
drivers: flash: add Nordic JEDEC QSPI NOR flash driver
Most JEDEC NOR flash devices uses not only typical SPI mode
(MISO,MOSI,SCK and CS), but also QSPI mode (IO0,IO1,IO2,IO3,SCK and CS).
QSPI mode uses more data lines and as a result provide higher
throughput. If this were not enough, Nordic chips provide
hardware acceleration for read/write/erase functions, what
gives significant performance boost.
It does a lot of things "behind the scene", i.e when user has written
some data to the flash and would like to read them back, it has to wait
until the flash is ready by reading WIP bit in Status Register.
This driver does it automatically.
Signed-off-by: Kamil Lazowski <Kamil.Lazowski@nordicsemi.no>
2019-12-19 13:33:37 +01:00
|
|
|
readoc:
|
|
|
|
type: string
|
|
|
|
enum:
|
2020-10-20 17:18:38 +02:00
|
|
|
- "fastread" # Single data line SPI, FAST_READ (0x0B)
|
2020-01-30 16:21:22 +01:00
|
|
|
- "read2o" # Dual data line SPI, READ2O (0x3B)
|
|
|
|
- "read2io" # Dual data line SPI, READ2IO (0xBB)
|
|
|
|
- "read4o" # Quad data line SPI, READ4O (0x6B)
|
|
|
|
- "read4io" # Quad data line SPI, READ4IO (0xEB)
|
drivers: flash: add Nordic JEDEC QSPI NOR flash driver
Most JEDEC NOR flash devices uses not only typical SPI mode
(MISO,MOSI,SCK and CS), but also QSPI mode (IO0,IO1,IO2,IO3,SCK and CS).
QSPI mode uses more data lines and as a result provide higher
throughput. If this were not enough, Nordic chips provide
hardware acceleration for read/write/erase functions, what
gives significant performance boost.
It does a lot of things "behind the scene", i.e when user has written
some data to the flash and would like to read them back, it has to wait
until the flash is ready by reading WIP bit in Status Register.
This driver does it automatically.
Signed-off-by: Kamil Lazowski <Kamil.Lazowski@nordicsemi.no>
2019-12-19 13:33:37 +01:00
|
|
|
description: |
|
|
|
|
Specify the number of data lines and opcode used for reading.
|
|
|
|
If not provided fastread will be selected.
|
|
|
|
|
|
|
|
writeoc:
|
|
|
|
type: string
|
|
|
|
enum:
|
2020-01-30 16:21:22 +01:00
|
|
|
- "pp" # Single data line SPI, PP (0x02)
|
|
|
|
- "pp2o" # Dual data line SPI, PP2O (0xA2)
|
2021-07-17 02:00:09 +02:00
|
|
|
- "pp4o" # Quad data line SPI, PP4O (0x32)
|
2020-01-30 16:21:22 +01:00
|
|
|
- "pp4io" # Quad data line SPI, PP4IO (0x38)
|
drivers: flash: add Nordic JEDEC QSPI NOR flash driver
Most JEDEC NOR flash devices uses not only typical SPI mode
(MISO,MOSI,SCK and CS), but also QSPI mode (IO0,IO1,IO2,IO3,SCK and CS).
QSPI mode uses more data lines and as a result provide higher
throughput. If this were not enough, Nordic chips provide
hardware acceleration for read/write/erase functions, what
gives significant performance boost.
It does a lot of things "behind the scene", i.e when user has written
some data to the flash and would like to read them back, it has to wait
until the flash is ready by reading WIP bit in Status Register.
This driver does it automatically.
Signed-off-by: Kamil Lazowski <Kamil.Lazowski@nordicsemi.no>
2019-12-19 13:33:37 +01:00
|
|
|
description: |
|
2020-05-15 23:36:40 +02:00
|
|
|
Specify the number of data lines and opcode used for writing.
|
drivers: flash: add Nordic JEDEC QSPI NOR flash driver
Most JEDEC NOR flash devices uses not only typical SPI mode
(MISO,MOSI,SCK and CS), but also QSPI mode (IO0,IO1,IO2,IO3,SCK and CS).
QSPI mode uses more data lines and as a result provide higher
throughput. If this were not enough, Nordic chips provide
hardware acceleration for read/write/erase functions, what
gives significant performance boost.
It does a lot of things "behind the scene", i.e when user has written
some data to the flash and would like to read them back, it has to wait
until the flash is ready by reading WIP bit in Status Register.
This driver does it automatically.
Signed-off-by: Kamil Lazowski <Kamil.Lazowski@nordicsemi.no>
2019-12-19 13:33:37 +01:00
|
|
|
If not provided pp will be selected.
|
|
|
|
|
|
|
|
address-size-32:
|
|
|
|
type: boolean
|
|
|
|
description: |
|
|
|
|
Set to indicate that 32-bit addressing is to be used.
|
|
|
|
If not specified 24-bit addressing will be used.
|
|
|
|
|
|
|
|
ppsize-512:
|
|
|
|
type: boolean
|
|
|
|
description: |
|
|
|
|
Set to indicate that the write opcode operates on 512-byte pages.
|
|
|
|
If not specified the write opcode operates on 256-byte pages.
|
|
|
|
|
|
|
|
sck-delay:
|
|
|
|
type: int
|
|
|
|
default: 0
|
|
|
|
description: |
|
|
|
|
Number of clock cycles CSn must be asserted before it can go low
|
|
|
|
again, specified in nanoseconds.
|
|
|
|
|
2021-07-03 01:02:25 +02:00
|
|
|
rx-delay:
|
|
|
|
type: int
|
|
|
|
description: |
|
|
|
|
Number of clock cycles from the rising edge of the SPI clock
|
|
|
|
until the input serial data is sampled.
|
|
|
|
|
drivers: flash: add Nordic JEDEC QSPI NOR flash driver
Most JEDEC NOR flash devices uses not only typical SPI mode
(MISO,MOSI,SCK and CS), but also QSPI mode (IO0,IO1,IO2,IO3,SCK and CS).
QSPI mode uses more data lines and as a result provide higher
throughput. If this were not enough, Nordic chips provide
hardware acceleration for read/write/erase functions, what
gives significant performance boost.
It does a lot of things "behind the scene", i.e when user has written
some data to the flash and would like to read them back, it has to wait
until the flash is ready by reading WIP bit in Status Register.
This driver does it automatically.
Signed-off-by: Kamil Lazowski <Kamil.Lazowski@nordicsemi.no>
2019-12-19 13:33:37 +01:00
|
|
|
cpha:
|
|
|
|
type: boolean
|
|
|
|
description: |
|
|
|
|
Set to indicate phase starts with asserted half-phase (CPHA=1).
|
|
|
|
For this driver using this property requires also using cpol.
|
|
|
|
|
|
|
|
cpol:
|
|
|
|
type: boolean
|
|
|
|
description: |
|
|
|
|
Set to indicate clock leading edge is falling (CPOL=1).
|
|
|
|
For this driver using this property requires also using cpha.
|
|
|
|
|
|
|
|
sck-frequency:
|
|
|
|
type: int
|
|
|
|
required: true
|
|
|
|
description: |
|
|
|
|
Maximum clock speed supported by the device, in Hz.
|