<feed xmlns='http://www.w3.org/2005/Atom'>
<title>kernel.git/drivers/iio/adc, branch linux-5.12.y</title>
<subtitle>Hosts the 0x221E linux distro kernel.
</subtitle>
<id>https://git.0xinfinity.dev/distro/kernel.git/atom?h=linux-5.12.y</id>
<link rel='self' href='https://git.0xinfinity.dev/distro/kernel.git/atom?h=linux-5.12.y'/>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/'/>
<updated>2021-07-14T15:00:21Z</updated>
<entry>
<title>iio: adc: ti-ads8688: Fix alignment of buffer in iio_push_to_buffers_with_timestamp()</title>
<updated>2021-07-14T15:00:21Z</updated>
<author>
<name>Jonathan Cameron</name>
</author>
<published>2021-06-13T15:22:57Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=a65024fc5754f2fca73541373a2502bef603565b'/>
<id>urn:sha1:a65024fc5754f2fca73541373a2502bef603565b</id>
<content type='text'>
[ Upstream commit 61fa5dfa5f52806f5ce37a0ba5712c271eb22f98 ]

Add __aligned(8) to ensure the buffer passed to
iio_push_to_buffers_with_timestamp() is suitable for the naturally
aligned timestamp that will be inserted.

Fixes: f214ff521fb1 ("iio: ti-ads8688: Update buffer allocation for timestamps")
Signed-off-by: Jonathan Cameron &lt;Jonathan.Cameron@huawei.com&gt;
Reviewed-by: Nuno Sá &lt;nuno.sa@analog.com&gt;
Link: https://lore.kernel.org/r/20210613152301.571002-5-jic23@kernel.org
Signed-off-by: Sasha Levin &lt;sashal@kernel.org&gt;
</content>
</entry>
<entry>
<title>iio: adc: mxs-lradc: Fix buffer alignment in iio_push_to_buffers_with_timestamp()</title>
<updated>2021-07-14T15:00:21Z</updated>
<author>
<name>Jonathan Cameron</name>
</author>
<published>2021-06-13T15:22:56Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=435967d9d5af5864cf77aff31ad4d4bfc336997a'/>
<id>urn:sha1:435967d9d5af5864cf77aff31ad4d4bfc336997a</id>
<content type='text'>
[ Upstream commit 6a6be221b8bd561b053f0701ec752a5ed9007f69 ]

To make code more readable, use a structure to express the channel
layout and ensure the timestamp is 8 byte aligned.
Add a comment on why the buffer is the size it is as not immediately
obvious.

Found during an audit of all calls of this function.

Fixes: 6dd112b9f85e ("iio: adc: mxs-lradc: Add support for ADC driver")
Signed-off-by: Jonathan Cameron &lt;Jonathan.Cameron@huawei.com&gt;
Cc: Andreas Klinger &lt;ak@it-klinger.de&gt;
Reviewed-by: Nuno Sá &lt;nuno.sa@analog.com&gt;
Link: https://lore.kernel.org/r/20210613152301.571002-4-jic23@kernel.org
Signed-off-by: Sasha Levin &lt;sashal@kernel.org&gt;
</content>
</entry>
<entry>
<title>iio: adc: hx711: Fix buffer alignment in iio_push_to_buffers_with_timestamp()</title>
<updated>2021-07-14T15:00:21Z</updated>
<author>
<name>Jonathan Cameron</name>
</author>
<published>2021-06-13T15:22:55Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=a5320c821919835ad2ae552db7a1f8142f6a9d8d'/>
<id>urn:sha1:a5320c821919835ad2ae552db7a1f8142f6a9d8d</id>
<content type='text'>
[ Upstream commit afe2a789fbf7acd1a05407fc7839cc08d23825e3 ]

To make code more readable, use a structure to express the channel
layout and ensure the timestamp is 8 byte aligned.

Found during an audit of all calls of this function.

Fixes: d3bf60450d47 ("iio: hx711: add triggered buffer support")
Signed-off-by: Jonathan Cameron &lt;Jonathan.Cameron@huawei.com&gt;
Cc: Andreas Klinger &lt;ak@it-klinger.de&gt;
Reviewed-by: Nuno Sá &lt;nuno.sa@analog.com&gt;
Link: https://lore.kernel.org/r/20210613152301.571002-3-jic23@kernel.org
Signed-off-by: Sasha Levin &lt;sashal@kernel.org&gt;
</content>
</entry>
<entry>
<title>iio: adc: at91-sama5d2: Fix buffer alignment in iio_push_to_buffers_with_timestamp()</title>
<updated>2021-07-14T15:00:21Z</updated>
<author>
<name>Jonathan Cameron</name>
</author>
<published>2021-06-13T15:22:54Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=d1d54f4b344069ee5e5a690ff62e9e2065a9d5ec'/>
<id>urn:sha1:d1d54f4b344069ee5e5a690ff62e9e2065a9d5ec</id>
<content type='text'>
[ Upstream commit 8f884758966259fa8c50c137ac6d4ce9bb7859db ]

