Linux Kernel
3.7.1
Main Page
Related Pages
Modules
Namespaces
Data Structures
Files
File List
Globals
All
Data Structures
Namespaces
Files
Functions
Variables
Typedefs
Enumerations
Enumerator
Macros
Groups
Pages
drivers
staging
csr
csr_time.c
Go to the documentation of this file.
1
/*****************************************************************************
2
3
(c) Cambridge Silicon Radio Limited 2010
4
All rights reserved and confidential information of CSR
5
6
Refer to LICENSE.txt included with this source for details
7
on the license terms.
8
9
*****************************************************************************/
10
11
#include <linux/kernel.h>
12
#include <linux/version.h>
13
#include <linux/time.h>
14
#include <linux/module.h>
15
16
#include "
csr_time.h
"
17
18
CsrTime
CsrTimeGet
(
CsrTime
*
high
)
19
{
20
struct
timespec
ts;
21
u64
time
;
22
CsrTime
low
;
23
24
ts =
current_kernel_time
();
25
time = (
u64
) ts.
tv_sec
* 1000000 + ts.
tv_nsec
/ 1000;
26
27
if
(high !=
NULL
)
28
*high = (
CsrTime
) ((time >> 32) & 0xFFFFFFFF);
29
30
low = (
CsrTime
) (time & 0xFFFFFFFF);
31
32
return
low
;
33
}
34
EXPORT_SYMBOL_GPL
(
CsrTimeGet
);
Generated on Thu Jan 10 2013 14:27:37 for Linux Kernel by
1.8.2