summaryrefslogtreecommitdiffstats
path: root/drivers/input/misc/ad714x-spi.c
diff options
context:
space:
mode:
authorMichael Hennerich <michael.hennerich@analog.com>2011-08-21 21:04:12 -0700
committerDmitry Torokhov <dmitry.torokhov@gmail.com>2011-08-22 09:59:06 -0700
commit5b9063b19caaffe7135e1f9b8b22174ded0f586b (patch)
treee93a30c0af580f3ea2a44049c6cec0b97f997931 /drivers/input/misc/ad714x-spi.c
parentb9cc510b395543cb7dba89c76421d23ed9e85f95 (diff)
downloadop-kernel-dev-5b9063b19caaffe7135e1f9b8b22174ded0f586b.zip
op-kernel-dev-5b9063b19caaffe7135e1f9b8b22174ded0f586b.tar.gz
Input: ad714xx-spi - force SPI bus into the default 8-bit mode
Signed-off-by: Michael Hennerich <michael.hennerich@analog.com> Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
Diffstat (limited to 'drivers/input/misc/ad714x-spi.c')
-rw-r--r--drivers/input/misc/ad714x-spi.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/drivers/input/misc/ad714x-spi.c b/drivers/input/misc/ad714x-spi.c
index 4120dd5..da83ac9 100644
--- a/drivers/input/misc/ad714x-spi.c
+++ b/drivers/input/misc/ad714x-spi.c
@@ -54,6 +54,12 @@ static int ad714x_spi_write(struct device *dev, unsigned short reg,
static int __devinit ad714x_spi_probe(struct spi_device *spi)
{
struct ad714x_chip *chip;
+ int err;
+
+ spi->bits_per_word = 8;
+ err = spi_setup(spi);
+ if (err < 0)
+ return err;
chip = ad714x_probe(&spi->dev, BUS_SPI, spi->irq,
ad714x_spi_read, ad714x_spi_write);
OpenPOWER on IntegriCloud