]> git.proxmox.com Git - mirror_edk2.git/blob - ArmPkg/Include/Library/ArmArchTimer.h
ArmPkg: Move TimerDxe and ArmArchTimerLib to new ArmGenericTimerCounterLib
[mirror_edk2.git] / ArmPkg / Include / Library / ArmArchTimer.h
1 /** @file
2
3 Copyright (c) 2011 - 2013, ARM Ltd. All rights reserved.<BR>
4
5 This program and the accompanying materials
6 are licensed and made available under the terms and conditions of the BSD License
7 which accompanies this distribution. The full text of the license may be found at
8 http://opensource.org/licenses/bsd-license.php
9
10 THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
11 WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
12
13 **/
14
15 #ifndef __ARM_ARCH_TIMER_H__
16 #define __ARM_ARCH_TIMER_H__
17
18 #define ARM_ARCH_TIMER_ENABLE (1 << 0)
19 #define ARM_ARCH_TIMER_IMASK (1 << 1)
20 #define ARM_ARCH_TIMER_ISTATUS (1 << 2)
21
22 typedef enum {
23 CntFrq = 0,
24 CntPct,
25 CntkCtl,
26 CntpTval,
27 CntpCtl,
28 CntvTval,
29 CntvCtl,
30 CntvCt,
31 CntpCval,
32 CntvCval,
33 CntvOff,
34 CnthCtl,
35 CnthpTval,
36 CnthpCtl,
37 CnthpCval,
38 RegMaximum
39 } ARM_ARCH_TIMER_REGS;
40
41 VOID
42 EFIAPI
43 ArmArchTimerReadReg (
44 IN ARM_ARCH_TIMER_REGS Reg,
45 OUT VOID *DstBuf
46 );
47
48 VOID
49 EFIAPI
50 ArmArchTimerWriteReg (
51 IN ARM_ARCH_TIMER_REGS Reg,
52 IN VOID *SrcBuf
53 );
54
55 #endif // __ARM_ARCH_TIMER_H__