On Fri, 15 Nov 2024 14:18:51 -0600 David Lechner <dlechner@xxxxxxxxxxxx> wrote: > This adds support for SPI offload to the ad7944 driver. This allows > reading data at the max sample rate of 2.5 MSPS. > > Signed-off-by: David Lechner <dlechner@xxxxxxxxxxxx> One request for some documentation on the storagebits value. Otherwise looks good to me. Reviewed-by: Jonathan Cameron <Jonathan.Cameron@xxxxxxxxxx> Note I'm giving tags because it might not all go through my tree + it's big and complex so they have the advantage I won't read things again if I've already tagged them (probably!) Jonathan > @@ -129,13 +144,33 @@ static const struct ad7944_chip_info _name##_chip_info = { \ > }, \ > IIO_CHAN_SOFT_TIMESTAMP(1), \ > }, \ > + /* basically the same minus soft timestamp plus sampling freq */\ > + .offload_channels = { \ > + { \ > + .type = IIO_VOLTAGE, \ > + .indexed = 1, \ > + .differential = _diff, \ > + .channel = 0, \ > + .channel2 = _diff ? 1 : 0, \ > + .scan_index = 0, \ > + .scan_type.sign = _diff ? 's' : 'u', \ > + .scan_type.realbits = _bits, \ > + .scan_type.storagebits = 32, \ Add a comment somewhere here on why it jumps up to 32 bits. > + .scan_type.endianness = IIO_CPU, \ > + .info_mask_separate = BIT(IIO_CHAN_INFO_RAW) \ > + | BIT(IIO_CHAN_INFO_SCALE) \ > + | BIT(IIO_CHAN_INFO_SAMP_FREQ), \ > + .info_mask_separate_available = \ > + BIT(IIO_CHAN_INFO_SAMP_FREQ), \ > + }, \ > + }, \ > }