Lines Matching refs:old
182 struct ff_effect *old, in need_condition_modifier() argument
195 ret |= old->u.condition[i].right_saturation != new->u.condition[i].right_saturation in need_condition_modifier()
196 || old->u.condition[i].left_saturation != new->u.condition[i].left_saturation in need_condition_modifier()
197 || old->u.condition[i].right_coeff != new->u.condition[i].right_coeff in need_condition_modifier()
198 || old->u.condition[i].left_coeff != new->u.condition[i].left_coeff in need_condition_modifier()
199 || old->u.condition[i].deadband != new->u.condition[i].deadband in need_condition_modifier()
200 || old->u.condition[i].center != new->u.condition[i].center; in need_condition_modifier()
210 struct ff_effect *old, in need_magnitude_modifier() argument
219 return old->u.constant.level != effect->u.constant.level; in need_magnitude_modifier()
226 static int need_envelope_modifier(struct iforce *iforce, struct ff_effect *old, in need_envelope_modifier() argument
231 if (old->u.constant.envelope.attack_length != effect->u.constant.envelope.attack_length in need_envelope_modifier()
232 || old->u.constant.envelope.attack_level != effect->u.constant.envelope.attack_level in need_envelope_modifier()
233 || old->u.constant.envelope.fade_length != effect->u.constant.envelope.fade_length in need_envelope_modifier()
234 || old->u.constant.envelope.fade_level != effect->u.constant.envelope.fade_level) in need_envelope_modifier()
239 if (old->u.periodic.envelope.attack_length != effect->u.periodic.envelope.attack_length in need_envelope_modifier()
240 || old->u.periodic.envelope.attack_level != effect->u.periodic.envelope.attack_level in need_envelope_modifier()
241 || old->u.periodic.envelope.fade_length != effect->u.periodic.envelope.fade_length in need_envelope_modifier()
242 || old->u.periodic.envelope.fade_level != effect->u.periodic.envelope.fade_level) in need_envelope_modifier()
258 static int need_period_modifier(struct iforce *iforce, struct ff_effect *old, in need_period_modifier() argument
266 return (old->u.periodic.period != new->u.periodic.period in need_period_modifier()
267 || old->u.periodic.magnitude != new->u.periodic.magnitude in need_period_modifier()
268 || old->u.periodic.offset != new->u.periodic.offset in need_period_modifier()
269 || old->u.periodic.phase != new->u.periodic.phase); in need_period_modifier()
276 static int need_core(struct ff_effect *old, struct ff_effect *new) in need_core() argument
278 if (old->direction != new->direction in need_core()
279 || old->trigger.button != new->trigger.button in need_core()
280 || old->trigger.interval != new->trigger.interval in need_core()
281 || old->replay.length != new->replay.length in need_core()
282 || old->replay.delay != new->replay.delay) in need_core()
338 int iforce_upload_periodic(struct iforce *iforce, struct ff_effect *effect, struct ff_effect *old) in iforce_upload_periodic() argument
349 if (!old || need_period_modifier(iforce, old, effect)) { in iforce_upload_periodic()
351 old != NULL, in iforce_upload_periodic()
359 if (!old || need_envelope_modifier(iforce, old, effect)) { in iforce_upload_periodic()
361 old !=NULL, in iforce_upload_periodic()
380 if (!old || need_core(old, effect)) { in iforce_upload_periodic()
409 int iforce_upload_constant(struct iforce *iforce, struct ff_effect *effect, struct ff_effect *old) in iforce_upload_constant() argument
419 if (!old || need_magnitude_modifier(iforce, old, effect)) { in iforce_upload_constant()
421 old != NULL, in iforce_upload_constant()
428 if (!old || need_envelope_modifier(iforce, old, effect)) { in iforce_upload_constant()
430 old != NULL, in iforce_upload_constant()
440 if (!old || need_core(old, effect)) { in iforce_upload_constant()
465 int iforce_upload_condition(struct iforce *iforce, struct ff_effect *effect, struct ff_effect *old) in iforce_upload_condition() argument
481 if (!old || need_condition_modifier(iforce, old, effect)) { in iforce_upload_condition()
483 old != NULL, in iforce_upload_condition()
495 old != NULL, in iforce_upload_condition()
508 if (!old || need_core(old, effect)) { in iforce_upload_condition()