2 * Copyright (C) 2001 Mike Corrigan IBM Corporation
4 * This program is free software; you can redistribute it and/or modify
5 * it under the terms of the GNU General Public License as published by
6 * the Free Software Foundation; either version 2 of the License, or
7 * (at your option) any later version.
9 * This program is distributed in the hope that it will be useful,
10 * but WITHOUT ANY WARRANTY; without even the implied warranty of
11 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12 * GNU General Public License for more details.
14 * You should have received a copy of the GNU General Public License
15 * along with this program; if not, write to the Free Software
16 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
18 #ifndef _ASM_POWERPC_ISERIES_HV_TYPES_H
19 #define _ASM_POWERPC_ISERIES_HV_TYPES_H
22 * General typedefs for the hypervisor.
25 #include <asm/types.h>
28 typedef u16 HvLpInstanceId;
30 typedef u64 HvLpSystemSerialNum;
31 typedef u8 HvLpDeviceSerialNum[12];
32 typedef u16 HvLpSanHwSet;
34 typedef u16 HvLpBoard;
36 typedef u8 HvLpDeviceType[4];
37 typedef u8 HvLpDeviceModel[3];
38 typedef u64 HvIoToken;
39 typedef u8 HvLpName[8];
41 typedef u64 HvRealMemoryIndex;
42 typedef u32 HvLpIndexMap; /* Must hold HVMAXARCHITECTEDLPS bits!!! */
43 typedef u16 HvLpVrmIndex;
44 typedef u32 HvXmGenerationId;
45 typedef u8 HvLpBusPool;
46 typedef u8 HvLpSharedPoolIndex;
47 typedef u16 HvLpSharedProcUnitsX100;
48 typedef u8 HvLpVirtualLanIndex;
49 typedef u16 HvLpVirtualLanIndexMap; /* Must hold HVMAXARCHITECTEDVIRTUALLANS bits!!! */
50 typedef u16 HvBusNumber; /* Hypervisor Bus Number */
51 typedef u8 HvSubBusNumber; /* Hypervisor SubBus Number */
52 typedef u8 HvAgentId; /* Hypervisor DevFn */
55 #define HVMAXARCHITECTEDLPS 32
56 #define HVMAXARCHITECTEDVIRTUALLANS 16
57 #define HVMAXARCHITECTEDVIRTUALDISKS 32
58 #define HVMAXARCHITECTEDVIRTUALCDROMS 8
59 #define HVMAXARCHITECTEDVIRTUALTAPES 8
60 #define HVCHUNKSIZE (256 * 1024)
61 #define HVPAGESIZE (4 * 1024)
62 #define HVLPMINMEGSPRIMARY 256
63 #define HVLPMINMEGSSECONDARY 64
64 #define HVCHUNKSPERMEG 4
65 #define HVPAGESPERMEG 256
66 #define HVPAGESPERCHUNK 64
68 #define HvLpIndexInvalid ((HvLpIndex)0xff)
71 * Enums for the sub-components under PLIC
72 * Used in HvCall and HvPrimaryCall
76 HvCallCpuCtlsCompId = 1,
78 HvCallEventCompId = 3,
86 HvCallRsvd3CompId = 11,
87 HvCallRsvd2CompId = 12,
88 HvCallRsvd1CompId = 13,
90 HvPrimaryCallCompId = 0,
91 HvPrimaryCallCfgCompId = 1,
92 HvPrimaryCallPciCompId = 2,
93 HvPrimaryCallSmCompId = 3,
94 HvPrimaryCallSpdCompId = 4,
95 HvPrimaryCallXmCompId = 5,
96 HvPrimaryCallRioCompId = 6,
97 HvPrimaryCallRsvd7CompId = 7,
98 HvPrimaryCallRsvd6CompId = 8,
99 HvPrimaryCallRsvd5CompId = 9,
100 HvPrimaryCallRsvd4CompId = 10,
101 HvPrimaryCallRsvd3CompId = 11,
102 HvPrimaryCallRsvd2CompId = 12,
103 HvPrimaryCallRsvd1CompId = 13,
104 HvPrimaryCallMaxCompId = HvCallMaxCompId
107 struct HvLpBufferList {
112 #endif /* _ASM_POWERPC_ISERIES_HV_TYPES_H */