| #
2cf66459 |
| 21-Feb-2024 |
Jon Lin <jon.lin@rock-chips.com> |
mtd: spi: Support auto merge
In order to enable dual NOR flash users to experience double the capacity and avoid frequent switching between two NOR flash devices, the two NOR flash devices are virtu
mtd: spi: Support auto merge
In order to enable dual NOR flash users to experience double the capacity and avoid frequent switching between two NOR flash devices, the two NOR flash devices are virtualized into one device, which I name it auto_merge tech.
Change-Id: I5edd7cde0481b1de6a35fce7ac67068889ff5ffe Signed-off-by: Jon Lin <jon.lin@rock-chips.com>
show more ...
|
| #
fd4baaac |
| 15-Jul-2022 |
Jon Lin <jon.lin@rock-chips.com> |
spi: Add comment for SPI_DMA_PREPARE
Users are required to ensure cache consistency when use SPI_DMA_PREPARE
Change-Id: I0859c9898c1cb721e71aa1f1541a6702bc953c0e Signed-off-by: Jon Lin <jon.lin@roc
spi: Add comment for SPI_DMA_PREPARE
Users are required to ensure cache consistency when use SPI_DMA_PREPARE
Change-Id: I0859c9898c1cb721e71aa1f1541a6702bc953c0e Signed-off-by: Jon Lin <jon.lin@rock-chips.com>
show more ...
|
| #
9689b7dd |
| 14-Dec-2020 |
Ovidiu Panait <ovidiu.panait@windriver.com> |
UPSTREAM: spi: spi-uclass: Fix spi_claim_bus() speed/mode setup logic
Currently, when different spi slaves claim the bus consecutively using spi_claim_bus(), spi_set_speed_mode() will only be execut
UPSTREAM: spi: spi-uclass: Fix spi_claim_bus() speed/mode setup logic
Currently, when different spi slaves claim the bus consecutively using spi_claim_bus(), spi_set_speed_mode() will only be executed on the first two calls, leaving the bus in a bad state starting with the third call.
This patch drops spi_slave->speed member and adds caching of bus speed/mode in dm_spi_bus struct. It also updates spi_claim_bus() to call spi_set_speed_mode() if either speed or mode is different from what the bus is currently configured for. Current behavior is to only take into account the speed, but not the mode, which seems wrong.
Fixes: 60e2809a848 ("dm: spi: Avoid setting the speed with every transfer") Reviewed-by: Simon Glass <sjg@chromium.org> Reported-by: Rasmus Villemoes <rasmus.villemoes@prevas.dk> Reported-by: Moshe, Yaniv <yanivmo@amazon.com> Signed-off-by: Ovidiu Panait <ovidiu.panait@windriver.com> (cherry picked from commit 741280e9accd3da20650a04f716538944d878482) Change-Id: I29912ceaf1e252fe6f124aea69190ef5e6160119 Signed-off-by: Jon Lin <jon.lin@rock-chips.com>
show more ...
|
| #
305d7e6e |
| 05-Dec-2019 |
Vignesh Raghavendra <vigneshr@ti.com> |
UPSTREAM: mtd: spi-nor-core: Add octal mode support
Add support for Octal flash devices. Octal flash devices use 8 IO lines for data transfer. Currently only 1-1-8 Octal Read mode is supported.
Sig
UPSTREAM: mtd: spi-nor-core: Add octal mode support
Add support for Octal flash devices. Octal flash devices use 8 IO lines for data transfer. Currently only 1-1-8 Octal Read mode is supported.
Signed-off-by: Vignesh Raghavendra <vigneshr@ti.com> Reviewed-by: Jagan Teki <jagan@amarulasolutions.com> (cherry picked from commit 658df8bd946493e7fa7b0048a3a9bd658a1f4518) Change-Id: I1fabb494a963ceccb873c8a04fc3241eddd65069 Signed-off-by: Jon Lin <jon.lin@rock-chips.com>
show more ...
|
| #
5a1c4376 |
| 09-Sep-2019 |
Bin Meng <bmeng.cn@gmail.com> |
UPSTREAM: dm: spi: Check cs number before accessing slaves
Add chip select number check in spi_find_chip_select().
Change-Id: I13f3ec8f3f7e881e41a57638e6ae70ee4d0b82d5 Signed-off-by: Bin Meng <bmen
UPSTREAM: dm: spi: Check cs number before accessing slaves
Add chip select number check in spi_find_chip_select().
Change-Id: I13f3ec8f3f7e881e41a57638e6ae70ee4d0b82d5 Signed-off-by: Bin Meng <bmeng.cn@gmail.com> Tested-by: Jagan Teki <jagan@amarulasolutions.com> # SoPine Signed-off-by: Jon Lin <jon.lin@rock-chips.com> (cherry picked from commit 7bacce524d48594dae399f9ee9280ab105f6c8cf)
show more ...
|
| #
f75b9e50 |
| 07-Dec-2019 |
Simon Glass <sjg@chromium.org> |
UPSTREAM: spi: Correct operations check in dm_spi_xfer()
At present we have to have an xfer() method even if it does nothing. This is not correct, so fix it.
Signed-off-by: Simon Glass <sjg@chromiu
UPSTREAM: spi: Correct operations check in dm_spi_xfer()
At present we have to have an xfer() method even if it does nothing. This is not correct, so fix it.
Signed-off-by: Simon Glass <sjg@chromium.org> Reviewed-by: Bin Meng <bmeng.cn@gmail.com> (cherry picked from commit ccdabd8956936319c5f7112bf5774e839b085874) Change-Id: I49ef01fa907e48e09850364a400c9451783c8056 Signed-off-by: Jon Lin <jon.lin@rock-chips.com>
show more ...
|
| #
7ac3b0ed |
| 21-Oct-2019 |
Simon Glass <sjg@chromium.org> |
UPSTREAM: spi: Add support for memory-mapped flash
On x86 platforms the SPI flash can be mapped into memory so that the contents can be read with normal memory accesses.
Add a new SPI method to fin
UPSTREAM: spi: Add support for memory-mapped flash
On x86 platforms the SPI flash can be mapped into memory so that the contents can be read with normal memory accesses.
Add a new SPI method to find the location of the SPI flash in memory. This differs from the existing device-tree "memory-map" mechanism in that the location can be discovered at run-time.
Change-Id: Ia736a9119159bad4770073f19a8862e0ea2610e9 Signed-off-by: Simon Glass <sjg@chromium.org> Reviewed-by: Bin Meng <bmeng.cn@gmail.com> Signed-off-by: Jon Lin <jon.lin@rock-chips.com> (cherry picked from commit c53b318e1bad2e0d5c2b846fadfc79ec77bfc5f7)
show more ...
|
| #
a3171fa3 |
| 22-Jul-2019 |
Jagan Teki <jagan@amarulasolutions.com> |
UPSTREAM: spi: Add spi_write_then_read
Add support for SPI synchronous write followed by read, this is common interface call from spi-nor to spi drivers.
Reviewed-by: Simon Glass <sjg@chromium.org>
UPSTREAM: spi: Add spi_write_then_read
Add support for SPI synchronous write followed by read, this is common interface call from spi-nor to spi drivers.
Reviewed-by: Simon Glass <sjg@chromium.org> Change-Id: Id064c8a2703d409ca64399cef498f4c768e26ac0 Signed-off-by: Jagan Teki <jagan@amarulasolutions.com> Tested-by: Adam Ford <aford173@gmail.com> #da850-evm Signed-off-by: Jon Lin <jon.lin@rock-chips.com> (cherry picked from commit 8473b32127232d8b602d905a2ed26ed48d352f6e)
show more ...
|
| #
f5a32af5 |
| 30-Jun-2020 |
Jon Lin <jon.lin@rock-chips.com> |
spi: spi-mem: Support dma transfer skip waiting idle
Change-Id: Iabe9260f4c6c7edcb885f9f9a6aa55650fdfc932 Signed-off-by: Jon Lin <jon.lin@rock-chips.com>
|
| #
e806bc1c |
| 15-Jan-2018 |
Mario Six <mario.six@gdsys.cc> |
UPSTREAM: spi: Remove spi_setup_slave_fdt
A previous patch removed the spi_flash_probe_fdt function, which contained the last call of the spi_setup_slave_fdt function, which is now equally obsolete.
UPSTREAM: spi: Remove spi_setup_slave_fdt
A previous patch removed the spi_flash_probe_fdt function, which contained the last call of the spi_setup_slave_fdt function, which is now equally obsolete.
This patch removes the function.
Reviewed-by: Simon Glass <sjg@chromium.org> Reviewed-by: Jagan Teki <jagan@openedev.com> Change-Id: I0836438bec6597bb99038997ae6a549d647f1666 Signed-off-by: Mario Six <mario.six@gdsys.cc> Signed-off-by: Jon Lin <jon.lin@rock-chips.com> (cherry picked from commit 184fa1c8da54d3c5305b3e1975e284e01de68bea)
show more ...
|
| #
b91a110b |
| 15-Jan-2018 |
Mario Six <mario.six@gdsys.cc> |
UPSTREAM: spi: Remove obsolete spi_base_setup_slave_fdt
0efc024 ("spi_flash: Add spi_flash_probe_fdt() to locate SPI by FDT node") added a helper function spi_base_setup_slave_fdt to to set up a SPI
UPSTREAM: spi: Remove obsolete spi_base_setup_slave_fdt
0efc024 ("spi_flash: Add spi_flash_probe_fdt() to locate SPI by FDT node") added a helper function spi_base_setup_slave_fdt to to set up a SPI slave from a given FDT blob. The only user was the exynos SPI driver.
But commit 73186c9 ("dm: exynos: Convert SPI to driver model") removed the use of this function, hence rendering it obsolete.
Remove this function, as well as the CONFIG_OF_SPI option, which guarded only this function.
Reviewed-by: Simon Glass <sjg@chromium.org> Reviewed-by: Jagan Teki <jagan@openedev.com> Change-Id: I2a5bd866fda6d65b908c1f71160da59ab5332a15 Signed-off-by: Mario Six <mario.six@gdsys.cc> Signed-off-by: Jon Lin <jon.lin@rock-chips.com> (cherry picked from commit c5b88f29ba46997e1cae39153980cae475b87b82)
show more ...
|
| #
ee9b3572 |
| 27-Feb-2019 |
Patrick Delaunay <patrick.delaunay@st.com> |
UPSTREAM: dm: spi: Read default speed and mode values from DT
This patch update the behavior introduced by commit 96907c0fe50a ("dm: spi: Read default speed and mode values from DT")
In case of DT
UPSTREAM: dm: spi: Read default speed and mode values from DT
This patch update the behavior introduced by commit 96907c0fe50a ("dm: spi: Read default speed and mode values from DT")
In case of DT boot, don't read default speed and mode for SPI from CONFIG_* but instead read from DT node. This will make sure that boards with multiple SPI/QSPI controllers can be probed at different bus frequencies and SPI modes.
Remove also use in boards of the value speed=0 (no more supported) for ENV in SPI by using CONFIG_ENV_SPI_MAX_HZ=0.
DT values will be always used when available (full DM support of SPI slave with available DT node) even if speed and mode are requested; for example in splash screen support (in splash_sf_read_raw) or in SPL boot (in spl_spi_load_image). The caller of spi_get_bus_and_cs() no more need to force speed=0.
But the current behavior don't change if the SPI slave is not present (device with generic driver is created automatically) or if platdata is used (CONFIG_OF_PLATDATA).
Signed-off-by: Patrick Delaunay <patrick.delaunay@st.com> Acked-by: Jagan Teki <jagan@amarulasolutions.com> Change-Id: I6f5990b73f33815a7acb9b5da9c90dce48b6211d Signed-off-by: Jon Lin <jon.lin@rock-chips.com> (cherry picked from commit b0cc1b846fcb310c0ac2f8cbeb4ed5947dc52912)
show more ...
|
| #
967efcae |
| 16-Aug-2018 |
Boris Brezillon <boris.brezillon@bootlin.com> |
UPSTREAM: spi: Extend the core to ease integration of SPI memory controllers
Some controllers are exposing high-level interfaces to access various kind of SPI memories. Unfortunately they do not fit
UPSTREAM: spi: Extend the core to ease integration of SPI memory controllers
Some controllers are exposing high-level interfaces to access various kind of SPI memories. Unfortunately they do not fit in the current spi_controller model and usually have drivers placed in drivers/mtd/spi-nor which are only supporting SPI NORs and not SPI memories in general.
This is an attempt at defining a SPI memory interface which works for all kinds of SPI memories (NORs, NANDs, SRAMs).
Change-Id: I5b907d51232777b54366a589a75b3b1ce1f54dd2 Signed-off-by: Boris Brezillon <boris.brezillon@bootlin.com> Signed-off-by: Miquel Raynal <miquel.raynal@bootlin.com> Acked-by: Jagan Teki <jagan@openedev.com> Signed-off-by: Jon Lin <jon.lin@rock-chips.com> (cherry picked from commit e0bc8d8542f7bd34e5a6722d3ae41bcf9ca044af)
show more ...
|
| #
d2a88c91 |
| 23-Jan-2018 |
Álvaro Fernández Rojas <noltari@gmail.com> |
UPSTREAM: drivers: spi: consider command bytes when sending transfers
Command bytes are part of the written bytes and they should be taken into account when sending a spi transfer.
Change-Id: I8b38
UPSTREAM: drivers: spi: consider command bytes when sending transfers
Command bytes are part of the written bytes and they should be taken into account when sending a spi transfer.
Change-Id: I8b38a1c15cbfc5bc5394ca59e386ddff413210fc Signed-off-by: Álvaro Fernández Rojas <noltari@gmail.com> Reviewed-by: Simon Glass <sjg@chromium.org> Reviewed-by: Daniel Schwierzeck <daniel.schwierzeck@gmail.com> Reviewed-by: Jagan Teki <jagan@openedev.com> Signed-off-by: Jon Lin <jon.lin@rock-chips.com> (cherry picked from commit 6c94bd12c4adca45033ef89daafa66fbfc9acd17)
show more ...
|
| #
d68b9b84 |
| 23-Jan-2018 |
Álvaro Fernández Rojas <noltari@gmail.com> |
UPSTREAM: drivers: spi: allow limiting reads
For some SPI controllers it's not possible to keep the CS active between transfers and they are limited to a known number of bytes. This splits spi_flash
UPSTREAM: drivers: spi: allow limiting reads
For some SPI controllers it's not possible to keep the CS active between transfers and they are limited to a known number of bytes. This splits spi_flash reads into different iterations in order to respect the SPI controller limits.
Change-Id: I9e5621b1939829ff8f9ed7d4dca50bb87d27b2ef Signed-off-by: Álvaro Fernández Rojas <noltari@gmail.com> Reviewed-by: Simon Glass <sjg@chromium.org> Reviewed-by: Daniel Schwierzeck <daniel.schwierzeck@gmail.com> Reviewed-by: Jagan Teki <jagan@openedev.com> Signed-off-by: Jon Lin <jon.lin@rock-chips.com> (cherry picked from commit 8af74edc30bb60a90a5c4d2769ff3129b187796e)
show more ...
|
| #
279e26f5 |
| 19-May-2017 |
Simon Glass <sjg@chromium.org> |
dm: spi: Convert uclass to livetree
Update the SPI uclass to support a live device tree. Also adjust spi_slave_ofdata_to_platdata() to accept a device instead of a blob and offset.
Signed-off-by: S
dm: spi: Convert uclass to livetree
Update the SPI uclass to support a live device tree. Also adjust spi_slave_ofdata_to_platdata() to accept a device instead of a blob and offset.
Signed-off-by: Simon Glass <sjg@chromium.org>
show more ...
|
| #
2d221489 |
| 29-Nov-2016 |
Stefano Babic <sbabic@denx.de> |
Merge branch 'master' of git://git.denx.de/u-boot
Signed-off-by: Stefano Babic <sbabic@denx.de>
|
| #
081abb13 |
| 22-Nov-2016 |
Tom Rini <trini@konsulko.com> |
Merge branch 'master' of git://git.denx.de/u-boot-spi
|
| #
20343ff3 |
| 30-Oct-2016 |
Jagan Teki <jagan@openedev.com> |
spi: Remove dual flash options/flags
Dual flash code in spi are usually take the spi controller to work with dual connected flash devices. Usually these dual connection operation's are referred to f
spi: Remove dual flash options/flags
Dual flash code in spi are usually take the spi controller to work with dual connected flash devices. Usually these dual connection operation's are referred to flash controller protocol rather with spi controller protocol, these are still present in flash side for the usage of spi-nor controllers.
So, this patch remove the dual_flash options or flags in sf which are triggered from spi controller side.
Cc: Bin Meng <bmeng.cn@gmail.com> Cc: York Sun <york.sun@nxp.com> Cc: Vignesh R <vigneshr@ti.com> Cc: Mugunthan V N <mugunthanvnm@ti.com> Cc: Michal Simek <michal.simek@xilinx.com> Cc: Siva Durga Prasad Paladugu <sivadur@xilinx.com> Signed-off-by: Jagan Teki <jagan@openedev.com> Reviewed-by: Simon Glass <sjg@chromium.org> Reviewed-by: Jagan Teki <jagan@openedev.com>
show more ...
|
| #
19d051a2 |
| 22-Sep-2016 |
Tom Rini <trini@konsulko.com> |
Merge branch 'master' of git://git.denx.de/u-boot-spi
|
| #
3ac48d0e |
| 10-Aug-2016 |
Jagan Teki <jteki@openedev.com> |
spi: Remove SPI_RX_FAST
Removed SPI_RX_FAST since default read for spi slaves are always 1-wire fast read.
Cc: Simon Glass <sjg@chromium.org> Cc: Bin Meng <bmeng.cn@gmail.com> Cc: Michal Simek <mic
spi: Remove SPI_RX_FAST
Removed SPI_RX_FAST since default read for spi slaves are always 1-wire fast read.
Cc: Simon Glass <sjg@chromium.org> Cc: Bin Meng <bmeng.cn@gmail.com> Cc: Michal Simek <michal.simek@xilinx.com> Cc: Siva Durga Prasad Paladugu <sivadur@xilinx.com> Cc: Vignesh R <vigneshr@ti.com> Cc: Mugunthan V N <mugunthanvnm@ti.com> Signed-off-by: Jagan Teki <jteki@openedev.com>
show more ...
|
| #
08fe9c29 |
| 08-Aug-2016 |
Jagan Teki <jteki@openedev.com> |
spi: Use mode for rx mode flags
Make rx mode flags as generic to spi, earlier mode_rx is maintained separately because of some flash specific code.
Cc: Simon Glass <sjg@chromium.org> Cc: Bin Meng <
spi: Use mode for rx mode flags
Make rx mode flags as generic to spi, earlier mode_rx is maintained separately because of some flash specific code.
Cc: Simon Glass <sjg@chromium.org> Cc: Bin Meng <bmeng.cn@gmail.com> Cc: Michal Simek <michal.simek@xilinx.com> Cc: Siva Durga Prasad Paladugu <sivadur@xilinx.com> Cc: Vignesh R <vigneshr@ti.com> Cc: Mugunthan V N <mugunthanvnm@ti.com> Signed-off-by: Jagan Teki <jteki@openedev.com>
show more ...
|
| #
08ca213a |
| 24-May-2016 |
Stefano Babic <sbabic@denx.de> |
Merge branch 'master' of git://git.denx.de/u-boot
|
| #
4b6e1fda |
| 17-May-2016 |
Tom Rini <trini@konsulko.com> |
Merge git://git.denx.de/u-boot-dm
|
| #
7a3eff4c |
| 03-May-2016 |
Peng Fan <van.freenix@gmail.com> |
dm: spi: introduce dm api
Introduce dm_spi_claim_bus, dm_spi_release_bus and dm_spi_xfer Convert spi_claim_bus, spi_release_bus and spi_xfer to use the new API.
Signed-off-by: Peng Fan <van.freenix
dm: spi: introduce dm api
Introduce dm_spi_claim_bus, dm_spi_release_bus and dm_spi_xfer Convert spi_claim_bus, spi_release_bus and spi_xfer to use the new API.
Signed-off-by: Peng Fan <van.freenix@gmail.com> Cc: Simon Glass <sjg@chromium.org> Cc: Jagan Teki <jteki@openedev.com> Acked-by: Simon Glass <sjg@chromium.org>
show more ...
|