Squash s2w commits

sweep2unlock: Add sweep2unlock v0.1

Thanks to Ezekeel's gladoskernel source which helped me
a lot in understanding how to emulate a virtual powerkey press.
The powerkey emulation is largely inspired by his coding for
Touch2Wake (Galaxy Nexus).

sweep2unlock: check if screen is offline

sweep2unlock: remove lck_reverse & checks

sweep2unlock: change sleep value, correct typo, add comment

sweep2unlock: change conditions

Don't assume unlock/lock is triggered if only one
condition is met. The new implementation includes
checking if 3 barriers are hit before triggering
the lock/unlock.
This assures only intentional triggering.
Also only allow one trigger as long as the finger
still touches the screen. Reset and allow another
trigger if the all fingers are lifted.

sweep2unlock: change barriers for screenoff trigger to avoid taking loads of screenshots :D

sweep2unlock: set scr_suspended early so that additional locks/unlocks are avoided

sweep2unlock: don't allow jumping through all barriers without having hit them

sweep2unlock: use an additional variable to determine if the barrier is already breached

sweep2unlock: change values to avoid taking screenshots when touching 'home'

sweep2unlock: break the loop if triggered, decrease sleep delay, change values to avoid screenshots when fast sweeping #2

sweep2unlock: Change barriers and homebutton back to original values.

The screenshot function from the HTC framework should
be disabled to avoid taking screenshots. This is the
proper way of doing things. We still have the AOSP
screenshot variant which can be accessed by pressing
Vol.DOWN + POWER at the same time and holding them for
about one second.

sweep2unlock: restructure early suspend / late resume hack

sweep2unlock: relocate main code, reformat it, change debug echo, slight 3rd barrier adjustment

sweep2unlock: use wakelocks

This solves not triggering irqs while the screen is offline.
It has to show how that affects battery life.

sweep2wake: rename sweep2unlock

sweep2wake: 'fat finger' fix ;)

sweep2wake: Add Kconfig entry

sweep2wake: redesign wakelocks

Only wakelock if necessary and release the wakelock immediately if not.

sweep2wake: allow the touchscreen irq to wake the phone

sweep2wake: remove wakelocks from the code

Since we now have a completely interrupt based wake up call
these wakelocks are obsolete so remove them.

sweep2wake: fix unresponsive touchscreen (depends on hw revision)

sweep2wake: redefine barriers for easier (un)locks

sweep2wake: add debug info

sweep2wake: fix typo, no need to enable something that is already enabled

sweep2wake: increase simulated powerkey press length

sweep2wake: Don't set suspended state if screen is not suspended

sweep2wake: add cmdline interface (on/off)

sweep2wake: reenable all suspend/resume commands if s2w_switch == false

cmdline_s2w: add debug output

sweep2wake: restructure ifdefs to gain readability

sweep2wake: always set suspend=1, reset baseline

If this is not set the baseline will not be reset
when the device comes from sleep, which results
in an unresponsive touchscreen. (Similiar to a
gounding issue)

sweep2wake: get button-backlight device

sweep2wake: enable dynamic button_backlight

If the screen is offline and you touch the home button (aka start a
sweep2unlock) the capacitive buttons will light up to guide your path.
They will be shutdown again as soon as you lift your finger.

sweep2wake: fix unlock start position

sweep2wake: Only reset the baseline if the screen is suspended, fix for old touchcontroller hwrev

sweep2wake: on resume suspend our touch controller for a short while
This allows resume to wake it up the right way a bit further down.
This is a HW revision fix, it is not needed for all touch controllers!

Sadly this breaks the sweep2unlock gesture.

sweep2wake: revert resetting the baseline

sweep2wake: button_backlight: fix backlight staying on

sweep2wake: fix led flickering as far as possible for now

sweep2wake: fix button_backlight being activated when sweeping to lock the phone

sweep2wake: increase fake suspend time, hw revision fix

sweep2wake: fix incorrect debug message

sweep2wake: add option to disable the button backlight control

input/touchscreen: cy8c: fix multitouch on certain hw revisions

sweep2wake: add sysfs-interface

sweep2wake: sysfs: no need to set the same value again :)

Signed-off-by: showp1984 <showp1984@gmail.com>

sweep2wake: sysfs: add missing ifdefs

Signed-off-by: showp1984 <showp1984@gmail.com>