delete IOCTL SENSORIOCSQUEUEDEPTH

- only used in test routines
This commit is contained in:
Daniel Agar
2018-11-06 07:43:43 +08:00
committed by Lorenz Meier
parent d2ed091a1d
commit dd0baaee91
31 changed files with 0 additions and 714 deletions
@@ -532,19 +532,6 @@ ACCELSIM::devIOCTL(unsigned long cmd, unsigned long arg)
}
}
case SENSORIOCSQUEUEDEPTH: {
/* lower bound is mandatory, upper bound is a sanity check */
if ((ul_arg < 1) || (ul_arg > 100)) {
return -EINVAL;
}
if (!_accel_reports->resize(ul_arg)) {
return -ENOMEM;
}
return OK;
}
case SENSORIOCRESET:
// Nothing to do for simulator
return OK;
@@ -612,19 +599,6 @@ ACCELSIM::mag_ioctl(unsigned long cmd, unsigned long arg)
}
}
case SENSORIOCSQUEUEDEPTH: {
/* lower bound is mandatory, upper bound is a sanity check */
if ((arg < 1) || (arg > 100)) {
return -EINVAL;
}
if (!_mag_reports->resize(arg)) {
return -ENOMEM;
}
return OK;
}
case SENSORIOCRESET:
// Nothing to do for simulator
return OK;
@@ -216,23 +216,6 @@ AirspeedSim::ioctl(cdev::file_t *filp, int cmd, unsigned long arg)
}
}
case SENSORIOCSQUEUEDEPTH: {
/* lower bound is mandatory, upper bound is a sanity check */
if ((arg < 1) || (arg > 100)) {
return -EINVAL;
}
//irqstate_t flags = px4_enter_critical_section();
if (!_reports->resize(arg)) {
//px4_leave_critical_section(flags);
return -ENOMEM;
}
//px4_leave_critical_section(flags);
return OK;
}
case SENSORIOCRESET:
/* XXX implement this */
return -EINVAL;
-26
View File
@@ -667,19 +667,6 @@ GYROSIM::devIOCTL(unsigned long cmd, unsigned long arg)
}
}
case SENSORIOCSQUEUEDEPTH: {
/* lower bound is mandatory, upper bound is a sanity check */
if ((arg < 1) || (arg > 100)) {
return -EINVAL;
}
if (!_accel_reports->resize(arg)) {
return -ENOMEM;
}
return OK;
}
case ACCELIOCSSCALE: {
/* copy scale, but only if off by a few percent */
struct accel_calibration_s *s = (struct accel_calibration_s *) arg;
@@ -710,19 +697,6 @@ GYROSIM::gyro_ioctl(unsigned long cmd, unsigned long arg)
case SENSORIOCRESET:
return devIOCTL(cmd, arg);
case SENSORIOCSQUEUEDEPTH: {
/* lower bound is mandatory, upper bound is a sanity check */
if ((arg < 1) || (arg > 100)) {
return -EINVAL;
}
if (!_gyro_reports->resize(arg)) {
return -ENOMEM;
}
return OK;
}
case GYROIOCSSCALE:
/* copy scale in */
memcpy(&_gyro_scale, (struct gyro_calibration_s *) arg, sizeof(_gyro_scale));