]> git.baikalelectronics.ru Git - kernel.git/commit
spi: core: Ignore unsupported Dual/Quad Transfer Mode bits
authorGeert Uytterhoeven <geert+renesas@glider.be>
Mon, 14 Apr 2014 17:39:53 +0000 (19:39 +0200)
committerMark Brown <broonie@linaro.org>
Fri, 18 Apr 2014 17:24:38 +0000 (18:24 +0100)
commit38ee3dacb41010b5f6f1c63924b5e967bbb0bcb8
treeb2ae5e910185145763a5a8a2a47628551147aba8
parent03a169e57a9a3fd69c1713c317a06f163ad63b5c
spi: core: Ignore unsupported Dual/Quad Transfer Mode bits

The availability of SPI Dual or Quad Transfer Mode as indicated by the
"spi-tx-bus-width" and "spi-rx-bus-width" properties in the device tree is
a hardware property of the SPI master, SPI slave, and board wiring.  Hence
the SPI core should not reject an SPI slave because an SPI master driver
doesn't (yet) support Dual or Quad Transfer Mode.

Change the lack of Dual or Quad Transfer Mode support in the SPI master
driver from an error condition to a warning condition, and ignore the
unsupported mode bits, falling back to Single Transfer Mode, to avoid
breakages when running old kernels with new device trees.

Fixes: fa747cdff8bf (spi: DUAL and QUAD support)
Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be>
Signed-off-by: Mark Brown <broonie@linaro.org>
Cc: stable@vger.kernel.org
drivers/spi/spi.c