d0cff03e | 25-Jan-2015 |
Simon Glass <sjg@chromium.org> |
dm: spi: Move slave details to child platdata
At present we go through various contortions to store the SPI slave's chip select in its private data. This only exists when the slave is active so must
dm: spi: Move slave details to child platdata
At present we go through various contortions to store the SPI slave's chip select in its private data. This only exists when the slave is active so must be set up when it is probed. Until the device is probed we don't actually know what chip select it will appear on.
However, now that we can support per-child platform data, we can use that instead. This allows us to set up the chip select when the child is bound, and avoid the messy contortions.
Unfortunately this is a fairly large change and it seems to be difficult to break it down further.
Signed-off-by: Simon Glass <sjg@chromium.org>
show more ...
|
babe6994 | 18-Dec-2014 |
Adnan Ali <adnan.ali@codethink.co.uk> |
sf: sf_params: Add S25FL164K flash identifier info
Add the necessary flash entry for the Spansion S25FL164K flash. Tested on Marvell 88F6218 based design.
Signed-off-by: Ben Dooks <ben.dooks@codeth
sf: sf_params: Add S25FL164K flash identifier info
Add the necessary flash entry for the Spansion S25FL164K flash. Tested on Marvell 88F6218 based design.
Signed-off-by: Ben Dooks <ben.dooks@codethink.co.uk> Reviewed-by: Jagannadha Sutradharudu Teki <jagannadh.teki@gmail.com>
show more ...
|
cf156007 | 18-Dec-2014 |
Adnan Ali <adnan.ali@codethink.co.uk> |
sf: sf_params: Add S25FL116K flash support
Added S25FL116K flash and tested on Marvell 88F6281 based system.
Signed-off-by: Adnan Ali <adnan.ali@codethink.co.uk> Reviewed-by: Jagannadha Sutradharud
sf: sf_params: Add S25FL116K flash support
Added S25FL116K flash and tested on Marvell 88F6281 based system.
Signed-off-by: Adnan Ali <adnan.ali@codethink.co.uk> Reviewed-by: Jagannadha Sutradharudu Teki <jagannadh.teki@gmail.com>
show more ...
|
b45a3de0 | 18-Dec-2014 |
Shengzhou Liu <Shengzhou.Liu@freescale.com> |
mtd/spi: Add support for SST25WF040B
Add support for SST25WF040B-40I-SN flash. Tested on T1024QDS board.
Signed-off-by: Shengzhou Liu <Shengzhou.Liu@freescale.com> Reviewed-by: Jagannadha Sutradhar
mtd/spi: Add support for SST25WF040B
Add support for SST25WF040B-40I-SN flash. Tested on T1024QDS board.
Signed-off-by: Shengzhou Liu <Shengzhou.Liu@freescale.com> Reviewed-by: Jagannadha Sutradharudu Teki <jagannadh.teki@gmail.com>
show more ...
|
54ba653a | 12-Dec-2014 |
Jagannadha Sutradharudu Teki <jagannadh.teki@gmail.com> |
sf: Enable byte program support
Enabled byte program support for sst flashes in sf.
Few controllers will only support BP, so this patch gives a tx transfer flag to set the BP so-that sf will operat
sf: Enable byte program support
Enabled byte program support for sst flashes in sf.
Few controllers will only support BP, so this patch gives a tx transfer flag to set the BP so-that sf will operate on byte program transfer.
A new TX operation mode SPI_OPM_TX_BP is introduced for such SPI controller to use byte program op for SST flash.
Signed-off-by: Jagannadha Sutradharudu Teki <jagannadh.teki@gmail.com> Tested-by: Bin Meng <bmeng.cn@gmail.com>
show more ...
|
74c2cee4 | 12-Dec-2014 |
Bin Meng <bmeng.cn@gmail.com> |
spi: sf: Support byte program for sst spi flash
Currently if SST flash advertises SST_WP flag in the params table the word program command (ADh) with auto address increment will be used for the flas
spi: sf: Support byte program for sst spi flash
Currently if SST flash advertises SST_WP flag in the params table the word program command (ADh) with auto address increment will be used for the flash write op. However some SPI controllers do not support the word program command (like the Intel ICH 7), the byte programm command (02h) has to be used.
Signed-off-by: Bin Meng <bmeng.cn@gmail.com> Acked-by: Simon Glass <sjg@chromium.org> Tested-by: Simon Glass <sjg@chromium.org> Reviewed-by: Jagannadha Sutradharudu Teki <jagannadh.teki@gmail.com>
show more ...
|
b648742a | 12-Dec-2014 |
Simon Glass <sjg@chromium.org> |
spi: Fix flag collision for SST_WP
At present SECT_4K is the same as SST_WP so we cannot tell these apart. Fix this so that the table in sf_params.c can be used correctly.
Reported-by: Jens Rottman
spi: Fix flag collision for SST_WP
At present SECT_4K is the same as SST_WP so we cannot tell these apart. Fix this so that the table in sf_params.c can be used correctly.
Reported-by: Jens Rottmann <Jens.Rottmann@adlinktech.com> Signed-off-by: Simon Glass <sjg@chromium.org> Reviewed-by: Jagannadha Sutradharudu Teki <jagannadh.teki@gmail.com>
show more ...
|
6b18656a | 11-Nov-2014 |
Simon Glass <sjg@chromium.org> |
dm: spi: Use device_bind_driver() instead of our own function
The SPI function does the same thing, so we may as well just use the new generic function. The 'cs' parameter was not actually used, so
dm: spi: Use device_bind_driver() instead of our own function
The SPI function does the same thing, so we may as well just use the new generic function. The 'cs' parameter was not actually used, so can be dropped.
Signed-off-by: Simon Glass <sjg@chromium.org> Reviewed-by: Jagannadha Sutradharudu Teki <jagannadh.teki@gmail.com> Acked-by: Heiko Schocher <hs@denx.de>
show more ...
|
fbb09918 | 14-Oct-2014 |
Simon Glass <sjg@chromium.org> |
dm: Convert spi_flash_probe() and 'sf probe' to use driver model
We want the SPI flash probing feature to operate as a standard driver. Add a driver for the basic probing feature used by most boards
dm: Convert spi_flash_probe() and 'sf probe' to use driver model
We want the SPI flash probing feature to operate as a standard driver. Add a driver for the basic probing feature used by most boards. This will be activated by device_probe() as with any other driver.
The 'sf probe' command currently keeps track of the SPI slave that it last used. This doesn't work with driver model, since some other driver or system may have probed the device and have access to it too. On the other hand, if we try to probe a device twice the second probe is a nop with driver model.
Fix this by searching for the matching device, removing it, and then probing it again. This should work as expected regardless of other device activity.
Signed-off-by: Simon Glass <sjg@chromium.org> Reviewed-by: Jagannadha Sutradharudu Teki <jagannadh.teki@gmail.com>
show more ...
|
4c2dbefd | 14-Oct-2014 |
Simon Glass <sjg@chromium.org> |
dm: sf: Add a uclass for SPI flash
Add a driver model uclass for SPI flash which supports the common operations (read, write, erase). Since we must keep support for the non-dm interface, some modifi
dm: sf: Add a uclass for SPI flash
Add a driver model uclass for SPI flash which supports the common operations (read, write, erase). Since we must keep support for the non-dm interface, some modification of the spi_flash header is required.
CONFIG_DM_SPI_FLASH is used to enable driver model for SPI flash.
Signed-off-by: Simon Glass <sjg@chromium.org> Reviewed-by: Jagannadha Sutradharudu Teki <jagannadh.teki@gmail.com>
show more ...
|
ae242cbf | 14-Oct-2014 |
Simon Glass <sjg@chromium.org> |
spi: Use error return value in sf_ops
Adjust spi_flash_probe_slave() to return an error value instead of a pointer so we get the correct error return.
Have the caller allocate memory for spi_flash
spi: Use error return value in sf_ops
Adjust spi_flash_probe_slave() to return an error value instead of a pointer so we get the correct error return.
Have the caller allocate memory for spi_flash to simplify error handling, and also so that driver model can use its existing allocated memory.
Add a spi.h include in the sf_params file.
Signed-off-by: Simon Glass <sjg@chromium.org> Reviewed-by: Jagannadha Sutradharudu Teki <jagannadh.teki@gmail.com>
show more ...
|