nuttx/uorb: Fix initialization error of variable of type struct sensor_ops_s
Related change: .flush :403469336f
.get_info :703bb7e7b3
Error Log: 1153 Building NuttX... 1154Error: sensors/bme680_uorb.c:428:3: error: initialization of 'int (*)(struct sensor_lowerhalf_s *, struct file *, long unsigned int)' from incompatible pointer type 'int (*)(struct sensor_lowerhalf_s *, struct file *, int, long unsigned int)' [-Werror=incompatible-pointer-types] 1155 428 | bme680_control /* control */ 1156 | ^~~~~~~~~~~~~~ Signed-off-by: wangjianyu3 <wangjianyu3@xiaomi.com>
This commit is contained in:
parent
f6c1d88931
commit
3ab62370cb
@ -157,9 +157,11 @@ static const struct sensor_ops_s g_adxl362_accel_ops =
|
||||
#else
|
||||
adxl362_fetch,
|
||||
#endif
|
||||
NULL, /* flush */
|
||||
NULL, /* selftest */
|
||||
NULL, /* set_calibvalue */
|
||||
NULL, /* calibrate */
|
||||
NULL, /* get_info */
|
||||
NULL, /* control */
|
||||
};
|
||||
|
||||
|
@ -105,9 +105,11 @@ static const struct sensor_ops_s g_adxl372_accel_ops =
|
||||
#else
|
||||
adxl372_fetch,
|
||||
#endif
|
||||
NULL, /* flush */
|
||||
NULL, /* selftest */
|
||||
NULL, /* set_calibvalue */
|
||||
NULL, /* calibrate */
|
||||
NULL /* get_info */
|
||||
NULL /* control */
|
||||
};
|
||||
|
||||
|
@ -114,9 +114,11 @@ static const struct sensor_ops_s g_bh1749nuc_sensor_ops =
|
||||
#else
|
||||
bh1749nuc_fetch,
|
||||
#endif
|
||||
NULL, /* flush */
|
||||
NULL, /* selftest */
|
||||
NULL, /* set_calibvalue */
|
||||
NULL, /* calibrate */
|
||||
NULL, /* get_info */
|
||||
bh1749nuc_control
|
||||
};
|
||||
|
||||
|
@ -422,9 +422,11 @@ static const struct sensor_ops_s g_sensor_ops =
|
||||
NULL, /* set_interval */
|
||||
NULL, /* batch */
|
||||
NULL, /* fetch */
|
||||
NULL, /* flush */
|
||||
NULL, /* selftest */
|
||||
NULL, /* set_calibvalue */
|
||||
bme680_calibrate, /* calibrate */
|
||||
NULL, /* get_info */
|
||||
bme680_control /* control */
|
||||
};
|
||||
|
||||
|
@ -126,9 +126,11 @@ static const struct sensor_ops_s g_sensor_ops =
|
||||
#else
|
||||
bmi270_fetch,
|
||||
#endif
|
||||
NULL, /* flush */
|
||||
NULL, /* selftest */
|
||||
NULL, /* set_calibvalue */
|
||||
NULL, /* calibrate */
|
||||
NULL, /* get_info */
|
||||
bmi270_control
|
||||
};
|
||||
|
||||
|
@ -180,9 +180,11 @@ static const struct sensor_ops_s g_bmm150_sensor_ops =
|
||||
#else
|
||||
bmm150_fetch,
|
||||
#endif
|
||||
NULL, /* flush */
|
||||
NULL, /* selftest */
|
||||
NULL, /* set_calibvalue */
|
||||
NULL, /* calibrate */
|
||||
NULL, /* get_info */
|
||||
NULL, /* control */
|
||||
};
|
||||
|
||||
|
@ -129,9 +129,11 @@ static const struct sensor_ops_s g_sensor_ops =
|
||||
#else
|
||||
.fetch = lsm9ds1_fetch,
|
||||
#endif
|
||||
NULL, /* flush */
|
||||
NULL, /* selftest */
|
||||
NULL, /* set_calibvalue */
|
||||
NULL, /* calibrate */
|
||||
NULL, /* get_info */
|
||||
.control = lsm9ds1_control
|
||||
};
|
||||
|
||||
|
@ -97,9 +97,11 @@ static const struct sensor_ops_s g_sensor_ops =
|
||||
NULL, /* set_interval */
|
||||
NULL, /* batch */
|
||||
NULL, /* fetch */
|
||||
NULL, /* flush */
|
||||
NULL, /* selftest */
|
||||
NULL, /* set_calibvalue */
|
||||
ltr308_calibrate, /* calibrate */
|
||||
NULL, /* get_info */
|
||||
NULL /* control */
|
||||
};
|
||||
|
||||
|
@ -374,9 +374,11 @@ static const struct sensor_ops_s g_mpu9250_ops =
|
||||
mpu9250_set_interval, /* set_interval */
|
||||
NULL, /* batch */
|
||||
NULL, /* fetch */
|
||||
NULL, /* flush */
|
||||
NULL, /* selftest */
|
||||
NULL, /* set_calibvalue */
|
||||
NULL, /* calibrate */
|
||||
NULL, /* get_info */
|
||||
mpu9250_control /* control */
|
||||
};
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user