dts/bindings: Add reset and irq gpios to "st,spbtle-rf" yaml

In order to generate GPIO definition for control pin of BlueNRG module
define reset-gpio and irq-gpio in st,spbtle-rf yaml binding.

Add HAS_DTS_SPI_PINS kconfig symbol to control use of the '#define'

Signed-off-by: Erwan Gouriou <erwan.gouriou@linaro.org>
This commit is contained in:
Erwan Gouriou 2018-05-04 16:15:29 +02:00 committed by Kumar Gala
commit 00376f08ca
3 changed files with 21 additions and 0 deletions

View file

@ -82,6 +82,8 @@ config BT_SPI_BLUENRG
Enable support for devices compatible with the BlueNRG Bluetooth Enable support for devices compatible with the BlueNRG Bluetooth
Stack. Current driver supports: ST X-NUCLEO BLE series. Stack. Current driver supports: ST X-NUCLEO BLE series.
if !HAS_DTS_SPI_PINS
config BT_SPI_CHIP_SELECT_DEV_NAME config BT_SPI_CHIP_SELECT_DEV_NAME
string "Chip Select (CS) line driver name" string "Chip Select (CS) line driver name"
depends on BT_SPI_BLUENRG depends on BT_SPI_BLUENRG
@ -118,6 +120,8 @@ config BT_SPI_RESET_PIN
help help
This option specifies the Reset line number on the SPI device This option specifies the Reset line number on the SPI device
endif # !HAS_DTS_SPI_PINS
config BT_SPI_MAX_CLK_FREQ config BT_SPI_MAX_CLK_FREQ
int "Maximum clock frequency for the HCI SPI interface" int "Maximum clock frequency for the HCI SPI interface"
default 5000000 default 5000000

View file

@ -43,6 +43,14 @@ config HAS_DTS_SPI_DEVICE
This option specifies that the target platform supports device tree This option specifies that the target platform supports device tree
configuration for spi devices, like sensors or RF modules. configuration for spi devices, like sensors or RF modules.
config HAS_DTS_SPI_PINS
bool
default n
help
This option specifies that the target platform supports device tree
configuration for pin definition of spi devices, like sensors or
RF modules.
config HAS_DTS_USB config HAS_DTS_USB
bool bool
default n default n

View file

@ -18,4 +18,13 @@ properties:
compatible: compatible:
constraint: "st,spbtle-rf" constraint: "st,spbtle-rf"
irq-gpios:
type: compound
category: required
generation: define, use-prop-name
reset-gpios:
type: compound
category: required
generation: define, use-prop-name
... ...