Lines Matching +full:spi +full:- +full:compatible
1 // SPDX-License-Identifier: GPL-2.0-only
13 #include <linux/spi/spi.h>
21 * For new single-chip sensors use <device_name> as compatible string.
22 * For old single-chip devices keep <device_name>-press to maintain
27 .compatible = "st,lps001wp-press",
31 .compatible = "st,lps25h-press",
35 .compatible = "st,lps331ap-press",
39 .compatible = "st,lps22hb-press",
43 .compatible = "st,lps33hw",
47 .compatible = "st,lps35hw",
51 .compatible = "st,lps22hh",
55 .compatible = "st,lps22df",
62 static int st_press_spi_probe(struct spi_device *spi) in st_press_spi_probe() argument
69 st_sensors_dev_name_probe(&spi->dev, spi->modalias, sizeof(spi->modalias)); in st_press_spi_probe()
71 settings = st_press_get_settings(spi->modalias); in st_press_spi_probe()
73 dev_err(&spi->dev, "device name %s not recognized.\n", in st_press_spi_probe()
74 spi->modalias); in st_press_spi_probe()
75 return -ENODEV; in st_press_spi_probe()
78 indio_dev = devm_iio_device_alloc(&spi->dev, sizeof(*press_data)); in st_press_spi_probe()
80 return -ENOMEM; in st_press_spi_probe()
83 press_data->sensor_settings = (struct st_sensor_settings *)settings; in st_press_spi_probe()
85 err = st_sensors_spi_configure(indio_dev, spi); in st_press_spi_probe()
105 { "lps001wp-press" },
106 { "lps25h-press", },
107 { "lps331ap-press" },
108 { "lps22hb-press" },
111 MODULE_DEVICE_TABLE(spi, st_press_id_table);
115 .name = "st-press-spi",
124 MODULE_DESCRIPTION("STMicroelectronics pressures spi driver");