aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/staging/csr/csr_time.h
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/staging/csr/csr_time.h')
-rw-r--r--drivers/staging/csr/csr_time.h82
1 files changed, 22 insertions, 60 deletions
diff --git a/drivers/staging/csr/csr_time.h b/drivers/staging/csr/csr_time.h
index 2a45f3e4024d..fc29e8e5e478 100644
--- a/drivers/staging/csr/csr_time.h
+++ b/drivers/staging/csr/csr_time.h
@@ -2,77 +2,43 @@
#define CSR_TIME_H__
/*****************************************************************************
- (c) Cambridge Silicon Radio Limited 2010
- All rights reserved and confidential information of CSR
+(c) Cambridge Silicon Radio Limited 2010
+All rights reserved and confidential information of CSR
- Refer to LICENSE.txt included with this source for details
- on the license terms.
+Refer to LICENSE.txt included with this source for details
+on the license terms.
*****************************************************************************/
#include <linux/types.h>
-#ifdef __cplusplus
-extern "C" {
-#endif
-
-/*******************************************************************************
-
- NAME
- CsrTime
-
- DESCRIPTION
- Type to hold a value describing the current system time, which is a
- measure of time elapsed since some arbitrarily defined fixed time
- reference, usually associated with system startup.
-
-*******************************************************************************/
-typedef u32 CsrTime;
-
-
/*******************************************************************************
- NAME
- CsrTimeUtc
+NAME
+ CsrTimeGet
- DESCRIPTION
- Type to hold a value describing a UTC wallclock time expressed in
- seconds and milliseconds elapsed since midnight January 1st 1970.
+DESCRIPTION
+ Returns the current system time in a low and a high part. The low part
+ is expressed in microseconds. The high part is incremented when the low
+ part wraps to provide an extended range.
-*******************************************************************************/
-typedef struct
-{
- u32 sec;
- u16 msec;
-} CsrTimeUtc;
-
-
-/*******************************************************************************
-
- NAME
- CsrTimeGet
+ The caller may provide a NULL pointer as the high parameter.
+ In this case the function just returns the low part and ignores the
+ high parameter.
- DESCRIPTION
- Returns the current system time in a low and a high part. The low part
- is expressed in microseconds. The high part is incremented when the low
- part wraps to provide an extended range.
+ Although the time is expressed in microseconds the actual resolution is
+ platform dependent and can be less. It is recommended that the
+ resolution is at least 10 milliseconds.
- The caller may provide a NULL pointer as the high parameter. In this case
- the function just returns the low part and ignores the high parameter.
+PARAMETERS
+ high - Pointer to variable that will receive the high part of the
+ current system time. Passing NULL is valid.
- Although the time is expressed in microseconds the actual resolution is
- platform dependent and can be less. It is recommended that the
- resolution is at least 10 milliseconds.
-
- PARAMETERS
- high - Pointer to variable that will receive the high part of the
- current system time. Passing NULL is valid.
-
- RETURNS
- Low part of current system time in microseconds.
+RETURNS
+ Low part of current system time in microseconds.
*******************************************************************************/
-CsrTime CsrTimeGet(CsrTime *high);
+u32 CsrTimeGet(u32 *high);
/*------------------------------------------------------------------*/
@@ -107,8 +73,4 @@ CsrTime CsrTimeGet(CsrTime *high);
*----------------------------------------------------------------------------*/
#define CsrTimeSub(t1, t2) ((s32) (t1) - (s32) (t2))
-#ifdef __cplusplus
-}
-#endif
-
#endif