diff options
author | Axel Lin <axel.lin@ingics.com> | 2014-01-17 05:53:40 -0500 |
---|---|---|
committer | Mark Brown <broonie@linaro.org> | 2014-01-17 10:54:22 -0500 |
commit | 23061f1eb844edd349c3a0f5f40e244c9d2abfde (patch) | |
tree | e7b8cc5fe643faac2472ddcf0fc14c3ef325be78 /drivers/spi/spi-topcliff-pch.c | |
parent | 81e53d0470878165a300d75ac06a5bc5eee543a2 (diff) |
spi: Remove duplicate code to set default bits_per_word setting
The implementation in spi_setup() already set spi->bits_per_word = 8 when
spi->bits_per_word is 0 before calling spi->master->setup.
So we don't need to do it again in setup() callback.
Signed-off-by: Axel Lin <axel.lin@ingics.com>
Acked-by: Marek Vasut <marex@denx.de>
Acked-by: Barry Song <Baohua.Song@csr.com>
Acked-by: Guenter Roeck <linux@roeck-us.net>
Signed-off-by: Mark Brown <broonie@linaro.org>
Diffstat (limited to 'drivers/spi/spi-topcliff-pch.c')
-rw-r--r-- | drivers/spi/spi-topcliff-pch.c | 6 |
1 files changed, 0 insertions, 6 deletions
diff --git a/drivers/spi/spi-topcliff-pch.c b/drivers/spi/spi-topcliff-pch.c index 446131308acb..9322de9e13fb 100644 --- a/drivers/spi/spi-topcliff-pch.c +++ b/drivers/spi/spi-topcliff-pch.c | |||
@@ -466,12 +466,6 @@ static void pch_spi_reset(struct spi_master *master) | |||
466 | 466 | ||
467 | static int pch_spi_setup(struct spi_device *pspi) | 467 | static int pch_spi_setup(struct spi_device *pspi) |
468 | { | 468 | { |
469 | /* check bits per word */ | ||
470 | if (pspi->bits_per_word == 0) { | ||
471 | pspi->bits_per_word = 8; | ||
472 | dev_dbg(&pspi->dev, "%s 8 bits per word\n", __func__); | ||
473 | } | ||
474 | |||
475 | /* Check baud rate setting */ | 469 | /* Check baud rate setting */ |
476 | /* if baud rate of chip is greater than | 470 | /* if baud rate of chip is greater than |
477 | max we can support,return error */ | 471 | max we can support,return error */ |