- 13 Jun, 2024 28 commits
-
-
Gustavo Silva authored
ENS160 supports a data ready interrupt. Use it in combination with triggered buffer for continuous data readings. Signed-off-by: Gustavo Silva <gustavograzs@gmail.com> Link: https://lore.kernel.org/r/20240604225747.7212-5-gustavograzs@gmail.comSigned-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
-
Gustavo Silva authored
ScioSense ENS160 is a digital metal oxide multi-gas sensor, designed for indoor air quality monitoring. The driver supports readings of CO2 and VOC, and can be accessed via both SPI and I2C. Datasheet: https://www.sciosense.com/wp-content/uploads/2023/12/ENS160-Datasheet.pdfSigned-off-by: Gustavo Silva <gustavograzs@gmail.com> Link: https://lore.kernel.org/r/20240604225747.7212-4-gustavograzs@gmail.comSigned-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
-
Gustavo Silva authored
Add bindings for ScioSense ENS160 multi-gas sensor. Datasheet: https://www.sciosense.com/wp-content/uploads/2023/12/ENS160-Datasheet.pdfReviewed-by: Conor Dooley <conor.dooley@microchip.com> Signed-off-by: Gustavo Silva <gustavograzs@gmail.com> Link: https://lore.kernel.org/r/20240604225747.7212-3-gustavograzs@gmail.comSigned-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
-
Gustavo Silva authored
Add vendor prefix for ScioSense B.V. https://www.sciosense.com/Acked-by: Conor Dooley <conor.dooley@microchip.com> Signed-off-by: Gustavo Silva <gustavograzs@gmail.com> Link: https://lore.kernel.org/r/20240604225747.7212-2-gustavograzs@gmail.comSigned-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
-
Dimitri Fedrau authored
The device has four programmable temperature alert outputs which can be used to monitor hot or cold-junction temperatures and detect falling and rising temperatures. It supports up to 255 degree celsius programmable hysteresis. Each alert can be individually configured by setting following options in the associated alert configuration register: - monitor hot or cold junction temperature - monitor rising or falling temperature - set comparator or interrupt mode - set output polarity - enable alert This patch binds alert outputs to iio events: - alert1: hot junction, rising temperature - alert2: hot junction, falling temperature - alert3: cold junction, rising temperature - alert4: cold junction, falling temperature All outputs are set in comparator mode and polarity depends on interrupt configuration. Signed-off-by: Dimitri Fedrau <dima.fedrau@gmail.com> Link: https://lore.kernel.org/r/20240604133639.959682-1-dima.fedrau@gmail.comSigned-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
-
Arthur Becker authored
Device tree bindings for the vishay VEML6040 RGBW light sensor iio driver Signed-off-by: Arthur Becker <arthur.becker@sentec.com> Reviewed-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org> Link: https://lore.kernel.org/r/20240604-veml6040-v4-2-5a4d59597874@sentec.comSigned-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
-
Arthur Becker authored
Implements driver for the Vishay VEML6040 rgbw light sensor. Included functionality: setting the integration time and reading the raw values for the four channels Not yet implemented: setting the measurements to 'Manual Force Mode' (Auto measurements off, and adding a measurement trigger) Datasheet: https://www.vishay.com/docs/84276/veml6040.pdfSigned-off-by: Arthur Becker <arthur.becker@sentec.com> Link: https://lore.kernel.org/r/20240604-veml6040-v4-1-5a4d59597874@sentec.comSigned-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
-
Neil Armstrong authored
On newer SoCs, the SAR ADC hardware can require a power-domain to operate, add it as optional. Signed-off-by: Neil Armstrong <neil.armstrong@linaro.org> Acked-by: Conor Dooley <conor.dooley@microchip.com> Link: https://lore.kernel.org/r/20240605-topic-amlogic-upstream-bindings-fixes-power-domains-sardac-v1-1-40a8de6baa59@linaro.orgSigned-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
-
Nuno Sa authored
Being this device a soft core, it's only supported on some/specific platforms. Hence add proper dependencies for the supported platforms. Also add COMPILE_TEST to increase the build coverage. Signed-off-by: Nuno Sa <nuno.sa@analog.com> Link: https://lore.kernel.org/r/20240604-dev-axi-dac-kconfig-v1-1-99ccd03938d1@analog.comSigned-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
-
Nuno Sa authored
Being this device a soft core, it's only supported on some/specific platforms. Hence add proper dependencies for the supported platforms. Also add COMPILE_TEST to increase the build coverage. Signed-off-by: Nuno Sa <nuno.sa@analog.com> Link: https://lore.kernel.org/r/20240604-dev-axi-adc-kconfig-v1-1-cfb725606b8e@analog.comSigned-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
-
Jean-Baptiste Maneyrol authored
Register caching is improving bus access a lot because of the register window bank setting. Previously, bank register was set for every register access. Now with caching, it happens only when changing bank which is very infrequent. Signed-off-by: Jean-Baptiste Maneyrol <jean-baptiste.maneyrol@tdk.com> Link: https://lore.kernel.org/r/20240607081039.789079-1-inv.git-commit@tdk.comSigned-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
-
Krzysztof Kozlowski authored
The driver calls spi_get_device_match_data() and on its failure calls again parts of it: spi_get_device_id() and getting driver data. This is entirely redundant, because it is part of spi_get_device_match_data(). Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org> Reviewed-by: Nuno Sa <nuno.sa@analog.com> Link: https://lore.kernel.org/r/20240606-spi-match-data-v1-8-320b291ee1fe@linaro.orgSigned-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
-
Krzysztof Kozlowski authored
Use spi_get_device_match_data() helper to simplify a bit the driver. Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org> Reviewed-by: Nuno Sa <nuno.sa@analog.com> Link: https://lore.kernel.org/r/20240606-spi-match-data-v1-7-320b291ee1fe@linaro.orgSigned-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
-
Krzysztof Kozlowski authored
Use spi_get_device_match_data() helper to simplify a bit the driver. Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org> Reviewed-by: Nuno Sa <nuno.sa@analog.com> Link: https://lore.kernel.org/r/20240606-spi-match-data-v1-6-320b291ee1fe@linaro.orgSigned-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
-
Krzysztof Kozlowski authored
Use spi_get_device_match_data() helper to simplify a bit the driver. Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org> Reviewed-by: Nuno Sa <nuno.sa@analog.com> Link: https://lore.kernel.org/r/20240606-spi-match-data-v1-5-320b291ee1fe@linaro.orgSigned-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
-
Krzysztof Kozlowski authored
Use spi_get_device_match_data() helper to simplify a bit the driver. Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org> Reviewed-by: Nuno Sa <nuno.sa@analog.com> Link: https://lore.kernel.org/r/20240606-spi-match-data-v1-4-320b291ee1fe@linaro.orgSigned-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
-
Krzysztof Kozlowski authored
Use spi_get_device_match_data() helper to simplify a bit the driver. Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org> Reviewed-by: Nuno Sa <nuno.sa@analog.com> Link: https://lore.kernel.org/r/20240606-spi-match-data-v1-3-320b291ee1fe@linaro.orgSigned-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
-
Krzysztof Kozlowski authored
Use spi_get_device_match_data() helper to simplify a bit the driver. Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org> Reviewed-by: Nuno Sa <nuno.sa@analog.com> Link: https://lore.kernel.org/r/20240606-spi-match-data-v1-2-320b291ee1fe@linaro.orgSigned-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
-
Krzysztof Kozlowski authored
Use spi_get_device_match_data() helper to simplify a bit the driver. Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org> Reviewed-by: Nuno Sa <nuno.sa@analog.com> Link: https://lore.kernel.org/r/20240606-spi-match-data-v1-1-320b291ee1fe@linaro.orgSigned-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
-
Uwe Kleine-König authored
These drivers don't use the driver_data member of struct i2c_device_id, so don't explicitly initialize this member. This prepares putting driver_data in an anonymous union which requires either no initialization or named designators. But it's also a nice cleanup on its own. Signed-off-by: Uwe Kleine-König <u.kleine-koenig@baylibre.com> Reviewed-by: Nuno Sa <nuno.sa@analog.com> Link: https://lore.kernel.org/r/20240606155407.499344-1-u.kleine-koenig@baylibre.comSigned-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
-
Antoni Pokusinski authored
This patch adds support for the integrated on-chip heater that is present on all the devices supported by this driver (si7020, si7021, si7013, th6). In order to configure the heater, the driver interacts with the following device registers: * User Register - the 2nd bit of this register is a "Heater Enable bit" (0 means that the heater is off, 1 means that it's on). * Heater Register - this register is present only on the si70xx devices and controls the current flowing through the heater. The 4 lower bits of this register can be assigned values from 0x0 to 0xF. Signed-off-by: Antoni Pokusinski <apokusinski01@gmail.com> Link: https://lore.kernel.org/r/20240607141029.51744-1-apokusinski@o2.plSigned-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
-
Jeff Johnson authored
make allmodconfig && make W=1 C=1 reports: WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/iio/adc/ingenic-adc.o WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/iio/adc/xilinx-ams.o WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/iio/buffer/kfifo_buf.o Add the missing invocations of the MODULE_DESCRIPTION() macro. Signed-off-by: Jeff Johnson <quic_jjohnson@quicinc.com> Link: https://lore.kernel.org/r/20240607-md-drivers-iic-v1-1-9f9db6246083@quicinc.comSigned-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
-
Erick Archer authored
It is preferred to use sizeof(*pointer) instead of sizeof(type) due to the type of the variable can change and one needs not change the former (unlike the latter). At the same time refactor the NULL comparison. This patch has no effect on runtime behavior. Signed-off-by: Erick Archer <erick.archer@outlook.com> Link: https://lore.kernel.org/r/AS8PR02MB7237D024459C314CECE72EAF8BFE2@AS8PR02MB7237.eurprd02.prod.outlook.comSigned-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
-
Aidan MacDonald authored
The AXP192 is identical to the AXP20x, except for the addition of two more GPIO ADC channels. Reviewed-by: Jonathan Cameron <Jonathan.Cameron@huawei.com> Reviewed-by: Andy Shevchenko <andy.shevchenko@gmail.com> Signed-off-by: Aidan MacDonald <aidanmacdonald.0x0@gmail.com> Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
-
Josua Mayer authored
TI tla2021 is a limited single-channel variant of tla2024 which is similar enough to be easily supportable through the same driver. Add compatible string for tla2021 so boards may describe it in device-tree. Signed-off-by: Josua Mayer <josua@solid-run.com> Acked-by: Conor Dooley <conor.dooley@microchip.com> Link: https://lore.kernel.org/r/20240602-cn9130-som-v6-3-89393e86d4c7@solid-run.comSigned-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
-
Gustavo Ueti Fukunaga authored
Make use of iio_device_claim_direct_scoped() to make error handling more natural and simplify code. Co-developed-by: Caio Dantas Simão Ugêda <caiodantas@usp.br> Signed-off-by: Caio Dantas Simão Ugêda <caiodantas@usp.br> Signed-off-by: Gustavo Ueti Fukunaga <gustavofukunaga@usp.br> Link: https://lore.kernel.org/r/20240527091942.53616-1-gustavofukunaga@usp.brSigned-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
-
Val Packett authored
Allow using the mount-matrix device tree property to align the accelerometer relative to the whole device. Signed-off-by: Val Packett <val@packett.cool> Link: https://lore.kernel.org/r/20240527080043.2709-1-val@packett.coolSigned-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
-
Julien Stephan authored
Some callbacks from iio_info structure are accessed without any check, so if a driver doesn't implement them trying to access the corresponding sysfs entries produce a kernel oops such as: [ 2203.527791] Unable to handle kernel NULL pointer dereference at virtual address 00000000 when execute [...] [ 2203.783416] Call trace: [ 2203.783429] iio_read_channel_info_avail from dev_attr_show+0x18/0x48 [ 2203.789807] dev_attr_show from sysfs_kf_seq_show+0x90/0x120 [ 2203.794181] sysfs_kf_seq_show from seq_read_iter+0xd0/0x4e4 [ 2203.798555] seq_read_iter from vfs_read+0x238/0x2a0 [ 2203.802236] vfs_read from ksys_read+0xa4/0xd4 [ 2203.805385] ksys_read from ret_fast_syscall+0x0/0x54 [ 2203.809135] Exception stack(0xe0badfa8 to 0xe0badff0) [ 2203.812880] dfa0: 00000003 b6f10f80 00000003 b6eab000 00020000 00000000 [ 2203.819746] dfc0: 00000003 b6f10f80 7ff00000 00000003 00000003 00000000 00020000 00000000 [ 2203.826619] dfe0: b6e1bc88 bed80958 b6e1bc94 b6e1bcb0 [ 2203.830363] Code: bad PC value [ 2203.832695] ---[ end trace 0000000000000000 ]--- Reviewed-by: Nuno Sa <nuno.sa@analog.com> Signed-off-by: Julien Stephan <jstephan@baylibre.com> Link: https://lore.kernel.org/r/20240530-iio-core-fix-segfault-v3-1-8b7cd2a03773@baylibre.comSigned-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
-
- 08 Jun, 2024 2 commits
-
-
Bruna Bispo authored
This fixes a checkpatch warning by changing the struct attribute from __attribute__((__packed__)) to __packed. Signed-off-by: Bruna Bispo <blbispo1@gmail.com> Link: https://lore.kernel.org/r/20240528143816.13409-1-blbispo1@gmail.comSigned-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
-
Ramona Gradinariu authored
Add documentation for adis16480 driver which describes the driver device files and shows how the user may use the ABI for various scenarios (configuration, measurement, etc.). Signed-off-by: Ramona Gradinariu <ramona.gradinariu@analog.com> Reviewed-by: Nuno Sa <nuno.sa@analog.com> Link: https://lore.kernel.org/r/20240528142409.239187-7-ramona.gradinariu@analog.comSigned-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
-
- 04 Jun, 2024 10 commits
-
-
Ramona Gradinariu authored
Add documentation for IIO interfacing tools describing the available tools which can be used to retrieve data from IIO sysfs. Reference this documentation in adis16475.rst Signed-off-by: Ramona Gradinariu <ramona.gradinariu@analog.com> Reviewed-by: Nuno Sa <nuno.sa@analog.com> Link: https://lore.kernel.org/r/20240528142409.239187-6-ramona.gradinariu@analog.comSigned-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
-
Ramona Gradinariu authored
The ADIS16545 and ADIS16547 are a complete inertial system that includes a triaxis gyroscope and a triaxis accelerometer. The serial peripheral interface (SPI) and register structure provide a simple interface for data collection and configuration control. These devices are similar to the ones already supported in the driver, with changes in the scales, timings and the max spi speed in burst mode. Also, they support delta angle and delta velocity readings in burst mode, for which support was added in the trigger handler. Co-developed-by: Nuno Sá <nuno.sa@analog.com> Signed-off-by: Ramona Gradinariu <ramona.gradinariu@analog.com> Reviewed-by: Nuno Sa <nuno.sa@analog.com> Link: https://lore.kernel.org/r/20240528142409.239187-5-ramona.gradinariu@analog.comSigned-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
-
Ramona Gradinariu authored
Add ADIS16545/47 compatibles. Each newly added device has a different angular velocity/linear acceleration scale combination, as follows: Accel dynamic range: - 8g: ADIS16545 - 40g: ADIS16547 Gyro dynamic range: - 125 deg/sec: ADIS1545-1, ADIS16547-1 - 450 deg/sec: ADIS1545-2, ADIS16547-2 - 2000 deg/sec: ADIS1545-3, ADIS16547-3 Signed-off-by: Ramona Gradinariu <ramona.gradinariu@analog.com> Reviewed-by: Conor Dooley <conor.dooley@microchip.com> Reviewed-by: Nuno Sa <nuno.sa@analog.com> Link: https://lore.kernel.org/r/20240528142409.239187-4-ramona.gradinariu@analog.comSigned-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
-
Ramona Gradinariu authored
Add support for delta angle and delta velocity raw readings to adis16480 driver. The following devices do not support delta readings in burst mode: ADIS16375, ADIS16480, ADIS16485, ADIS16488, ADIS16490, ADIS16495-1, ADIS16495-2, ADIS16495-3, ADIS16497-1, ADIS16497-2, ADIS16497-3, thus they cannot be retrieved via the buffer interface. For these devices, the delta measurements are retrieved by performing normal register readings and are made available through the raw attributes of the specific channels. Signed-off-by: Ramona Gradinariu <ramona.gradinariu@analog.com> Reviewed-by: Nuno Sa <nuno.sa@analog.com> Link: https://lore.kernel.org/r/20240528142409.239187-3-ramona.gradinariu@analog.comSigned-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
-
Ramona Gradinariu authored
With this, we can pass the maxixum spi burst speed to the 'ADIS16480_DATA()' macro. This is in preparation to support new devices that have a different speed than the one used so far. Co-developed-by: Nuno Sá <nuno.sa@analog.com> Signed-off-by: Ramona Gradinariu <ramona.gradinariu@analog.com> Reviewed-by: Nuno Sa <nuno.sa@analog.com> Link: https://lore.kernel.org/r/20240528142409.239187-2-ramona.gradinariu@analog.comSigned-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
-
Ramona Gradinariu authored
Add support for ADIS1657X family devices in already exiting ADIS16475 driver. Signed-off-by: Ramona Gradinariu <ramona.bolboaca13@gmail.com> Link: https://lore.kernel.org/r/20240527142618.275897-10-ramona.bolboaca13@gmail.comSigned-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
-
Ramona Gradinariu authored
Add ADIS1657X family devices compatibles and specify the according maximum SPI baudrate. Similarly to other ADIS1650X devices, ADIS1657X supports sync-mode values [0,2]. Each newly added device has a different angular velocity/linear acceleration/ delta velocity scale combination, as follows: Accel dynamic range sensitivity: - 262144000 LSB/g: ADIS16575 - 52428800 LSB/g: ADIS16576, ADIS16577 Gyro dynamic range sensitivity: - 2621440 LSB/deg/sec: ADIS1575-2, ADIS1576-2, ADIS1577-2 - 655360 LSB/deg/sec: ADIS1575-3, ADIS1576-3, ADIS1577-3 Delta velocity sensitivity: - 2^15/100 LSB/m/sec: ADIS16575 - 2^15/125 LSB/m/sec: ADIS16576 - 2^15/400 LSB/m/sec: ADIS16577 Each ADIS1657X device supports FIFO usage and a sample-rate of 4.1KHz, meanwhile the already existing devices do not support FIFO usage and have a maximum sample-rate of 2.1KHz. Reviewed-by: Conor Dooley <conor.dooley@microchip.com> Signed-off-by: Ramona Gradinariu <ramona.bolboaca13@gmail.com> Link: https://lore.kernel.org/r/20240527142618.275897-9-ramona.bolboaca13@gmail.comSigned-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
-
Ramona Gradinariu authored
Re-define ADIS16475_DATA such that it takes _burst_max_len, _burst_max_speed_hz and _has_fifo as parameters. Also, do a preparatory rename operation for ADIS16475_BURST32_MAX_DATA to ADIS16475_BURST32_MAX_DATA_NO_TS32 to be able to differentiate in the future between devices which are using 16-bit or 32-bit timestamp size in burst mode. Signed-off-by: Ramona Gradinariu <ramona.bolboaca13@gmail.com> Link: https://lore.kernel.org/r/20240527142618.275897-8-ramona.bolboaca13@gmail.comSigned-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
-
Ramona Gradinariu authored
Currently, adis library allows configuration only for edge interrupts, needed for data ready sampling. This patch removes the restriction for level interrupts for devices which have FIFO support. Furthermore, in case of devices which have FIFO support, devm_request_threaded_irq is used for interrupt allocation, to avoid flooding the processor with the FIFO watermark level interrupt, which is active until enough data has been read from the FIFO. Reviewed-by: Nuno Sa <nuno.sa@analog.com> Signed-off-by: Ramona Gradinariu <ramona.bolboaca13@gmail.com> Link: https://lore.kernel.org/r/20240527142618.275897-7-ramona.bolboaca13@gmail.comSigned-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
-
Ramona Gradinariu authored
Currently adis16475 supports a sample rate between 1900 and 2100 Hz. This patch changes the setting of sample rate from hardcoded values to a generic computation based on the internal clock frequency. This is a preparatory patch for adding support for adis1657x family devices which allow sample rates between 3900 and 4100 Hz. Reviewed-by: Nuno Sa <nuno.sa@analog.com> Signed-off-by: Ramona Gradinariu <ramona.bolboaca13@gmail.com> Link: https://lore.kernel.org/r/20240527142618.275897-6-ramona.bolboaca13@gmail.comSigned-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
-