To make code more readable, use a structure to express the channel
layout and ensure the timestamp is 8 byte aligned.

Found during an audit of all calls of this function.

Fixes: 5e1a1da0f8c9 ("iio: adc: at91-sama5d2_adc: add hw trigger and buffer support")
Signed-off-by: Jonathan Cameron &lt;Jonathan.Cameron@huawei.com&gt;
Cc: Eugen Hristev &lt;eugen.hristev@microchip.com&gt;
Reviewed-by: Nuno Sá &lt;nuno.sa@analog.com&gt;
Link: https://lore.kernel.org/r/20210613152301.571002-2-jic23@kernel.org
Signed-off-by: Sasha Levin &lt;sashal@kernel.org&gt;
</content>
</entry>
<entry>
<title>iio: adc: vf610: Fix buffer alignment in iio_push_to_buffers_with_timestamp()</title>
<updated>2021-07-14T15:00:11Z</updated>
<author>
<name>Jonathan Cameron</name>
</author>
<published>2021-05-01T17:01:11Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=db210cc73f3fd9790913e3450d02e1601d6ed5e8'/>
<id>urn:sha1:db210cc73f3fd9790913e3450d02e1601d6ed5e8</id>
<content type='text'>
[ Upstream commit 7765dfaa22ea08abf0c175e7553826ba2a939632 ]

To make code more readable, use a structure to express the channel
layout and ensure the timestamp is 8 byte aligned.

Found during an audit of all calls of uses of
iio_push_to_buffers_with_timestamp()

Fixes: 0010d6b44406 ("iio: adc: vf610: Add IIO buffer support for Vybrid ADC")
Signed-off-by: Jonathan Cameron &lt;Jonathan.Cameron@huawei.com&gt;
Cc: Stefan-Gabriel Mirea &lt;stefan-gabriel.mirea@nxp.com&gt;
Cc: Sanchayan Maity &lt;maitysanchayan@gmail.com&gt;
Reviewed-by: Andy Shevchenko &lt;andy.shevchenko@gmail.com&gt;
Link: https://lore.kernel.org/r/20210501170121.512209-10-jic23@kernel.org
Signed-off-by: Sasha Levin &lt;sashal@kernel.org&gt;
</content>
</entry>
<entry>
<title>iio: adc: ti-ads1015: Fix buffer alignment in iio_push_to_buffers_with_timestamp()</title>
<updated>2021-07-14T15:00:10Z</updated>
<author>
<name>Jonathan Cameron</name>
</author>
<published>2021-05-01T17:01:10Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=9fb49be54254133057f8e4629cf5db8375c1377c'/>
<id>urn:sha1:9fb49be54254133057f8e4629cf5db8375c1377c</id>
<content type='text'>
[ Upstream commit d85d71dd1ab67eaa7351f69fec512d8f09d164e1 ]

To make code more readable, use a structure to express the channel
layout and ensure the timestamp is 8 byte aligned.

Found during an audit of all calls of this function.

Fixes: ecc24e72f437 ("iio: adc: Add TI ADS1015 ADC driver support")
Signed-off-by: Jonathan Cameron &lt;Jonathan.Cameron@huawei.com&gt;
Cc: Daniel Baluta &lt;daniel.baluta@nxp.com&gt;
Cc: Andy Shevchenko &lt;andriy.shevchenko@linux.intel.com&gt;
Reviewed-by: Andy Shevchenko &lt;andy.shevchenko@gmail.com&gt;
Link: https://lore.kernel.org/r/20210501170121.512209-9-jic23@kernel.org
Signed-off-by: Sasha Levin &lt;sashal@kernel.org&gt;
</content>
</entry>
<entry>
<title>iio: adc: ad7192: handle regulator voltage error first</title>
<updated>2021-06-03T07:09:30Z</updated>
<author>
<name>Alexandru Ardelean</name>
</author>
<published>2021-05-13T12:07:44Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=0f9df705e0dd267570ce2b82aaab7ea342d2447b'/>
<id>urn:sha1:0f9df705e0dd267570ce2b82aaab7ea342d2447b</id>
<content type='text'>
commit b0f27fca5a6c7652e265aae6a4452ce2f2ed64da upstream.

This change fixes a corner-case, where for a zero regulator value, the
driver would exit early, initializing the driver only partially.
The driver would be in an unknown state.

