diff options
author | Mark A. Greer <mgreer@animalcreek.com> | 2014-09-02 15:12:17 -0700 |
---|---|---|
committer | Samuel Ortiz <sameo@linux.intel.com> | 2014-09-07 23:13:42 +0200 |
commit | 24707296c762d1828c4a51aa1872dc275dc3fccc (patch) | |
tree | 284cfa02797d75ef9a8eb0c2d101e2ed46b9dfda /drivers/nfc/trf7970a.c | |
parent | cc8d7158644c439d946bfc65778a507b6f12b10d (diff) |
NFC: trf7970a: Call spi_setup() to configure SPI communication
Call spi_setup() to configure SPI communication
with the trf7970a. This will ensure that the
correct SPI parameters are used.
Signed-off-by: Mark A. Greer <mgreer@animalcreek.com>
Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
Diffstat (limited to 'drivers/nfc/trf7970a.c')
-rw-r--r-- | drivers/nfc/trf7970a.c | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/drivers/nfc/trf7970a.c b/drivers/nfc/trf7970a.c index 509acac26af..159b0a3f965 100644 --- a/drivers/nfc/trf7970a.c +++ b/drivers/nfc/trf7970a.c @@ -1272,6 +1272,12 @@ static int trf7970a_probe(struct spi_device *spi) spi->mode = SPI_MODE_1; spi->bits_per_word = 8; + ret = spi_setup(spi); + if (ret < 0) { + dev_err(trf->dev, "Can't set up SPI Communication\n"); + return ret; + } + if (of_property_read_bool(np, "irq-status-read-quirk")) trf->quirks |= TRF7970A_QUIRK_IRQ_STATUS_READ; |