summaryrefslogtreecommitdiff
path: root/drivers/platform
diff options
context:
space:
mode:
authorGreg Kroah-Hartman <gregkh@linuxfoundation.org>2020-07-17 12:04:05 +0200
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2020-07-17 12:04:05 +0200
commitf6b35db072dcf25365972503ade853960da5c984 (patch)
tree244ad967bfd5bc34a36ca1912d35f6a7a96ec70c /drivers/platform
parent419317021ccc8957d9cf11bf2500c2cff37ca6c7 (diff)
parent62a30a292a8283b3022b602964ff7484d5824841 (diff)
Merge tag 'iio-for-5.9a-take2' of git://git.kernel.org/pub/scm/linux/kernel/git/jic23/iio into staging-next
Jonathan writes: First set of new device support, cleanups and features for IIO in the 5.9 cycle Some new devices, but particularly good this time is the core rework coming from Alexandru. Some of this has been in Analog's tree a long time, but other parts are motivated by closing down common mistakes in new drivers. Changes since first try at this pull request: * Add missed patch to actually remove iio_priv_to_dev and as a result also drop a few ingenic patches that need to be updated to take this into account. * Fix an ordering issue int he pollfunc attach in the core rework. New device support * qcom pmic7 adc - New driver using common qcom-vadc library. Some associated cleanups and refactors. * invensense icm42600 - New driver supporting icm42600, icm42602, icm42605 and icm42622 via i2c or spi. These are all 6 axis IMUs with gyro and accelerometers. Driver supports buffered modes using the hardware fifo and interpolation for accurate timestamps. * sensirion scd30 - New driver for this carbon dioxide sensor including i2c and serial interfaces + bindings. Features * ak8975 - Add reset gpio support. * bma400 - Support SPI. * bmc150 - Document and add support for bmc156b and bmm150b, tidy up _magn endings. * bmi160 - Regulator and mount matrix support. * mxc4005 - Add ID for mxc6655 * rockchip-saradc - Triggered buffer support. DT bindings * qcom spmi-vadc converted to yaml + pmic7 bindings * ak8975 tidy up and convert to yaml + add reset-gpio binding * ingenic-adc -convert to yaml. Core rework all carried through by Alexandru Ardelean. * Assign parent device in the core rather than every driver. A few devices need to provide specific non standard parents, so there is support for overriding. * Start to take parts of struct iio_dev opaque to the drivers. This will be a long term job, but should reduce the number of drivers we get that use parts that are currently only 'internal' by documentation. * Move attach and detach of pollfunc to the core. Every triggered buffer using driver had to do the same thing, so lets do it in the core. The hard part here was getting all the drivers into canonical form so there would be no functional changes in this final patch. That's taken quite a lot of work over last couple of cycles! Cleanups and minor fixes. * docs - Improve IIO_CONCENTRATION channel type description in ABI docs. - Drop doubled word cases. - Http to Https conversion. * core - Make iio_device_get_drvdata take a const struct iio_dev * avoiding some nasty casts. * ADCs - Drop lots of users of of_match_ptr macro, includes of mod_devicetable.h and CONFIG_OF protections. These prevent use of ACPI PRP0001 with these drivers and get coppied into lots of new drivers. * ad5380 - Constify iio_chan_spec_ext_info * ad5592r - Constify iio_chan_spec_ext_info - Avoid use of iio_priv_to_dev (precursor to taking parts of iio_dev opaque) * ad8366 - Make gpio optional as doesn't matter if its there or not. * adis16480 - Use irq types instead of the flags. * atlas-ezo-sensor - Minimize scope of ret variable. * at91-adc - Add COMPILE_TEST dependency to driver to improve build coverage. - Avoid use of iio_priv_to_dev (precursor to taking parts of iio_dev opaque) * at91-sama5d2 - Avoid use of iio_priv_to_dev (precursor to taking parts of iio_dev opaque) - Drop Ludovic as a co-maintaienr. * cros_ec - Reapply the range after resume. - Add a read only frequency entry for legacy version. - Typo fixes * hts221 - Avoid use of iio_priv_to_dev (precursor to taking parts of iio_dev opaque) * inv_mpu - Drop double check on ACPI companion device. * iqs621 - Avoid use of iio_priv_to_dev (precursor to taking parts of iio_dev opaque) * iqs624 - Avoid use of iio_priv_to_dev (precursor to taking parts of iio_dev opaque) * max11100 - Constify iio_chan_spec * mmc35240 - Constify reg_default * rockchip-saradc - Move to managed allocators for everything in probe. - Use more distinctive prefix for channel macros. * stk3310 - Constify regmap_config. * stm32-adc - Avoid use of iio_priv_to_dev (precursor to taking parts of iio_dev opaque) * stm32-dfsdm-adc - Avoid use of iio_priv_to_dev (precursor to taking parts of iio_dev opaque) * ti-am335x - Use managed allocations where straight forward in probe function. * tsl2563 - Avoid use of iio_priv_to_dev (precursor to taking parts of iio_dev opaque) * tag 'iio-for-5.9a-take2' of git://git.kernel.org/pub/scm/linux/kernel/git/jic23/iio: (107 commits) iio: buffer: fix attach/detach pollfunc order iio: core: remove iio_priv_to_dev() helper Replace HTTP links with HTTPS ones: drivers/iio Replace HTTP links with HTTPS ones: Documentation/devicetree/bindings/iio dt-bindings: iio/adc: Convert ingenic-adc docs to YAML. iio: cros_ec_accel_legacy: Add Read Only frequency entries MAINTAINERS: adc: at91-sama5d2_adc: remove myself as co-maintainer iio: adc: ti_am335x_adc: alloc kfifo & IRQ via devm_ functions iio: adc: ti_am335x_adc: alloc channels via devm_kcalloc() iio:adc:ingenic: drop of_match_ptr protection and include mod_devicetable.h iio:adc:ti-tlc4541: Drop CONFIG_OF and of_match_ptr protections. iio:adc:ti-adc161s626: Drop of_match_ptr protection. iio:adc:ti-adc084s021: drop of_match_ptr protection iio:adc:ti-adc0832: drop CONFIG_OF and of_match_ptr protections iio:adc:ti-adc081c: Drop of_match_ptr and change to mod_devicetable.h iio:adc:sd_adc_modulator: Drop of_match_ptr and tweak includes iio:adc:mcp3422: remove CONFIG_OF and of_match_ptr protections iio:adc:mcp320x: Drop CONFIG_OF and of_match_ptr protections iio:adc:max1118: Drop CONFIG_OF / of_match_ptr protections iio:adc:max11100: Drop of_match_ptr protection / add mod_devicetable.h include ...
Diffstat (limited to 'drivers/platform')
-rw-r--r--drivers/platform/x86/toshiba_acpi.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/drivers/platform/x86/toshiba_acpi.c b/drivers/platform/x86/toshiba_acpi.c
index 1ddab5a6dead..36fff00af9eb 100644
--- a/drivers/platform/x86/toshiba_acpi.c
+++ b/drivers/platform/x86/toshiba_acpi.c
@@ -3114,7 +3114,7 @@ static int toshiba_acpi_add(struct acpi_device *acpi_dev)
toshiba_accelerometer_available(dev);
if (dev->accelerometer_supported) {
- dev->indio_dev = iio_device_alloc(sizeof(*dev));
+ dev->indio_dev = iio_device_alloc(&acpi_dev->dev, sizeof(*dev));
if (!dev->indio_dev) {
pr_err("Unable to allocate iio device\n");
goto iio_error;
@@ -3124,7 +3124,6 @@ static int toshiba_acpi_add(struct acpi_device *acpi_dev)
dev->indio_dev->info = &toshiba_iio_accel_info;
dev->indio_dev->name = "Toshiba accelerometer";
- dev->indio_dev->dev.parent = &acpi_dev->dev;
dev->indio_dev->modes = INDIO_DIRECT_MODE;
dev->indio_dev->channels = toshiba_iio_accel_channels;
dev->indio_dev->num_channels =