This change reworks the code to check regulator_voltage() return value
for negative (error) first, and return early. This is the more common
idiom.

Also, this change is removing the 'voltage_uv' variable and using the 'ret'
value directly. The only place where 'voltage_uv' is being used is to
compute the internal reference voltage, and the type of this variable is
'int' (same are for 'ret'). Using only 'ret' avoids having to assign it on
the error path.

Fixes: ab0afa65bbc7 ("staging: iio: adc: ad7192: fail probe on get_voltage")
Cc: Alexandru Tachici &lt;alexandru.tachici@analog.com&gt;
Signed-off-by: Alexandru Ardelean &lt;aardelean@deviqon.com&gt;
Signed-off-by: Jonathan Cameron &lt;Jonathan.Cameron@huawei.com&gt;
Cc: &lt;Stable@vger.kernel.org&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
</content>
</entry>
<entry>
<title>iio: adc: ad7192: Avoid disabling a clock that was never enabled.</title>
<updated>2021-06-03T07:09:30Z</updated>
<author>
<name>Jonathan Cameron</name>
</author>
<published>2021-05-13T12:07:43Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=d6e18ad1e127cf171e5bf4e17d7674d645dd02d1'/>
<id>urn:sha1:d6e18ad1e127cf171e5bf4e17d7674d645dd02d1</id>
<content type='text'>
commit e32fe6d90f44922ccbb94016cfc3c238359e3e39 upstream.

Found by inspection.

If the internal clock source is being used, the driver doesn't
call clk_prepare_enable() and as such we should not call
clk_disable_unprepare()

Use the same condition to protect the disable path as is used
on the enable one.  Note this will all get simplified when
the driver moves over to a full devm_ flow, but that would make
backporting the fix harder.

Fix obviously predates move out of staging, but backporting will
become more complex (and is unlikely to happen), hence that patch
is given in the fixes tag.

Alexandru's sign off is here because he added this patch into
a larger series that Jonathan then applied.

Fixes: b581f748cce0 ("staging: iio: adc: ad7192: move out of staging")
Cc: Alexandru Tachici &lt;alexandru.tachici@analog.com&gt;
Reviewed-by: Alexandru Ardelean &lt;ardeleanalex@gmail.com&gt;
Signed-off-by: Jonathan Cameron &lt;Jonathan.Cameron@huawei.com&gt;
Signed-off-by: Alexandru Ardelean &lt;aardelean@deviqon.com&gt;
Cc: &lt;Stable@vger.kernel.org&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
</content>
</entry>
<entry>
<title>iio: adc: ad7793: Add missing error code in ad7793_setup()</title>
<updated>2021-06-03T07:09:30Z</updated>
<author>
<name>YueHaibing</name>
</author>
<published>2021-05-14T08:02:54Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=f4ab222b7d235ac0e134d844ee8d0fd051d7db15'/>
<id>urn:sha1:f4ab222b7d235ac0e134d844ee8d0fd051d7db15</id>
<content type='text'>
commit 4ed243b1da169bcbc1ec5507867e56250c5f1ff9 upstream.

Set error code while device ID query failed.

Fixes: 88bc30548aae ("IIO: ADC: New driver for AD7792/AD7793 3 Channel SPI ADC")
Signed-off-by: YueHaibing &lt;yuehaibing@huawei.com&gt;
Cc: &lt;Stable@vger.kernel.org&gt;
Signed-off-by: Jonathan Cameron &lt;Jonathan.Cameron@huawei.com&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
</content>
</entry>
<entry>
<title>iio: adc: ad7923: Fix undersized rx buffer.</title>
<updated>2021-06-03T07:09:30Z</updated>
<author>
<name>Jonathan Cameron</name>
</author>
<published>2021-05-01T16:53:14Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=a4cfd59f1543b1555d71c3c699e68ae1b2c3eeba'/>
<id>urn:sha1:a4cfd59f1543b1555d71c3c699e68ae1b2c3eeba</id>
<content type='text'>
commit 01fcf129f61b26d5b3d2d8afb03e770dee271bc8 upstream.

Fixes tag is where the max channels became 8, but timestamp space was missing
before that.

Fixes: 851644a60d20 ("iio: adc: ad7923: Add support for the ad7908/ad7918/ad7928")
Signed-off-by: Jonathan Cameron &lt;Jonathan.Cameron@huawei.com&gt;
Cc: Daniel Junho &lt;djunho@gmail.com&gt;
Reviewed-by: Andy Shevchenko &lt;andy.shevchenko@gmail.com&gt;
Link: https://lore.kernel.org/r/20210501165314.511954-3-jic23@kernel.org
Cc: &lt;Stable@vger.kernel.org&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
</content>
</entry>
</feed>
