On Tue, Aug 16, 2016 at 3:58 PM, Peter Meerwald-Stadler <pmeerw@xxxxxxxxxx> wrote: >> - The code did not regard the fact that only the upper 12 bits of >> the accelerometer values are valid. Shift these >> down four bits to yield the real raw value. > > maybe can do without nval temporary variable I could but I thought this code looks neater than the alternatives, I tried the inlining way but thought it was hard to read. Well let's see what Jonathan prefers, I can rewrite it for sure. Yours, Linus Walleij -- To unsubscribe from this list: send the line "unsubscribe linux-iio" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html