xref: /haiku/src/add-ons/kernel/cpu/x86/generic_x86.h (revision 1deede7388b04dbeec5af85cae7164735ea9e70d)
1 /*
2  * Copyright 2005, Haiku, Inc.
3  * Distributed under the terms of the MIT License.
4  *
5  * Authors:
6  *		Axel Dörfler, axeld@pinc-software.de
7  */
8 #ifndef CPU_GENERIC_x86_H
9 #define CPU_GENERIC_x86_H
10 
11 
12 #include <SupportDefs.h>
13 
14 
15 struct x86_mtrr_info;
16 
17 extern uint64 gPhysicalMask;
18 
19 #ifdef __cplusplus
20 extern "C" {
21 #endif
22 
23 extern uint32	generic_count_mtrrs(void);
24 extern void		generic_init_mtrrs(uint32 count);
25 extern void		generic_set_mtrr(uint32 index, uint64 base, uint64 length, uint8 type);
26 extern status_t generic_get_mtrr(uint32 index, uint64 *_base, uint64 *_length,
27 					uint8 *_type);
28 extern void		generic_set_mtrrs(uint8 defaultType,
29 					const struct x86_mtrr_info* infos,
30 					uint32 count, uint32 maxCount);
31 extern status_t generic_mtrr_compute_physical_mask(void);
32 
33 extern void		generic_dump_mtrrs(uint32 count);
34 
35 #ifdef __cplusplus
36 }
37 #endif
38 
39 #endif	// CPU_GENERIC_x86_H
40