diff options
author | Bin Meng <bmeng.cn@gmail.com> | 2014-12-12 19:36:16 +0530 |
---|---|---|
committer | Simon Glass <sjg@chromium.org> | 2014-12-13 15:08:04 -0700 |
commit | 996467172e29e28247d8e9a35ada43a1376b5883 (patch) | |
tree | ea8bace6c613b6aeeea57f0a3c2a94e9fa4aaeda /drivers/spi/ich.c | |
parent | fa388bca3eb3f81f6412c69f0e15ab05ad4918a7 (diff) |
x86: ich-spi: Set the tx operation mode for ich 7
ICH 7 SPI controller only supports byte program (02h) for SST flash.
Word program (ADh) is not supported.
Signed-off-by: Bin Meng <bmeng.cn@gmail.com>
Reviewed-by: Jagannadha Sutradharudu Teki <jagannadh.teki@gmail.com>
Diffstat (limited to 'drivers/spi/ich.c')
-rw-r--r-- | drivers/spi/ich.c | 9 |
1 files changed, 7 insertions, 2 deletions
diff --git a/drivers/spi/ich.c b/drivers/spi/ich.c index b356411c36..16730ec33f 100644 --- a/drivers/spi/ich.c +++ b/drivers/spi/ich.c @@ -141,9 +141,14 @@ struct spi_slave *spi_setup_slave(unsigned int bus, unsigned int cs, ich->slave.max_write_size = ctlr.databytes; ich->speed = max_hz; - /* ICH 7 SPI controller only supports array read command */ - if (ctlr.ich_version == 7) + /* + * ICH 7 SPI controller only supports array read command + * and byte program command for SST flash + */ + if (ctlr.ich_version == 7) { ich->slave.op_mode_rx = SPI_OPM_RX_AS; + ich->slave.op_mode_tx = SPI_OPM_TX_BP; + } return &ich->slave; } |