iio: adis_buffer: update device page after changing it
authorNuno Sa <nuno.sa@analog.com>
Tue, 27 Apr 2021 08:54:50 +0000 (10:54 +0200)
committerJonathan Cameron <Jonathan.Cameron@huawei.com>
Mon, 17 May 2021 12:49:09 +0000 (13:49 +0100)
commit0ae157081ca33d4ec5a997b67b8942bd149305b6
tree4c95b2e02087034138caf56aecf1acdfe8edf4b6
parent00a72db718fa198da3946286dcad222399ccd4fb
iio: adis_buffer: update device page after changing it

It makes more sense to update the device page as soon as we we
successfully changed it. Moreover, a follow up patch will handle
'spi_sync' error path which would leave 'current_page' in a inconsistent
state.

Signed-off-by: Nuno Sa <nuno.sa@analog.com>
Reviewed-by: Alexandru Ardelean <ardeleanalex@gmail.com>
Link: https://lore.kernel.org/r/20210427085454.30616-3-nuno.sa@analog.com
Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
drivers/iio/imu/adis_buffer.c