提交 c3061abb 编写于 作者: B Bryan Wu 提交者: Linus Torvalds

spi: spi_bfin: bugfix for 8..16 bit word sizes

Fix bug in u16_cs_chg_reader to read data_len-2 bytes data firstly, then read
out the last 2 bytes data
Signed-off-by: NBryan Wu <bryan.wu@analog.com>
Signed-off-by: NDavid Brownell <dbrownell@users.sourceforge.net>
Signed-off-by: NAndrew Morton <akpm@linux-foundation.org>
Signed-off-by: NLinus Torvalds <torvalds@linux-foundation.org>
上级 bb90eb00
...@@ -501,7 +501,7 @@ static void u16_cs_chg_reader(struct driver_data *drv_data) ...@@ -501,7 +501,7 @@ static void u16_cs_chg_reader(struct driver_data *drv_data)
cs_active(drv_data, chip); cs_active(drv_data, chip);
dummy_read(drv_data); dummy_read(drv_data);
while (drv_data->rx < drv_data->rx_end) { while (drv_data->rx < drv_data->rx_end - 2) {
cs_deactive(drv_data, chip); cs_deactive(drv_data, chip);
if (chip->cs_chg_udelay) if (chip->cs_chg_udelay)
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册