Skip to content

Commit

Permalink
fix N900 tsc2005 disable sysfs disable path for newer kernels
Browse files Browse the repository at this point in the history
Add new path to check for enable/disable support of touschreen during
the display blank/unblank. In newer kernels the disable path has changed from
/sys/devices/platform/omap2_mcspi.1/spi1.0/ts_disable
to
/sys/devices/platform/omap2_mcspi.1/spi1.0/disable

Signed-off-by: Mika Laitio <ext-mika.1.laitio@nokia.com>
  • Loading branch information
lamikr authored and Kalle Jokiniemi committed Oct 2, 2012
1 parent 3238c16 commit 62e19ba
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 1 deletion.
3 changes: 3 additions & 0 deletions tklock.c
Expand Up @@ -3103,6 +3103,9 @@ gboolean mce_tklock_init(void)
if (g_access(MCE_RM680_TOUCHSCREEN_SYSFS_DISABLE_PATH, W_OK) == 0) {
mce_touchscreen_sysfs_disable_path =
MCE_RM680_TOUCHSCREEN_SYSFS_DISABLE_PATH;
} else if (g_access(MCE_RX44_TOUCHSCREEN_SYSFS_DISABLE_PATH_KERNEL2637, W_OK) == 0) {
mce_touchscreen_sysfs_disable_path =
MCE_RX44_TOUCHSCREEN_SYSFS_DISABLE_PATH_KERNEL2637;
} else if (g_access(MCE_RX44_TOUCHSCREEN_SYSFS_DISABLE_PATH, W_OK) == 0) {
mce_touchscreen_sysfs_disable_path =
MCE_RX44_TOUCHSCREEN_SYSFS_DISABLE_PATH;
Expand Down
3 changes: 2 additions & 1 deletion tklock.h
Expand Up @@ -70,7 +70,8 @@
#define MCE_RM680_TOUCHSCREEN_SYSFS_DISABLE_PATH "/sys/class/i2c-adapter/i2c-2/2-004b/disable_ts"

/** SysFS interface to enable/disable RX-44/RX-48/RX-51 touchscreen IRQs */
#define MCE_RX44_TOUCHSCREEN_SYSFS_DISABLE_PATH "/sys/devices/platform/omap2_mcspi.1/spi1.0/disable_ts"
#define MCE_RX44_TOUCHSCREEN_SYSFS_DISABLE_PATH "/sys/devices/platform/omap2_mcspi.1/spi1.0/disable_ts"
#define MCE_RX44_TOUCHSCREEN_SYSFS_DISABLE_PATH_KERNEL2637 "/sys/devices/platform/omap2_mcspi.1/spi1.0/disable"

/** Touch screen enable delay for calibration **/
#define MCE_TOUCHSCREEN_CALIBRATION_DELAY 100000 /* 100 milliseconds */
Expand Down

0 comments on commit 62e19ba

Please sign in to comment.