]> git.baikalelectronics.ru Git - kernel.git/commit
spi: Allow SPI controller override device buswidth
authorJohn Garry <john.garry@huawei.com>
Fri, 28 Feb 2020 15:18:49 +0000 (23:18 +0800)
committerMark Brown <broonie@kernel.org>
Fri, 28 Feb 2020 18:01:42 +0000 (18:01 +0000)
commit9363e58a67fbae489900fe7433cc15c8e25e39f0
tree6e41d9f9d35c2a9a6f803843f93fe3150ca9e13d
parentbf214e33adc048f37fdb0ee346e212d1e26645b2
spi: Allow SPI controller override device buswidth

Currently ACPI firmware description for a SPI device does not have any
method to describe the data buswidth on the board.

So even through the controller and device may support higher modes than
standard SPI, it cannot be assumed that the board does - as such, that
device is limited to standard SPI in such a circumstance.

As a workaround, allow the controller driver supply buswidth override bits,
which are used inform the core code that the controller driver knows the
buswidth supported on that board for that device.

A host controller driver might know this info from DMI tables, for example.

Signed-off-by: John Garry <john.garry@huawei.com>
Link: https://lore.kernel.org/r/1582903131-160033-2-git-send-email-john.garry@huawei.com
Signed-off-by: Mark Brown <broonie@kernel.org>
drivers/spi/spi.c
include/linux/spi/spi.h