summaryrefslogtreecommitdiff
path: root/Documentation
diff options
context:
space:
mode:
authorGreg Kroah-Hartman <gregkh@linuxfoundation.org>2015-01-21 10:13:37 +0800
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2015-01-21 10:13:37 +0800
commit6e49557b316e8db983a6d40d18e88ab0ba8571ef (patch)
treeded6ad6cdaace89769d7a3464fd0170f4d4471b8 /Documentation
parente60088575bcbaf8d71a0e9f1d44fbf136f95e2cd (diff)
parentdf1fad80dfa0a7644b525c4a0dd8f2be21f57358 (diff)
Merge tag 'iio-for-3.20a_take2' of git://git.kernel.org/pub/scm/linux/kernel/git/jic23/iio into staging-testing
Jonathan writes: First round of IIO new drivers, cleanups and functionality for the 3.20 cycle take 2 Updated pull request with Daniel's fix on top for the power management Kconfig changes that had snuck in since last update of the IIO tree worked it's way through from mainline. Original pull message New device support * jsa1212 proxmity / ambient light sensor * SM08500 supported added to the kxcjk-1013 accelerometer driver * KMX61 Accelerometer/Magnetometer. This took a somewhat rocky path being first merged, then reverted for a rewrite after a discussion of how to support additional functionality and finally being merged prior to some last reviews coming in, with resultant follow up patches. * Freescale mma9551l driver (minor follow up warning supression patch). * Semtech SX9500 proximity device driver. * ak8975 gains support for ak09911 and ak09912 and drop the standalone driver for the ak09911. New functionality * Dummy driver gains some virtual registers making it more flexible. * IIO_ACTIVITY channel types, with modifiers running, walking etc. This is to support on chip motion clasifiers. As such it is in the form of a confidence percentage. The only devices so far only do binary decisions but this gives us room when other devices give more nuanced clasification. * IIO_EV_DIR_NONE type for events where there is no obvious direction. First case is step detection. * IIO_STEPS channel type for pedometers. * ENABLE mask element used to control turning on counting types such as the pedometer that need a 'start point'. * INSTANCE event type to support things that happen once. * info element for height calibration (used in various motion estimation algorithms). Note heigh tof use * dummy driver demonstration of the use of all the new bits above. * event monitor support for the new events. * inv_mpu6050 gains an i2c mux to allow bypassing the device to access additional devices connected on the other side of it. Note that in Windows these are handled by firmware on the device and not exposed directly. * inv_mpu6050 gains ACPI enumeration. * inkern interface gains iio_write_channel_raw to allow in kernel users of DAC functionality via a simple wrapper. * Document input current readings in the ABI docs. * Add an error message when we get an out of range error in device tree processing for the in kernel interfaces. Basically a device tree debugging aid. * Add a sanity check that a scan index for a channel is unique during registration. There to help catch bugs as this should never happen in a bug free driver. Cleanups and fixlets A rework of buffer registration from Lars - a precursor to some other upcoming new stuff (a few patches from others rolled in here as well). * Ensure all drivers register the same channels for the device and buffer. * Move buffer registration into the core rather than using the old two step approach. Now we have simple ways of using a unified set channels for both without requiring channels be exposed by both interface, this removes a fair bit of boilerplate. * Stop sca3000 and ad5933 (both in staging) enabling buffer channels by default. It has long be convention in IIO to startup with no channels enabled and leave it up to userspace to say what goes in the buffer. Getting rid of these allows us to drop export of iio_scan_mask_set. * Drop get_bytes_per_datum from iio_buffer_access_funcs as not been used for a while. * Allocate standard buffer attributes in the core rather than in every driver with a buffer. * Make the length attribute read only when a driver is not able to set the length. * Drop the get_length callback for buffers as it is already available in struct iio_buffer. * Drop an unused arguement form iio_kfifo_allocate and add devm allocator for it. * some kconfig entries gain anotation with the resulting module name. * Fix a resulting compile issue in dummy driver due to a stub taking wrong parameters as a result of the above rework. * Fix an off by 2 error in copying the core assigned buffer attributes. Other cleanups, * Trivial space before comma fixups. * ak8975 fixlets - none critical. Rework to allow more device support. * Drop unnecessary sizeof(u8) calls. * bmp280 - refactor the compensation code to reduce copy operations and code length. A second patch futher optimized this and performed some other minor cleanups. * kxcjk-1013 - various power control cleanups to avoid unnecessary enable / disable of device. Make sure it is only controlled at all if CONFIG_PM is enabled. Also som cleanups of error paths. * Small cleanups in adf4530 driver - pointless message and unnecessary braces. * Clarifiy the proximity ABI docs to make it clear it should get bigger as we move futher away. * Drop a misleading comment form industrialio-core.c * Trivial white space cleanups. * sca3000 looses an unused debug function. * Fix char unsigned ordering in ad8366 * Increase the sleep time in ad9523 to make it predictable (value didn't really matter so make it more than 20 msecs) * mxs-lradc touchscreen property cleanups in device tree are fixed to ensure the meet all the 'interesting' documentation. * A couple of cleanups for the staging ad5933 driver to avoid unnecessary conversion to a processed temperature vlaue in kernel and remove platform data form the state structure as not needed after probe. * Fix a wrong scale factor in the docs. Misc * Add IIO include files to the maintainers entry.
Diffstat (limited to 'Documentation')
-rw-r--r--Documentation/ABI/testing/sysfs-bus-iio95
-rw-r--r--Documentation/devicetree/bindings/staging/iio/adc/mxs-lradc.txt4
-rw-r--r--Documentation/driver-model/devres.txt2
3 files changed, 98 insertions, 3 deletions
diff --git a/Documentation/ABI/testing/sysfs-bus-iio b/Documentation/ABI/testing/sysfs-bus-iio
index 117521dbf2b3..831db8623e4b 100644
--- a/Documentation/ABI/testing/sysfs-bus-iio
+++ b/Documentation/ABI/testing/sysfs-bus-iio
@@ -92,6 +92,18 @@ Description:
is required is a consistent labeling. Units after application
of scale and offset are millivolts.
+What: /sys/bus/iio/devices/iio:deviceX/in_currentY_raw
+What: /sys/bus/iio/devices/iio:deviceX/in_currentY_supply_raw
+KernelVersion: 3.17
+Contact: linux-iio@vger.kernel.org
+Description:
+ Raw (unscaled no bias removal etc.) current measurement from
+ channel Y. In special cases where the channel does not
+ correspond to externally available input one of the named
+ versions may be used. The number must always be specified and
+ unique to allow association with event codes. Units after
+ application of scale and offset are milliamps.
+
What: /sys/bus/iio/devices/iio:deviceX/in_capacitanceY_raw
KernelVersion: 3.2
Contact: linux-iio@vger.kernel.org
@@ -234,6 +246,8 @@ What: /sys/bus/iio/devices/iio:deviceX/in_accel_y_offset
What: /sys/bus/iio/devices/iio:deviceX/in_accel_z_offset
What: /sys/bus/iio/devices/iio:deviceX/in_voltageY_offset
What: /sys/bus/iio/devices/iio:deviceX/in_voltage_offset
+What: /sys/bus/iio/devices/iio:deviceX/in_currentY_offset
+What: /sys/bus/iio/devices/iio:deviceX/in_current_offset
What: /sys/bus/iio/devices/iio:deviceX/in_tempY_offset
What: /sys/bus/iio/devices/iio:deviceX/in_temp_offset
What: /sys/bus/iio/devices/iio:deviceX/in_pressureY_offset
@@ -262,6 +276,9 @@ What: /sys/bus/iio/devices/iio:deviceX/in_voltage_scale
What: /sys/bus/iio/devices/iio:deviceX/in_voltage-voltage_scale
What: /sys/bus/iio/devices/iio:deviceX/out_voltageY_scale
What: /sys/bus/iio/devices/iio:deviceX/out_altvoltageY_scale
+What: /sys/bus/iio/devices/iio:deviceX/in_currentY_scale
+What: /sys/bus/iio/devices/iio:deviceX/in_currentY_supply_scale
+What: /sys/bus/iio/devices/iio:deviceX/in_current_scale
What: /sys/bus/iio/devices/iio:deviceX/in_accel_scale
What: /sys/bus/iio/devices/iio:deviceX/in_accel_peak_scale
What: /sys/bus/iio/devices/iio:deviceX/in_anglvel_scale
@@ -323,6 +340,14 @@ Description:
production inaccuracies). If shared across all channels,
<type>_calibscale is used.
+What: /sys/bus/iio/devices/iio:deviceX/in_steps_calibheight
+KernelVersion: 3.19
+Contact: linux-iio@vger.kernel.org
+Description:
+ Height of the user (in centimeters) used by some pedometers
+ to compute the stride length, distance, speed and activity
+ type.
+
What: /sys/bus/iio/devices/iio:deviceX/in_accel_scale_available
What: /sys/.../iio:deviceX/in_voltageX_scale_available
What: /sys/.../iio:deviceX/in_voltage-voltage_scale_available
@@ -790,6 +815,40 @@ Description:
met before an event is generated. If direction is not
specified then this period applies to both directions.
+What: /sys/.../events/in_activity_still_thresh_rising_en
+What: /sys/.../events/in_activity_still_thresh_falling_en
+What: /sys/.../events/in_activity_walking_thresh_rising_en
+What: /sys/.../events/in_activity_walking_thresh_falling_en
+What: /sys/.../events/in_activity_jogging_thresh_rising_en
+What: /sys/.../events/in_activity_jogging_thresh_falling_en
+What: /sys/.../events/in_activity_running_thresh_rising_en
+What: /sys/.../events/in_activity_running_thresh_falling_en
+KernelVersion: 3.19
+Contact: linux-iio@vger.kernel.org
+Description:
+ Enables or disables activitity events. Depending on direction
+ an event is generated when sensor ENTERS or LEAVES a given state.
+
+What: /sys/.../events/in_activity_still_thresh_rising_value
+What: /sys/.../events/in_activity_still_thresh_falling_value
+What: /sys/.../events/in_activity_walking_thresh_rising_value
+What: /sys/.../events/in_activity_walking_thresh_falling_value
+What: /sys/.../events/in_activity_jogging_thresh_rising_value
+What: /sys/.../events/in_activity_jogging_thresh_falling_value
+What: /sys/.../events/in_activity_running_thresh_rising_value
+What: /sys/.../events/in_activity_running_thresh_falling_value
+KernelVersion: 3.19
+Contact: linux-iio@vger.kernel.org
+Description:
+ Confidence value (in units as percentage) to be used
+ for deciding when an event should be generated. E.g for
+ running: If the confidence value reported by the sensor
+ is greater than in_activity_running_thresh_rising_value
+ then the sensor ENTERS running state. Conversely, if the
+ confidence value reported by the sensor is lower than
+ in_activity_running_thresh_falling_value then the sensor
+ is LEAVING running state.
+
What: /sys/.../iio:deviceX/events/in_accel_mag_en
What: /sys/.../iio:deviceX/events/in_accel_mag_rising_en
What: /sys/.../iio:deviceX/events/in_accel_mag_falling_en
@@ -822,6 +881,13 @@ Description:
number or direction is not specified, applies to all channels of
this type.
+What: /sys/.../events/in_steps_instance_en
+KernelVersion: 3.19
+Contact: linux-iio@vger.kernel.org
+Description:
+ Enables or disables step detection. Each time the user takes a step an
+ event of this type will be generated.
+
What: /sys/bus/iio/devices/iio:deviceX/trigger/current_trigger
KernelVersion: 2.6.35
Contact: linux-iio@vger.kernel.org
@@ -956,6 +1022,16 @@ Description:
and the relevant _type attributes to establish the data storage
format.
+What: /sys/.../iio:deviceX/in_activity_still_input
+What: /sys/.../iio:deviceX/in_activity_walking_input
+What: /sys/.../iio:deviceX/in_activity_jogging_input
+What: /sys/.../iio:deviceX/in_activity_running_input
+KernelVersion: 3.19
+Contact: linux-iio@vger.kernel.org
+Description:
+ This attribute is used to read the confidence for an activity
+ expressed in units as percentage.
+
What: /sys/.../iio:deviceX/in_anglvel_z_quadrature_correction_raw
KernelVersion: 2.6.38
Contact: linux-iio@vger.kernel.org
@@ -992,7 +1068,9 @@ Description:
reflectivity of infrared or ultrasound emitted.
Often these sensors are unit less and as such conversion
to SI units is not possible. Where it is, the units should
- be meters.
+ be meters. If such a conversion is not possible, the reported
+ values should behave in the same way as a distance, i.e. lower
+ values indicate something is closer to the sensor.
What: /sys/.../iio:deviceX/in_illuminanceY_input
What: /sys/.../iio:deviceX/in_illuminanceY_raw
@@ -1051,3 +1129,18 @@ Description:
after application of scale and offset. If no offset or scale is
present, output should be considered as processed with the
unit in milliamps.
+
+What: /sys/.../iio:deviceX/in_steps_en
+KernelVersion: 3.19
+Contact: linux-iio@vger.kernel.org
+Description:
+ Activates the step counter. After activation, the number of steps
+ taken by the user will be counted in hardware and exported through
+ in_steps_input.
+
+What: /sys/.../iio:deviceX/in_steps_input
+KernelVersion: 3.19
+Contact: linux-iio@vger.kernel.org
+Description:
+ This attribute is used to read the number of steps taken by the user
+ since the last reboot while activated.
diff --git a/Documentation/devicetree/bindings/staging/iio/adc/mxs-lradc.txt b/Documentation/devicetree/bindings/staging/iio/adc/mxs-lradc.txt
index ee05dc390694..307537787574 100644
--- a/Documentation/devicetree/bindings/staging/iio/adc/mxs-lradc.txt
+++ b/Documentation/devicetree/bindings/staging/iio/adc/mxs-lradc.txt
@@ -12,9 +12,9 @@ Optional properties:
property is not present, then the touchscreen is
disabled. 5 wires is valid for i.MX28 SoC only.
- fsl,ave-ctrl: number of samples per direction to calculate an average value.
- Allowed value is 1 ... 31, default is 4
+ Allowed value is 1 ... 32, default is 4
- fsl,ave-delay: delay between consecutive samples. Allowed value is
- 1 ... 2047. It is used if 'fsl,ave-ctrl' > 1, counts at
+ 2 ... 2048. It is used if 'fsl,ave-ctrl' > 1, counts at
2 kHz and its default is 2 (= 1 ms)
- fsl,settling: delay between plate switch to next sample. Allowed value is
1 ... 2047. It counts at 2 kHz and its default is
diff --git a/Documentation/driver-model/devres.txt b/Documentation/driver-model/devres.txt
index b5ab416cd53a..6d1e8eeb5990 100644
--- a/Documentation/driver-model/devres.txt
+++ b/Documentation/driver-model/devres.txt
@@ -258,6 +258,8 @@ IIO
devm_iio_device_free()
devm_iio_device_register()
devm_iio_device_unregister()
+ devm_iio_kfifo_allocate()
+ devm_iio_kfifo_free()
devm_iio_trigger_alloc()
devm_iio_trigger_free()