drivers: sensor: bme280: respect devicetree cs-gpios flags

Forward flags cell from cs-gpios devicetree property into device SPI
configuration.

Signed-off-by: Peter Bigot <peter.bigot@nordicsemi.no>
This commit is contained in:
Peter Bigot 2020-07-06 15:25:45 -05:00 committed by Kumar Gala
commit 2036bbcde4

View file

@ -604,7 +604,11 @@ done:
#define BME280_HAS_CS(inst) DT_INST_SPI_DEV_HAS_CS_GPIOS(inst)
#define BME280_DATA_SPI_CS(inst) \
{ .spi_cs = { .gpio_pin = DT_INST_SPI_DEV_CS_GPIOS_PIN(inst), }, }
{ .spi_cs = { \
.gpio_pin = DT_INST_SPI_DEV_CS_GPIOS_PIN(inst), \
.gpio_dt_flags = DT_INST_SPI_DEV_CS_GPIOS_FLAGS(inst), \
}, \
}
#define BME280_DATA_SPI(inst) \
COND_CODE_1(BME280_HAS_CS(inst), \