aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/spi/spi-atmel.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/spi/spi-atmel.c')
-rw-r--r--drivers/spi/spi-atmel.c9
1 files changed, 1 insertions, 8 deletions
diff --git a/drivers/spi/spi-atmel.c b/drivers/spi/spi-atmel.c
index 380387a47b1d..31cfc8711547 100644
--- a/drivers/spi/spi-atmel.c
+++ b/drivers/spi/spi-atmel.c
@@ -1268,13 +1268,6 @@ static int atmel_spi_setup(struct spi_device *spi)
1268 return -EINVAL; 1268 return -EINVAL;
1269 } 1269 }
1270 1270
1271 if (bits < 8 || bits > 16) {
1272 dev_dbg(&spi->dev,
1273 "setup: invalid bits_per_word %u (8 to 16)\n",
1274 bits);
1275 return -EINVAL;
1276 }
1277
1278 /* see notes above re chipselect */ 1271 /* see notes above re chipselect */
1279 if (!atmel_spi_is_v2(as) 1272 if (!atmel_spi_is_v2(as)
1280 && spi->chip_select == 0 1273 && spi->chip_select == 0
@@ -1515,7 +1508,7 @@ static int atmel_spi_probe(struct platform_device *pdev)
1515 1508
1516 /* the spi->mode bits understood by this driver: */ 1509 /* the spi->mode bits understood by this driver: */
1517 master->mode_bits = SPI_CPOL | SPI_CPHA | SPI_CS_HIGH; 1510 master->mode_bits = SPI_CPOL | SPI_CPHA | SPI_CS_HIGH;
1518 1511 master->bits_per_word_mask = SPI_BPW_RANGE_MASK(8, 16);
1519 master->dev.of_node = pdev->dev.of_node; 1512 master->dev.of_node = pdev->dev.of_node;
1520 master->bus_num = pdev->id; 1513 master->bus_num = pdev->id;
1521 master->num_chipselect = master->dev.of_node ? 0 : 4; 1514 master->num_chipselect = master->dev.of_node ? 0 : 4;