aboutsummaryrefslogtreecommitdiffstats
path: root/contrib/dib0700
diff options
context:
space:
mode:
authorMauro Carvalho Chehab <m.chehab@samsung.com>2014-06-24 18:42:59 -0300
committerMauro Carvalho Chehab <m.chehab@samsung.com>2014-06-24 18:42:59 -0300
commitf9b3e670a100ffb7d0218e6cc961c85a23a3e52e (patch)
tree597f628076d44bf9a0560b18c714449c1ee6c517 /contrib/dib0700
parente75d9692dc28c7fe1f7d2cf5e73c0cf3ace931ba (diff)
parse_dib0700.pl: Make the delays multiple of 10ms
That makes it more real to what the Kernel would provide. Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
Diffstat (limited to 'contrib/dib0700')
-rwxr-xr-xcontrib/dib0700/parse_dib0700.pl4
1 files changed, 3 insertions, 1 deletions
diff --git a/contrib/dib0700/parse_dib0700.pl b/contrib/dib0700/parse_dib0700.pl
index 15acd316..590cdd0f 100755
--- a/contrib/dib0700/parse_dib0700.pl
+++ b/contrib/dib0700/parse_dib0700.pl
@@ -14,6 +14,8 @@
use strict;
+my $min_delay = 10;
+
my %req_map = (
0x0 => "REQUEST_SET_USB_XFER_LEN",
0x2 => "REQUEST_I2C_READ",
@@ -110,7 +112,7 @@ while (<>) {
$delay = 0;
if (m/(IN|OUT): (\d+) ms \d+ ms/) {
- $delay = $2 if ($2 > 1);
+ $delay = $min_delay * int(($2 + $min_delay / 2) / $min_delay);
}
if ($req eq "REQUEST_I2C_READ") {

Privacy Policy