|
@@ -1168,29 +1168,6 @@ out:
|
|
|
return retval;
|
|
|
}
|
|
|
|
|
|
-static inline int tv2int(const struct timeval *a, const struct timeval *b)
|
|
|
-{
|
|
|
- int usecs = 0;
|
|
|
- int sec = 0;
|
|
|
-
|
|
|
- if (b->tv_usec > a->tv_usec) {
|
|
|
- usecs = 1000000;
|
|
|
- sec--;
|
|
|
- }
|
|
|
-
|
|
|
- usecs += a->tv_usec - b->tv_usec;
|
|
|
-
|
|
|
- sec += a->tv_sec - b->tv_sec;
|
|
|
- sec *= 1000;
|
|
|
- usecs /= 1000;
|
|
|
- sec += usecs;
|
|
|
-
|
|
|
- if (sec < 0)
|
|
|
- sec = 1000;
|
|
|
-
|
|
|
- return sec;
|
|
|
-}
|
|
|
-
|
|
|
/*
|
|
|
* The directional pad behaves a bit differently, depending on whether this is
|
|
|
* one of the older ffdc devices or a newer device. Newer devices appear to
|