Lines Matching refs:old
178 struct ff_effect *old, in need_condition_modifier() argument
191 ret |= old->u.condition[i].right_saturation != new->u.condition[i].right_saturation in need_condition_modifier()
192 || old->u.condition[i].left_saturation != new->u.condition[i].left_saturation in need_condition_modifier()
193 || old->u.condition[i].right_coeff != new->u.condition[i].right_coeff in need_condition_modifier()
194 || old->u.condition[i].left_coeff != new->u.condition[i].left_coeff in need_condition_modifier()
195 || old->u.condition[i].deadband != new->u.condition[i].deadband in need_condition_modifier()
196 || old->u.condition[i].center != new->u.condition[i].center; in need_condition_modifier()
206 struct ff_effect *old, in need_magnitude_modifier() argument
215 return old->u.constant.level != effect->u.constant.level; in need_magnitude_modifier()
222 static int need_envelope_modifier(struct iforce *iforce, struct ff_effect *old, in need_envelope_modifier() argument
227 if (old->u.constant.envelope.attack_length != effect->u.constant.envelope.attack_length in need_envelope_modifier()
228 || old->u.constant.envelope.attack_level != effect->u.constant.envelope.attack_level in need_envelope_modifier()
229 || old->u.constant.envelope.fade_length != effect->u.constant.envelope.fade_length in need_envelope_modifier()
230 || old->u.constant.envelope.fade_level != effect->u.constant.envelope.fade_level) in need_envelope_modifier()
235 if (old->u.periodic.envelope.attack_length != effect->u.periodic.envelope.attack_length in need_envelope_modifier()
236 || old->u.periodic.envelope.attack_level != effect->u.periodic.envelope.attack_level in need_envelope_modifier()
237 || old->u.periodic.envelope.fade_length != effect->u.periodic.envelope.fade_length in need_envelope_modifier()
238 || old->u.periodic.envelope.fade_level != effect->u.periodic.envelope.fade_level) in need_envelope_modifier()
254 static int need_period_modifier(struct iforce *iforce, struct ff_effect *old, in need_period_modifier() argument
262 return (old->u.periodic.period != new->u.periodic.period in need_period_modifier()
263 || old->u.periodic.magnitude != new->u.periodic.magnitude in need_period_modifier()
264 || old->u.periodic.offset != new->u.periodic.offset in need_period_modifier()
265 || old->u.periodic.phase != new->u.periodic.phase); in need_period_modifier()
272 static int need_core(struct ff_effect *old, struct ff_effect *new) in need_core() argument
274 if (old->direction != new->direction in need_core()
275 || old->trigger.button != new->trigger.button in need_core()
276 || old->trigger.interval != new->trigger.interval in need_core()
277 || old->replay.length != new->replay.length in need_core()
278 || old->replay.delay != new->replay.delay) in need_core()
334 int iforce_upload_periodic(struct iforce *iforce, struct ff_effect *effect, struct ff_effect *old) in iforce_upload_periodic() argument
345 if (!old || need_period_modifier(iforce, old, effect)) { in iforce_upload_periodic()
347 old != NULL, in iforce_upload_periodic()
355 if (!old || need_envelope_modifier(iforce, old, effect)) { in iforce_upload_periodic()
357 old !=NULL, in iforce_upload_periodic()
376 if (!old || need_core(old, effect)) { in iforce_upload_periodic()
405 int iforce_upload_constant(struct iforce *iforce, struct ff_effect *effect, struct ff_effect *old) in iforce_upload_constant() argument
415 if (!old || need_magnitude_modifier(iforce, old, effect)) { in iforce_upload_constant()
417 old != NULL, in iforce_upload_constant()
424 if (!old || need_envelope_modifier(iforce, old, effect)) { in iforce_upload_constant()
426 old != NULL, in iforce_upload_constant()
436 if (!old || need_core(old, effect)) { in iforce_upload_constant()
461 int iforce_upload_condition(struct iforce *iforce, struct ff_effect *effect, struct ff_effect *old) in iforce_upload_condition() argument
477 if (!old || need_condition_modifier(iforce, old, effect)) { in iforce_upload_condition()
479 old != NULL, in iforce_upload_condition()
491 old != NULL, in iforce_upload_condition()
504 if (!old || need_core(old, effect)) { in iforce_upload_condition()