]> git.baikalelectronics.ru Git - kernel.git/commit
iio: accel: bmg160: optimize transfers in trigger handler
authorIrina Tirdea <irina.tirdea@intel.com>
Thu, 24 Mar 2016 09:29:29 +0000 (11:29 +0200)
committerJonathan Cameron <jic23@kernel.org>
Sun, 3 Apr 2016 09:27:45 +0000 (10:27 +0100)
commit2067653bed7cf46f2f0eea2ac7b4adc66e5d9bb3
treeed9802fe70bcfb51ab11e27081a167628ad7e64a
parenteb36c09bb667b1fda688e4323073984884f01950
iio: accel: bmg160: optimize transfers in trigger handler

Some i2c busses (e.g.: Synopsys DesignWare I2C adapter) need to
enable/disable the bus at each i2c transfer and must wait for
the enable/disable to happen before sending the data.

When reading data in the trigger handler, the bmg160 gyro driver does
one bus transfer for each axis. This has an impact on the frequency
of the accelerometer at high sample rates due to additional delays
introduced by the bus at each transfer.

Reading all axis values in one bus transfer reduces the delays
introduced by the bus.

Signed-off-by: Irina Tirdea <irina.tirdea@intel.com>
Signed-off-by: Jonathan Cameron <jic23@kernel.org>
drivers/iio/gyro/bmg160_core.c