30 Aug, 2016

12 commits

  • Replace my previous employer address.

    Signed-off-by: Vlad Dogaru
    Signed-off-by: Jonathan Cameron

    Vlad Dogaru
     
  • We get 2 warnings when biuld kernel with W=1:
    drivers/iio/common/st_sensors/st_sensors_trigger.c:69:13: warning: no previous prototype
    for 'st_sensors_irq_handler' [-Wmissing-prototypes]
    drivers/iio/common/st_sensors/st_sensors_trigger.c:85:13: warning: no previous prototype
    for 'st_sensors_irq_thread' [-Wmissing-prototypes]

    In fact, these functions are only used in the file in which they are
    declared and don't need a declaration, but can be made static.
    so this patch marks these functions with 'static'.

    Signed-off-by: Baoyou Xie
    Reviewed-by: Linus Walleij
    Signed-off-by: Jonathan Cameron

    Baoyou Xie
     
  • Remove .owner field if calls are used which set it automatically.

    Generated by: scripts/coccinelle/api/platform_no_drv_owner.cocci

    Signed-off-by: Wei Yongjun
    Acked-by: Linus Walleij
    Signed-off-by: Jonathan Cameron

    Wei Yongjun
     
  • The ak8974_configure() function is used only from the PM code,
    but that can be hidden when CONFIG_PM is disabled:

    drivers/iio/magnetometer/ak8974.c:201:12: error: 'ak8974_configure' defined but not used [-Werror=unused-function]

    This replaces the #ifdef with a __maybe_unused annotation, which
    will work correctly in all configurations and avoid the warning,
    as the compiler can now see where ak8974_configure is called from.

    Signed-off-by: Arnd Bergmann
    Fixes: 7c94a8b2ee8c ("iio: magn: add a driver for AK8974")
    Signed-off-by: Jonathan Cameron

    Arnd Bergmann
     
  • A small rework of the PM code in this driver introduced a harmless
    warning when CONFIG_PM_SLEEP is not set:

    drivers/iio/common/hid-sensors/hid-sensor-trigger.c:212:12: error: 'hid_sensor_resume' defined but not used [-Werror=unused-function]

    This removes the #ifdef and instead marks all three PM functions
    as __maybe_unused, which covers all possible cases and is harder
    to get wrong.

    Signed-off-by: Arnd Bergmann
    Fixes: 7f6cf7414538 ("iio: hid-sensors: use asynchronous resume")
    Signed-off-by: Jonathan Cameron

    Arnd Bergmann
     
  • When terminating for_each_child_of_node() iteration with
    break or return, of_node_put() should be used to prevent
    stale device node references from being left behind.

    This is detected by Coccinelle semantic patch.

    Signed-off-by: Wei Yongjun
    Signed-off-by: Jonathan Cameron

    Wei Yongjun
     
  • Fixes the following sparse warnings:

    drivers/iio/temperature/maxim_thermocouple.c:35:28: warning:
    symbol 'max6675_channels' was not declared. Should it be static?
    drivers/iio/temperature/maxim_thermocouple.c:52:28: warning:
    symbol 'max31855_channels' was not declared. Should it be static?
    drivers/iio/temperature/maxim_thermocouple.c:98:38: warning:
    symbol 'maxim_thermocouple_chips' was not declared. Should it be static?

    Signed-off-by: Wei Yongjun
    Reviewed-By: Matt Ranostay
    Signed-off-by: Jonathan Cameron

    Wei Yongjun
     
  • These sensors all have Vdd and Vdd_IO lines. This means the
    supplies are *not* optional (optional means that the supply is
    optional in the electrical sense, not the software sense)
    so we need to get the and enable them at all times.

    If the device tree or board file does not define suitable
    regulators for the component, it will be substituted by a
    dummy regulator, or, if regulators are disabled altogether,
    by stubs. There is no need to use the IS_ERR_OR_NULL() check
    that is considered harmful.

    Cc: Giuseppe Barba
    Cc: Denis Ciocca
    Cc: Crestez Dan Leonard
    Cc: Gregor Boirie
    Cc: Mark Brown
    Signed-off-by: Linus Walleij
    Signed-off-by: Jonathan Cameron

    Linus Walleij
     
  • Add support for Analog Devices AD8801/AD8803, 8 channels 8bits, Digital to
    Analog converters.

    Signed-off-by: Gwenhael Goavec-Merou
    Signed-off-by: Jonathan Cameron

    Gwenhael Goavec-Merou
     
  • Signed-off-by: Matt Ranostay
    Signed-off-by: Jonathan Cameron

    Matt Ranostay
     
  • Add support the VZ89TE variant which removes the voc_short channel,
    and has CRC check for data transactions.

    Signed-off-by: Matt Ranostay
    Signed-off-by: Jonathan Cameron

    Matt Ranostay
     
  • Abstract chip configuration data to allow supporting multiple variants
    of the VZ89 chemical sensor line.

    Signed-off-by: Matt Ranostay
    Signed-off-by: Jonathan Cameron

    Matt Ranostay
     

29 Aug, 2016

