iio: cros_ec: Set Gyroscope default frequency to 25Hz
Subsystems (2)
PATCH v2 1/1 iio: cros_ec: Set Gyroscope default frequency to 25Hz
BMI160 Minimium gyroscope frequency in normal mode is 25Hz. When older EC firmware do not report their sensors frequencies, use 25Hz as the minimum for gyroscope to be sure it works on BMI160.
frequency range via iio sysfs")
---
Change since v1: Fix spelling.
drivers/iio/common/cros_ec_sensors/cros_ec_sensors_core.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-)
drivers/iio/common/cros_ec_sensors/cros_ec_sensors_core.c +4 -1
@@ -85,10 +85,13 @@ static void get_default_min_max_freq(enum motionsensor_type type,switch (type) {case MOTIONSENSE_TYPE_ACCEL : -case MOTIONSENSE_TYPE_GYRO : *min_freq =12500 ; *max_freq =100000 ;break ; +case MOTIONSENSE_TYPE_GYRO : + *min_freq =25000 ; + *max_freq =100000 ; +break ;case MOTIONSENSE_TYPE_MAG : *min_freq =5000 ; *max_freq =25000 ;
Signature · 1 line
2.28.0.rc0.142.g3c755180ce-goog
Hi Gwendal,
Thank you for your patch.
Quoted 7 lines · Gwendal Grignou
BMI160 Minimium gyroscope frequency in normal mode is 25Hz. When older EC firmware do not report their sensors frequencies, use 25Hz as the minimum for gyroscope to be sure it works on BMI160.
Fixes ae7b02ad2f32d ("iio: common: cros_ec_sensors: Expose cros_ec_sensorsfrequency range via iio sysfs")
I think your email broke this line, it should be a single line. Other than that ...
Quoted 1 line
Signed-off-by Gwendal Grignou <[email protected]>
Quoted 26 lines
---
Change since v1: Fix spelling.drivers/iio/common/cros_ec_sensors/cros_ec_sensors_core.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-)drivers/iio/common/cros_ec_sensors/cros_ec_sensors_core.c +4
-1@@ -85,10 +85,13 @@ static void get_default_min_max_freq(enum motionsensor_type type,switch (type) {case MOTIONSENSE_TYPE_ACCEL : -case MOTIONSENSE_TYPE_GYRO : *min_freq =12500 ; *max_freq =100000 ;break ; +case MOTIONSENSE_TYPE_GYRO : + *min_freq =25000 ; + *max_freq =100000 ; +break ;case MOTIONSENSE_TYPE_MAG : *min_freq =5000 ; *max_freq =25000 ;
Quoted 13 lines · On Fri, 31 Jul 2020 13:17:53 +0200 Enric Balletbo i Serra…
Hi Gwendal,
Thank you for your patch.
Quoted 7 lines · Gwendal Grignou
BMI160 Minimium gyroscope frequency in normal mode is 25Hz. When older EC firmware do not report their sensors frequencies, use 25Hz as the minimum for gyroscope to be sure it works on BMI160.
Fixes ae7b02ad2f32d ("iio: common: cros_ec_sensors: Expose cros_ec_sensorsfrequency range via iio sysfs")
Quoted 5 lines
I think your email broke this line, it should be a single line. Other than that ...
Quoted 1 line
Signed-off-by Gwendal Grignou <[email protected]>Reviewed-by Enric Balletbo i Serra <[email protected]>
Applied to the fixes-togreg branch of iio.git and marked for stable.
Thanks,
Jonathan
Quoted 27 lines
Quoted 27 lines
---
Change since v1: Fix spelling.drivers/iio/common/cros_ec_sensors/cros_ec_sensors_core.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-)drivers/iio/common/cros_ec_sensors/cros_ec_sensors_core.c +4
-1@@ -85,10 +85,13 @@ static void get_default_min_max_freq(enum motionsensor_type type,switch (type) {case MOTIONSENSE_TYPE_ACCEL : -case MOTIONSENSE_TYPE_GYRO : *min_freq =12500 ; *max_freq =100000 ;break ; +case MOTIONSENSE_TYPE_GYRO : + *min_freq =25000 ; + *max_freq =100000 ; +break ;case MOTIONSENSE_TYPE_MAG : *min_freq =5000 ; *max_freq =25000 ;