• Nuno Sá's avatar
    iio: adis: Support different burst sizes · 3e04cb60
    Nuno Sá authored
    Add burst_max_len to `adis_burst`. This is useful for devices which
    support different burst modes with different sizes. The buffer to be
    used in the spi transfer is allocated with this variable making sure
    that has space for all burst modes. The spi transfer length should hold
    the "real" burst length depending on the current burst mode configured
    in the device.
    
    Moreover, `extra_len` in `adis_burst` is made const and it should
    contain the smallest extra length necessary for a burst transfer. In
    `struct adis` was added a new `burst_extra_len` that should hold the
    extra bytes needed depending on the device instance being used.
    Signed-off-by: default avatarNuno Sá <nuno.sa@analog.com>
    Signed-off-by: default avatarJonathan Cameron <Jonathan.Cameron@huawei.com>
    3e04cb60
adis_buffer.c 6.67 KB