Re: [PATCH V3 1/3] Input: cyttsp - Cypress TTSP capacitive multi-touch screen support

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



> To be more precise, the correct approach is:
> 
> 	for (i = 0; i < CY_MAX_ID; i++)
> 		if (!(used & (1 << i)))
> 			cyttsp_report_slot_empty(ts->input, i);
> 
> or
> 
> 	for (i = 0; i < CY_MAX_ID; i++)
> 		if (previous & (1 << i) &&
> 		    !(used & (1 << i)))
> 			cyttsp_report_slot_empty(ts->input, i);
> 
> where used is a bitmask to store each contact state for this event and
> previous is a bitmask to store the state for the previous event.
> 
> I looked at input_mt_report_slot_state() and it seems that it only
> checks whether the active parameter to send an ABS_MT_TRACKING_ID -1
> input event, so I think that I should use the latter.

Please implement the first version; the event never gets sent unless
there is an actual change, which you can see by following the code
deeper. If/when there are more drivers in need of a similar approach,
I might integrate the logic in the input-mt core instead.

Thanks,
Henrik
--
To unsubscribe from this list: send the line "unsubscribe linux-input" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[Index of Archives]     [Linux Media Devel]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]     [Linux Wireless Networking]     [Linux Omap]

  Powered by Linux