History

Input: atmel_mxt_ts - use deep sleep mode when stopped

The hardcoded 0x83 CTRL setting overrides other settings in that byte, enabling extra reporting that may not be useful on a particular platform. Implement improved suspend mechanism via deep sleep. By writing zero to both the active and idle cycle times the maXTouch device can be put into a deep sleep mode, using minimal power. It is necessary to issue a calibrate command after the chip has spent any time in deep sleep, however a soft reset is unnecessary. Use the old method on Chromebook Pixel via platform data option. This patch also deals with the situation where the power configuration is zero on probe, which would mean that the device never wakes up to execute commands. After a config download, the T7 power configuration may have changed so it is necessary to re-read it.

Nick Dyer committed 11 years ago

Commit 7f3884f1 parent 7d6548a3 files · +120 −15Browse files

Showing the changes to include/linux/platform_data (1 of 3 files). Show all

Unified · Split

include/linux/platform_data/atmel_mxt_ts.h+31−0
@@ -0,0 +1,31 @@
1/*
2 * Atmel maXTouch Touchscreen driver
3 *
4 * Copyright (C) 2010 Samsung Electronics Co.Ltd
5 * Author: Joonyoung Shim <jy0922.shim@samsung.com>
6 *
7 * This program is free software; you can redistribute it and/or modify it
8 * under the terms of the GNU General Public License as published by the
9 * Free Software Foundation; either version 2 of the License, or (at your
10 * option) any later version.
11 */
12
13#ifndef __LINUX_PLATFORM_DATA_ATMEL_MXT_TS_H
14#define __LINUX_PLATFORM_DATA_ATMEL_MXT_TS_H
15
16#include <linux/types.h>
17
18enum mxt_suspend_mode {
19 MXT_SUSPEND_DEEP_SLEEP = 0,
20 MXT_SUSPEND_T9_CTRL = 1,
21};
22
23/* The platform data for the Atmel maXTouch touchscreen driver */
24struct mxt_platform_data {
25 unsigned long irqflags;
26 u8 t19_num_keys;
27 const unsigned int *t19_keymap;
28 enum mxt_suspend_mode suspend_mode;
29};
30
31#endif /* __LINUX_PLATFORM_DATA_ATMEL_MXT_TS_H */