Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 262378
b: refs/heads/master
c: 3f27757
h: refs/heads/master
v: v3
  • Loading branch information
Rakesh Iyer authored and Dmitry Torokhov committed Jul 30, 2011
1 parent e914309 commit f281fcc
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 3 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 2501ec97663d84cfbc8fd8848c382f89c3bf8d1d
refs/heads/master: 3f27757a1182f5e3feff7425b1c3e43f3e466724
5 changes: 3 additions & 2 deletions trunk/drivers/input/keyboard/tegra-kbc.c
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,7 @@
* 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
*/

#include <linux/kernel.h>
#include <linux/module.h>
#include <linux/input.h>
#include <linux/platform_device.h>
Expand All @@ -37,7 +38,7 @@
#define KBC_ROW_SCAN_DLY 5

/* KBC uses a 32KHz clock so a cycle = 1/32Khz */
#define KBC_CYCLE_USEC 32
#define KBC_CYCLE_MS 32

/* KBC Registers */

Expand Down Expand Up @@ -647,7 +648,7 @@ static int __devinit tegra_kbc_probe(struct platform_device *pdev)
debounce_cnt = min(pdata->debounce_cnt, KBC_MAX_DEBOUNCE_CNT);
scan_time_rows = (KBC_ROW_SCAN_TIME + debounce_cnt) * num_rows;
kbc->repoll_dly = KBC_ROW_SCAN_DLY + scan_time_rows + pdata->repeat_cnt;
kbc->repoll_dly = ((kbc->repoll_dly * KBC_CYCLE_USEC) + 999) / 1000;
kbc->repoll_dly = DIV_ROUND_UP(kbc->repoll_dly, KBC_CYCLE_MS);

input_dev->name = pdev->name;
input_dev->id.bustype = BUS_HOST;
Expand Down

0 comments on commit f281fcc

Please sign in to comment.