Skip to content

Commit 967b89a

Browse files
ulfalizeravisconti
authored andcommitted
sensors: lps2hh: Fix misspelled GPIOS_CONTROLLER references
DT_INST_0_ST_LPS22HH_CS_GPIO_CONTROLLER should be DT_INST_0_ST_LPS22HH_CS_GPIOS_CONTROLLER, which is the name generated by gen_defines.py. Discovered while working on unrelated removing of special-casing for clocks. Co-authored-by: Armando Visconti <[email protected]> Signed-off-by: Ulf Magnusson <[email protected]>
1 parent 7fc0486 commit 967b89a

File tree

3 files changed

+6
-6
lines changed

3 files changed

+6
-6
lines changed

drivers/sensor/lps22hh/lps22hh.c

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -211,9 +211,9 @@ static const struct lps22hh_config lps22hh_config = {
211211
SPI_MODE_CPHA | SPI_WORD_SET(8) |
212212
SPI_LINES_SINGLE),
213213
.spi_conf.slave = DT_INST_0_ST_LPS22HH_BASE_ADDRESS,
214-
#if defined(DT_INST_0_ST_LPS22HH_CS_GPIO_CONTROLLER)
215-
.gpio_cs_port = DT_INST_0_ST_LPS22HH_CS_GPIO_CONTROLLER,
216-
.cs_gpio = DT_INST_0_ST_LPS22HH_CS_GPIO_PIN,
214+
#if defined(DT_INST_0_ST_LPS22HH_CS_GPIOS_CONTROLLER)
215+
.gpio_cs_port = DT_INST_0_ST_LPS22HH_CS_GPIOS_CONTROLLER,
216+
.cs_gpio = DT_INST_0_ST_LPS22HH_CS_GPIOS_PIN,
217217

218218
.spi_conf.cs = &lps22hh_data.cs_ctrl,
219219
#else

drivers/sensor/lps22hh/lps22hh.h

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,7 @@ struct lps22hh_config {
4141
u16_t i2c_slv_addr;
4242
#elif DT_ST_LPS22HH_BUS_SPI
4343
struct spi_config spi_conf;
44-
#if defined(DT_INST_0_ST_LPS22HH_CS_GPIO_CONTROLLER)
44+
#if defined(DT_INST_0_ST_LPS22HH_CS_GPIOS_CONTROLLER)
4545
const char *gpio_cs_port;
4646
u8_t cs_gpio;
4747
#endif
@@ -79,7 +79,7 @@ struct lps22hh_data {
7979
#endif
8080

8181
#endif /* CONFIG_LPS22HH_TRIGGER */
82-
#if defined(DT_INST_0_ST_LPS22HH_CS_GPIO_CONTROLLER)
82+
#if defined(DT_INST_0_ST_LPS22HH_CS_GPIOS_CONTROLLER)
8383
struct spi_cs_control cs_ctrl;
8484
#endif
8585
};

drivers/sensor/lps22hh/lps22hh_spi.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -105,7 +105,7 @@ int lps22hh_spi_init(struct device *dev)
105105
data->ctx = &data->ctx_spi;
106106
data->ctx->handle = dev;
107107

108-
#if defined(DT_INST_0_ST_LPS22HH_CS_GPIO_CONTROLLER)
108+
#if defined(DT_INST_0_ST_LPS22HH_CS_GPIOS_CONTROLLER)
109109
const struct lps22hh_config *cfg = dev->config->config_info;
110110

111111
/* handle SPI CS thru GPIO if it is the case */

0 commit comments

Comments
 (0)