4 commits

  • Adds basic support for the LTC2485 ADC - a delta-sigma analog-to-digital
    converter with an I2C interface that operates in single shot conversion
    mode.

    The driver supports an on board 5V reference and the power-on default
    configuration which rejects both 50hz & 60hz line frequencies and
    operates in 1x speed mode.

    Signed-off-by: Alison Schofield
    Cc: Daniel Baluta
    Signed-off-by: Jonathan Cameron

    Alison Schofield
     
  • fix checkpatch.pl warning about 'Statements should start on a
    tabstop'

    Signed-off-by: Clifton Barnes
    Signed-off-by: Jonathan Cameron

    Clifton Barnes
     
  • Now there are channel modifiers with their own scaling those should be
    used when possible over the generic channel type scaling.

    Examples are of IIO_TEMP channel having a generic scaling value, and
    another having IIO_MOD_TEMP_AMBIENT modifier with another scaling value.

    Previously the first scaling value for a channel type would be applied
    to all channels of like type in iio_generic_buffer

    Signed-off-by: Matt Ranostay
    Signed-off-by: Jonathan Cameron

    Matt Ranostay
     
  • The comparison for devnr limits is off-by-one, the current check
    allows 0 to AD5755_NUM_CHANNELS and the limit should be in fact
    0 to AD5755_NUM_CHANNELS - 1. This can lead to an out of bounds
    write to pdata->dac[devnr]. Fix this by replacing > with >= on the
    comparison.

    Signed-off-by: Colin Ian King
    Fixes: c947459979c6 ("iio: ad5755: add support for dt bindings")
    Signed-off-by: Jonathan Cameron

    Colin Ian King
     

24 Aug, 2016

1 commit

  • …iio into work-testing

    Jonathan writes:

    First round of new features, device support and cleanups for IIO in the 4.9 cycle.

    Device support

    * ak8974
    - New driver and bindings for this 2009 vintage magnetometer (it was very
    popular back then!)
    * atlas-ph-sensor
    - ORP sensor support(I had to look up what one of these was)
    * cio-dac
    - New driver for Measurement Computing DAC boards
    * dmard06
    - New driver for Domintech DMARDO6 accelerometer. Also vendor prefix.
    * dmard09
    - New driver for Domintech DMARD09 accelerometer.
    * maxim-thermocouple
    - max6675 and max31855 new driver
    * mt6577 auxdac
    - new driver for this Mediatek chip mt2701, mt6577 and mt8173 have this
    hardware.
    * ti-adc161s626
    - new driver for this TI single channel differential ADC.
    * vcnl4000
    - support vcnl4010 and vcnl4020 which are compatible for all features
    currently supported by this driver.

    New features

    * Core
    - Allow retrieving of underlying iio_dev from a callback buffer handle.
    This is needed to allow client drivers to perform operations such as
    configuring the trigger used.
    * hid-sensors
    - asynchronous resume support to avoid really long resume times.
    * kxcjk-1013
    - add the mysterious KIOX000A ACPI id seen in the wild.
    * Tools
    - lsiio now enumerates processed as well as raw channels.

    Cleanup

    * ad7298
    - use iio_device_claim_direct_mode and friends to simplify locking around
    mode switching and drop some boilerplate.
    * ad7793
    - use iio_device_claim_direct_mode and friends to simplify locking around
    mode switching and drop some boilerplate.
    * ade7854
    - checkpatch fixups (alignment of parameters)
    * atlas-ph-sensor
    - use iio_device_claim_direct_mode and friends to simplify locking around
    mode switching and drop some boilerplate.
    - Switch to REGCACHE_NONE as there are no useful register to cache.
    * bma180
    - use iio_device_claim_direct_mode and friends to simplify locking around
    mode switching and drop some boilerplate.
    * hdc100x
    - Add mention of the HDC1000 and HDC1008 to the Kconfig help text.
    * isl29018
    - Add driver specific prefixes to defines and function names.
    - Remove excessive logging.
    - Drop newlines which add nothing to readability.
    - General tidying up of comments.
    - Drop I2C_CLASS_HWMON as irrelevant to driver.
    * isl29028
    - Add driver specific prefixes to defines, enums and function names.
    - Drop comma's from available attribute output as not ABI compliant.
    - Drop I2C_CLASS_HWMON as irrelevant to driver.
    * kxsd9
    - devicetree bindings.
    * mag3110
    - This one wasn't locking to protect against mode switches during
    raw_reads. Use the iio_claim_direct_mode function to fix this buglet.
    * maxim-theromcouple
    - Fix missing selects for triggered buffer support in Kconfig.
    * nau7802
    - Use complete instead of complete_all as only one completion at a time.
    * sx9500
    - Use complete instead of complete_all as only one completion at a time.
    * us5182d
    - Add a missing error code asignment instead of checking the result of
    an already checked statement.
    * vcnl4000
    - Use BIT macro where appropriate.
    - Refactor return codes in read_raw callback.
    - Add some missing locking for concurrent accesses to the device.

    Greg Kroah-Hartman
     

23 Aug, 2016

2 commits


22 Aug, 2016

21 commits