Fix the definition differences issue of termios.h in different version of kernel...
[mirror_edk2.git] / EdkUnixPkg / Dxe / UnixThunk / Cpu / CpuDriver.h
CommitLineData
c9093a06 1/*++\r
2\r
3Copyright (c) 2006, Intel Corporation \r
4All rights reserved. This program and the accompanying materials \r
5are licensed and made available under the terms and conditions of the BSD License \r
6which accompanies this distribution. The full text of the license may be found at \r
7http://opensource.org/licenses/bsd-license.php \r
8 \r
9THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS, \r
10WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED. \r
11\r
12Module Name:\r
13\r
14 CpuDriver.h\r
15\r
16Abstract:\r
17\r
377fc2ae 18 UNIX Emulation Architectural Protocol Driver as defined in Tiano.\r
c9093a06 19\r
20--*/\r
21\r
22#ifndef _CPU_ARCHITECTURAL_PROTOCOL_DRIVER_H_\r
23#define _CPU_ARCHITECTURAL_PROTOCOL_DRIVER_H_\r
24\r
25\r
26\r
061f40e7 27extern UINT8 CpuStrings[];\r
c9093a06 28\r
29//\r
30// Internal Data Structures\r
31//\r
32#define CPU_ARCH_PROT_PRIVATE_SIGNATURE EFI_SIGNATURE_32 ('c', 'a', 'p', 'd')\r
33\r
34typedef struct {\r
35 UINTN Signature;\r
36 EFI_HANDLE Handle;\r
37\r
38 EFI_CPU_ARCH_PROTOCOL Cpu;\r
39 EFI_CPU_IO_PROTOCOL CpuIo;\r
40\r
41 //\r
42 // Local Data for CPU interface goes here\r
43 //\r
44 BOOLEAN InterruptState;\r
45\r
46} CPU_ARCH_PROTOCOL_PRIVATE;\r
47\r
48#define CPU_ARCH_PROTOCOL_PRIVATE_DATA_FROM_THIS(a) \\r
49 CR (a, \\r
50 CPU_ARCH_PROTOCOL_PRIVATE, \\r
51 Cpu, \\r
52 CPU_ARCH_PROT_PRIVATE_SIGNATURE \\r
53 )\r
54\r
55EFI_STATUS\r
56EFIAPI\r
57CpuMemoryServiceRead (\r
58 IN EFI_CPU_IO_PROTOCOL *This,\r
59 IN EFI_CPU_IO_PROTOCOL_WIDTH Width,\r
60 IN UINT64 Address,\r
61 IN UINTN Count,\r
62 IN OUT VOID *Buffer\r
63 );\r
64\r
65EFI_STATUS\r
66EFIAPI\r
67CpuMemoryServiceWrite (\r
68 IN EFI_CPU_IO_PROTOCOL *This,\r
69 IN EFI_CPU_IO_PROTOCOL_WIDTH Width,\r
70 IN UINT64 Address,\r
71 IN UINTN Count,\r
72 IN OUT VOID *Buffer\r
73 );\r
74\r
75EFI_STATUS\r
76EFIAPI\r
77CpuIoServiceRead (\r
78 IN EFI_CPU_IO_PROTOCOL *This,\r
79 IN EFI_CPU_IO_PROTOCOL_WIDTH Width,\r
80 IN UINT64 UserAddress,\r
81 IN UINTN Count,\r
82 IN OUT VOID *UserBuffer\r
83 );\r
84\r
85EFI_STATUS\r
86EFIAPI\r
87CpuIoServiceWrite (\r
88 IN EFI_CPU_IO_PROTOCOL *This,\r
89 IN EFI_CPU_IO_PROTOCOL_WIDTH Width,\r
90 IN UINT64 UserAddress,\r
91 IN UINTN Count,\r
92 IN OUT VOID *UserBuffer\r
93 );\r
94\r
95\r
96#endif\r