input: Add Atmel maXTouch touchscreen driver
A message that is not in the archive (sent off-list or not yet received): [email protected]
Hi Ulf,
Quoted 8 lines · Ulf Samuelsson
Hi Iiro,
Quoted 4 lines · Iiro Valkonen
/ / / Add Atmel maXTouch touchscreen driver (I2C interface)./ / The MT slots protocol will be implemented later./ / /
Quoted 17 lines
I believe there is already a driver for this hardware in the tree (
qt602240.c). Could you tell me what additional features your driver implements and why can't they be added to the existing driver.Thanks.
Signature · 10 lines
Dmitry ========= When we reviewed the Samsung QT602240 driver internally, we found 20 significant problems including memory leaks and doing I2C transfers within interrupts. I have been told that since I2C transfers can sleep, this is not a good idea.
It does so in _threaded_ interrupt which is perfectly fine. The need to access slower buses from the interrupt context was one of the reasons this facility was added to the kernel.
Quoted 2 lines
Configuration is done inside the driver, instead of using platform data. etc. etc.
The platform data is defined in include/linux/i2c/qt602240_ts.h and can be extended if needed.
The driver passed both mutitouch protocol review process and the general review and I believe most (all?) memory leaks and other issues presented in the original version have been fixed.
Quoted 5 lines
This is why I started writing a new driver and Iiro has added significant improvements/rewrites and is the current maintainer of the maXTouch driver within Atmel - the manufacturer of the device in question.
Quoted 7 lines
Have not checked if the
qt602240.cstill does memory leaks, but it still seems to make I2C transfers in the interrupt.My suggestion is that we deprecate the
qt602240.cand remove it in some future version.
Instead we should use the official driver from Atmel, that Iiro sent to the list.
No. I regret to say but I find the in-tree version of qt602240.c in much better shape than what was submitted by Iiro. Please identify the improvements that are needed for the driver and submit separate patches implementing these improvements.
Thanks.
Signature · 1 line
Dmitry