driver: fix build error in accelgyro_icm426xx.c
Remove const attribute in icm426xx_set_range and icm426xx_init. Remove struct accelgyro_saved_data_t *data in icm426xx_set_range for no used. BUG=none BRANCH=none TEST=change the base motionsensor in Ezkinil and build the code successfully. The motion function is workable on Ezkinil DUT with the ICM chip. Signed-off-by: Sue Chen <sue.chen@quanta.corp-partner.google.com> Change-Id: I183bdd9de2d148466e5ba57ba6917108b04ce332 Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/2581160 Reviewed-by: Edward Hill <ecgh@chromium.org>
This commit is contained in:
parent
85ecd7589b
commit
6cc11c09ba
|
@ -450,10 +450,9 @@ out_unlock:
|
|||
return ret;
|
||||
}
|
||||
|
||||
static int icm426xx_set_range(const struct motion_sensor_t *s, int range,
|
||||
static int icm426xx_set_range(struct motion_sensor_t *s, int range,
|
||||
int rnd)
|
||||
{
|
||||
struct accelgyro_saved_data_t *data = ICM_GET_SAVED_DATA(s);
|
||||
int reg, ret, reg_val;
|
||||
int newrange;
|
||||
|
||||
|
@ -859,7 +858,7 @@ static int icm426xx_init_config(const struct motion_sensor_t *s)
|
|||
return icm_field_update8(s, ICM426XX_REG_INTF_CONFIG0, mask, val);
|
||||
}
|
||||
|
||||
static int icm426xx_init(const struct motion_sensor_t *s)
|
||||
static int icm426xx_init(struct motion_sensor_t *s)
|
||||
{
|
||||
struct icm_drv_data_t *st = ICM_GET_DATA(s);
|
||||
struct accelgyro_saved_data_t *saved_data = ICM_GET_SAVED_DATA(s);
|
||||
|
|
Loading…
Reference in New Issue