diff options
author | Stephen Warren <swarren@wwwdotorg.org> | 2013-05-21 22:36:35 -0400 |
---|---|---|
committer | Mark Brown <broonie@opensource.wolfsonmicro.com> | 2013-05-29 15:48:17 -0400 |
commit | 24778be20f87d5aadb19624fc768b3159fa43efc (patch) | |
tree | 05124574b6d331f34938bbae09d4014fde7dca76 /drivers/spi/spi-ath79.c | |
parent | 2922a8de996956893bb98e4aa91be9774c958336 (diff) |
spi: convert drivers to use bits_per_word_mask
Fill in the recently added spi_master.bits_per_word_mask field in as
many drivers as possible. Make related cleanups, such as removing any
redundant error-checking, or empty setup callbacks.
Signed-off-by: Stephen Warren <swarren@wwwdotorg.org>
Acked-by: H Hartley Sweeten <hsweeten@visionengravers.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Diffstat (limited to 'drivers/spi/spi-ath79.c')
-rw-r--r-- | drivers/spi/spi-ath79.c | 4 |
1 files changed, 1 insertions, 3 deletions
diff --git a/drivers/spi/spi-ath79.c b/drivers/spi/spi-ath79.c index e504b7636058..5e2d52ce387f 100644 --- a/drivers/spi/spi-ath79.c +++ b/drivers/spi/spi-ath79.c | |||
@@ -155,9 +155,6 @@ static int ath79_spi_setup(struct spi_device *spi) | |||
155 | { | 155 | { |
156 | int status = 0; | 156 | int status = 0; |
157 | 157 | ||
158 | if (spi->bits_per_word > 32) | ||
159 | return -EINVAL; | ||
160 | |||
161 | if (!spi->controller_state) { | 158 | if (!spi->controller_state) { |
162 | status = ath79_spi_setup_cs(spi); | 159 | status = ath79_spi_setup_cs(spi); |
163 | if (status) | 160 | if (status) |
@@ -226,6 +223,7 @@ static int ath79_spi_probe(struct platform_device *pdev) | |||
226 | 223 | ||
227 | pdata = pdev->dev.platform_data; | 224 | pdata = pdev->dev.platform_data; |
228 | 225 | ||
226 | master->bits_per_word_mask = SPI_BPW_RANGE_MASK(1, 32); | ||
229 | master->setup = ath79_spi_setup; | 227 | master->setup = ath79_spi_setup; |
230 | master->cleanup = ath79_spi_cleanup; | 228 | master->cleanup = ath79_spi_cleanup; |
231 | if (pdata) { | 229 | if (pdata) { |