We now support the ARM Versatile/PB platform, which means qemu-system-arm -M versatil...
[reactos.git] / reactos / boot / freeldr / freeldr / include / arch / arm / hardware.h
1 /*
2 * PROJECT: ReactOS Boot Loader
3 * LICENSE: GPL - See COPYING in the top level directory
4 * FILE: boot/freeldr/include/arch/arm/hardware.h
5 * PURPOSE: Header for ARC definitions (to be cleaned up)
6 * PROGRAMMERS: ReactOS Portable Systems Group
7 */
8
9 #ifndef _ARM_HARDWARE_
10 #define __ARM_HARDWARE_
11
12 #ifndef __REGISTRY_H
13 #include "../../reactos/registry.h"
14 #endif
15
16 //
17 // Marvell Feroceon-based SoC:
18 // Buffalo Linkstation, KuroBox Pro, D-Link DS323 and others
19 //
20 #define MACH_TYPE_FEROCEON 526
21
22 //
23 // ARM Versatile PB:
24 // qemu-system-arm -M versatilepb, RealView Development Boards and others
25 //
26 #define MACH_TYPE_VERSATILE_PB 387
27
28 //
29 // Compatible boot-loaders should return us this information
30 //
31 #define ARM_BOARD_CONFIGURATION_MAJOR_VERSION 1
32 #define ARM_BOARD_CONFIGURATION_MINOR_VERSION 1
33 typedef struct _ARM_BOARD_CONFIGURATION_BLOCK
34 {
35 ULONG MajorVersion;
36 ULONG MinorVersion;
37 ULONG BoardType;
38 ULONG ClockRate;
39 ULONG TimerRegisterBase;
40 ULONG UartRegisterBase;
41 ULONG MemoryMapEntryCount;
42 PBIOS_MEMORY_MAP MemoryMap;
43 CHAR CommandLine[256];
44 } ARM_BOARD_CONFIGURATION_BLOCK, *PARM_BOARD_CONFIGURATION_BLOCK;
45
46 //
47 // Static heap for ARC Hardware Component Tree
48 // 16KB oughta be enough for anyone.
49 //
50 #define HW_MAX_ARC_HEAP_SIZE 16 * 1024
51
52 //
53 // ARC Component Configuration Routines
54 //
55 VOID
56 NTAPI
57 FldrSetComponentInformation(
58 IN PCONFIGURATION_COMPONENT_DATA ComponentKey,
59 IN IDENTIFIER_FLAG Flags,
60 IN ULONG Key,
61 IN ULONG Affinity
62 );
63
64 VOID
65 NTAPI
66 FldrSetIdentifier(
67 IN PCONFIGURATION_COMPONENT_DATA ComponentKey,
68 IN PCHAR Identifier
69 );
70
71 VOID
72 NTAPI
73 FldrCreateSystemKey(
74 OUT PCONFIGURATION_COMPONENT_DATA *SystemKey
75 );
76
77 VOID
78 NTAPI
79 FldrCreateComponentKey(
80 IN PCONFIGURATION_COMPONENT_DATA SystemKey,
81 IN PWCHAR BusName,
82 IN ULONG BusNumber,
83 IN CONFIGURATION_CLASS Class,
84 IN CONFIGURATION_TYPE Type,
85 OUT PCONFIGURATION_COMPONENT_DATA *ComponentKey
86 );
87
88 VOID
89 NTAPI
90 FldrSetConfigurationData(
91 IN PCONFIGURATION_COMPONENT_DATA ComponentKey,
92 IN PCM_PARTIAL_RESOURCE_LIST ResourceList,
93 IN ULONG Size
94 );
95
96 VOID
97 ArmFeroSerialInit(IN ULONG Baudrate);
98
99 VOID
100 ArmFeroPutChar(IN INT Char);
101
102 INT
103 ArmFeroGetCh(VOID);
104
105 BOOLEAN
106 ArmFeroKbHit(VOID);
107
108 VOID
109 ArmVersaSerialInit(IN ULONG Baudrate);
110
111 VOID
112 ArmVersaPutChar(IN INT Char);
113
114 INT
115 ArmVersaGetCh(VOID);
116
117 BOOLEAN
118 ArmVersaKbHit(VOID);
119
120 extern PARM_BOARD_CONFIGURATION_BLOCK ArmBoardBlock;
121
122 #endif