summaryrefslogtreecommitdiff
path: root/drivers
diff options
context:
space:
mode:
authorXiaohui Tao <xtao@nvidia.com>2013-10-14 10:36:05 -0700
committerHarshada Kale <hkale@nvidia.com>2013-10-15 04:05:19 -0700
commit09376c3e077fbda880f674d3d4df901c4a6654ca (patch)
tree896d235b088f30a300db72457203268fa3cbcf8b /drivers
parentdd95ea1e1644214f9953611628bb97f433aaf1ac (diff)
input: touch: raydium: import for service busy
Limit the number of service busy printks inside touch driver for power saving purposes from v60.0 to v56.2. Bug 1288488 Change-Id: I66d4fad29b90cf5eddcbb9f068596378d24ae925 Signed-off-by: Xiaohui Tao <xtao@nvidia.com> Reviewed-on: http://git-master/r/299024 Reviewed-by: Automatic_Commit_Validation_User Reviewed-by: Sang-Hun Lee <sanlee@nvidia.com> Reviewed-by: Robert Collins <rcollins@nvidia.com> Reviewed-by: Ankit Pashiney <apashiney@nvidia.com>
Diffstat (limited to 'drivers')
-rw-r--r--drivers/input/touchscreen/rm31080a_ts.c12
1 files changed, 10 insertions, 2 deletions
diff --git a/drivers/input/touchscreen/rm31080a_ts.c b/drivers/input/touchscreen/rm31080a_ts.c
index ce9889633ef6..ef1c1febafd1 100644
--- a/drivers/input/touchscreen/rm31080a_ts.c
+++ b/drivers/input/touchscreen/rm31080a_ts.c
@@ -211,6 +211,8 @@ unsigned char g_stRmWatchdogCmd[KRL_SIZE_RM_WATCHDOG];
unsigned char g_stRmTestModeCmd[KRL_SIZE_RM_TESTMODE];
unsigned char g_stRmSlowScanCmd[KRL_SIZE_RM_SLOWSCAN];
+static int g_service_busy_report_count;
+
/*=============================================================================
FUNCTION DECLARATION
=============================================================================*/
@@ -1056,10 +1058,16 @@ static void *rm_tch_enqueue_start(void)
if (!g_stQ.pQueue) /*error handling for no memory*/
return NULL;
- if (!rm_tch_queue_is_full())
+ if (!rm_tch_queue_is_full()) {
+ g_service_busy_report_count = 100;
return &g_stQ.pQueue[g_stQ.u16Rear];
+ }
- rm_printk("rm31080:touch service is busy,try again.\n");
+ if (g_service_busy_report_count < 0) {
+ g_service_busy_report_count = 100;
+ rm_printk("rm31080:touch service is busy,try again.\n");
+ } else
+ g_service_busy_report_count--;
return NULL;
}