Re: [PATCH v2 1/2] iio: gyro: Add driver support for ADXRS290
From: Nishant Malpani
Date: Tue Jul 21 2020 - 17:14:09 EST
On 22/07/20 2:05 am, Nishant Malpani wrote:
[...]
+ÂÂÂÂÂÂÂÂÂÂÂÂÂÂÂÂÂÂÂÂÂÂ return IIO_VAL_INT;
+ÂÂÂÂÂÂÂÂÂÂÂÂÂÂ default:
+ÂÂÂÂÂÂÂÂÂÂÂÂÂÂÂÂÂÂÂÂÂÂ return -EINVAL;
+ÂÂÂÂÂÂÂÂÂÂÂÂÂÂ }
...
+ÂÂÂÂÂÂÂÂÂÂÂÂÂÂ *vals = (const int *)adxrs290_lpf_3db_freq_tbl;
Why casting?
adxrs290_lpf_3db_freq_tbl is of type (int *)[2], right? Without the
casting, an incompatible-pointer-type error is thrown.
Sorry, the above is incorrect. adxrs290_lpf_3db_freq_tbl is a pointer to
an array of two ints.
[...]
Regards,
Nishant Malpani